/*! 
 * DevExtreme (dx.all.debug.js)
 * Version: 16.1.6
 * Build date: Fri Sep 02 2016
 *
 * Copyright (c) 2012 - 2016 Developer Express Inc. ALL RIGHTS RESERVED
 * EULA: https://www.devexpress.com/Support/EULAs/DevExtreme.xml
 */
"use strict";
! function(modules) {
    var installedModules = {};

    function __webpack_require__(moduleId) {
        if (installedModules[moduleId]) {
            return installedModules[moduleId].exports
        }
        var module = installedModules[moduleId] = {
            exports: {},
            id: moduleId,
            loaded: false
        };
        modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
        module.loaded = true;
        return module.exports
    }
    __webpack_require__.m = modules;
    __webpack_require__.c = installedModules;
    __webpack_require__.p = "";
    return __webpack_require__(0)
}([
    /*!**************************!*\
      !*** multi dx.all.debug ***!
      \**************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! c:\projects\DevExtreme\16.1\BuildLabel\Temp\DevExtreme.v16.1\repo\DXTreme.ClientResources\Root\Scripts\bundles\dx.all.js */ 1)
    },
    /*!***********************************!*\
      !*** ./Scripts/bundles/dx.all.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./modules/parts/widgets-all */ 2);
        __webpack_require__( /*! ./modules/parts/viz */ 439)
    },
    /*!******************************************************!*\
      !*** ./Scripts/bundles/modules/parts/widgets-all.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./widgets-mobile */ 3);
        __webpack_require__( /*! ./widgets-web */ 325)
    },
    /*!*********************************************************!*\
      !*** ./Scripts/bundles/modules/parts/widgets-mobile.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var ui = __webpack_require__( /*! ./widgets-base */ 4);
        ui.dxPanorama = __webpack_require__( /*! ../../../ui/panorama */ 320);
        ui.dxPivot = __webpack_require__( /*! ../../../ui/pivot */ 321);
        ui.dxSlideOut = __webpack_require__( /*! ../../../ui/slide_out */ 323);
        ui.dxSlideOutView = __webpack_require__( /*! ../../../ui/slide_out_view */ 324)
    },
    /*!*******************************************************!*\
      !*** ./Scripts/bundles/modules/parts/widgets-base.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var DevExpress = __webpack_require__( /*! ./core */ 5);
        __webpack_require__( /*! ./data */ 180);
        var ui = DevExpress.ui = __webpack_require__( /*! ../../../bundles/modules/ui */ 192);
        ui.themes = __webpack_require__( /*! ../../../ui/themes */ 143);
        ui.setTemplateEngine = __webpack_require__( /*! ../../../ui/set_template_engine */ 193);
        ui.dialog = __webpack_require__( /*! ../../../ui/dialog */ 194);
        ui.notify = __webpack_require__( /*! ../../../ui/notify */ 199);
        ui.dxActionSheet = __webpack_require__( /*! ../../../ui/action_sheet */ 201);
        ui.dxAutocomplete = __webpack_require__( /*! ../../../ui/autocomplete */ 203);
        ui.dxBox = __webpack_require__( /*! ../../../ui/box */ 245);
        ui.dxButton = __webpack_require__( /*! ../../../ui/button */ 196);
        ui.dxCalendar = __webpack_require__( /*! ../../../ui/calendar */ 246);
        ui.dxCheckBox = __webpack_require__( /*! ../../../ui/check_box */ 241);
        ui.dxColorBox = __webpack_require__( /*! ../../../ui/color_box */ 252);
        ui.dxDateBox = __webpack_require__( /*! ../../../ui/date_box */ 259);
        ui.dxDeferRendering = __webpack_require__( /*! ../../../ui/defer_rendering */ 271);
        ui.dxDropDownMenu = __webpack_require__( /*! ../../../ui/drop_down_menu */ 272);
        ui.dxFileUploader = __webpack_require__( /*! ../../../ui/file_uploader */ 273);
        ui.dxForm = __webpack_require__( /*! ../../../ui/form */ 276);
        ui.dxGallery = __webpack_require__( /*! ../../../ui/gallery */ 287);
        ui.dxList = __webpack_require__( /*! ../../../ui/list */ 213);
        ui.dxLoadIndicator = __webpack_require__( /*! ../../../ui/load_indicator */ 231);
        ui.dxLoadPanel = __webpack_require__( /*! ../../../ui/load_panel */ 239);
        ui.dxLookup = __webpack_require__( /*! ../../../ui/lookup */ 288);
        ui.dxMap = __webpack_require__( /*! ../../../ui/map */ 289);
        ui.dxMultiView = __webpack_require__( /*! ../../../ui/multi_view */ 283);
        ui.dxNavBar = __webpack_require__( /*! ../../../ui/nav_bar */ 296);
        ui.dxNumberBox = __webpack_require__( /*! ../../../ui/number_box */ 255);
        ui.dxOverlay = __webpack_require__( /*! ../../../ui/overlay */ 109);
        ui.dxPopover = __webpack_require__( /*! ../../../ui/popover */ 202);
        ui.dxPopup = __webpack_require__( /*! ../../../ui/popup */ 195);
        ui.dxProgressBar = __webpack_require__( /*! ../../../ui/progress_bar */ 274);
        ui.dxRadioGroup = __webpack_require__( /*! ../../../ui/radio_group */ 297);
        ui.dxRangeSlider = __webpack_require__( /*! ../../../ui/range_slider */ 299);
        ui.dxResizable = __webpack_require__( /*! ../../../ui/resizable */ 112);
        ui.dxResponsiveBox = __webpack_require__( /*! ../../../ui/responsive_box */ 281);
        ui.dxScrollView = __webpack_require__( /*! ../../../ui/scroll_view */ 306);
        ui.dxSelectBox = __webpack_require__( /*! ../../../ui/select_box */ 307);
        ui.dxSlider = __webpack_require__( /*! ../../../ui/slider */ 300);
        ui.dxSwitch = __webpack_require__( /*! ../../../ui/switch */ 308);
        ui.dxTabPanel = __webpack_require__( /*! ../../../ui/tab_panel */ 282);
        ui.dxTabs = __webpack_require__( /*! ../../../ui/tabs */ 284);
        ui.dxTagBox = __webpack_require__( /*! ../../../ui/tag_box */ 309);
        ui.dxTextArea = __webpack_require__( /*! ../../../ui/text_area */ 310);
        ui.dxTextBox = __webpack_require__( /*! ../../../ui/text_box */ 206);
        ui.dxTileView = __webpack_require__( /*! ../../../ui/tile_view */ 311);
        ui.dxToast = __webpack_require__( /*! ../../../ui/toast */ 200);
        ui.dxToolbar = __webpack_require__( /*! ../../../ui/toolbar */ 312);
        ui.dxTooltip = __webpack_require__( /*! ../../../ui/tooltip */ 303);
        ui.dxTrackBar = __webpack_require__( /*! ../../../ui/track_bar */ 275);
        DevExpress.validationEngine = __webpack_require__( /*! ../../../ui/validation_engine */ 117);
        ui.dxValidationSummary = __webpack_require__( /*! ../../../ui/validation_summary */ 285);
        ui.dxValidationGroup = __webpack_require__( /*! ../../../ui/validation_group */ 286);
        ui.dxValidator = __webpack_require__( /*! ../../../ui/validator */ 279);
        ui.CollectionWidget = __webpack_require__( /*! ../../../ui/collection/ui.collection_widget.edit */ 151);
        ui.dxDropDownEditor = __webpack_require__( /*! ../../../ui/drop_down_editor/ui.drop_down_editor */ 205);
        module.exports = ui
    },
    /*!***********************************************!*\
      !*** ./Scripts/bundles/modules/parts/core.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var DevExpress = __webpack_require__( /*! ../../../bundles/modules/core */ 6);
        DevExpress.framework = __webpack_require__( /*! ../../../bundles/modules/framework */ 85);
        __webpack_require__( /*! ../../../integration/angular */ 144);
        __webpack_require__( /*! ../../../integration/knockout */ 86);
        __webpack_require__( /*! ../../../localization/globalize/core */ 171);
        __webpack_require__( /*! ../../../localization/globalize/message */ 173);
        __webpack_require__( /*! ../../../localization/globalize/number */ 174);
        __webpack_require__( /*! ../../../localization/globalize/date */ 175);
        __webpack_require__( /*! ../../../localization/globalize/currency */ 176);
        __webpack_require__( /*! ../../../events/click */ 64);
        __webpack_require__( /*! ../../../events/contextmenu */ 165);
        __webpack_require__( /*! ../../../events/dblclick */ 177);
        __webpack_require__( /*! ../../../events/drag */ 110);
        __webpack_require__( /*! ../../../events/hold */ 164);
        __webpack_require__( /*! ../../../events/hover */ 102);
        __webpack_require__( /*! ../../../events/pointer */ 65);
        __webpack_require__( /*! ../../../events/swipe */ 178);
        __webpack_require__( /*! ../../../events/transform */ 179);
        module.exports = DevExpress
    },
    /*!*****************************************!*\
      !*** ./Scripts/bundles/modules/core.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var DevExpress = window.DevExpress = window.DevExpress || {};
        DevExpress.clientExporter = __webpack_require__( /*! ../../client_exporter */ 7);
        DevExpress.VERSION = __webpack_require__( /*! ../../core/version */ 16);
        DevExpress.Class = __webpack_require__( /*! ../../core/class */ 20);
        DevExpress.DOMComponent = __webpack_require__( /*! ../../core/dom_component */ 29);
        DevExpress.Component = __webpack_require__( /*! ../../core/component */ 34);
        DevExpress.registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43);
        DevExpress.devices = __webpack_require__( /*! ../../core/devices */ 40);
        var errors = DevExpress.errors = __webpack_require__( /*! ../../core/errors */ 17);
        DevExpress.Color = __webpack_require__( /*! ../../color */ 26);
        var $ = __webpack_require__( /*! jquery */ 9);
        var compareVersions = __webpack_require__( /*! ../../core/utils/version */ 45).compare;
        if (compareVersions($.fn.jquery, [1, 10]) < 0) {
            throw errors.Error("E0012")
        }
        var animationFrame = __webpack_require__( /*! ../../animation/frame */ 46);
        /**
         * @name requestAnimationFrame
         * @publicName requestAnimationFrame(callback)
         * @type method
         * @deprecated utils_requestAnimationFrame
         */
        DevExpress.requestAnimationFrame = function() {
            errors.log("W0000", "DevExpress.requestAnimationFrame", "15.2", "Use the 'DevExpress.utils.requestAnimationFrame' method instead.");
            return animationFrame.requestAnimationFrame.apply(animationFrame, arguments)
        };
        DevExpress.cancelAnimationFrame = function() {
            errors.log("W0000", "DevExpress.cancelAnimationFrame", "15.2", "Use the 'DevExpress.utils.cancelAnimationFrame' method instead.");
            return animationFrame.cancelAnimationFrame.apply(animationFrame, arguments)
        };
        DevExpress.EventsMixin = __webpack_require__( /*! ../../core/events_mixin */ 39);
        DevExpress.utils = {};
        DevExpress.utils.requestAnimationFrame = animationFrame.requestAnimationFrame;
        DevExpress.utils.cancelAnimationFrame = animationFrame.cancelAnimationFrame;
        DevExpress.utils.initMobileViewport = __webpack_require__( /*! ../../mobile/init_mobile_viewport/init_mobile_viewport */ 47).initMobileViewport;
        DevExpress.utils.extendFromObject = __webpack_require__( /*! ../../core/utils/object */ 37).extendFromObject;
        DevExpress.utils.createComponents = __webpack_require__( /*! ../../core/utils/dom */ 50).createComponents;
        DevExpress.utils.triggerShownEvent = __webpack_require__( /*! ../../core/utils/dom */ 50).triggerShownEvent;
        DevExpress.utils.triggerHidingEvent = __webpack_require__( /*! ../../core/utils/dom */ 50).triggerHidingEvent;
        DevExpress.utils.resetActiveElement = __webpack_require__( /*! ../../core/utils/dom */ 50).resetActiveElement;
        DevExpress.utils.findBestMatches = __webpack_require__( /*! ../../core/utils/common */ 14).findBestMatches;
        DevExpress.createQueue = __webpack_require__( /*! ../../core/utils/queue */ 51).create;
        DevExpress.utils.dom = __webpack_require__( /*! ../../core/utils/dom */ 50);
        DevExpress.utils.common = __webpack_require__( /*! ../../core/utils/common */ 14);
        DevExpress.utils.date = __webpack_require__( /*! ../../core/utils/date */ 52);
        DevExpress.utils.browser = __webpack_require__( /*! ../../core/utils/browser */ 18);
        DevExpress.utils.inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49);
        DevExpress.utils.resizeCallbacks = __webpack_require__( /*! ../../core/utils/window */ 30).resizeCallbacks;
        DevExpress.utils.console = __webpack_require__( /*! ../../core/utils/console */ 12);
        DevExpress.utils.string = __webpack_require__( /*! ../../core/utils/string */ 13);
        DevExpress.utils.support = __webpack_require__( /*! ../../core/utils/support */ 48);
        DevExpress.processHardwareBackButton = __webpack_require__( /*! ../../mobile/process_hardware_back_button */ 53);
        DevExpress.viewPort = __webpack_require__( /*! ../../core/utils/view_port */ 42).value;
        DevExpress.hideTopOverlay = __webpack_require__( /*! ../../mobile/hide_top_overlay */ 54);
        DevExpress.formatHelper = __webpack_require__( /*! ../../format_helper */ 55);
        var config = DevExpress.config = __webpack_require__( /*! ../../core/config */ 15);
        Object.defineProperty(DevExpress, "rtlEnabled", {
            get: function() {
                errors.log("W0003", "DevExpress", "rtlEnabled", "16.1", "Use the 'DevExpress.config' method instead");
                return config().rtlEnabled
            },
            set: function(value) {
                errors.log("W0003", "DevExpress", "rtlEnabled", "16.1", "Use the 'DevExpress.config' method instead");
                config({
                    rtlEnabled: value
                })
            }
        });
        Object.defineProperty(DevExpress, "designMode", {
            get: function() {
                return config().designMode
            },
            set: function(value) {
                config({
                    designMode: value
                })
            }
        });
        DevExpress.animationPresets = __webpack_require__( /*! ../../animation/presets/presets */ 58).presets;
        DevExpress.fx = __webpack_require__( /*! ../../animation/fx */ 59);
        DevExpress.TransitionExecutor = __webpack_require__( /*! ../../animation/transition_executor/transition_executor */ 63).TransitionExecutor;
        DevExpress.AnimationPresetCollection = __webpack_require__( /*! ../../animation/presets/presets */ 58).PresetCollection;
        module.exports = DevExpress.events = {};
        DevExpress.events.click = __webpack_require__( /*! ../../events/click */ 64);
        DevExpress.events.utils = __webpack_require__( /*! ../../events/utils */ 62);
        DevExpress.events.GestureEmitter = __webpack_require__( /*! ../../events/gesture/emitter.gesture */ 78);
        DevExpress.localization = {};
        DevExpress.localization.message = __webpack_require__( /*! ../../localization/message */ 80);
        DevExpress.localization.number = __webpack_require__( /*! ../../localization/number */ 22);
        DevExpress.localization.date = __webpack_require__( /*! ../../localization/date */ 56);
        __webpack_require__( /*! ../../localization/currency */ 24);
        module.exports = DevExpress
    },
    /*!************************************!*\
      !*** ./Scripts/client_exporter.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var fileSaver = __webpack_require__( /*! ./client_exporter/file_saver */ 8).fileSaver,
            _isFunction = __webpack_require__( /*! ./core/utils/common */ 14).isFunction;
        exports.export = function(data, options, getData) {
            if (!data) {
                return
            }
            var exportingAction = options.exportingAction,
                exportedAction = options.exportedAction,
                fileSavingAction = options.fileSavingAction,
                eventArgs = {
                    fileName: options.fileName,
                    format: options.format,
                    cancel: false
                };
            _isFunction(exportingAction) && exportingAction(eventArgs);
            if (!eventArgs.cancel) {
                getData(data, options, function(blob) {
                    _isFunction(exportedAction) && exportedAction();
                    if (_isFunction(fileSavingAction)) {
                        eventArgs.data = blob;
                        fileSavingAction(eventArgs)
                    }
                    if (!eventArgs.cancel) {
                        fileSaver.saveAs(eventArgs.fileName, options.format, blob, options.proxyUrl)
                    }
                })
            }
        };
        exports.fileSaver = fileSaver;
        exports.excel = {
            creator: __webpack_require__( /*! ./client_exporter/excel_creator */ 19).ExcelCreator,
            getData: __webpack_require__( /*! ./client_exporter/excel_creator */ 19).getData,
            formatConverter: __webpack_require__( /*! ./client_exporter/excel_creator */ 19).excelFormatConverter
        };
        exports.excel.__internals = __webpack_require__( /*! ./client_exporter/excel_creator */ 19).__internals;
        exports.image = {
            creator: __webpack_require__( /*! ./client_exporter/image_creator */ 25).imageCreator,
            getData: __webpack_require__( /*! ./client_exporter/image_creator */ 25).getData
        };
        exports.pdf = {
            creator: __webpack_require__( /*! ./client_exporter/pdf_creator */ 27).pdfCreator,
            getData: __webpack_require__( /*! ./client_exporter/pdf_creator */ 27).getData
        };
        exports.svg = {
            creator: __webpack_require__( /*! ./client_exporter/svg_creator */ 28).svgCreator,
            getData: __webpack_require__( /*! ./client_exporter/svg_creator */ 28).getData
        }
    },
    /*!***********************************************!*\
      !*** ./Scripts/client_exporter/file_saver.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../ui/widget/ui.errors */ 10),
            browser = __webpack_require__( /*! ../core/utils/browser */ 18),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            FILE_EXTESIONS = {
                EXCEL: "xlsx",
                CSS: "css",
                PNG: "png",
                JPEG: "jpeg",
                GIF: "gif",
                SVG: "svg",
                PDF: "pdf"
            };
        var MIME_TYPES = exports.MIME_TYPES = {
            CSS: "text/css",
            EXCEL: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
            PNG: "image/png",
            JPEG: "image/jpeg",
            GIF: "image/gif",
            SVG: "image/svg+xml",
            PDF: "application/pdf"
        };
        exports.fileSaver = {
            _getDataUri: function(format, data) {
                return "data:" + MIME_TYPES[format] + ";base64," + data
            },
            _linkDownloader: function(fileName, href, callback) {
                var exportLinkElement = document.createElement("a"),
                    attributes = {
                        download: fileName,
                        href: href
                    };
                if (commonUtils.isDefined(callback)) {
                    attributes.onclick = callback
                }
                document.body.appendChild(exportLinkElement);
                $(exportLinkElement).css({
                    display: "none"
                }).text("load").attr(attributes)[0].click();
                return exportLinkElement
            },
            _formDownloader: function(proxyUrl, fileName, contentType, data, callback) {
                var formAttributes = {
                        method: "post",
                        action: proxyUrl,
                        enctype: "multipart/form-data"
                    },
                    exportForm = $("<form>").css({
                        display: "none"
                    }).attr(formAttributes);
                if (commonUtils.isDefined(callback)) {
                    exportForm.submit(callback)
                }
                exportForm.append('<input type="hidden" name="fileName" value="' + fileName + '" />');
                exportForm.append('<input type="hidden" name="contentType" value="' + contentType + '" />');
                exportForm.append('<input type="hidden" name="data" value="' + data + '" />');
                exportForm.appendTo("body");
                exportForm.submit();
                if (exportForm.submit()) {
                    exportForm.remove()
                }
                return exportForm
            },
            _saveByProxy: function(proxyUrl, fileName, format, data, callback) {
                return this._formDownloader(proxyUrl, fileName, MIME_TYPES[format], data, callback)
            },
            _winJSBlobSave: function(blob, fileName, format) {
                var savePicker = new Windows.Storage.Pickers.FileSavePicker;
                savePicker.suggestedStartLocation = Windows.Storage.Pickers.PickerLocationId.documentsLibrary;
                savePicker.fileTypeChoices.insert(MIME_TYPES[format], ["." + FILE_EXTESIONS[format]]);
                savePicker.suggestedFileName = fileName;
                savePicker.pickSaveFileAsync().then(function(file) {
                    if (file) {
                        file.openAsync(Windows.Storage.FileAccessMode.readWrite).then(function(outputStream) {
                            var inputStream = blob.msDetachStream();
                            Windows.Storage.Streams.RandomAccessStream.copyAsync(inputStream, outputStream).then(function() {
                                outputStream.flushAsync().done(function() {
                                    inputStream.close();
                                    outputStream.close()
                                })
                            })
                        })
                    }
                })
            },
            _saveBlobAs: function(fileName, format, data, linkClick) {
                this._blobSaved = false;
                if (commonUtils.isDefined(navigator.msSaveOrOpenBlob)) {
                    navigator.msSaveOrOpenBlob(data, fileName);
                    this._blobSaved = true
                } else {
                    if (commonUtils.isDefined(window.WinJS)) {
                        this._winJSBlobSave(data, fileName, format);
                        this._blobSaved = true
                    } else {
                        var URL = window.URL || window.webkitURL || window.mozURL || window.msURL || window.oURL;
                        linkClick = commonUtils.isDefined(linkClick) ? linkClick : function() {
                            var link = $("#dxExportLink");
                            URL.revokeObjectURL(link.attr("href"));
                            link.remove()
                        };
                        if (commonUtils.isDefined(URL)) {
                            return this._linkDownloader(fileName, URL.createObjectURL(data), linkClick)
                        }
                    }
                }
            },
            saveAs: function(fileName, format, data, proxyURL, linkClick) {
                fileName += "." + FILE_EXTESIONS[format];
                if (commonUtils.isFunction(window.Blob)) {
                    this._saveBlobAs(fileName, format, data)
                } else {
                    if (commonUtils.isDefined(proxyURL) && !commonUtils.isDefined(navigator.userAgent.match(/iPad/i))) {
                        this._saveByProxy(proxyURL, fileName, format, data)
                    } else {
                        if (!commonUtils.isDefined(navigator.userAgent.match(/iPad/i))) {
                            errors.log("E1034")
                        }
                        if (browser.msie && parseInt(browser.version) < 10) {
                            return
                        }
                        this._linkDownloader(fileName, this._getDataUri(format, data), linkClick)
                    }
                }
            }
        }
    },
    /*!*************************!*\
      !*** external "jQuery" ***!
      \*************************/
    function(module, exports) {
        module.exports = jQuery
    },
    /*!****************************************!*\
      !*** ./Scripts/ui/widget/ui.errors.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var errorUtils = __webpack_require__( /*! ../../core/utils/error */ 11),
            errors = __webpack_require__( /*! ../../core/errors */ 17);
        module.exports = errorUtils(errors.ERROR_MESSAGES, {
            E1001: "Module '{0}'. Controller '{1}' is already registered",
            E1002: "Module '{0}'. Controller '{1}' must be inheritor of DevExpress.ui.dxDataGrid.Controller",
            E1003: "Module '{0}'. View '{1}' is already registered",
            E1004: "Module '{0}'. View '{1}' must be inheritor of DevExpress.ui.dxDataGrid.View",
            E1005: "Public method '{0}' is already registered",
            E1006: "Public method '{0}.{1}' is not exists",
            E1007: "State storing can not be provided due to the restrictions of your browser",
            E1010: "A template should contain dxTextBox widget",
            E1011: "You have to implement 'remove' method in dataStore used by dxList to be able to delete items",
            E1012: "Editing type '{0}' with name '{1}' not supported",
            E1016: "Unexpected type of data source is provided for a lookup column",
            E1018: "The 'collapseAll' method cannot be called when using a remote data source",
            E1019: "Search mode '{0}' is unavailable",
            E1020: "Type can not be changed after initialization",
            E1021: "{0} '{1}' you are trying to remove does not exist",
            E1022: "Markers option should be an array",
            E1023: "Routes option should be an array",
            E1024: "Google provider cannot be used in WinJS application",
            E1025: "This layout is too complex to render",
            E1026: "The 'custom' value is set to a summary item's summaryType option, but a function for calculating the custom summary is not assigned to the grid's calculateCustomSummary option",
            E1030: "Unknown dxScrollView refresh strategy: '{0}'",
            E1031: "Unknown subscription is detected in the dxScheduler widget: '{0}'",
            E1032: "Unknown start date is detected in an appointment of the dxScheduler widget: '{0}'",
            E1033: "Unknown step is specified for the scheduler's navigator: '{0}'",
            E1034: "The current browser does not implement an API required for saving files",
            E1035: "The editor could not be created because of the internal error: {0}",
            E1036: "Validation rules are not defined for any form item",
            E1037: "Invalid structure of grouped data",
            E1038: "Your browser does not support local storage for local web pages",
            E0139: "The cell position can not be calculated",
            E1040: "The key value should be unique within the data array",
            W1001: "Key option can not be modified after initialization",
            W1002: "Item '{0}' you are trying to select does not exist",
            W1003: "Group with key '{0}' in which you are trying to select items does not exist",
            W1004: "Item '{0}' you are trying to select in group '{1}' does not exist",
            W1005: "Due to column data types being unspecified, data has been loaded twice in order to apply initial filter settings. To resolve this issue, specify data types for all grid columns."
        })
    },
    /*!*************************************!*\
      !*** ./Scripts/core/utils/error.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            consoleUtils = __webpack_require__( /*! ./console */ 12),
            stringUtils = __webpack_require__( /*! ./string */ 13),
            version = __webpack_require__( /*! ../version */ 16);
        var ERROR_URL = "http://js.devexpress.com/error/" + version.split(".").slice(0, 2).join("_") + "/";
        module.exports = function(baseErrors, errors) {
            var exports = {
                ERROR_MESSAGES: $.extend(errors, baseErrors),
                Error: function() {
                    return makeError($.makeArray(arguments))
                },
                log: function(id) {
                    var method = "log";
                    if (/^E\d+$/.test(id)) {
                        method = "error"
                    } else {
                        if (/^W\d+$/.test(id)) {
                            method = "warn"
                        }
                    }
                    consoleUtils.logger[method]("log" === method ? id : combineMessage($.makeArray(arguments)))
                }
            };
            var combineMessage = function(args) {
                var id = args[0];
                args = args.slice(1);
                return formatMessage(id, formatDetails(id, args))
            };
            var formatDetails = function(id, args) {
                args = [exports.ERROR_MESSAGES[id]].concat(args);
                return stringUtils.format.apply(this, args).replace(/\.*\s*?$/, "")
            };
            var formatMessage = function(id, details) {
                return stringUtils.format.apply(this, ["{0} - {1}. See:\n{2}", id, details, ERROR_URL + id])
            };
            var makeError = function(args) {
                var id, details, message;
                id = args[0];
                args = args.slice(1);
                details = formatDetails(id, args);
                message = formatMessage(id, details);
                return $.extend(new Error(message), {
                    __id: id,
                    __details: details
                })
            };
            return exports
        }
    },
    /*!***************************************!*\
      !*** ./Scripts/core/utils/console.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var logger = function() {
            var console = window.console;

            function info(text) {
                if (!console || !$.isFunction(console.info)) {
                    return
                }
                console.info(text)
            }

            function warn(text) {
                if (!console || !$.isFunction(console.warn)) {
                    return
                }
                console.warn(text)
            }

            function error(text) {
                if (!console || !$.isFunction(console.error)) {
                    return
                }
                console.error(text)
            }
            return {
                info: info,
                warn: warn,
                error: error
            }
        }();
        var debug = function() {
            function assert(condition, message) {
                if (!condition) {
                    throw new Error(message)
                }
            }

            function assertParam(parameter, message) {
                assert(null !== parameter && void 0 !== parameter, message)
            }
            return {
                assert: assert,
                assertParam: assertParam
            }
        }();
        exports.logger = logger;
        exports.debug = debug
    },
    /*!**************************************!*\
      !*** ./Scripts/core/utils/string.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ./common */ 14);
        var encodeHtml = function() {
            var encodeRegExp = [new RegExp("&", "g"), new RegExp('"', "g"), new RegExp("'", "g"), new RegExp("<", "g"), new RegExp(">", "g")];
            return function(str) {
                return String(str).replace(encodeRegExp[0], "&amp;").replace(encodeRegExp[1], "&quot;").replace(encodeRegExp[2], "&#39;").replace(encodeRegExp[3], "&lt;").replace(encodeRegExp[4], "&gt;")
            }
        }();
        var pairToObject = function(raw) {
            var pair = commonUtils.splitPair(raw),
                h = parseInt(pair && pair[0], 10),
                v = parseInt(pair && pair[1], 10);
            if (!isFinite(h)) {
                h = 0
            }
            if (!isFinite(v)) {
                v = h
            }
            return {
                h: h,
                v: v
            }
        };
        var quadToObject = function(raw) {
            var quad = commonUtils.splitQuad(raw),
                left = parseInt(quad && quad[0], 10),
                top = parseInt(quad && quad[1], 10),
                right = parseInt(quad && quad[2], 10),
                bottom = parseInt(quad && quad[3], 10);
            if (!isFinite(left)) {
                left = 0
            }
            if (!isFinite(top)) {
                top = left
            }
            if (!isFinite(right)) {
                right = left
            }
            if (!isFinite(bottom)) {
                bottom = top
            }
            return {
                top: top,
                right: right,
                bottom: bottom,
                left: left
            }
        };
        var stringFormat = function() {
            var replaceDollarCount, reg, value, s = arguments[0],
                values = $.makeArray(arguments).slice(1);
            if ($.isFunction(s)) {
                return s.apply(this, values)
            }
            for (var i = 0; i < values.length; i++) {
                reg = new RegExp("\\{" + i + "\\}", "gm");
                value = values[i];
                if ("string" === $.type(value) && value.indexOf("$") >= 0) {
                    replaceDollarCount = "$".replace("$", "$$").length;
                    value = value.replace("$", 1 === replaceDollarCount ? "$$$$" : "$$")
                }
                s = s.replace(reg, value)
            }
            return s
        };
        var replaceAll = function() {
            var preg_quote = function(str) {
                return (str + "").replace(/([\+\*\?\\\.\[\^\]\$\(\)\{\}\><\|\=\!\:])/g, "\\$1")
            };
            return function(text, searchToken, replacementToken) {
                return text.replace(new RegExp("(" + preg_quote(searchToken) + ")", "gi"), replacementToken)
            }
        }();
        var isEmpty = function(text) {
            var SPACE_REGEXP = /\s/g;
            return function(text) {
                return !text || !text.replace(SPACE_REGEXP, "")
            }
        }();
        exports.encodeHtml = encodeHtml;
        exports.pairToObject = pairToObject;
        exports.quadToObject = quadToObject;
        exports.format = stringFormat;
        exports.replaceAll = replaceAll;
        exports.isEmpty = isEmpty
    },
    /*!**************************************!*\
      !*** ./Scripts/core/utils/common.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            config = __webpack_require__( /*! ../config */ 15);
        var isDefined = function(object) {
            return null !== object && void 0 !== object
        };
        var isString = function(object) {
            return "string" === $.type(object)
        };
        var isNumber = function(object) {
            return "number" === typeof object && isFinite(object) || $.isNumeric(object)
        };
        var isObject = function(object) {
            return "object" === $.type(object)
        };
        var isArray = function(object) {
            return "array" === $.type(object)
        };
        var isDate = function(object) {
            return "date" === $.type(object)
        };
        var isBoolean = function(object) {
            return "boolean" === $.type(object)
        };
        var isFunction = function(object) {
            return "function" === $.type(object)
        };
        var isPrimitive = function(value) {
            return $.inArray($.type(value), ["object", "array", "function"]) === -1
        };
        var isExponential = function(value) {
            return isNumber(value) && value.toString().indexOf("e") !== -1
        };
        var ensureDefined = function(value, defaultValue) {
            return isDefined(value) ? value : defaultValue
        };
        var getDefaultAlignment = function(isRtlEnabled) {
            var rtlEnabled = isRtlEnabled || config().rtlEnabled;
            return rtlEnabled ? "right" : "left"
        };
        var executeAsync = function(action, context) {
            var timerId, deferred = $.Deferred(),
                normalizedContext = context || this,
                task = {
                    promise: deferred.promise(),
                    abort: function() {
                        clearTimeout(timerId);
                        deferred.rejectWith(normalizedContext)
                    }
                },
                callback = function() {
                    var result = action.call(normalizedContext);
                    if (result && result.done && $.isFunction(result.done)) {
                        result.done(function() {
                            deferred.resolveWith(normalizedContext)
                        })
                    } else {
                        deferred.resolveWith(normalizedContext)
                    }
                };
            timerId = (arguments[2] || setTimeout)(callback, "number" === typeof context ? context : 0);
            return task
        };
        var delayedFuncs = [];
        var delayedNames = [];
        var delayedDeferreds = [];
        var executingName;
        var deferExecute = function(name, func, deferred) {
            if (executingName && executingName !== name) {
                delayedFuncs.push(func);
                delayedNames.push(name);
                deferred = deferred || $.Deferred();
                delayedDeferreds.push(deferred);
                return deferred
            } else {
                var oldExecutingName = executingName,
                    currentDelayedCount = delayedDeferreds.length;
                executingName = name;
                var result = func();
                if (!result) {
                    if (delayedDeferreds.length > currentDelayedCount) {
                        result = $.when.apply($, delayedDeferreds.slice(currentDelayedCount))
                    } else {
                        if (deferred) {
                            deferred.resolve()
                        }
                    }
                }
                executingName = oldExecutingName;
                if (deferred && result && result.done) {
                    result.done(deferred.resolve).fail(deferred.reject)
                }
                if (!executingName && delayedFuncs.length) {
                    ("render" === delayedNames.shift() ? deferRender : deferUpdate)(delayedFuncs.shift(), delayedDeferreds.shift())
                }
                return result
            }
        };
        var deferRender = function(func, deferred) {
            return deferExecute("render", func, deferred)
        };
        var deferUpdate = function(func, deferred) {
            return deferExecute("update", func, deferred)
        };
        var deferRenderer = function(func) {
            return function() {
                var that = this;
                return deferExecute("render", function() {
                    return func.call(that)
                })
            }
        };
        var deferUpdater = function(func) {
            return function() {
                var that = this;
                return deferExecute("update", function() {
                    return func.call(that)
                })
            }
        };
        var findBestMatches = function(targetFilter, items, mapFn) {
            var bestMatches = [],
                maxMatchCount = 0;
            $.each(items, function(index, itemSrc) {
                var matchCount = 0,
                    item = mapFn ? mapFn(itemSrc) : itemSrc;
                $.each(targetFilter, function(paramName, targetValue) {
                    var value = item[paramName];
                    if (void 0 === value) {
                        return
                    }
                    if (match(value, targetValue)) {
                        matchCount++;
                        return
                    }
                    matchCount = -1;
                    return false
                });
                if (matchCount < maxMatchCount) {
                    return
                }
                if (matchCount > maxMatchCount) {
                    bestMatches.length = 0;
                    maxMatchCount = matchCount
                }
                bestMatches.push(itemSrc)
            });
            return bestMatches
        };
        var match = function(value, targetValue) {
            if ($.isArray(value) && $.isArray(targetValue)) {
                var mismatch = false;
                $.each(value, function(index, valueItem) {
                    if (valueItem !== targetValue[index]) {
                        mismatch = true;
                        return false
                    }
                });
                if (mismatch) {
                    return false
                }
                return true
            }
            if (value === targetValue) {
                return true
            }
            return false
        };
        var splitPair = function(raw) {
            switch (typeof raw) {
                case "string":
                    return raw.split(/\s+/, 2);
                case "object":
                    return [raw.x || raw.h, raw.y || raw.v];
                case "number":
                    return [raw];
                default:
                    return raw
            }
        };
        var splitQuad = function(raw) {
            switch (typeof raw) {
                case "string":
                    return raw.split(/\s+/, 4);
                case "object":
                    return [raw.x || raw.h || raw.left, raw.y || raw.v || raw.top, raw.x || raw.h || raw.right, raw.y || raw.v || raw.bottom];
                case "number":
                    return [raw];
                default:
                    return raw
            }
        };
        var normalizeKey = function(id) {
            var key = isString(id) ? id : id.toString(),
                arr = key.match(/[^a-zA-Z0-9]/g);
            arr && $.each(arr, function(_, sign) {
                key = key.replace(sign, "_" + sign.charCodeAt() + "_")
            });
            return key
        };
        exports.isDefined = isDefined;
        exports.isString = isString;
        exports.isNumber = isNumber;
        exports.isObject = isObject;
        exports.isArray = isArray;
        exports.isDate = isDate;
        exports.isBoolean = isBoolean;
        exports.isFunction = isFunction;
        exports.isPrimitive = isPrimitive;
        exports.isExponential = isExponential;
        exports.ensureDefined = ensureDefined;
        exports.executeAsync = executeAsync;
        exports.deferRender = deferRender;
        exports.deferRenderer = deferRenderer;
        exports.deferUpdate = deferUpdate;
        exports.deferUpdater = deferUpdater;
        exports.splitPair = splitPair;
        exports.splitQuad = splitQuad;
        exports.findBestMatches = findBestMatches;
        exports.getDefaultAlignment = getDefaultAlignment;
        exports.normalizeKey = normalizeKey
    },
    /*!********************************!*\
      !*** ./Scripts/core/config.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            config = {
                rtlEnabled: false,
                defaultCurrency: "USD",
                designMode: false
            };
        module.exports = function() {
            if (!arguments.length) {
                return config
            }
            $.extend(config, arguments[0])
        }
    },
    /*!*********************************!*\
      !*** ./Scripts/core/version.js ***!
      \*********************************/
    function(module, exports) {
        module.exports = "16.1.6"
    },
    /*!********************************!*\
      !*** ./Scripts/core/errors.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var errorUtils = __webpack_require__( /*! ./utils/error */ 11);
        module.exports = errorUtils({
            E0001: "Method is not implemented",
            E0002: "Member name collision: {0}",
            E0003: "A class must be instantiated using the 'new' keyword",
            E0004: "The NAME property of the component is not specified",
            E0005: "Unknown device",
            E0006: "Unknown endpoint key is requested",
            E0007: "'Invalidate' method is called outside the update transaction",
            E0008: "Type of the option name is not appropriate to create an action",
            E0009: "Component '{0}' has not been initialized for an element",
            E0010: "Animation configuration with the '{0}' type requires '{1}' configuration as {2}",
            E0011: "Unknown animation type '{0}'",
            E0012: "jQuery version is too old. Please upgrade jQuery to 1.10.0 or later",
            E0013: "KnockoutJS version is too old. Please upgrade KnockoutJS to 2.3.0 or later",
            E0014: "The 'release' method shouldn't be called for an unlocked Lock object",
            E0015: "Queued task returned an unexpected result",
            E0017: "Event namespace is not defined",
            E0018: "DevExpress.ui.DevExpressPopup widget is required",
            E0020: "Template engine '{0}' is not supported",
            E0021: "Unknown theme is set: {0}",
            E0022: "LINK[rel=DevExpress-theme] tags must go before DevExpress included scripts",
            E0023: "Template name is not specified",
            E0100: "Unknown validation type is detected",
            E0101: "Misconfigured range validation rule is detected",
            E0102: "Misconfigured comparison validation rule is detected",
            E0110: "Unknown validation group is detected",
            E0120: "Adapter for a DevExpressValidator component cannot be configured",
            E0121: "The onCustomItemCreating action should return an item or Promise of jQuery Deferred object resolved when an item is created",
            E4016: "The compileSetter(expr) method is called with 'self' passed as a parameter",
            W0000: "'{0}' is deprecated in {1}. {2}",
            W0001: "{0} - '{1}' option is deprecated in {2}. {3}",
            W0002: "{0} - '{1}' method is deprecated in {2}. {3}",
            W0003: "{0} - '{1}' property is deprecated in {2}. {3}",
            W0004: "Timeout for theme loading is over: {0}",
            W0005: "'{0}' event is deprecated in {1}. {2}",
            W0006: "Invalid recurrence rule: '{0}'",
            W0008: "Invalid view name: '{0}'",
            W0009: "Invalid time zone name: '{0}'",
            W0010: "{0} is deprecated in {1}. {2}",
            W0011: "Number parsing is invoked while the parser is not defined",
            W0012: "Date parsing is invoked while the parser is not defined"
        })
    },
    /*!***************************************!*\
      !*** ./Scripts/core/utils/browser.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var webkitRegExp = /(webkit)[ \/]([\w.]+)/,
            ieRegExp = /(msie) (\d{1,2}\.\d)/,
            ie11RegExp = /(trident).*rv:(\d{1,2}\.\d)/,
            msEdge = /(edge)\/((\d+)?[\w\.]+)/,
            mozillaRegExp = /(mozilla)(?:.*? rv:([\w.]+))/;
        var browserFromUA = function(ua) {
            ua = ua.toLowerCase();
            var result = {},
                matches = ieRegExp.exec(ua) || ie11RegExp.exec(ua) || msEdge.exec(ua) || ua.indexOf("compatible") < 0 && mozillaRegExp.exec(ua) || webkitRegExp.exec(ua) || [],
                browserName = matches[1],
                browserVersion = matches[2];
            if ("trident" === browserName || "edge" === browserName) {
                browserName = "msie"
            }
            if (browserName) {
                result[browserName] = true;
                result.version = browserVersion
            }
            return result
        };
        module.exports = $.extend({
            _fromUA: browserFromUA
        }, browserFromUA(navigator.userAgent))
    },
    /*!**************************************************!*\
      !*** ./Scripts/client_exporter/excel_creator.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            stringUtils = __webpack_require__( /*! ../core/utils/string */ 13),
            JSZip = __webpack_require__( /*! jszip */ 21),
            numberFormatter = __webpack_require__( /*! ../localization/number */ 22),
            fileSaver = __webpack_require__( /*! ./file_saver */ 8),
            XML_TAG = '<?xml version="1.0" encoding="utf-8"?>',
            GROUP_SHEET_PR_XML = '<sheetPr><outlinePr summaryBelow="0"/></sheetPr>',
            SINGLE_SHEET_PR_XML = "<sheetPr/>",
            BASE_STYLE_XML = '<fonts count="2"><font><sz val="11"/><color theme="1"/><name val="Calibri"/><family val="2"/><scheme val="minor"/></font><font><b/><sz val="11"/><color theme="1"/><name val="Calibri"/><family val="2"/><scheme val="minor"/></font></fonts><fills count="1"><fill><patternFill patternType="none"/></fill></fills><borders count="1"><border><left style="thin"><color rgb="FFD3D3D3"/></left><right style="thin"><color rgb="FFD3D3D3"/></right><top style="thin"><color rgb="FFD3D3D3"/></top><bottom style="thin"><color rgb="FFD3D3D3"/></bottom></border></borders><cellStyleXfs count="1"><xf numFmtId="0" fontId="0" fillId="0" borderId="0"/></cellStyleXfs>',
            OPEN_XML_FORMAT_URL = "http://schemas.openxmlformats.org",
            RELATIONSHIP_PART_NAME = "rels",
            XL_FOLDER_NAME = "xl",
            WORKBOOK_FILE_NAME = "workbook.xml",
            CONTENTTYPES_FILE_NAME = "[Content_Types].xml",
            SHAREDSTRING_FILE_NAME = "sharedStrings.xml",
            STYLE_FILE_NAME = "styles.xml",
            WORKSHEETS_FOLDER = "worksheets",
            WORKSHEET_FILE_NAME = "sheet1.xml",
            DEFINED_DATE_FORMATS = {
                longDate: "d MMMM yyyy",
                longTime: "H:mm:ss",
                monthAndDay: "MMMM dd",
                monthAndYear: "MMMM yyyy",
                quarterAndYear: "MM\\/dd\\/yyyy",
                shortDate: "MM\\/dd\\/yyyy",
                shortTime: "H:mm",
                millisecond: "H:mm:ss",
                day: "dd",
                month: "MMMM",
                quarter: "MM\\/dd\\/yyyy",
                year: "yyyy"
            },
            DEFAULT_DATE_FORMAT = "shortTime",
            DEFINED_NUMBER_FORMTATS = {
                thousands: "#,##0{0},&quot;K&quot;",
                millions: "#,##0{0},,&quot;M&quot;",
                billions: "#,##0{0},,,&quot;B&quot;",
                trillions: "#,##0{0},,,,&quot;T&quot;",
                percent: "0{0}%",
                decimal: "#{0}",
                fixedPoint: "#,##0{0}",
                exponential: "0{0}E+00",
                currency: " "
            },
            VALID_TYPES = {
                "boolean": "b",
                date: "d",
                number: "n",
                string: "s"
            },
            EXCEL_START_TIME = Date.UTC(1899, 11, 30),
            DAYS_COUNT_BEFORE_29_FEB_1900 = 60,
            BOLD_STYLES_COUNT = 4,
            MAX_DIGIT_WIDTH_IN_PIXELS = 7,
            CUSTOM_FORMAT_START_INDEX = 165;
        __webpack_require__( /*! ../localization/currency */ 24);
        exports.excelFormatConverter = {
            _applyPrecision: function(format, precision) {
                var result, i;
                if (precision > 0) {
                    result = "decimal" !== format ? "." : "";
                    for (i = 0; i < precision; i++) {
                        result += "0"
                    }
                    return result
                }
                return ""
            },
            _getCurrencyFormat: function(currency) {
                return numberFormatter.getOpenXmlCurrencyFormat(currency)
            },
            _convertDateFormat: function(format) {
                return DEFINED_DATE_FORMATS[format] || DEFINED_DATE_FORMATS[DEFAULT_DATE_FORMAT]
            },
            _convertNumberFormat: function(format, precision) {
                var result, excelFormat = "currency" === format ? this._getCurrencyFormat() : DEFINED_NUMBER_FORMTATS[format];
                if (excelFormat) {
                    result = stringUtils.format(excelFormat, this._applyPrecision(format, precision))
                }
                return result
            },
            convertFormat: function(format, precision, type) {
                if (commonUtils.isDefined(format)) {
                    if ("date" === type) {
                        return exports.excelFormatConverter._convertDateFormat(format)
                    } else {
                        if (DEFINED_NUMBER_FORMTATS[format]) {
                            return exports.excelFormatConverter._convertNumberFormat(format, precision)
                        }
                    }
                }
            }
        };
        exports.ExcelCreator = Class.inherit({
            _getXMLTag: function(tagName, attributes, content) {
                var i, attr, result = "<" + tagName,
                    length = attributes.length;
                for (i = 0; i < length; i++) {
                    attr = attributes[i];
                    result = result + " " + attr.name + '="' + attr.value + '"'
                }
                return commonUtils.isDefined(content) ? result + ">" + content + "</" + tagName + ">" : result + " />"
            },
            _getDataProviderRowIndex: function(dpRowIndex) {
                var correctRowIndex = this._dataProvider.getHeaderRowCount ? this._dataProvider.getHeaderRowCount() : 0;
                return dpRowIndex - correctRowIndex
            },
            _getExcelRowIndex: function(exRowIndex) {
                var correctRowIndex = this._dataProvider.getHeaderRowCount ? this._dataProvider.getHeaderRowCount() : 0;
                return exRowIndex + correctRowIndex
            },
            _getCellIndex: function(rowIndex, cellIndex) {
                var charCode, sheetIndex = "",
                    max = 26;
                if (this._maxIndex[0] < Number(rowIndex)) {
                    this._maxIndex[0] = Number(rowIndex)
                }
                if (this._maxIndex[1] < Number(cellIndex)) {
                    this._maxIndex[1] = Number(cellIndex)
                }
                while (true) {
                    charCode = 65 + (cellIndex >= max ? cellIndex % max : Math.ceil(cellIndex));
                    sheetIndex = String.fromCharCode(charCode) + sheetIndex;
                    if (cellIndex >= max) {
                        cellIndex = Math.floor(cellIndex / max) - 1
                    } else {
                        break
                    }
                }
                return sheetIndex + rowIndex
            },
            _getDataType: function(dataType) {
                return VALID_TYPES[dataType] || "s"
            },
            _appendFormat: function(format, precision, dataType) {
                format = exports.excelFormatConverter.convertFormat(format, precision, dataType);
                if (format) {
                    if ($.inArray(format, this._styleFormat) === -1) {
                        this._styleFormat.push(format)
                    }
                    return $.inArray(format, this._styleFormat) + 1
                }
            },
            _appendString: function(value) {
                if (commonUtils.isDefined(value)) {
                    value = String(value);
                    if (value.length) {
                        value = stringUtils.encodeHtml(value);
                        if (void 0 === this._stringHash[value]) {
                            this._stringHash[value] = this._stringArray.length;
                            this._stringArray.push(value)
                        }
                        return this._stringHash[value]
                    }
                }
            },
            _getExcelDateValue: function(date) {
                var days, totalTime;
                if (commonUtils.isDate(date)) {
                    days = Math.floor((Date.UTC(date.getFullYear(), date.getMonth(), date.getDate()) - EXCEL_START_TIME) / 864e5);
                    if (days < DAYS_COUNT_BEFORE_29_FEB_1900) {
                        days--
                    }
                    totalTime = (3600 * date.getHours() + 60 * date.getMinutes() + date.getSeconds()) / 86400;
                    return days + totalTime
                }
            },
            _prepareValue: function(rowIndex, cellIndex) {
                var dataProvider = this._dataProvider,
                    value = dataProvider.getCellValue(rowIndex, cellIndex),
                    type = this._getDataType(dataProvider.getCellType(rowIndex, cellIndex)),
                    formatID = this._styleArray[cellIndex + BOLD_STYLES_COUNT].formatID,
                    format = commonUtils.isNumber(formatID) ? this._styleFormat[formatID - 1] : null;
                if ("d" === type && !commonUtils.isDate(value)) {
                    type = "s"
                }
                switch (type) {
                    case "s":
                        value = this._appendString(value);
                        break;
                    case "d":
                        value = this._getExcelDateValue(value, format);
                        type = "n"
                }
                return {
                    value: value,
                    type: type
                }
            },
            _getHeadersArray: function() {
                var i, j, column, columns = this._dataProvider.getColumns(true),
                    result = [];
                for (i = 0; i < columns.length - 1; i++) {
                    result.push([]);
                    for (j = 0; j < columns[i].length; j++) {
                        column = columns[i][j];
                        result[i].push({
                            style: 0,
                            type: "s",
                            value: this._appendString(column.caption)
                        })
                    }
                }
                return result
            },
            _getDataArray: function() {
                var rowIndex, cellIndex, cellsArray, cellData, cellsLength, type, styleID, result = [],
                    rowsLength = this._dataProvider.getRowsCount(),
                    columns = this._dataProvider.getColumns();
                for (rowIndex = 0; rowIndex < rowsLength; rowIndex++) {
                    cellsArray = [];
                    cellsLength = columns.length;
                    for (cellIndex = 0; cellIndex !== cellsLength; cellIndex++) {
                        cellData = this._prepareValue(rowIndex, cellIndex);
                        type = cellData.type;
                        if (!this._dataProvider.isGroupRow(rowIndex) && commonUtils.isDefined(this._styleArray[cellIndex + BOLD_STYLES_COUNT].formatID) && "s" !== cellData.type) {
                            type = "n"
                        }
                        styleID = cellIndex + BOLD_STYLES_COUNT;
                        if (this._dataProvider.isGroupRow(rowIndex)) {
                            styleID = BOLD_STYLES_COUNT - 1
                        }
                        if (this._dataProvider.isTotalCell(rowIndex, cellIndex)) {
                            styleID = this._getBoldStyleID(columns[cellIndex].alignment)
                        }
                        cellsArray.push({
                            style: styleID,
                            value: cellData.value,
                            type: type
                        })
                    }
                    if (rowIndex && !this._needSheetPr && this._dataProvider.getGroupLevel(this._getDataProviderRowIndex(rowIndex)) > 0) {
                        this._needSheetPr = true
                    }
                    result.push(cellsArray)
                }
                return result
            },
            _getBoldStyleID: function(alignment) {
                for (var i = 0; i < BOLD_STYLES_COUNT - 1; i++) {
                    if (this._styleArray[i].alignment === alignment) {
                        return i
                    }
                }
            },
            _calculateWidth: function(pixelsWidth) {
                pixelsWidth = parseInt(pixelsWidth, 10);
                if (!pixelsWidth || pixelsWidth < 5) {
                    pixelsWidth = 100
                }
                return Math.min(255, Math.floor((pixelsWidth - 5) / MAX_DIGIT_WIDTH_IN_PIXELS * 100 + .5) / 100)
            },
            _prepareStyleData: function() {
                var i, column, wrapText = Number(!!this._options.wrapTextEnabled),
                    alignments = ["center", "left", "right"],
                    columns = this._dataProvider.getColumns();
                for (i = 0; i < alignments.length; i++) {
                    this._styleArray.push({
                        bold: true,
                        alignment: alignments[i],
                        wrapText: 1
                    })
                }
                this._styleArray.push({
                    bold: true,
                    alignment: commonUtils.getDefaultAlignment(this._rtlEnabled),
                    wrapText: 0
                });
                for (i = 0; i < columns.length; i++) {
                    column = columns[i];
                    this._styleArray.push({
                        alignment: commonUtils.isDefined(column.alignment) ? column.alignment : "left",
                        formatID: this._appendFormat(column.format, column.precision, column.dataType),
                        wrapText: wrapText
                    });
                    this._colsArray.push(this._calculateWidth(column.width))
                }
            },
            _prepareCellData: function() {
                if (this._dataProvider.isHeadersVisible()) {
                    this._cellsArray = this._cellsArray.concat(this._getHeadersArray())
                }
                this._cellsArray = this._cellsArray.concat(this._getDataArray())
            },
            _createXMLRelationships: function(xmlRelationships) {
                return this._getXMLTag("Relationships", [{
                    name: "xmlns",
                    value: OPEN_XML_FORMAT_URL + "/package/2006/relationships"
                }], xmlRelationships)
            },
            _createXMLRelationship: function(id, type, target) {
                return this._getXMLTag("Relationship", [{
                    name: "Id",
                    value: "rId" + id
                }, {
                    name: "Type",
                    value: OPEN_XML_FORMAT_URL + "/officeDocument/2006/relationships/" + type
                }, {
                    name: "Target",
                    value: target
                }])
            },
            _getWorkbookContent: function() {
                var content = '<bookViews><workbookView xWindow="0" yWindow="0" windowWidth="0" windowHeight="0"/></bookViews><sheets><sheet name="Sheet" sheetId="1" r:id="rId1" /></sheets><definedNames><definedName name="_xlnm.Print_Titles" localSheetId="0">Sheet!$1:$1</definedName><definedName name="_xlnm._FilterDatabase" hidden="0" localSheetId="0">Sheet!$A$1:$F$6332</definedName></definedNames>';
                return XML_TAG + this._getXMLTag("workbook", [{
                    name: "xmlns:r",
                    value: OPEN_XML_FORMAT_URL + "/officeDocument/2006/relationships"
                }, {
                    name: "xmlns",
                    value: OPEN_XML_FORMAT_URL + "/spreadsheetml/2006/main"
                }], content)
            },
            _getContentTypesContent: function() {
                return XML_TAG + '<Types xmlns="' + OPEN_XML_FORMAT_URL + '/package/2006/content-types"><Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml" /><Default Extension="xml" ContentType="application/xml" /><Override PartName="/xl/worksheets/sheet1.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml" /><Override PartName="/xl/styles.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml" /><Override PartName="/xl/sharedStrings.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml" /><Override PartName="/xl/workbook.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml" /></Types>'
            },
            _generateStylesXML: function() {
                var styleIndex, style, formatIndex, xlFolder = this._zip.folder(XL_FOLDER_NAME),
                    stylesLength = this._styleArray.length,
                    xmlStyles = [],
                    XML = "";
                for (formatIndex = 0; formatIndex < this._styleFormat.length; formatIndex++) {
                    this._styleFormat[formatIndex] = this._getXMLTag("numFmt", [{
                        name: "numFmtId",
                        value: Number(formatIndex) + CUSTOM_FORMAT_START_INDEX
                    }, {
                        name: "formatCode",
                        value: this._styleFormat[formatIndex]
                    }])
                }
                XML = XML + this._getXMLTag("numFmts", [{
                    name: "count",
                    value: this._styleFormat.length
                }], this._styleFormat.join("")) + BASE_STYLE_XML;
                for (styleIndex = 0; styleIndex < stylesLength; styleIndex++) {
                    style = this._styleArray[styleIndex];
                    xmlStyles.push(this._getXMLTag("xf", [{
                        name: "xfId",
                        value: 0
                    }, {
                        name: "applyAlignment",
                        value: 1
                    }, {
                        name: "fontId",
                        value: Number(!!style.bold)
                    }, {
                        name: "applyNumberFormat",
                        value: commonUtils.isDefined(style.formatID) ? 1 : 0
                    }, {
                        name: "numFmtId",
                        value: commonUtils.isDefined(style.formatID) ? Number(style.formatID) + CUSTOM_FORMAT_START_INDEX - 1 : 0
                    }], this._getXMLTag("alignment", [{
                        name: "horizontal",
                        value: style.alignment
                    }, {
                        name: "vertical",
                        value: "top"
                    }, {
                        name: "wrapText",
                        value: style.wrapText
                    }])))
                }
                XML += this._getXMLTag("cellXfs", [{
                    name: "count",
                    value: xmlStyles.length
                }], xmlStyles.join(""));
                XML += this._getXMLTag("cellStyles", [{
                    name: "count",
                    value: 1
                }], this._getXMLTag("cellStyle", [{
                    name: "name",
                    value: "Normal"
                }, {
                    name: "xfId",
                    value: 0
                }, {
                    name: "builtinId",
                    value: 0
                }]));
                XML = XML_TAG + this._getXMLTag("styleSheet", [{
                    name: "xmlns",
                    value: OPEN_XML_FORMAT_URL + "/spreadsheetml/2006/main"
                }], XML);
                xlFolder.file(STYLE_FILE_NAME, XML);
                this._styleArray = []
            },
            _generateStringsXML: function() {
                var stringIndex, xlFolder = this._zip.folder(XL_FOLDER_NAME),
                    stringsLength = this._stringArray.length,
                    sharedStringXml = XML_TAG;
                for (stringIndex = 0; stringIndex < stringsLength; stringIndex++) {
                    this._stringArray[stringIndex] = this._getXMLTag("si", [], this._getXMLTag("t", [], this._stringArray[stringIndex]))
                }
                sharedStringXml += this._getXMLTag("sst", [{
                    name: "xmlns",
                    value: OPEN_XML_FORMAT_URL + "/spreadsheetml/2006/main"
                }, {
                    name: "count",
                    value: this._stringArray.length
                }, {
                    name: "uniqueCount",
                    value: this._stringArray.length
                }], this._stringArray.join(""));
                xlFolder.file(SHAREDSTRING_FILE_NAME, sharedStringXml);
                this._stringArray = []
            },
            _getPaneXML: function() {
                var attributes = [{
                        name: "activePane",
                        value: "bottomLeft"
                    }, {
                        name: "state",
                        value: "frozen"
                    }],
                    frozenArea = this._dataProvider.getFrozenArea();
                if (!(frozenArea.x || frozenArea.y)) {
                    return ""
                }
                if (frozenArea.x) {
                    attributes.push({
                        name: "xSplit",
                        value: frozenArea.x
                    })
                }
                if (frozenArea.y) {
                    attributes.push({
                        name: "ySplit",
                        value: frozenArea.y
                    })
                }
                attributes.push({
                    name: "topLeftCell",
                    value: this._getCellIndex(frozenArea.y + 1, frozenArea.x)
                });
                return this._getXMLTag("pane", attributes)
            },
            _generateWorksheetXML: function() {
                var colIndex, rowIndex, cellData, xmlCells, maxCellIndex, cellsLength, counter = 0,
                    xmlRows = [],
                    rowsLength = this._cellsArray.length,
                    colsLength = this._colsArray.length,
                    rSpans = "1:" + colsLength,
                    headerRowCount = this._dataProvider.getHeaderRowCount ? this._dataProvider.getHeaderRowCount() : 1,
                    xmlResult = [
                        ['<?xml version="1.0" encoding="UTF-8" standalone="yes"?><worksheet xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="x14ac" xmlns:x14ac="http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac">', this._needSheetPr ? GROUP_SHEET_PR_XML : SINGLE_SHEET_PR_XML, '<dimension ref="A1:', this._getCellIndex(this._maxIndex[0], this._maxIndex[1]) + '"/><sheetViews><sheetView ' + (this._rtlEnabled ? 'rightToLeft="1" ' : "") + 'tabSelected="1" workbookViewId="0">' + this._getPaneXML() + '</sheetView></sheetViews><sheetFormatPr defaultRowHeight="15" outlineLevelRow="', this._dataProvider.getRowsCount() > 0 ? this._dataProvider.getGroupLevel(0) : 0, '" x14ac:dyDescent="0.25"/>'].join("")
                    ];
                for (colIndex = 0; colIndex < colsLength; colIndex++) {
                    this._colsArray[colIndex] = this._getXMLTag("col", [{
                        name: "width",
                        value: this._colsArray[colIndex]
                    }, {
                        name: "min",
                        value: Number(colIndex) + 1
                    }, {
                        name: "max",
                        value: Number(colIndex) + 1
                    }])
                }
                xmlResult.push(this._getXMLTag("cols", [], this._colsArray.join("")) + "<sheetData>");
                for (rowIndex = 0; rowIndex < rowsLength; rowIndex++) {
                    xmlCells = [];
                    cellsLength = this._cellsArray[rowIndex].length;
                    for (colIndex = 0; colIndex < cellsLength; colIndex++) {
                        rowIndex = Number(rowIndex);
                        cellData = this._cellsArray[rowIndex][colIndex];
                        xmlCells.push(this._getXMLTag("c", [{
                            name: "r",
                            value: this._getCellIndex(rowIndex + 1, colIndex)
                        }, {
                            name: "s",
                            value: cellData.style
                        }, {
                            name: "t",
                            value: cellData.type
                        }], commonUtils.isDefined(cellData.value) ? this._getXMLTag("v", [], cellData.value) : null))
                    }
                    xmlRows.push(this._getXMLTag("row", [{
                        name: "r",
                        value: Number(rowIndex) + 1
                    }, {
                        name: "spans",
                        value: rSpans
                    }, {
                        name: "outlineLevel",
                        value: rowIndex >= headerRowCount ? this._dataProvider.getGroupLevel(this._getDataProviderRowIndex(rowIndex)) : 0
                    }, {
                        name: "x14ac:dyDescent",
                        value: "0.25"
                    }], xmlCells.join("")));
                    this._cellsArray[rowIndex] = null;
                    if (counter++ > 1e4) {
                        xmlResult.push(xmlRows.join(""));
                        xmlRows = [];
                        counter = 0
                    }
                }
                xmlResult.push(xmlRows.join(""));
                xmlRows = [];
                maxCellIndex = this._getCellIndex(this._maxIndex[0], this._maxIndex[1]);
                xmlResult.push("</sheetData>" + (this._options.autoFilterEnabled ? '<autoFilter ref="A' + this._dataProvider.getHeaderRowCount() + ":" + maxCellIndex + '" />' : "") + this._generateMergingXML() + '<ignoredErrors><ignoredError sqref="A1:' + maxCellIndex + '" numberStoredAsText="1" /></ignoredErrors></worksheet>');
                this._zip.folder(XL_FOLDER_NAME).folder(WORKSHEETS_FOLDER).file(WORKSHEET_FILE_NAME, xmlResult.join(""));
                this._colsArray = [];
                this._cellsArray = [];
                xmlResult = []
            },
            _generateMergingXML: function() {
                var k, l, cellIndex, rowIndex, mergeArrayLength, mergeIndex, rowsLength = commonUtils.isDefined(this._dataProvider.getHeaderRowCount) ? this._dataProvider.getHeaderRowCount() : this._dataProvider.getRowsCount(),
                    columnsLength = this._dataProvider.getColumns().length,
                    usedArea = [],
                    mergeArray = [],
                    mergeXML = "";
                for (rowIndex = 0; rowIndex < rowsLength; rowIndex++) {
                    for (cellIndex = 0; cellIndex !== columnsLength; cellIndex++) {
                        if (!commonUtils.isDefined(usedArea[rowIndex]) || !commonUtils.isDefined(usedArea[rowIndex][cellIndex])) {
                            var cellMerge = this._dataProvider.getCellMerging(rowIndex, cellIndex);
                            if (cellMerge.colspan || cellMerge.rowspan) {
                                mergeArray.push({
                                    start: this._getCellIndex(rowIndex + 1, cellIndex),
                                    end: this._getCellIndex(rowIndex + 1 + (cellMerge.rowspan || 0), cellIndex + (cellMerge.colspan || 0))
                                });
                                for (k = rowIndex; k <= rowIndex + cellMerge.rowspan || 0; k++) {
                                    for (l = cellIndex; l <= cellIndex + cellMerge.colspan || 0; l++) {
                                        if (!commonUtils.isDefined(usedArea[k])) {
                                            usedArea[k] = []
                                        }
                                        usedArea[k][l] = true
                                    }
                                }
                            }
                        }
                    }
                }
                mergeArrayLength = mergeArray.length;
                for (mergeIndex = 0; mergeIndex < mergeArrayLength; mergeIndex++) {
                    mergeXML += this._getXMLTag("mergeCell", [{
                        name: "ref",
                        value: mergeArray[mergeIndex].start + ":" + mergeArray[mergeIndex].end
                    }])
                }
                return mergeXML.length ? this._getXMLTag("mergeCells", [{
                    name: "count",
                    value: mergeArrayLength
                }], mergeXML) : ""
            },
            _generateCommonXML: function() {
                var xmlRelationships, relsFileContent = XML_TAG + this._createXMLRelationships(this._createXMLRelationship(1, "officeDocument", "xl/" + WORKBOOK_FILE_NAME)),
                    xlFolder = this._zip.folder(XL_FOLDER_NAME),
                    relsXML = XML_TAG;
                this._zip.folder("_" + RELATIONSHIP_PART_NAME).file("." + RELATIONSHIP_PART_NAME, relsFileContent);
                xmlRelationships = this._createXMLRelationship(1, "worksheet", "worksheets/" + WORKSHEET_FILE_NAME) + this._createXMLRelationship(2, "styles", STYLE_FILE_NAME) + this._createXMLRelationship(3, "sharedStrings", SHAREDSTRING_FILE_NAME);
                relsXML += this._createXMLRelationships(xmlRelationships);
                xlFolder.folder("_" + RELATIONSHIP_PART_NAME).file(WORKBOOK_FILE_NAME + ".rels", relsXML);
                xlFolder.file(WORKBOOK_FILE_NAME, this._getWorkbookContent());
                this._zip.file(CONTENTTYPES_FILE_NAME, this._getContentTypesContent())
            },
            _generateContent: function() {
                this._prepareStyleData();
                this._prepareCellData();
                this._generateWorkXML();
                this._generateCommonXML()
            },
            _generateWorkXML: function() {
                this._generateStylesXML();
                this._generateStringsXML();
                this._generateWorksheetXML()
            },
            ctor: function(dataProvider, options) {
                this._rtlEnabled = options && !!options.rtlEnabled;
                this._options = options;
                this._maxIndex = [1, 2];
                this._stringArray = [];
                this._stringHash = {};
                this._styleArray = [];
                this._colsArray = [];
                this._cellsArray = [];
                this._styleFormat = [];
                this._needSheetPr = false;
                this._dataProvider = dataProvider;
                this._zip = new JSZip
            },
            ready: function() {
                return this._dataProvider.ready()
            },
            getData: function(isBlob) {
                var options = {
                    type: isBlob ? "blob" : "base64",
                    compression: "DEFLATE",
                    mimeType: fileSaver.MIME_TYPES.EXCEL
                };
                this._generateContent();
                return this._zip.generateAsync ? this._zip.generateAsync(options) : this._zip.generate(options)
            }
        });
        exports.getData = function(data, options, callback) {
            var excelCreator = new exports.ExcelCreator(data, options);
            excelCreator.ready().done(function() {
                if (excelCreator._zip.generateAsync) {
                    excelCreator.getData(commonUtils.isFunction(window.Blob)).then(callback)
                } else {
                    callback(excelCreator.getData(commonUtils.isFunction(window.Blob)))
                }
            })
        };
        exports.__internals = {
            CONTENTTYPES_FILE_NAME: CONTENTTYPES_FILE_NAME,
            RELATIONSHIP_PART_NAME: RELATIONSHIP_PART_NAME,
            XL_FOLDER_NAME: XL_FOLDER_NAME,
            WORKBOOK_FILE_NAME: WORKBOOK_FILE_NAME,
            STYLE_FILE_NAME: STYLE_FILE_NAME,
            WORKSHEET_FILE_NAME: WORKSHEET_FILE_NAME,
            WORKSHEETS_FOLDER: WORKSHEETS_FOLDER,
            SHAREDSTRING_FILE_NAME: SHAREDSTRING_FILE_NAME,
            GROUP_SHEET_PR_XML: GROUP_SHEET_PR_XML,
            SINGLE_SHEET_PR_XML: SINGLE_SHEET_PR_XML
        }
    },
    /*!*******************************!*\
      !*** ./Scripts/core/class.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var errors = __webpack_require__( /*! ./errors */ 17);
        var wrapOverridden = function(baseProto, methodName, method) {
            return function() {
                var prevCallBase = this.callBase;
                this.callBase = baseProto[methodName];
                try {
                    return method.apply(this, arguments)
                } finally {
                    this.callBase = prevCallBase
                }
            }
        };
        var clonePrototype = function(obj) {
            var func = function() {};
            func.prototype = obj.prototype;
            return new func
        };
        var redefine = function(members) {
            var overridden, memberName, member, that = this;
            if (!members) {
                return that
            }
            for (memberName in members) {
                member = members[memberName];
                overridden = "function" === typeof that.prototype[memberName] && "function" === typeof member;
                that.prototype[memberName] = overridden ? wrapOverridden(that.parent.prototype, memberName, member) : member
            }
            return that
        };
        var include = function() {
            var argument, name, i, classObj = this;
            for (i = 0; i < arguments.length; i++) {
                argument = arguments[i];
                if (argument.ctor) {
                    classObj._includedCtors.push(argument.ctor)
                }
                if (argument.postCtor) {
                    classObj._includedPostCtors.push(argument.postCtor)
                }
                for (name in argument) {
                    if ("ctor" === name || "postCtor" === name) {
                        continue
                    }
                    if (name in classObj.prototype) {
                        throw errors.Error("E0002", name)
                    }
                    classObj.prototype[name] = argument[name]
                }
            }
            return classObj
        };
        var subclassOf = function(parentClass) {
            if (this.parent === parentClass) {
                return true
            }
            if (!this.parent || !this.parent.subclassOf) {
                return false
            }
            return this.parent.subclassOf(parentClass)
        };
        var abstract = function() {
            throw errors.Error("E0001")
        };
        var copyStatic = function() {
            var hasOwn = Object.prototype.hasOwnProperty;
            return function(source, destination) {
                for (var key in source) {
                    if (!hasOwn.call(source, key)) {
                        return
                    }
                    destination[key] = source[key]
                }
            }
        }();
        var classImpl = function() {};
        classImpl.inherit = function(members) {
            var inheritor = function() {
                if (!this || this === window || "function" !== typeof this.constructor) {
                    throw errors.Error("E0003")
                }
                var i, instance = this,
                    ctor = instance.ctor,
                    includedCtors = instance.constructor._includedCtors,
                    includedPostCtors = instance.constructor._includedPostCtors;
                for (i = 0; i < includedCtors.length; i++) {
                    includedCtors[i].call(instance)
                }
                if (ctor) {
                    ctor.apply(instance, arguments)
                }
                for (i = 0; i < includedPostCtors.length; i++) {
                    includedPostCtors[i].call(instance)
                }
            };
            inheritor.prototype = clonePrototype(this);
            copyStatic(this, inheritor);
            inheritor.inherit = this.inherit;
            inheritor.abstract = abstract;
            inheritor.redefine = redefine;
            inheritor.include = include;
            inheritor.subclassOf = subclassOf;
            inheritor.parent = this;
            inheritor._includedCtors = this._includedCtors ? this._includedCtors.slice(0) : [];
            inheritor._includedPostCtors = this._includedPostCtors ? this._includedPostCtors.slice(0) : [];
            inheritor.prototype.constructor = inheritor;
            inheritor.redefine(members);
            return inheritor
        };
        classImpl.abstract = abstract;
        module.exports = classImpl
    },
    /*!*******************************!*\
      !*** external "window.JSZip" ***!
      \*******************************/
    function(module, exports) {
        module.exports = window.JSZip
    },
    /*!****************************************!*\
      !*** ./Scripts/localization/number.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dependencyInjector = __webpack_require__( /*! ../core/utils/dependency_injector */ 23),
            errors = __webpack_require__( /*! ../core/errors */ 17);
        var MAX_LARGE_NUMBER_POWER = 4,
            DECIMAL_BASE = 10;
        var NUMERIC_FORMATS = ["currency", "fixedpoint", "exponential", "percent", "decimal"];
        var LargeNumberFormatPostfixes = {
            1: "K",
            2: "M",
            3: "B",
            4: "T"
        };
        var LargeNumberFormatPowers = {
            largenumber: "auto",
            thousands: 1,
            millions: 2,
            billions: 3,
            trillions: 4
        };
        var numberLocalization = dependencyInjector({
            numericFormats: NUMERIC_FORMATS,
            defaultLargeNumberFormatPostfixes: LargeNumberFormatPostfixes,
            _parseNumberFormatString: function(formatType) {
                var formatList, formatObject = {};
                if (!formatType || "string" !== typeof formatType) {
                    return
                }
                formatList = formatType.split(" ");
                $.each(formatList, function(index, value) {
                    if ($.inArray(value, NUMERIC_FORMATS) > -1) {
                        formatObject.formatType = value
                    } else {
                        if (value in LargeNumberFormatPowers) {
                            formatObject.power = LargeNumberFormatPowers[value]
                        }
                    }
                });
                if (formatObject.power && !formatObject.formatType) {
                    formatObject.formatType = "fixedpoint"
                }
                if (formatObject.formatType) {
                    return formatObject
                }
            },
            _calculateNumberPower: function(value, base, minPower, maxPower) {
                var number = Math.abs(value),
                    power = 0;
                if (number > 1) {
                    while (number && number >= base && (void 0 === maxPower || power < maxPower)) {
                        power++;
                        number /= base
                    }
                } else {
                    if (number > 0 && number < 1) {
                        while (number < 1 && (void 0 === minPower || power > minPower)) {
                            power--;
                            number *= base
                        }
                    }
                }
                return power
            },
            _getNumberByPower: function(number, power, base) {
                var result = number;
                while (power > 0) {
                    result /= base;
                    power--
                }
                while (power < 0) {
                    result *= base;
                    power++
                }
                return result
            },
            _formatNumber: function(value, formatObject, formatConfig) {
                var powerPostfix;
                if ("auto" === formatObject.power) {
                    formatObject.power = this._calculateNumberPower(value, 1e3, 0, MAX_LARGE_NUMBER_POWER)
                }
                if (formatObject.power) {
                    value = this._getNumberByPower(value, formatObject.power, 1e3)
                }
                powerPostfix = this.defaultLargeNumberFormatPostfixes[formatObject.power] || "";
                return this._formatNumberCore(value, formatObject.formatType, formatConfig) + powerPostfix
            },
            _formatNumberExponential: function(value, formatConfig) {
                var powString, power = this._calculateNumberPower(value, DECIMAL_BASE),
                    number = this._getNumberByPower(value, power, DECIMAL_BASE);
                if (void 0 === formatConfig.precision) {
                    formatConfig.precision = 1
                }
                if (number.toFixed(formatConfig.precision || 0) >= DECIMAL_BASE) {
                    power++;
                    number /= DECIMAL_BASE
                }
                powString = (power >= 0 ? "+" : "") + power.toString();
                return this._formatNumberCore(number, "fixedpoint", formatConfig) + "E" + powString
            },
            _addZeroes: function(value, precision) {
                var multiplier = Math.pow(10, precision);
                value = (value * multiplier >>> 0) / multiplier;
                var result = value.toString();
                while (result.length < precision) {
                    result = "0" + result
                }
                return result
            },
            _addGroupSeparators: function(value) {
                var parts = value.toString().split(".");
                return parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, ",") + (parts[1] ? "." + parts[1] : "")
            },
            _formatNumberCore: function(value, format, formatConfig) {
                if ("exponential" === format) {
                    return this._formatNumberExponential(value, formatConfig)
                }
                if ("decimal" !== format) {
                    formatConfig.precision = formatConfig.precision || 0
                }
                if ("percent" === format) {
                    value = 100 * value
                }
                if (void 0 !== formatConfig.precision) {
                    if ("decimal" === format) {
                        value = this._addZeroes(value, formatConfig.precision)
                    } else {
                        value = value.toFixed(formatConfig.precision)
                    }
                }
                if ("decimal" !== format) {
                    value = this._addGroupSeparators(value)
                }
                if ("percent" === format) {
                    value += "%"
                }
                return value.toString()
            },
            _normalizeFormat: function(format) {
                if (!format) {
                    return {}
                }
                if ("function" === typeof format) {
                    return format
                }
                if (!$.isPlainObject(format)) {
                    format = {
                        type: format
                    }
                }
                if (format.type) {
                    format.type = format.type.toLowerCase()
                }
                return format
            },
            format: function(value, format) {
                if ("number" !== typeof value) {
                    return value
                }
                if ("number" === typeof format) {
                    return value
                }
                format = format && format.formatter || format;
                if ("function" === typeof format) {
                    return format(value)
                }
                format = this._normalizeFormat(format);
                if (!format.type) {
                    format.type = "decimal"
                }
                var numberConfig = this._parseNumberFormatString(format.type);
                if (!numberConfig) {
                    return
                }
                return this._formatNumber(value, numberConfig, format)
            },
            parse: function(text, format) {
                if (!text) {
                    return
                }
                if (format && format.parser) {
                    return format.parser(text)
                }
                if (format) {
                    errors.log("W0011")
                }
                return parseFloat(text.replace(/^\D+|,+/g, ""))
            }
        });
        module.exports = numberLocalization
    },
    /*!***************************************************!*\
      !*** ./Scripts/core/utils/dependency_injector.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        module.exports = function(object) {
            var $ = __webpack_require__( /*! jquery */ 9),
                Class = __webpack_require__( /*! ../class */ 20);
            var BaseClass = Class.inherit(object),
                InjectedClass = BaseClass,
                instance = new InjectedClass(object),
                initialFields = {};
            var injectFields = function(injectionObject, initial) {
                $.each(injectionObject, function(key) {
                    if ($.isFunction(instance[key])) {
                        if (initial || !object[key]) {
                            object[key] = function() {
                                return instance[key].apply(object, arguments)
                            }
                        }
                    } else {
                        if (initial) {
                            initialFields[key] = object[key]
                        }
                        object[key] = instance[key]
                    }
                })
            };
            injectFields(object, true);
            object.inject = function(injectionObject) {
                InjectedClass = InjectedClass.inherit(injectionObject);
                instance = new InjectedClass;
                injectFields(injectionObject)
            };
            object.resetInjection = function() {
                $.extend(object, initialFields);
                InjectedClass = BaseClass;
                instance = new BaseClass
            };
            return object
        }
    },
    /*!******************************************!*\
      !*** ./Scripts/localization/currency.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            numberLocalization = __webpack_require__( /*! ./number */ 22);
        numberLocalization.inject({
            _formatNumberCore: function(value, format, formatConfig) {
                if ("currency" === format) {
                    formatConfig.precision = formatConfig.precision || 0;
                    return this.getCurrencySymbol().symbol + this.format(value, $.extend({}, formatConfig, {
                        type: "fixedpoint"
                    }))
                }
                return this.callBase.apply(this, arguments)
            },
            getCurrencySymbol: function(currency) {
                return {
                    symbol: "$"
                }
            },
            getOpenXmlCurrencyFormat: function(currency) {
                return "$#,##0{0}_);\\($#,##0{0}\\)"
            }
        })
    },
    /*!**************************************************!*\
      !*** ./Scripts/client_exporter/image_creator.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var currentTspanY, clipPaths, textOffset, imageDeferreds, patterns, filters, $ = __webpack_require__( /*! jquery */ 9),
            Color = __webpack_require__( /*! ../color */ 26),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            _math = Math,
            PI = _math.PI,
            _min = _math.min,
            _abs = _math.abs,
            _sqrt = _math.sqrt,
            _pow = _math.pow,
            _atan2 = _math.atan2,
            _cos = _math.cos,
            _sin = _math.sin,
            _each = $.each,
            _extend = $.extend,
            _number = Number,
            IMAGE_QUALITY = 1,
            TEXT_DECORATION_LINE_WIDTH_COEFF = .05,
            DEFAULT_MARGIN_SIZE = {
                x: 30,
                y: 20
            },
            DEFAULT_FONT_SIZE = "10px",
            DEFAULT_FONT_FAMILY = "sans-serif",
            DEFAULT_TEXT_COLOR = "#000";

        function createCanvas(width, height) {
            var canvas = $("<canvas>")[0];
            canvas.width = width + 2 * DEFAULT_MARGIN_SIZE.x;
            canvas.height = height + 2 * DEFAULT_MARGIN_SIZE.y;
            return canvas
        }

        function getStringFromCanvas(canvas, mimeType) {
            var dataURL = canvas.toDataURL(mimeType, IMAGE_QUALITY),
                imageData = atob(dataURL.substring(("data:" + mimeType + ";base64,").length));
            return imageData
        }

        function arcTo(x1, y1, x2, y2, radius, largeArcFlag, clockwise, context) {
            var opSide, adjSide, centerX, centerY, startAngle, endAngle, cBx = (x1 + x2) / 2,
                cBy = (y1 + y2) / 2,
                aB = _atan2(y1 - y2, x1 - x2),
                k = largeArcFlag ? 1 : -1;
            aB += 90 * (PI / 180) * (clockwise ? 1 : -1);
            opSide = _sqrt(_pow(x2 - x1, 2) + _pow(y2 - y1, 2)) / 2;
            adjSide = _sqrt(_abs(_pow(radius, 2) - _pow(opSide, 2)));
            centerX = cBx + k * (adjSide * _cos(aB));
            centerY = cBy + k * (adjSide * _sin(aB));
            startAngle = _atan2(y1 - centerY, x1 - centerX);
            endAngle = _atan2(y2 - centerY, x2 - centerX);
            context.arc(centerX, centerY, radius, startAngle, endAngle, !clockwise)
        }

        function getElementOptions(element, isText) {
            var coords, attr = parseAttributes(element.attributes || {}),
                style = element.style || {},
                options = _extend({}, attr, {
                    text: element.textContent,
                    textAlign: "middle" === attr["text-anchor"] ? "center" : attr["text-anchor"]
                }),
                transform = attr.transform;
            if (transform) {
                coords = transform.match(/translate\(-*\d+([.]\d+)*(,*\s*-*\d+([.]\d+)*)*/);
                if (coords) {
                    coords = coords[0].match(/-*\d+([.]\d+)*/g);
                    options.translateX = _number(coords[0]);
                    options.translateY = coords[1] ? _number(coords[1]) : 0
                }
                coords = transform.match(/rotate\(-*\d+([.]\d+)*(,*\s*-*\d+([.]\d+)*,*\s*-*\d+([.]\d+)*)*/);
                if (coords) {
                    coords = coords[0].match(/-*\d+([.]\d+)*/g);
                    options.rotationAngle = _number(coords[0]);
                    options.rotationX = coords[1] && _number(coords[1]);
                    options.rotationY = coords[2] && _number(coords[2])
                }
            }
            parseStyles(style, options, isText);
            isText && aggregateTextPosition(options);
            return options
        }

        function drawRect(context, options) {
            var x = options.x,
                y = options.y,
                width = options.width,
                height = options.height,
                cornerRadius = options.rx;
            if (!cornerRadius) {
                context.rect(options.x, options.y, options.width, options.height)
            } else {
                cornerRadius = _min(cornerRadius, width / 2, height / 2);
                context.save();
                context.translate(x, y);
                context.moveTo(width / 2, 0);
                context.arcTo(width, 0, width, height, cornerRadius);
                context.arcTo(width, height, 0, height, cornerRadius);
                context.arcTo(0, height, 0, 0, cornerRadius);
                context.arcTo(0, 0, cornerRadius, 0, cornerRadius);
                context.lineTo(width / 2, 0);
                context.restore()
            }
        }

        function drawImage(context, options) {
            var d = $.Deferred(),
                image = new Image;
            image.onload = function() {
                context.save();
                context.globalAlpha = options.globalAlpha;
                transformElement(context, options);
                clipElement(context, options);
                context.drawImage(image, options.x, options.y, options.width, options.height);
                context.restore();
                d.resolve()
            };
            image.onerror = function(e) {
                d.resolve()
            };
            imageDeferreds.push(d);
            image.setAttribute("crossOrigin", "anonymous");
            image.src = options["xlink:href"]
        }

        function drawPath(context, dAttr) {
            var param1, param2, dArray = dAttr.split(" "),
                i = 0;
            do {
                param1 = _number(dArray[i + 1]);
                param2 = _number(dArray[i + 2]);
                switch (dArray[i]) {
                    case "M":
                        context.moveTo(param1, param2);
                        i += 3;
                        break;
                    case "L":
                        context.lineTo(param1, param2);
                        i += 3;
                        break;
                    case "C":
                        context.bezierCurveTo(param1, param2, _number(dArray[i + 3]), _number(dArray[i + 4]), _number(dArray[i + 5]), _number(dArray[i + 6]));
                        i += 7;
                        break;
                    case "A":
                        arcTo(_number(dArray[i - 2]), _number(dArray[i - 1]), _number(dArray[i + 6]), _number(dArray[i + 7]), param1, _number(dArray[i + 4]), _number(dArray[i + 5]), context);
                        i += 8;
                        break;
                    case "Z":
                        context.closePath();
                        i += 1
                }
            } while (i < dArray.length)
        }

        function parseStyles(style, options, isText) {
            _each(style, function(_, field) {
                if ("" !== style[field]) {
                    options[$.camelCase(field)] = style[field]
                }
            });
            options.textDecoration = options.textDecoration || options.textDecorationLine;
            options.globalAlpha = options.opacity || options.globalAlpha
        }

        function parseUrl(urlString) {
            return urlString.match(/\w+/g).pop()
        }

        function setFontStyle(context, options) {
            var fontParams = [];
            options.fontSize = options.fontSize || DEFAULT_FONT_SIZE;
            options.fontFamily || DEFAULT_FONT_FAMILY;
            options.fill = options.fill || DEFAULT_TEXT_COLOR;
            options.fontStyle && fontParams.push(options.fontStyle);
            options.fontWeight && fontParams.push(options.fontWeight);
            fontParams.push(options.fontSize);
            fontParams.push(options.fontFamily);
            context.font = fontParams.join(" ");
            context.textAlign = options.textAlign;
            context.fillStyle = options.fill;
            context.globalAlpha = options.globalAlpha
        }

        function drawText(context, options) {
            setFontStyle(context, options);
            options.text && context.fillText(options.text, options.x, options.y);
            strokeElement(context, options, true);
            drawTextDecoration(context, options);
            textOffset = options.x + context.measureText(options.text).width
        }

        function drawTextDecoration(context, options) {
            if (!options.textDecoration || "none" === options.textDecoration) {
                return
            }
            var x = options.x,
                align = options.textAlign,
                textWidth = context.measureText(options.text).width,
                textHeight = parseInt(options.fontSize, 10),
                lineHeight = textHeight * TEXT_DECORATION_LINE_WIDTH_COEFF < 1 ? 1 : textHeight * TEXT_DECORATION_LINE_WIDTH_COEFF,
                y = options.y;
            if ("center" === align) {
                x -= textWidth / 2
            } else {
                if ("end" === align) {
                    x -= textWidth
                }
            }
            switch (options.textDecoration) {
                case "line-through":
                    y -= textHeight / 3 + lineHeight / 2;
                    break;
                case "overline":
                    y -= textHeight - lineHeight;
                    break;
                case "underline":
                    y += lineHeight
            }
            context.rect(x, y, textWidth, lineHeight);
            fillElement(context, options);
            strokeElement(context, options)
        }

        function createClipPath(element) {
            clipPaths[element.attributes.id.textContent] = element.childNodes[0]
        }

        function createPattern(element) {
            patterns[element.attributes.id.textContent] = element
        }

        function aggregateOpacity(options) {
            options.strokeOpacity = void 0 !== options["stroke-opacity"] ? options["stroke-opacity"] : 1;
            options.fillOpacity = void 0 !== options["fill-opacity"] ? options["fill-opacity"] : 1;
            if (void 0 !== options.opacity) {
                options.strokeOpacity *= options.opacity;
                options.fillOpacity *= options.opacity
            }
        }

        function aggregateTextPosition(options) {
            if (options.dy) {
                options.y = currentTspanY + _number(options.dy)
            }
            if (textOffset && void 0 === options.x) {
                options.x = textOffset
            }
            if (void 0 !== options.y) {
                currentTspanY = options.y
            } else {
                options.y = currentTspanY
            }
        }

        function drawElement(element, context, parentOptions) {
            var tagName = element.tagName,
                isText = "text" === tagName || "tspan" === tagName || void 0 === tagName,
                isImage = "image" === tagName,
                options = _extend({}, parentOptions, getElementOptions(element, isText));
            if ("hidden" === options.visibility) {
                return
            }
            context.save();
            !isImage && transformElement(context, options);
            clipElement(context, options);
            aggregateOpacity(options);
            context.beginPath();
            switch (element.tagName) {
                case void 0:
                    drawText(context, options);
                    break;
                case "text":
                case "tspan":
                    textOffset = 0;
                    drawCanvasElements(element.childNodes, context, options);
                    break;
                case "title":
                    return;
                case "image":
                    drawImage(context, options);
                    break;
                case "path":
                    drawPath(context, options.d);
                    break;
                case "rect":
                    drawRect(context, options);
                    context.closePath();
                    break;
                case "circle":
                    context.arc(options.cx, options.cy, options.r, 0, 2 * PI, 1)
            }
            applyFilter(context, options);
            if (!isText) {
                fillElement(context, options);
                strokeElement(context, options)
            }
            context.restore()
        }

        function applyFilter(context, options) {
            var filterOptions, matches = options.filter && options.filter.match(/url\(\#(.*)\)/);
            if (matches && matches[1]) {
                filterOptions = filters && filters[matches[1]];
                if (!filterOptions) {
                    filterOptions = {
                        offsetX: 0,
                        offsetY: 0,
                        blur: 0,
                        color: "#000"
                    }
                }
                context.shadowOffsetX = filterOptions.offsetX;
                context.shadowOffsetY = filterOptions.offsetY;
                context.shadowColor = filterOptions.color;
                context.shadowBlur = filterOptions.blur
            }
        }

        function transformElement(context, options) {
            context.translate(options.translateX || 0, options.translateY || 0);
            delete options.translateX;
            delete options.translateY;
            if (options.rotationAngle) {
                context.translate(options.rotationX || 0, options.rotationY || 0);
                context.rotate(options.rotationAngle * PI / 180);
                context.translate(-(options.rotationX || 0), -(options.rotationY || 0));
                delete options.rotationAngle;
                delete options.rotationX;
                delete options.rotationY
            }
        }

        function clipElement(context, options) {
            if (options["clip-path"]) {
                drawElement(clipPaths[parseUrl(options["clip-path"])], context, {});
                context.clip();
                delete options["clip-path"]
            }
        }

        function hex2rgba(hexColor, alpha) {
            var color = new Color(hexColor);
            return "rgba(" + color.r + "," + color.g + "," + color.b + "," + alpha + ")"
        }

        function createFilter(element) {
            var color, opacity, filterOptions = {};
            _each(element.childNodes, function(_, node) {
                var attr = node.attributes;
                if (!attr.result) {
                    return
                }
                switch (attr.result.value) {
                    case "gaussianBlurResult":
                        filterOptions.blur = _number(attr.stdDeviation.value);
                        break;
                    case "offsetResult":
                        filterOptions.offsetX = _number(attr.dx.value);
                        filterOptions.offsetY = _number(attr.dy.value);
                        break;
                    case "floodResult":
                        color = attr["flood-color"] ? attr["flood-color"].value : "#000";
                        opacity = attr["flood-opacity"] ? attr["flood-opacity"].value : 1;
                        filterOptions.color = hex2rgba(color, opacity)
                }
            });
            filters[element.id] = filterOptions
        }

        function drawCanvasElements(elements, context, parentOptions) {
            var options;
            _each(elements, function(_, element) {
                switch (element.tagName && element.tagName.toLowerCase()) {
                    case "g":
                        options = _extend({}, parentOptions, getElementOptions(element));
                        context.save();
                        transformElement(context, options);
                        clipElement(context, options);
                        drawCanvasElements(element.childNodes, context, options);
                        context.restore();
                        break;
                    case "defs":
                        clipPaths = {};
                        patterns = {};
                        filters = {};
                        drawCanvasElements(element.childNodes, context);
                        break;
                    case "clippath":
                        createClipPath(element);
                        break;
                    case "pattern":
                        createPattern(element);
                        break;
                    case "filter":
                        createFilter(element);
                        break;
                    default:
                        drawElement(element, context, parentOptions)
                }
            })
        }

        function setLineDash(context, options) {
            var matches = options["stroke-dasharray"] && options["stroke-dasharray"].match(/(\d+)/g);
            if (matches && matches.length) {
                matches = $.map(matches, function(item) {
                    return _number(item)
                });
                context.setLineDash(matches)
            }
        }

        function strokeElement(context, options, isText) {
            var stroke = options.stroke;
            if (stroke && "none" !== stroke && 0 !== options["stroke-width"]) {
                setLineDash(context, options);
                context.lineJoin = options["stroke-linejoin"];
                context.lineWidth = options["stroke-width"];
                context.globalAlpha = options.strokeOpacity;
                context.strokeStyle = stroke;
                isText ? context.strokeText(options.text, options.x, options.y) : context.stroke()
            }
        }

        function getPattern(context, fill) {
            var pattern = patterns[parseUrl(fill)],
                options = getElementOptions(pattern),
                patternCanvas = createCanvas(options.width, options.height),
                patternContext = patternCanvas.getContext("2d");
            drawCanvasElements(pattern.childNodes, patternContext, options);
            return context.createPattern(patternCanvas, "repeat")
        }

        function fillElement(context, options) {
            var fill = options.fill;
            if (fill && "none" !== fill) {
                context.fillStyle = fill.search(/url/) === -1 ? fill : getPattern(context, fill);
                context.globalAlpha = options.fillOpacity;
                context.fill()
            }
        }
        var parseAttributes = function(attributes) {
            var attr, newAttributes = {};
            $.each(attributes, function(index, item) {
                attr = item.textContent;
                if (isFinite(attr)) {
                    attr = _number(attr)
                }
                newAttributes[item.name.toLowerCase()] = attr
            });
            return newAttributes
        };

        function drawBackground(context, width, height, backgroundColor) {
            context.fillStyle = backgroundColor || "#ffffff";
            context.fillRect(-DEFAULT_MARGIN_SIZE.x, -DEFAULT_MARGIN_SIZE.y, width + 2 * DEFAULT_MARGIN_SIZE.x, height + 2 * DEFAULT_MARGIN_SIZE.y)
        }

        function getCanvasFromSvg(markup, width, height, backgroundColor) {
            var canvas = createCanvas(width, height),
                context = canvas.getContext("2d"),
                parser = new DOMParser,
                elem = parser.parseFromString(markup, "image/svg+xml"),
                svgElem = elem.childNodes[0];
            context.translate(DEFAULT_MARGIN_SIZE.x, DEFAULT_MARGIN_SIZE.y);
            imageDeferreds = [];
            document.body.appendChild(canvas);
            if (svgElem.attributes.direction) {
                canvas.dir = svgElem.attributes.direction.textContent
            }
            drawBackground(context, width, height, backgroundColor);
            drawCanvasElements(svgElem.childNodes, context, {});
            document.body.removeChild(canvas);
            return canvas
        }

        function resolveString(string, canvas, mimeType) {
            $.when.apply($, imageDeferreds).done(function() {
                var resultString = getStringFromCanvas(canvas, mimeType);
                string.resolve(resultString)
            })
        }
        exports.imageCreator = {
            getImageData: function(markup, options) {
                var mimeType = "image/" + options.format,
                    string = $.Deferred(),
                    width = options.width,
                    height = options.height,
                    backgroundColor = options.backgroundColor;
                if ($.isFunction(options.__parseAttributesFn)) {
                    parseAttributes = options.__parseAttributesFn
                }
                resolveString(string, getCanvasFromSvg(markup, width, height, backgroundColor), mimeType);
                return string
            },
            getData: function(markup, options) {
                var that = this,
                    imageData = exports.imageCreator.getImageData(markup, options),
                    mimeType = "image/" + options.format,
                    data = $.Deferred();
                $.when(imageData).done(function(binaryData) {
                    imageData = commonUtils.isFunction(window.Blob) ? that._getBlob(binaryData, mimeType) : that._getBase64(binaryData);
                    data.resolve(imageData)
                });
                return data
            },
            _getBlob: function(binaryData, mimeType) {
                var i, dataArray = new Uint8Array(binaryData.length);
                for (i = 0; i < binaryData.length; i++) {
                    dataArray[i] = binaryData.charCodeAt(i)
                }
                return new Blob([dataArray.buffer], {
                    type: mimeType
                })
            },
            _getBase64: function(binaryData) {
                return window.btoa(binaryData)
            }
        };
        exports.getData = function(data, options, callback) {
            exports.imageCreator.getData(data, options).done(callback)
        }
    },
    /*!**************************!*\
      !*** ./Scripts/color.js ***!
      \**************************/
    function(module, exports) {
        var standardColorNames = {
            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",
            darkkhaki: "bdb76b",
            darkmagenta: "8b008b",
            darkolivegreen: "556b2f",
            darkorange: "ff8c00",
            darkorchid: "9932cc",
            darkred: "8b0000",
            darksalmon: "e9967a",
            darkseagreen: "8fbc8f",
            darkslateblue: "483d8b",
            darkslategray: "2f4f4f",
            darkturquoise: "00ced1",
            darkviolet: "9400d3",
            deeppink: "ff1493",
            deepskyblue: "00bfff",
            dimgray: "696969",
            dodgerblue: "1e90ff",
            feldspar: "d19275",
            firebrick: "b22222",
            floralwhite: "fffaf0",
            forestgreen: "228b22",
            fuchsia: "ff00ff",
            gainsboro: "dcdcdc",
            ghostwhite: "f8f8ff",
            gold: "ffd700",
            goldenrod: "daa520",
            gray: "808080",
            green: "008000",
            greenyellow: "adff2f",
            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",
            lightgrey: "d3d3d3",
            lightgreen: "90ee90",
            lightpink: "ffb6c1",
            lightsalmon: "ffa07a",
            lightseagreen: "20b2aa",
            lightskyblue: "87cefa",
            lightslateblue: "8470ff",
            lightslategray: "778899",
            lightsteelblue: "b0c4de",
            lightyellow: "ffffe0",
            lime: "00ff00",
            limegreen: "32cd32",
            linen: "faf0e6",
            magenta: "ff00ff",
            maroon: "800000",
            mediumaquamarine: "66cdaa",
            mediumblue: "0000cd",
            mediumorchid: "ba55d3",
            mediumpurple: "9370d8",
            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: "d87093",
            papayawhip: "ffefd5",
            peachpuff: "ffdab9",
            peru: "cd853f",
            pink: "ffc0cb",
            plum: "dda0dd",
            powderblue: "b0e0e6",
            purple: "800080",
            rebeccapurple: "663399",
            red: "ff0000",
            rosybrown: "bc8f8f",
            royalblue: "4169e1",
            saddlebrown: "8b4513",
            salmon: "fa8072",
            sandybrown: "f4a460",
            seagreen: "2e8b57",
            seashell: "fff5ee",
            sienna: "a0522d",
            silver: "c0c0c0",
            skyblue: "87ceeb",
            slateblue: "6a5acd",
            slategray: "708090",
            snow: "fffafa",
            springgreen: "00ff7f",
            steelblue: "4682b4",
            tan: "d2b48c",
            teal: "008080",
            thistle: "d8bfd8",
            tomato: "ff6347",
            turquoise: "40e0d0",
            violet: "ee82ee",
            violetred: "d02090",
            wheat: "f5deb3",
            white: "ffffff",
            whitesmoke: "f5f5f5",
            yellow: "ffff00",
            yellowgreen: "9acd32"
        };
        var standardColorTypes = [{
            re: /^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,
            process: function(colorString) {
                return [parseInt(colorString[1], 10), parseInt(colorString[2], 10), parseInt(colorString[3], 10)]
            }
        }, {
            re: /^rgba\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3}),\s*(\d*\.*\d+)\)$/,
            process: function(colorString) {
                return [parseInt(colorString[1], 10), parseInt(colorString[2], 10), parseInt(colorString[3], 10), parseFloat(colorString[4])]
            }
        }, {
            re: /^#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})$/,
            process: function(colorString) {
                return [parseInt(colorString[1], 16), parseInt(colorString[2], 16), parseInt(colorString[3], 16)]
            }
        }, {
            re: /^#([a-f0-9]{1})([a-f0-9]{1})([a-f0-9]{1})$/,
            process: function(colorString) {
                return [parseInt(colorString[1] + colorString[1], 16), parseInt(colorString[2] + colorString[2], 16), parseInt(colorString[3] + colorString[3], 16)]
            }
        }, {
            re: /^hsv\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,
            process: function(colorString) {
                var h = parseInt(colorString[1], 10),
                    s = parseInt(colorString[2], 10),
                    v = parseInt(colorString[3], 10),
                    rgb = hsvToRgb(h, s, v);
                return [rgb[0], rgb[1], rgb[2], 1, [h, s, v]]
            }
        }, {
            re: /^hsl\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,
            process: function(colorString) {
                var h = parseInt(colorString[1], 10),
                    s = parseInt(colorString[2], 10),
                    l = parseInt(colorString[3], 10),
                    rgb = hslToRgb(h, s, l);
                return [rgb[0], rgb[1], rgb[2], 1, null, [h, s, l]]
            }
        }];

        function Color(value) {
            this.baseColor = value;
            var color;
            if (value) {
                color = String(value).toLowerCase().replace(/ /g, "");
                color = standardColorNames[color] ? "#" + standardColorNames[color] : color;
                color = parseColor(color)
            }
            if (!color) {
                this.colorIsInvalid = true
            }
            color = color || {};
            this.r = normalize(color[0]);
            this.g = normalize(color[1]);
            this.b = normalize(color[2]);
            this.a = normalize(color[3], 1, 1);
            if (color[4]) {
                this.hsv = {
                    h: color[4][0],
                    s: color[4][1],
                    v: color[4][2]
                }
            } else {
                this.hsv = toHsvFromRgb(this.r, this.g, this.b)
            }
            if (color[5]) {
                this.hsl = {
                    h: color[5][0],
                    s: color[5][1],
                    l: color[5][2]
                }
            } else {
                this.hsl = toHslFromRgb(this.r, this.g, this.b)
            }
        }

        function parseColor(color) {
            if ("transparent" === color) {
                return [0, 0, 0, 0]
            }
            var str, i = 0,
                ii = standardColorTypes.length;
            for (; i < ii; ++i) {
                str = standardColorTypes[i].re.exec(color);
                if (str) {
                    return standardColorTypes[i].process(str)
                }
            }
            return null
        }

        function normalize(colorComponent, def, max) {
            def = def || 0;
            max = max || 255;
            return colorComponent < 0 || isNaN(colorComponent) ? def : colorComponent > max ? max : colorComponent
        }

        function toHexFromRgb(r, g, b) {
            return "#" + (16777216 | r << 16 | g << 8 | b).toString(16).slice(1)
        }

        function toHsvFromRgb(r, g, b) {
            var H, S, V, max = Math.max(r, g, b),
                min = Math.min(r, g, b),
                delta = max - min;
            V = max;
            S = 0 === max ? 0 : 1 - min / max;
            if (max === min) {
                H = 0
            } else {
                switch (max) {
                    case r:
                        H = 60 * ((g - b) / delta);
                        if (g < b) {
                            H += 360
                        }
                        break;
                    case g:
                        H = 60 * ((b - r) / delta) + 120;
                        break;
                    case b:
                        H = 60 * ((r - g) / delta) + 240
                }
            }
            S *= 100;
            V *= 100 / 255;
            return {
                h: Math.round(H),
                s: Math.round(S),
                v: Math.round(V)
            }
        }

        function hsvToRgb(h, s, v) {
            var Vdec, Vinc, Vmin, Hi, a, r, g, b;
            Hi = Math.floor(h % 360 / 60);
            Vmin = (100 - s) * v / 100;
            a = (v - Vmin) * (h % 60 / 60);
            Vinc = Vmin + a;
            Vdec = v - a;
            switch (Hi) {
                case 0:
                    r = v;
                    g = Vinc;
                    b = Vmin;
                    break;
                case 1:
                    r = Vdec;
                    g = v;
                    b = Vmin;
                    break;
                case 2:
                    r = Vmin;
                    g = v;
                    b = Vinc;
                    break;
                case 3:
                    r = Vmin;
                    g = Vdec;
                    b = v;
                    break;
                case 4:
                    r = Vinc;
                    g = Vmin;
                    b = v;
                    break;
                case 5:
                    r = v;
                    g = Vmin;
                    b = Vdec
            }
            return [Math.round(2.55 * r), Math.round(2.55 * g), Math.round(2.55 * b)]
        }

        function calculateHue(r, g, b, delta) {
            var max = Math.max(r, g, b);
            switch (max) {
                case r:
                    return (g - b) / delta + (g < b ? 6 : 0);
                case g:
                    return (b - r) / delta + 2;
                case b:
                    return (r - g) / delta + 4
            }
        }

        function toHslFromRgb(r, g, b) {
            r = convertTo01Bounds(r, 255);
            g = convertTo01Bounds(g, 255);
            b = convertTo01Bounds(b, 255);
            var h, s, max = Math.max(r, g, b),
                min = Math.min(r, g, b),
                maxMinSum = max + min,
                l = maxMinSum / 2;
            if (max === min) {
                h = s = 0
            } else {
                var delta = max - min;
                if (l > .5) {
                    s = delta / (2 - maxMinSum)
                } else {
                    s = delta / maxMinSum
                }
                h = calculateHue(r, g, b, delta);
                h /= 6
            }
            return {
                h: _round(360 * h),
                s: _round(100 * s),
                l: _round(100 * l)
            }
        }

        function makeTc(colorPart, h) {
            var Tc = h;
            if ("r" === colorPart) {
                Tc = h + 1 / 3
            }
            if ("b" === colorPart) {
                Tc = h - 1 / 3
            }
            return Tc
        }

        function modifyTc(Tc) {
            if (Tc < 0) {
                Tc += 1
            }
            if (Tc > 1) {
                Tc -= 1
            }
            return Tc
        }

        function hueToRgb(p, q, Tc) {
            Tc = modifyTc(Tc);
            if (Tc < 1 / 6) {
                return p + 6 * (q - p) * Tc
            }
            if (Tc < .5) {
                return q
            }
            if (Tc < 2 / 3) {
                return p + (q - p) * (2 / 3 - Tc) * 6
            }
            return p
        }

        function hslToRgb(h, s, l) {
            var r, g, b;
            h = convertTo01Bounds(h, 360), s = convertTo01Bounds(s, 100), l = convertTo01Bounds(l, 100);
            if (0 === s) {
                r = g = b = l
            } else {
                var q = l < .5 ? l * (1 + s) : l + s - l * s,
                    p = 2 * l - q;
                r = hueToRgb(p, q, makeTc("r", h));
                g = hueToRgb(p, q, makeTc("g", h));
                b = hueToRgb(p, q, makeTc("b", h))
            }
            return [_round(255 * r), _round(255 * g), _round(255 * b)]
        }

        function convertTo01Bounds(n, max) {
            n = Math.min(max, Math.max(0, parseFloat(n)));
            if (Math.abs(n - max) < 1e-6) {
                return 1
            }
            return n % max / parseFloat(max)
        }

        function isIntegerBtwMinAndMax(number, min, max) {
            min = min || 0;
            max = max || 255;
            if (number % 1 !== 0 || number < min || number > max || "number" !== typeof number || isNaN(number)) {
                return false
            }
            return true
        }
        var _round = Math.round;
        Color.prototype = {
            constructor: Color,
            highlight: function(step) {
                step = step || 10;
                return this.alter(step).toHex()
            },
            darken: function(step) {
                step = step || 10;
                return this.alter(-step).toHex()
            },
            alter: function(step) {
                var result = new Color;
                result.r = normalize(this.r + step);
                result.g = normalize(this.g + step);
                result.b = normalize(this.b + step);
                return result
            },
            blend: function(blendColor, opacity) {
                var other = blendColor instanceof Color ? blendColor : new Color(blendColor),
                    result = new Color;
                result.r = normalize(_round(this.r * (1 - opacity) + other.r * opacity));
                result.g = normalize(_round(this.g * (1 - opacity) + other.g * opacity));
                result.b = normalize(_round(this.b * (1 - opacity) + other.b * opacity));
                return result
            },
            toHex: function() {
                return toHexFromRgb(this.r, this.g, this.b)
            },
            getPureColor: function() {
                var rgb = hsvToRgb(this.hsv.h, 100, 100);
                return new Color("rgb(" + rgb.join(",") + ")")
            },
            isValidHex: function(hex) {
                return /(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)/i.test(hex)
            },
            isValidRGB: function(r, g, b) {
                if (!isIntegerBtwMinAndMax(r) || !isIntegerBtwMinAndMax(g) || !isIntegerBtwMinAndMax(b)) {
                    return false
                }
                return true
            },
            isValidAlpha: function(a) {
                if (isNaN(a) || a < 0 || a > 1 || "number" !== typeof a) {
                    return false
                }
                return true
            },
            colorIsInvalid: false
        };
        module.exports = Color
    },
    /*!************************************************!*\
      !*** ./Scripts/client_exporter/pdf_creator.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var pdfString, $ = __webpack_require__( /*! jquery */ 9),
            imageCreator = __webpack_require__( /*! ./image_creator */ 25).imageCreator,
            browser = __webpack_require__( /*! ../core/utils/browser */ 18),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            _each = $.each,
            DEFAULT_MARGIN_SIZE = {
                x: 30,
                y: 20
            },
            objectsCount = 0,
            globalOffset = 0,
            PAGES_POINTER = 1,
            RESOURCES_POINTER = 2,
            MAIN_PAGE_POINTER = 3,
            CONTENT_POINTER = 4,
            IMAGE_POINTER = 5,
            INFO_POINTER = 6,
            ROOT_POINTER = 7;

        function addObject(pdfDoc, pointer, content, stream) {
            pdfDoc.content.push({
                type: stream ? "stream" : "object",
                name: pointer + " 0 obj",
                content: content,
                stream: stream
            });
            objectsCount++
        }

        function _pxToPt(px) {
            return .75 * px
        }

        function addMainPage(pdfDoc, options) {
            var width = _pxToPt(options.width + 2 * DEFAULT_MARGIN_SIZE.x).toFixed(2),
                height = _pxToPt(options.height + 2 * DEFAULT_MARGIN_SIZE.y).toFixed(2);
            addObject(pdfDoc, MAIN_PAGE_POINTER, {
                "/Type": "/Page",
                "/Parent": PAGES_POINTER + " 0 R",
                "/Resources": RESOURCES_POINTER + " 0 R",
                "/MediaBox": "[0 0 " + width + " " + height + "]",
                "/Contents": CONTENT_POINTER + " 0 R"
            })
        }

        function addContents(pdfDoc, options) {
            var width = _pxToPt(options.width + 2 * DEFAULT_MARGIN_SIZE.x),
                height = _pxToPt(options.height + 2 * DEFAULT_MARGIN_SIZE.y);
            addObject(pdfDoc, CONTENT_POINTER, {
                "/Length": 54
            }, "0.20 w\n0 G\nq " + width.toFixed(2) + " 0 0 " + height.toFixed(2) + " 0.00 0.00 cm /I0 Do Q")
        }

        function addPages(pdfDoc) {
            addObject(pdfDoc, PAGES_POINTER, {
                "/Type": "/Pages",
                "/Kids": "[" + MAIN_PAGE_POINTER + " 0 R]",
                "/Count": "1"
            })
        }

        function addInfo(pdfDoc) {
            addObject(pdfDoc, INFO_POINTER, {
                "/Producer": "DevExtreme",
                "/CreationDate": exports.pdfCreator.generateCurrentDate()
            })
        }

        function addRoot(pdfDoc) {
            addObject(pdfDoc, ROOT_POINTER, {
                "/Type": "/Catalog",
                "/Pages": "1 0 R",
                "/OpenAction": "[3 0 R /FitH null]",
                "/PageLayout": "/OneColumn"
            })
        }

        function addResources(pdfDoc) {
            addObject(pdfDoc, RESOURCES_POINTER, {
                "/ProcSet": "[/PDF /ImageB /ImageC /ImageI]",
                "/XObject": "<<\n/I0 5 0 R\n>>"
            })
        }

        function addImage(pdfDoc, imageString, options) {
            addObject(pdfDoc, IMAGE_POINTER, {
                "/Type": "/XObject",
                "/Subtype": "/Image",
                "/Width": options.width + 2 * DEFAULT_MARGIN_SIZE.x,
                "/Height": options.height + 2 * DEFAULT_MARGIN_SIZE.y,
                "/ColorSpace": "/DeviceRGB",
                "/BitsPerComponent": 8,
                "/Filter": "/DCTDecode",
                "/Length": imageString.length
            }, imageString)
        }

        function generateXREF(pdfDoc) {
            var cr = exports.pdfCreator;
            cr.addLine("xref");
            cr.addLine("0 " + objectsCount);
            cr.addLine("0000000000 65535 f");
            _each(pdfDoc.content, function(_, section) {
                var i, zeroString = "",
                    offset = section.offset;
                for (i = String(offset).length; i < 10; i++) {
                    zeroString += "0"
                }
                cr.addLine(zeroString + offset + " 00000 n")
            })
        }

        function generateContent(pdfDoc) {
            var cr = exports.pdfCreator;
            _each(pdfDoc.content, function(_, section) {
                cr.addLine(section.name);
                cr.addLine("<<");
                _each(section.content, function(key, value) {
                    cr.addLine(key + " " + value)
                });
                cr.addLine(">>");
                if ("stream" === section.type) {
                    cr.addLine("stream");
                    cr.addLine(section.stream);
                    cr.addLine("endstream")
                }
                cr.addLine("endobj");
                section.offset = globalOffset;
                globalOffset = pdfString.length
            })
        }

        function generateTrailer(pdfDoc) {
            var cr = exports.pdfCreator;
            cr.addLine("trailer");
            cr.addLine("<<");
            cr.addLine("/Size 8");
            cr.addLine("/Root 7 0 R");
            cr.addLine("/Info 6 0 R");
            cr.addLine(">>");
            cr.addLine("startxref");
            cr.addLine(pdfString.length)
        }
        exports.pdfCreator = {
            createPdfDoc: function(imageString, options) {
                var pdfDoc = {
                    content: []
                };
                addMainPage(pdfDoc, options);
                addContents(pdfDoc, options);
                addPages(pdfDoc);
                addImage(pdfDoc, imageString, options);
                addResources(pdfDoc);
                addInfo(pdfDoc);
                addRoot(pdfDoc);
                return pdfDoc
            },
            addLine: function(line) {
                pdfString += line + "\n"
            },
            closeLine: function() {
                pdfString += "%%EOF"
            },
            generateCurrentDate: function() {
                return new Date
            },
            generatePdfString: function(pdfDoc) {
                exports.pdfCreator.addLine("%PDF-1.3");
                globalOffset += pdfString.length;
                generateContent(pdfDoc);
                generateXREF(pdfDoc);
                generateTrailer(pdfDoc);
                exports.pdfCreator.closeLine();
                return pdfString
            },
            getData: function(data, options, isFullMode) {
                pdfString = "";
                globalOffset = 0;
                objectsCount = 1;
                var that = this,
                    imageData = imageCreator.getImageData(data, $.extend({}, options, {
                        format: "jpeg"
                    }), isFullMode),
                    blob = $.Deferred();
                $.when(imageData).done(function(imageString) {
                    var binaryData, pdfData, pdfDoc = exports.pdfCreator.createPdfDoc(imageString, options);
                    binaryData = exports.pdfCreator.generatePdfString(pdfDoc);
                    pdfData = commonUtils.isFunction(window.Blob) ? that._getBlob(binaryData) : that._getBase64(binaryData);
                    blob.resolve(pdfData)
                });
                return blob
            },
            _getBlob: function(binaryData) {
                var i, dataArray = new Uint8Array(binaryData.length);
                for (i = 0; i < binaryData.length; i++) {
                    dataArray[i] = binaryData.charCodeAt(i)
                }
                return new Blob([dataArray.buffer], {
                    type: "application/pdf"
                })
            },
            _getBase64: function(binaryData) {
                return window.btoa(binaryData)
            }
        };
        exports.getData = function(data, options, callback) {
            exports.pdfCreator.getData(data, options, browser.msie).done(callback)
        }
    },
    /*!************************************************!*\
      !*** ./Scripts/client_exporter/svg_creator.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14);
        exports.svgCreator = {
            _markup: "",
            _imageArray: {},
            _imageDeferreds: [],
            _getBinaryFile: function(src, callback) {
                var xhr = new XMLHttpRequest;
                xhr.onreadystatechange = function() {
                    if (xhr.readyState === xhr.DONE) {
                        if (200 === xhr.status && xhr.response) {
                            callback(xhr.response)
                        } else {
                            callback(false)
                        }
                    }
                };
                xhr.open("GET", src, true);
                xhr.responseType = "arraybuffer";
                xhr.send()
            },
            _loadImages: function() {
                var that = this;
                $.each(that._imageArray, function(src) {
                    var deferred = new $.Deferred;
                    that._imageDeferreds.push(deferred);
                    that._getBinaryFile(src, function(response) {
                        if (!response) {
                            delete that._imageArray[src];
                            deferred.resolve();
                            return
                        }
                        var i, binary = "",
                            bytes = new Uint8Array(response),
                            length = bytes.byteLength;
                        for (i = 0; i < length; i++) {
                            binary += String.fromCharCode(bytes[i])
                        }
                        that._imageArray[src] = "data:image/png;base64," + btoa(binary);
                        deferred.resolve()
                    })
                })
            },
            _parseImages: function(element) {
                var href, that = this;
                if ("image" === element.tagName) {
                    href = $(element).attr("xlink:href");
                    if (!that._imageArray[href]) {
                        that._imageArray[href] = ""
                    }
                }
                $.each(element.childNodes, function(_, element) {
                    that._parseImages(element)
                })
            },
            _prepareImages: function(svgElem) {
                this._parseImages(svgElem);
                this._loadImages();
                return $.when.apply($, this._imageDeferreds)
            },
            getData: function(data, options) {
                var markup, that = this,
                    xmlVersion = '<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>',
                    blob = $.Deferred(),
                    parser = new DOMParser,
                    elem = parser.parseFromString(data, "image/svg+xml"),
                    svgElem = elem.childNodes[0],
                    $svgObject = $(svgElem);
                $svgObject.css("background-color", options.backgroundColor);
                markup = xmlVersion + $("<html />").append($svgObject[0]).html();
                that._prepareImages(svgElem).done(function() {
                    $.each(that._imageArray, function(href, dataURI) {
                        markup = markup.split(href).join(dataURI)
                    });
                    blob.resolve(commonUtils.isFunction(window.Blob) ? that._getBlob(markup) : that._getBase64(markup))
                });
                return blob
            },
            _getBlob: function(markup) {
                return new Blob([markup], {
                    type: "image/svg+xml"
                })
            },
            _getBase64: function(markup) {
                return window.btoa(markup)
            }
        };
        exports.getData = function(data, options, callback) {
            exports.svgCreator.getData(data, options).done(callback)
        }
    },
    /*!***************************************!*\
      !*** ./Scripts/core/dom_component.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            config = __webpack_require__( /*! ./config */ 15),
            errors = __webpack_require__( /*! ./errors */ 17),
            windowResizeCallbacks = __webpack_require__( /*! ./utils/window */ 30).resizeCallbacks,
            commonUtils = __webpack_require__( /*! ./utils/common */ 14),
            publicComponentUtils = __webpack_require__( /*! ./utils/public_component */ 31),
            Component = __webpack_require__( /*! ./component */ 34),
            abstract = Component.abstract;
        var RTL_DIRECTION_CLASS = "dx-rtl",
            VISIBILITY_CHANGE_CLASS = "dx-visibility-change-handler",
            VISIBILITY_CHANGE_EVENTNAMESPACE = "VisibilityChange";
        var DOMComponent = Component.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    width: void 0,
                    height: void 0,
                    rtlEnabled: config().rtlEnabled,
                    disabled: false
                })
            },
            ctor: function(element, options) {
                this._$element = $(element);
                publicComponentUtils.attachInstanceToElement(this._$element, this.constructor.publicName(), this, this._dispose);
                this.callBase(options)
            },
            _visibilityChanged: abstract,
            _dimensionChanged: abstract,
            _init: function() {
                this.callBase();
                this._attachWindowResizeCallback()
            },
            _attachWindowResizeCallback: function() {
                if (this._isDimensionChangeSupported()) {
                    var windowResizeCallBack = this._windowResizeCallBack = $.proxy(this._dimensionChanged, this);
                    windowResizeCallbacks.add(windowResizeCallBack)
                }
            },
            _isDimensionChangeSupported: function() {
                return this._dimensionChanged !== abstract
            },
            _render: function() {
                this._toggleRTLDirection(this.option("rtlEnabled"));
                this._renderVisibilityChange();
                this._renderDimensions()
            },
            _renderVisibilityChange: function() {
                if (this._isDimensionChangeSupported()) {
                    this._attachDimensionChangeHandlers()
                }
                if (!this._isVisibilityChangeSupported()) {
                    return
                }
                this.element().addClass(VISIBILITY_CHANGE_CLASS);
                this._attachVisibilityChangeHandlers()
            },
            _renderDimensions: function() {
                var width = this.option("width"),
                    height = this.option("height"),
                    $element = this.element();
                $element.outerWidth(width);
                $element.outerHeight(height)
            },
            _attachDimensionChangeHandlers: function() {
                var that = this;
                var resizeEventName = "dxresize." + this.NAME + VISIBILITY_CHANGE_EVENTNAMESPACE;
                that.element().off(resizeEventName).on(resizeEventName, function() {
                    that._dimensionChanged()
                })
            },
            _attachVisibilityChangeHandlers: function() {
                var that = this;
                var hidingEventName = "dxhiding." + this.NAME + VISIBILITY_CHANGE_EVENTNAMESPACE;
                var shownEventName = "dxshown." + this.NAME + VISIBILITY_CHANGE_EVENTNAMESPACE;
                that._isHidden = !that._isVisible();
                that.element().off(hidingEventName).on(hidingEventName, function() {
                    that._checkVisibilityChanged("hiding")
                }).off(shownEventName).on(shownEventName, function() {
                    that._checkVisibilityChanged("shown")
                })
            },
            _isVisible: function() {
                return this.element().is(":visible")
            },
            _checkVisibilityChanged: function(event) {
                if ("hiding" === event && this._isVisible() && !this._isHidden) {
                    this._visibilityChanged(false);
                    this._isHidden = true
                } else {
                    if ("shown" === event && this._isVisible() && this._isHidden) {
                        this._isHidden = false;
                        this._visibilityChanged(true)
                    }
                }
            },
            _isVisibilityChangeSupported: function() {
                return this._visibilityChanged !== abstract
            },
            _clean: $.noop,
            _modelByElement: function() {
                var modelByElement = this.option("modelByElement") || $.noop;
                return modelByElement(this.element())
            },
            _invalidate: function() {
                if (!this._updateLockCount) {
                    throw errors.Error("E0007")
                }
                this._requireRefresh = true
            },
            _refresh: function() {
                this._clean();
                this._render()
            },
            _dispose: function() {
                this.callBase();
                this._clean();
                this._detachWindowResizeCallback()
            },
            _detachWindowResizeCallback: function() {
                if (this._isDimensionChangeSupported()) {
                    windowResizeCallbacks.remove(this._windowResizeCallBack)
                }
            },
            _toggleRTLDirection: function(rtl) {
                this.element().toggleClass(RTL_DIRECTION_CLASS, rtl)
            },
            _createComponent: function(element, component, config) {
                var that = this;
                config = config || {};
                var synchronizableOptions = $.grep(["rtlEnabled", "disabled"], function(value) {
                    return !(value in config)
                });
                var nestedComponentOptions = that.option("nestedComponentOptions") || $.noop;
                that._extendConfig(config, $.extend({
                    templatesRenderAsynchronously: this.option("templatesRenderAsynchronously"),
                    rtlEnabled: this.option("rtlEnabled"),
                    disabled: this.option("disabled")
                }, nestedComponentOptions(this)));
                var instance;
                if (commonUtils.isString(component)) {
                    var $element = $(element)[component](config);
                    instance = $element[component]("instance")
                } else {
                    if (element) {
                        instance = component.getInstance(element);
                        if (instance) {
                            instance.option(config)
                        } else {
                            instance = new component(element, config)
                        }
                    }
                }
                if (instance) {
                    var optionChangedHandler = function(args) {
                        if ($.inArray(args.name, synchronizableOptions) >= 0) {
                            instance.option(args.name, args.value)
                        }
                    };
                    that.on("optionChanged", optionChangedHandler);
                    instance.on("disposing", function() {
                        that.off("optionChanged", optionChangedHandler)
                    })
                }
                return instance
            },
            _extendConfig: function(config, extendConfig) {
                $.each(extendConfig, function(key, value) {
                    config[key] = config.hasOwnProperty(key) ? config[key] : value
                })
            },
            _defaultActionConfig: function() {
                return $.extend(this.callBase(), {
                    context: this._modelByElement(this.element())
                })
            },
            _defaultActionArgs: function() {
                var element = this.element(),
                    model = this._modelByElement(this.element());
                return $.extend(this.callBase(), {
                    element: element,
                    model: model
                })
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "width":
                    case "height":
                        this._renderDimensions();
                        break;
                    case "rtlEnabled":
                        this._invalidate();
                        break;
                    case "disabled":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            endUpdate: function() {
                var requireRender = !this._initializing && !this._initialized;
                this.callBase.apply(this, arguments);
                if (!this._updateLockCount) {
                    if (requireRender) {
                        this._render()
                    } else {
                        if (this._requireRefresh) {
                            this._requireRefresh = false;
                            this._refresh()
                        }
                    }
                }
            },
            element: function() {
                return this._$element
            }
        });
        DOMComponent.getInstance = function($element) {
            return publicComponentUtils.getInstanceByElement($element, this.publicName())
        };
        DOMComponent.defaultOptions = function(rule) {
            this.prototype._customRules = this.prototype._customRules || [];
            this.prototype._customRules.push(rule)
        };
        module.exports = DOMComponent
    },
    /*!**************************************!*\
      !*** ./Scripts/core/utils/window.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var resizeCallbacks = function() {
            var prevSize, callbacks = $.Callbacks(),
                jqWindow = $(window),
                resizeEventHandlerAttached = false,
                originalCallbacksAdd = callbacks.add,
                originalCallbacksRemove = callbacks.remove;
            var formatSize = function() {
                return [jqWindow.width(), jqWindow.height()].join()
            };
            var handleResize = function() {
                var now = formatSize();
                if (now === prevSize) {
                    return
                }
                prevSize = now;
                setTimeout(callbacks.fire)
            };
            prevSize = formatSize();
            callbacks.add = function() {
                var result = originalCallbacksAdd.apply(callbacks, arguments);
                if (!resizeEventHandlerAttached && callbacks.has()) {
                    jqWindow.on("resize", handleResize);
                    resizeEventHandlerAttached = true
                }
                return result
            };
            callbacks.remove = function() {
                var result = originalCallbacksRemove.apply(callbacks, arguments);
                if (!callbacks.has() && resizeEventHandlerAttached) {
                    jqWindow.off("resize", handleResize);
                    resizeEventHandlerAttached = false
                }
                return result
            };
            return callbacks
        }();
        var defaultScreenFactorFunc = function(width) {
            if (width < 768) {
                return "xs"
            } else {
                if (width < 992) {
                    return "sm"
                } else {
                    if (width < 1200) {
                        return "md"
                    } else {
                        return "lg"
                    }
                }
            }
        };
        var getCurrentScreenFactor = function(screenFactorCallback) {
            var screenFactorFunc = screenFactorCallback || defaultScreenFactorFunc;
            return screenFactorFunc($(window).width())
        };
        exports.resizeCallbacks = resizeCallbacks;
        exports.defaultScreenFactorFunc = defaultScreenFactorFunc;
        exports.getCurrentScreenFactor = getCurrentScreenFactor
    },
    /*!************************************************!*\
      !*** ./Scripts/core/utils/public_component.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            WeakMap = __webpack_require__( /*! ./weak_map */ 32),
            commonUtils = __webpack_require__( /*! ./common */ 14),
            removeEvent = __webpack_require__( /*! ../remove_event */ 33);
        var COMPONENT_NAMES_DATA_KEY = "dxComponents",
            ANONYMOUS_COMPONENT_DATA_KEY = "dxPrivateComponent";
        var componentNames = new WeakMap,
            nextAnonymousComponent = 0;
        exports.attachInstanceToElement = function($element, name, component, disposeFn) {
            var element = $element.get(0),
                data = $.data(element);
            disposeFn = disposeFn || $.noop;
            data[name] = component;
            $element.one(removeEvent, function() {
                disposeFn.call(component)
            });
            if (!data[COMPONENT_NAMES_DATA_KEY]) {
                data[COMPONENT_NAMES_DATA_KEY] = []
            }
            data[COMPONENT_NAMES_DATA_KEY].push(name)
        };
        exports.getInstanceByElement = function(element, name) {
            element = $(element).get(0);
            return $.data(element, name)
        };
        exports.getName = function(newName) {
            if (commonUtils.isDefined(newName)) {
                componentNames.set(this, newName);
                return
            }
            if (!componentNames.has(this)) {
                var generatedName = ANONYMOUS_COMPONENT_DATA_KEY + nextAnonymousComponent++;
                componentNames.set(this, generatedName);
                return generatedName
            }
            return componentNames.get(this)
        }
    },
    /*!****************************************!*\
      !*** ./Scripts/core/utils/weak_map.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            WeakMap = window.WeakMap;
        if (!WeakMap) {
            WeakMap = function() {
                var keys = [],
                    values = [];
                this.set = function(key, value) {
                    var index = $.inArray(key, keys);
                    if (index === -1) {
                        keys.push(key);
                        values.push(value)
                    } else {
                        values[index] = value
                    }
                };
                this.get = function(key) {
                    var index = $.inArray(key, keys);
                    if (index === -1) {
                        return
                    }
                    return values[index]
                };
                this.has = function(key) {
                    var index = $.inArray(key, keys);
                    if (index === -1) {
                        return false
                    }
                    return true
                }
            }
        }
        module.exports = WeakMap
    },
    /*!**************************************!*\
      !*** ./Scripts/core/remove_event.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            cleanData = $.cleanData,
            specialEvents = $.event.special;
        var eventName = "dxremove",
            eventPropName = "dxRemoveEvent";
        $.cleanData = function(elements) {
            for (var i = 0; i < elements.length; i++) {
                var $element = $(elements[i]);
                if ($element.prop(eventPropName)) {
                    $element.removeProp(eventPropName);
                    $element.triggerHandler(eventName)
                }
            }
            return cleanData(elements)
        };
        specialEvents[eventName] = {
            noBubble: true,
            setup: function() {
                $(this).prop(eventPropName, true)
            }
        };
        module.exports = eventName
    },
    /*!***********************************!*\
      !*** ./Scripts/core/component.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ./class */ 20),
            Action = __webpack_require__( /*! ./action */ 35),
            errors = __webpack_require__( /*! ./errors */ 17),
            coreDataUtils = __webpack_require__( /*! ./utils/data */ 36),
            commonUtils = __webpack_require__( /*! ./utils/common */ 14),
            EventsMixin = __webpack_require__( /*! ./events_mixin */ 39),
            publicComponentUtils = __webpack_require__( /*! ./utils/public_component */ 31),
            devices = __webpack_require__( /*! ./devices */ 40);
        var cachedGetters = {};
        var cachedSetters = {};
        var Component = Class.inherit({
            _setDeprecatedOptions: function() {
                this._deprecatedOptions = {}
            },
            _getDeprecatedOptions: function() {
                return this._deprecatedOptions
            },
            _getOptionAliasesByName: function(optionName) {
                return $.map(this._deprecatedOptions, function(deprecate, aliasName) {
                    return optionName === deprecate.alias ? aliasName : void 0
                })
            },
            _getDefaultOptions: function() {
                return {
                    onInitialized: null,
                    onOptionChanged: null,
                    onDisposing: null,
                    defaultOptionsRules: null
                }
            },
            _setDefaultOptions: function() {
                this._options = this._getDefaultOptions()
            },
            _defaultOptionsRules: function() {
                return []
            },
            _setOptionsByDevice: function(userRules) {
                var rules = this._defaultOptionsRules();
                if (this._customRules) {
                    rules = rules.concat(this._customRules)
                }
                if ($.isArray(userRules)) {
                    rules = rules.concat(userRules)
                }
                var rulesOptions = this._convertRulesToOptions(rules);
                $.extend(true, this._options, rulesOptions);
                for (var fieldName in this._optionsByReference) {
                    if (rulesOptions.hasOwnProperty(fieldName)) {
                        this._options[fieldName] = rulesOptions[fieldName]
                    }
                }
            },
            _convertRulesToOptions: function(rules) {
                var options = {};
                var currentDevice = devices.current();
                var deviceMatch = function(device, filter) {
                    filter = $.makeArray(filter);
                    return 1 === filter.length && $.isEmptyObject(filter[0]) || commonUtils.findBestMatches(device, filter).length > 0
                };
                for (var i = 0; i < rules.length; i++) {
                    var match, rule = rules[i],
                        deviceFilter = rule.device || {};
                    if ($.isFunction(deviceFilter)) {
                        match = deviceFilter(currentDevice)
                    } else {
                        match = deviceMatch(currentDevice, deviceFilter)
                    }
                    if (match) {
                        $.extend(options, rule.options)
                    }
                }
                return options
            },
            _isInitialOptionValue: function(name) {
                var isCustomOption = this._customRules && this._convertRulesToOptions(this._customRules).hasOwnProperty(name);
                var optionValue = this.option(name);
                var initialOptionValue = this.initialOption(name);
                var isInitialOption = $.isFunction(optionValue) && $.isFunction(optionValue) ? optionValue.toString() === initialOptionValue.toString() : optionValue === initialOptionValue;
                return !isCustomOption && isInitialOption
            },
            _setOptionsByReference: function() {
                this._optionsByReference = {}
            },
            _getOptionsByReference: function() {
                return this._optionsByReference
            },
            ctor: function(options) {
                this.NAME = this.constructor.publicName();
                options = options || {};
                this._options = {};
                this._updateLockCount = 0;
                this._optionChangedCallbacks = options._optionChangedCallbacks || $.Callbacks();
                this._disposingCallbacks = options._disposingCallbacks || $.Callbacks();
                this.beginUpdate();
                try {
                    this._suppressDeprecatedWarnings();
                    this._setOptionsByReference();
                    this._setDeprecatedOptions();
                    this._setDefaultOptions();
                    this._setOptionsByDevice(options.defaultOptionsRules);
                    this._resumeDeprecatedWarnings();
                    this._initOptions(options)
                } finally {
                    this.endUpdate()
                }
            },
            _initOptions: function(options) {
                this.option(options)
            },
            _optionValuesEqual: function(name, oldValue, newValue) {
                oldValue = coreDataUtils.toComparable(oldValue, true);
                newValue = coreDataUtils.toComparable(newValue, true);
                if (oldValue && newValue && oldValue.jquery && newValue.jquery) {
                    return newValue.is(oldValue)
                }
                var oldValueIsNaN = oldValue !== oldValue,
                    newValueIsNaN = newValue !== newValue;
                if (oldValueIsNaN && newValueIsNaN) {
                    return true
                }
                if (null === oldValue || "object" !== typeof oldValue) {
                    return oldValue === newValue
                }
                return false
            },
            _init: function() {
                this._createOptionChangedAction();
                this.on("disposing", function(args) {
                    this._disposingCallbacks.fireWith(this, [args])
                })
            },
            _createOptionChangedAction: function() {
                this._optionChangedAction = this._createActionByOption("onOptionChanged", {
                    excludeValidators: ["disabled", "readOnly", "designMode"]
                })
            },
            _createDisposingAction: function() {
                this._disposingAction = this._createActionByOption("onDisposing", {
                    excludeValidators: ["disabled", "readOnly", "designMode"]
                })
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onDisposing":
                    case "onInitialized":
                        break;
                    case "onOptionChanged":
                        this._createOptionChangedAction();
                        break;
                    case "defaultOptionsRules":
                }
            },
            _dispose: function() {
                this._optionChangedCallbacks.empty();
                this._createDisposingAction();
                this._disposingAction();
                this._disposeEvents();
                this._disposed = true
            },
            instance: function() {
                return this
            },
            beginUpdate: function() {
                this._updateLockCount++
            },
            endUpdate: function() {
                this._updateLockCount = Math.max(this._updateLockCount - 1, 0);
                if (!this._updateLockCount) {
                    if (!this._initializing && !this._initialized) {
                        this._initializing = true;
                        try {
                            this._init()
                        } finally {
                            this._initializing = false;
                            this._updateLockCount++;
                            this._createActionByOption("onInitialized", {
                                excludeValidators: ["disabled", "readOnly", "designMode"]
                            })();
                            this._updateLockCount--;
                            this._initialized = true
                        }
                    }
                }
            },
            _logWarningIfDeprecated: function(option) {
                var info = this._deprecatedOptions[option];
                if (info && !this._deprecatedOptionsSuppressed) {
                    this._logDeprecatedWarning(option, info)
                }
            },
            _logDeprecatedWarningCount: 0,
            _logDeprecatedWarning: function(option, info) {
                var message = info.message || "Use the '" + info.alias + "' option instead";
                errors.log("W0001", this.NAME, option, info.since, message);
                ++this._logDeprecatedWarningCount
            },
            _suppressDeprecatedWarnings: function() {
                this._deprecatedOptionsSuppressed = true
            },
            _resumeDeprecatedWarnings: function() {
                this._deprecatedOptionsSuppressed = false
            },
            _optionChanging: $.noop,
            _notifyOptionChanged: function(option, value, previousValue) {
                var that = this;
                if (this._initialized) {
                    var optionNames = [option].concat(that._getOptionAliasesByName(option));
                    for (var i = 0; i < optionNames.length; i++) {
                        var name = optionNames[i],
                            args = {
                                name: name.split(/[.\[]/)[0],
                                fullName: name,
                                value: value,
                                previousValue: previousValue
                            };
                        that._optionChangedCallbacks.fireWith(that, [$.extend(that._defaultActionArgs(), args)]);
                        that._optionChangedAction($.extend({}, args));
                        if (!that._disposed) {
                            that._optionChanged(args)
                        }
                    }
                }
            },
            initialOption: function(optionName) {
                var currentOptions, currentInitialized = this._initialized;
                if (!this._initialOptions) {
                    currentOptions = this._options;
                    this._options = {};
                    this._initialized = false;
                    this._setDefaultOptions();
                    this._setOptionsByDevice(currentOptions.defaultOptionsRules);
                    this._initialOptions = this._options;
                    this._options = currentOptions;
                    this._initialized = currentInitialized
                }
                return this._initialOptions[optionName]
            },
            _defaultActionConfig: function() {
                return {
                    context: this,
                    component: this
                }
            },
            _defaultActionArgs: function() {
                return {
                    component: this
                }
            },
            _createAction: function(actionSource, config) {
                var action, that = this;
                return function(e) {
                    if (!arguments.length) {
                        e = {}
                    }
                    if (e instanceof $.Event) {
                        throw Error("Action must be executed with jQuery.Event like action({ jQueryEvent: event })")
                    }
                    if (!$.isPlainObject(e)) {
                        e = {
                            actionValue: e
                        }
                    }
                    action = action || new Action(actionSource, $.extend(config, that._defaultActionConfig()));
                    return action.execute.call(action, $.extend(e, that._defaultActionArgs()))
                }
            },
            _createActionByOption: function(optionName, config) {
                var action, eventName, actionFunc, that = this;
                var result = function() {
                    if (!eventName) {
                        config = config || {};
                        if ("string" !== typeof optionName) {
                            throw errors.Error("E0008")
                        }
                        if (0 === optionName.indexOf("on")) {
                            eventName = optionName.charAt(2).toLowerCase() + optionName.substr(3)
                        } else {
                            throw Error("The '" + optionName + "' option name should start with 'on' prefix")
                        }
                        actionFunc = that.option(optionName)
                    }
                    if (!action && !actionFunc && !config.beforeExecute && !config.afterExecute && !that.hasEvent(eventName)) {
                        return
                    }
                    if (!action) {
                        var beforeExecute = config.beforeExecute;
                        config.beforeExecute = function(args) {
                            that.fireEvent(eventName, args.args);
                            beforeExecute && beforeExecute.apply(that, arguments)
                        };
                        that._suppressDeprecatedWarnings();
                        action = that._createAction(actionFunc, config);
                        that._resumeDeprecatedWarnings()
                    }
                    return action.apply(that, arguments)
                };
                var onActionCreated = that.option("onActionCreated") || $.noop;
                result = onActionCreated(that, result, config) || result;
                return result
            },
            isOptionDeprecated: function(name) {
                var deprecatedOptions = this._getDeprecatedOptions();
                return deprecatedOptions.hasOwnProperty(name)
            },
            option: function() {
                var normalizeOptionName = function(that, name) {
                    var deprecate;
                    if (name) {
                        if (!that._cachedDeprecateNames) {
                            that._cachedDeprecateNames = [];
                            for (var optionName in that._deprecatedOptions) {
                                that._cachedDeprecateNames.push(optionName)
                            }
                        }
                        for (var i = 0; i < that._cachedDeprecateNames.length; i++) {
                            if (that._cachedDeprecateNames[i] === name) {
                                deprecate = that._deprecatedOptions[name];
                                break
                            }
                        }
                        if (deprecate) {
                            that._logWarningIfDeprecated(name);
                            var alias = deprecate.alias;
                            if (alias) {
                                name = alias
                            }
                        }
                    }
                    return name
                };
                var getPreviousName = function(fullName) {
                    var splittedNames = fullName.split(".");
                    splittedNames.pop();
                    return splittedNames.join(".")
                };
                var getFieldName = function(fullName) {
                    var splittedNames = fullName.split(".");
                    return splittedNames[splittedNames.length - 1]
                };
                var getOptionValue = function(options, name, unwrapObservables) {
                    var getter = cachedGetters[name];
                    if (!getter) {
                        getter = cachedGetters[name] = coreDataUtils.compileGetter(name)
                    }
                    return getter(options, {
                        functionsAsIs: true,
                        unwrapObservables: unwrapObservables
                    })
                };
                var clearOptionsField = function(options, name) {
                    delete options[name];
                    var previousFieldName = getPreviousName(name),
                        fieldName = getFieldName(name),
                        fieldObject = previousFieldName ? getOptionValue(options, previousFieldName, false) : options;
                    if (fieldObject) {
                        delete fieldObject[fieldName]
                    }
                };
                var setOptionsField = function(options, fullName, value) {
                    var fieldObject, fieldName = "";
                    do {
                        if (fieldName) {
                            fieldName = "." + fieldName
                        }
                        fieldName = getFieldName(fullName) + fieldName;
                        fullName = getPreviousName(fullName);
                        fieldObject = fullName ? getOptionValue(options, fullName, false) : options
                    } while (!fieldObject);
                    fieldObject[fieldName] = value
                };
                var normalizeOptionValue = function(that, options, name, value) {
                    if (name) {
                        var alias = normalizeOptionName(that, name);
                        if (alias && alias !== name) {
                            setOptionsField(options, alias, value);
                            clearOptionsField(options, name)
                        }
                    }
                };
                var prepareOption = function(that, options, name, value) {
                    if ($.isPlainObject(value)) {
                        for (var valueName in value) {
                            prepareOption(that, options, name + "." + valueName, value[valueName])
                        }
                    }
                    normalizeOptionValue(that, options, name, value)
                };
                var setOptionValue = function(that, name, value) {
                    if (!cachedSetters[name]) {
                        cachedSetters[name] = coreDataUtils.compileSetter(name)
                    }
                    cachedSetters[name](that._options, value, {
                        functionsAsIs: true,
                        merge: !that._getOptionsByReference()[name],
                        unwrapObservables: false
                    })
                };
                var setOption = function(that, name, value) {
                    var previousValue = getOptionValue(that._options, name, false);
                    if (that._optionValuesEqual(name, previousValue, value)) {
                        return
                    }
                    if (that._initialized) {
                        that._optionChanging(name, previousValue, value)
                    }
                    setOptionValue(that, name, value);
                    that._notifyOptionChanged(name, value, previousValue)
                };
                return function(options, value) {
                    var that = this,
                        name = options;
                    if (arguments.length < 2 && "object" !== $.type(name)) {
                        name = normalizeOptionName(that, name);
                        return getOptionValue(that._options, name)
                    }
                    if ("string" === typeof name) {
                        options = {};
                        options[name] = value
                    }
                    that.beginUpdate();
                    try {
                        var optionName;
                        for (optionName in options) {
                            prepareOption(that, options, optionName, options[optionName])
                        }
                        for (optionName in options) {
                            setOption(that, optionName, options[optionName])
                        }
                    } finally {
                        that.endUpdate()
                    }
                }
            }()
        }).include(EventsMixin);
        Component.publicName = publicComponentUtils.getName;
        module.exports = Component
    },
    /*!********************************!*\
      !*** ./Scripts/core/action.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            config = __webpack_require__( /*! ./config */ 15),
            Class = __webpack_require__( /*! ./class */ 20);
        var Action = Class.inherit({
            ctor: function(action, config) {
                config = config || {};
                this._action = action;
                this._context = config.context || window;
                this._beforeExecute = config.beforeExecute;
                this._afterExecute = config.afterExecute;
                this._component = config.component;
                this._validatingTargetName = config.validatingTargetName;
                var excludeValidators = this._excludeValidators = {};
                if (config.excludeValidators) {
                    for (var i = 0; i < config.excludeValidators.length; i++) {
                        excludeValidators[config.excludeValidators[i]] = true
                    }
                }
            },
            execute: function() {
                var e = {
                    action: this._action,
                    args: Array.prototype.slice.call(arguments),
                    context: this._context,
                    component: this._component,
                    validatingTargetName: this._validatingTargetName,
                    cancel: false,
                    handled: false
                };
                var beforeExecute = this._beforeExecute,
                    afterExecute = this._afterExecute;
                if (!this._validateAction(e)) {
                    return
                }
                beforeExecute && beforeExecute.call(this._context, e);
                if (e.cancel) {
                    return
                }
                var result = this._executeAction(e);
                var argsBag = e.args[0];
                if (argsBag && argsBag.cancel) {
                    return
                }
                afterExecute && afterExecute.call(this._context, e);
                return result
            },
            _validateAction: function(e) {
                var excludeValidators = this._excludeValidators,
                    executors = Action.executors;
                for (var name in executors) {
                    if (!excludeValidators[name]) {
                        var executor = executors[name];
                        if (executor.validate) {
                            executor.validate(e)
                        }
                        if (e.cancel) {
                            return false
                        }
                    }
                }
                return true
            },
            _executeAction: function(e) {
                var result, executors = Action.executors;
                for (var name in executors) {
                    var executor = executors[name];
                    if (executor.execute) {
                        executor.execute(e)
                    }
                    if (e.handled) {
                        result = e.result;
                        break
                    }
                }
                return result
            }
        });
        Action.executors = {};
        Action.registerExecutor = function(name, executor) {
            if ($.isPlainObject(name)) {
                $.each(name, Action.registerExecutor);
                return
            }
            Action.executors[name] = executor
        };
        Action.unregisterExecutor = function() {
            var args = $.makeArray(arguments);
            $.each(args, function() {
                delete Action.executors[this]
            })
        };
        Action.registerExecutor({
            undefined: {
                execute: function(e) {
                    if (!e.action) {
                        e.result = void 0;
                        e.handled = true
                    }
                }
            },
            func: {
                execute: function(e) {
                    if ($.isFunction(e.action)) {
                        e.result = e.action.call(e.context, e.args[0]);
                        e.handled = true
                    }
                }
            }
        });
        var createValidatorByTargetElement = function(condition) {
            return function(e) {
                if (!e.args.length) {
                    return
                }
                var args = e.args[0],
                    element = args[e.validatingTargetName] || args.element;
                if (element && condition(element)) {
                    e.cancel = true
                }
            }
        };
        Action.registerExecutor({
            designMode: {
                validate: function(e) {
                    if (config().designMode) {
                        e.cancel = true
                    }
                }
            },
            disabled: {
                validate: createValidatorByTargetElement(function($target) {
                    return $target.is(".dx-state-disabled, .dx-state-disabled *")
                })
            },
            readOnly: {
                validate: createValidatorByTargetElement(function($target) {
                    return $target.is(".dx-state-readonly, .dx-state-readonly *")
                })
            }
        });
        module.exports = Action
    },
    /*!************************************!*\
      !*** ./Scripts/core/utils/data.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../errors */ 17),
            Class = __webpack_require__( /*! ../class */ 20),
            objectUtils = __webpack_require__( /*! ./object */ 37),
            variableWrapper = __webpack_require__( /*! ./variable_wrapper */ 38),
            unwrapVariable = variableWrapper.unwrap,
            isWrapped = variableWrapper.isWrapped,
            assign = variableWrapper.assign;
        var bracketsToDots = function(expr) {
            return expr.replace(/\[/g, ".").replace(/\]/g, "")
        };
        var readPropValue = function(obj, propName) {
            if ("this" === propName) {
                return obj
            }
            return obj[propName]
        };
        var assignPropValue = function(obj, propName, value, options) {
            if ("this" === propName) {
                throw new errors.Error("E4016")
            }
            var propValue = obj[propName];
            if (options.unwrapObservables && isWrapped(propValue)) {
                assign(propValue, value)
            } else {
                obj[propName] = value
            }
        };
        var prepareOptions = function(options) {
            options = options || {};
            options.unwrapObservables = void 0 !== options.unwrapObservables ? options.unwrapObservables : true;
            return options
        };
        var unwrap = function(value, options) {
            return options.unwrapObservables ? unwrapVariable(value) : value
        };
        var compileGetter = function(expr) {
            if (arguments.length > 1) {
                expr = $.makeArray(arguments)
            }
            if (!expr || "this" === expr) {
                return function(obj) {
                    return obj
                }
            }
            if ("string" === typeof expr) {
                expr = bracketsToDots(expr);
                var path = expr.split(".");
                return function(obj, options) {
                    options = prepareOptions(options);
                    var functionAsIs = options.functionsAsIs,
                        current = unwrap(obj, options);
                    for (var i = 0; i < path.length; i++) {
                        if (!current) {
                            break
                        }
                        var next = unwrap(current[path[i]], options);
                        if (!functionAsIs && $.isFunction(next)) {
                            next = next.call(current)
                        }
                        current = next
                    }
                    return current
                }
            }
            if ($.isArray(expr)) {
                return combineGetters(expr)
            }
            if ($.isFunction(expr)) {
                return expr
            }
        };
        var combineGetters = function(getters) {
            var compiledGetters = {};
            for (var i = 0, l = getters.length; i < l; i++) {
                var getter = getters[i];
                compiledGetters[getter] = compileGetter(getter)
            }
            return function(obj, options) {
                var result;
                $.each(compiledGetters, function(name) {
                    var current, path, last, i, value = this(obj, options);
                    if (void 0 === value) {
                        return
                    }
                    current = result || (result = {});
                    path = name.split(".");
                    last = path.length - 1;
                    for (i = 0; i < last; i++) {
                        current = current[path[i]] = {}
                    }
                    current[path[i]] = value
                });
                return result
            }
        };
        var compileSetter = function(expr) {
            expr = expr || "this";
            expr = bracketsToDots(expr);
            var pos = expr.lastIndexOf("."),
                targetGetter = compileGetter(expr.substr(0, pos)),
                targetPropName = expr.substr(1 + pos);
            return function(obj, value, options) {
                options = prepareOptions(options);
                var target = targetGetter(obj, {
                        functionsAsIs: options.functionsAsIs,
                        unwrapObservables: options.unwrapObservables
                    }),
                    prevTargetValue = readPropValue(target, targetPropName);
                if (!options.functionsAsIs && $.isFunction(prevTargetValue) && !isWrapped(prevTargetValue)) {
                    target[targetPropName](value)
                } else {
                    prevTargetValue = unwrap(prevTargetValue, options);
                    if (options.merge && $.isPlainObject(value) && (void 0 === prevTargetValue || $.isPlainObject(prevTargetValue)) && !(value instanceof $.Event)) {
                        if (!prevTargetValue) {
                            assignPropValue(target, targetPropName, {}, options)
                        }
                        objectUtils.deepExtendArraySafe(unwrap(readPropValue(target, targetPropName), options), value)
                    } else {
                        assignPropValue(target, targetPropName, value, options)
                    }
                }
            }
        };
        var toComparable = function(value, caseSensitive) {
            if (value instanceof Date) {
                return value.getTime()
            }
            if (value && value instanceof Class && value.valueOf) {
                return value.valueOf()
            }
            if (!caseSensitive && "string" === typeof value) {
                return value.toLowerCase()
            }
            return value
        };
        exports.compileGetter = compileGetter;
        exports.compileSetter = compileSetter;
        exports.toComparable = toComparable
    },
    /*!**************************************!*\
      !*** ./Scripts/core/utils/object.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ./common */ 14),
            variableWrapper = __webpack_require__( /*! ./variable_wrapper */ 38);
        var clone = function() {
            function Clone() {}
            return function(obj) {
                Clone.prototype = obj;
                return new Clone
            }
        }();
        var extendFromObject = function(target, source, overrideExistingValues) {
            target = target || {};
            for (var prop in source) {
                if (source.hasOwnProperty(prop)) {
                    var value = source[prop];
                    if (!(prop in target) || overrideExistingValues) {
                        target[prop] = value
                    }
                }
            }
            return target
        };
        var orderEach = function(map, func) {
            var key, i, keys = [];
            for (key in map) {
                if (map.hasOwnProperty(key)) {
                    keys.push(key)
                }
            }
            keys.sort(function(x, y) {
                var isNumberX = commonUtils.isNumber(x),
                    isNumberY = commonUtils.isNumber(y);
                if (isNumberX && isNumberY) {
                    return x - y
                }
                if (isNumberX && !isNumberY) {
                    return -1
                }
                if (!isNumberX && isNumberY) {
                    return 1
                }
                if (x < y) {
                    return -1
                }
                if (x > y) {
                    return 1
                }
                return 0
            });
            for (i = 0; i < keys.length; i++) {
                key = keys[i];
                func(key, map[key])
            }
        };
        var assignValueToProperty = function(target, property, value) {
            if (variableWrapper.isWrapped(target[property])) {
                variableWrapper.assign(target[property], value)
            } else {
                target[property] = value
            }
        };
        var deepExtendArraySafe = function(target, changes) {
            var prevValue, newValue;
            for (var name in changes) {
                prevValue = target[name];
                newValue = changes[name];
                if (target === newValue) {
                    continue
                }
                if ($.isPlainObject(newValue) && !(newValue instanceof $.Event)) {
                    assignValueToProperty(target, name, deepExtendArraySafe($.isPlainObject(prevValue) ? prevValue : {}, newValue))
                } else {
                    if (void 0 !== newValue) {
                        assignValueToProperty(target, name, newValue)
                    }
                }
            }
            return target
        };
        exports.clone = clone;
        exports.extendFromObject = extendFromObject;
        exports.orderEach = orderEach;
        exports.deepExtendArraySafe = deepExtendArraySafe
    },
    /*!************************************************!*\
      !*** ./Scripts/core/utils/variable_wrapper.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var logger = __webpack_require__( /*! ./console */ 12).logger,
            dependencyInjector = __webpack_require__( /*! ./dependency_injector */ 23);
        module.exports = dependencyInjector({
            isWrapped: function(value) {
                return false
            },
            isWritableWrapped: function(value) {
                return false
            },
            wrap: function(value) {
                return value
            },
            unwrap: function(value) {
                return value
            },
            assign: function(variable, value) {
                logger.error("Method 'assign' should not be used for not wrapped variables. Use 'isWrapped' method for enshuring.")
            }
        })
    },
    /*!**************************************!*\
      !*** ./Scripts/core/events_mixin.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        module.exports = {
            ctor: function() {
                this._events = {}
            },
            hasEvent: function(eventName) {
                var callbacks = this._events[eventName];
                if (callbacks) {
                    return callbacks.has()
                }
                return false
            },
            fireEvent: function(eventName, eventArgs) {
                var callbacks = this._events[eventName];
                if (callbacks) {
                    callbacks.fireWith(this, eventArgs)
                }
                return this
            },
            on: function(eventName, eventHandler) {
                if ($.isPlainObject(eventName)) {
                    $.each(eventName, $.proxy(function(e, h) {
                        this.on(e, h)
                    }, this))
                } else {
                    var addFn, callbacks = this._events[eventName];
                    if (!callbacks) {
                        callbacks = $.Callbacks();
                        this._events[eventName] = callbacks
                    }
                    addFn = callbacks.originalAdd || callbacks.add;
                    addFn.call(callbacks, eventHandler)
                }
                return this
            },
            off: function(eventName, eventHandler) {
                var callbacks = this._events[eventName];
                if (callbacks) {
                    if ($.isFunction(eventHandler)) {
                        callbacks.remove(eventHandler)
                    } else {
                        callbacks.empty()
                    }
                }
                return this
            },
            _disposeEvents: function() {
                $.each(this._events, function() {
                    this.empty()
                })
            }
        }
    },
    /*!*********************************!*\
      !*** ./Scripts/core/devices.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ./class */ 20),
            errors = __webpack_require__( /*! ./errors */ 17),
            resizeCallbacks = __webpack_require__( /*! ./utils/window */ 30).resizeCallbacks,
            EventsMixin = __webpack_require__( /*! ./events_mixin */ 39),
            SessionStorage = __webpack_require__( /*! ./utils/storage */ 41).sessionStorage,
            viewPort = __webpack_require__( /*! ./utils/view_port */ 42),
            Config = __webpack_require__( /*! ./config */ 15);
        var KNOWN_UA_TABLE = {
            iPhone: "iPhone",
            iPhone5: "iPhone",
            iPhone6: "iPhone",
            iPhone6plus: "iPhone",
            iPad: "iPad",
            iPadMini: "iPad Mini",
            androidPhone: "Android Mobile",
            androidTablet: "Android",
            win8: "MSAppHost",
            win8Phone: "Windows Phone 8.0",
            msSurface: "MSIE ARM Tablet PC",
            desktop: "desktop",
            win10Phone: "Windows Phone 10.0",
            win10: "MSAppHost/3.0"
        };
        var DEFAULT_DEVICE = {
            deviceType: "desktop",
            platform: "generic",
            version: [],
            phone: false,
            tablet: false,
            android: false,
            ios: false,
            win: false,
            generic: true,
            grade: "A",
            mac: false
        };
        var uaParsers = {
            win: function(userAgent) {
                var isPhone = /windows phone/i.test(userAgent) || userAgent.match(/WPDesktop/),
                    isTablet = !isPhone && /arm(.*)trident/i.test(userAgent),
                    isDesktop = !isPhone && !isTablet && /msapphost/i.test(userAgent);
                if (!(isPhone || isTablet || isDesktop)) {
                    return
                }
                var matches = userAgent.match(/windows phone (\d+).(\d+)/i) || userAgent.match(/windows nt (\d+).(\d+)/i),
                    version = [];
                if (matches) {
                    version.push(parseInt(matches[1], 10), parseInt(matches[2], 10))
                } else {
                    matches = userAgent.match(/msapphost(\/(\d+).(\d+))?/i);
                    matches && version.push(3 === parseInt(matches[2], 10) ? 10 : 8)
                }
                return {
                    deviceType: isPhone ? "phone" : isTablet ? "tablet" : "desktop",
                    platform: "win",
                    version: version,
                    grade: "A"
                }
            },
            ios: function(userAgent) {
                if (!/ip(hone|od|ad)/i.test(userAgent)) {
                    return
                }
                var isPhone = /ip(hone|od)/i.test(userAgent),
                    matches = userAgent.match(/os (\d+)_(\d+)_?(\d+)?/i),
                    version = matches ? [parseInt(matches[1], 10), parseInt(matches[2], 10), parseInt(matches[3] || 0, 10)] : [],
                    isIPhone4 = 480 === window.screen.height,
                    grade = isIPhone4 ? "B" : "A";
                return {
                    deviceType: isPhone ? "phone" : "tablet",
                    platform: "ios",
                    version: version,
                    grade: grade
                }
            },
            android: function(userAgent) {
                if (!/android|htc_|silk/i.test(userAgent)) {
                    return
                }
                var isPhone = /mobile/i.test(userAgent),
                    matches = userAgent.match(/android (\d+)\.(\d+)\.?(\d+)?/i),
                    version = matches ? [parseInt(matches[1], 10), parseInt(matches[2], 10), parseInt(matches[3] || 0, 10)] : [],
                    worseThan4_4 = version.length > 1 && (version[0] < 4 || 4 === version[0] && version[1] < 4),
                    grade = worseThan4_4 ? "B" : "A";
                return {
                    deviceType: isPhone ? "phone" : "tablet",
                    platform: "android",
                    version: version,
                    grade: grade
                }
            }
        };
        var Devices = Class.inherit({
            ctor: function(options) {
                this._window = options && options.window || window;
                this._realDevice = this._getDevice();
                this._currentDevice = void 0;
                this._currentOrientation = void 0;
                this.changed = $.Callbacks();
                this._recalculateOrientation();
                resizeCallbacks.add($.proxy(this._recalculateOrientation, this))
            },
            current: function(deviceOrName) {
                if (deviceOrName) {
                    this._currentDevice = this._getDevice(deviceOrName);
                    this._forced = true;
                    this.changed.fire();
                    if ("win" === this._currentDevice.platform && 8 === this._currentDevice.version[0]) {
                        errors.log("W0010", "the 'win8' theme", "16.1", "Use the 'win10' theme instead.")
                    }
                    return
                }
                if (!this._currentDevice) {
                    deviceOrName = void 0;
                    try {
                        deviceOrName = this._getDeviceOrNameFromWindowScope()
                    } catch (e) {
                        deviceOrName = this._getDeviceNameFromSessionStorage()
                    } finally {
                        if (!deviceOrName) {
                            deviceOrName = this._getDeviceNameFromSessionStorage()
                        }
                        if (deviceOrName) {
                            this._forced = true
                        }
                    }
                    this._currentDevice = this._getDevice(deviceOrName)
                }
                return this._currentDevice
            },
            real: function() {
                var forceDevice = arguments[0];
                if ($.isPlainObject(forceDevice)) {
                    $.extend(this._realDevice, forceDevice);
                    return
                }
                return $.extend({}, this._realDevice)
            },
            orientation: function() {
                return this._currentOrientation
            },
            isForced: function() {
                return this._forced
            },
            isRippleEmulator: function() {
                return !!this._window.tinyHippos
            },
            _getCssClasses: function(device) {
                var result = [];
                var realDevice = this._realDevice;
                device = device || this.current();
                if (device.deviceType) {
                    result.push("dx-device-" + device.deviceType);
                    if ("desktop" !== device.deviceType) {
                        result.push("dx-device-mobile")
                    }
                }
                result.push("dx-device-" + realDevice.platform);
                if (realDevice.version && realDevice.version.length) {
                    result.push("dx-device-" + realDevice.platform + "-" + realDevice.version[0])
                }
                if (devices.isSimulator()) {
                    result.push("dx-simulator")
                }
                if (Config().rtlEnabled) {
                    result.push("dx-rtl")
                }
                return result
            },
            attachCssClasses: function(element, device) {
                this._deviceClasses = this._getCssClasses(device).join(" ");
                $(element).addClass(this._deviceClasses)
            },
            detachCssClasses: function(element) {
                $(element).removeClass(this._deviceClasses)
            },
            isSimulator: function() {
                try {
                    return this._isSimulator || this._window.top !== this._window.self && this._window.top["dx-force-device"] || this.isRippleEmulator()
                } catch (e) {
                    return false
                }
            },
            forceSimulator: function() {
                this._isSimulator = true
            },
            _getDevice: function(deviceName) {
                if ("genericPhone" === deviceName) {
                    deviceName = {
                        deviceType: "phone",
                        platform: "generic",
                        generic: true
                    }
                }
                if ($.isPlainObject(deviceName)) {
                    return this._fromConfig(deviceName)
                } else {
                    var ua;
                    if (deviceName) {
                        ua = KNOWN_UA_TABLE[deviceName];
                        if (!ua) {
                            throw errors.Error("E0005")
                        }
                    } else {
                        ua = navigator.userAgent
                    }
                    return this._fromUA(ua)
                }
            },
            _getDeviceOrNameFromWindowScope: function() {
                var result;
                if (this._window.top["dx-force-device-object"] || this._window.top["dx-force-device"]) {
                    result = this._window.top["dx-force-device-object"] || this._window.top["dx-force-device"]
                }
                return result
            },
            _getDeviceNameFromSessionStorage: function() {
                var sessionStorage = SessionStorage();
                if (!sessionStorage) {
                    return
                }
                var deviceOrName = sessionStorage.getItem("dx-force-device");
                try {
                    return $.parseJSON(deviceOrName)
                } catch (ex) {
                    return deviceOrName
                }
            },
            _fromConfig: function(config) {
                var result = $.extend({}, DEFAULT_DEVICE, this._currentDevice, config),
                    shortcuts = {
                        phone: "phone" === result.deviceType,
                        tablet: "tablet" === result.deviceType,
                        android: "android" === result.platform,
                        ios: "ios" === result.platform,
                        win: "win" === result.platform,
                        generic: "generic" === result.platform
                    };
                return $.extend(result, shortcuts)
            },
            _fromUA: function(ua) {
                var config;
                $.each(uaParsers, function(platform, parser) {
                    config = parser(ua);
                    return !config
                });
                if (config) {
                    return this._fromConfig(config)
                }
                var isMac = /(mac os)/.test(ua.toLowerCase()),
                    deviceWithOS = DEFAULT_DEVICE;
                deviceWithOS.mac = isMac;
                return deviceWithOS
            },
            _changeOrientation: function() {
                var $window = $(this._window),
                    orientation = $window.height() > $window.width() ? "portrait" : "landscape";
                if (this._currentOrientation === orientation) {
                    return
                }
                this._currentOrientation = orientation;
                this.fireEvent("orientationChanged", [{
                    orientation: orientation
                }])
            },
            _recalculateOrientation: function() {
                var windowWidth = $(this._window).width();
                if (this._currentWidth === windowWidth) {
                    return
                }
                this._currentWidth = windowWidth;
                this._changeOrientation()
            }
        }).include(EventsMixin);
        var devices = new Devices;
        viewPort.changeCallback.add(function(viewPort, prevViewport) {
            devices.detachCssClasses(prevViewport);
            devices.attachCssClasses(viewPort)
        });
        if (!devices.isForced() && "win" === devices.current().platform) {
            devices.current({
                version: [10]
            })
        }
        module.exports = devices
    },
    /*!***************************************!*\
      !*** ./Scripts/core/utils/storage.js ***!
      \***************************************/
    function(module, exports) {
        var getSessionStorage = function() {
            var sessionStorage;
            try {
                sessionStorage = window.sessionStorage
            } catch (e) {}
            return sessionStorage
        };
        exports.sessionStorage = getSessionStorage
    },
    /*!*****************************************!*\
      !*** ./Scripts/core/utils/view_port.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            changeCallback = $.Callbacks(),
            $originalViewPort = $();
        var value = function() {
            var $current;
            return function(element) {
                if (!arguments.length) {
                    return $current
                }
                var $element = $(element);
                $originalViewPort = $element;
                var isNewViewportFound = !!$element.length;
                var prevViewPort = value();
                $current = isNewViewportFound ? $element : $("body");
                changeCallback.fire(isNewViewportFound ? value() : $(), prevViewPort)
            }
        }();
        $(function() {
            value(".dx-viewport")
        });
        exports.value = value;
        exports.changeCallback = changeCallback;
        exports.originalViewPort = function() {
            return $originalViewPort
        }
    },
    /*!***********************************************!*\
      !*** ./Scripts/core/component_registrator.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ./errors */ 17),
            MemorizedCallbacks = __webpack_require__( /*! ./memorized_callbacks */ 44);
        var callbacks = new MemorizedCallbacks;
        var registerComponent = function(name, namespace, componentClass) {
            if (!componentClass) {
                componentClass = namespace
            } else {
                namespace[name] = componentClass
            }
            componentClass.publicName(name);
            callbacks.fire(name, componentClass)
        };
        registerComponent.callbacks = callbacks;
        var registerJQueryComponent = function(name, componentClass) {
            $.fn[name] = function(options) {
                var result, isMemberInvoke = "string" === typeof options;
                if (isMemberInvoke) {
                    var memberName = options,
                        memberArgs = $.makeArray(arguments).slice(1);
                    this.each(function() {
                        var instance = componentClass.getInstance(this);
                        if (!instance) {
                            throw errors.Error("E0009", name)
                        }
                        var member = instance[memberName],
                            memberValue = member.apply(instance, memberArgs);
                        if (void 0 === result) {
                            result = memberValue
                        }
                    })
                } else {
                    this.each(function() {
                        var instance = componentClass.getInstance(this);
                        if (instance) {
                            instance.option(options)
                        } else {
                            new componentClass(this, options)
                        }
                    });
                    result = this
                }
                return result
            }
        };
        callbacks.add(registerJQueryComponent);
        module.exports = registerComponent
    },
    /*!*********************************************!*\
      !*** ./Scripts/core/memorized_callbacks.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var MemorizedCallbacks = function() {
            var memory = [];
            var callbacks = $.Callbacks();
            this.add = function(fn) {
                $.each(memory, function(_, item) {
                    fn.apply(fn, item)
                });
                callbacks.add(fn)
            };
            this.remove = function(fn) {
                callbacks.remove(fn)
            };
            this.fire = function() {
                memory.push(arguments);
                callbacks.fire.apply(callbacks, arguments)
            }
        };
        module.exports = MemorizedCallbacks
    },
    /*!***************************************!*\
      !*** ./Scripts/core/utils/version.js ***!
      \***************************************/
    function(module, exports) {
        var compare = function(x, y, maxLevel) {
            function normalizeArg(value) {
                if ("string" === typeof value) {
                    return value.split(".")
                }
                if ("number" === typeof value) {
                    return [value]
                }
                return value
            }
            x = normalizeArg(x);
            y = normalizeArg(y);
            var length = Math.max(x.length, y.length);
            if (isFinite(maxLevel)) {
                length = Math.min(length, maxLevel)
            }
            for (var i = 0; i < length; i++) {
                var xItem = parseInt(x[i] || 0, 10),
                    yItem = parseInt(y[i] || 0, 10);
                if (xItem < yItem) {
                    return -1
                }
                if (xItem > yItem) {
                    return 1
                }
            }
            return 0
        };
        exports.compare = compare
    },
    /*!************************************!*\
      !*** ./Scripts/animation/frame.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            FRAME_ANIMATION_STEP_TIME = 1e3 / 60,
            request = function(callback) {
                return this.setTimeout(callback, FRAME_ANIMATION_STEP_TIME)
            },
            cancel = function(requestID) {
                this.clearTimeout(requestID)
            },
            nativeRequest = window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || window.oRequestAnimationFrame || window.msRequestAnimationFrame,
            nativeCancel = window.cancelAnimationFrame || window.webkitCancelAnimationFrame || window.mozCancelAnimationFrame || window.oCancelAnimationFrame || window.msCancelAnimationFrame;
        if (nativeRequest && nativeCancel) {
            request = nativeRequest;
            cancel = nativeCancel
        }
        if (nativeRequest && !nativeCancel) {
            var canceledRequests = {};
            request = function(callback) {
                var requestId = nativeRequest.call(window, function() {
                    try {
                        if (requestId in canceledRequests) {
                            return
                        }
                        callback.apply(this, arguments)
                    } finally {
                        delete canceledRequests[requestId]
                    }
                });
                return requestId
            };
            cancel = function(requestId) {
                canceledRequests[requestId] = true
            }
        }
        exports.requestAnimationFrame = $.proxy(request, window);
        exports.cancelAnimationFrame = $.proxy(cancel, window)
    },
    /*!*********************************************************************!*\
      !*** ./Scripts/mobile/init_mobile_viewport/init_mobile_viewport.js ***!
      \*********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            resizeCallbacks = __webpack_require__( /*! ../../core/utils/window */ 30).resizeCallbacks,
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            devices = __webpack_require__( /*! ../../core/devices */ 40);
        var initMobileViewport = function(options) {
            options = $.extend({}, options);
            var realDevice = devices.real();
            var allowZoom = options.allowZoom;
            var allowPan = options.allowPan;
            var allowSelection = "allowSelection" in options ? options.allowSelection : "generic" === realDevice.platform;
            var metaSelector = "meta[name=viewport]";
            if (!$(metaSelector).length) {
                $("<meta />").attr("name", "viewport").appendTo("head")
            }
            var metaVerbs = ["width=device-width"],
                msTouchVerbs = [];
            if (allowZoom) {
                msTouchVerbs.push("pinch-zoom")
            } else {
                metaVerbs.push("initial-scale=1.0", "maximum-scale=1.0, user-scalable=no")
            }
            if (allowPan) {
                msTouchVerbs.push("pan-x", "pan-y")
            }
            if (!allowPan && !allowZoom) {
                $("html, body").css({
                    "-ms-content-zooming": "none",
                    "-ms-user-select": "none",
                    overflow: "hidden"
                })
            } else {
                $("html").css("-ms-overflow-style", "-ms-autohiding-scrollbar")
            }
            if (!allowSelection && support.supportProp("user-select")) {
                $(".dx-viewport").css(support.styleProp("user-select"), "none")
            }
            $(metaSelector).attr("content", metaVerbs.join());
            $("html").css("-ms-touch-action", msTouchVerbs.join(" ") || "none");
            realDevice = devices.real();
            if (support.touch && !("win" === realDevice.platform && 10 === realDevice.version[0])) {
                $(document).off(".dxInitMobileViewport").on("dxpointermove.dxInitMobileViewport", function(e) {
                    var count = e.pointers.length,
                        isTouchEvent = "touch" === e.pointerType,
                        zoomDisabled = !allowZoom && count > 1,
                        panDisabled = !allowPan && 1 === count && !e.isScrollingEvent;
                    if (isTouchEvent && (zoomDisabled || panDisabled)) {
                        e.preventDefault()
                    }
                })
            }
            if (realDevice.ios) {
                var isPhoneGap = "file:" === document.location.protocol;
                if (!isPhoneGap) {
                    resizeCallbacks.add(function() {
                        var windowWidth = $(window).width();
                        $("body").width(windowWidth)
                    })
                }
            }
            if (realDevice.android) {
                resizeCallbacks.add(function() {
                    setTimeout(function() {
                        document.activeElement.scrollIntoViewIfNeeded()
                    })
                })
            }
        };
        exports.initMobileViewport = initMobileViewport
    },
    /*!***************************************!*\
      !*** ./Scripts/core/utils/support.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            inflector = __webpack_require__( /*! ./inflector */ 49),
            devices = __webpack_require__( /*! ../devices */ 40);
        var camelize = inflector.camelize;
        var jsPrefixes = ["", "Webkit", "Moz", "O", "Ms"],
            cssPrefixes = {
                "": "",
                Webkit: "-webkit-",
                Moz: "-moz-",
                O: "-o-",
                ms: "-ms-"
            },
            styles = document.createElement("dx").style;
        var transitionEndEventNames = {
            webkitTransition: "webkitTransitionEnd",
            MozTransition: "transitionend",
            OTransition: "oTransitionEnd",
            msTransition: "MsTransitionEnd",
            transition: "transitionend"
        };
        var forEachPrefixes = function(prop, callBack) {
            prop = camelize(prop, true);
            var result;
            for (var i = 0, cssPrefixesCount = jsPrefixes.length; i < cssPrefixesCount; i++) {
                var jsPrefix = jsPrefixes[i];
                var prefixedProp = jsPrefix + prop;
                var lowerPrefixedProp = camelize(prefixedProp);
                result = callBack(lowerPrefixedProp, jsPrefix);
                if (void 0 === result) {
                    result = callBack(prefixedProp, jsPrefix)
                }
                if (void 0 !== result) {
                    break
                }
            }
            return result
        };
        var styleProp = function(prop) {
            return forEachPrefixes(prop, function(specific) {
                if (specific in styles) {
                    return specific
                }
            })
        };
        var stylePropPrefix = function(prop) {
            return forEachPrefixes(prop, function(specific, jsPrefix) {
                if (specific in styles) {
                    return cssPrefixes[jsPrefix]
                }
            })
        };
        var supportProp = function(prop) {
            return !!styleProp(prop)
        };
        var isNativeScrollingSupported = function() {
            var realDevice = devices.real(),
                realPlatform = realDevice.platform,
                realVersion = realDevice.version,
                isObsoleteAndroid = realVersion && realVersion[0] < 4 && "android" === realPlatform,
                isNativeScrollDevice = !isObsoleteAndroid && $.inArray(realPlatform, ["ios", "android", "win"]) > -1 || realDevice.mac;
            return isNativeScrollDevice
        };
        var inputType = function(type) {
            if ("text" === type) {
                return true
            }
            var input = document.createElement("input");
            try {
                input.setAttribute("type", type);
                input.value = "wrongValue";
                return !input.value
            } catch (e) {
                return false
            }
        };
        var touchEvents = "ontouchstart" in window && !("callPhantom" in window),
            pointerEvents = !!window.navigator.pointerEnabled || !!window.navigator.msPointerEnabled,
            touchPointersPresent = !!window.navigator.maxTouchPoints || !!window.navigator.msMaxTouchPoints;
        exports.touchEvents = touchEvents;
        exports.pointerEvents = pointerEvents;
        exports.touch = touchEvents || pointerEvents && touchPointersPresent;
        exports.transform = supportProp("transform");
        exports.transition = supportProp("transition");
        exports.transitionEndEventName = transitionEndEventNames[styleProp("transition")];
        exports.animation = supportProp("animation");
        exports.nativeScrolling = isNativeScrollingSupported();
        exports.winJS = "WinJS" in window;
        exports.styleProp = styleProp;
        exports.stylePropPrefix = stylePropPrefix;
        exports.supportProp = supportProp;
        exports.hasKo = !!window.ko;
        exports.inputType = inputType
    },
    /*!*****************************************!*\
      !*** ./Scripts/core/utils/inflector.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var _normalize = function(text) {
            if (void 0 === text || null === text) {
                return ""
            }
            return String(text)
        };
        var _ucfirst = function(text) {
            return _normalize(text).charAt(0).toUpperCase() + text.substr(1)
        };
        var _chop = function(text) {
            return _normalize(text).replace(/([a-z\d])([A-Z])/g, "$1 $2").split(/[\s_-]+/)
        };
        var dasherize = function(text) {
            return $.map(_chop(text), function(p) {
                return p.toLowerCase()
            }).join("-")
        };
        var underscore = function(text) {
            return dasherize(text).replace(/-/g, "_")
        };
        var camelize = function(text, upperFirst) {
            return $.map(_chop(text), function(p, i) {
                p = p.toLowerCase();
                if (upperFirst || i > 0) {
                    p = _ucfirst(p)
                }
                return p
            }).join("")
        };
        var humanize = function(text) {
            return _ucfirst(dasherize(text).replace(/-/g, " "))
        };
        var titleize = function(text) {
            return $.map(_chop(text), function(p) {
                return _ucfirst(p.toLowerCase())
            }).join(" ")
        };
        var captionize = function(name) {
            var i, char, captionList = [],
                isPrevCharNewWord = false,
                isNewWord = false;
            for (i = 0; i < name.length; i++) {
                char = name.charAt(i);
                isNewWord = char === char.toUpperCase() || char in ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9"];
                if ("_" === char || "." === char) {
                    char = " ";
                    isNewWord = true
                } else {
                    if (0 === i) {
                        char = char.toUpperCase();
                        isNewWord = true
                    } else {
                        if (!isPrevCharNewWord && isNewWord) {
                            if (captionList.length > 0) {
                                captionList.push(" ")
                            }
                        }
                    }
                }
                captionList.push(char);
                isPrevCharNewWord = isNewWord
            }
            return captionList.join("")
        };
        exports.dasherize = dasherize;
        exports.camelize = camelize;
        exports.humanize = humanize;
        exports.titleize = titleize;
        exports.underscore = underscore;
        exports.captionize = captionize
    },
    /*!***********************************!*\
      !*** ./Scripts/core/utils/dom.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../errors */ 17),
            commonUtils = __webpack_require__( /*! ./common */ 14);
        var resetActiveElement = function() {
            var activeElement = document.activeElement;
            if (activeElement && activeElement !== document.body && activeElement.blur) {
                activeElement.blur()
            }
        };
        var getSelection = function() {
            if (window.getSelection) {
                return window.getSelection()
            }
            if (document.selection) {
                return document.selection
            }
            return null
        };
        var clearSelection = function() {
            var selection = getSelection();
            if (!selection) {
                return
            }
            if ("Caret" === selection.type) {
                return
            }
            if (selection.empty) {
                selection.empty()
            } else {
                if (selection.removeAllRanges) {
                    selection.removeAllRanges()
                }
            }
        };
        var closestCommonParent = function(startTarget, endTarget) {
            var $startParents = $(startTarget).parents().addBack(),
                $endParents = $(endTarget).parents().addBack(),
                startingParent = Math.min($startParents.length, $endParents.length) - 1;
            for (var i = startingParent; i >= 0; i--) {
                if ($startParents.eq(i).is($endParents.eq(i))) {
                    return $startParents.get(i)
                }
            }
        };
        var triggerVisibilityChangeEvent = function(eventName) {
            var VISIBILITY_CHANGE_SELECTOR = ".dx-visibility-change-handler";
            return function(element) {
                var $element = $(element || "body");
                var $changeHandlers = $element.find(VISIBILITY_CHANGE_SELECTOR).add($element.filter(VISIBILITY_CHANGE_SELECTOR));
                $changeHandlers.each(function() {
                    $(this).triggerHandler(eventName)
                })
            }
        };
        var uniqueId = function() {
            var counter = 0;
            return function(prefix) {
                return (prefix || "") + counter++
            }
        }();
        var dataOptionsAttributeName = "data-options";
        var getElementOptions = function(element) {
            var result, optionsString = $(element).attr(dataOptionsAttributeName);
            if ("{" !== $.trim(optionsString).charAt(0)) {
                optionsString = "{" + optionsString + "}"
            }
            try {
                result = new Function("return " + optionsString)()
            } catch (ex) {
                throw errors.Error("E3018", ex, optionsString)
            }
            return result
        };
        var createComponents = function(elements, componentTypes) {
            var result = [],
                selector = "[" + dataOptionsAttributeName + "]";
            elements.find(selector).addBack(selector).each(function(index, element) {
                var $element = $(element),
                    options = getElementOptions(element);
                for (var componentName in options) {
                    if (!componentTypes || $.inArray(componentName, componentTypes) > -1) {
                        if ($element[componentName]) {
                            $element[componentName](options[componentName]);
                            result.push($element[componentName]("instance"))
                        }
                    }
                }
            });
            return result
        };
        var createMarkupFromString = function(str) {
            if (!window.WinJS) {
                return $(str)
            }
            var tempElement = $("<div />");
            window.WinJS.Utilities.setInnerHTMLUnsafe(tempElement.get(0), str);
            return tempElement.contents()
        };
        var normalizeTemplateElement = function(element) {
            var $element = commonUtils.isDefined(element) && (element.nodeType || element.jquery) ? $(element) : $("<div>").html(element).contents();
            if (1 === $element.length) {
                if ($element.is("script")) {
                    $element = normalizeTemplateElement($element.html())
                } else {
                    if ($element.is("table")) {
                        $element = $element.contents()
                    }
                }
            }
            return $element
        };
        var toggleAttr = function($target, attr, value) {
            value ? $target.attr(attr, value) : $target.removeAttr(attr)
        };
        var clipboardText = function(event, text) {
            var clipboard = event.originalEvent && event.originalEvent.clipboardData || window.clipboardData;
            if (1 === arguments.length) {
                return clipboard && clipboard.getData("Text")
            }
            clipboard && clipboard.setData("Text", text)
        };
        exports.resetActiveElement = resetActiveElement;
        exports.createMarkupFromString = createMarkupFromString;
        exports.triggerShownEvent = triggerVisibilityChangeEvent("dxshown");
        exports.triggerHidingEvent = triggerVisibilityChangeEvent("dxhiding");
        exports.triggerResizeEvent = triggerVisibilityChangeEvent("dxresize");
        exports.getElementOptions = getElementOptions;
        exports.createComponents = createComponents;
        exports.normalizeTemplateElement = normalizeTemplateElement;
        exports.clearSelection = clearSelection;
        exports.getSelection = getSelection;
        exports.uniqueId = uniqueId;
        exports.closestCommonParent = closestCommonParent;
        exports.clipboardText = clipboardText;
        exports.toggleAttr = toggleAttr
    },
    /*!*************************************!*\
      !*** ./Scripts/core/utils/queue.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../errors */ 17);

        function createQueue(discardPendingTasks) {
            var _tasks = [],
                _busy = false;

            function exec() {
                while (_tasks.length) {
                    _busy = true;
                    var task = _tasks.shift(),
                        result = task();
                    if (void 0 === result) {
                        continue
                    }
                    if (result.then) {
                        $.when(result).always(exec);
                        return
                    }
                    throw errors.Error("E0015")
                }
                _busy = false
            }

            function add(task, removeTaskCallback) {
                if (!discardPendingTasks) {
                    _tasks.push(task)
                } else {
                    if (_tasks[0] && removeTaskCallback) {
                        removeTaskCallback(_tasks[0])
                    }
                    _tasks = [task]
                }
                if (!_busy) {
                    exec()
                }
            }

            function busy() {
                return _busy
            }
            return {
                add: add,
                busy: busy
            }
        }
        exports.create = createQueue;
        exports.enqueue = createQueue().add
    },
    /*!************************************!*\
      !*** ./Scripts/core/utils/date.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ./common */ 14),
            inflector = __webpack_require__( /*! ./inflector */ 49),
            isObject = commonUtils.isObject,
            isString = commonUtils.isString,
            isDate = commonUtils.isDate,
            isDefined = commonUtils.isDefined,
            camelize = inflector.camelize;
        var dateUnitIntervals = ["millisecond", "second", "minute", "hour", "day", "week", "month", "quarter", "year"];
        var toMilliseconds = function(value) {
            switch (value) {
                case "millisecond":
                    return 1;
                case "second":
                    return 1e3 * toMilliseconds("millisecond");
                case "minute":
                    return 60 * toMilliseconds("second");
                case "hour":
                    return 60 * toMilliseconds("minute");
                case "day":
                    return 24 * toMilliseconds("hour");
                case "week":
                    return 7 * toMilliseconds("day");
                case "month":
                    return 30 * toMilliseconds("day");
                case "quarter":
                    return 3 * toMilliseconds("month");
                case "year":
                    return 365 * toMilliseconds("day");
                default:
                    return 0
            }
        };
        var getDatesInterval = function(startDate, endDate, intervalUnit) {
            var delta = endDate.getTime() - startDate.getTime(),
                millisecondCount = toMilliseconds(intervalUnit) || 1;
            return Math.floor(delta / millisecondCount)
        };
        var getNextDateUnit = function(unit, withWeeks) {
            var interval = getDateUnitInterval(unit);
            switch (interval) {
                case "millisecond":
                    return "second";
                case "second":
                    return "minute";
                case "minute":
                    return "hour";
                case "hour":
                    return "day";
                case "day":
                    return withWeeks ? "week" : "month";
                case "week":
                    return "month";
                case "month":
                    return "quarter";
                case "quarter":
                    return "year";
                case "year":
                    return "year";
                default:
                    return 0
            }
        };
        var convertMillisecondsToDateUnits = function(value) {
            var i, dateUnitCount, dateUnitInterval, dateUnitIntervals = ["millisecond", "second", "minute", "hour", "day", "month", "year"],
                result = {};
            for (i = dateUnitIntervals.length - 1; i >= 0; i--) {
                dateUnitInterval = dateUnitIntervals[i];
                dateUnitCount = Math.floor(value / toMilliseconds(dateUnitInterval));
                if (dateUnitCount > 0) {
                    result[dateUnitInterval + "s"] = dateUnitCount;
                    value -= convertDateUnitToMilliseconds(dateUnitInterval, dateUnitCount)
                }
            }
            return result
        };
        var dateToMilliseconds = function(tickInterval) {
            var milliseconds = 0;
            if (isObject(tickInterval)) {
                $.each(tickInterval, function(key, value) {
                    milliseconds += convertDateUnitToMilliseconds(key.substr(0, key.length - 1), value)
                })
            }
            if (isString(tickInterval)) {
                milliseconds = convertDateUnitToMilliseconds(tickInterval, 1)
            }
            return milliseconds
        };
        var convertDateUnitToMilliseconds = function(dateUnit, count) {
            return toMilliseconds(dateUnit) * count
        };
        var getDateUnitInterval = function(tickInterval) {
            var i, maxInterval = -1;
            if (isString(tickInterval)) {
                return tickInterval
            }
            if (isObject(tickInterval)) {
                $.each(tickInterval, function(key, value) {
                    for (i = 0; i < dateUnitIntervals.length; i++) {
                        if (value && (key === dateUnitIntervals[i] + "s" || key === dateUnitIntervals[i]) && maxInterval < i) {
                            maxInterval = i
                        }
                    }
                });
                return dateUnitIntervals[maxInterval]
            }
            return ""
        };
        var tickIntervalToFormatMap = {
            millisecond: "millisecond",
            second: "longtime",
            minute: "shorttime",
            hour: "shorttime",
            day: "day",
            week: "day",
            month: "month",
            quarter: "quarter",
            year: "year"
        };

        function getDateFormatByTickInterval(tickInterval) {
            return tickIntervalToFormatMap[getDateUnitInterval(tickInterval)] || ""
        }
        var getQuarter = function(month) {
            return Math.floor(month / 3)
        };
        var getFirstQuarterMonth = function(month) {
            return 3 * getQuarter(month)
        };
        var correctDateWithUnitBeginning = function(date, dateInterval, withCorrection) {
            date = new Date(date.getTime());
            var firstQuarterMonth, oldDate = new Date(date.getTime()),
                dateUnitInterval = getDateUnitInterval(dateInterval);
            switch (dateUnitInterval) {
                case "second":
                    date.setMilliseconds(0);
                    break;
                case "minute":
                    date.setSeconds(0, 0);
                    break;
                case "hour":
                    date.setMinutes(0, 0, 0);
                    break;
                case "year":
                    date.setMonth(0);
                case "month":
                    date.setDate(1);
                case "day":
                    date.setHours(0, 0, 0, 0);
                    break;
                case "week":
                    date.setDate(date.getDate() - date.getDay());
                    date.setHours(0, 0, 0, 0);
                    break;
                case "quarter":
                    firstQuarterMonth = getFirstQuarterMonth(date.getMonth());
                    if (date.getMonth() !== firstQuarterMonth) {
                        date.setMonth(firstQuarterMonth)
                    }
                    date.setDate(1);
                    date.setHours(0, 0, 0, 0)
            }
            if (withCorrection && "hour" !== dateUnitInterval && "minute" !== dateUnitInterval && "second" !== dateUnitInterval) {
                fixTimezoneGap(oldDate, date)
            }
            return date
        };
        var trimTime = function(date) {
            return dateUtils.correctDateWithUnitBeginning(date, "day")
        };
        var getDatesDifferences = function(date1, date2) {
            var differences, counter = 0;
            differences = {
                year: date1.getFullYear() !== date2.getFullYear(),
                month: date1.getMonth() !== date2.getMonth(),
                day: date1.getDate() !== date2.getDate(),
                hour: date1.getHours() !== date2.getHours(),
                minute: date1.getMinutes() !== date2.getMinutes(),
                second: date1.getSeconds() !== date2.getSeconds()
            };
            $.each(differences, function(key, value) {
                if (value) {
                    counter++
                }
            });
            differences.count = counter;
            return differences
        };

        function addDateInterval(value, interval, dir) {
            var result = new Date(value.getTime()),
                intervalObject = isString(interval) ? getDateIntervalByString(interval.toLowerCase()) : interval;
            if (intervalObject.years) {
                result.setFullYear(result.getFullYear() + intervalObject.years * dir)
            }
            if (intervalObject.quarters) {
                result.setMonth(result.getMonth() + 3 * intervalObject.quarters * dir)
            }
            if (intervalObject.months) {
                result.setMonth(result.getMonth() + intervalObject.months * dir)
            }
            if (intervalObject.weeks) {
                result.setDate(result.getDate() + 7 * intervalObject.weeks * dir)
            }
            if (intervalObject.days) {
                result.setDate(result.getDate() + intervalObject.days * dir)
            }
            if (intervalObject.hours) {
                result.setHours(result.getHours() + intervalObject.hours * dir)
            }
            if (intervalObject.minutes) {
                result.setMinutes(result.getMinutes() + intervalObject.minutes * dir)
            }
            if (intervalObject.seconds) {
                result.setSeconds(result.getSeconds() + intervalObject.seconds * dir)
            }
            if (intervalObject.milliseconds) {
                result.setMilliseconds(value.getMilliseconds() + intervalObject.milliseconds * dir)
            }
            return result
        }
        var addInterval = function(value, interval, isNegative) {
            var dir = isNegative ? -1 : 1;
            return isDate(value) ? addDateInterval(value, interval, dir) : value + interval * dir
        };
        var getSequenceByInterval = function(min, max, interval) {
            var cur, intervals = [];
            intervals.push(isDate(min) ? new Date(min.getTime()) : min);
            cur = min;
            while (cur < max) {
                cur = addInterval(cur, interval);
                intervals.push(cur)
            }
            return intervals
        };
        var getViewFirstCellDate = function(viewType, date) {
            if ("month" === viewType) {
                return new Date(date.getFullYear(), date.getMonth(), 1)
            }
            if ("year" === viewType) {
                return new Date(date.getFullYear(), 0, date.getDate())
            }
            if ("decade" === viewType) {
                return new Date(getFirstYearInDecade(date), date.getMonth(), date.getDate())
            }
            if ("century" === viewType) {
                return new Date(getFirstDecadeInCentury(date), date.getMonth(), date.getDate())
            }
        };
        var getViewLastCellDate = function(viewType, date) {
            if ("month" === viewType) {
                return new Date(date.getFullYear(), date.getMonth(), getLastMonthDay(date))
            }
            if ("year" === viewType) {
                return new Date(date.getFullYear(), 11, date.getDate())
            }
            if ("decade" === viewType) {
                return new Date(getFirstYearInDecade(date) + 9, date.getMonth(), date.getDate())
            }
            if ("century" === viewType) {
                return new Date(getFirstDecadeInCentury(date) + 90, date.getMonth(), date.getDate())
            }
        };
        var getViewMinBoundaryDate = function(viewType, date) {
            var resultDate = new Date(date.getFullYear(), date.getMonth(), 1);
            if ("month" === viewType) {
                return resultDate
            }
            resultDate.setMonth(0);
            if ("year" === viewType) {
                return resultDate
            }
            if ("decade" === viewType) {
                resultDate.setFullYear(getFirstYearInDecade(date))
            }
            if ("century" === viewType) {
                resultDate.setFullYear(getFirstDecadeInCentury(date))
            }
            return resultDate
        };
        var getViewMaxBoundaryDate = function(viewType, date) {
            var resultDate = new Date(date.getFullYear(), date.getMonth(), getLastMonthDay(date));
            if ("month" === viewType) {
                return resultDate
            }
            resultDate.setMonth(11);
            resultDate.setDate(getLastMonthDay(resultDate));
            if ("year" === viewType) {
                return resultDate
            }
            if ("decade" === viewType) {
                resultDate.setFullYear(getFirstYearInDecade(date) + 9)
            }
            if ("century" === viewType) {
                resultDate.setFullYear(getFirstDecadeInCentury(date) + 99)
            }
            return resultDate
        };
        var getLastMonthDay = function(date) {
            var resultDate = new Date(date.getFullYear(), date.getMonth() + 1, 0);
            return resultDate.getDate()
        };
        var sameView = function(view, date1, date2) {
            return dateUtils[camelize("same " + view)](date1, date2)
        };
        var getViewUp = function(typeView) {
            switch (typeView) {
                case "month":
                    return "year";
                case "year":
                    return "decade";
                case "decade":
                    return "century"
            }
        };
        var getViewDown = function(typeView) {
            switch (typeView) {
                case "century":
                    return "decade";
                case "decade":
                    return "year";
                case "year":
                    return "month"
            }
        };
        var getDifferenceInMonth = function(typeView) {
            var difference = 1;
            if ("year" === typeView) {
                difference = 12
            }
            if ("decade" === typeView) {
                difference = 120
            }
            if ("century" === typeView) {
                difference = 1200
            }
            return difference
        };
        var getDifferenceInMonthForCells = function(typeView) {
            var difference = 1;
            if ("decade" === typeView) {
                difference = 12
            }
            if ("century" === typeView) {
                difference = 120
            }
            return difference
        };
        var getDateIntervalByString = function(intervalString) {
            var result = {};
            switch (intervalString) {
                case "year":
                    result.years = 1;
                    break;
                case "month":
                    result.months = 1;
                    break;
                case "quarter":
                    result.months = 3;
                    break;
                case "week":
                    result.days = 7;
                    break;
                case "day":
                    result.days = 1;
                    break;
                case "hour":
                    result.hours = 1;
                    break;
                case "minute":
                    result.minutes = 1;
                    break;
                case "second":
                    result.seconds = 1;
                    break;
                case "millisecond":
                    result.milliseconds = 1
            }
            return result
        };
        var sameDate = function(date1, date2) {
            return sameMonthAndYear(date1, date2) && date1.getDate() === date2.getDate()
        };
        var sameMonthAndYear = function(date1, date2) {
            return sameYear(date1, date2) && date1.getMonth() === date2.getMonth()
        };
        var sameYear = function(date1, date2) {
            return date1 && date2 && date1.getFullYear() === date2.getFullYear()
        };
        var sameDecade = function(date1, date2) {
            if (!isDefined(date1) || !isDefined(date2)) {
                return
            }
            var startDecadeDate1 = date1.getFullYear() - date1.getFullYear() % 10,
                startDecadeDate2 = date2.getFullYear() - date2.getFullYear() % 10;
            return date1 && date2 && startDecadeDate1 === startDecadeDate2
        };
        var sameCentury = function(date1, date2) {
            if (!isDefined(date1) || !isDefined(date2)) {
                return
            }
            var startCenturyDate1 = date1.getFullYear() - date1.getFullYear() % 100,
                startCenturyDate2 = date2.getFullYear() - date2.getFullYear() % 100;
            return date1 && date2 && startCenturyDate1 === startCenturyDate2
        };
        var getFirstDecadeInCentury = function(date) {
            return date && date.getFullYear() - date.getFullYear() % 100
        };
        var getFirstYearInDecade = function(date) {
            return date && date.getFullYear() - date.getFullYear() % 10
        };
        var getShortDateFormat = function() {
            return "yyyy/M/d"
        };
        var getFirstMonthDate = function(date) {
            if (!isDefined(date)) {
                return
            }
            var newDate = new Date(date.getFullYear(), date.getMonth(), 1);
            return newDate
        };
        var getLastMonthDate = function(date) {
            if (!isDefined(date)) {
                return
            }
            var newDate = new Date(date.getFullYear(), date.getMonth() + 1, 0);
            return newDate
        };
        var getFirstWeekDate = function(date, firstDayOfWeek) {
            var delta = (date.getDay() - firstDayOfWeek + 7) % 7;
            var result = new Date(date);
            result.setDate(date.getDate() - delta);
            return result
        };
        var normalizeDateByWeek = function(date, currentDate) {
            var differenceInDays = dateUtils.getDatesInterval(date, currentDate, "day"),
                resultDate = new Date(date);
            if (differenceInDays >= 6) {
                resultDate = new Date(resultDate.setDate(resultDate.getDate() + 7))
            }
            return resultDate
        };
        var dateInRange = function(date, min, max, format) {
            if ("date" === format) {
                min = min && new Date(min.getFullYear(), min.getMonth(), min.getDate());
                max = max && new Date(max.getFullYear(), max.getMonth(), max.getDate());
                date = date && new Date(date.getFullYear(), date.getMonth(), date.getDate())
            }
            return normalizeDate(date, min, max) === date
        };
        var normalizeDate = function(date, min, max) {
            var normalizedDate = date;
            if (!isDefined(date)) {
                return date
            }
            if (isDefined(min) && date < min) {
                normalizedDate = min
            }
            if (isDefined(max) && date > max) {
                normalizedDate = max
            }
            return normalizedDate
        };
        var fixTimezoneGap = function(oldDate, newDate) {
            if (!isDefined(oldDate)) {
                return
            }
            var sign, trial, diff = newDate.getHours() - oldDate.getHours();
            if (0 === diff) {
                return
            }
            sign = 1 === diff || diff === -23 ? -1 : 1, trial = new Date(newDate.getTime() + 36e5 * sign);
            if (sign > 0 || trial.getDate() === newDate.getDate()) {
                newDate.setTime(trial.getTime())
            }
        };
        var getTimezonesDifference = function(min, max) {
            return 60 * (max.getTimezoneOffset() - min.getTimezoneOffset()) * 1e3
        };
        var makeDate = function(date) {
            return new Date(date)
        };
        var NUMBER_SERIALIZATION_FORMAT = "number",
            DATE_SERIALIZATION_FORMAT = "yyyy'/'MM'/'dd",
            DATETIME_SERIALIZATION_FORMAT = "yyyy'/'MM'/'dd HH:mm:ss";
        var getDateSerializationFormat = function(value) {
            if (commonUtils.isNumber(value)) {
                return NUMBER_SERIALIZATION_FORMAT
            } else {
                if (commonUtils.isString(value)) {
                    if (value.indexOf(":") >= 0) {
                        return DATETIME_SERIALIZATION_FORMAT
                    } else {
                        return DATE_SERIALIZATION_FORMAT
                    }
                }
            }
        };
        var deserializeDate = function(value, serializationFormat, localizationParseFunc) {
            var parsedValue;
            if (!serializationFormat || serializationFormat === NUMBER_SERIALIZATION_FORMAT || serializationFormat === DATE_SERIALIZATION_FORMAT || serializationFormat === DATETIME_SERIALIZATION_FORMAT) {
                parsedValue = serializationFormat === NUMBER_SERIALIZATION_FORMAT ? value : !isDate(value) && Date.parse(value);
                return parsedValue ? new Date(parsedValue) : value
            }
            if (void 0 !== value) {
                return localizationParseFunc(value, serializationFormat)
            }
        };
        var serializeDate = function(value, serializationFormat, localizationFormatFunc) {
            if (serializationFormat === NUMBER_SERIALIZATION_FORMAT) {
                return value && value.valueOf && value.valueOf()
            }
            if (serializationFormat) {
                return localizationFormatFunc(value, serializationFormat)
            }
            return value
        };
        var dateUtils = {
            dateUnitIntervals: dateUnitIntervals,
            convertMillisecondsToDateUnits: convertMillisecondsToDateUnits,
            dateToMilliseconds: dateToMilliseconds,
            getNextDateUnit: getNextDateUnit,
            convertDateUnitToMilliseconds: convertDateUnitToMilliseconds,
            getDateUnitInterval: getDateUnitInterval,
            getDateFormatByTickInterval: getDateFormatByTickInterval,
            getDatesDifferences: getDatesDifferences,
            correctDateWithUnitBeginning: correctDateWithUnitBeginning,
            trimTime: trimTime,
            addDateInterval: addDateInterval,
            addInterval: addInterval,
            getSequenceByInterval: getSequenceByInterval,
            getDateIntervalByString: getDateIntervalByString,
            sameDate: sameDate,
            sameMonthAndYear: sameMonthAndYear,
            sameMonth: sameMonthAndYear,
            sameYear: sameYear,
            sameDecade: sameDecade,
            sameCentury: sameCentury,
            sameView: sameView,
            getDifferenceInMonth: getDifferenceInMonth,
            getDifferenceInMonthForCells: getDifferenceInMonthForCells,
            getFirstYearInDecade: getFirstYearInDecade,
            getFirstDecadeInCentury: getFirstDecadeInCentury,
            getShortDateFormat: getShortDateFormat,
            getViewFirstCellDate: getViewFirstCellDate,
            getViewLastCellDate: getViewLastCellDate,
            getViewDown: getViewDown,
            getViewUp: getViewUp,
            getLastMonthDay: getLastMonthDay,
            getLastMonthDate: getLastMonthDate,
            getFirstMonthDate: getFirstMonthDate,
            getFirstWeekDate: getFirstWeekDate,
            normalizeDateByWeek: normalizeDateByWeek,
            getQuarter: getQuarter,
            getFirstQuarterMonth: getFirstQuarterMonth,
            dateInRange: dateInRange,
            normalizeDate: normalizeDate,
            getViewMinBoundaryDate: getViewMinBoundaryDate,
            getViewMaxBoundaryDate: getViewMaxBoundaryDate,
            fixTimezoneGap: fixTimezoneGap,
            getTimezonesDifference: getTimezonesDifference,
            makeDate: makeDate,
            deserializeDate: deserializeDate,
            serializeDate: serializeDate,
            getDateSerializationFormat: getDateSerializationFormat,
            getDatesInterval: getDatesInterval
        };
        module.exports = dateUtils
    },
    /*!********************************************************!*\
      !*** ./Scripts/mobile/process_hardware_back_button.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            hardwareBack = $.Callbacks();
        module.exports = function() {
            hardwareBack.fire()
        };
        module.exports.processCallback = hardwareBack
    },
    /*!********************************************!*\
      !*** ./Scripts/mobile/hide_top_overlay.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var hideCallback = function() {
            var callbacks = [];
            return {
                add: function(callback) {
                    var indexOfCallback = $.inArray(callback, callbacks);
                    if (indexOfCallback === -1) {
                        callbacks.push(callback)
                    }
                },
                remove: function(callback) {
                    var indexOfCallback = $.inArray(callback, callbacks);
                    if (indexOfCallback !== -1) {
                        callbacks.splice(indexOfCallback, 1)
                    }
                },
                fire: function() {
                    var callback = callbacks.pop(),
                        result = !!callback;
                    if (result) {
                        callback()
                    }
                    return result
                },
                hasCallback: function() {
                    return callbacks.length > 0
                },
                reset: function() {
                    callbacks = []
                }
            }
        }();
        module.exports = function() {
            return hideCallback.fire()
        };
        module.exports.hideCallback = hideCallback
    },
    /*!**********************************!*\
      !*** ./Scripts/format_helper.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ./core/utils/common */ 14),
            dateUtils = __webpack_require__( /*! ./core/utils/date */ 52),
            numberLocalization = __webpack_require__( /*! ./localization/number */ 22),
            dateLocalization = __webpack_require__( /*! ./localization/date */ 56),
            dependencyInjector = __webpack_require__( /*! ./core/utils/dependency_injector */ 23),
            logger = __webpack_require__( /*! ./core/utils/console */ 12).logger;
        __webpack_require__( /*! ./localization/currency */ 24);
        module.exports = dependencyInjector({
            format: function(value, format, precision) {
                var formatIsValid = commonUtils.isString(format) && "" !== format || $.isPlainObject(format) || commonUtils.isFunction(format),
                    valueIsValid = commonUtils.isNumber(value) || commonUtils.isDate(value);
                if (!formatIsValid || !valueIsValid) {
                    return commonUtils.isDefined(value) ? value.toString() : ""
                }
                if (commonUtils.isFunction(format)) {
                    return format(value)
                }
                if (void 0 !== precision) {
                    logger.warn("Option 'precision' is deprecated. Use field 'precision' of a format object instead.")
                }
                if (commonUtils.isString(format)) {
                    format = {
                        type: format,
                        precision: precision
                    }
                }
                if (commonUtils.isNumber(value)) {
                    return numberLocalization.format(value, format)
                }
                if (commonUtils.isDate(value)) {
                    return dateLocalization.format(value, format)
                }
            },
            getTimeFormat: function(showSecond) {
                if (showSecond) {
                    return dateLocalization.getPatternByFormat("longtime")
                }
                return dateLocalization.getPatternByFormat("shorttime")
            },
            _normalizeFormat: function(format) {
                if (!commonUtils.isArray(format)) {
                    return format
                }
                if (1 === format.length) {
                    return format[0]
                }
                return function(date) {
                    return format.map(function(formatPart) {
                        return dateLocalization.format(date, formatPart)
                    }).join(" ")
                }
            },
            getDateFormatByDifferences: function(dateDifferences) {
                var resultFormat = [];
                if (dateDifferences.millisecond) {
                    resultFormat.push(dateLocalization.getPatternByFormat("millisecond"))
                }
                if (dateDifferences.hour || dateDifferences.minute || dateDifferences.second) {
                    resultFormat.unshift(this.getTimeFormat(dateDifferences.second))
                }
                if (dateDifferences.year && dateDifferences.month && dateDifferences.day) {
                    resultFormat.unshift(dateLocalization.getPatternByFormat("shortdate"));
                    return this._normalizeFormat(resultFormat)
                }
                if (dateDifferences.year && dateDifferences.month) {
                    return dateLocalization.getPatternByFormat("monthandyear")
                }
                if (dateDifferences.year && dateDifferences.quarter) {
                    return dateLocalization.getPatternByFormat("quarterandyear")
                }
                if (dateDifferences.year) {
                    return dateLocalization.getPatternByFormat("year")
                }
                if (dateDifferences.quarter) {
                    return dateLocalization.getPatternByFormat("quarter")
                }
                if (dateDifferences.month && dateDifferences.day) {
                    resultFormat.unshift(dateLocalization.getPatternByFormat("monthandday"));
                    return this._normalizeFormat(resultFormat)
                }
                if (dateDifferences.month) {
                    return dateLocalization.getPatternByFormat("month")
                }
                if (dateDifferences.day) {
                    var dayPattern = dateLocalization.getPatternByFormat("dayofweek") + ", " + dateLocalization.getPatternByFormat("day");
                    resultFormat.unshift(dayPattern);
                    return this._normalizeFormat(resultFormat)
                }
                return this._normalizeFormat(resultFormat)
            },
            getDateFormatByTicks: function(ticks) {
                var resultFormat, maxDif, currentDif, i;
                if (ticks.length > 1) {
                    maxDif = dateUtils.getDatesDifferences(ticks[0], ticks[1]);
                    for (i = 1; i < ticks.length - 1; i++) {
                        currentDif = dateUtils.getDatesDifferences(ticks[i], ticks[i + 1]);
                        if (maxDif.count < currentDif.count) {
                            maxDif = currentDif
                        }
                    }
                } else {
                    maxDif = {
                        year: true,
                        month: true,
                        day: true,
                        hour: ticks[0].getHours() > 0,
                        minute: ticks[0].getMinutes() > 0,
                        second: ticks[0].getSeconds() > 0
                    }
                }
                resultFormat = this.getDateFormatByDifferences(maxDif);
                return resultFormat
            },
            getDateFormatByTickInterval: function(startValue, endValue, tickInterval) {
                var resultFormat, dateDifferences, dateUnitInterval, dateDifferencesConverter = {
                        week: "day"
                    },
                    correctDateDifferences = function(dateDifferences, tickInterval, value) {
                        switch (tickInterval) {
                            case "year":
                            case "quarter":
                                dateDifferences.month = value;
                            case "month":
                                dateDifferences.day = value;
                            case "week":
                            case "day":
                                dateDifferences.hour = value;
                            case "hour":
                                dateDifferences.minute = value;
                            case "minute":
                                dateDifferences.second = value;
                            case "second":
                                dateDifferences.millisecond = value
                        }
                    },
                    correctDifferencesByMaxDate = function(differences, minDate, maxDate) {
                        if (!maxDate.getMilliseconds() && maxDate.getSeconds()) {
                            if (maxDate.getSeconds() - minDate.getSeconds() === 1) {
                                differences.millisecond = true;
                                differences.second = false
                            }
                        } else {
                            if (!maxDate.getSeconds() && maxDate.getMinutes()) {
                                if (maxDate.getMinutes() - minDate.getMinutes() === 1) {
                                    differences.second = true;
                                    differences.minute = false
                                }
                            } else {
                                if (!maxDate.getMinutes() && maxDate.getHours()) {
                                    if (maxDate.getHours() - minDate.getHours() === 1) {
                                        differences.minute = true;
                                        differences.hour = false
                                    }
                                } else {
                                    if (!maxDate.getHours() && maxDate.getDate() > 1) {
                                        if (maxDate.getDate() - minDate.getDate() === 1) {
                                            differences.hour = true;
                                            differences.day = false
                                        }
                                    } else {
                                        if (1 === maxDate.getDate() && maxDate.getMonth()) {
                                            if (maxDate.getMonth() - minDate.getMonth() === 1) {
                                                differences.day = true;
                                                differences.month = false
                                            }
                                        } else {
                                            if (!maxDate.getMonth() && maxDate.getFullYear()) {
                                                if (maxDate.getFullYear() - minDate.getFullYear() === 1) {
                                                    differences.month = true;
                                                    differences.year = false
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    };
                tickInterval = commonUtils.isString(tickInterval) ? tickInterval.toLowerCase() : tickInterval;
                dateDifferences = dateUtils.getDatesDifferences(startValue, endValue);
                if (startValue !== endValue) {
                    correctDifferencesByMaxDate(dateDifferences, startValue > endValue ? endValue : startValue, startValue > endValue ? startValue : endValue)
                }
                dateUnitInterval = dateUtils.getDateUnitInterval(dateDifferences);
                correctDateDifferences(dateDifferences, dateUnitInterval, true);
                dateUnitInterval = dateUtils.getDateUnitInterval(tickInterval || "second");
                correctDateDifferences(dateDifferences, dateUnitInterval, false);
                dateDifferences[dateDifferencesConverter[dateUnitInterval] || dateUnitInterval] = true;
                resultFormat = this.getDateFormatByDifferences(dateDifferences);
                return resultFormat
            }
        })
    },
    /*!**************************************!*\
      !*** ./Scripts/localization/date.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            numberLocalization = __webpack_require__( /*! ./number */ 22),
            dependencyInjector = __webpack_require__( /*! ../core/utils/dependency_injector */ 23),
            errors = __webpack_require__( /*! ../core/errors */ 17);
        __webpack_require__( /*! ./core */ 57);
        var FORMATS_TO_PATTERN_MAP = {
            shortdate: "M/d/y",
            shorttime: "h:mm a",
            longdate: "EEEE, MMMM d, y",
            longtime: "h:mm:ss a",
            monthandday: "MMMM d",
            monthandyear: "MMMM y",
            quarterandyear: "QQQ y",
            day: "d",
            year: "y",
            shortdateshorttime: "M/d/y, h:mm a",
            mediumdatemediumtime: "MMMM d, h:mm a",
            longdatelongtime: "EEEE, MMMM d, y, h:mm:ss a",
            month: "LLLL",
            shortyear: "yy",
            dayofweek: "EEEE",
            quarter: "QQQ",
            hour: "HH",
            minute: "mm",
            second: "ss",
            millisecond: "SSS",
            "datetime-local": "yyyy-MM-ddTHH':'mm':'ss"
        };
        var parseTime = function(text) {
            var now = new Date,
                parts = text.split(" "),
                time = parts[0].split(":"),
                hours = Number(time[0]),
                minutes = Number(time[1]),
                second = Number(time[2]) || 0;
            if (/^pm$/i.test(parts[1])) {
                hours += 12
            }
            return new Date(now.getFullYear(), now.getMonth(), now.getDate(), hours, minutes, second)
        };
        var removeTimezoneOffset = function(date) {
            return new Date(date.valueOf() + 60 * date.getTimezoneOffset() * 1e3)
        };
        var months = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
            days = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
        var ampm = function(date) {
            return date.getHours() >= 12 ? "PM" : "AM"
        };
        var getTwelveHourTimeFormat = function(hours) {
            return hours % 12 || 12
        };
        var formatNumber = function(number, precision) {
            return numberLocalization.format(number, {
                type: "decimal",
                precision: precision
            })
        };
        var FORMATTERS = {
            millisecond: function(date) {
                return formatNumber(date.getMilliseconds(date), 3)
            },
            second: function(date) {
                return formatNumber(date.getSeconds(), 2)
            },
            minute: function(date) {
                return formatNumber(date.getMinutes(), 2)
            },
            h: function(date) {
                return formatNumber(getTwelveHourTimeFormat(date.getHours()), 1)
            },
            hh: function(date) {
                return formatNumber(getTwelveHourTimeFormat(date.getHours()), 2)
            },
            hour: function(date) {
                return formatNumber(date.getHours(), 2)
            },
            day: function(date) {
                return date.getDate()
            },
            dayofweek: function(date) {
                return days[date.getDay()]
            },
            M: function(date) {
                return date.getMonth() + 1
            },
            MM: function(date) {
                return formatNumber(date.getMonth() + 1, 2)
            },
            month: function(date) {
                return months[date.getMonth()]
            },
            year: function(date) {
                return date.getFullYear()
            },
            shortyear: function(date) {
                return String(date.getFullYear()).substr(2, 2)
            },
            shorttime: function(date) {
                return FORMATTERS.h(date) + ":" + FORMATTERS.minute(date) + " " + ampm(date)
            },
            shortdate: function(date) {
                return [FORMATTERS.M(date), FORMATTERS.day(date), FORMATTERS.year(date)].join("/")
            },
            shortdateshorttime: function(date) {
                return [FORMATTERS.shortdate(date), FORMATTERS.shorttime(date)].join(", ")
            },
            mediumdatemediumtime: function(date) {
                return [FORMATTERS.monthandday(date), FORMATTERS.shorttime(date)].join(", ")
            },
            monthandyear: function(date) {
                return [FORMATTERS.month(date), FORMATTERS.year(date)].join(" ")
            },
            monthandday: function(date) {
                return [FORMATTERS.month(date), FORMATTERS.day(date)].join(" ")
            },
            longdate: function(date) {
                return FORMATTERS.dayofweek(date) + ", " + FORMATTERS.month(date) + " " + FORMATTERS.day(date) + ", " + FORMATTERS.year(date)
            },
            longtime: function(date) {
                return [FORMATTERS.h(date), FORMATTERS.minute(date), FORMATTERS.second(date)].join(":") + " " + ampm(date)
            },
            longdatelongtime: function(date) {
                return [FORMATTERS.longdate(date), FORMATTERS.longtime(date)].join(", ")
            },
            d: function(date) {
                return formatNumber(FORMATTERS.day(date), 1)
            },
            dd: function(date) {
                return formatNumber(FORMATTERS.day(date), 2)
            },
            "d MMMM": function(date) {
                return FORMATTERS.day(date) + " " + FORMATTERS.month(date)
            },
            "yyyy/M/d": function(date) {
                return [FORMATTERS.year(date), FORMATTERS.M(date), FORMATTERS.day(date)].join("/")
            },
            "yyyy/MM/dd": function(date) {
                return [FORMATTERS.year(date), FORMATTERS.MM(date), FORMATTERS.dd(date)].join("/")
            },
            "dd.MM.yyyy": function(date) {
                return [FORMATTERS.dd(date), FORMATTERS.MM(date), FORMATTERS.year(date)].join(".")
            },
            "HH:mm": function(date) {
                return [FORMATTERS.hour(date), FORMATTERS.minute(date)].join(":")
            },
            "HH:mm:ss": function(date) {
                return [FORMATTERS["HH:mm"](date), FORMATTERS.second(date)].join(":")
            },
            "h:mm:ss": function(date) {
                return [FORMATTERS.h(date), FORMATTERS.minute(date), FORMATTERS.second(date)].join(":")
            },
            "h:mm:ss:SSS": function(date) {
                return [FORMATTERS.h(date), FORMATTERS.minute(date), FORMATTERS.second(date), FORMATTERS.SSS(date)].join(":")
            },
            "yyyy/MM/dd HH:mm:ss": function(date) {
                return [FORMATTERS["yyyy/MM/dd"](date), FORMATTERS["HH:mm:ss"](date)].join(" ")
            },
            "yyyy-MM-dd hh:mm:ss.SSS a": function(date) {
                return [
                    [FORMATTERS.year(date), FORMATTERS.MM(date), FORMATTERS.dd(date)].join("-"), [FORMATTERS.hh(date), FORMATTERS.minute(date), FORMATTERS.second(date)].join(":") + "." + FORMATTERS.SSS(date), ampm(date)
                ].join(" ")
            },
            "yyyy-MM-dd": function(date) {
                return [FORMATTERS.year(date), FORMATTERS.MM(date), FORMATTERS.dd(date)].join("-")
            },
            yyyyMMddTHHmmss: function(date) {
                return [FORMATTERS.year(date), FORMATTERS.MM(date), FORMATTERS.dd(date), "T", FORMATTERS.hour(date), FORMATTERS.minute(date), FORMATTERS.second(date)].join("")
            },
            "datetime-local": function(date) {
                return FORMATTERS["yyyy-MM-dd"](date) + "T" + FORMATTERS["HH:mm:ss"](date)
            },
            "yyyy-MM-ddTHH:mm:ssZ": function(date) {
                return FORMATTERS["datetime-local"](date) + "Z"
            },
            "yyyy-MM-ddTHH:mmZ": function(date) {
                return FORMATTERS["yyyy-MM-dd"](date) + "T" + FORMATTERS.hour(date) + ":" + FORMATTERS.minute(date) + "Z"
            },
            "dd/MM/yyyy": function(date) {
                return [FORMATTERS.dd(date), FORMATTERS.MM(date), FORMATTERS.year(date)].join("/")
            },
            "yyyy MMMM d": function(date) {
                return [FORMATTERS.year(date), FORMATTERS.month(date), FORMATTERS.day(date)].join(" ")
            },
            "EEEE, d": function(date) {
                return [FORMATTERS.dayofweek(date), FORMATTERS.d(date)].join(", ")
            },
            "EEEE MM yy": function(date) {
                return [FORMATTERS.dayofweek(date), FORMATTERS.MM(date), FORMATTERS.shortyear(date)].join(" ")
            },
            "d MMMM yyyy": function(date) {
                return [FORMATTERS.day(date), FORMATTERS.month(date), FORMATTERS.year(date)].join(" ")
            },
            "E d": function(date) {
                return FORMATTERS.E(date) + " " + FORMATTERS.day(date)
            },
            E: function(date) {
                return cutCaptions([FORMATTERS.dayofweek(date)], "abbreviated")[0]
            },
            EEE: function(date) {
                return FORMATTERS.E(date)
            },
            "EEE hh": function(date) {
                return [FORMATTERS.EEE(date), FORMATTERS.hh(date)].join(" ")
            },
            "ss SSS": function(date) {
                return [FORMATTERS.second(date), FORMATTERS.SSS(date)].join(" ")
            },
            quarter: function(date) {
                var month = date.getMonth();
                if (month >= 0 && month < 3) {
                    return "Q1"
                }
                if (month > 2 && month < 6) {
                    return "Q2"
                }
                if (month > 5 && month < 9) {
                    return "Q3"
                }
                return "Q4"
            },
            quarterandyear: function(date) {
                return FORMATTERS.quarter(date) + " " + FORMATTERS.year(date)
            }
        };
        var parseWithoutTimezone = function(text) {
            if ("Z" !== text.slice(-1)) {
                text += "Z"
            }
            return removeTimezoneOffset(new Date(text))
        };
        var PARSERS = {
            day: function(text) {
                var now = new Date;
                return new Date(now.getFullYear(), now.getMonth(), Number(text))
            },
            hour: function(text) {
                var now = new Date;
                return new Date(now.getFullYear(), now.getMonth(), now.getDate(), Number(text))
            },
            minute: function(text) {
                var now = new Date;
                return new Date(now.getFullYear(), now.getMonth(), now.getDate(), now.getHours(), Number(text))
            },
            month: function(text) {
                return new Date((new Date).getFullYear(), $.inArray(text, months))
            },
            monthandday: function(text) {
                var parts = text.split(" "),
                    ret = PARSERS.month(parts[0]);
                ret.setDate(Number(parts[1]));
                return ret
            },
            monthandyear: function(text) {
                var parts = text.split(" "),
                    ret = PARSERS.month(parts[0]);
                ret.setYear(Number(parts[1]));
                return ret
            },
            year: function(text) {
                var date = new Date(new Date(0));
                date.setUTCFullYear(Number(text));
                return removeTimezoneOffset(date)
            },
            shortyear: function(text) {
                var MAX_YEAR_IN_XXI_CENTURY = 36;
                var year = Number(text);
                if (year > MAX_YEAR_IN_XXI_CENTURY) {
                    year += 1900
                } else {
                    year += 2e3
                }
                return PARSERS.year(year)
            },
            shortdate: function(text) {
                var parts = text.split("/");
                if (3 !== parts.length) {
                    return
                }
                return new Date(Number(parts[2]), Number(parts[0]) - 1, Number(parts[1]))
            },
            longtime: function(text) {
                return parseTime(text)
            },
            shorttime: function(text) {
                return parseTime(text)
            },
            millisecond: function(text) {
                return new Date(Number(text))
            },
            "yyyy MMMM d": function(text) {
                var parts = text.split(" ");
                if (3 !== parts.length) {
                    return
                }
                return new Date(Number(parts[0]), $.inArray(parts[1], months), Number(parts[2]))
            },
            "HH:mm": function(text) {
                var parts = text.split(":");
                return new Date(0, 0, 0, Number(parts[0]), Number(parts[1]), 0, 0)
            },
            "yyyy-MM-ddTHH:mm:ssZ": parseWithoutTimezone,
            "yyyy-MM-ddTHH:mmZ": parseWithoutTimezone,
            "datetime-local": parseWithoutTimezone,
            mediumdatemediumtime: function(text) {
                var parts = text.split(", "),
                    dateParts = parts[0].split(" "),
                    timeParts = parts[1].split(" ");
                var ampm = 2 === timeParts.length ? timeParts.pop() : void 0;
                var ret = PARSERS.month(dateParts[0]);
                ret.setDate(Number(dateParts[1]));
                timeParts = timeParts[0].split(":");
                var hours = Number(timeParts[0]);
                switch (String(ampm).toLowerCase()) {
                    case "am":
                        hours = 12 === hours ? 0 : hours;
                        break;
                    case "pm":
                        hours = 12 === hours ? 12 : hours + 12
                }
                ret.setHours(hours);
                ret.setMinutes(Number(timeParts[1]));
                return ret
            }
        };
        $.each(FORMATS_TO_PATTERN_MAP, function(key, value) {
            value = value.replace(/'/g, "");
            FORMATTERS[value] = FORMATTERS[key];
            PARSERS[value] = PARSERS[key]
        });
        var getByFormat = function(obj, format) {
            return obj[format.toLowerCase()] || obj[format.replace(/'/g, "")]
        };
        var cutCaptions = function(captions, format) {
            var lengthByFormat = {
                abbreviated: 3,
                "short": 2,
                narrow: 1
            };
            return $.map(captions, function(caption) {
                return caption.substr(0, lengthByFormat[format])
            })
        };
        var dateLocalization = dependencyInjector({
            getPatternByFormat: function(format) {
                return FORMATS_TO_PATTERN_MAP[format.toLowerCase()]
            },
            getMonthNames: function(format) {
                return cutCaptions(months, format)
            },
            getDayNames: function(format) {
                return cutCaptions(days, format)
            },
            getTimeSeparator: function() {
                return ":"
            },
            format: function(date, format) {
                if (!date) {
                    return
                }
                if (!format) {
                    return date
                }
                var formatter;
                if ("function" === typeof format) {
                    formatter = format
                } else {
                    if (format.formatter) {
                        formatter = format.formatter
                    } else {
                        format = format.type || format;
                        formatter = getByFormat(FORMATTERS, format)
                    }
                }
                if (!formatter) {
                    return
                }
                return formatter(date)
            },
            parse: function(text, format) {
                var result, parser;
                if (!text) {
                    return
                }
                if (!format) {
                    return new Date(text)
                }
                if (format.parser) {
                    return format.parser(text)
                }
                if (format.type || format.formatter) {
                    format = format.type
                }
                if (format && "function" !== typeof format) {
                    parser = getByFormat(PARSERS, format)
                }
                if (parser) {
                    result = parser(text)
                } else {
                    errors.log("W0012");
                    result = new Date(text)
                }
                if (!result || isNaN(result.getTime())) {
                    return
                }
                return result
            },
            firstDayOfWeekIndex: function() {
                return 0
            }
        });
        module.exports = dateLocalization
    },
    /*!**************************************!*\
      !*** ./Scripts/localization/core.js ***!
      \**************************************/
    function(module, exports) {},
    /*!**********************************************!*\
      !*** ./Scripts/animation/presets/presets.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Component = __webpack_require__( /*! ../../core/component */ 34),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            fx = __webpack_require__( /*! ../fx */ 59);
        var directionPostfixes = {
            forward: " dx-forward",
            backward: " dx-backward",
            none: " dx-no-direction",
            undefined: " dx-no-direction"
        };
        var optionPrefix = "preset_";
        var AnimationPresetCollection = Component.inherit({
            ctor: function() {
                this.callBase.apply(this, arguments);
                this._customRules = [];
                this._registeredPresets = [];
                this.resetToDefaults()
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    defaultAnimationDuration: 400,
                    defaultAnimationDelay: 0,
                    defaultStaggerAnimationDuration: 300,
                    defaultStaggerAnimationDelay: 40,
                    defaultStaggerAnimationStartDelay: 500
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return device.phone
                    },
                    options: {
                        defaultStaggerAnimationDuration: 350,
                        defaultStaggerAnimationDelay: 50,
                        defaultStaggerAnimationStartDelay: 0
                    }
                }, {
                    device: function() {
                        return devices.current().android || devices.real.android
                    },
                    options: {
                        defaultAnimationDelay: 100
                    }
                }])
            },
            _getPresetOptionName: function(animationName) {
                return optionPrefix + animationName
            },
            _createAndroidSlideAnimationConfig: function(throughOpacity, widthMultiplier) {
                var that = this;
                var createBaseConfig = function(configModifier) {
                    return {
                        type: "slide",
                        delay: void 0 === configModifier.delay ? that.option("defaultAnimationDelay") : configModifier.delay,
                        duration: void 0 === configModifier.duration ? that.option("defaultAnimationDuration") : configModifier.duration
                    }
                };
                return {
                    enter: function($element, configModifier) {
                        var width = $element.parent().width() * widthMultiplier,
                            direction = configModifier.direction,
                            config = createBaseConfig(configModifier);
                        config.to = {
                            left: 0,
                            opacity: 1
                        };
                        if ("forward" === direction) {
                            config.from = {
                                left: width,
                                opacity: throughOpacity
                            }
                        } else {
                            if ("backward" === direction) {
                                config.from = {
                                    left: -width,
                                    opacity: throughOpacity
                                }
                            } else {
                                config.from = {
                                    left: 0,
                                    opacity: 0
                                }
                            }
                        }
                        return fx.createAnimation($element, config)
                    },
                    leave: function($element, configModifier) {
                        var width = $element.parent().width() * widthMultiplier,
                            direction = configModifier.direction,
                            config = createBaseConfig(configModifier);
                        config.from = {
                            left: 0,
                            opacity: 1
                        };
                        if ("forward" === direction) {
                            config.to = {
                                left: -width,
                                opacity: throughOpacity
                            }
                        } else {
                            if ("backward" === direction) {
                                config.to = {
                                    left: width,
                                    opacity: throughOpacity
                                }
                            } else {
                                config.to = {
                                    left: 0,
                                    opacity: 0
                                }
                            }
                        }
                        return fx.createAnimation($element, config)
                    }
                }
            },
            _createOpenDoorConfig: function() {
                var that = this;
                var createBaseConfig = function(configModifier) {
                    return {
                        type: "css",
                        extraCssClasses: "dx-opendoor-animation",
                        delay: void 0 === configModifier.delay ? that.option("defaultAnimationDelay") : configModifier.delay,
                        duration: void 0 === configModifier.duration ? that.option("defaultAnimationDuration") : configModifier.duration
                    }
                };
                return {
                    enter: function($element, configModifier) {
                        var direction = configModifier.direction,
                            config = createBaseConfig(configModifier);
                        config.delay = "none" === direction ? config.delay : config.duration;
                        config.from = "dx-enter dx-opendoor-animation" + directionPostfixes[direction];
                        config.to = "dx-enter-active";
                        return fx.createAnimation($element, config)
                    },
                    leave: function($element, configModifier) {
                        var direction = configModifier.direction,
                            config = createBaseConfig(configModifier);
                        config.from = "dx-leave dx-opendoor-animation" + directionPostfixes[direction];
                        config.to = "dx-leave-active";
                        return fx.createAnimation($element, config)
                    }
                }
            },
            _createWinPopConfig: function() {
                var that = this,
                    baseConfig = {
                        type: "css",
                        extraCssClasses: "dx-win-pop-animation",
                        duration: that.option("defaultAnimationDuration")
                    };
                return {
                    enter: function($element, configModifier) {
                        var config = baseConfig,
                            direction = configModifier.direction;
                        config.delay = "none" === direction ? that.option("defaultAnimationDelay") : that.option("defaultAnimationDuration") / 2;
                        config.from = "dx-enter dx-win-pop-animation" + directionPostfixes[direction];
                        config.to = "dx-enter-active";
                        return fx.createAnimation($element, config)
                    },
                    leave: function($element, configModifier) {
                        var config = baseConfig,
                            direction = configModifier.direction;
                        config.delay = that.option("defaultAnimationDelay");
                        config.from = "dx-leave dx-win-pop-animation" + directionPostfixes[direction];
                        config.to = "dx-leave-active";
                        return fx.createAnimation($element, config)
                    }
                }
            },
            resetToDefaults: function() {
                this.clear();
                this.registerDefaultPresets();
                this.applyChanges()
            },
            clear: function(name) {
                var that = this,
                    newRegisteredPresets = [];
                $.each(this._registeredPresets, function(index, preset) {
                    if (!name || name === preset.name) {
                        that.option(that._getPresetOptionName(preset.name), void 0)
                    } else {
                        newRegisteredPresets.push(preset)
                    }
                });
                this._registeredPresets = newRegisteredPresets;
                this.applyChanges()
            },
            registerPreset: function(name, config) {
                this._registeredPresets.push({
                    name: name,
                    config: config
                })
            },
            applyChanges: function() {
                var that = this;
                this._customRules.length = 0;
                $.each(this._registeredPresets, function(index, preset) {
                    var rule = {
                        device: preset.config.device,
                        options: {}
                    };
                    rule.options[that._getPresetOptionName(preset.name)] = preset.config.animation;
                    that._customRules.push(rule)
                });
                this._setOptionsByDevice()
            },
            getPreset: function(name) {
                var result = name;
                while ("string" === typeof result) {
                    result = this.option(this._getPresetOptionName(result))
                }
                return result
            },
            registerDefaultPresets: function() {
                this.registerPreset("pop", {
                    animation: {
                        extraCssClasses: "dx-android-pop-animation",
                        delay: this.option("defaultAnimationDelay"),
                        duration: this.option("defaultAnimationDuration")
                    }
                });
                this.registerPreset("openDoor", {
                    animation: this._createOpenDoorConfig()
                });
                this.registerPreset("win-pop", {
                    animation: this._createWinPopConfig()
                });
                this.registerPreset("fade", {
                    animation: {
                        extraCssClasses: "dx-fade-animation",
                        delay: this.option("defaultAnimationDelay"),
                        duration: this.option("defaultAnimationDuration")
                    }
                });
                this.registerPreset("slide", {
                    device: function() {
                        return devices.current().android || devices.real.android
                    },
                    animation: this._createAndroidSlideAnimationConfig(1, 1)
                });
                this.registerPreset("slide", {
                    device: function() {
                        return !devices.current().android && !devices.real.android
                    },
                    animation: {
                        extraCssClasses: "dx-slide-animation",
                        delay: this.option("defaultAnimationDelay"),
                        duration: this.option("defaultAnimationDuration")
                    }
                });
                this.registerPreset("ios7-slide", {
                    animation: {
                        extraCssClasses: "dx-ios7-slide-animation",
                        delay: this.option("defaultAnimationDelay"),
                        duration: this.option("defaultAnimationDuration")
                    }
                });
                this.registerPreset("overflow", {
                    animation: {
                        extraCssClasses: "dx-overflow-animation",
                        delay: this.option("defaultAnimationDelay"),
                        duration: this.option("defaultAnimationDuration")
                    }
                });
                this.registerPreset("ios7-toolbar", {
                    device: function() {
                        return !devices.current().android && !devices.real.android
                    },
                    animation: {
                        extraCssClasses: "dx-ios7-toolbar-animation",
                        delay: this.option("defaultAnimationDelay"),
                        duration: this.option("defaultAnimationDuration")
                    }
                });
                this.registerPreset("ios7-toolbar", {
                    device: function() {
                        return devices.current().android || devices.real.android
                    },
                    animation: this._createAndroidSlideAnimationConfig(0, .4)
                });
                this.registerPreset("stagger-fade", {
                    animation: {
                        extraCssClasses: "dx-fade-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                });
                this.registerPreset("stagger-slide", {
                    animation: {
                        extraCssClasses: "dx-slide-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                });
                this.registerPreset("stagger-fade-slide", {
                    animation: {
                        extraCssClasses: "dx-fade-slide-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                });
                this.registerPreset("stagger-drop", {
                    animation: {
                        extraCssClasses: "dx-drop-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                });
                this.registerPreset("stagger-fade-drop", {
                    animation: {
                        extraCssClasses: "dx-fade-drop-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                });
                this.registerPreset("stagger-fade-rise", {
                    animation: {
                        extraCssClasses: "dx-fade-rise-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                });
                this.registerPreset("stagger-3d-drop", {
                    animation: {
                        extraCssClasses: "dx-3d-drop-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                });
                this.registerPreset("stagger-fade-zoom", {
                    animation: {
                        extraCssClasses: "dx-fade-zoom-animation",
                        staggerDelay: this.option("defaultStaggerAnimationDelay"),
                        duration: this.option("defaultStaggerAnimationDuration"),
                        delay: this.option("defaultStaggerAnimationStartDelay")
                    }
                })
            }
        });
        exports.PresetCollection = AnimationPresetCollection;
        var animationPresets = new AnimationPresetCollection;
        exports.presets = animationPresets
    },
    /*!*********************************!*\
      !*** ./Scripts/animation/fx.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../core/errors */ 17),
            translator = __webpack_require__( /*! ./translator */ 60),
            animationFrame = __webpack_require__( /*! ./frame */ 46),
            support = __webpack_require__( /*! ../core/utils/support */ 48),
            positionUtils = __webpack_require__( /*! ./position */ 61),
            removeEvent = __webpack_require__( /*! ../core/remove_event */ 33),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            transitionEndEventName = support.transitionEndEventName + ".dxFX",
            removeEventName = eventUtils.addNamespace(removeEvent, "dxFX");
        var CSS_TRANSITION_EASING_REGEX = /cubic-bezier\((\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\)/,
            RELATIVE_VALUE_REGEX = /^([+-])=(.*)/i,
            ANIM_DATA_KEY = "dxAnimData",
            ANIM_QUEUE_KEY = "dxAnimQueue",
            TRANSFORM_PROP = "transform";
        var TransitionAnimationStrategy = {
            initAnimation: function($element, config) {
                $element.css({
                    transitionProperty: "none"
                });
                if ("string" === typeof config.from) {
                    $element.addClass(config.from)
                } else {
                    setProps($element, config.from)
                }
                var that = this,
                    deferred = $.Deferred(),
                    cleanupWhen = config.cleanupWhen;
                config.transitionAnimation = {
                    deferred: deferred,
                    finish: function() {
                        that._finishTransition($element, config);
                        if (cleanupWhen) {
                            $.when(deferred, cleanupWhen).always(function() {
                                that._cleanup($element, config)
                            })
                        } else {
                            that._cleanup($element, config)
                        }
                        deferred.resolveWith($element, [config, $element])
                    }
                };
                this._completeAnimationCallback($element, config).done(function() {
                    config.transitionAnimation.finish()
                }).fail(function() {
                    deferred.rejectWith($element, [config, $element])
                });
                if (!config.duration) {
                    config.transitionAnimation.finish()
                }
                $element.css("transform")
            },
            animate: function($element, config) {
                this._startAnimation($element, config);
                return config.transitionAnimation.deferred.promise()
            },
            _completeAnimationCallback: function($element, config) {
                var simulatedEndEventTimer, waitForJSCompleteTimer, that = this,
                    startTime = $.now() + config.delay,
                    deferred = $.Deferred(),
                    transitionEndFired = $.Deferred(),
                    simulatedTransitionEndFired = $.Deferred();
                config.transitionAnimation.cleanup = function() {
                    clearTimeout(simulatedEndEventTimer);
                    clearTimeout(waitForJSCompleteTimer);
                    $element.off(transitionEndEventName);
                    $element.off(removeEventName)
                };
                $element.one(transitionEndEventName, function() {
                    if ($.now() - startTime >= config.duration) {
                        transitionEndFired.reject()
                    }
                }).off(removeEventName).on(removeEventName, function() {
                    that.stop($element, config);
                    deferred.reject()
                });
                waitForJSCompleteTimer = setTimeout(function() {
                    simulatedEndEventTimer = setTimeout(function() {
                        simulatedTransitionEndFired.reject()
                    }, config.duration + config.delay + fx._simulatedTransitionEndDelay);
                    $.when(transitionEndFired, simulatedTransitionEndFired).fail($.proxy(function() {
                        deferred.resolve()
                    }, this))
                });
                return deferred.promise()
            },
            _startAnimation: function($element, config) {
                $element.css({
                    transitionProperty: "all",
                    transitionDelay: config.delay + "ms",
                    transitionDuration: config.duration + "ms",
                    transitionTimingFunction: config.easing
                });
                if ("string" === typeof config.to) {
                    $element[0].className += " " + config.to
                } else {
                    if (config.to) {
                        setProps($element, config.to)
                    }
                }
            },
            _finishTransition: function($element, config) {
                $element.css("transition", "none")
            },
            _cleanup: function($element, config) {
                config.transitionAnimation.cleanup();
                if ("string" === typeof config.from) {
                    $element.removeClass(config.from);
                    $element.removeClass(config.to)
                }
            },
            stop: function($element, config, jumpToEnd) {
                if (!config) {
                    return
                }
                if (jumpToEnd) {
                    config.transitionAnimation.finish()
                } else {
                    if ($.isPlainObject(config.to)) {
                        $.each(config.to, function(key) {
                            $element.css(key, $element.css(key))
                        })
                    }
                    this._finishTransition($element, config);
                    this._cleanup($element, config)
                }
            }
        };
        var FrameAnimationStrategy = {
            initAnimation: function($element, config) {
                setProps($element, config.from)
            },
            animate: function($element, config) {
                var deferred = $.Deferred(),
                    that = this;
                if (!config) {
                    return deferred.reject().promise()
                }
                $.each(config.to, function(prop) {
                    if (void 0 === config.from[prop]) {
                        config.from[prop] = that._normalizeValue($element.css(prop))
                    }
                });
                if (config.to[TRANSFORM_PROP]) {
                    config.from[TRANSFORM_PROP] = that._parseTransform(config.from[TRANSFORM_PROP]);
                    config.to[TRANSFORM_PROP] = that._parseTransform(config.to[TRANSFORM_PROP])
                }
                config.frameAnimation = {
                    to: config.to,
                    from: config.from,
                    currentValue: config.from,
                    easing: convertTransitionTimingFuncToJQueryEasing(config.easing),
                    duration: config.duration,
                    startTime: (new Date).valueOf(),
                    finish: function() {
                        this.currentValue = this.to;
                        this.draw();
                        animationFrame.cancelAnimationFrame(config.frameAnimation.animationFrameId);
                        deferred.resolve()
                    },
                    draw: function() {
                        if (config.draw) {
                            config.draw(this.currentValue);
                            return
                        }
                        var currentValue = $.extend({}, this.currentValue);
                        if (currentValue[TRANSFORM_PROP]) {
                            currentValue[TRANSFORM_PROP] = $.map(currentValue[TRANSFORM_PROP], function(value, prop) {
                                if ("translate" === prop) {
                                    return translator.getTranslateCss(value)
                                } else {
                                    if ("scale" === prop) {
                                        return "scale(" + value + ")"
                                    } else {
                                        if ("rotate" === prop.substr(0, prop.length - 1)) {
                                            return prop + "(" + value + "deg)"
                                        }
                                    }
                                }
                            }).join(" ")
                        }
                        $element.css(currentValue)
                    }
                };
                if (config.delay) {
                    config.frameAnimation.startTime += config.delay;
                    config.frameAnimation.delayTimeout = setTimeout(function() {
                        that._startAnimation($element, config)
                    }, config.delay)
                } else {
                    that._startAnimation($element, config)
                }
                return deferred.promise()
            },
            _startAnimation: function($element, config) {
                $element.off(removeEventName).on(removeEventName, function() {
                    if (config.frameAnimation) {
                        animationFrame.cancelAnimationFrame(config.frameAnimation.animationFrameId)
                    }
                });
                this._animationStep($element, config)
            },
            _parseTransform: function(transformString) {
                var result = {};
                $.each(transformString.match(/(\w|\d)+\([^\)]*\)\s*/g), function(i, part) {
                    var translateData = translator.parseTranslate(part),
                        scaleData = part.match(/scale\((.+?)\)/),
                        rotateData = part.match(/(rotate.)\((.+)deg\)/);
                    if (translateData) {
                        result.translate = translateData
                    }
                    if (scaleData && scaleData[1]) {
                        result.scale = parseFloat(scaleData[1])
                    }
                    if (rotateData && rotateData[1]) {
                        result[rotateData[1]] = parseFloat(rotateData[2])
                    }
                });
                return result
            },
            stop: function($element, config, jumpToEnd) {
                var frameAnimation = config && config.frameAnimation;
                if (!frameAnimation) {
                    return
                }
                animationFrame.cancelAnimationFrame(frameAnimation.animationFrameId);
                clearTimeout(frameAnimation.delayTimeout);
                if (jumpToEnd) {
                    frameAnimation.finish()
                }
                delete config.frameAnimation
            },
            _animationStep: function($element, config) {
                var frameAnimation = config && config.frameAnimation;
                if (!frameAnimation) {
                    return
                }
                var now = (new Date).valueOf();
                if (now >= frameAnimation.startTime + frameAnimation.duration) {
                    frameAnimation.finish();
                    return
                }
                frameAnimation.currentValue = this._calcStepValue(frameAnimation, now - frameAnimation.startTime);
                frameAnimation.draw();
                var that = this;
                frameAnimation.animationFrameId = animationFrame.requestAnimationFrame(function() {
                    that._animationStep($element, config)
                })
            },
            _calcStepValue: function(frameAnimation, currentDuration) {
                var calcValueRecursively = function(from, to) {
                    var result = $.isArray(to) ? [] : {};
                    var calcEasedValue = function(propName) {
                        var x = currentDuration / frameAnimation.duration,
                            t = currentDuration,
                            b = 1 * from[propName],
                            c = to[propName] - from[propName],
                            d = frameAnimation.duration;
                        return $.easing[frameAnimation.easing](x, t, b, c, d)
                    };
                    $.each(to, function(propName, endPropValue) {
                        if ("string" === typeof endPropValue && false === parseFloat(endPropValue, 10)) {
                            return true
                        }
                        result[propName] = "object" === typeof endPropValue ? calcValueRecursively(from[propName], endPropValue) : calcEasedValue(propName)
                    });
                    return result
                };
                return calcValueRecursively(frameAnimation.from, frameAnimation.to)
            },
            _normalizeValue: function(value) {
                var numericValue = parseFloat(value, 10);
                if (false === numericValue) {
                    return value
                }
                return numericValue
            }
        };
        var FallbackToNoAnimationStrategy = {
            initAnimation: function($element, config) {},
            animate: function($element, config) {
                return $.Deferred().resolve().promise()
            },
            stop: $.noop,
            isSynchronous: true
        };
        var animationStrategies = {
            transition: support.transition ? TransitionAnimationStrategy : FrameAnimationStrategy,
            frame: FrameAnimationStrategy,
            noAnimation: FallbackToNoAnimationStrategy
        };
        var getAnimationStrategy = function(config) {
            config = config || {};
            var strategy = config.strategy || "transition";
            if ("css" === config.type && !support.transition) {
                strategy = "noAnimation"
            }
            return animationStrategies[strategy]
        };
        var TransitionTimingFuncMap = {
            linear: "cubic-bezier(0, 0, 1, 1)",
            ease: "cubic-bezier(0.25, 0.1, 0.25, 1)",
            "ease-in": "cubic-bezier(0.42, 0, 1, 1)",
            "ease-out": "cubic-bezier(0, 0, 0.58, 1)",
            "ease-in-out": "cubic-bezier(0.42, 0, 0.58, 1)"
        };
        var convertTransitionTimingFuncToJQueryEasing = function(cssTransitionEasing) {
            cssTransitionEasing = TransitionTimingFuncMap[cssTransitionEasing] || cssTransitionEasing;
            var bezCoeffs = cssTransitionEasing.match(CSS_TRANSITION_EASING_REGEX);
            if (!bezCoeffs) {
                return "linear"
            }
            bezCoeffs = bezCoeffs.slice(1, 5);
            $.each(bezCoeffs, function(index, value) {
                bezCoeffs[index] = parseFloat(value)
            });
            var easingName = "cubicbezier_" + bezCoeffs.join("_").replace(/\./g, "p");
            if (!$.isFunction($.easing[easingName])) {
                var polynomBezier = function(x1, y1, x2, y2) {
                    var Cx = 3 * x1,
                        Bx = 3 * (x2 - x1) - Cx,
                        Ax = 1 - Cx - Bx,
                        Cy = 3 * y1,
                        By = 3 * (y2 - y1) - Cy,
                        Ay = 1 - Cy - By;
                    var bezierX = function(t) {
                        return t * (Cx + t * (Bx + t * Ax))
                    };
                    var bezierY = function(t) {
                        return t * (Cy + t * (By + t * Ay))
                    };
                    var findXfor = function(t) {
                        var z, x = t,
                            i = 0;
                        while (i < 14) {
                            z = bezierX(x) - t;
                            if (Math.abs(z) < .001) {
                                break
                            }
                            x -= z / derivativeX(x);
                            i++
                        }
                        return x
                    };
                    var derivativeX = function(t) {
                        return Cx + t * (2 * Bx + 3 * t * Ax)
                    };
                    return function(t) {
                        return bezierY(findXfor(t))
                    }
                };
                $.easing[easingName] = function(x, t, b, c, d) {
                    return c * polynomBezier(bezCoeffs[0], bezCoeffs[1], bezCoeffs[2], bezCoeffs[3])(t / d) + b
                }
            }
            return easingName
        };
        var baseConfigValidator = function(config, animationType, validate, typeMessage) {
            $.each(["from", "to"], function() {
                if (!validate(config[this])) {
                    throw errors.Error("E0010", animationType, this, typeMessage)
                }
            })
        };
        var isObjectConfigValidator = function(config, animationType) {
            return baseConfigValidator(config, animationType, function(target) {
                return $.isPlainObject(target)
            }, "a plain object")
        };
        var isStringConfigValidator = function(config, animationType) {
            return baseConfigValidator(config, animationType, function(target) {
                return "string" === typeof target
            }, "a string")
        };
        var CustomAnimationConfigurator = {
            setup: function($element, config) {}
        };
        var CssAnimationConfigurator = {
            validateConfig: function(config) {
                isStringConfigValidator(config, "css")
            },
            setup: function($element, config) {}
        };
        var positionAliases = {
            top: {
                my: "bottom center",
                at: "top center"
            },
            bottom: {
                my: "top center",
                at: "bottom center"
            },
            right: {
                my: "left center",
                at: "right center"
            },
            left: {
                my: "right center",
                at: "left center"
            }
        };
        var SlideAnimationConfigurator = {
            validateConfig: function(config) {
                isObjectConfigValidator(config, "slide")
            },
            setup: function($element, config) {
                var location = translator.locate($element);
                if ("slide" !== config.type) {
                    var positioningConfig = "slideIn" === config.type ? config.from : config.to;
                    positioningConfig.position = $.extend({
                        of: window
                    }, positionAliases[config.direction]);
                    setupPosition($element, positioningConfig)
                }
                this._setUpConfig(location, config.from);
                this._setUpConfig(location, config.to);
                translator.clearCache($element);
                if (!support.transform && "static" === $element.css("position")) {
                    $element.css("position", "relative")
                }
            },
            _setUpConfig: function(location, config) {
                config.left = "left" in config ? config.left : "+=0";
                config.top = "top" in config ? config.top : "+=0";
                this._initNewPosition(location, config)
            },
            _initNewPosition: function(location, config) {
                var position = {
                    left: config.left,
                    top: config.top
                };
                delete config.left;
                delete config.top;
                var relativeValue = this._getRelativeValue(position.left);
                if (void 0 !== relativeValue) {
                    position.left = relativeValue + location.left
                } else {
                    config.left = 0
                }
                relativeValue = this._getRelativeValue(position.top);
                if (void 0 !== relativeValue) {
                    position.top = relativeValue + location.top
                } else {
                    config.top = 0
                }
                var translate = {
                    x: 0,
                    y: 0
                };
                if (support.transform) {
                    translate = {
                        x: position.left,
                        y: position.top
                    }
                } else {
                    config.left = position.left;
                    config.top = position.top
                }
                config[TRANSFORM_PROP] = translator.getTranslateCss(translate)
            },
            _getRelativeValue: function(value) {
                var relativeValue;
                if ("string" === typeof value && (relativeValue = RELATIVE_VALUE_REGEX.exec(value))) {
                    return parseInt(relativeValue[1] + "1") * relativeValue[2]
                }
            }
        };
        var FadeAnimationConfigurator = {
            setup: function($element, config) {
                var toOpacity, from = config.from,
                    fromOpacity = $.isPlainObject(from) ? config.skipElementInitialStyles ? 0 : $element.css("opacity") : String(from);
                switch (config.type) {
                    case "fadeIn":
                        toOpacity = 1;
                        break;
                    case "fadeOut":
                        toOpacity = 0;
                        break;
                    default:
                        toOpacity = String(config.to)
                }
                config.from = {
                    visibility: "visible",
                    opacity: fromOpacity
                };
                config.to = {
                    opacity: toOpacity
                }
            }
        };
        var PopAnimationConfigurator = {
            validateConfig: function(config) {
                isObjectConfigValidator(config, "pop")
            },
            setup: function($element, config) {
                var from = config.from,
                    to = config.to,
                    fromOpacity = "opacity" in from ? from.opacity : $element.css("opacity"),
                    toOpacity = "opacity" in to ? to.opacity : 1,
                    fromScale = "scale" in from ? from.scale : 0,
                    toScale = "scale" in to ? to.scale : 1;
                config.from = {
                    opacity: fromOpacity
                };
                var translate = translator.getTranslate($element);
                config.from[TRANSFORM_PROP] = this._getCssTransform(translate, fromScale);
                config.to = {
                    opacity: toOpacity
                };
                config.to[TRANSFORM_PROP] = this._getCssTransform(translate, toScale)
            },
            _getCssTransform: function(translate, scale) {
                return translator.getTranslateCss(translate) + "scale(" + scale + ")"
            }
        };
        var animationConfigurators = {
            custom: CustomAnimationConfigurator,
            slide: SlideAnimationConfigurator,
            slideIn: SlideAnimationConfigurator,
            slideOut: SlideAnimationConfigurator,
            fade: FadeAnimationConfigurator,
            fadeIn: FadeAnimationConfigurator,
            fadeOut: FadeAnimationConfigurator,
            pop: PopAnimationConfigurator,
            css: CssAnimationConfigurator
        };
        var getAnimationConfigurator = function(config) {
            var result = animationConfigurators[config.type];
            if (!result) {
                throw errors.Error("E0011", config.type)
            }
            return result
        };
        var defaultJSConfig = {
                type: "custom",
                from: {},
                to: {},
                duration: 400,
                start: $.noop,
                complete: $.noop,
                easing: "ease",
                delay: 0
            },
            defaultCssConfig = {
                duration: 400,
                easing: "ease",
                delay: 0
            };
        var setupAnimationOnElement = function() {
            var animation = this,
                $element = animation.element,
                config = animation.config;
            setupPosition($element, config.from);
            setupPosition($element, config.to);
            animation.configurator.setup($element, config);
            $element.data(ANIM_DATA_KEY, animation);
            if (fx.off) {
                config.duration = 0;
                config.delay = 0
            }
            animation.strategy.initAnimation($element, config);
            if (config.start) {
                config.start.apply(this, [$element, config])
            }
        };
        var onElementAnimationComplete = function(animation) {
            var $element = animation.element,
                config = animation.config;
            $element.removeData(ANIM_DATA_KEY);
            if (config.complete) {
                config.complete.apply(this, [$element, config])
            }
            animation.deferred.resolveWith(this, [$element, config])
        };
        var startAnimationOnElement = function() {
            var animation = this,
                $element = animation.element,
                config = animation.config;
            animation.isStarted = true;
            return animation.strategy.animate($element, config).done(function() {
                onElementAnimationComplete(animation)
            }).fail(function() {
                animation.deferred.rejectWith(this, [$element, config])
            })
        };
        var stopAnimationOnElement = function(jumpToEnd) {
            var animation = this,
                $element = animation.element,
                config = animation.config;
            clearTimeout(animation.startTimeout);
            if (!animation.isStarted) {
                animation.start()
            }
            animation.strategy.stop($element, config, jumpToEnd)
        };
        var createAnimation = function(element, initialConfig) {
            var defaultConfig = "css" === initialConfig.type ? defaultCssConfig : defaultJSConfig,
                config = $.extend(true, {}, defaultConfig, initialConfig),
                configurator = getAnimationConfigurator(config),
                strategy = getAnimationStrategy(config),
                animation = {
                    element: $(element),
                    config: config,
                    configurator: configurator,
                    strategy: strategy,
                    isSynchronous: strategy.isSynchronous,
                    setup: setupAnimationOnElement,
                    start: startAnimationOnElement,
                    stop: stopAnimationOnElement,
                    deferred: $.Deferred()
                };
            if ($.isFunction(configurator.validateConfig)) {
                configurator.validateConfig(config)
            }
            return animation
        };
        var animate = function(element, config) {
            var $element = $(element);
            if (!$element.length) {
                return $.Deferred().resolve().promise()
            }
            var animation = createAnimation($element, config);
            pushInAnimationQueue($element, animation);
            return animation.deferred.promise()
        };
        var pushInAnimationQueue = function($element, animation) {
            var queueData = getAnimQueueData($element);
            writeAnimQueueData($element, queueData);
            queueData.push(animation);
            if (!isAnimating($element)) {
                shiftFromAnimationQueue($element, queueData)
            }
        };
        var getAnimQueueData = function($element) {
            return $element.data(ANIM_QUEUE_KEY) || []
        };
        var writeAnimQueueData = function($element, queueData) {
            $element.data(ANIM_QUEUE_KEY, queueData)
        };
        var destroyAnimQueueData = function($element) {
            $element.removeData(ANIM_QUEUE_KEY)
        };
        var isAnimating = function($element) {
            return !!$element.data(ANIM_DATA_KEY)
        };
        var shiftFromAnimationQueue = function($element, queueData) {
            queueData = getAnimQueueData($element);
            if (!queueData.length) {
                return
            }
            var animation = queueData.shift();
            if (0 === queueData.length) {
                destroyAnimQueueData($element)
            }
            executeAnimation(animation).done(function() {
                if (!isAnimating($element)) {
                    shiftFromAnimationQueue($element)
                }
            })
        };
        var executeAnimation = function(animation) {
            animation.setup();
            if (fx.off || animation.isSynchronous) {
                animation.start()
            } else {
                animation.startTimeout = setTimeout(function() {
                    animation.start()
                });
                var namespacedRemoveEvent = eventUtils.addNamespace(removeEvent, "dxFXStartAnimation");
                animation.element.off(namespacedRemoveEvent).on(namespacedRemoveEvent, function() {
                    clearTimeout(animation.startTimeout)
                })
            }
            return animation.deferred.promise()
        };
        var setupPosition = function($element, config) {
            if (!config || !config.position) {
                return
            }
            var position = positionUtils.calculate($element, config.position),
                offset = $element.offset(),
                currentPosition = $element.position();
            $.extend(config, {
                left: position.h.location - offset.left + currentPosition.left,
                top: position.v.location - offset.top + currentPosition.top
            });
            delete config.position
        };
        var setProps = function($element, props) {
            $.each(props, function(key, value) {
                try {
                    $element.css(key, value)
                } catch (e) {}
            })
        };
        var stop = function(element, jumpToEnd) {
            var $element = $(element),
                queueData = getAnimQueueData($element);
            $.each(queueData, function(_, animation) {
                animation.config.delay = 0;
                animation.config.duration = 0;
                animation.isSynchronous = true
            });
            if (!isAnimating($element)) {
                shiftFromAnimationQueue($element, queueData)
            }
            var animation = $element.data(ANIM_DATA_KEY);
            if (animation) {
                animation.stop(jumpToEnd)
            }
            $element.removeData(ANIM_DATA_KEY);
            destroyAnimQueueData($element)
        };
        var fx = {
            off: false,
            animationTypes: animationConfigurators,
            animate: animate,
            createAnimation: createAnimation,
            isAnimating: isAnimating,
            stop: stop,
            _simulatedTransitionEndDelay: 100
        };
        fx.__internals = {
            convertTransitionTimingFuncToJQueryEasing: convertTransitionTimingFuncToJQueryEasing
        };
        module.exports = fx
    },
    /*!*****************************************!*\
      !*** ./Scripts/animation/translator.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            support = __webpack_require__( /*! ../core/utils/support */ 48);
        var TRANSLATOR_DATA_KEY = "dxTranslator",
            TRANSFORM_MATRIX_REGEX = /matrix(3d)?\((.+?)\)/,
            TRANSLATE_REGEX = /translate(?:3d)?\((.+?)\)/;
        var locate = function($element) {
            var translate = support.transform ? getTranslate($element) : getTranslateFallback($element);
            return {
                left: translate.x,
                top: translate.y
            }
        };
        var move = function($element, position) {
            if (!support.transform) {
                $element.css(position);
                return
            }
            var translate, left = position.left,
                top = position.top;
            if (void 0 === left) {
                translate = getTranslate($element);
                translate.y = top || 0
            } else {
                if (void 0 === top) {
                    translate = getTranslate($element);
                    translate.x = left || 0
                } else {
                    translate = {
                        x: left || 0,
                        y: top || 0,
                        z: 0
                    };
                    cacheTranslate($element, translate)
                }
            }
            $element.css({
                transform: getTranslateCss(translate)
            });
            if (isPercentValue(left) || isPercentValue(top)) {
                clearCache($element)
            }
        };
        var isPercentValue = function(value) {
            return "string" === $.type(value) && "%" === value[value.length - 1]
        };
        var getTranslateFallback = function($element) {
            var result;
            try {
                var originalTop = $element.css("top"),
                    originalLeft = $element.css("left");
                var position = $element.position();
                $element.css({
                    transform: "none",
                    top: 0,
                    left: 0
                });
                clearCache($element);
                var finalPosition = $element.position();
                result = {
                    x: position.left - finalPosition.left || parseInt(originalLeft) || 0,
                    y: position.top - finalPosition.top || parseInt(originalTop) || 0
                };
                $element.css({
                    top: originalTop,
                    left: originalLeft
                })
            } catch (e) {
                result = {
                    x: 0,
                    y: 0
                }
            }
            return result
        };
        var getTranslate = function($element) {
            var result = $element.length ? $.data($element.get(0), TRANSLATOR_DATA_KEY) : null;
            if (!result) {
                var transformValue = $element.css("transform") || getTranslateCss({
                        x: 0,
                        y: 0
                    }),
                    matrix = transformValue.match(TRANSFORM_MATRIX_REGEX),
                    is3D = matrix && matrix[1];
                if (matrix) {
                    matrix = matrix[2].split(",");
                    if ("3d" === is3D) {
                        matrix = matrix.slice(12, 15)
                    } else {
                        matrix.push(0);
                        matrix = matrix.slice(4, 7)
                    }
                } else {
                    matrix = [0, 0, 0]
                }
                result = {
                    x: parseFloat(matrix[0]),
                    y: parseFloat(matrix[1]),
                    z: parseFloat(matrix[2])
                };
                cacheTranslate($element, result)
            }
            return result
        };
        var cacheTranslate = function($element, translate) {
            if ($element.length) {
                $.data($element.get(0), TRANSLATOR_DATA_KEY, translate)
            }
        };
        var clearCache = function($element) {
            if ($element.length) {
                $.removeData($element.get(0), TRANSLATOR_DATA_KEY)
            }
        };
        var resetPosition = function($element) {
            $element.css({
                left: 0,
                top: 0,
                transform: "none"
            });
            clearCache($element)
        };
        var parseTranslate = function(translateString) {
            var result = translateString.match(TRANSLATE_REGEX);
            if (!result || !result[1]) {
                return
            }
            result = result[1].split(",");
            result = {
                x: parseFloat(result[0]),
                y: parseFloat(result[1]),
                z: parseFloat(result[2])
            };
            return result
        };
        var getTranslateCss = function(translate) {
            translate.x = translate.x || 0;
            translate.y = translate.y || 0;
            var xValueString = isPercentValue(translate.x) ? translate.x : translate.x + "px";
            var yValueString = isPercentValue(translate.y) ? translate.y : translate.y + "px";
            return "translate(" + xValueString + ", " + yValueString + ")"
        };
        exports.move = move;
        exports.locate = locate;
        exports.clearCache = clearCache;
        exports.parseTranslate = parseTranslate;
        exports.getTranslate = getTranslate;
        exports.getTranslateCss = getTranslateCss;
        exports.resetPosition = resetPosition
    },
    /*!***************************************!*\
      !*** ./Scripts/animation/position.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            stringUtils = __webpack_require__( /*! ../core/utils/string */ 13),
            translator = __webpack_require__( /*! ./translator */ 60),
            support = __webpack_require__( /*! ../core/utils/support */ 48);
        var horzRe = /left|right/,
            vertRe = /top|bottom/,
            collisionRe = /fit|flip|none/;
        var normalizeAlign = function(raw) {
            var result = {
                h: "center",
                v: "center"
            };
            var pair = commonUtils.splitPair(raw);
            if (pair) {
                $.each(pair, function() {
                    var w = String(this).toLowerCase();
                    if (horzRe.test(w)) {
                        result.h = w
                    } else {
                        if (vertRe.test(w)) {
                            result.v = w
                        }
                    }
                })
            }
            return result
        };
        var normalizeOffset = function(raw) {
            return stringUtils.pairToObject(raw)
        };
        var normalizeCollision = function(raw) {
            var pair = commonUtils.splitPair(raw),
                h = String(pair && pair[0]).toLowerCase(),
                v = String(pair && pair[1]).toLowerCase();
            if (!collisionRe.test(h)) {
                h = "none"
            }
            if (!collisionRe.test(v)) {
                v = h
            }
            return {
                h: h,
                v: v
            }
        };
        var getAlignFactor = function(align) {
            switch (align) {
                case "center":
                    return .5;
                case "right":
                case "bottom":
                    return 1;
                default:
                    return 0
            }
        };
        var inverseAlign = function(align) {
            switch (align) {
                case "left":
                    return "right";
                case "right":
                    return "left";
                case "top":
                    return "bottom";
                case "bottom":
                    return "top";
                default:
                    return align
            }
        };
        var calculateOversize = function(data, bounds) {
            var oversize = 0;
            if (data.myLocation < bounds.min) {
                oversize += bounds.min - data.myLocation
            }
            if (data.myLocation > bounds.max) {
                oversize += data.myLocation - bounds.max
            }
            return oversize
        };
        var collisionSide = function(direction, data, bounds) {
            if (data.myLocation < bounds.min) {
                return "h" === direction ? "left" : "top"
            }
            if (data.myLocation > bounds.max) {
                return "h" === direction ? "right" : "bottom"
            }
            return "none"
        };
        var initMyLocation = function(data) {
            data.myLocation = data.atLocation + getAlignFactor(data.atAlign) * data.atSize - getAlignFactor(data.myAlign) * data.mySize + data.offset
        };
        var decolliders = {
            fit: function(data, bounds) {
                var result = false;
                if (data.myLocation > bounds.max) {
                    data.myLocation = bounds.max;
                    result = true
                }
                if (data.myLocation < bounds.min) {
                    data.myLocation = bounds.min;
                    result = true
                }
                data.fit = result
            },
            flip: function(data, bounds) {
                data.flip = false;
                if ("center" === data.myAlign && "center" === data.atAlign) {
                    return
                }
                if (data.myLocation < bounds.min || data.myLocation > bounds.max) {
                    var inverseData = $.extend({}, data, {
                        myAlign: inverseAlign(data.myAlign),
                        atAlign: inverseAlign(data.atAlign),
                        offset: -data.offset
                    });
                    initMyLocation(inverseData);
                    inverseData.oversize = calculateOversize(inverseData, bounds);
                    if (inverseData.myLocation >= bounds.min && inverseData.myLocation <= bounds.max || data.oversize > inverseData.oversize) {
                        data.myLocation = inverseData.myLocation;
                        data.oversize = inverseData.oversize;
                        data.flip = true
                    }
                }
            },
            flipfit: function(data, bounds) {
                this.flip(data, bounds);
                this.fit(data, bounds)
            },
            none: function(data, bounds) {
                data.oversize = 0
            }
        };
        var scrollbarWidth;
        var calculateScrollbarWidth = function() {
            var $scrollDiv = $("<div>").css({
                    width: 100,
                    height: 100,
                    overflow: "scroll",
                    position: "absolute",
                    top: -9999
                }).appendTo($("body")),
                result = $scrollDiv.get(0).offsetWidth - $scrollDiv.get(0).clientWidth;
            $scrollDiv.remove();
            scrollbarWidth = result
        };
        var defaultPositionResult = {
            h: {
                location: 0,
                flip: false,
                fit: false,
                oversize: 0
            },
            v: {
                location: 0,
                flip: false,
                fit: false,
                oversize: 0
            }
        };
        var calculatePosition = function(what, options) {
            var $what = $(what),
                currentOffset = $what.offset(),
                result = $.extend(true, {}, defaultPositionResult, {
                    h: {
                        location: currentOffset.left
                    },
                    v: {
                        location: currentOffset.top
                    }
                });
            if (!options) {
                return result
            }
            var my = normalizeAlign(options.my),
                at = normalizeAlign(options.at),
                of = options.of || window,
                offset = normalizeOffset(options.offset),
                collision = normalizeCollision(options.collision),
                boundary = options.boundary,
                boundaryOffset = normalizeOffset(options.boundaryOffset);
            var h = {
                mySize: $what.outerWidth(),
                myAlign: my.h,
                atAlign: at.h,
                offset: offset.h,
                collision: collision.h,
                boundaryOffset: boundaryOffset.h
            };
            var v = {
                mySize: $what.outerHeight(),
                myAlign: my.v,
                atAlign: at.v,
                offset: offset.v,
                collision: collision.v,
                boundaryOffset: boundaryOffset.v
            };
            if (of.preventDefault) {
                h.atLocation = of.pageX;
                v.atLocation = of.pageY;
                h.atSize = 0;
                v.atSize = 0
            } else {
                of = $(of);
                if ($.isWindow(of[0])) {
                    h.atLocation = of.scrollLeft();
                    v.atLocation = of.scrollTop();
                    h.atSize = of.width();
                    v.atSize = of.height()
                } else {
                    if (9 === of[0].nodeType) {
                        h.atLocation = 0;
                        v.atLocation = 0;
                        h.atSize = of.width();
                        v.atSize = of.height()
                    } else {
                        var o = of.offset();
                        h.atLocation = o.left;
                        v.atLocation = o.top;
                        h.atSize = of.outerWidth();
                        v.atSize = of.outerHeight()
                    }
                }
            }
            initMyLocation(h);
            initMyLocation(v);
            var bounds = function() {
                var win = $(window),
                    windowWidth = win.width(),
                    windowHeight = win.height(),
                    left = win.scrollLeft(),
                    top = win.scrollTop(),
                    hScrollbar = document.width > document.documentElement.clientWidth,
                    vScrollbar = document.height > document.documentElement.clientHeight,
                    hZoomLevel = support.touch ? document.documentElement.clientWidth / (vScrollbar ? windowWidth - scrollbarWidth : windowWidth) : 1,
                    vZoomLevel = support.touch ? document.documentElement.clientHeight / (hScrollbar ? windowHeight - scrollbarWidth : windowHeight) : 1;
                if (void 0 === scrollbarWidth) {
                    calculateScrollbarWidth()
                }
                var boundaryWidth = windowWidth,
                    boundaryHeight = windowHeight;
                if (boundary) {
                    var $boundary = $(boundary),
                        boundaryPosition = $boundary.offset();
                    left = boundaryPosition.left;
                    top = boundaryPosition.top;
                    boundaryWidth = $boundary.width();
                    boundaryHeight = $boundary.height()
                }
                return {
                    h: {
                        min: left + h.boundaryOffset,
                        max: left + boundaryWidth / hZoomLevel - h.mySize - h.boundaryOffset
                    },
                    v: {
                        min: top + v.boundaryOffset,
                        max: top + boundaryHeight / vZoomLevel - v.mySize - v.boundaryOffset
                    }
                }
            }();
            h.oversize = calculateOversize(h, bounds.h);
            v.oversize = calculateOversize(v, bounds.v);
            h.collisionSide = collisionSide("h", h, bounds.h);
            v.collisionSide = collisionSide("v", v, bounds.v);
            if (decolliders[h.collision]) {
                decolliders[h.collision](h, bounds.h)
            }
            if (decolliders[v.collision]) {
                decolliders[v.collision](v, bounds.v)
            }
            var preciser = function(number) {
                return options.precise ? number : Math.round(number)
            };
            $.extend(true, result, {
                h: {
                    location: preciser(h.myLocation),
                    oversize: preciser(h.oversize),
                    fit: h.fit,
                    flip: h.flip,
                    collisionSide: h.collisionSide
                },
                v: {
                    location: preciser(v.myLocation),
                    oversize: preciser(v.oversize),
                    fit: v.fit,
                    flip: v.flip,
                    collisionSide: v.collisionSide
                },
                precise: options.precise
            });
            return result
        };
        var position = function(what, options) {
            var $what = $(what);
            if (!options) {
                return $what.offset()
            }
            translator.resetPosition($what);
            var offset = $what.offset(),
                targetPosition = options.h && options.v ? options : calculatePosition($what, options);
            var preciser = function(number) {
                return options.precise ? number : Math.round(number)
            };
            translator.move($what, {
                left: targetPosition.h.location - preciser(offset.left),
                top: targetPosition.v.location - preciser(offset.top)
            });
            return targetPosition
        };
        $.extend(position, {
            inverseAlign: inverseAlign,
            normalizeAlign: normalizeAlign
        });
        module.exports = {
            calculateScrollbarWidth: calculateScrollbarWidth,
            calculate: calculatePosition,
            setup: position
        }
    },
    /*!*********************************!*\
      !*** ./Scripts/events/utils.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../core/errors */ 17),
            eventNS = $.event,
            hooksNS = eventNS.fixHooks;
        var eventSource = function() {
            var EVENT_SOURCES_REGEX = {
                dx: /^dx/i,
                mouse: /(mouse|wheel)/i,
                touch: /^touch/i,
                keyboard: /^key/i,
                pointer: /^(ms)?pointer/i
            };
            return function(e) {
                var result = "other";
                $.each(EVENT_SOURCES_REGEX, function(key) {
                    if (this.test(e.type)) {
                        result = key;
                        return false
                    }
                });
                return result
            }
        }();
        var isDxEvent = function(e) {
            return "dx" === eventSource(e)
        };
        var isNativeMouseEvent = function(e) {
            return "mouse" === eventSource(e)
        };
        var isNativeTouchEvent = function(e) {
            return "touch" === eventSource(e)
        };
        var isPointerEvent = function(e) {
            return "pointer" === eventSource(e)
        };
        var isMouseEvent = function(e) {
            return isNativeMouseEvent(e) || (isPointerEvent(e) || isDxEvent(e)) && "mouse" === e.pointerType
        };
        var isTouchEvent = function(e) {
            return isNativeTouchEvent(e) || (isPointerEvent(e) || isDxEvent(e)) && "touch" === e.pointerType
        };
        var isKeyboardEvent = function(e) {
            return "keyboard" === eventSource(e)
        };
        var isFakeClickEvent = function(e) {
            return 0 === e.screenX && !e.offsetX && 0 === e.pageX
        };
        var eventData = function(e) {
            return {
                x: e.pageX,
                y: e.pageY,
                time: e.timeStamp
            }
        };
        var eventDelta = function(from, to) {
            return {
                x: to.x - from.x,
                y: to.y - from.y,
                time: to.time - from.time || 1
            }
        };
        var hasTouches = function(e) {
            if (isNativeTouchEvent(e)) {
                return (e.originalEvent.touches || []).length
            }
            if (isDxEvent(e)) {
                return (e.pointers || []).length
            }
            return 0
        };
        var needSkipEvent = function(e) {
            var $target = $(e.target),
                touchInInput = $target.is("input, textarea, select");
            if ($target.is(".dx-skip-gesture-event *, .dx-skip-gesture-event")) {
                return true
            }
            if ("dxmousewheel" === e.type) {
                return $target.is("input[type='number'], textarea, select") && $target.is(":focus")
            }
            if (isMouseEvent(e)) {
                return touchInInput || e.which > 1
            }
            if (isTouchEvent(e)) {
                return touchInInput && $target.is(":focus")
            }
        };
        var createEvent = function(originalEvent, args) {
            var event = $.Event(originalEvent),
                fixHook = hooksNS[originalEvent.type] || eventNS.mouseHooks;
            var props = fixHook.props ? eventNS.props.concat(fixHook.props) : eventNS.props,
                propIndex = props.length;
            while (propIndex--) {
                var prop = props[propIndex];
                event[prop] = originalEvent[prop]
            }
            if (args) {
                $.extend(event, args)
            }
            return fixHook.filter ? fixHook.filter(event, originalEvent) : event
        };
        var fireEvent = function(props) {
            var event = createEvent(props.originalEvent, props);
            eventNS.trigger(event, null, props.delegateTarget || event.target);
            return event
        };
        var addNamespace = function(eventNames, namespace) {
            if (!namespace) {
                throw errors.Error("E0017")
            }
            if ("string" === typeof eventNames) {
                if (eventNames.indexOf(" ") === -1) {
                    return eventNames + "." + namespace
                }
                return addNamespace(eventNames.split(/\s+/g), namespace)
            }
            $.each(eventNames, function(index, eventName) {
                eventNames[index] = eventName + "." + namespace
            });
            return eventNames.join(" ")
        };
        module.exports = {
            eventSource: eventSource,
            isPointerEvent: isPointerEvent,
            isMouseEvent: isMouseEvent,
            isTouchEvent: isTouchEvent,
            isKeyboardEvent: isKeyboardEvent,
            isFakeClickEvent: isFakeClickEvent,
            hasTouches: hasTouches,
            eventData: eventData,
            eventDelta: eventDelta,
            needSkipEvent: needSkipEvent,
            createEvent: createEvent,
            fireEvent: fireEvent,
            addNamespace: addNamespace
        }
    },
    /*!**********************************************************************!*\
      !*** ./Scripts/animation/transition_executor/transition_executor.js ***!
      \**********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            fx = __webpack_require__( /*! ../fx */ 59),
            animationPresetsModule = __webpack_require__( /*! ../presets/presets */ 58);
        var directionPostfixes = {
                forward: " dx-forward",
                backward: " dx-backward",
                none: " dx-no-direction",
                undefined: " dx-no-direction"
            },
            DX_ANIMATING_CLASS = "dx-animating";
        var TransitionExecutor = Class.inherit({
            ctor: function() {
                this._accumulatedDelays = {
                    enter: 0,
                    leave: 0
                };
                this._animations = [];
                this.reset()
            },
            _createAnimations: function($elements, initialConfig, configModifier, type) {
                var animationConfig, that = this,
                    result = [];
                configModifier = configModifier || {};
                animationConfig = this._prepareElementAnimationConfig(initialConfig, configModifier, type);
                if (animationConfig) {
                    $elements.each(function() {
                        var animation = that._createAnimation($(this), animationConfig, configModifier);
                        if (animation) {
                            animation.element.addClass(DX_ANIMATING_CLASS);
                            animation.setup();
                            result.push(animation)
                        }
                    })
                }
                return result
            },
            _prepareElementAnimationConfig: function(config, configModifier, type) {
                var result;
                if ("string" === typeof config) {
                    var presetName = config;
                    config = animationPresetsModule.presets.getPreset(presetName)
                }
                if (!config) {
                    result = void 0
                } else {
                    if ($.isFunction(config[type])) {
                        result = config[type]
                    } else {
                        result = $.extend({
                            skipElementInitialStyles: true,
                            cleanupWhen: this._completePromise
                        }, config, configModifier);
                        if (!result.type || "css" === result.type) {
                            var cssClass = "dx-" + type,
                                extraCssClasses = (result.extraCssClasses ? " " + result.extraCssClasses : "") + directionPostfixes[result.direction];
                            result.type = "css";
                            result.from = (result.from || cssClass) + extraCssClasses;
                            result.to = result.to || cssClass + "-active"
                        }
                        result.staggerDelay = result.staggerDelay || 0;
                        result.delay = result.delay || 0;
                        if (result.staggerDelay) {
                            result.delay += this._accumulatedDelays[type];
                            this._accumulatedDelays[type] += result.staggerDelay
                        }
                    }
                }
                return result
            },
            _createAnimation: function($element, animationConfig, configModifier) {
                var result;
                if ($.isPlainObject(animationConfig)) {
                    result = fx.createAnimation($element, animationConfig)
                } else {
                    if ($.isFunction(animationConfig)) {
                        result = animationConfig($element, configModifier)
                    }
                }
                return result
            },
            _startAnimations: function() {
                var animations = this._animations;
                for (var i = 0; i < animations.length; i++) {
                    animations[i].start()
                }
            },
            _stopAnimations: function(jumpToEnd) {
                var animations = this._animations;
                for (var i = 0; i < animations.length; i++) {
                    animations[i].stop(jumpToEnd)
                }
            },
            _clearAnimations: function() {
                var animations = this._animations;
                for (var i = 0; i < animations.length; i++) {
                    animations[i].element.removeClass(DX_ANIMATING_CLASS)
                }
                this._animations.length = 0
            },
            reset: function() {
                this._accumulatedDelays.enter = 0;
                this._accumulatedDelays.leave = 0;
                this._clearAnimations();
                this._completeDeferred = $.Deferred();
                this._completePromise = this._completeDeferred.promise()
            },
            enter: function($elements, animationConfig, configModifier) {
                var animations = this._createAnimations($elements, animationConfig, configModifier, "enter");
                this._animations.push.apply(this._animations, animations)
            },
            leave: function($elements, animationConfig, configModifier) {
                var animations = this._createAnimations($elements, animationConfig, configModifier, "leave");
                this._animations.push.apply(this._animations, animations)
            },
            start: function() {
                var result, that = this;
                if (!this._animations.length) {
                    that.reset();
                    result = $.Deferred().resolve().promise()
                } else {
                    var animationDeferreds = $.map(this._animations, function(animation) {
                        var result = $.Deferred();
                        animation.deferred.always(function() {
                            result.resolve()
                        });
                        return result.promise()
                    });
                    result = $.when.apply($, animationDeferreds).always(function() {
                        that._completeDeferred.resolve();
                        that.reset()
                    });
                    commonUtils.executeAsync(function() {
                        that._startAnimations()
                    })
                }
                return result
            },
            stop: function(jumpToEnd) {
                this._stopAnimations(jumpToEnd)
            }
        });
        exports.TransitionExecutor = TransitionExecutor
    },
    /*!*********************************!*\
      !*** ./Scripts/events/click.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            animationFrame = __webpack_require__( /*! ../animation/frame */ 46),
            eventUtils = __webpack_require__( /*! ./utils */ 62),
            pointerEvents = __webpack_require__( /*! ./pointer */ 65),
            Emitter = __webpack_require__( /*! ./core/emitter */ 75),
            registerEmitter = __webpack_require__( /*! ./core/emitter_registrator */ 76);
        var CLICK_EVENT_NAME = "dxclick",
            TOUCH_BOUNDARY = 10,
            abs = Math.abs;
        var isInput = function(element) {
            return $(element).is("input, textarea, select, button ,:focus, :focus *")
        };
        var misc = {
            requestAnimationFrame: animationFrame.requestAnimationFrame
        };
        var ClickEmitter = Emitter.inherit({
            ctor: function(element) {
                this.callBase(element);
                this._makeElementClickable($(element))
            },
            _makeElementClickable: function($element) {
                if (!$element.attr("onclick")) {
                    $element.attr("onclick", "void(0)")
                }
            },
            start: function(e) {
                this._blurPrevented = e.isDefaultPrevented();
                this._startTarget = e.target;
                this._startEventData = eventUtils.eventData(e)
            },
            end: function(e) {
                if (this._eventOutOfElement(e, this.getElement().get(0)) || e.type === pointerEvents.cancel) {
                    this._cancel(e);
                    return
                }
                if (!isInput(e.target) && !this._blurPrevented) {
                    domUtils.resetActiveElement()
                }
                this._accept(e);
                misc.requestAnimationFrame($.proxy(function() {
                    this._fireClickEvent(e)
                }, this))
            },
            _eventOutOfElement: function(e, element) {
                var target = e.target,
                    targetChanged = !$.contains(element, target) && element !== target,
                    gestureDelta = eventUtils.eventDelta(eventUtils.eventData(e), this._startEventData),
                    boundsExceeded = abs(gestureDelta.x) > TOUCH_BOUNDARY || abs(gestureDelta.y) > TOUCH_BOUNDARY;
                return targetChanged || boundsExceeded
            },
            _fireClickEvent: function(e) {
                this._fireEvent(CLICK_EVENT_NAME, e, {
                    target: domUtils.closestCommonParent(this._startTarget, e.target)
                })
            }
        });
        ! function() {
            var NATIVE_CLICK_CLASS = "dx-native-click";
            var useNativeClick = devices.real().generic;
            var prevented = null;

            function isNativeClickEvent(e) {
                return useNativeClick || $(e.target).closest("." + NATIVE_CLICK_CLASS).length
            }
            ClickEmitter = ClickEmitter.inherit({
                configurate: function(data) {
                    this.callBase(data);
                    if (data.useNative) {
                        this.getElement().addClass(NATIVE_CLICK_CLASS)
                    }
                },
                start: function(e) {
                    prevented = null;
                    if (!isNativeClickEvent(e)) {
                        this.callBase(e)
                    }
                },
                end: function(e) {
                    if (!isNativeClickEvent(e)) {
                        this.callBase(e)
                    }
                },
                cancel: function() {
                    prevented = true
                }
            });
            var clickHandler = function(e) {
                if ((!e.which || 1 === e.which) && !prevented && isNativeClickEvent(e)) {
                    eventUtils.fireEvent({
                        type: CLICK_EVENT_NAME,
                        originalEvent: e
                    })
                }
            };
            $(document).on(eventUtils.addNamespace("click", "NATIVE_DXCLICK_STRATEGY"), clickHandler);
            exports.useNativeClick = useNativeClick
        }();
        ! function() {
            var desktopDevice = devices.real().generic;
            if (!desktopDevice) {
                var startTarget = null,
                    blurPrevented = false;
                var pointerDownHandler = function(e) {
                    startTarget = e.target;
                    blurPrevented = e.isDefaultPrevented()
                };
                var clickHandler = function(e) {
                    var $target = $(e.target);
                    if (!blurPrevented && startTarget && !$target.is(startTarget) && !$(startTarget).is("label") && isInput($target)) {
                        domUtils.resetActiveElement()
                    }
                    startTarget = null;
                    blurPrevented = false
                };
                var NATIVE_CLICK_FIXER_NAMESPACE = "NATIVE_CLICK_FIXER";
                $(document).on(eventUtils.addNamespace(pointerEvents.down, NATIVE_CLICK_FIXER_NAMESPACE), pointerDownHandler).on(eventUtils.addNamespace("click", NATIVE_CLICK_FIXER_NAMESPACE), clickHandler)
            }
        }();
        registerEmitter({
            emitter: ClickEmitter,
            bubble: true,
            events: [CLICK_EVENT_NAME]
        });
        exports.name = CLICK_EVENT_NAME;
        exports.misc = misc
    },
    /*!***********************************!*\
      !*** ./Scripts/events/pointer.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            support = __webpack_require__( /*! ../core/utils/support */ 48),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerEvent = __webpack_require__( /*! ./core/event_registrator */ 66),
            TouchStrategy = __webpack_require__( /*! ./pointer/touch */ 67),
            MsPointerStrategy = __webpack_require__( /*! ./pointer/mspointer */ 70),
            MouseStrategy = __webpack_require__( /*! ./pointer/mouse */ 73),
            MouseAndTouchStrategy = __webpack_require__( /*! ./pointer/mouse_and_touch */ 74);
        var EventStrategy = function() {
            if (support.pointerEvents) {
                return MsPointerStrategy
            }
            var device = devices.real();
            if (support.touch && !(device.tablet || device.phone)) {
                return MouseAndTouchStrategy
            }
            if (support.touch) {
                return TouchStrategy
            }
            return MouseStrategy
        }();
        $.each(EventStrategy.map, function(pointerEvent, originalEvents) {
            registerEvent(pointerEvent, new EventStrategy(pointerEvent, originalEvents))
        });
        module.exports = {
            down: "dxpointerdown",
            up: "dxpointerup",
            move: "dxpointermove",
            cancel: "dxpointercancel",
            enter: "dxpointerenter",
            leave: "dxpointerleave",
            over: "dxpointerover",
            out: "dxpointerout"
        }
    },
    /*!**************************************************!*\
      !*** ./Scripts/events/core/event_registrator.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            MemorizedCallbacks = __webpack_require__( /*! ../../core/memorized_callbacks */ 44);
        var eventNS = $.event,
            hooksNS = eventNS.fixHooks,
            specialNS = $.event.special;
        var DX_EVENT_HOOKS = {
            props: eventNS.mouseHooks.props.concat(["pointerType", "pointerId", "pointers"])
        };
        var callbacks = new MemorizedCallbacks;
        var registerEvent = function(name, eventObject) {
            var strategy = {};
            if ("noBubble" in eventObject) {
                strategy.noBubble = eventObject.noBubble
            }
            if ("bindType" in eventObject) {
                strategy.bindType = eventObject.bindType
            }
            if ("delegateType" in eventObject) {
                strategy.delegateType = eventObject.delegateType
            }
            $.each(["setup", "teardown", "add", "remove", "trigger", "handle", "_default", "dispose"], function(_, methodName) {
                if (!eventObject[methodName]) {
                    return
                }
                strategy[methodName] = function() {
                    var args = $.makeArray(arguments);
                    args.unshift(this);
                    return eventObject[methodName].apply(eventObject, args)
                }
            });
            hooksNS[name] = DX_EVENT_HOOKS;
            callbacks.fire(name, strategy)
        };
        registerEvent.callbacks = callbacks;
        var registerJQueryEvent = function(name, eventObject) {
            specialNS[name] = eventObject
        };
        callbacks.add(registerJQueryEvent);
        module.exports = registerEvent
    },
    /*!*****************************************!*\
      !*** ./Scripts/events/pointer/touch.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            BaseStrategy = __webpack_require__( /*! ./base */ 68);
        __webpack_require__( /*! ./touch_hooks */ 69);
        var eventMap = {
            dxpointerdown: "touchstart",
            dxpointermove: "touchmove",
            dxpointerup: "touchend",
            dxpointercancel: "touchcancel",
            dxpointerover: "",
            dxpointerout: "",
            dxpointerenter: "",
            dxpointerleave: ""
        };
        var normalizeTouchEvent = function(e) {
            var pointers = [];
            $.each(e.touches, function(_, touch) {
                pointers.push($.extend({
                    pointerId: touch.identifier
                }, touch))
            });
            return {
                pointers: pointers,
                pointerId: e.changedTouches[0].identifier
            }
        };
        var skipTouchWithSameIdentifier = function(pointerEvent) {
            return "ios" === devices.real().platform && ("dxpointerdown" === pointerEvent || "dxpointerup" === pointerEvent)
        };
        var TouchStrategy = BaseStrategy.inherit({
            ctor: function() {
                this.callBase.apply(this, arguments);
                this._pointerId = 0
            },
            _handler: function(e) {
                if (skipTouchWithSameIdentifier(this._eventName)) {
                    var touch = e.changedTouches[0];
                    if (this._pointerId === touch.identifier && 0 !== this._pointerId) {
                        return
                    }
                    this._pointerId = touch.identifier
                }
                return this.callBase.apply(this, arguments)
            },
            _fireEvent: function(args) {
                return this.callBase($.extend(normalizeTouchEvent(args.originalEvent), args))
            }
        });
        TouchStrategy.map = eventMap;
        TouchStrategy.normalize = normalizeTouchEvent;
        module.exports = TouchStrategy
    },
    /*!****************************************!*\
      !*** ./Scripts/events/pointer/base.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            eventUtils = __webpack_require__( /*! ../utils */ 62);
        var POINTER_EVENTS_NAMESPACE = "dxPointerEvents";
        var BaseStrategy = Class.inherit({
            ctor: function(eventName, originalEvents) {
                this._eventName = eventName;
                this._originalEvents = eventUtils.addNamespace(originalEvents, POINTER_EVENTS_NAMESPACE);
                this._handlerCount = 0;
                this.noBubble = this._isNoBubble()
            },
            _isNoBubble: function() {
                var eventName = this._eventName;
                return "dxpointerenter" === eventName || "dxpointerleave" === eventName
            },
            _handler: function(e) {
                var delegateTarget = this._getDelegateTarget(e);
                return this._fireEvent({
                    type: this._eventName,
                    pointerType: e.pointerType || eventUtils.eventSource(e),
                    originalEvent: e,
                    delegateTarget: delegateTarget,
                    timeStamp: browser.mozilla ? (new Date).getTime() : e.timeStamp
                })
            },
            _getDelegateTarget: function(e) {
                var delegateTarget;
                if (this.noBubble) {
                    delegateTarget = e.delegateTarget
                }
                return delegateTarget
            },
            _fireEvent: function(args) {
                return eventUtils.fireEvent(args)
            },
            setup: function() {
                return true
            },
            add: function(element, handleObj) {
                if (this._handlerCount <= 0 || this.noBubble) {
                    this._selector = handleObj.selector;
                    element = this.noBubble ? element : document;
                    var that = this;
                    $(element).on(this._originalEvents, this._selector, function(e) {
                        that._handler(e)
                    })
                }
                if (!this.noBubble) {
                    this._handlerCount++
                }
            },
            remove: function(element) {
                if (!this.noBubble) {
                    this._handlerCount--
                }
            },
            teardown: function(element) {
                if (this._handlerCount && !this.noBubble) {
                    return
                }
                element = this.noBubble ? element : document;
                if (this._originalEvents !== "." + POINTER_EVENTS_NAMESPACE) {
                    $(element).off(this._originalEvents, this._selector)
                }
            },
            dispose: function(element) {
                element = this.noBubble ? element : document;
                $(element).off(this._originalEvents)
            }
        });
        module.exports = BaseStrategy
    },
    /*!***********************************************!*\
      !*** ./Scripts/events/pointer/touch_hooks.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var touchEventHook = {
            filter: function(event, originalEvent) {
                var touches = originalEvent.touches.length ? originalEvent.touches : originalEvent.changedTouches;
                $.each(["pageX", "pageY", "screenX", "screenY", "clientX", "clientY"], function() {
                    event[this] = touches[0][this]
                });
                return event
            },
            props: $.event.mouseHooks.props.concat(["touches", "changedTouches", "targetTouches", "detail", "result", "originalTarget", "charCode", "prevValue"])
        };
        $.each(["touchstart", "touchmove", "touchend", "touchcancel"], function() {
            $.event.fixHooks[this] = touchEventHook
        })
    },
    /*!*********************************************!*\
      !*** ./Scripts/events/pointer/mspointer.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseStrategy = __webpack_require__( /*! ./base */ 68),
            Observer = __webpack_require__( /*! ./observer */ 71),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18);
        __webpack_require__( /*! ./mspointer_hooks */ 72);
        var isIE10 = browser.msie && 10 === parseInt(browser.version);
        var eventMap = {
            dxpointerdown: "MSPointerDown pointerdown",
            dxpointermove: "MSPointerMove pointermove",
            dxpointerup: "MSPointerUp pointerup",
            dxpointercancel: "MSPointerCancel pointercancel",
            dxpointerover: "MSPointerOver pointerover",
            dxpointerout: "MSPointerOut pointerout",
            dxpointerenter: isIE10 ? "mouseenter" : "MSPointerEnter pointerenter",
            dxpointerleave: isIE10 ? "mouseleave" : "MSPointerLeave pointerleave"
        };
        var observer;
        var activated = false;
        var activateStrategy = function() {
            if (activated) {
                return
            }
            observer = new Observer(eventMap, function(a, b) {
                return a.pointerId === b.pointerId
            }, function(e) {
                if (e.isPrimary) {
                    observer.reset()
                }
            });
            activated = true
        };
        var MsPointerStrategy = BaseStrategy.inherit({
            ctor: function() {
                this.callBase.apply(this, arguments);
                activateStrategy()
            },
            _fireEvent: function(args) {
                return this.callBase($.extend({
                    pointers: observer.pointers(),
                    pointerId: args.originalEvent.pointerId
                }, args))
            }
        });
        MsPointerStrategy.map = eventMap;
        MsPointerStrategy.resetObserver = function() {
            observer.reset()
        };
        module.exports = MsPointerStrategy
    },
    /*!********************************************!*\
      !*** ./Scripts/events/pointer/observer.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var addEventsListener = function(events, handler) {
            events = events.split(" ");
            $.each(events, function(_, event) {
                if (document.addEventListener) {
                    document.addEventListener(event, handler, true)
                } else {
                    document.attachEvent("on" + event, handler)
                }
            })
        };
        var Observer = function(eventMap, pointerEquals, onPointerAdding) {
            onPointerAdding = onPointerAdding || function() {};
            var pointers = [];
            var getPointerIndex = function(e) {
                var index = -1;
                $.each(pointers, function(i, pointer) {
                    if (!pointerEquals(e, pointer)) {
                        return true
                    }
                    index = i;
                    return false
                });
                return index
            };
            var addPointer = function(e) {
                if (getPointerIndex(e) === -1) {
                    onPointerAdding(e);
                    pointers.push(e)
                }
            };
            var removePointer = function(e) {
                var index = getPointerIndex(e);
                if (index > -1) {
                    pointers.splice(index, 1)
                }
            };
            var updatePointer = function(e) {
                pointers[getPointerIndex(e)] = e
            };
            addEventsListener(eventMap.dxpointerdown, addPointer);
            addEventsListener(eventMap.dxpointermove, updatePointer);
            addEventsListener(eventMap.dxpointerup, removePointer);
            addEventsListener(eventMap.dxpointercancel, removePointer);
            this.pointers = function() {
                return pointers
            };
            this.reset = function() {
                pointers = []
            }
        };
        module.exports = Observer
    },
    /*!***************************************************!*\
      !*** ./Scripts/events/pointer/mspointer_hooks.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var POINTER_TYPE_MAP = {
            2: "touch",
            3: "pen",
            4: "mouse"
        };
        var pointerEventHook = {
            filter: function(event, originalEvent) {
                var pointerType = originalEvent.pointerType;
                if ($.isNumeric(pointerType)) {
                    event.pointerType = POINTER_TYPE_MAP[pointerType]
                }
                return event
            },
            props: $.event.mouseHooks.props.concat(["pointerId", "pointerType", "originalTarget", "width", "height", "pressure", "result", "tiltX", "charCode", "tiltY", "detail", "isPrimary", "prevValue"])
        };
        $.each(["MSPointerDown", "MSPointerMove", "MSPointerUp", "MSPointerCancel", "MSPointerOver", "MSPointerOut", "mouseenter", "mouseleave", "pointerdown", "pointermove", "pointerup", "pointercancel", "pointerover", "pointerout", "pointerenter", "pointerleave"], function() {
            $.event.fixHooks[this] = pointerEventHook
        })
    },
    /*!*****************************************!*\
      !*** ./Scripts/events/pointer/mouse.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseStrategy = __webpack_require__( /*! ./base */ 68),
            Observer = __webpack_require__( /*! ./observer */ 71);
        var eventMap = {
            dxpointerdown: "mousedown",
            dxpointermove: "mousemove",
            dxpointerup: "mouseup",
            dxpointercancel: "",
            dxpointerover: "mouseover",
            dxpointerout: "mouseout",
            dxpointerenter: "mouseenter",
            dxpointerleave: "mouseleave"
        };
        var normalizeMouseEvent = function(e) {
            e.pointerId = 1;
            return {
                pointers: observer.pointers(),
                pointerId: 1
            }
        };
        var observer;
        var activated = false;
        var activateStrategy = function() {
            if (activated) {
                return
            }
            observer = new Observer(eventMap, function(a, b) {
                return true
            });
            activated = true
        };
        var MouseStrategy = BaseStrategy.inherit({
            ctor: function() {
                this.callBase.apply(this, arguments);
                activateStrategy()
            },
            _fireEvent: function(args) {
                return this.callBase($.extend(normalizeMouseEvent(args.originalEvent), args))
            }
        });
        MouseStrategy.map = eventMap;
        MouseStrategy.normalize = normalizeMouseEvent;
        MouseStrategy.activate = activateStrategy;
        MouseStrategy.resetObserver = function() {
            observer.reset()
        };
        module.exports = MouseStrategy
    },
    /*!***************************************************!*\
      !*** ./Scripts/events/pointer/mouse_and_touch.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseStrategy = __webpack_require__( /*! ./base */ 68),
            MouseStrategy = __webpack_require__( /*! ./mouse */ 73),
            TouchStrategy = __webpack_require__( /*! ./touch */ 67),
            eventUtils = __webpack_require__( /*! ../utils */ 62);
        var eventMap = {
            dxpointerdown: "touchstart mousedown",
            dxpointermove: "touchmove mousemove",
            dxpointerup: "touchend mouseup",
            dxpointercancel: "touchcancel",
            dxpointerover: "mouseover",
            dxpointerout: "mouseout",
            dxpointerenter: "mouseenter",
            dxpointerleave: "mouseleave"
        };
        var activated = false;
        var activateStrategy = function() {
            if (activated) {
                return
            }
            MouseStrategy.activate();
            activated = true
        };
        var MouseAndTouchStrategy = BaseStrategy.inherit({
            EVENT_LOCK_TIMEOUT: 100,
            ctor: function() {
                this.callBase.apply(this, arguments);
                activateStrategy()
            },
            _handler: function(e) {
                var isMouseEvent = eventUtils.isMouseEvent(e);
                if (!isMouseEvent) {
                    this._skipNextEvents = true
                }
                if (isMouseEvent && this._mouseLocked) {
                    return
                }
                if (isMouseEvent && this._skipNextEvents) {
                    this._skipNextEvents = false;
                    this._mouseLocked = true;
                    clearTimeout(this._unlockMouseTimer);
                    var that = this;
                    this._unlockMouseTimer = setTimeout(function() {
                        that._mouseLocked = false
                    }, this.EVENT_LOCK_TIMEOUT);
                    return
                }
                return this.callBase(e)
            },
            _fireEvent: function(args) {
                var isMouseEvent = eventUtils.isMouseEvent(args.originalEvent),
                    normalizer = isMouseEvent ? MouseStrategy.normalize : TouchStrategy.normalize;
                return this.callBase($.extend(normalizer(args.originalEvent), args))
            },
            dispose: function() {
                this.callBase();
                this._skipNextEvents = false;
                this._mouseLocked = false;
                clearTimeout(this._unlockMouseTimer)
            }
        });
        MouseAndTouchStrategy.map = eventMap;
        MouseAndTouchStrategy.resetObserver = MouseStrategy.resetObserver;
        module.exports = MouseAndTouchStrategy
    },
    /*!****************************************!*\
      !*** ./Scripts/events/core/emitter.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            eventUtils = __webpack_require__( /*! ../utils */ 62);
        var Emitter = Class.inherit({
            ctor: function(element) {
                this._$element = $(element);
                this._cancelCallback = $.Callbacks();
                this._acceptCallback = $.Callbacks()
            },
            getElement: function() {
                return this._$element
            },
            validate: function(e) {
                return "dxmousewheel" !== e.type
            },
            validatePointers: function(e) {
                return 1 === eventUtils.hasTouches(e)
            },
            allowInterruptionByMousewheel: function() {
                return true
            },
            configurate: function(data) {
                $.extend(this, data)
            },
            addCancelCallback: function(callback) {
                this._cancelCallback.add(callback)
            },
            removeCancelCallback: function() {
                this._cancelCallback.empty()
            },
            _cancel: function(e) {
                this._cancelCallback.fire(this, e)
            },
            addAcceptCallback: function(callback) {
                this._acceptCallback.add(callback)
            },
            removeAcceptCallback: function() {
                this._acceptCallback.empty()
            },
            _accept: function(e) {
                this._acceptCallback.fire(this, e)
            },
            _requestAccept: function(e) {
                this._acceptRequestEvent = e
            },
            _forgetAccept: function() {
                this._accept(this._acceptRequestEvent);
                this._acceptRequestEvent = null
            },
            start: $.noop,
            move: $.noop,
            end: $.noop,
            cancel: $.noop,
            reset: function() {
                if (this._acceptRequestEvent) {
                    this._accept(this._acceptRequestEvent)
                }
            },
            _fireEvent: function(eventName, e, params) {
                var eventData = $.extend({
                    type: eventName,
                    originalEvent: e,
                    target: this._getEmitterTarget(e),
                    delegateTarget: this.getElement().get(0)
                }, params);
                e = eventUtils.fireEvent(eventData);
                if (e.cancel) {
                    this._cancel(e)
                }
                return e
            },
            _getEmitterTarget: function(e) {
                return (this.delegateSelector ? $(e.target).closest(this.delegateSelector) : this.getElement()).get(0)
            },
            dispose: $.noop
        });
        module.exports = Emitter
    },
    /*!****************************************************!*\
      !*** ./Scripts/events/core/emitter_registrator.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            registerEvent = __webpack_require__( /*! ./event_registrator */ 66),
            eventUtils = __webpack_require__( /*! ../utils */ 62),
            pointerEvents = __webpack_require__( /*! ../pointer */ 65),
            wheelEvent = __webpack_require__( /*! ./wheel */ 77);
        var MANAGER_EVENT = "dxEventManager",
            EMITTER_DATA = "dxEmitter";
        var EventManager = Class.inherit({
            ctor: function() {
                this._attachHandlers();
                this.reset();
                this._proxiedCancelHandler = $.proxy(this._cancelHandler, this);
                this._proxiedAcceptHandler = $.proxy(this._acceptHandler, this)
            },
            _attachHandlers: function() {
                $(document).on(eventUtils.addNamespace(pointerEvents.down, MANAGER_EVENT), $.proxy(this._pointerDownHandler, this)).on(eventUtils.addNamespace(pointerEvents.move, MANAGER_EVENT), $.proxy(this._pointerMoveHandler, this)).on(eventUtils.addNamespace([pointerEvents.up, pointerEvents.cancel].join(" "), MANAGER_EVENT), $.proxy(this._pointerUpHandler, this)).on(eventUtils.addNamespace(wheelEvent.name, MANAGER_EVENT), $.proxy(this._mouseWheelHandler, this))
            },
            _eachEmitter: function(callback) {
                var activeEmitters = this._activeEmitters || [];
                var i = 0;
                while (activeEmitters.length > i) {
                    var emitter = activeEmitters[i];
                    if (false === callback(emitter)) {
                        break
                    }
                    if (activeEmitters[i] === emitter) {
                        i++
                    }
                }
            },
            _applyToEmitters: function(method, arg) {
                this._eachEmitter(function(emitter) {
                    emitter[method].call(emitter, arg)
                })
            },
            reset: function() {
                this._eachEmitter(this._proxiedCancelHandler);
                this._activeEmitters = []
            },
            resetEmitter: function(emitter) {
                this._proxiedCancelHandler(emitter)
            },
            _pointerDownHandler: function(e) {
                if (eventUtils.isMouseEvent(e) && e.which > 1) {
                    return
                }
                this._updateEmitters(e)
            },
            _updateEmitters: function(e) {
                if (!this._isSetChanged(e)) {
                    return
                }
                this._cleanEmitters(e);
                this._fetchEmitters(e)
            },
            _isSetChanged: function(e) {
                var currentSet = this._closestEmitter(e);
                var previousSet = this._emittersSet || [];
                var setChanged = currentSet.length !== previousSet.length;
                $.each(currentSet, function(index, emitter) {
                    setChanged = setChanged || previousSet[index] !== emitter;
                    return !setChanged
                });
                this._emittersSet = currentSet;
                return setChanged
            },
            _closestEmitter: function(e) {
                var that = this,
                    result = [],
                    $element = $(e.target);

                function handleEmitter(_, emitter) {
                    if (!!emitter && emitter.validatePointers(e) && emitter.validate(e)) {
                        emitter.addCancelCallback(that._proxiedCancelHandler);
                        emitter.addAcceptCallback(that._proxiedAcceptHandler);
                        result.push(emitter)
                    }
                }
                while ($element.length) {
                    var emitters = $.data($element.get(0), EMITTER_DATA) || [];
                    $.each(emitters, handleEmitter);
                    $element = $element.parent()
                }
                return result
            },
            _acceptHandler: function(acceptedEmitter, e) {
                var that = this;
                this._eachEmitter(function(emitter) {
                    if (emitter !== acceptedEmitter) {
                        that._cancelEmitter(emitter, e)
                    }
                })
            },
            _cancelHandler: function(canceledEmitter, e) {
                this._cancelEmitter(canceledEmitter, e)
            },
            _cancelEmitter: function(emitter, e) {
                var activeEmitters = this._activeEmitters;
                if (e) {
                    emitter.cancel(e)
                } else {
                    emitter.reset()
                }
                emitter.removeCancelCallback();
                emitter.removeAcceptCallback();
                var emitterIndex = $.inArray(emitter, activeEmitters);
                if (emitterIndex > -1) {
                    activeEmitters.splice(emitterIndex, 1)
                }
            },
            _cleanEmitters: function(e) {
                this._applyToEmitters("end", e);
                this.reset(e)
            },
            _fetchEmitters: function(e) {
                this._activeEmitters = this._emittersSet.slice();
                this._applyToEmitters("start", e)
            },
            _pointerMoveHandler: function(e) {
                this._applyToEmitters("move", e)
            },
            _pointerUpHandler: function(e) {
                this._updateEmitters(e)
            },
            _mouseWheelHandler: function(e) {
                if (!this._allowInterruptionByMousewheel()) {
                    return
                }
                e.pointers = [null];
                this._pointerDownHandler(e);
                this._adjustWheelEvent(e);
                this._pointerMoveHandler(e);
                e.pointers = [];
                this._pointerUpHandler(e)
            },
            _allowInterruptionByMousewheel: function() {
                var allowInterruption = true;
                this._eachEmitter(function(emitter) {
                    allowInterruption = emitter.allowInterruptionByMousewheel() && allowInterruption;
                    return allowInterruption
                });
                return allowInterruption
            },
            _adjustWheelEvent: function(e) {
                var closestGestureEmitter = null;
                this._eachEmitter(function(emitter) {
                    if (!emitter.gesture) {
                        return
                    }
                    var direction = emitter.getDirection(e);
                    if ("horizontal" !== direction && !e.shiftKey || "vertical" !== direction && e.shiftKey) {
                        closestGestureEmitter = emitter;
                        return false
                    }
                });
                if (!closestGestureEmitter) {
                    return
                }
                var direction = closestGestureEmitter.getDirection(e),
                    verticalGestureDirection = "both" === direction && !e.shiftKey || "vertical" === direction,
                    prop = verticalGestureDirection ? "pageY" : "pageX";
                e[prop] += e.delta
            },
            isActive: function(element) {
                var result = false;
                this._eachEmitter(function(emitter) {
                    result = result || emitter.getElement().is(element)
                });
                return result
            }
        });
        var eventManager = new EventManager;
        var EMITTER_SUBSCRIPTION_DATA = "dxEmitterSubscription";
        var registerEmitter = function(emitterConfig) {
            var emitterClass = emitterConfig.emitter,
                emitterName = emitterConfig.events[0],
                emitterEvents = emitterConfig.events;
            $.each(emitterEvents, function(_, eventName) {
                registerEvent(eventName, {
                    noBubble: !emitterConfig.bubble,
                    setup: function(element, data) {
                        var subscriptions = $.data(element, EMITTER_SUBSCRIPTION_DATA) || {},
                            emitters = $.data(element, EMITTER_DATA) || {},
                            emitter = emitters[emitterName] || new emitterClass(element);
                        subscriptions[eventName] = true;
                        emitters[emitterName] = emitter;
                        $.data(element, EMITTER_DATA, emitters);
                        $.data(element, EMITTER_SUBSCRIPTION_DATA, subscriptions)
                    },
                    add: function(element, handleObj) {
                        var emitters = $.data(element, EMITTER_DATA),
                            emitter = emitters[emitterName];
                        emitter.configurate($.extend({
                            delegateSelector: handleObj.selector
                        }, handleObj.data), handleObj.type)
                    },
                    teardown: function(element) {
                        var subscriptions = $.data(element, EMITTER_SUBSCRIPTION_DATA),
                            emitters = $.data(element, EMITTER_DATA),
                            emitter = emitters[emitterName];
                        delete subscriptions[eventName];
                        var disposeEmitter = true;
                        $.each(emitterEvents, function(_, eventName) {
                            disposeEmitter = disposeEmitter && !subscriptions[eventName];
                            return disposeEmitter
                        });
                        if (disposeEmitter) {
                            if (eventManager.isActive(element)) {
                                eventManager.resetEmitter(emitter)
                            }
                            emitter && emitter.dispose();
                            delete emitters[emitterName]
                        }
                    }
                })
            })
        };
        module.exports = registerEmitter
    },
    /*!**************************************!*\
      !*** ./Scripts/events/core/wheel.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerEvent = __webpack_require__( /*! ./event_registrator */ 66),
            eventUtils = __webpack_require__( /*! ../utils */ 62);
        var EVENT_NAME = "dxmousewheel",
            EVENT_NAMESPACE = "dxWheel";
        $.event.fixHooks.wheel = $.event.mouseHooks;
        var wheelEvent = void 0 !== document.onwheel ? "wheel" : "mousewheel";
        var wheel = {
            setup: function(element, data) {
                var $element = $(element);
                $element.on(eventUtils.addNamespace(wheelEvent, EVENT_NAMESPACE), $.proxy(wheel._wheelHandler, wheel))
            },
            teardown: function(element) {
                var $element = $(element);
                $element.off("." + EVENT_NAMESPACE)
            },
            _wheelHandler: function(e) {
                var delta = this._getWheelDelta(e.originalEvent);
                eventUtils.fireEvent({
                    type: EVENT_NAME,
                    originalEvent: e,
                    delta: delta,
                    pointerType: "mouse"
                });
                e.stopPropagation()
            },
            _getWheelDelta: function(event) {
                return event.wheelDelta ? event.wheelDelta : 30 * -event.deltaY
            }
        };
        registerEvent(EVENT_NAME, wheel);
        exports.name = EVENT_NAME
    },
    /*!***************************************************!*\
      !*** ./Scripts/events/gesture/emitter.gesture.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            mathUtils = __webpack_require__( /*! ../../core/utils/math */ 79),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            eventUtils = __webpack_require__( /*! ../utils */ 62),
            Emitter = __webpack_require__( /*! ../core/emitter */ 75),
            sign = mathUtils.sign,
            abs = Math.abs;
        var SLEEP = 0,
            INITED = 1,
            STARTED = 2,
            TOUCH_BOUNDARY = 10,
            IMMEDIATE_TOUCH_BOUNDARY = 0,
            IMMEDIATE_TIMEOUT = 180;
        var isMousewheelEvent = function(e) {
            return e && "dxmousewheel" === e.type
        };
        var supportPointerEvents = function() {
            var cssSupport = support.styleProp("pointer-events");
            var msieLess11 = browser.msie && parseInt(browser.version, 10) < 11;
            return cssSupport && !msieLess11
        };
        var gestureCover = function() {
            var GESTURE_COVER_CLASS = "dx-gesture-cover";
            var isDesktop = "generic" === devices.real().platform;
            if (!supportPointerEvents() || !isDesktop) {
                return $.noop
            }
            var $cover = $("<div>").addClass(GESTURE_COVER_CLASS).css("pointerEvents", "none");
            $cover.on("dxmousewheel", function(e) {
                e.preventDefault()
            });
            $(function() {
                $cover.appendTo("body")
            });
            return function(toggle, cursor) {
                $cover.css("pointerEvents", toggle ? "all" : "none");
                toggle && $cover.css("cursor", cursor)
            }
        }();
        var GestureEmitter = Emitter.inherit({
            gesture: true,
            configurate: function(data) {
                this.getElement().css("msTouchAction", data.immediate ? "pinch-zoom" : "");
                this.callBase(data)
            },
            allowInterruptionByMousewheel: function() {
                return this._stage !== STARTED
            },
            getDirection: function() {
                return this.direction
            },
            _cancel: function(e) {
                this.callBase.apply(this, arguments);
                this._toggleGestureCover(false);
                this._stage = SLEEP
            },
            start: function(e) {
                if (eventUtils.needSkipEvent(e)) {
                    this._cancel(e);
                    return
                }
                this._startEvent = eventUtils.createEvent(e);
                this._startEventData = eventUtils.eventData(e);
                this._prevEventData = this._startEventData;
                this._stage = INITED;
                this._init(e);
                this._setupImmediateTimer()
            },
            _setupImmediateTimer: function() {
                clearTimeout(this._immediateTimer);
                this._immediateAccepted = false;
                if (!this.immediate) {
                    return
                }
                this._immediateTimer = setTimeout($.proxy(function() {
                    this._immediateAccepted = true
                }, this), IMMEDIATE_TIMEOUT)
            },
            move: function(e) {
                if (this._stage === INITED && this._directionConfirmed(e)) {
                    this._stage = STARTED;
                    this._resetActiveElement();
                    this._toggleGestureCover(true, e);
                    this._clearSelection(e);
                    this._adjustStartEvent(e);
                    this._start(this._startEvent);
                    this._prevEventData = eventUtils.eventData(this._startEvent);
                    if (this._stage === SLEEP) {
                        return
                    }
                    this._requestAccept(e);
                    this._move(e);
                    this._forgetAccept()
                } else {
                    if (this._stage === STARTED) {
                        this._clearSelection(e);
                        this._move(e)
                    }
                }
                this._prevEventData = eventUtils.eventData(e)
            },
            _directionConfirmed: function(e) {
                var touchBoundary = this._getTouchBoundary(e),
                    delta = eventUtils.eventDelta(this._startEventData, eventUtils.eventData(e)),
                    deltaX = abs(delta.x),
                    deltaY = abs(delta.y);
                var horizontalMove = this._validateMove(touchBoundary, deltaX, deltaY),
                    verticalMove = this._validateMove(touchBoundary, deltaY, deltaX);
                var direction = this.getDirection(e),
                    bothAccepted = "both" === direction && (horizontalMove || verticalMove),
                    horizontalAccepted = "horizontal" === direction && horizontalMove,
                    verticalAccepted = "vertical" === direction && verticalMove;
                return bothAccepted || horizontalAccepted || verticalAccepted || this._immediateAccepted
            },
            _validateMove: function(touchBoundary, mainAxis, crossAxis) {
                return mainAxis && mainAxis >= touchBoundary && (this.immediate ? mainAxis >= crossAxis : true)
            },
            _getTouchBoundary: function(e) {
                return this.immediate || isMousewheelEvent(e) ? IMMEDIATE_TOUCH_BOUNDARY : TOUCH_BOUNDARY
            },
            _adjustStartEvent: function(e) {
                var touchBoundary = this._getTouchBoundary(e),
                    delta = eventUtils.eventDelta(this._startEventData, eventUtils.eventData(e));
                this._startEvent.pageX += sign(delta.x) * touchBoundary;
                this._startEvent.pageY += sign(delta.y) * touchBoundary
            },
            _resetActiveElement: function() {
                if ("ios" === devices.real().platform && $(":focus", this.getElement()).length) {
                    domUtils.resetActiveElement()
                }
            },
            _toggleGestureCover: function(toggle, e) {
                var isStarted = this._stage === STARTED;
                if (isStarted) {
                    gestureCover(toggle, this.getElement().css("cursor"))
                }
            },
            _clearSelection: function(e) {
                if (isMousewheelEvent(e) || eventUtils.isTouchEvent(e)) {
                    return
                }
                domUtils.clearSelection()
            },
            end: function(e) {
                this._toggleGestureCover(false, e);
                if (this._stage === STARTED) {
                    this._end(e)
                } else {
                    if (this._stage === INITED) {
                        this._stop(e)
                    }
                }
                this._stage = SLEEP
            },
            dispose: function() {
                clearTimeout(this._immediateTimer);
                this.callBase.apply(this, arguments);
                this._toggleGestureCover(false)
            },
            _init: $.noop,
            _start: $.noop,
            _move: $.noop,
            _stop: $.noop,
            _end: $.noop
        });
        GestureEmitter.initialTouchBoundary = TOUCH_BOUNDARY;
        GestureEmitter.touchBoundary = function(newBoundary) {
            if (commonUtils.isDefined(newBoundary)) {
                TOUCH_BOUNDARY = newBoundary;
                return
            }
            return TOUCH_BOUNDARY
        };
        module.exports = GestureEmitter
    },
    /*!************************************!*\
      !*** ./Scripts/core/utils/math.js ***!
      \************************************/
    function(module, exports) {
        var sign = function(value) {
            if (0 === value) {
                return 0
            }
            return value / Math.abs(value)
        };
        var fitIntoRange = function(value, minValue, maxValue) {
            return Math.min(Math.max(value, minValue), maxValue)
        };
        exports.sign = sign;
        exports.fitIntoRange = fitIntoRange
    },
    /*!*****************************************!*\
      !*** ./Scripts/localization/message.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dependencyInjector = __webpack_require__( /*! ../core/utils/dependency_injector */ 23),
            stringFormat = __webpack_require__( /*! ../core/utils/string */ 13).format,
            humanize = __webpack_require__( /*! ../core/utils/inflector */ 49).humanize;
        __webpack_require__( /*! ./core */ 57);
        var baseDictionary = $.extend(true, {}, __webpack_require__( /*! ./en/core.en */ 81), __webpack_require__( /*! ./en/widgets-base.en */ 82), __webpack_require__( /*! ./en/widgets-mobile.en */ 83), __webpack_require__( /*! ./en/widgets-web.en */ 84));
        var newMessages = {};
        var messageLocalization = dependencyInjector({
            _dictionary: baseDictionary,
            locale: function() {
                var currentLocale = "en";
                return function(locale) {
                    if (!locale) {
                        return currentLocale
                    }
                    currentLocale = locale
                }
            }(),
            load: function(messages) {
                $.extend(true, this._dictionary, messages)
            },
            _localizablePrefix: "@",
            setup: function(localizablePrefix) {
                this._localizablePrefix = localizablePrefix
            },
            localizeString: function(text) {
                var that = this,
                    regex = new RegExp("(^|[^a-zA-Z_0-9" + that._localizablePrefix + "-]+)(" + that._localizablePrefix + "{1,2})([a-zA-Z_0-9-]+)", "g"),
                    escapeString = that._localizablePrefix + that._localizablePrefix;
                return text.replace(regex, function(str, prefix, escape, localizationKey) {
                    var result, defaultResult = that._localizablePrefix + localizationKey;
                    if (escape !== escapeString) {
                        result = that.format(localizationKey)
                    }
                    if (!result) {
                        newMessages[localizationKey] = humanize(localizationKey)
                    }
                    return prefix + (result || defaultResult)
                })
            },
            _messageLoaded: function(key, locale) {
                return void 0 !== this._dictionary[locale || this.locale()][key]
            },
            localizeNode: function(node) {
                var that = this;
                $(node).each(function(index, nodeItem) {
                    if (!nodeItem.nodeType) {
                        return
                    }
                    if (3 === nodeItem.nodeType) {
                        nodeItem.nodeValue = that.localizeString(nodeItem.nodeValue)
                    } else {
                        if (!$(nodeItem).is("iframe")) {
                            $.each(nodeItem.attributes || [], function(index, attr) {
                                if ("string" === typeof attr.value) {
                                    var localizedValue = that.localizeString(attr.value);
                                    if (attr.value !== localizedValue) {
                                        attr.value = localizedValue
                                    }
                                }
                            });
                            $(nodeItem).contents().each(function(index, node) {
                                that.localizeNode(node)
                            })
                        }
                    }
                })
            },
            getMessagesByLocales: function() {
                return this._dictionary
            },
            getDictionary: function(onlyNew) {
                if (onlyNew) {
                    return newMessages
                }
                return $.extend({}, newMessages, this.getMessagesByLocales()[this.locale()])
            },
            getFormatter: function(key, locale) {
                var localeMessages = this._dictionary[locale || this.locale()],
                    message = localeMessages && localeMessages[key];
                if (message) {
                    return function() {
                        var args = 1 === arguments.length && Array.isArray(arguments[0]) ? arguments[0].slice(0) : Array.prototype.slice.call(arguments, 0);
                        args.unshift(message);
                        return stringFormat.apply(this, args)
                    }
                }
            },
            format: function(key) {
                var formatter = this.getFormatter(key);
                return formatter && formatter() || ""
            }
        });
        module.exports = messageLocalization
    },
    /*!********************************************!*\
      !*** ./Scripts/localization/en/core.en.js ***!
      \********************************************/
    function(module, exports) {
        module.exports = {
            en: {
                Yes: "Yes",
                No: "No",
                Cancel: "Cancel",
                Clear: "Clear",
                Done: "Done",
                Loading: "Loading...",
                Select: "Select...",
                Search: "Search",
                Back: "Back",
                OK: "OK",
                "dxCollectionWidget-noDataText": "No data to display",
                "validation-required": "Required",
                "validation-required-formatted": "{0} is required",
                "validation-numeric": "Value must be a number",
                "validation-numeric-formatted": "{0} must be a number",
                "validation-range": "Value is out of range",
                "validation-range-formatted": "{0} is out of range",
                "validation-stringLength": "The length of the value is not correct",
                "validation-stringLength-formatted": "The length of {0} is not correct",
                "validation-custom": "Value is invalid",
                "validation-custom-formatted": "{0} is invalid",
                "validation-compare": "Values do not match",
                "validation-compare-formatted": "{0} does not match",
                "validation-pattern": "Value does not match pattern",
                "validation-pattern-formatted": "{0} does not match pattern",
                "validation-email": "Email is invalid",
                "validation-email-formatted": "{0} is invalid",
                "validation-mask": "Value is invalid"
            }
        }
    },
    /*!****************************************************!*\
      !*** ./Scripts/localization/en/widgets-base.en.js ***!
      \****************************************************/
    function(module, exports) {
        module.exports = {
            en: {
                "dxLookup-searchPlaceholder": "Minimum character number: {0}",
                "dxList-pullingDownText": "Pull down to refresh...",
                "dxList-pulledDownText": "Release to refresh...",
                "dxList-refreshingText": "Refreshing...",
                "dxList-pageLoadingText": "Loading...",
                "dxList-nextButtonText": "More",
                "dxList-selectAll": "Select All",
                "dxListEditDecorator-delete": "Delete",
                "dxListEditDecorator-more": "More",
                "dxScrollView-pullingDownText": "Pull down to refresh...",
                "dxScrollView-pulledDownText": "Release to refresh...",
                "dxScrollView-refreshingText": "Refreshing...",
                "dxScrollView-reachBottomText": "Loading...",
                "dxDateBox-simulatedDataPickerTitleTime": "Select time",
                "dxDateBox-simulatedDataPickerTitleDate": "Select date",
                "dxDateBox-simulatedDataPickerTitleDateTime": "Select date and time",
                "dxDateBox-validation-datetime": "Value must be a date or time",
                "dxFileUploader-selectFile": "Select file",
                "dxFileUploader-dropFile": "or Drop file here",
                "dxFileUploader-bytes": "bytes",
                "dxFileUploader-kb": "kb",
                "dxFileUploader-Mb": "Mb",
                "dxFileUploader-Gb": "Gb",
                "dxFileUploader-upload": "Upload",
                "dxFileUploader-uploaded": "Uploaded",
                "dxFileUploader-readyToUpload": "Ready to upload",
                "dxFileUploader-uploadFailedMessage": "Upload failed",
                "dxRangeSlider-ariaFrom": "From",
                "dxRangeSlider-ariaTill": "Till",
                "dxSwitch-onText": "ON",
                "dxSwitch-offText": "OFF",
                "dxForm-optionalMark": "optional",
                "dxForm-requiredMessage": "{0} is required",
                "dxNumberBox-invalidValueMessage": "Value must be a number"
            }
        }
    },
    /*!******************************************************!*\
      !*** ./Scripts/localization/en/widgets-mobile.en.js ***!
      \******************************************************/
    function(module, exports) {},
    /*!***************************************************!*\
      !*** ./Scripts/localization/en/widgets-web.en.js ***!
      \***************************************************/
    function(module, exports) {
        module.exports = {
            en: {
                "dxDataGrid-columnChooserTitle": "Column Chooser",
                "dxDataGrid-columnChooserEmptyText": "Drag a column here to hide it",
                "dxDataGrid-groupContinuesMessage": "Continues on the next page",
                "dxDataGrid-groupContinuedMessage": "Continued from the previous page",
                "dxDataGrid-groupHeaderText": "Group by This Column",
                "dxDataGrid-ungroupHeaderText": "Ungroup",
                "dxDataGrid-ungroupAllText": "Ungroup All",
                "dxDataGrid-editingEditRow": "Edit",
                "dxDataGrid-editingSaveRowChanges": "Save",
                "dxDataGrid-editingCancelRowChanges": "Cancel",
                "dxDataGrid-editingDeleteRow": "Delete",
                "dxDataGrid-editingUndeleteRow": "Undelete",
                "dxDataGrid-editingConfirmDeleteMessage": "Are you sure you want to delete this record?",
                "dxDataGrid-validationCancelChanges": "Cancel changes",
                "dxDataGrid-groupPanelEmptyText": "Drag a column header here to group by that column",
                "dxDataGrid-noDataText": "No data",
                "dxDataGrid-searchPanelPlaceholder": "Search...",
                "dxDataGrid-filterRowShowAllText": "(All)",
                "dxDataGrid-filterRowResetOperationText": "Reset",
                "dxDataGrid-filterRowOperationEquals": "Equals",
                "dxDataGrid-filterRowOperationNotEquals": "Does not equal",
                "dxDataGrid-filterRowOperationLess": "Less than",
                "dxDataGrid-filterRowOperationLessOrEquals": "Less than or equal to",
                "dxDataGrid-filterRowOperationGreater": "Greater than",
                "dxDataGrid-filterRowOperationGreaterOrEquals": "Greater than or equal to",
                "dxDataGrid-filterRowOperationStartsWith": "Starts with",
                "dxDataGrid-filterRowOperationContains": "Contains",
                "dxDataGrid-filterRowOperationNotContains": "Does not contain",
                "dxDataGrid-filterRowOperationEndsWith": "Ends with",
                "dxDataGrid-filterRowOperationBetween": "Between",
                "dxDataGrid-filterRowOperationBetweenStartText": "Start",
                "dxDataGrid-filterRowOperationBetweenEndText": "End",
                "dxDataGrid-applyFilterText": "Apply filter",
                "dxDataGrid-trueText": "true",
                "dxDataGrid-falseText": "false",
                "dxDataGrid-sortingAscendingText": "Sort Ascending",
                "dxDataGrid-sortingDescendingText": "Sort Descending",
                "dxDataGrid-sortingClearText": "Clear Sorting",
                "dxDataGrid-editingSaveAllChanges": "Save changes",
                "dxDataGrid-editingCancelAllChanges": "Discard changes",
                "dxDataGrid-editingAddRow": "Add a row",
                "dxDataGrid-summaryMin": "Min: {0}",
                "dxDataGrid-summaryMinOtherColumn": "Min of {1} is {0}",
                "dxDataGrid-summaryMax": "Max: {0}",
                "dxDataGrid-summaryMaxOtherColumn": "Max of {1} is {0}",
                "dxDataGrid-summaryAvg": "Avg: {0}",
                "dxDataGrid-summaryAvgOtherColumn": "Avg of {1} is {0}",
                "dxDataGrid-summarySum": "Sum: {0}",
                "dxDataGrid-summarySumOtherColumn": "Sum of {1} is {0}",
                "dxDataGrid-summaryCount": "Count: {0}",
                "dxDataGrid-columnFixingFix": "Fix",
                "dxDataGrid-columnFixingUnfix": "Unfix",
                "dxDataGrid-columnFixingLeftPosition": "To the left",
                "dxDataGrid-columnFixingRightPosition": "To the right",
                "dxDataGrid-exportTo": "Export",
                "dxDataGrid-exportToExcel": "Export to Excel file",
                "dxDataGrid-excelFormat": "Excel file",
                "dxDataGrid-selectedRows": "Selected rows",
                "dxDataGrid-exportSelectedRows": "Export selected rows",
                "dxDataGrid-exportAll": "Export all data",
                "dxDataGrid-headerFilterEmptyValue": "(Blanks)",
                "dxDataGrid-headerFilterOK": "OK",
                "dxDataGrid-headerFilterCancel": "Cancel",
                "dxDataGrid-ariaColumn": "Column",
                "dxDataGrid-ariaValue": "Value",
                "dxDataGrid-ariaFilterCell": "Filter cell",
                "dxDataGrid-ariaCollapse": "Collapse",
                "dxDataGrid-ariaExpand": "Expand",
                "dxDataGrid-ariaDataGrid": "Data grid",
                "dxDataGrid-ariaSearchInGrid": "Search in data grid",
                "dxDataGrid-ariaSelectAll": "Select all",
                "dxDataGrid-ariaSelectRow": "Select row",
                "dxPager-infoText": "Page {0} of {1} ({2} items)",
                "dxPager-pagesCountText": "of",
                "dxPivotGrid-grandTotal": "Grand Total",
                "dxPivotGrid-total": "{0} Total",
                "dxPivotGrid-fieldChooserTitle": "Field Chooser",
                "dxPivotGrid-showFieldChooser": "Show Field Chooser",
                "dxPivotGrid-expandAll": "Expand All",
                "dxPivotGrid-collapseAll": "Collapse All",
                "dxPivotGrid-sortColumnBySummary": 'Sort "{0}" by This Column',
                "dxPivotGrid-sortRowBySummary": 'Sort "{0}" by This Row',
                "dxPivotGrid-removeAllSorting": "Remove All Sorting",
                "dxPivotGrid-rowFields": "Row Fields",
                "dxPivotGrid-columnFields": "Column Fields",
                "dxPivotGrid-dataFields": "Data Fields",
                "dxPivotGrid-filterFields": "Filter Fields",
                "dxPivotGrid-allFields": "All Fields",
                "dxPivotGrid-columnFieldArea": "Drop Column Fields Here",
                "dxPivotGrid-dataFieldArea": "Drop Data Fields Here",
                "dxPivotGrid-rowFieldArea": "Drop Row Fields Here",
                "dxPivotGrid-filterFieldArea": "Drop Filter Fields Here",
                "dxScheduler-editorLabelTitle": "Subject",
                "dxScheduler-editorLabelStartDate": "Start Date",
                "dxScheduler-editorLabelEndDate": "End Date",
                "dxScheduler-editorLabelDescription": "Description",
                "dxScheduler-editorLabelRecurrence": "Repeat",
                "dxScheduler-openAppointment": "Open appointment",
                "dxScheduler-recurrenceNever": "Never",
                "dxScheduler-recurrenceDaily": "Daily",
                "dxScheduler-recurrenceWeekly": "Weekly",
                "dxScheduler-recurrenceMonthly": "Monthly",
                "dxScheduler-recurrenceYearly": "Yearly",
                "dxScheduler-recurrenceEvery": "Every",
                "dxScheduler-recurrenceEnd": "End repeat",
                "dxScheduler-recurrenceAfter": "After",
                "dxScheduler-recurrenceOn": "On",
                "dxScheduler-recurrenceRepeatDaily": "day(s)",
                "dxScheduler-recurrenceRepeatWeekly": "week(s)",
                "dxScheduler-recurrenceRepeatMonthly": "month(s)",
                "dxScheduler-recurrenceRepeatYearly": "year(s)",
                "dxScheduler-switcherDay": "Day",
                "dxScheduler-switcherWeek": "Week",
                "dxScheduler-switcherWorkWeek": "Work week",
                "dxScheduler-switcherMonth": "Month",
                "dxScheduler-switcherAgenda": "Agenda",
                "dxScheduler-switcherTimelineDay": "Timeline Day",
                "dxScheduler-switcherTimelineWeek": "Timeline Week",
                "dxScheduler-switcherTimelineWorkWeek": "Timeline Work Week",
                "dxScheduler-switcherTimelineMonth": "Timeline Month",
                "dxScheduler-recurrenceRepeatOnDate": "on date",
                "dxScheduler-recurrenceRepeatCount": "occurrence(s)",
                "dxScheduler-allDay": "All day",
                "dxScheduler-confirmRecurrenceEditMessage": "Do you want to edit only this appointment or the whole series?",
                "dxScheduler-confirmRecurrenceDeleteMessage": "Do you want to delete only this appointment or the whole series?",
                "dxScheduler-confirmRecurrenceEditSeries": "Edit series",
                "dxScheduler-confirmRecurrenceDeleteSeries": "Delete series",
                "dxScheduler-confirmRecurrenceEditOccurrence": "Edit appointment",
                "dxScheduler-confirmRecurrenceDeleteOccurrence": "Delete appointment",
                "dxScheduler-noTimezoneTitle": "No timezone",
                "dxCalendar-todayButtonText": "Today",
                "dxCalendar-ariaWidgetName": "Calendar",
                "dxColorView-ariaRed": "Red",
                "dxColorView-ariaGreen": "Green",
                "dxColorView-ariaBlue": "Blue",
                "dxColorView-ariaAlpha": "Transparency",
                "dxColorView-ariaHex": "Color code",
                "vizExport-printingButtonText": "Print",
                "vizExport-titleMenuText": "Exporting/Printing",
                "vizExport-exportButtonText": "{0} file"
            }
        }
    },
    /*!**********************************************!*\
      !*** ./Scripts/bundles/modules/framework.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./core */ 6);
        __webpack_require__( /*! ../../integration/knockout */ 86);
        module.exports = DevExpress.framework = {};
        DevExpress.framework.dxCommand = __webpack_require__( /*! ../../framework/command */ 121);
        DevExpress.framework.Router = __webpack_require__( /*! ../../framework/router */ 123);
        DevExpress.framework.StateManager = __webpack_require__( /*! ../../framework/state_manager */ 124);
        DevExpress.framework.ViewCache = __webpack_require__( /*! ../../framework/view_cache */ 125);
        DevExpress.framework.NullViewCache = __webpack_require__( /*! ../../framework/view_cache */ 125).NullViewCache;
        DevExpress.framework.ConditionalViewCacheDecorator = __webpack_require__( /*! ../../framework/view_cache */ 125).ConditionalViewCacheDecorator;
        DevExpress.framework.CapacityViewCacheDecorator = __webpack_require__( /*! ../../framework/view_cache */ 125).CapacityViewCacheDecorator;
        DevExpress.framework.HistoryDependentViewCacheDecorator = __webpack_require__( /*! ../../framework/view_cache */ 125).HistoryDependentViewCacheDecorator;
        DevExpress.framework.dxCommandContainer = __webpack_require__( /*! ../../framework/html/command_container */ 126);
        DevExpress.framework.dxView = __webpack_require__( /*! ../../framework/html/view_engine_components */ 128).dxView;
        DevExpress.framework.dxLayout = __webpack_require__( /*! ../../framework/html/view_engine_components */ 128).dxLayout;
        DevExpress.framework.dxViewPlaceholder = __webpack_require__( /*! ../../framework/html/view_engine_components */ 128).dxViewPlaceholder;
        DevExpress.framework.dxContentPlaceholder = __webpack_require__( /*! ../../framework/html/view_engine_components */ 128).dxContentPlaceholder;
        DevExpress.framework.dxTransition = __webpack_require__( /*! ../../framework/html/view_engine_components */ 128).dxTransition;
        DevExpress.framework.dxContent = __webpack_require__( /*! ../../framework/html/view_engine_components */ 128).dxContent;
        DevExpress.framework.html = {};
        DevExpress.framework.html.HtmlApplication = __webpack_require__( /*! ../../framework/html/html_application */ 129);
        DevExpress.framework.Route = __webpack_require__( /*! ../../framework/router */ 123).Route;
        DevExpress.framework.MemoryKeyValueStorage = __webpack_require__( /*! ../../framework/state_manager */ 124).MemoryKeyValueStorage;
        DevExpress.framework.NavigationDevices = __webpack_require__( /*! ../../framework/navigation_devices */ 134);
        DevExpress.framework.NavigationManager = __webpack_require__( /*! ../../framework/navigation_manager */ 133);
        DevExpress.framework.createActionExecutors = __webpack_require__( /*! ../../framework/action_executors */ 132).createActionExecutors;
        DevExpress.framework.Application = __webpack_require__( /*! ../../framework/application */ 130).Application;
        var browserAdapters = __webpack_require__( /*! ../../framework/browser_adapters */ 135);
        DevExpress.framework.DefaultBrowserAdapter = browserAdapters.DefaultBrowserAdapter;
        DevExpress.framework.OldBrowserAdapter = browserAdapters.OldBrowserAdapter;
        DevExpress.framework.BuggyAndroidBrowserAdapter = browserAdapters.BuggyAndroidBrowserAdapter;
        DevExpress.framework.HistorylessBrowserAdapter = browserAdapters.HistorylessBrowserAdapter;
        DevExpress.framework.BuggyCordovaWP81BrowserAdapter = browserAdapters.BuggyCordovaWP81BrowserAdapter;
        DevExpress.framework.CommandMapping = __webpack_require__( /*! ../../framework/command_mapping */ 136);
        DevExpress.framework.HistoryBasedNavigationDevice = __webpack_require__( /*! ../../framework/navigation_devices */ 134).HistoryBasedNavigationDevice;
        DevExpress.framework.StackBasedNavigationDevice = __webpack_require__( /*! ../../framework/navigation_devices */ 134).StackBasedNavigationDevice;
        DevExpress.framework.HistoryBasedNavigationManager = __webpack_require__( /*! ../../framework/navigation_manager */ 133).HistoryBasedNavigationManager;
        DevExpress.framework.StackBasedNavigationManager = __webpack_require__( /*! ../../framework/navigation_manager */ 133).StackBasedNavigationManager;
        DevExpress.framework.NavigationStack = __webpack_require__( /*! ../../framework/navigation_manager */ 133).NavigationStack;
        DevExpress.framework.utils = __webpack_require__( /*! ../../framework/utils */ 131).utils;
        DevExpress.framework.templateProvider = __webpack_require__( /*! ../../framework/utils */ 131).templateProvider;
        DevExpress.framework.html.CommandManager = __webpack_require__( /*! ../../framework/html/command_manager */ 139);
        DevExpress.framework.html.HtmlApplication = __webpack_require__( /*! ../../framework/html/html_application */ 129);
        DevExpress.framework.html.layoutSets = __webpack_require__( /*! ../../framework/html/presets */ 138).layoutSets;
        DevExpress.framework.html.animationSets = __webpack_require__( /*! ../../framework/html/presets */ 138).animationSets;
        DevExpress.framework.html.DefaultLayoutController = __webpack_require__( /*! ../../framework/html/layout_controller */ 142).DefaultLayoutController;
        DevExpress.framework.html.layoutSets = __webpack_require__( /*! ../../framework/html/layout_controller */ 142).layoutSets;
        DevExpress.framework.html.MarkupComponent = __webpack_require__( /*! ../../framework/html/markup_component */ 127).MarkupComponent;
        DevExpress.framework.html.ViewEngine = __webpack_require__( /*! ../../framework/html/view_engine */ 141).ViewEngine;
        DevExpress.framework.html.ViewEngineComponents = __webpack_require__( /*! ../../framework/html/view_engine_components */ 128);
        var widgetCommandAdaptersModule = __webpack_require__( /*! ../../framework/html/widget_command_adapters */ 140);
        DevExpress.framework.html.commandToDXWidgetAdapters = {
            dxToolbar: widgetCommandAdaptersModule.dxToolbar,
            dxList: widgetCommandAdaptersModule.dxList,
            dxNavBar: widgetCommandAdaptersModule.dxNavBar,
            dxPivot: widgetCommandAdaptersModule.dxPivot,
            dxSlideOut: widgetCommandAdaptersModule.dxSlideOut
        }
    },
    /*!*****************************************!*\
      !*** ./Scripts/integration/knockout.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var ko = __webpack_require__( /*! knockout */ 87);
        if (ko) {
            var errors = __webpack_require__( /*! ../core/errors */ 17),
                compareVersion = __webpack_require__( /*! ../core/utils/version */ 45).compare;
            if (compareVersion(ko.version, [2, 3]) < 0) {
                throw errors.Error("E0013")
            }
            __webpack_require__( /*! ./knockout/component_registrator */ 88);
            __webpack_require__( /*! ./knockout/event_registrator */ 114);
            __webpack_require__( /*! ./knockout/components */ 115);
            __webpack_require__( /*! ./knockout/validation */ 116);
            __webpack_require__( /*! ./knockout/variable_wrapper_utils */ 118);
            __webpack_require__( /*! ./knockout/clean_node */ 119);
            __webpack_require__( /*! ./knockout/clean_node_old */ 120)
        }
    },
    /*!****************************!*\
      !*** external "window.ko" ***!
      \****************************/
    function(module, exports) {
        module.exports = window.ko
    },
    /*!***************************************************************!*\
      !*** ./Scripts/integration/knockout/component_registrator.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ko = __webpack_require__( /*! knockout */ 87),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Widget = __webpack_require__( /*! ../../ui/widget/ui.widget */ 89),
            KoTemplateProvider = __webpack_require__( /*! ./template_provider */ 104),
            Editor = __webpack_require__( /*! ../../ui/editor/editor */ 107),
            Locker = __webpack_require__( /*! ../../core/utils/locker */ 113);
        var LOCKS_DATA_KEY = "dxKoLocks",
            CREATED_WITH_KO_DATA_KEY = "dxKoCreation";
        var editorsBindingHandlers = [];
        var registerComponentKoBinding = function(componentName, componentClass) {
            if (componentClass.subclassOf(Editor)) {
                editorsBindingHandlers.push(componentName)
            }
            ko.bindingHandlers[componentName] = {
                init: function(domNode, valueAccessor) {
                    var $element = $(domNode),
                        optionChangedCallbacks = $.Callbacks(),
                        ctorOptions = {
                            templateProvider: KoTemplateProvider,
                            modelByElement: function($element) {
                                if ($element.length) {
                                    return ko.dataFor($element.get(0))
                                }
                            },
                            nestedComponentOptions: function(component) {
                                return {
                                    modelByElement: component.option("modelByElement"),
                                    nestedComponentOptions: component.option("nestedComponentOptions")
                                }
                            },
                            watchMethod: function(watchValue, callback, element) {
                                var values;
                                ko.computed(function() {
                                    if (values) {
                                        callback()
                                    }
                                    values = watchValue()
                                }, null, {
                                    disposeWhenNodeIsRemoved: element
                                })
                            },
                            _optionChangedCallbacks: optionChangedCallbacks
                        },
                        optionNameToModelMap = {};
                    var applyModelValueToOption = function(optionName, modelValue) {
                        var component = $element.data(componentName),
                            locks = $element.data(LOCKS_DATA_KEY),
                            optionValue = ko.unwrap(modelValue);
                        if (ko.isWriteableObservable(modelValue)) {
                            optionNameToModelMap[optionName] = modelValue
                        }
                        if (component) {
                            if (locks.locked(optionName)) {
                                return
                            }
                            locks.obtain(optionName);
                            try {
                                if (ko.ignoreDependencies) {
                                    ko.ignoreDependencies(component.option, component, [optionName, optionValue])
                                } else {
                                    component.option(optionName, optionValue)
                                }
                            } finally {
                                locks.release(optionName)
                            }
                        } else {
                            ctorOptions[optionName] = optionValue
                        }
                    };
                    var handleOptionChanged = function(args) {
                        var optionName = args.fullName,
                            optionValue = args.value;
                        if (!(optionName in optionNameToModelMap)) {
                            return
                        }
                        var $element = this._$element,
                            locks = $element.data(LOCKS_DATA_KEY);
                        if (locks.locked(optionName)) {
                            return
                        }
                        locks.obtain(optionName);
                        try {
                            optionNameToModelMap[optionName](optionValue)
                        } finally {
                            locks.release(optionName)
                        }
                    };
                    var createComponent = function() {
                        optionChangedCallbacks.add(handleOptionChanged);
                        $element.data(CREATED_WITH_KO_DATA_KEY, true).data(LOCKS_DATA_KEY, new Locker)[componentName](ctorOptions);
                        ctorOptions = null
                    };
                    var unwrapModelValue = function(currentModel, propertyName, propertyPath) {
                        var unwrappedPropertyValue;
                        ko.computed(function() {
                            var propertyValue = currentModel[propertyName];
                            applyModelValueToOption(propertyPath, propertyValue);
                            unwrappedPropertyValue = ko.unwrap(propertyValue)
                        }, null, {
                            disposeWhenNodeIsRemoved: domNode
                        });
                        if ($.isPlainObject(unwrappedPropertyValue)) {
                            unwrapModel(unwrappedPropertyValue, propertyPath)
                        }
                    };
                    var unwrapModel = function(model, propertyPath) {
                        for (var propertyName in model) {
                            if (model.hasOwnProperty(propertyName)) {
                                unwrapModelValue(model, propertyName, propertyPath ? [propertyPath, propertyName].join(".") : propertyName)
                            }
                        }
                    };
                    ko.computed(function() {
                        var component = $element.data(componentName),
                            model = ko.unwrap(valueAccessor());
                        if (component) {
                            component.beginUpdate()
                        }
                        unwrapModel(model);
                        if (component) {
                            component.endUpdate()
                        } else {
                            createComponent()
                        }
                    }, null, {
                        disposeWhenNodeIsRemoved: domNode
                    });
                    return {
                        controlsDescendantBindings: componentClass.subclassOf(Widget)
                    }
                }
            };
            if ("dxValidator" === componentName) {
                ko.bindingHandlers.dxValidator.after = editorsBindingHandlers
            }
        };
        registerComponent.callbacks.add(function(name, componentClass) {
            registerComponentKoBinding(name, componentClass)
        })
    },
    /*!****************************************!*\
      !*** ./Scripts/ui/widget/ui.widget.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ./ui.errors */ 10),
            Action = __webpack_require__( /*! ../../core/action */ 35),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            DOMComponent = __webpack_require__( /*! ../../core/dom_component */ 29),
            TemplateBase = __webpack_require__( /*! ./ui.template_base */ 90),
            DynamicTemplate = __webpack_require__( /*! ./ui.template.dynamic */ 91),
            EmptyTemplate = __webpack_require__( /*! ./ui.template.empty */ 92),
            MoveTemplate = __webpack_require__( /*! ./ui.template.move */ 93),
            TemplateProvider = __webpack_require__( /*! ./jquery.template_provider */ 94),
            KeyboardProcessor = __webpack_require__( /*! ./ui.keyboard_processor */ 100),
            selectors = __webpack_require__( /*! ./jquery.selectors */ 101),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            hoverEvents = __webpack_require__( /*! ../../events/hover */ 102),
            feedbackEvents = __webpack_require__( /*! ../../events/core/emitter.feedback */ 103),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        var UI_FEEDBACK = "UIFeedback",
            WIDGET_CLASS = "dx-widget",
            ACTIVE_STATE_CLASS = "dx-state-active",
            DISABLED_STATE_CLASS = "dx-state-disabled",
            INVISIBLE_STATE_CLASS = "dx-state-invisible",
            HOVER_STATE_CLASS = "dx-state-hover",
            FOCUSED_STATE_CLASS = "dx-state-focused",
            FEEDBACK_SHOW_TIMEOUT = 30,
            FEEDBACK_HIDE_TIMEOUT = 400,
            FOCUS_NAMESPACE = "Focus",
            ANONYMOUS_TEMPLATE_NAME = "template",
            TEXT_NODE = 3,
            TEMPLATE_SELECTOR = "[data-options*='dxTemplate']",
            TEMPLATE_WRAPPER_CLASS = "dx-template-wrapper";
        var beforeActivateExists = void 0 !== document.onbeforeactivate;
        var Widget = DOMComponent.inherit({
            _supportedKeys: function() {
                return {}
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    disabled: false,
                    visible: true,
                    hint: void 0,
                    activeStateEnabled: false,
                    onContentReady: null,
                    hoverStateEnabled: false,
                    focusStateEnabled: false,
                    tabIndex: 0,
                    accessKey: null,
                    onFocusIn: null,
                    onFocusOut: null,
                    watchMethod: $.noop,
                    _keyboardProcessor: void 0,
                    templateProvider: TemplateProvider,
                    _templates: {}
                })
            },
            _feedbackShowTimeout: FEEDBACK_SHOW_TIMEOUT,
            _feedbackHideTimeout: FEEDBACK_HIDE_TIMEOUT,
            _init: function() {
                this.callBase();
                this._tempTemplates = [];
                this._dynamicTemplates = {};
                this._initTemplates();
                this._initContentReadyAction()
            },
            _initTemplates: function() {
                this._extractTemplates();
                this._extractAnonymousTemplate()
            },
            _extractTemplates: function() {
                var templates = this.option("_templates"),
                    templateElements = this.element().contents().filter(TEMPLATE_SELECTOR);
                var templatesMap = {};
                templateElements.each(function(_, template) {
                    var templateOptions = domUtils.getElementOptions(template).dxTemplate;
                    if (!templateOptions) {
                        return
                    }
                    if (!templateOptions.name) {
                        throw errors.Error("E0023")
                    }
                    $(template).addClass(TEMPLATE_WRAPPER_CLASS).detach();
                    templatesMap[templateOptions.name] = templatesMap[templateOptions.name] || [];
                    templatesMap[templateOptions.name].push(template)
                });
                $.each(templatesMap, $.proxy(function(templateName, value) {
                    var deviceTemplate = this._findTemplateByDevice(value);
                    if (deviceTemplate) {
                        templates[templateName] = this._createTemplate(deviceTemplate, this)
                    }
                }, this))
            },
            _findTemplateByDevice: function(templates) {
                var suitableTemplate = commonUtils.findBestMatches(devices.current(), templates, function(template) {
                    return domUtils.getElementOptions(template).dxTemplate
                })[0];
                $.each(templates, function(index, template) {
                    if (template !== suitableTemplate) {
                        $(template).remove()
                    }
                });
                return suitableTemplate
            },
            _extractAnonymousTemplate: function() {
                var templates = this.option("_templates"),
                    anonymousTemplateName = this._getAnonymousTemplateName(),
                    $anonymousTemplate = this.element().contents().detach();
                var $notJunkTemplateContent = $anonymousTemplate.filter(function(_, element) {
                        var isTextNode = element.nodeType === TEXT_NODE,
                            isEmptyText = $.trim($(element).text()).length < 1;
                        return !(isTextNode && isEmptyText)
                    }),
                    onlyJunkTemplateContent = $notJunkTemplateContent.length < 1;
                if (!templates[anonymousTemplateName] && !onlyJunkTemplateContent) {
                    templates[anonymousTemplateName] = this._createTemplate($anonymousTemplate, this)
                }
            },
            _getAriaTarget: function() {
                return this._focusTarget()
            },
            _getAnonymousTemplateName: function() {
                return ANONYMOUS_TEMPLATE_NAME
            },
            _getTemplateByOption: function(optionName) {
                return this._getTemplate(this.option(optionName))
            },
            _getTemplate: function(templateSource) {
                if ($.isFunction(templateSource)) {
                    var that = this;
                    return new DynamicTemplate(function(options) {
                        var args = [];
                        if ("model" in options) {
                            args.push(options.model)
                        }
                        if ("index" in options) {
                            args.push(options.index)
                        }
                        args.push(options.container);
                        var templateSourceResult = templateSource.apply(that, args);
                        if (commonUtils.isDefined(templateSourceResult)) {
                            return that._acquireTemplate(templateSourceResult, this, true)
                        } else {
                            return new EmptyTemplate
                        }
                    }, this)
                }
                return this._acquireTemplate(templateSource, this)
            },
            _acquireTemplate: function(templateSource, owner, preferRenderer) {
                if (null == templateSource) {
                    return this._createTemplate(domUtils.normalizeTemplateElement(templateSource), owner)
                }
                if (templateSource instanceof TemplateBase || commonUtils.isFunction(templateSource.render)) {
                    return templateSource
                }
                if (templateSource.nodeType || templateSource.jquery) {
                    templateSource = $(templateSource);
                    if (preferRenderer && !templateSource.is("script")) {
                        return new MoveTemplate(templateSource, owner)
                    }
                    return this._createTemplate(templateSource, owner)
                }
                if ("string" === typeof templateSource) {
                    var userTemplate = this.option("_templates")[templateSource];
                    if (userTemplate) {
                        return userTemplate
                    }
                    var dynamicTemplate = this._dynamicTemplates[templateSource];
                    if (dynamicTemplate) {
                        return dynamicTemplate
                    }
                    var defaultTemplate = this.option("templateProvider").getTemplates(this)[templateSource];
                    if (defaultTemplate) {
                        return defaultTemplate
                    }
                    return this._createTemplate(domUtils.normalizeTemplateElement(templateSource), owner)
                }
                return this._acquireTemplate(templateSource.toString(), owner)
            },
            _createTemplate: function(element, owner) {
                var template = this.option("templateProvider").createTemplate(element, owner);
                this._tempTemplates.push(template);
                return template
            },
            _cleanTemplates: function() {
                var that = this;
                $.each(this.option("_templates"), function(_, template) {
                    if (that === template.owner()) {
                        template.dispose()
                    }
                });
                $.each(this._tempTemplates, function(_, template) {
                    template.dispose()
                })
            },
            _initContentReadyAction: function() {
                this._contentReadyAction = this._createActionByOption("onContentReady", {
                    excludeValidators: ["designMode", "disabled", "readOnly"]
                })
            },
            _render: function() {
                this.element().addClass(WIDGET_CLASS);
                this.callBase();
                this._toggleDisabledState(this.option("disabled"));
                this._toggleVisibility(this.option("visible"));
                this._renderHint();
                this._renderContent();
                this._renderFocusState();
                this._attachFeedbackEvents();
                this._attachHoverEvents()
            },
            _renderHint: function() {
                domUtils.toggleAttr(this.element(), "title", this.option("hint"))
            },
            _renderContent: function() {
                var that = this;
                commonUtils.deferRender(function() {
                    that._renderContentImpl()
                });
                that._fireContentReadyAction()
            },
            _renderContentImpl: $.noop,
            _fireContentReadyAction: function() {
                this._contentReadyAction()
            },
            _dispose: function() {
                this._cleanTemplates();
                this._contentReadyAction = null;
                this.callBase()
            },
            _clean: function() {
                this._cleanFocusState();
                this.callBase();
                this.element().empty()
            },
            _toggleVisibility: function(visible) {
                this.element().toggleClass(INVISIBLE_STATE_CLASS, !visible);
                this.setAria("hidden", !visible || void 0)
            },
            _renderFocusState: function() {
                if (!this.option("focusStateEnabled") || this.option("disabled")) {
                    return
                }
                this._renderFocusTarget();
                this._attachFocusEvents();
                this._attachKeyboardEvents();
                this._renderAccessKey()
            },
            _renderAccessKey: function() {
                var focusTarget = this._focusTarget();
                focusTarget.attr("accesskey", this.option("accessKey"));
                var clickNamespace = eventUtils.addNamespace(clickEvent.name, UI_FEEDBACK);
                focusTarget.off(clickNamespace);
                this.option("accessKey") && focusTarget.on(clickNamespace, $.proxy(function(e) {
                    if (eventUtils.isFakeClickEvent(e)) {
                        e.stopImmediatePropagation();
                        this.focus()
                    }
                }, this))
            },
            _eventBindingTarget: function() {
                return this.element()
            },
            _focusTarget: function() {
                return this._getActiveElement()
            },
            _getActiveElement: function() {
                var activeElement = this._eventBindingTarget();
                if (this._activeStateUnit) {
                    activeElement = activeElement.find(this._activeStateUnit).not("." + DISABLED_STATE_CLASS)
                }
                return activeElement
            },
            _renderFocusTarget: function() {
                this._focusTarget().attr("tabindex", this.option("tabIndex"))
            },
            _keyboardEventBindingTarget: function() {
                return this._eventBindingTarget()
            },
            _detachFocusEvents: function() {
                var $element = this._focusTarget(),
                    namespace = this.NAME + FOCUS_NAMESPACE,
                    focusEvents = eventUtils.addNamespace("focusin", namespace);
                focusEvents = focusEvents + " " + eventUtils.addNamespace("focusout", namespace);
                if (beforeActivateExists) {
                    focusEvents = focusEvents + " " + eventUtils.addNamespace("beforeactivate", namespace)
                }
                $element.off(focusEvents)
            },
            _attachFocusEvents: function() {
                var namespace = this.NAME + FOCUS_NAMESPACE,
                    focusInEvent = eventUtils.addNamespace("focusin", namespace),
                    focusOutEvent = eventUtils.addNamespace("focusout", namespace);
                this._focusTarget().on(focusInEvent, $.proxy(this._focusInHandler, this)).on(focusOutEvent, $.proxy(this._focusOutHandler, this));
                if (beforeActivateExists) {
                    var beforeactivateEvent = eventUtils.addNamespace("beforeactivate", namespace);
                    this._focusTarget().on(beforeactivateEvent, function(e) {
                        if (!$(e.target).is(selectors.focusable)) {
                            e.preventDefault()
                        }
                    })
                }
            },
            _refreshFocusEvent: function() {
                this._detachFocusEvents();
                this._attachFocusEvents()
            },
            _focusInHandler: function(e) {
                var that = this;
                that._createActionByOption("onFocusIn", {
                    beforeExecute: function() {
                        that._updateFocusState(e, true)
                    },
                    excludeValidators: ["readOnly"]
                })({
                    jQueryEvent: e
                })
            },
            _focusOutHandler: function(e) {
                var that = this;
                that._createActionByOption("onFocusOut", {
                    beforeExecute: function() {
                        that._updateFocusState(e, false)
                    },
                    excludeValidators: ["readOnly", "disabled"]
                })({
                    jQueryEvent: e
                })
            },
            _updateFocusState: function(e, isFocused) {
                var target = e.target;
                if ($.inArray(target, this._focusTarget()) !== -1) {
                    this._toggleFocusClass(isFocused, $(target))
                }
            },
            _toggleFocusClass: function(isFocused, $element) {
                var $focusTarget = $element && $element.length ? $element : this._focusTarget();
                $focusTarget.toggleClass(FOCUSED_STATE_CLASS, isFocused)
            },
            _hasFocusClass: function(element) {
                var $focusTarget = $(element || this._focusTarget());
                return $focusTarget.hasClass(FOCUSED_STATE_CLASS)
            },
            _attachKeyboardEvents: function() {
                var processor = this.option("_keyboardProcessor") || new KeyboardProcessor({
                    element: this._keyboardEventBindingTarget(),
                    focusTarget: this._focusTarget()
                });
                this._keyboardProcessor = processor.reinitialize(this._keyboardHandler, this)
            },
            _keyboardHandler: function(options) {
                var e = options.originalEvent,
                    key = options.key;
                var keys = this._supportedKeys(),
                    func = keys[key];
                if (void 0 !== func) {
                    var handler = $.proxy(func, this);
                    return handler(e) || false
                } else {
                    return true
                }
            },
            _refreshFocusState: function() {
                this._cleanFocusState();
                this._renderFocusState()
            },
            _cleanFocusState: function() {
                var $element = this._focusTarget();
                this._detachFocusEvents();
                this._toggleFocusClass(false);
                $element.removeAttr("tabindex");
                if (this._keyboardProcessor) {
                    this._keyboardProcessor.dispose()
                }
            },
            _attachHoverEvents: function() {
                var that = this,
                    hoverableSelector = that._activeStateUnit,
                    nameStart = eventUtils.addNamespace(hoverEvents.start, UI_FEEDBACK),
                    nameEnd = eventUtils.addNamespace(hoverEvents.end, UI_FEEDBACK);
                that._eventBindingTarget().off(nameStart, hoverableSelector).off(nameEnd, hoverableSelector);
                if (that.option("hoverStateEnabled")) {
                    var startAction = new Action(function(args) {
                        that._hoverStartHandler(args.event);
                        var $target = args.element;
                        that._refreshHoveredElement($target)
                    }, {
                        excludeValidators: ["readOnly"]
                    });
                    that._eventBindingTarget().on(nameStart, hoverableSelector, function(e) {
                        startAction.execute({
                            element: $(e.target),
                            event: e
                        })
                    }).on(nameEnd, hoverableSelector, function(e) {
                        that._hoverEndHandler(e);
                        that._forgetHoveredElement()
                    })
                } else {
                    that._toggleHoverClass(false)
                }
            },
            _hoverStartHandler: $.noop,
            _hoverEndHandler: $.noop,
            _attachFeedbackEvents: function() {
                var feedbackAction, feedbackActionDisabled, that = this,
                    feedbackSelector = that._activeStateUnit,
                    activeEventName = eventUtils.addNamespace(feedbackEvents.active, UI_FEEDBACK),
                    inactiveEventName = eventUtils.addNamespace(feedbackEvents.inactive, UI_FEEDBACK);
                that._eventBindingTarget().off(activeEventName, feedbackSelector).off(inactiveEventName, feedbackSelector);
                if (that.option("activeStateEnabled")) {
                    var feedbackActionHandler = function(args) {
                        var $element = args.element,
                            value = args.value,
                            jQueryEvent = args.jQueryEvent;
                        that._toggleActiveState($element, value, jQueryEvent)
                    };
                    that._eventBindingTarget().on(activeEventName, feedbackSelector, {
                        timeout: that._feedbackShowTimeout
                    }, function(e) {
                        feedbackAction = feedbackAction || new Action(feedbackActionHandler), feedbackAction.execute({
                            element: $(e.currentTarget),
                            value: true,
                            jQueryEvent: e
                        })
                    }).on(inactiveEventName, feedbackSelector, {
                        timeout: that._feedbackHideTimeout
                    }, function(e) {
                        feedbackActionDisabled = feedbackActionDisabled || new Action(feedbackActionHandler, {
                            excludeValidators: ["disabled", "readOnly"]
                        }), feedbackActionDisabled.execute({
                            element: $(e.currentTarget),
                            value: false,
                            jQueryEvent: e
                        })
                    })
                }
            },
            _toggleActiveState: function($element, value) {
                this._toggleHoverClass(!value);
                $element.toggleClass(ACTIVE_STATE_CLASS, value)
            },
            _refreshHoveredElement: function(hoveredElement) {
                var selector = this._activeStateUnit || this._eventBindingTarget();
                this._forgetHoveredElement();
                this._hoveredElement = hoveredElement.closest(selector);
                this._toggleHoverClass(true)
            },
            _forgetHoveredElement: function() {
                this._toggleHoverClass(false);
                delete this._hoveredElement
            },
            _toggleHoverClass: function(value) {
                if (this._hoveredElement) {
                    this._hoveredElement.toggleClass(HOVER_STATE_CLASS, value && this.option("hoverStateEnabled"))
                }
            },
            _toggleDisabledState: function(value) {
                this.element().toggleClass(DISABLED_STATE_CLASS, Boolean(value));
                this._toggleHoverClass(!value);
                this.setAria("disabled", value || void 0)
            },
            _setWidgetOption: function(widgetName, args) {
                if (!this[widgetName]) {
                    return
                }
                if ($.isPlainObject(args[0])) {
                    $.each(args[0], $.proxy(function(option, value) {
                        this._setWidgetOption(widgetName, [option, value])
                    }, this));
                    return
                }
                var optionName = args[0];
                var value = args[1];
                if (1 === args.length) {
                    value = this.option(optionName)
                }
                var widgetOptionMap = this[widgetName + "OptionMap"];
                this[widgetName].option(widgetOptionMap ? widgetOptionMap(optionName) : optionName, value)
            },
            _createComponent: function(element, name, config) {
                config = config || {};
                this._extendConfig(config, {
                    templateProvider: this.option("templateProvider"),
                    _templates: this.option("_templates")
                });
                return this.callBase(element, name, config)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "disabled":
                        this._toggleDisabledState(args.value);
                        this._refreshFocusState();
                        break;
                    case "hint":
                        this._renderHint();
                        break;
                    case "activeStateEnabled":
                        this._attachFeedbackEvents();
                        break;
                    case "hoverStateEnabled":
                        this._attachHoverEvents();
                        break;
                    case "tabIndex":
                    case "_keyboardProcessor":
                    case "focusStateEnabled":
                        this._refreshFocusState();
                        break;
                    case "onFocusIn":
                    case "onFocusOut":
                        break;
                    case "accessKey":
                        this._renderAccessKey();
                        break;
                    case "visible":
                        var visible = args.value;
                        this._toggleVisibility(visible);
                        if (this._isVisibilityChangeSupported()) {
                            this._checkVisibilityChanged(args.value ? "shown" : "hiding")
                        }
                        break;
                    case "onContentReady":
                        this._initContentReadyAction();
                        break;
                    case "_templates":
                    case "templateProvider":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _isVisible: function() {
                return this.callBase() && this.option("visible")
            },
            beginUpdate: function() {
                this._ready(false);
                this.callBase()
            },
            endUpdate: function() {
                this.callBase();
                if (this._initialized) {
                    this._ready(true)
                }
            },
            _ready: function(value) {
                if (0 === arguments.length) {
                    return this._isReady
                }
                this._isReady = value
            },
            setAria: function() {
                var setAttribute = function(option) {
                    var attrName = "role" === option.name || "id" === option.name ? option.name : "aria-" + option.name,
                        attrValue = option.value;
                    if (null === attrValue || void 0 === attrValue) {
                        attrValue = void 0
                    } else {
                        attrValue = attrValue.toString()
                    }
                    domUtils.toggleAttr(option.target, attrName, attrValue)
                };
                if (!$.isPlainObject(arguments[0])) {
                    setAttribute({
                        name: arguments[0],
                        value: arguments[1],
                        target: arguments[2] || this._getAriaTarget()
                    })
                } else {
                    var $target = arguments[1] || this._getAriaTarget();
                    $.each(arguments[0], function(key, value) {
                        setAttribute({
                            name: key,
                            value: value,
                            target: $target
                        })
                    })
                }
            },
            isReady: function() {
                return this._ready()
            },
            repaint: function() {
                this._refresh()
            },
            focus: function() {
                this._focusTarget().focus()
            },
            registerKeyHandler: function(key, handler) {
                var currentKeys = this._supportedKeys(),
                    addingKeys = {};
                addingKeys[key] = handler;
                this._supportedKeys = function() {
                    return $.extend(currentKeys, addingKeys)
                }
            }
        });
        module.exports = Widget
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/widget/ui.template_base.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            triggerShownEvent = __webpack_require__( /*! ../../core/utils/dom */ 50).triggerShownEvent,
            Class = __webpack_require__( /*! ../../core/class */ 20),
            abstract = Class.abstract;
        var renderedCallbacks = $.Callbacks();
        var TemplateBase = Class.inherit({
            ctor: function(element, owner) {
                this._element = $(element);
                this._owner = owner
            },
            owner: function() {
                return this._owner
            },
            render: function(options) {
                options = options || {};
                var data = options.model;
                if (options.container) {
                    data = this._prepareDataForContainer(data, options.container)
                }
                var $result = this._renderCore($.extend({}, options, {
                    model: data
                }));
                this._ensureResultInContainer($result, options.container);
                renderedCallbacks.fire($result, options.container);
                return $result
            },
            _ensureResultInContainer: function($result, $container) {
                if (!$container) {
                    return
                }
                var resultInContainer = $.contains($container.get(0), $result.get(0));
                $container.append($result);
                if (resultInContainer) {
                    return
                }
                var resultInBody = $.contains(document.body, $container.get(0));
                if (!resultInBody) {
                    return
                }
                triggerShownEvent($result)
            },
            source: function() {
                return this._element.clone()
            },
            _prepareDataForContainer: function(data) {
                return data
            },
            _renderCore: abstract,
            dispose: function() {
                this._owner = null
            }
        });
        module.exports = TemplateBase;
        module.exports.renderedCallbacks = renderedCallbacks
    },
    /*!**************************************************!*\
      !*** ./Scripts/ui/widget/ui.template.dynamic.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            TemplateBase = __webpack_require__( /*! ./ui.template_base */ 90);
        var DynamicTemplate = TemplateBase.inherit({
            ctor: function(compileFunction, owner) {
                this.callBase($(), owner);
                this._compileFunction = compileFunction
            },
            _renderCore: function(options) {
                var compiledTemplate = this._compileFunction(options);
                var renderResult = compiledTemplate.render(options);
                if (compiledTemplate.owner() === this) {
                    compiledTemplate.dispose()
                }
                return renderResult
            }
        });
        module.exports = DynamicTemplate
    },
    /*!************************************************!*\
      !*** ./Scripts/ui/widget/ui.template.empty.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            TemplateBase = __webpack_require__( /*! ./ui.template_base */ 90);
        var EmptyTemplate = TemplateBase.inherit({
            ctor: function(owner) {
                this.callBase($(), owner)
            },
            _renderCore: function() {
                return $()
            }
        });
        module.exports = EmptyTemplate
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/widget/ui.template.move.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var TemplateBase = __webpack_require__( /*! ./ui.template_base */ 90);
        var MoveTemplate = TemplateBase.inherit({
            _renderCore: function() {
                return this._element
            }
        });
        module.exports = MoveTemplate
    },
    /*!*******************************************************!*\
      !*** ./Scripts/ui/widget/jquery.template_provider.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            TemplateProviderBase = __webpack_require__( /*! ./ui.template_provider_base */ 95),
            Template = __webpack_require__( /*! ./jquery.template */ 96),
            FunctionTemplate = __webpack_require__( /*! ./ui.template.function */ 97),
            defaultTemplates = __webpack_require__( /*! ./jquery.default_templates */ 98);
        var TemplateProvider = TemplateProviderBase.inherit({
            createTemplate: function(element, owner) {
                return new Template(element, owner)
            },
            _templatesForWidget: function(widgetName) {
                var templateGenerators = defaultTemplates[widgetName] || {},
                    templates = {};
                $.each(templateGenerators, function(name, generator) {
                    templates[name] = new FunctionTemplate(function() {
                        var $markup = generator.apply(this, arguments);
                        if ("itemFrame" !== name) {
                            $markup = $markup.contents()
                        }
                        return $markup
                    }, templateProvider)
                });
                return templates
            }
        });
        var templateProvider = new TemplateProvider;
        module.exports = templateProvider
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/widget/ui.template_provider_base.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20);
        var abstract = Class.abstract;
        var TemplateProviderBase = Class.inherit({
            ctor: function() {
                this.widgetTemplatesCache = {}
            },
            createTemplate: abstract,
            getTemplates: function(widget) {
                return this._getWidgetTemplates(widget.constructor)
            },
            _getWidgetTemplates: function(widgetConstructor) {
                if (!widgetConstructor.publicName) {
                    return {}
                }
                return this._getCachedWidgetTemplates(widgetConstructor)
            },
            _getCachedWidgetTemplates: function(widgetConstructor) {
                var widgetName = widgetConstructor.publicName(),
                    templatesCache = this.widgetTemplatesCache;
                if (!templatesCache[widgetName]) {
                    templatesCache[widgetName] = $.extend({}, this._getWidgetTemplates(widgetConstructor.parent), this._templatesForWidget(widgetName))
                }
                return templatesCache[widgetName]
            },
            _templatesForWidget: abstract
        });
        module.exports = TemplateProviderBase
    },
    /*!**********************************************!*\
      !*** ./Scripts/ui/widget/jquery.template.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../../core/errors */ 17),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            TemplateBase = __webpack_require__( /*! ./ui.template_base */ 90),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50);
        var templateEngines = {};
        var registerTemplateEngine = function(name, templateEngine) {
            templateEngines[name] = templateEngine
        };
        var outerHtml = function(element) {
            element = $(element);
            var templateTag = element.length && element[0].nodeName.toLowerCase();
            if ("script" === templateTag) {
                return element.html()
            } else {
                element = $("<div>").append(element);
                return element.html()
            }
        };
        registerTemplateEngine("default", {
            compile: function(element) {
                return domUtils.normalizeTemplateElement(element)
            },
            render: function(template, data) {
                return template.clone()
            }
        });
        registerTemplateEngine("jquery-tmpl", {
            compile: function(element) {
                return outerHtml(element)
            },
            render: function(template, data) {
                return $.tmpl(template, data)
            }
        });
        registerTemplateEngine("jsrender", {
            compile: function(element) {
                return $.templates(outerHtml(element))
            },
            render: function(template, data) {
                return template.render(data)
            }
        });
        registerTemplateEngine("mustache", {
            compile: function(element) {
                return Mustache.compile(outerHtml(element))
            },
            render: function(template, data) {
                return template(data)
            }
        });
        registerTemplateEngine("hogan", {
            compile: function(element) {
                return Hogan.compile(outerHtml(element))
            },
            render: function(template, data) {
                return template.render(data)
            }
        });
        registerTemplateEngine("underscore", {
            compile: function(element) {
                return _.template(outerHtml(element))
            },
            render: function(template, data) {
                return template(data)
            }
        });
        registerTemplateEngine("handlebars", {
            compile: function(element) {
                return Handlebars.compile(outerHtml(element))
            },
            render: function(template, data) {
                return template(data)
            }
        });
        registerTemplateEngine("doT", {
            compile: function(element) {
                return doT.template(outerHtml(element))
            },
            render: function(template, data) {
                return template(data)
            }
        });
        var currentTemplateEngine;
        var setTemplateEngine = function(templateEngine) {
            if (commonUtils.isString(templateEngine)) {
                currentTemplateEngine = templateEngines[templateEngine];
                if (!currentTemplateEngine) {
                    throw errors.Error("E0020", templateEngine)
                }
            } else {
                currentTemplateEngine = templateEngine
            }
        };
        setTemplateEngine("default");
        var Template = TemplateBase.inherit({
            ctor: function(element, owner) {
                this.callBase(element, owner);
                this._compiledTemplate = currentTemplateEngine.compile(element)
            },
            _renderCore: function(options) {
                return $("<div>").append(currentTemplateEngine.render(this._compiledTemplate, options.model)).contents()
            }
        });
        module.exports = Template;
        module.exports.setTemplateEngine = setTemplateEngine
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/widget/ui.template.function.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            TemplateBase = __webpack_require__( /*! ./ui.template_base */ 90),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50);
        var FunctionTemplate = TemplateBase.inherit({
            ctor: function(render, owner) {
                this.callBase($(), owner);
                this._render = render
            },
            _renderCore: function(options) {
                return domUtils.normalizeTemplateElement(this._render(options.model, options.index, options.container))
            }
        });
        module.exports = FunctionTemplate
    },
    /*!*******************************************************!*\
      !*** ./Scripts/ui/widget/jquery.default_templates.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49),
            iconUtils = __webpack_require__( /*! ../../core/utils/icon */ 99),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            errors = __webpack_require__( /*! ../../core/errors */ 17),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var TEMPLATE_GENERATORS = {};
        var emptyTemplate = function() {
            return $()
        };
        var ITEM_CONTENT_PLACEHOLDER_CLASS = "dx-item-content-placeholder";
        TEMPLATE_GENERATORS.CollectionWidget = {
            item: function(itemData) {
                var $itemContent = $("<div>");
                if ($.isPlainObject(itemData)) {
                    if (itemData.text) {
                        $itemContent.text(itemData.text)
                    }
                    if (itemData.html) {
                        $itemContent.html(itemData.html)
                    }
                } else {
                    $itemContent.text(String(itemData))
                }
                return $itemContent
            },
            itemFrame: function(itemData) {
                var $itemFrame = $("<div>");
                $itemFrame.toggleClass("dx-state-invisible", void 0 !== itemData.visible && !itemData.visible);
                $itemFrame.toggleClass("dx-state-disabled", !!itemData.disabled);
                var $placeholder = $("<div>").addClass(ITEM_CONTENT_PLACEHOLDER_CLASS);
                $itemFrame.append($placeholder);
                return $itemFrame
            }
        };
        var BUTTON_TEXT_CLASS = "dx-button-text";
        TEMPLATE_GENERATORS.dxButton = {
            content: function(itemData) {
                var $itemContent = $("<div>"),
                    $iconElement = iconUtils.getImageContainer(itemData.icon),
                    $textContainer = itemData.text ? $("<span>").text(itemData.text).addClass(BUTTON_TEXT_CLASS) : void 0;
                $itemContent.append($iconElement).append($textContainer);
                return $itemContent
            }
        };
        var LIST_ITEM_BADGE_CONTAINER_CLASS = "dx-list-item-badge-container",
            LIST_ITEM_BADGE_CLASS = "dx-list-item-badge",
            BADGE_CLASS = "dx-badge",
            LIST_ITEM_CHEVRON_CONTAINER_CLASS = "dx-list-item-chevron-container",
            LIST_ITEM_CHEVRON_CLASS = "dx-list-item-chevron";
        TEMPLATE_GENERATORS.dxList = {
            item: function(itemData) {
                var $itemContent = TEMPLATE_GENERATORS.CollectionWidget.item(itemData);
                if (itemData.key) {
                    var $key = $("<div>").text(itemData.key);
                    $key.appendTo($itemContent)
                }
                return $itemContent
            },
            itemFrame: function(itemData) {
                var $itemFrame = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(itemData);
                if (itemData.badge) {
                    var $badgeContainer = $("<div>").addClass(LIST_ITEM_BADGE_CONTAINER_CLASS),
                        $badge = $("<div>").addClass(LIST_ITEM_BADGE_CLASS).addClass(BADGE_CLASS);
                    $badge.text(itemData.badge);
                    $badgeContainer.append($badge).appendTo($itemFrame)
                }
                if (itemData.showChevron) {
                    var $chevronContainer = $("<div>").addClass(LIST_ITEM_CHEVRON_CONTAINER_CLASS),
                        $chevron = $("<div>").addClass(LIST_ITEM_CHEVRON_CLASS);
                    $chevronContainer.append($chevron).appendTo($itemFrame)
                }
                return $itemFrame
            },
            group: function(groupData) {
                var $groupContent = $("<div>");
                if ($.isPlainObject(groupData)) {
                    if (groupData.key) {
                        $groupContent.text(groupData.key)
                    }
                } else {
                    $groupContent.html(String(groupData))
                }
                return $groupContent
            }
        };
        TEMPLATE_GENERATORS.dxDropDownMenu = {
            item: TEMPLATE_GENERATORS.dxList.item,
            content: TEMPLATE_GENERATORS.dxButton.content
        };
        TEMPLATE_GENERATORS.dxDropDownList = {
            item: TEMPLATE_GENERATORS.dxList.item
        };
        TEMPLATE_GENERATORS.dxRadioGroup = {
            item: TEMPLATE_GENERATORS.CollectionWidget.item
        };
        TEMPLATE_GENERATORS.dxScheduler = {
            item: function(itemData) {
                var $itemContent = TEMPLATE_GENERATORS.CollectionWidget.item(itemData);
                var $details = $("<div>").addClass("dx-scheduler-appointment-content-details");
                if (itemData.allDay) {
                    $("<div>").text(" All day: ").addClass("dx-scheduler-appointment-content-allday").appendTo($details)
                }
                if (itemData.startDate) {
                    $("<div>").text(dateLocalization.format(dateUtils.makeDate(itemData.startDate), "shorttime")).addClass("dx-scheduler-appointment-content-date").appendTo($details)
                }
                if (itemData.endDate) {
                    $("<div>").text(" - ").addClass("dx-scheduler-appointment-content-date").appendTo($details);
                    $("<div>").text(dateLocalization.format(dateUtils.makeDate(itemData.endDate), "shorttime")).addClass("dx-scheduler-appointment-content-date").appendTo($details)
                }
                $details.appendTo($itemContent);
                if (itemData.recurrenceRule) {
                    $("<span>").addClass("dx-scheduler-appointment-recurrence-icon dx-icon-repeat").appendTo($itemContent)
                }
                return $itemContent
            },
            appointmentTooltip: emptyTemplate,
            appointmentPopup: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxOverlay = {
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxSlideOutView = {
            menu: emptyTemplate,
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxSlideOut = {
            menuItem: TEMPLATE_GENERATORS.dxList.item,
            menuGroup: TEMPLATE_GENERATORS.dxList.group,
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxAccordion = {
            title: function(titleData) {
                var $titleContent = $("<div>"),
                    icon = titleData.icon,
                    iconSrc = titleData.iconSrc,
                    $iconElement = iconUtils.getImageContainer(icon || iconSrc);
                if ($.isPlainObject(titleData)) {
                    if (titleData.title) {
                        $titleContent.text(titleData.title)
                    }
                } else {
                    $titleContent.html(String(titleData))
                }
                $iconElement && $iconElement.prependTo($titleContent);
                return $titleContent
            },
            item: TEMPLATE_GENERATORS.CollectionWidget.item
        };
        TEMPLATE_GENERATORS.dxActionSheet = {
            item: function(itemData) {
                return $("<div>").append($("<div>").dxButton($.extend({
                    onClick: itemData.click
                }, itemData)))
            }
        };
        var GALLERY_IMAGE_CLASS = "dx-gallery-item-image";
        TEMPLATE_GENERATORS.dxGallery = {
            item: function(itemData) {
                var $itemContent = $("<div>"),
                    $img = $("<img>").addClass(GALLERY_IMAGE_CLASS);
                if ($.isPlainObject(itemData)) {
                    $img.attr({
                        src: itemData.imageSrc,
                        alt: itemData.imageAlt
                    }).appendTo($itemContent)
                } else {
                    $img.attr("src", String(itemData)).appendTo($itemContent)
                }
                return $itemContent
            }
        };
        var DX_MENU_ITEM_CAPTION_CLASS = "dx-menu-item-text",
            DX_MENU_ITEM_POPOUT_CLASS = "dx-menu-item-popout",
            DX_MENU_ITEM_POPOUT_CONTAINER_CLASS = "dx-menu-item-popout-container";
        TEMPLATE_GENERATORS.dxMenuBase = {
            item: function(itemData) {
                var $itemContent = $("<div>"),
                    icon = itemData.icon,
                    iconSrc = itemData.iconSrc,
                    $iconElement = iconUtils.getImageContainer(icon || iconSrc);
                $iconElement && $iconElement.appendTo($itemContent);
                var $itemCaption;
                if (!commonUtils.isPrimitive(itemData) && itemData.text) {
                    $itemCaption = $("<span>").addClass(DX_MENU_ITEM_CAPTION_CLASS).text(itemData.text)
                } else {
                    if (!$.isPlainObject(itemData)) {
                        $itemCaption = $("<span>").addClass(DX_MENU_ITEM_CAPTION_CLASS).html(String(itemData))
                    }
                }
                $itemContent.append($itemCaption);
                var $popOutImage, $popOutContainer;
                if (itemData.items && itemData.items.length > 0) {
                    $popOutContainer = $("<span>").addClass(DX_MENU_ITEM_POPOUT_CONTAINER_CLASS).appendTo($itemContent);
                    $popOutImage = $("<div>").addClass(DX_MENU_ITEM_POPOUT_CLASS).appendTo($popOutContainer)
                }
                return $itemContent
            }
        };
        var PANORAMA_ITEM_TITLE_CLASS = "dx-panorama-item-title";
        TEMPLATE_GENERATORS.dxPanorama = {
            itemFrame: function(itemData) {
                var $itemContent = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(itemData);
                if (itemData.title) {
                    var $itemHeader = $("<div>").addClass(PANORAMA_ITEM_TITLE_CLASS).text(itemData.title);
                    $itemContent.prepend($itemHeader)
                }
                return $itemContent
            }
        };
        TEMPLATE_GENERATORS.dxPivotTabs = {
            item: function(itemData) {
                var $itemContent = $("<div>");
                var $itemText;
                if (itemData && itemData.title) {
                    $itemText = $("<span>").text(itemData.title)
                } else {
                    $itemText = $("<span>").text(String(itemData))
                }
                $itemContent.html($itemText);
                return $itemContent
            }
        };
        TEMPLATE_GENERATORS.dxPivot = {
            title: TEMPLATE_GENERATORS.dxPivotTabs.item,
            content: emptyTemplate
        };
        var TABS_ITEM_TEXT_CLASS = "dx-tab-text";
        TEMPLATE_GENERATORS.dxTabs = {
            item: function(itemData) {
                var $itemContent = TEMPLATE_GENERATORS.CollectionWidget.item(itemData);
                if (itemData.html) {
                    return $itemContent
                }
                var icon = itemData.icon,
                    iconSrc = itemData.iconSrc,
                    $iconElement = iconUtils.getImageContainer(icon || iconSrc);
                if (!itemData.html) {
                    $itemContent.wrapInner($("<span>").addClass(TABS_ITEM_TEXT_CLASS))
                }
                $iconElement && $iconElement.prependTo($itemContent);
                return $itemContent
            },
            itemFrame: function(itemData) {
                var $badge = $(),
                    $itemFrame = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(itemData);
                if (itemData.badge) {
                    $badge = $("<div>", {
                        "class": "dx-tabs-item-badge dx-badge"
                    }).text(itemData.badge)
                }
                $itemFrame.append($badge);
                return $itemFrame
            }
        };
        TEMPLATE_GENERATORS.dxTabPanel = {
            item: TEMPLATE_GENERATORS.CollectionWidget.item,
            title: function(itemData) {
                var itemTitleData = itemData;
                if ($.isPlainObject(itemData)) {
                    itemTitleData = $.extend({}, itemData, {
                        text: itemData.title,
                        html: null
                    })
                }
                var $title = TEMPLATE_GENERATORS.dxTabs.item(itemTitleData);
                return $title
            }
        };
        var NAVBAR_ITEM_BADGE_CLASS = "dx-navbar-item-badge";
        TEMPLATE_GENERATORS.dxNavBar = {
            itemFrame: function(itemData) {
                var $itemFrame = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(itemData);
                if (itemData.badge) {
                    var $badge = $("<div>").addClass(NAVBAR_ITEM_BADGE_CLASS).addClass(BADGE_CLASS);
                    $badge.text(itemData.badge);
                    $badge.appendTo($itemFrame)
                }
                return $itemFrame
            }
        };
        TEMPLATE_GENERATORS.dxToolbarBase = {
            item: function(itemData) {
                var $itemContent = TEMPLATE_GENERATORS.CollectionWidget.item(itemData);
                var widgetName = itemData.widget;
                if (widgetName) {
                    var widgetElement = $("<div>").appendTo($itemContent),
                        options = itemData.options || {};
                    if ("button" === widgetName || "tabs" === widgetName || "dropDownMenu" === widgetName) {
                        var depricatedName = widgetName;
                        widgetName = inflector.camelize("dx-" + widgetName);
                        errors.log("W0001", "dxToolbar - 'widget' item field", depricatedName, "16.1", "Use: '" + widgetName + "' instead")
                    }
                    widgetElement[widgetName](options)
                } else {
                    if (itemData.text) {
                        $itemContent.wrapInner("<div>")
                    }
                }
                return $itemContent
            },
            actionSheetItem: TEMPLATE_GENERATORS.dxActionSheet.item
        };
        TEMPLATE_GENERATORS.dxToolbarBase.menuItem = TEMPLATE_GENERATORS.dxToolbarBase.item;
        TEMPLATE_GENERATORS.dxTreeView = {
            item: function(itemData) {
                var $itemContent = $("<div>"),
                    icon = itemData.icon,
                    iconSrc = itemData.iconSrc,
                    $iconElement = iconUtils.getImageContainer(icon || iconSrc);
                if (itemData.html) {
                    $itemContent.html(itemData.html)
                } else {
                    $iconElement && $iconElement.appendTo($itemContent);
                    $("<span>").text(itemData.text).appendTo($itemContent)
                }
                return $itemContent
            }
        };
        var popupTitleAndBottom = function(itemData) {
            return $("<div>").append($("<div>").dxToolbarBase({
                items: itemData
            }))
        };
        TEMPLATE_GENERATORS.dxPopup = {
            title: popupTitleAndBottom,
            bottom: popupTitleAndBottom
        };
        TEMPLATE_GENERATORS.dxLookup = {
            title: TEMPLATE_GENERATORS.dxPopup.title,
            group: TEMPLATE_GENERATORS.dxList.group
        };
        var TAGBOX_TAG_CONTENT_CLASS = "dx-tag-content",
            TAGBOX_TAG_REMOVE_BUTTON_CLASS = "dx-tag-remove-button";
        TEMPLATE_GENERATORS.dxTagBox = {
            tag: function(itemData, index, $tag) {
                var $tagContent = $("<div>").addClass(TAGBOX_TAG_CONTENT_CLASS);
                $("<span>").text(itemData).appendTo($tagContent);
                $("<div>").addClass(TAGBOX_TAG_REMOVE_BUTTON_CLASS).appendTo($tagContent);
                return $("<div>").append($tagContent)
            }
        };
        TEMPLATE_GENERATORS.dxCalendar = {
            cell: function(itemData) {
                return $("<div>").append($("<span>").text(itemData.text || String(itemData)))
            }
        };
        module.exports = TEMPLATE_GENERATORS
    },
    /*!************************************!*\
      !*** ./Scripts/core/utils/icon.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var getImageSourceType = function(source) {
            if (!source || "string" !== typeof source) {
                return false
            }
            if (/data:.*base64|\.|\//.test(source)) {
                return "image"
            }
            if (/^[\w-_]+$/.test(source)) {
                return "dxIcon"
            }
            return "fontIcon"
        };
        var getImageContainer = function(source) {
            var imageType = getImageSourceType(source),
                ICON_CLASS = "dx-icon";
            switch (imageType) {
                case "image":
                    return $("<img>", {
                        src: source
                    }).addClass(ICON_CLASS);
                case "fontIcon":
                    return $("<i>", {
                        "class": ICON_CLASS + " " + source
                    });
                case "dxIcon":
                    return $("<i>", {
                        "class": ICON_CLASS + " " + ICON_CLASS + "-" + source
                    });
                default:
                    return null
            }
        };
        exports.getImageSourceType = getImageSourceType;
        exports.getImageContainer = getImageContainer
    },
    /*!****************************************************!*\
      !*** ./Scripts/ui/widget/ui.keyboard_processor.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        var KeyboardProcessor = Class.inherit({
            _keydown: eventUtils.addNamespace("keydown", "KeyboardProcessor"),
            codes: {
                8: "backspace",
                9: "tab",
                13: "enter",
                27: "escape",
                33: "pageUp",
                34: "pageDown",
                35: "end",
                36: "home",
                37: "leftArrow",
                38: "upArrow",
                39: "rightArrow",
                40: "downArrow",
                46: "del",
                32: "space",
                70: "F",
                65: "A",
                106: "asterisk",
                109: "minus"
            },
            ctor: function(options) {
                var _this = this;
                options = options || {};
                if (options.element) {
                    this._element = $(options.element)
                }
                if (options.focusTarget) {
                    this._focusTarget = options.focusTarget
                }
                this._handler = options.handler;
                this._context = options.context;
                this._childProcessors = [];
                if (this._element) {
                    this._processFunction = function(e) {
                        _this.process(e)
                    };
                    this._element.on(this._keydown, this._processFunction)
                }
            },
            dispose: function() {
                if (this._element) {
                    this._element.off(this._keydown, this._processFunction)
                }
                this._element = void 0;
                this._handler = void 0;
                this._context = void 0;
                this._childProcessors = void 0
            },
            clearChildren: function() {
                this._childProcessors = []
            },
            push: function(child) {
                if (!this._childProcessors) {
                    this.clearChildren()
                }
                this._childProcessors.push(child);
                return child
            },
            attachChildProcessor: function() {
                var childProcessor = new KeyboardProcessor;
                this._childProcessors.push(childProcessor);
                return childProcessor
            },
            reinitialize: function(childHandler, childContext) {
                this._context = childContext;
                this._handler = childHandler;
                return this
            },
            process: function(e) {
                if (this._focusTarget && this._focusTarget !== e.target && $.inArray(e.target, this._focusTarget) < 0) {
                    return false
                }
                var args = {
                    key: this.codes[e.which] || e.which,
                    ctrl: e.ctrlKey,
                    shift: e.shiftKey,
                    alt: e.altKey,
                    originalEvent: e
                };
                var handlerResult = this._handler && this._handler.call(this._context, args);
                if (handlerResult && this._childProcessors) {
                    $.each(this._childProcessors, function(index, childProcessor) {
                        childProcessor.process(e)
                    })
                }
            }
        });
        module.exports = KeyboardProcessor
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/widget/jquery.selectors.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var focusable = function(element, tabIndex) {
            var nodeName = element.nodeName.toLowerCase(),
                isTabIndexNotNaN = !isNaN(tabIndex),
                isVisible = visible(element),
                isDisabled = element.disabled,
                isDefaultFocus = /^(input|select|textarea|button|object|iframe)$/.test(nodeName),
                isHyperlink = "a" === nodeName,
                isFocusable = true;
            if (isDefaultFocus) {
                isFocusable = !isDisabled
            } else {
                if (isHyperlink) {
                    isFocusable = element.href || isTabIndexNotNaN
                } else {
                    isFocusable = isTabIndexNotNaN
                }
            }
            return isVisible ? isFocusable : false
        };
        var visible = function(element) {
            var $element = $(element);
            return $element.is(":visible") && "hidden" !== $element.css("visibility") && "hidden" !== $element.parents().css("visibility")
        };
        var icontains = function(elem, text) {
            var result = false;
            $.each($(elem).contents(), function(index, content) {
                if (3 === content.nodeType && (content.textContent || content.nodeValue || "").toLowerCase().indexOf((text || "").toLowerCase()) > -1) {
                    result = true;
                    return false
                }
            });
            return result
        };
        $.extend($.expr[":"], {
            "dx-focusable": function(element) {
                return focusable(element, $.attr(element, "tabindex"))
            },
            "dx-tabbable": function(element) {
                var tabIndex = $.attr(element, "tabindex");
                return (isNaN(tabIndex) || tabIndex >= 0) && focusable(element, tabIndex)
            },
            "dx-icontains": $.expr.createPseudo(function(text) {
                return function(elem) {
                    return icontains(elem, text)
                }
            })
        });
        module.exports = {
            focusable: ":dx-focusable",
            tabbable: ":dx-tabbable",
            icontains: ":dx-icontains"
        }
    },
    /*!*********************************!*\
      !*** ./Scripts/events/hover.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerEvent = __webpack_require__( /*! ./core/event_registrator */ 66),
            eventUtils = __webpack_require__( /*! ./utils */ 62),
            pointerEvents = __webpack_require__( /*! ./pointer */ 65);
        var HOVERSTART_NAMESPACE = "dxHoverStart",
            HOVERSTART = "dxhoverstart",
            POINTERENTER_NAMESPACED_EVENT_NAME = eventUtils.addNamespace(pointerEvents.enter, HOVERSTART_NAMESPACE),
            HOVEREND_NAMESPACE = "dxHoverEnd",
            HOVEREND = "dxhoverend",
            POINTERLEAVE_NAMESPACED_EVENT_NAME = eventUtils.addNamespace(pointerEvents.leave, HOVEREND_NAMESPACE);
        var Hover = Class.inherit({
            noBubble: true,
            add: function(element, handleObj) {
                var that = this,
                    $element = $(element);
                $element.off(this._originalEventName).on(this._originalEventName, handleObj.selector, function(e) {
                    that._handler(e)
                })
            },
            _handler: function(e) {
                if (eventUtils.isTouchEvent(e) || devices.isSimulator()) {
                    return
                }
                eventUtils.fireEvent({
                    type: this._eventName,
                    originalEvent: e,
                    delegateTarget: e.delegateTarget
                })
            },
            teardown: function(element) {
                $(element).off(this._originalEventName)
            }
        });
        var HoverStart = Hover.inherit({
            ctor: function() {
                this._eventName = HOVERSTART;
                this._originalEventName = POINTERENTER_NAMESPACED_EVENT_NAME;
                this._isMouseDown = false
            },
            _handler: function(e) {
                var pointers = e.pointers || [];
                if (!pointers.length) {
                    this.callBase(e)
                }
            }
        });
        var HoverEnd = Hover.inherit({
            ctor: function() {
                this._eventName = HOVEREND;
                this._originalEventName = POINTERLEAVE_NAMESPACED_EVENT_NAME
            }
        });
        registerEvent(HOVERSTART, new HoverStart);
        registerEvent(HOVEREND, new HoverEnd);
        exports.start = HOVERSTART;
        exports.end = HOVEREND
    },
    /*!*************************************************!*\
      !*** ./Scripts/events/core/emitter.feedback.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            eventUtils = __webpack_require__( /*! ../utils */ 62),
            pointerEvents = __webpack_require__( /*! ../pointer */ 65),
            Emitter = __webpack_require__( /*! ./emitter */ 75),
            registerEmitter = __webpack_require__( /*! ./emitter_registrator */ 76);
        var ACTIVE_EVENT_NAME = "dxactive",
            INACTIVE_EVENT_NAME = "dxinactive",
            ACTIVE_TIMEOUT = 30,
            INACTIVE_TIMEOUT = 400;
        var FeedbackEvent = Class.inherit({
            ctor: function(timeout, fire) {
                this._timeout = timeout;
                this._fire = fire
            },
            start: function() {
                var that = this;
                this._schedule(function() {
                    that.force()
                })
            },
            _schedule: function(fn) {
                this._timer = window.setTimeout(fn, this._timeout)
            },
            stop: function() {
                clearTimeout(this._timer)
            },
            force: function() {
                if (this._fired) {
                    return
                }
                this.stop();
                this._fire();
                this._fired = true
            },
            fired: function() {
                return this._fired
            }
        });
        var activeFeedback;
        var FeedbackEmitter = Emitter.inherit({
            ctor: function() {
                this.callBase.apply(this, arguments);
                this._active = new FeedbackEvent(0, $.noop);
                this._inactive = new FeedbackEvent(0, $.noop)
            },
            configurate: function(data, eventName) {
                switch (eventName) {
                    case ACTIVE_EVENT_NAME:
                        data.activeTimeout = data.timeout;
                        break;
                    case INACTIVE_EVENT_NAME:
                        data.inactiveTimeout = data.timeout
                }
                this.callBase(data)
            },
            start: function(e) {
                if (activeFeedback) {
                    var activeChildExists = $.contains(this.getElement().get(0), activeFeedback.getElement().get(0));
                    var childJustActivated = !activeFeedback._active.fired();
                    if (activeChildExists && childJustActivated) {
                        this._cancel();
                        return
                    }
                    activeFeedback._inactive.force()
                }
                activeFeedback = this;
                this._initEvents(e);
                this._active.start()
            },
            _initEvents: function(e) {
                var that = this,
                    eventTarget = this._getEmitterTarget(e),
                    mouseEvent = eventUtils.isMouseEvent(e),
                    isSimulator = devices.isSimulator(),
                    deferFeedback = isSimulator || !mouseEvent,
                    activeTimeout = commonUtils.ensureDefined(this.activeTimeout, ACTIVE_TIMEOUT),
                    inactiveTimeout = commonUtils.ensureDefined(this.inactiveTimeout, INACTIVE_TIMEOUT);
                this._active = new FeedbackEvent(deferFeedback ? activeTimeout : 0, function() {
                    that._fireEvent(ACTIVE_EVENT_NAME, e, {
                        target: eventTarget
                    })
                });
                this._inactive = new FeedbackEvent(deferFeedback ? inactiveTimeout : 0, function() {
                    that._fireEvent(INACTIVE_EVENT_NAME, e, {
                        target: eventTarget
                    });
                    activeFeedback = null
                })
            },
            cancel: function(e) {
                this.end(e)
            },
            end: function(e) {
                var skipTimers = e.type !== pointerEvents.up;
                if (skipTimers) {
                    this._active.stop()
                } else {
                    this._active.force()
                }
                this._inactive.start();
                if (skipTimers) {
                    this._inactive.force()
                }
            },
            dispose: function() {
                this._active.stop();
                this._inactive.stop();
                this.callBase()
            },
            lockInactive: function() {
                this._active.force();
                this._inactive.stop();
                activeFeedback = null;
                this._cancel();
                return $.proxy(this._inactive.force, this._inactive)
            }
        });
        FeedbackEmitter.lock = function(deferred) {
            var lockInactive = activeFeedback ? activeFeedback.lockInactive() : $.noop;
            $.when(deferred).always(lockInactive)
        };
        registerEmitter({
            emitter: FeedbackEmitter,
            events: [ACTIVE_EVENT_NAME, INACTIVE_EVENT_NAME]
        });
        exports.lock = FeedbackEmitter.lock;
        exports.active = ACTIVE_EVENT_NAME;
        exports.inactive = INACTIVE_EVENT_NAME
    },
    /*!***********************************************************!*\
      !*** ./Scripts/integration/knockout/template_provider.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ko = __webpack_require__( /*! knockout */ 87),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            templateProvider = __webpack_require__( /*! ../../ui/widget/jquery.template_provider */ 94),
            KoTemplate = __webpack_require__( /*! ./template */ 105),
            defaultTemplates = __webpack_require__( /*! ./default_templates */ 106);
        var KoTemplateProvider = templateProvider.constructor.inherit({
            createTemplate: function(element, owner) {
                return new KoTemplate(element, owner)
            },
            applyTemplate: function(element, model) {
                ko.applyBindings(model, element)
            },
            _templatesForWidget: function(widgetName) {
                var templateGenerators = defaultTemplates[widgetName];
                if (!templateGenerators) {
                    return this.callBase(widgetName)
                }
                var templates = {};
                $.each(templateGenerators, function(name, generator) {
                    var $markup = domUtils.createMarkupFromString(generator());
                    if ("itemFrame" !== name) {
                        $markup = $markup.contents()
                    }
                    templates[name] = new KoTemplate($markup, koTemplateProvider)
                });
                return templates
            }
        });
        var koTemplateProvider = new KoTemplateProvider;
        module.exports = koTemplateProvider
    },
    /*!**************************************************!*\
      !*** ./Scripts/integration/knockout/template.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ko = __webpack_require__( /*! knockout */ 87),
            TemplateBase = __webpack_require__( /*! ../../ui/widget/ui.template_base */ 90),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50);
        var KoTemplate = TemplateBase.inherit({
            ctor: function(element, owner) {
                this.callBase(element, owner);
                this._template = $("<div>").append(domUtils.normalizeTemplateElement(element));
                this._registerKoTemplate()
            },
            _registerKoTemplate: function() {
                var template = this._template.get(0);
                new ko.templateSources.anonymousTemplate(template).nodes(template)
            },
            _prepareDataForContainer: function(data, container) {
                var containerElement, containerContext, result = data;
                if (container.length) {
                    containerElement = container.get(0);
                    data = void 0 !== data ? data : ko.dataFor(containerElement) || {};
                    containerContext = ko.contextFor(containerElement);
                    if (containerContext) {
                        result = data === containerContext.$data ? containerContext : containerContext.createChildContext(data)
                    } else {
                        result = data
                    }
                }
                return result
            },
            _renderCore: function(options) {
                var $placeholder = $("<div>").appendTo(options.container);
                var $result;
                ko.renderTemplate(this._template.get(0), options.model, {
                    afterRender: function(nodes) {
                        $result = $(nodes)
                    }
                }, $placeholder.get(0), "replaceNode");
                return $result
            },
            dispose: function() {
                this.callBase();
                this._template.remove()
            }
        });
        module.exports = KoTemplate
    },
    /*!***********************************************************!*\
      !*** ./Scripts/integration/knockout/default_templates.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var TEMPLATE_GENERATORS = {};
        var createElementWithBindAttr = function(tagName, bindings, closeTag, additionalProperties) {
            closeTag = void 0 === closeTag ? true : closeTag;
            var bindAttr = $.map(bindings, function(value, key) {
                return key + ":" + value
            }).join(",");
            additionalProperties = additionalProperties || "";
            return "<" + tagName + ' data-bind="' + bindAttr + '" ' + additionalProperties + ">" + (closeTag ? "</" + tagName + ">" : "")
        };
        var defaultKoTemplateBasicBindings = {
            css: "{ 'dx-state-disabled': $data.disabled, 'dx-state-invisible': !($data.visible === undefined || ko.unwrap($data.visible)) }"
        };
        var emptyTemplate = function() {
            return ""
        };
        TEMPLATE_GENERATORS.CollectionWidget = {
            itemFrame: function() {
                var markup = [createElementWithBindAttr("div", defaultKoTemplateBasicBindings, false), "<div class='dx-item-content-placeholder'></div>", "</div>"];
                return markup.join("")
            },
            item: function() {
                var htmlBinding = createElementWithBindAttr("div", {
                        html: "html"
                    }),
                    textBinding = createElementWithBindAttr("div", {
                        text: "text"
                    }),
                    primitiveBinding = createElementWithBindAttr("div", {
                        text: "String($data)"
                    });
                var markup = ["<div>", "<!-- ko if: $data.html -->", htmlBinding, "<!-- /ko -->", "<!-- ko if: !$data.html && $data.text -->", textBinding, "<!-- /ko -->", "<!-- ko ifnot: jQuery.isPlainObject($data) -->", primitiveBinding, "<!-- /ko -->", "</div>"];
                return markup.join("")
            }
        };
        var BUTTON_TEXT_CLASS = "dx-button-text";
        TEMPLATE_GENERATORS.dxButton = {
            content: function() {
                var textBinding = createElementWithBindAttr("span", {
                    text: "$data.text",
                    css: "{ '" + BUTTON_TEXT_CLASS + "' : !!$data.text }"
                });
                var markup = ["<div>", "<!-- ko dxIcon: $data.icon || $data.iconSrc --><!-- /ko -->", textBinding, "</div>"];
                return markup.join("")
            }
        };
        var LIST_ITEM_BADGE_CONTAINER_CLASS = "dx-list-item-badge-container",
            LIST_ITEM_BADGE_CLASS = "dx-list-item-badge",
            BADGE_CLASS = "dx-badge",
            LIST_ITEM_CHEVRON_CONTAINER_CLASS = "dx-list-item-chevron-container",
            LIST_ITEM_CHEVRON_CLASS = "dx-list-item-chevron";
        TEMPLATE_GENERATORS.dxList = {
            item: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.item(),
                    keyBinding = createElementWithBindAttr("div", {
                        text: "key"
                    });
                template = [template.substring(0, template.length - 6), "<!-- ko if: $data.key -->" + keyBinding + "<!-- /ko -->", "</div>"];
                return template.join("")
            },
            itemFrame: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(),
                    badgeBinding = createElementWithBindAttr("div", {
                        text: "badge"
                    }, true, 'class="' + LIST_ITEM_BADGE_CLASS + " " + BADGE_CLASS + '"');
                var markup = [template.substring(0, template.length - 6), "<!-- ko if: $data.badge -->", '<div class="' + LIST_ITEM_BADGE_CONTAINER_CLASS + '">', badgeBinding, "</div>", "<!-- /ko -->", "<!-- ko if: $data.showChevron -->", '<div class="' + LIST_ITEM_CHEVRON_CONTAINER_CLASS + '">', '<div class="' + LIST_ITEM_CHEVRON_CLASS + '"></div>', "</div>", "<!-- /ko -->", "</div>"];
                return markup.join("")
            },
            group: function() {
                var keyBinding = createElementWithBindAttr("div", {
                        text: "key"
                    }),
                    primitiveBinding = createElementWithBindAttr("div", {
                        text: "String($data)"
                    });
                var markup = ["<div>", "<!-- ko if: $data.key -->", keyBinding, "<!-- /ko -->", "<!-- ko ifnot: jQuery.isPlainObject($data) -->", primitiveBinding, "<!-- /ko -->", "</div>"];
                return markup.join("")
            }
        };
        TEMPLATE_GENERATORS.dxDropDownMenu = {
            item: TEMPLATE_GENERATORS.dxList.item,
            content: TEMPLATE_GENERATORS.dxButton.content
        };
        TEMPLATE_GENERATORS.dxDropDownList = {
            item: TEMPLATE_GENERATORS.dxList.item
        };
        TEMPLATE_GENERATORS.dxRadioGroup = {
            item: TEMPLATE_GENERATORS.CollectionWidget.item
        };
        TEMPLATE_GENERATORS.dxScheduler = {
            item: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.item(),
                    startDateBinding = createElementWithBindAttr("div class='dx-scheduler-appointment-content-date'", {
                        dxShorttimeDate: "$data.startDate"
                    }),
                    endDateBinding = createElementWithBindAttr("div class='dx-scheduler-appointment-content-date'", {
                        dxShorttimeDate: "$data.endDate"
                    }),
                    allDayBinding = createElementWithBindAttr("div class='dx-scheduler-appointment-content-allday'", {
                        text: "' All day: '"
                    }),
                    dash = createElementWithBindAttr("div class='dx-scheduler-appointment-content-date'", {
                        text: "' - '"
                    });
                template = [template.substring(0, template.length - 6), "<div class='dx-scheduler-appointment-content-details'>", "<!-- ko if: $data.allDay -->" + allDayBinding + "<!-- /ko -->", "<!-- ko if: $data.startDate -->" + startDateBinding + "<!-- /ko -->", "<!-- ko if: $data.endDate -->" + dash + "<!-- /ko -->", "<!-- ko if: $data.endDate -->" + endDateBinding + "<!-- /ko -->", "</div>", "<!-- ko if: $data.recurrenceRule --><span class='dx-scheduler-appointment-recurrence-icon dx-icon-repeat'></span><!-- /ko -->", "</div>"];
                return template.join("")
            },
            appointmentTooltip: emptyTemplate,
            appointmentPopup: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxOverlay = {
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxSlideOutView = {
            menu: emptyTemplate,
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxSlideOut = {
            menuItem: TEMPLATE_GENERATORS.dxList.item,
            menuGroup: TEMPLATE_GENERATORS.dxList.group,
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxAccordion = {
            title: function() {
                var titleBinding = createElementWithBindAttr("span", {
                    text: "jQuery.isPlainObject($data) ? $data.title : String($data)"
                });
                var markup = ["<div>", "<!-- ko dxIcon: $data.icon || $data.iconSrc --><!-- /ko -->", titleBinding, "</div>"];
                return markup.join("")
            },
            item: TEMPLATE_GENERATORS.CollectionWidget.item
        };
        TEMPLATE_GENERATORS.dxResponsiveBox = {
            item: TEMPLATE_GENERATORS.CollectionWidget.item
        }, TEMPLATE_GENERATORS.dxPivotTabs = {
            item: function() {
                var titleBinding = createElementWithBindAttr("span", {
                        text: "title"
                    }),
                    primitiveBinding = createElementWithBindAttr("div", {
                        text: "String($data)"
                    });
                var markup = ["<div>", "<!-- ko if: $data.title -->", titleBinding, "<!-- /ko -->", "<!-- ko ifnot: $data.title || jQuery.isPlainObject($data) -->", primitiveBinding, "<!-- /ko -->", "</div>"];
                return markup.join("")
            }
        };
        TEMPLATE_GENERATORS.dxPivot = {
            title: TEMPLATE_GENERATORS.dxPivotTabs.item,
            content: emptyTemplate
        };
        var PANORAMA_ITEM_TITLE_CLASS = "dx-panorama-item-title";
        TEMPLATE_GENERATORS.dxPanorama = {
            itemFrame: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(),
                    headerBinding = createElementWithBindAttr("div", {
                        text: "title"
                    }, true, 'class="' + PANORAMA_ITEM_TITLE_CLASS + '"');
                var divInnerStart = template.indexOf(">") + 1;
                template = [template.substring(0, divInnerStart), "<!-- ko if: $data.title -->", headerBinding, "<!-- /ko -->", template.substring(divInnerStart, template.length)];
                return template.join("")
            }
        };
        TEMPLATE_GENERATORS.dxActionSheet = {
            item: function() {
                return ["<div>", createElementWithBindAttr("div", {
                    dxButton: "{ text: $data.text, onClick: $data.clickAction || $data.onClick, type: $data.type, disabled: !!ko.unwrap($data.disabled) }"
                }), "</div>"].join("")
            }
        };
        TEMPLATE_GENERATORS.dxToolbarBase = {
            item: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.item();
                template = [template.substring(0, template.length - 6), "<!-- ko if: $data.widget -->"];
                template.push("<!-- ko dxPolymorphWidget: { name: $data.widget, options: $data.options } --><!-- /ko -->");
                template.push("<!-- /ko -->");
                return template.join("")
            },
            actionSheetItem: TEMPLATE_GENERATORS.dxActionSheet.item
        };
        TEMPLATE_GENERATORS.dxToolbarBase.menuItem = TEMPLATE_GENERATORS.dxToolbarBase.item;
        var GALLERY_IMAGE_CLASS = "dx-gallery-item-image";
        TEMPLATE_GENERATORS.dxGallery = {
            item: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.item(),
                    primitiveBinding = createElementWithBindAttr("div", {
                        text: "String($data)"
                    }),
                    imgBinding = createElementWithBindAttr("img", {
                        attr: "{ src: String($data) }"
                    }, false, 'class="' + GALLERY_IMAGE_CLASS + '"');
                template = [template.substring(0, template.length - 6).replace(primitiveBinding, imgBinding), "<!-- ko if: $data.imageSrc -->", createElementWithBindAttr("img", {
                    attr: "{ src: $data.imageSrc, alt: $data.imageAlt }"
                }, false, 'class="' + GALLERY_IMAGE_CLASS + '"'), "<!-- /ko -->"].join("");
                return template
            }
        };
        TEMPLATE_GENERATORS.dxTabs = {
            item: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.item(),
                    basePrimitiveBinding = createElementWithBindAttr("div", {
                        text: "String($data)"
                    }),
                    primitiveBinding = '<span class="dx-tab-text" data-bind="text: String($data)"></span>',
                    baseTextBinding = createElementWithBindAttr("div", {
                        text: "text"
                    }),
                    textBinding = '<!-- ko dxIcon: $data.icon || $data.iconSrc --><!-- /ko --><span class="dx-tab-text" data-bind="text: $data.text"></span>';
                template = template.replace("<!-- ko if: !$data.html && $data.text -->", "<!-- ko if: !$data.html && ($data.text || $data.icon || $data.iconSrc) -->").replace(basePrimitiveBinding, primitiveBinding).replace(baseTextBinding, textBinding);
                return template
            },
            itemFrame: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(),
                    badgeBinding = createElementWithBindAttr("div", {
                        attr: "{ 'class': 'dx-tabs-item-badge dx-badge' }",
                        text: "badge"
                    });
                var markup = [template.substring(0, template.length - 6), "<!-- ko if: $data.badge -->", badgeBinding, "<!-- /ko -->", "</div>"];
                return markup.join("")
            }
        };
        TEMPLATE_GENERATORS.dxTabPanel = {
            item: TEMPLATE_GENERATORS.CollectionWidget.item,
            title: function() {
                var template = TEMPLATE_GENERATORS.dxTabs.item(),
                    htmlBinding = "<!-- ko if: $data.html -->" + createElementWithBindAttr("div", {
                        html: "html"
                    }) + "<!-- /ko -->";
                return template.replace(/\$data\.text/g, "$data.title").replace(/\!\$data\.html\ \&\&\ /, "").replace(htmlBinding, "")
            }
        };
        var NAVBAR_ITEM_BADGE_CLASS = "dx-navbar-item-badge";
        TEMPLATE_GENERATORS.dxNavBar = {
            itemFrame: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.itemFrame(),
                    badgeBinding = createElementWithBindAttr("div", {
                        text: "badge"
                    }, true, 'class="' + NAVBAR_ITEM_BADGE_CLASS + " " + BADGE_CLASS + '"');
                var markup = [template.substring(0, template.length - 6), "<!-- ko if: $data.badge -->", badgeBinding, "<!-- /ko -->", "</div>"];
                return markup.join("")
            }
        };
        TEMPLATE_GENERATORS.dxMenuBase = {
            item: function() {
                var template = [createElementWithBindAttr("div", defaultKoTemplateBasicBindings, false)],
                    textBinding = createElementWithBindAttr("span", {
                        text: "text",
                        css: "{ 'dx-menu-item-text': true }"
                    }),
                    primitiveBinding = createElementWithBindAttr("span", {
                        text: "String($data)",
                        css: "{ 'dx-menu-item-text': true }"
                    }),
                    popout = "<span class='dx-menu-item-popout-container'><div class='dx-menu-item-popout'></div></span>";
                template.push("<!-- ko dxIcon: $data.icon || $data.iconSrc --><!-- /ko -->", "<!-- ko if: $data.text -->", textBinding, "<!-- /ko -->", "<!-- ko ifnot: jQuery.isPlainObject($data) || $data.text -->", primitiveBinding, "<!-- /ko -->", "<!-- ko if: $data.items -->", popout, "<!-- /ko -->", "</div>");
                return template.join("")
            }
        };
        TEMPLATE_GENERATORS.dxTreeView = {
            item: function() {
                var node = [],
                    link = createElementWithBindAttr("span", {
                        text: "text"
                    }, true),
                    htmlBinding = createElementWithBindAttr("div", {
                        html: "html"
                    });
                node.push("<div>", "<!-- ko if: $data.html && !$data.text -->", htmlBinding, "<!-- /ko -->", "<!-- ko dxIcon: $data.icon || $data.iconSrc --><!-- /ko -->", "<!-- ko if: !$data.html && $data.text -->" + link + "<!-- /ko -->", "</div>");
                return node.join("")
            }
        };
        var popupTitleAndBottom = function() {
            return ["<div>", createElementWithBindAttr("div", {
                dxToolbarBase: "{ items: $data }"
            }), "</div>"].join("")
        };
        TEMPLATE_GENERATORS.dxPopup = {
            title: popupTitleAndBottom,
            bottom: popupTitleAndBottom
        };
        TEMPLATE_GENERATORS.dxLookup = {
            title: TEMPLATE_GENERATORS.dxPopup.title,
            group: TEMPLATE_GENERATORS.dxList.group
        };
        var TAGBOX_TAG_CONTENT_CLASS = "dx-tag-content",
            TAGBOX_TAG_REMOVE_BUTTON_CLASS = "dx-tag-remove-button";
        TEMPLATE_GENERATORS.dxTagBox = {
            tag: function() {
                return ["<div>", "<div class=" + TAGBOX_TAG_CONTENT_CLASS + ">", createElementWithBindAttr("span", {
                    text: "$data"
                }), "<div class=" + TAGBOX_TAG_REMOVE_BUTTON_CLASS + "></div>", "</div>", "</div>"].join("")
            }
        };
        module.exports = TEMPLATE_GENERATORS
    },
    /*!*************************************!*\
      !*** ./Scripts/ui/editor/editor.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            ValidationMixin = __webpack_require__( /*! ../validation/validation_mixin */ 108),
            Overlay = __webpack_require__( /*! ../overlay */ 109);
        var READONLY_STATE_CLASS = "dx-state-readonly",
            INVALID_CLASS = "dx-invalid",
            INVALID_MESSAGE = "dx-invalid-message",
            INVALID_MESSAGE_AUTO = "dx-invalid-message-auto",
            INVALID_MESSAGE_ALWAYS = "dx-invalid-message-always",
            VALIDATION_TARGET = "dx-validation-target",
            VALIDATION_MESSAGE_MIN_WIDTH = 100;
        var Editor = Widget.inherit({
            _init: function() {
                this.callBase();
                this.validationRequest = $.Callbacks();
                var $element = this.element();
                if ($element) {
                    $.data($element[0], VALIDATION_TARGET, this)
                }
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: null,
                    onValueChanged: null,
                    readOnly: false,
                    isValid: true,
                    validationError: null,
                    validationMessageMode: "auto",
                    validationBoundary: void 0,
                    validationMessageOffset: {
                        h: 0,
                        v: 0
                    }
                })
            },
            _attachKeyboardEvents: function() {
                if (this.option("readOnly")) {
                    return
                }
                this.callBase();
                this._attachChildKeyboardEvents()
            },
            _attachChildKeyboardEvents: $.noop,
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    validationError: true
                })
            },
            _createValueChangeAction: function() {
                this._valueChangeAction = this._createActionByOption("onValueChanged", {
                    excludeValidators: ["disabled", "readOnly"]
                })
            },
            _suppressValueChangeAction: function() {
                this._valueChangeActionSuppressed = true
            },
            _resumeValueChangeAction: function() {
                this._valueChangeActionSuppressed = false
            },
            _render: function() {
                this.callBase();
                this._renderValidationState();
                this._toggleReadOnlyState()
            },
            _raiseValueChangeAction: function(value, previousValue, extraArguments) {
                if (!this._valueChangeAction) {
                    this._createValueChangeAction()
                }
                this._valueChangeAction(this._valueChangeArgs(value, previousValue))
            },
            _valueChangeArgs: function(value, previousValue) {
                return {
                    value: value,
                    previousValue: previousValue,
                    jQueryEvent: this._valueChangeEventInstance
                }
            },
            _saveValueChangeEvent: function(e) {
                this._valueChangeEventInstance = e
            },
            _renderValidationState: function() {
                var isValid = this.option("isValid"),
                    validationError = this.option("validationError"),
                    validationMessageMode = this.option("validationMessageMode"),
                    $element = this.element();
                $element.toggleClass(INVALID_CLASS, !isValid);
                this.setAria("invalid", !isValid || void 0);
                if (this._$validationMessage) {
                    this._$validationMessage.remove();
                    this._$validationMessage = null
                }
                if (!isValid && validationError && validationError.message) {
                    this._$validationMessage = $("<div/>", {
                        "class": INVALID_MESSAGE
                    }).html(validationError.message).appendTo($element);
                    this._validationMessage = this._createComponent(this._$validationMessage, Overlay, {
                        target: this._getValidationMessageTarget(),
                        shading: false,
                        width: "auto",
                        height: "auto",
                        container: $element,
                        position: this._getValidationMessagePosition("below"),
                        closeOnOutsideClick: false,
                        closeOnTargetScroll: false,
                        animation: null,
                        visible: true,
                        propagateOutsideClick: true
                    });
                    this._$validationMessage.toggleClass(INVALID_MESSAGE_AUTO, "auto" === validationMessageMode).toggleClass(INVALID_MESSAGE_ALWAYS, "always" === validationMessageMode);
                    this._setValidationMessageMaxWidth()
                }
            },
            _setValidationMessageMaxWidth: function() {
                if (!this._validationMessage) {
                    return
                }
                var validationMessageMaxWidth = Math.max(VALIDATION_MESSAGE_MIN_WIDTH, this._getValidationMessageTarget().outerWidth());
                this._validationMessage.option("maxWidth", validationMessageMaxWidth)
            },
            _getValidationMessageTarget: function() {
                return this.element()
            },
            _getValidationMessagePosition: function(positionRequest) {
                var rtlEnabled = this.option("rtlEnabled"),
                    messagePositionSide = commonUtils.getDefaultAlignment(rtlEnabled),
                    messageOriginalOffset = this.option("validationMessageOffset"),
                    messageOffset = {
                        h: messageOriginalOffset.h,
                        v: messageOriginalOffset.v
                    },
                    verticalPositions = "below" === positionRequest ? [" top", " bottom"] : [" bottom", " top"];
                if (rtlEnabled) {
                    messageOffset.h = -messageOffset.h
                }
                if ("below" !== positionRequest) {
                    messageOffset.v = -messageOffset.v
                }
                return {
                    offset: messageOffset,
                    boundary: this.option("validationBoundary"),
                    my: messagePositionSide + verticalPositions[0],
                    at: messagePositionSide + verticalPositions[1],
                    collision: "none flip"
                }
            },
            _toggleReadOnlyState: function() {
                this.element().toggleClass(READONLY_STATE_CLASS, !!this.option("readOnly"));
                this.setAria("readonly", this.option("readOnly") || void 0)
            },
            _dispose: function() {
                var element = this.element()[0];
                $.data(element, VALIDATION_TARGET, null);
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onValueChanged":
                        this._createValueChangeAction();
                        break;
                    case "isValid":
                    case "validationError":
                    case "validationBoundary":
                    case "validationMessageMode":
                        this._renderValidationState();
                        break;
                    case "readOnly":
                        this._toggleReadOnlyState();
                        this._refreshFocusState();
                        break;
                    case "value":
                        if (!this._valueChangeActionSuppressed) {
                            this._raiseValueChangeAction(args.value, args.previousValue);
                            this._saveValueChangeEvent(void 0)
                        }
                        if (args.value != args.previousValue) {
                            this.validationRequest.fire({
                                value: args.value,
                                editor: this
                            })
                        }
                        break;
                    case "width":
                        this.callBase(args);
                        this._setValidationMessageMaxWidth();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            reset: function() {
                this.option("value", null)
            }
        }).include(ValidationMixin);
        module.exports = Editor
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/validation/validation_mixin.js ***!
      \***************************************************/
    function(module, exports) {
        var ValidationMixin = {
            _findGroup: function() {
                var $dxGroup, group = this.option("validationGroup");
                if (!group) {
                    $dxGroup = this.element().parents(".dx-validationgroup:first");
                    if ($dxGroup.length) {
                        group = $dxGroup.dxValidationGroup("instance")
                    } else {
                        group = this._modelByElement(this.element())
                    }
                }
                return group
            }
        };
        module.exports = ValidationMixin
    },
    /*!*******************************!*\
      !*** ./Scripts/ui/overlay.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            compareVersions = __webpack_require__( /*! ../core/utils/version */ 45).compare,
            viewPortUtils = __webpack_require__( /*! ../core/utils/view_port */ 42),
            viewPort = viewPortUtils.value,
            viewPortChanged = viewPortUtils.changeCallback,
            hideTopOverlayCallback = __webpack_require__( /*! ../mobile/hide_top_overlay */ 54).hideCallback,
            positionUtils = __webpack_require__( /*! ../animation/position */ 61),
            fitIntoRange = __webpack_require__( /*! ../core/utils/math */ 79).fitIntoRange,
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Widget = __webpack_require__( /*! ./widget/ui.widget */ 89),
            KeyboardProcessor = __webpack_require__( /*! ./widget/ui.keyboard_processor */ 100),
            selectors = __webpack_require__( /*! ./widget/jquery.selectors */ 101),
            dragEvents = __webpack_require__( /*! ../events/drag */ 110),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../events/pointer */ 65),
            Resizable = __webpack_require__( /*! ./resizable */ 112);
        var OVERLAY_CLASS = "dx-overlay",
            OVERLAY_WRAPPER_CLASS = "dx-overlay-wrapper",
            OVERLAY_CONTENT_CLASS = "dx-overlay-content",
            OVERLAY_SHADER_CLASS = "dx-overlay-shader",
            OVERLAY_MODAL_CLASS = "dx-overlay-modal",
            INVISIBLE_STATE_CLASS = "dx-state-invisible",
            ANONYMOUS_TEMPLATE_NAME = "content",
            RTL_DIRECTION_CLASS = "dx-rtl",
            ACTIONS = ["onShowing", "onShown", "onHiding", "onHidden", "onPositioning", "onPositioned", "onResizeStart", "onResize", "onResizeEnd"],
            FIRST_Z_INDEX = 1500,
            OVERLAY_STACK = [],
            DISABLED_STATE_CLASS = "dx-state-disabled",
            TAB_KEY = 9;
        var realDevice = devices.real(),
            realVersion = realDevice.version,
            iOS = "ios" === realDevice.platform,
            iOS7_0andBelow = iOS && compareVersions(realVersion, [7, 1]) < 0,
            android4_0nativeBrowser = "android" === realDevice.platform && 0 === compareVersions(realVersion, [4, 0], 2) && navigator.userAgent.indexOf("Chrome") === -1;
        var forceRepaint = function($element) {
            if (iOS7_0andBelow) {
                $element.width()
            }
            if (android4_0nativeBrowser) {
                var $parents = $element.parents(),
                    inScrollView = $parents.is(".dx-scrollable-native");
                if (!inScrollView) {
                    $parents.css("backface-visibility", "hidden");
                    $parents.css("backface-visibility");
                    $parents.css("backface-visibility", "visible")
                }
            }
        };
        var getElement = function(value) {
            return value && $(value instanceof $.Event ? value.target : value)
        };
        $(document).on(pointerEvents.down, function(e) {
            for (var i = OVERLAY_STACK.length - 1; i >= 0; i--) {
                if (!OVERLAY_STACK[i]._proxiedDocumentDownHandler(e)) {
                    return
                }
            }
        });
        var Overlay = Widget.inherit({
            _supportedKeys: function() {
                var offsetSize = 5,
                    move = function(top, left, e) {
                        if (!this.option("dragEnabled")) {
                            return
                        }
                        e.preventDefault();
                        e.stopPropagation();
                        var allowedOffsets = this._allowedOffsets();
                        var offset = {
                            top: fitIntoRange(top, -allowedOffsets.top, allowedOffsets.bottom),
                            left: fitIntoRange(left, -allowedOffsets.left, allowedOffsets.right)
                        };
                        this._changePosition(offset)
                    };
                return $.extend(this.callBase(), {
                    escape: function(e) {
                        this.hide()
                    },
                    upArrow: $.proxy(move, this, -offsetSize, 0),
                    downArrow: $.proxy(move, this, offsetSize, 0),
                    leftArrow: $.proxy(move, this, 0, -offsetSize),
                    rightArrow: $.proxy(move, this, 0, offsetSize)
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    activeStateEnabled: false,
                    visible: false,
                    deferRendering: true,
                    shading: true,
                    shadingColor: "",
                    position: {
                        my: "center",
                        at: "center"
                    },
                    width: function() {
                        return .8 * $(window).width()
                    },
                    minWidth: null,
                    maxWidth: null,
                    height: function() {
                        return .8 * $(window).height()
                    },
                    minHeight: null,
                    maxHeight: null,
                    animation: {
                        show: {
                            type: "pop",
                            duration: 300,
                            from: {
                                scale: .55
                            }
                        },
                        hide: {
                            type: "pop",
                            duration: 300,
                            to: {
                                opacity: 0,
                                scale: .55
                            },
                            from: {
                                opacity: 1,
                                scale: 1
                            }
                        }
                    },
                    closeOnOutsideClick: false,
                    closeOnBackButton: true,
                    onShowing: null,
                    onShown: null,
                    onHiding: null,
                    onHidden: null,
                    contentTemplate: "content",
                    dragEnabled: false,
                    resizeEnabled: false,
                    onResizeStart: null,
                    onResize: null,
                    onResizeEnd: null,
                    onContentReady: null,
                    target: void 0,
                    container: void 0,
                    hideTopOverlayHandler: void 0,
                    closeOnTargetScroll: false,
                    onPositioned: null,
                    boundaryOffset: {
                        h: 0,
                        v: 0
                    },
                    propagateOutsideClick: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        var realDevice = devices.real(),
                            realPlatform = realDevice.platform,
                            realVersion = realDevice.version;
                        return "android" === realPlatform && compareVersions(realVersion, [4, 2]) < 0
                    },
                    options: {
                        animation: {
                            show: {
                                type: "fade",
                                duration: 400
                            },
                            hide: {
                                type: "fade",
                                duration: 400,
                                to: {
                                    opacity: 0
                                },
                                from: {
                                    opacity: 1
                                }
                            }
                        }
                    }
                }])
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    animation: true
                })
            },
            _getAnonymousTemplateName: function() {
                return ANONYMOUS_TEMPLATE_NAME
            },
            _wrapper: function() {
                return this._$wrapper
            },
            _container: function() {
                return this._$content
            },
            _eventBindingTarget: function() {
                return this._$content
            },
            _init: function() {
                this.callBase();
                this._initActions();
                this._initCloseOnOutsideClickHandler();
                this._initTabTerminatorHandler();
                this._$wrapper = $("<div>").addClass(OVERLAY_WRAPPER_CLASS);
                this._$content = $("<div>").addClass(OVERLAY_CONTENT_CLASS);
                var $element = this.element();
                this._$wrapper.addClass($element.attr("class"));
                $element.addClass(OVERLAY_CLASS);
                this._$wrapper.attr("data-bind", "dxControlsDescendantBindings: true");
                this._$wrapper.on("MSPointerDown", $.noop);
                this._$wrapper.on("focusin", function(e) {
                    e.stopPropagation()
                });
                this._toggleViewPortSubscription(true)
            },
            _initOptions: function(options) {
                this._initTarget(options.target);
                this._initContainer(options.container);
                this._initHideTopOverlayHandler(options.hideTopOverlayHandler);
                this.callBase(options)
            },
            _initTarget: function(target) {
                if (!commonUtils.isDefined(target)) {
                    return
                }
                var options = this.option();
                $.each(["position.of", "animation.show.from.position.of", "animation.show.to.position.of", "animation.hide.from.position.of", "animation.hide.to.position.of"], function(_, path) {
                    var pathParts = path.split(".");
                    var option = options;
                    while (option) {
                        if (1 === pathParts.length) {
                            if ($.isPlainObject(option)) {
                                option[pathParts.shift()] = target
                            }
                            break
                        } else {
                            option = option[pathParts.shift()]
                        }
                    }
                })
            },
            _initContainer: function(container) {
                container = void 0 === container ? viewPort() : container;
                var $element = this.element(),
                    $container = $element.closest(container);
                if (!$container.length) {
                    $container = $(container).first()
                }
                this._$container = $container.length ? $container : $element.parent()
            },
            _initHideTopOverlayHandler: function(handler) {
                this._hideTopOverlayHandler = void 0 !== handler ? handler : $.proxy(this._defaultHideTopOverlayHandler, this)
            },
            _defaultHideTopOverlayHandler: function() {
                this.hide()
            },
            _initActions: function() {
                this._actions = {};
                $.each(ACTIONS, $.proxy(function(_, action) {
                    this._actions[action] = this._createActionByOption(action, {
                        excludeValidators: ["disabled", "readOnly"]
                    }) || $.noop
                }, this))
            },
            _initCloseOnOutsideClickHandler: function() {
                var that = this;
                this._proxiedDocumentDownHandler = function() {
                    return that._documentDownHandler.apply(that, arguments)
                }
            },
            _documentDownHandler: function(e) {
                if (this._showAnimationProcessing) {
                    this._stopAnimation();
                    return
                }
                var closeOnOutsideClick = this.option("closeOnOutsideClick");
                if ($.isFunction(closeOnOutsideClick)) {
                    closeOnOutsideClick = closeOnOutsideClick(e)
                }
                if (closeOnOutsideClick) {
                    var $container = this._$content,
                        outsideClick = !$container.is(e.target) && !$.contains($container.get(0), e.target);
                    if (outsideClick) {
                        if (this.option("shading")) {
                            e.preventDefault()
                        }
                        this.hide()
                    }
                }
                return this.option("propagateOutsideClick")
            },
            _isTopOverlay: function() {
                var overlayStack = this._overlayStack();
                return overlayStack[overlayStack.length - 1] === this
            },
            _overlayStack: function() {
                return OVERLAY_STACK
            },
            _zIndexInitValue: function() {
                return FIRST_Z_INDEX
            },
            _toggleViewPortSubscription: function(toggle) {
                viewPortChanged.remove(this._viewPortChangeHandle);
                if (toggle) {
                    this._viewPortChangeHandle = $.proxy(this._viewPortChangeHandler, this);
                    viewPortChanged.add(this._viewPortChangeHandle)
                }
            },
            _viewPortChangeHandler: function() {
                this._initContainer(this.option("container"));
                this._refresh()
            },
            _renderVisibilityAnimate: function(visible) {
                this._stopAnimation();
                return visible ? this._show() : this._hide()
            },
            _normalizePosition: function() {
                this._position = this.option("position")
            },
            _getAnimationConfig: function() {
                var animation = this.option("animation");
                if ($.isFunction(animation)) {
                    animation = animation.call(this)
                }
                return animation
            },
            _show: function() {
                var that = this,
                    deferred = $.Deferred();
                this._parentHidden = this._isParentHidden();
                deferred.done(function() {
                    delete that._parentHidden
                });
                if (this._parentHidden) {
                    return deferred.resolve()
                }
                if (this._currentVisible) {
                    return $.when().promise()
                }
                this._currentVisible = true;
                this._normalizePosition();
                var animation = that._getAnimationConfig() || {},
                    showAnimation = this._normalizeAnimation(animation.show, "to"),
                    startShowAnimation = showAnimation && showAnimation.start || $.noop,
                    completeShowAnimation = showAnimation && showAnimation.complete || $.noop;
                if (this._isHidingActionCanceled) {
                    delete this._isHidingActionCanceled;
                    deferred.resolve()
                } else {
                    var show = function() {
                        this._renderVisibility(true);
                        this._animate(showAnimation, function() {
                            if (that.option("focusStateEnabled")) {
                                that._focusTarget().focus()
                            }
                            completeShowAnimation.apply(this, arguments);
                            that._showAnimationProcessing = false;
                            that._actions.onShown();
                            deferred.resolve()
                        }, function() {
                            startShowAnimation.apply(this, arguments);
                            that._showAnimationProcessing = true
                        })
                    }.bind(this);
                    if (this.option("templatesRenderAsynchronously")) {
                        this._asyncShowTimeout = setTimeout(show)
                    } else {
                        show()
                    }
                }
                return deferred.promise()
            },
            _normalizeAnimation: function(animation, prop) {
                if (animation && animation[prop]) {
                    animation = $.extend({
                        type: "slide"
                    }, animation);
                    $.extend(animation[prop], {
                        position: this._position
                    })
                }
                return animation
            },
            _hide: function() {
                if (!this._currentVisible) {
                    return $.when().promise()
                }
                this._currentVisible = false;
                var that = this,
                    deferred = $.Deferred(),
                    animation = that._getAnimationConfig() || {},
                    hideAnimation = this._normalizeAnimation(animation.hide, "from"),
                    completeHideAnimation = hideAnimation && hideAnimation.complete || $.noop,
                    hidingArgs = {
                        cancel: false
                    };
                this._actions.onHiding(hidingArgs);
                if (hidingArgs.cancel) {
                    this._isHidingActionCanceled = true;
                    this.option("visible", true);
                    deferred.resolve()
                } else {
                    this._forceFocusLost();
                    this._toggleShading(false);
                    this._toggleSubscriptions(false);
                    this._animate(hideAnimation, function() {
                        that._renderVisibility(false);
                        completeHideAnimation.apply(this, arguments);
                        that._actions.onHidden();
                        deferred.resolve()
                    })
                }
                return deferred.promise()
            },
            _forceFocusLost: function() {
                document.activeElement && this._$content.find(document.activeElement).length && document.activeElement.blur()
            },
            _animate: function(animation, completeCallback, startCallback) {
                if (animation) {
                    startCallback = startCallback || animation.start || $.noop;
                    var $content = this._$content;
                    fx.animate(this._$content, $.extend({}, animation, {
                        start: function() {
                            $content.css("pointer-events", "none");
                            startCallback.apply(this, arguments)
                        },
                        complete: function() {
                            $content.css("pointer-events", "");
                            completeCallback.apply(this, arguments)
                        }
                    }))
                } else {
                    completeCallback()
                }
            },
            _stopAnimation: function() {
                fx.stop(this._$content, true)
            },
            _renderVisibility: function(visible) {
                if (visible && this._isParentHidden()) {
                    return
                }
                this._currentVisible = visible;
                this._stopAnimation();
                clearTimeout(this._asyncShowTimeout);
                if (!visible) {
                    domUtils.triggerHidingEvent(this._$content)
                }
                this._toggleVisibility(visible);
                this._$content.toggleClass(INVISIBLE_STATE_CLASS, !visible);
                this._updateZIndexStackPosition(visible);
                if (visible) {
                    this._renderContent();
                    this._actions.onShowing();
                    this._moveToContainer();
                    this._renderGeometry();
                    domUtils.triggerShownEvent(this._$content);
                    domUtils.triggerResizeEvent(this._$content)
                } else {
                    this._moveFromContainer()
                }
                this._toggleShading(visible);
                this._toggleSubscriptions(visible)
            },
            _updateZIndexStackPosition: function(pushToStack) {
                var overlayStack = this._overlayStack(),
                    index = $.inArray(this, overlayStack);
                if (pushToStack) {
                    if (index === -1) {
                        var length = overlayStack.length;
                        this._zIndex = (length ? overlayStack[length - 1]._zIndex : this._zIndexInitValue()) + 1;
                        overlayStack.push(this)
                    }
                    this._$wrapper.css("z-index", this._zIndex);
                    this._$content.css("z-index", this._zIndex)
                } else {
                    if (index !== -1) {
                        overlayStack.splice(index, 1)
                    }
                }
            },
            _toggleShading: function(visible) {
                this._$wrapper.toggleClass(OVERLAY_MODAL_CLASS, this.option("shading") && !this.option("container"));
                this._$wrapper.toggleClass(OVERLAY_SHADER_CLASS, visible && this.option("shading"));
                this._$wrapper.css("background-color", this.option("shading") ? this.option("shadingColor") : "");
                this._toggleTabTerminator(visible && this.option("shading"))
            },
            _initTabTerminatorHandler: function() {
                var that = this;
                this._proxiedTabTerminatorHandler = function() {
                    that._tabKeyHandler.apply(that, arguments)
                }
            },
            _toggleTabTerminator: function(enabled) {
                var eventName = eventUtils.addNamespace("keydown", this.NAME);
                if (enabled) {
                    $(document).on(eventName, this._proxiedTabTerminatorHandler)
                } else {
                    $(document).off(eventName, this._proxiedTabTerminatorHandler)
                }
            },
            _tabKeyHandler: function(e) {
                if (e.keyCode !== TAB_KEY || !this._isTopOverlay()) {
                    return
                }
                var tabbableElements = this._$wrapper.find(selectors.tabbable),
                    $firstTabbable = tabbableElements.first(),
                    $lastTabbable = tabbableElements.last(),
                    isTabOnLast = !e.shiftKey && e.target === $lastTabbable.get(0),
                    isShiftTabOnFirst = e.shiftKey && e.target === $firstTabbable.get(0),
                    isEmptyTabList = 0 === tabbableElements.length,
                    isOutsideTarget = $.inArray(e.target, tabbableElements) === -1;
                if (isTabOnLast || isShiftTabOnFirst || isEmptyTabList || isOutsideTarget) {
                    e.preventDefault();
                    (e.shiftKey ? $lastTabbable : $firstTabbable).focusin().focus()
                }
            },
            _toggleSubscriptions: function(enabled) {
                this._toggleHideTopOverlayCallback(enabled);
                this._toggleParentsScrollSubscription(enabled)
            },
            _toggleHideTopOverlayCallback: function(subscribe) {
                if (!this._hideTopOverlayHandler) {
                    return
                }
                if (subscribe && this.option("closeOnBackButton")) {
                    hideTopOverlayCallback.add(this._hideTopOverlayHandler)
                } else {
                    hideTopOverlayCallback.remove(this._hideTopOverlayHandler)
                }
            },
            _toggleParentsScrollSubscription: function(subscribe) {
                if (!this._position) {
                    return
                }
                var target = this._position.of || $(),
                    closeOnScroll = this.option("closeOnTargetScroll"),
                    $parents = getElement(target).parents(),
                    scrollEvent = eventUtils.addNamespace("scroll", this.NAME);
                if ("generic" === devices.real().platform) {
                    $parents = $parents.add(window)
                }
                this._proxiedTargetParentsScrollHandler = this._proxiedTargetParentsScrollHandler || $.proxy(function(e) {
                    this._targetParentsScrollHandler(e)
                }, this);
                $().add(this._$prevTargetParents).off(scrollEvent, this._proxiedTargetParentsScrollHandler);
                if (subscribe && closeOnScroll) {
                    $parents.on(scrollEvent, this._proxiedTargetParentsScrollHandler);
                    this._$prevTargetParents = $parents
                }
            },
            _targetParentsScrollHandler: function(e) {
                var closeHandled = false,
                    closeOnScroll = this.option("closeOnTargetScroll");
                if ($.isFunction(closeOnScroll)) {
                    closeHandled = closeOnScroll(e)
                }
                if (!closeHandled && !this._showAnimationProcessing) {
                    this.hide()
                }
            },
            _render: function() {
                this.callBase();
                this._$content.appendTo(this.element());
                this._renderVisibilityAnimate(this.option("visible"))
            },
            _renderContent: function() {
                var shouldDeferRendering = !this._currentVisible && this.option("deferRendering");
                var isParentHidden = this.option("visible") && this._isParentHidden();
                if (isParentHidden) {
                    this._isHidden = true;
                    return
                }
                if (this._contentAlreadyRendered || shouldDeferRendering) {
                    return
                }
                this._contentAlreadyRendered = true;
                this.callBase()
            },
            _isParentHidden: function() {
                if (void 0 !== this._parentHidden) {
                    return this._parentHidden
                }
                var $parent = this.element().parent();
                if ($parent.is(":visible")) {
                    return false
                }
                var isHidden = false;
                $parent.add($parent.parents()).each(function() {
                    var $element = $(this);
                    if ("none" === $element.css("display")) {
                        isHidden = true;
                        return false
                    }
                });
                return isHidden || !$.contains(document, $parent.get(0))
            },
            _renderContentImpl: function() {
                var $element = this.element();
                this._$content.appendTo($element);
                var contentTemplate = this._getTemplate(this.option("contentTemplate"));
                contentTemplate && contentTemplate.render({
                    container: this.content(),
                    noModel: true
                });
                this._renderDrag();
                this._renderResize();
                this._renderScrollTerminator()
            },
            _renderDrag: function() {
                var $dragTarget = this._getDragTarget();
                if (!$dragTarget) {
                    return
                }
                var startEventName = eventUtils.addNamespace(dragEvents.start, this.NAME),
                    updateEventName = eventUtils.addNamespace(dragEvents.move, this.NAME);
                $dragTarget.off(startEventName).off(updateEventName);
                if (!this.option("dragEnabled")) {
                    return
                }
                $dragTarget.on(startEventName, $.proxy(this._dragStartHandler, this)).on(updateEventName, $.proxy(this._dragUpdateHandler, this))
            },
            _renderResize: function() {
                this._createComponent(this._$content, Resizable, {
                    handles: this.option("resizeEnabled") ? "all" : "none",
                    onResizeEnd: $.proxy(this._resizeEndHandler, this),
                    onResize: $.proxy(this._actions.onResize, this),
                    onResizeStart: $.proxy(this._actions.onResizeStart, this),
                    minHeight: 100,
                    minWidth: 100,
                    area: this._$container
                })
            },
            _resizeEndHandler: function() {
                this._positionChangeHandled = true;
                this._dimensionChangeHandled = true;
                this._actions.onResizeEnd()
            },
            _renderScrollTerminator: function() {
                var $scrollTerminator = this._wrapper();
                var terminatorEventName = eventUtils.addNamespace(dragEvents.move, this.NAME);
                $scrollTerminator.off(terminatorEventName).on(terminatorEventName, {
                    validate: function() {
                        return true
                    },
                    getDirection: function() {
                        return "both"
                    },
                    _toggleGestureCover: $.noop,
                    _clearSelection: $.noop,
                    isNative: true
                }, function(e) {
                    if ("mousemove" !== e.originalEvent.originalEvent.type) {
                        e.preventDefault()
                    }
                })
            },
            _getDragTarget: function() {
                return this.content()
            },
            _dragStartHandler: function(e) {
                e.targetElements = [];
                this._prevOffset = {
                    x: 0,
                    y: 0
                };
                var allowedOffsets = this._allowedOffsets();
                e.maxTopOffset = allowedOffsets.top;
                e.maxBottomOffset = allowedOffsets.bottom;
                e.maxLeftOffset = allowedOffsets.left;
                e.maxRightOffset = allowedOffsets.right
            },
            _deltaSize: function() {
                var $content = this._$content,
                    $container = this._$container;
                var contentWidth = $content.outerWidth(),
                    contentHeight = $content.outerHeight(),
                    containerWidth = $container.width(),
                    containerHeight = $container.height();
                return {
                    width: containerWidth - contentWidth,
                    height: containerHeight - contentHeight
                }
            },
            _dragUpdateHandler: function(e) {
                var offset = e.offset,
                    prevOffset = this._prevOffset,
                    targetOffset = {
                        top: offset.y - prevOffset.y,
                        left: offset.x - prevOffset.x
                    };
                this._changePosition(targetOffset);
                this._prevOffset = offset
            },
            _changePosition: function(offset) {
                var position = translator.locate(this._$content);
                translator.move(this._$content, {
                    left: position.left + offset.left,
                    top: position.top + offset.top
                });
                this._positionChangeHandled = true
            },
            _allowedOffsets: function() {
                var position = translator.locate(this._$content),
                    deltaSize = this._deltaSize(),
                    isAllowedDrag = deltaSize.height >= 0 && deltaSize.width >= 0,
                    boundaryOffset = this.option("boundaryOffset");
                return {
                    top: isAllowedDrag ? position.top + boundaryOffset.v : 0,
                    bottom: isAllowedDrag ? -position.top + deltaSize.height - boundaryOffset.v : 0,
                    left: isAllowedDrag ? position.left + boundaryOffset.h : 0,
                    right: isAllowedDrag ? -position.left + deltaSize.width - boundaryOffset.h : 0
                }
            },
            _fireContentReadyAction: function() {
                if (this.option("visible")) {
                    this._moveToContainer()
                }
                this.callBase.apply(this, arguments)
            },
            _moveFromContainer: function() {
                this._$content.appendTo(this.element());
                this._detachWrapperToContainer()
            },
            _detachWrapperToContainer: function() {
                this._$wrapper.detach()
            },
            _moveToContainer: function() {
                this._attachWrapperToContainer();
                this._$content.appendTo(this._$wrapper)
            },
            _attachWrapperToContainer: function() {
                var $element = this.element();
                if (this._$container && this._$container[0] !== $element.parent()[0]) {
                    this._$wrapper.appendTo(this._$container)
                } else {
                    this._$wrapper.appendTo($element)
                }
            },
            _renderGeometry: function() {
                if (this.option("visible")) {
                    this._renderGeometryImpl()
                }
            },
            _renderGeometryImpl: function() {
                this._stopAnimation();
                this._normalizePosition();
                this._renderShading();
                this._renderDimensions();
                var resultPosition = this._renderPosition();
                this._actions.onPositioned({
                    position: resultPosition
                })
            },
            _renderShading: function() {
                var $wrapper = this._$wrapper,
                    $container = this._getContainer();
                $wrapper.css("position", this._isWindow($container) && !iOS ? "fixed" : "absolute");
                this._renderShadingDimensions();
                this._renderShadingPosition()
            },
            _renderShadingPosition: function() {
                if (this.option("shading")) {
                    var $container = this._getContainer();
                    positionUtils.setup(this._$wrapper, {
                        my: "top left",
                        at: "top left",
                        of: $container
                    })
                }
            },
            _renderShadingDimensions: function() {
                if (this.option("shading")) {
                    var $container = this._getContainer(),
                        wrapperWidth = this._isWindow($container) ? "100%" : $container.outerWidth(),
                        wrapperHeight = this._isWindow($container) ? "100%" : $container.outerHeight();
                    this._$wrapper.css({
                        width: wrapperWidth,
                        height: wrapperHeight
                    })
                }
            },
            _isWindow: function($element) {
                return !!$element && $.isWindow($element.get(0))
            },
            _getContainer: function() {
                var position = this._position,
                    container = this.option("container"),
                    positionOf = position ? position.of || window : null;
                return getElement(container || positionOf)
            },
            _renderDimensions: function() {
                this._$content.css({
                    minWidth: this.option("minWidth"),
                    maxWidth: this.option("maxWidth"),
                    minHeight: this.option("minHeight"),
                    maxHeight: this.option("maxHeight")
                });
                if (this._dimensionChangeHandled) {
                    var $content = this._$content,
                        $container = this._$container;
                    $content.outerWidth(Math.min($content.outerWidth(), $container.width())).outerHeight(Math.min($content.outerHeight(), $container.height()))
                } else {
                    this._$content.outerWidth(this.option("width")).outerHeight(this.option("height"))
                }
            },
            _renderPosition: function() {
                if (this._positionChangeHandled) {
                    var allowedOffsets = this._allowedOffsets();
                    this._changePosition({
                        top: fitIntoRange(0, -allowedOffsets.top, allowedOffsets.bottom),
                        left: fitIntoRange(0, -allowedOffsets.left, allowedOffsets.right)
                    })
                } else {
                    this._renderOverlayBoundaryOffset();
                    translator.resetPosition(this._$content);
                    var resultPosition = positionUtils.setup(this._$content, this._position);
                    forceRepaint(this._$content);
                    this._actions.onPositioning();
                    return resultPosition
                }
            },
            _renderOverlayBoundaryOffset: function() {
                var boundaryOffset = this.option("boundaryOffset");
                this._$content.css("margin", boundaryOffset.v + "px " + boundaryOffset.h + "px")
            },
            _focusTarget: function() {
                return this._$content
            },
            _attachKeyboardEvents: function() {
                this._keyboardProcessor = new KeyboardProcessor({
                    element: this._$content,
                    handler: this._keyboardHandler,
                    context: this
                })
            },
            _keyboardHandler: function(options) {
                var e = options.originalEvent,
                    $target = $(e.target);
                if ($target.is(this._$content)) {
                    this.callBase.apply(this, arguments)
                }
            },
            _isVisible: function() {
                return this.option("visible")
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    if (this.option("visible")) {
                        this._renderVisibilityAnimate(visible)
                    }
                } else {
                    this._renderVisibilityAnimate(visible)
                }
            },
            _dimensionChanged: function() {
                this._renderGeometry()
            },
            _clean: function() {
                if (!this._contentAlreadyRendered) {
                    this.content().empty()
                }
                this._renderVisibility(false);
                this._cleanFocusState()
            },
            _dispose: function() {
                fx.stop(this._$content, false);
                clearTimeout(this._deferShowTimer);
                this._toggleViewPortSubscription(false);
                this._toggleSubscriptions(false);
                this._updateZIndexStackPosition(false);
                this._toggleTabTerminator(false);
                this._actions = null;
                this.callBase();
                this._$wrapper.remove();
                this._$content.remove()
            },
            _toggleDisabledState: function(value) {
                this.callBase.apply(this, arguments);
                this._$content.toggleClass(DISABLED_STATE_CLASS, Boolean(value))
            },
            _toggleRTLDirection: function(rtl) {
                this._$content.toggleClass(RTL_DIRECTION_CLASS, rtl)
            },
            _optionChanged: function(args) {
                var value = args.value;
                if ($.inArray(args.name, ACTIONS) > -1) {
                    this._initActions();
                    return
                }
                switch (args.name) {
                    case "dragEnabled":
                        this._renderDrag();
                        this._renderGeometry();
                        break;
                    case "resizeEnabled":
                        this._renderResize();
                        this._renderGeometry();
                        break;
                    case "shading":
                    case "shadingColor":
                        this._toggleShading(this.option("visible"));
                        break;
                    case "width":
                    case "minWidth":
                    case "maxWidth":
                    case "height":
                    case "minHeight":
                    case "maxHeight":
                    case "position":
                    case "boundaryOffset":
                        this._renderGeometry();
                        break;
                    case "visible":
                        this._renderVisibilityAnimate(value).done($.proxy(function() {
                            if (!this._animateDeferred) {
                                return
                            }
                            this._animateDeferred.resolveWith(this)
                        }, this));
                        break;
                    case "target":
                        this._initTarget(value);
                        this._invalidate();
                        break;
                    case "container":
                        this._initContainer(value);
                        this._invalidate();
                        break;
                    case "deferRendering":
                    case "contentTemplate":
                        this._contentAlreadyRendered = false;
                        this._invalidate();
                        break;
                    case "closeOnBackButton":
                        this._toggleHideTopOverlayCallback(this.option("visible"));
                        break;
                    case "closeOnTargetScroll":
                        this._toggleParentsScrollSubscription(this.option("visible"));
                        break;
                    case "closeOnOutsideClick":
                    case "animation":
                    case "propagateOutsideClick":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            toggle: function(showing) {
                showing = void 0 === showing ? !this.option("visible") : showing;
                if (showing === this.option("visible")) {
                    return $.Deferred().resolve().promise()
                }
                var animateDeferred = $.Deferred();
                this._animateDeferred = animateDeferred;
                this.option("visible", showing);
                return animateDeferred.promise().done($.proxy(function() {
                    delete this._animateDeferred
                }, this))
            },
            show: function() {
                return this.toggle(true)
            },
            hide: function() {
                return this.toggle(false)
            },
            content: function() {
                return this._$content
            },
            repaint: function() {
                this._renderGeometry()
            }
        });
        Overlay.baseZIndex = function(zIndex) {
            FIRST_Z_INDEX = zIndex
        };
        registerComponent("dxOverlay", Overlay);
        module.exports = Overlay
    },
    /*!********************************!*\
      !*** ./Scripts/events/drag.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            wrapToArray = __webpack_require__( /*! ../core/utils/array */ 111).wrapToArray,
            registerEvent = __webpack_require__( /*! ./core/event_registrator */ 66),
            eventUtils = __webpack_require__( /*! ./utils */ 62),
            GestureEmitter = __webpack_require__( /*! ./gesture/emitter.gesture */ 78),
            registerEmitter = __webpack_require__( /*! ./core/emitter_registrator */ 76);
        var DRAG_START_EVENT = "dxdragstart",
            DRAG_EVENT = "dxdrag",
            DRAG_END_EVENT = "dxdragend",
            DRAG_ENTER_EVENT = "dxdragenter",
            DRAG_LEAVE_EVENT = "dxdragleave",
            DROP_EVENT = "dxdrop";
        var knownDropTargets = [],
            knownDropTargetSelectors = [],
            knownDropTargetConfigs = [];
        var dropTargetRegistration = {
            setup: function(element, data) {
                var knownDropTarget = $.inArray(element, knownDropTargets) !== -1;
                if (!knownDropTarget) {
                    knownDropTargets.push(element);
                    knownDropTargetSelectors.push([]);
                    knownDropTargetConfigs.push(data || {})
                }
            },
            add: function(element, handleObj) {
                var index = $.inArray(element, knownDropTargets);
                var selector = handleObj.selector;
                if ($.inArray(selector, knownDropTargetSelectors[index]) === -1) {
                    knownDropTargetSelectors[index].push(selector)
                }
            },
            teardown: function(element, data) {
                var elementEvents = $._data(element, "events"),
                    handlersCount = 0;
                $.each([DRAG_ENTER_EVENT, DRAG_LEAVE_EVENT, DROP_EVENT], function(_, eventName) {
                    var eventHandlers = elementEvents[eventName];
                    if (eventHandlers) {
                        handlersCount += eventHandlers.length
                    }
                });
                if (!handlersCount) {
                    var index = $.inArray(element, knownDropTargets);
                    knownDropTargets.splice(index, 1);
                    knownDropTargetSelectors.splice(index, 1);
                    knownDropTargetConfigs.splice(index, 1)
                }
            }
        };
        registerEvent(DRAG_ENTER_EVENT, dropTargetRegistration);
        registerEvent(DRAG_LEAVE_EVENT, dropTargetRegistration);
        registerEvent(DROP_EVENT, dropTargetRegistration);
        var getItemDelegatedTargets = function($element) {
            var dropTargetIndex = $.inArray($element.get(0), knownDropTargets),
                dropTargetSelectors = knownDropTargetSelectors[dropTargetIndex];
            var $delegatedTargets = $element.find(dropTargetSelectors.join(", "));
            if ($.inArray(void 0, dropTargetSelectors) !== -1) {
                $delegatedTargets = $delegatedTargets.addBack()
            }
            return $delegatedTargets
        };
        var getItemConfig = function($element) {
            var dropTargetIndex = $.inArray($element.get(0), knownDropTargets);
            return knownDropTargetConfigs[dropTargetIndex]
        };
        var getItemPosition = function(dropTargetConfig, $element) {
            if (dropTargetConfig.itemPositionFunc) {
                return dropTargetConfig.itemPositionFunc($element)
            } else {
                return $element.offset()
            }
        };
        var getItemSize = function(dropTargetConfig, $element) {
            if (dropTargetConfig.itemSizeFunc) {
                return dropTargetConfig.itemSizeFunc($element)
            }
            return {
                width: $element.width(),
                height: $element.height()
            }
        };
        var DragEmitter = GestureEmitter.inherit({
            ctor: function(element) {
                this.callBase(element);
                this.direction = "both"
            },
            _init: function(e) {
                this._initEvent = e
            },
            _start: function(e) {
                e = this._fireEvent(DRAG_START_EVENT, this._initEvent);
                this._maxLeftOffset = e.maxLeftOffset;
                this._maxRightOffset = e.maxRightOffset;
                this._maxTopOffset = e.maxTopOffset;
                this._maxBottomOffset = e.maxBottomOffset;
                var dropTargets = wrapToArray(e.targetElements || (null === e.targetElements ? [] : knownDropTargets));
                this._dropTargets = $.map(dropTargets, function(element) {
                    return $(element).get(0)
                })
            },
            _move: function(e) {
                var eventData = eventUtils.eventData(e),
                    dragOffset = this._calculateOffset(eventData);
                this._fireEvent(DRAG_EVENT, e, {
                    offset: dragOffset
                });
                this._processDropTargets(e, dragOffset);
                e.preventDefault()
            },
            _calculateOffset: function(eventData) {
                return {
                    x: this._calculateXOffset(eventData),
                    y: this._calculateYOffset(eventData)
                }
            },
            _calculateXOffset: function(eventData) {
                if ("vertical" !== this.direction) {
                    var offset = eventData.x - this._startEventData.x;
                    return this._fitOffset(offset, this._maxLeftOffset, this._maxRightOffset)
                }
                return 0
            },
            _calculateYOffset: function(eventData) {
                if ("horizontal" !== this.direction) {
                    var offset = eventData.y - this._startEventData.y;
                    return this._fitOffset(offset, this._maxTopOffset, this._maxBottomOffset)
                }
                return 0
            },
            _fitOffset: function(offset, minOffset, maxOffset) {
                if (null != minOffset) {
                    offset = Math.max(offset, -minOffset)
                }
                if (null != maxOffset) {
                    offset = Math.min(offset, maxOffset)
                }
                return offset
            },
            _processDropTargets: function(e, dragOffset) {
                var target = this._findDropTarget(e),
                    sameTarget = target === this._currentDropTarget;
                if (!sameTarget) {
                    this._fireDropTargetEvent(e, DRAG_LEAVE_EVENT);
                    this._currentDropTarget = target;
                    this._fireDropTargetEvent(e, DRAG_ENTER_EVENT)
                }
            },
            _fireDropTargetEvent: function(event, eventName) {
                if (!this._currentDropTarget) {
                    return
                }
                var eventData = {
                    type: eventName,
                    originalEvent: event,
                    draggingElement: this._$element.get(0),
                    target: this._currentDropTarget
                };
                eventUtils.fireEvent(eventData)
            },
            _findDropTarget: function(e) {
                var result, that = this;
                $.each(knownDropTargets, function(_, target) {
                    if (!that._checkDropTargetActive(target)) {
                        return
                    }
                    var $target = $(target);
                    $.each(getItemDelegatedTargets($target), function(_, delegatedTarget) {
                        var $delegatedTarget = $(delegatedTarget);
                        if (that._checkDropTarget(getItemConfig($target), $delegatedTarget, e)) {
                            result = delegatedTarget
                        }
                    })
                });
                return result
            },
            _checkDropTargetActive: function(target) {
                var active = false;
                $.each(this._dropTargets, function(_, activeTarget) {
                    active = active || activeTarget === target || $.contains(activeTarget, target);
                    return !active
                });
                return active
            },
            _checkDropTarget: function(config, $target, e) {
                var isDraggingElement = $target.get(0) === this._$element.get(0);
                if (isDraggingElement) {
                    return false
                }
                var targetPosition = getItemPosition(config, $target);
                if (e.pageX < targetPosition.left) {
                    return false
                }
                if (e.pageY < targetPosition.top) {
                    return false
                }
                var targetSize = getItemSize(config, $target);
                if (e.pageX > targetPosition.left + targetSize.width) {
                    return false
                }
                if (e.pageY > targetPosition.top + targetSize.height) {
                    return false
                }
                return $target
            },
            _end: function(e) {
                var eventData = eventUtils.eventData(e);
                this._fireEvent(DRAG_END_EVENT, e, {
                    offset: this._calculateOffset(eventData)
                });
                this._fireDropTargetEvent(e, DROP_EVENT);
                delete this._currentDropTarget
            }
        });
        registerEmitter({
            emitter: DragEmitter,
            events: [DRAG_START_EVENT, DRAG_EVENT, DRAG_END_EVENT]
        });
        exports.dropTargets = knownDropTargets;
        exports.move = DRAG_EVENT;
        exports.start = DRAG_START_EVENT;
        exports.end = DRAG_END_EVENT;
        exports.enter = DRAG_ENTER_EVENT;
        exports.leave = DRAG_LEAVE_EVENT;
        exports.drop = DROP_EVENT
    },
    /*!*************************************!*\
      !*** ./Scripts/core/utils/array.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ./common */ 14),
            objectUtils = __webpack_require__( /*! ./object */ 37);
        var isEmpty = function(entity) {
            return $.isArray(entity) && !entity.length
        };
        var wrapToArray = function(entity) {
            return $.isArray(entity) ? entity : [entity]
        };
        var intersection = function(a, b) {
            if (!$.isArray(a) || 0 === a.length || !$.isArray(b) || 0 === b.length) {
                return []
            }
            var result = [];
            $.each(a, function(_, value) {
                var index = $.inArray(value, b);
                if (index !== -1) {
                    result.push(value)
                }
            });
            return result
        };
        var removeDuplicates = function(from, what) {
            if (!$.isArray(from) || 0 === from.length) {
                return []
            }
            if (!$.isArray(what) || 0 === what.length) {
                return from.slice()
            }
            var result = [];
            $.each(from, function(_, value) {
                var index = $.inArray(value, what);
                if (index === -1) {
                    result.push(value)
                }
            });
            return result
        };
        var normalizeIndexes = function(items, indexParameterName, currentItem, needIndexCallback) {
            var indexedItems = {},
                parameterIndex = 0;
            $.each(items, function(index, item) {
                index = item[indexParameterName];
                if (commonUtils.isDefined(index)) {
                    indexedItems[index] = indexedItems[index] || [];
                    if (item === currentItem) {
                        indexedItems[index].unshift(item)
                    } else {
                        indexedItems[index].push(item)
                    }
                    delete item[indexParameterName]
                }
            });
            objectUtils.orderEach(indexedItems, function(index, items) {
                $.each(items, function() {
                    if (index >= 0) {
                        this[indexParameterName] = parameterIndex++
                    }
                })
            });
            $.each(items, function() {
                if (!commonUtils.isDefined(this[indexParameterName]) && (!needIndexCallback || needIndexCallback(this))) {
                    this[indexParameterName] = parameterIndex++
                }
            });
            return parameterIndex
        };
        exports.isEmpty = isEmpty;
        exports.wrapToArray = wrapToArray;
        exports.intersection = intersection;
        exports.removeDuplicates = removeDuplicates;
        exports.normalizeIndexes = normalizeIndexes
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/resizable.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            stringUtils = __webpack_require__( /*! ../core/utils/string */ 13),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            fitIntoRange = __webpack_require__( /*! ../core/utils/math */ 79).fitIntoRange,
            DOMComponent = __webpack_require__( /*! ../core/dom_component */ 29),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            dragEvents = __webpack_require__( /*! ../events/drag */ 110);
        var RESIZABLE = "dxResizable",
            RESIZABLE_CLASS = "dx-resizable",
            RESIZABLE_RESIZING_CLASS = "dx-resizable-resizing",
            RESIZABLE_HANDLE_CLASS = "dx-resizable-handle",
            RESIZABLE_HANDLE_TOP_CLASS = "dx-resizable-handle-top",
            RESIZABLE_HANDLE_BOTTOM_CLASS = "dx-resizable-handle-bottom",
            RESIZABLE_HANDLE_LEFT_CLASS = "dx-resizable-handle-left",
            RESIZABLE_HANDLE_RIGHT_CLASS = "dx-resizable-handle-right",
            RESIZABLE_HANDLE_CORNER_CLASS = "dx-resizable-handle-corner",
            DRAGSTART_START_EVENT_NAME = eventUtils.addNamespace(dragEvents.start, RESIZABLE),
            DRAGSTART_EVENT_NAME = eventUtils.addNamespace(dragEvents.move, RESIZABLE),
            DRAGSTART_END_EVENT_NAME = eventUtils.addNamespace(dragEvents.end, RESIZABLE);
        var Resizable = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    handles: "all",
                    step: "1",
                    stepPrecision: "simple",
                    area: void 0,
                    minWidth: 30,
                    maxWidth: 1 / 0,
                    minHeight: 30,
                    maxHeight: 1 / 0,
                    onResizeStart: null,
                    onResize: null,
                    onResizeEnd: null
                })
            },
            _init: function() {
                this.callBase();
                this.element().addClass(RESIZABLE_CLASS)
            },
            _render: function() {
                this.callBase();
                this._renderActions();
                this._renderHandles()
            },
            _renderActions: function() {
                this._resizeStartAction = this._createActionByOption("onResizeStart");
                this._resizeEndAction = this._createActionByOption("onResizeEnd");
                this._resizeAction = this._createActionByOption("onResize")
            },
            _renderHandles: function() {
                var handles = this.option("handles");
                if ("none" === handles) {
                    return
                }
                var directions = "all" === handles ? ["top", "bottom", "left", "right"] : handles.split(" ");
                $.each(directions, $.proxy(function(index, handleName) {
                    this._renderHandle(handleName)
                }, this));
                $.inArray("bottom", directions) + 1 && $.inArray("right", directions) + 1 && this._renderHandle("corner-bottom-right");
                $.inArray("bottom", directions) + 1 && $.inArray("left", directions) + 1 && this._renderHandle("corner-bottom-left");
                $.inArray("top", directions) + 1 && $.inArray("right", directions) + 1 && this._renderHandle("corner-top-right");
                $.inArray("top", directions) + 1 && $.inArray("left", directions) + 1 && this._renderHandle("corner-top-left")
            },
            _renderHandle: function(handleName) {
                var $element = this.element(),
                    $handle = $("<div>");
                $handle.addClass(RESIZABLE_HANDLE_CLASS).addClass(RESIZABLE_HANDLE_CLASS + "-" + handleName).appendTo($element);
                this._attachEventHandlers($handle)
            },
            _attachEventHandlers: function($handle) {
                if (this.option("disabled")) {
                    return
                }
                var handlers = {};
                handlers[DRAGSTART_START_EVENT_NAME] = $.proxy(this._dragStartHandler, this);
                handlers[DRAGSTART_EVENT_NAME] = $.proxy(this._dragHandler, this);
                handlers[DRAGSTART_END_EVENT_NAME] = $.proxy(this._dragEndHandler, this);
                $handle.on(handlers, {
                    direction: "both",
                    immediate: true
                })
            },
            _dragStartHandler: function(e) {
                var $element = this.element();
                if ($element.is(".dx-state-disabled, .dx-state-disabled *")) {
                    e.cancel = true;
                    return
                }
                this._toggleResizingClass(true);
                this._movingSides = this._getMovingSides(e);
                this._elementLocation = translator.locate($element);
                this._elementSize = {
                    width: $element.outerWidth(),
                    height: $element.outerHeight()
                };
                this._renderDragOffsets(e);
                this._resizeStartAction({
                    jQueryEvent: e,
                    width: this._elementSize.width,
                    height: this._elementSize.height,
                    handles: this._movingSides
                });
                e.targetElements = null
            },
            _toggleResizingClass: function(value) {
                this.element().toggleClass(RESIZABLE_RESIZING_CLASS, value)
            },
            _renderDragOffsets: function(e) {
                var area = this._getArea();
                if (!area) {
                    return
                }
                var $handle = $(e.target).closest("." + RESIZABLE_HANDLE_CLASS),
                    handleWidth = $handle.outerWidth(),
                    handleHeight = $handle.outerHeight(),
                    handleOffset = $handle.offset(),
                    areaOffset = area.offset;
                e.maxLeftOffset = handleOffset.left - areaOffset.left;
                e.maxRightOffset = areaOffset.left + area.width - handleOffset.left - handleWidth;
                e.maxTopOffset = handleOffset.top - areaOffset.top;
                e.maxBottomOffset = areaOffset.top + area.height - handleOffset.top - handleHeight
            },
            _getBorderWidth: function($element, direction) {
                var borderWidth = $element.css("border-" + direction + "-width");
                return parseInt(borderWidth) || 0
            },
            _dragHandler: function(e) {
                var $element = this.element(),
                    sides = this._movingSides;
                var location = this._elementLocation,
                    size = this._elementSize,
                    offset = this._getOffset(e);
                var width = size.width + offset.x * (sides.left ? -1 : 1),
                    height = size.height + offset.y * (sides.top ? -1 : 1);
                if (offset.x || "strict" === this.option("stepPrecision")) {
                    this._renderWidth(width)
                }
                if (offset.y || "strict" === this.option("stepPrecision")) {
                    this._renderHeight(height)
                }
                var offsetTop = offset.y - ((this.element().outerHeight() || height) - height),
                    offsetLeft = offset.x - ((this.element().outerWidth() || width) - width);
                translator.move($element, {
                    top: location.top + (sides.top ? offsetTop : 0),
                    left: location.left + (sides.left ? offsetLeft : 0)
                });
                this._resizeAction({
                    jQueryEvent: e,
                    width: width,
                    height: height,
                    handles: this._movingSides
                })
            },
            _getOffset: function(e) {
                var offset = e.offset,
                    steps = stringUtils.pairToObject(this.option("step")),
                    sides = this._getMovingSides(e),
                    strictPrecision = "strict" === this.option("stepPrecision");
                if (!sides.left && !sides.right) {
                    offset.x = 0
                }
                if (!sides.top && !sides.bottom) {
                    offset.y = 0
                }
                return strictPrecision ? this._getStrictOffset(offset, steps, sides) : this._getSimpleOffset(offset, steps)
            },
            _getSimpleOffset: function(offset, steps) {
                return {
                    x: offset.x - offset.x % steps.h,
                    y: offset.y - offset.y % steps.v
                }
            },
            _getStrictOffset: function(offset, steps, sides) {
                var location = this._elementLocation,
                    size = this._elementSize,
                    xPos = sides.left ? location.left : location.left + size.width,
                    yPos = sides.top ? location.top : location.top + size.height,
                    newXShift = (xPos + offset.x) % steps.h,
                    newYShift = (yPos + offset.y) % steps.v,
                    sign = Math.sign || function(x) {
                        x = +x;
                        if (0 === x || isNaN(x)) {
                            return x
                        }
                        return x > 0 ? 1 : -1
                    },
                    separatorOffset = function(steps, offset) {
                        return (1 + .2 * sign(offset)) % 1 * steps
                    },
                    isSmallOffset = function(offset, steps) {
                        return Math.abs(offset) < .2 * steps
                    };
                var newOffsetX = offset.x - newXShift,
                    newOffsetY = offset.y - newYShift;
                if (newXShift > separatorOffset(steps.h, offset.x)) {
                    newOffsetX += steps.h
                }
                if (newYShift > separatorOffset(steps.v, offset.y)) {
                    newOffsetY += steps.v
                }
                return {
                    x: (sides.left || sides.right) && !isSmallOffset(offset.x, steps.h) ? newOffsetX : 0,
                    y: (sides.top || sides.bottom) && !isSmallOffset(offset.y, steps.v) ? newOffsetY : 0
                }
            },
            _getMovingSides: function(e) {
                var $target = $(e.target),
                    hasCornerTopLeftClass = $target.hasClass(RESIZABLE_HANDLE_CORNER_CLASS + "-top-left"),
                    hasCornerTopRightClass = $target.hasClass(RESIZABLE_HANDLE_CORNER_CLASS + "-top-right"),
                    hasCornerBottomLeftClass = $target.hasClass(RESIZABLE_HANDLE_CORNER_CLASS + "-bottom-left"),
                    hasCornerBottomRightClass = $target.hasClass(RESIZABLE_HANDLE_CORNER_CLASS + "-bottom-right");
                return {
                    top: $target.hasClass(RESIZABLE_HANDLE_TOP_CLASS) || hasCornerTopLeftClass || hasCornerTopRightClass,
                    left: $target.hasClass(RESIZABLE_HANDLE_LEFT_CLASS) || hasCornerTopLeftClass || hasCornerBottomLeftClass,
                    bottom: $target.hasClass(RESIZABLE_HANDLE_BOTTOM_CLASS) || hasCornerBottomLeftClass || hasCornerBottomRightClass,
                    right: $target.hasClass(RESIZABLE_HANDLE_RIGHT_CLASS) || hasCornerTopRightClass || hasCornerBottomRightClass
                }
            },
            _getArea: function() {
                var area = this.option("area");
                if ($.isFunction(area)) {
                    area = area.call(this)
                }
                if ($.isPlainObject(area)) {
                    return this._getAreaFromObject(area)
                }
                return this._getAreaFromElement(area)
            },
            _getAreaFromObject: function(area) {
                var result = {
                    width: area.right - area.left,
                    height: area.bottom - area.top,
                    offset: {
                        left: area.left,
                        top: area.top
                    }
                };
                this._correctAreaGeometry(result);
                return result
            },
            _getAreaFromElement: function(area) {
                var result, $area = $(area);
                if ($area.length) {
                    result = {};
                    result.width = $area.innerWidth();
                    result.height = $area.innerHeight();
                    result.offset = $area.offset();
                    this._correctAreaGeometry(result, $area)
                }
                return result
            },
            _correctAreaGeometry: function(result, $area) {
                var areaBorderLeft = $area ? this._getBorderWidth($area, "left") : 0,
                    areaBorderTop = $area ? this._getBorderWidth($area, "top") : 0;
                result.offset.left += areaBorderLeft + this._getBorderWidth(this.element(), "left");
                result.offset.top += areaBorderTop + this._getBorderWidth(this.element(), "top");
                result.width -= this.element().outerWidth() - this.element().innerWidth();
                result.height -= this.element().outerHeight() - this.element().innerHeight()
            },
            _dragEndHandler: function(e) {
                var $element = this.element();
                this._resizeEndAction({
                    jQueryEvent: e,
                    width: $element.outerWidth(),
                    height: $element.outerHeight(),
                    handles: this._movingSides
                });
                this._toggleResizingClass(false)
            },
            _renderWidth: function(width) {
                this.option("width", fitIntoRange(width, this.option("minWidth"), this.option("maxWidth")))
            },
            _renderHeight: function(height) {
                this.option("height", fitIntoRange(height, this.option("minHeight"), this.option("maxHeight")))
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "disabled":
                    case "handles":
                        this._invalidate();
                        break;
                    case "minWidth":
                    case "maxWidth":
                        this._renderWidth(this.element().outerWidth());
                        break;
                    case "minHeight":
                    case "maxHeight":
                        this._renderHeight(this.element().outerHeight());
                        break;
                    case "onResize":
                    case "onResizeStart":
                    case "onResizeEnd":
                        this._renderActions();
                        break;
                    case "area":
                    case "step":
                    case "stepPrecision":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _clean: function() {
                this.element().find("." + RESIZABLE_HANDLE_CLASS).remove()
            }
        });
        registerComponent(RESIZABLE, Resizable);
        module.exports = Resizable
    },
    /*!**************************************!*\
      !*** ./Scripts/core/utils/locker.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var errors = __webpack_require__( /*! ../errors */ 17);
        var Locker = function() {
            var info = {};
            var currentCount = function(lockName) {
                return info[lockName] || 0
            };
            return {
                obtain: function(lockName) {
                    info[lockName] = currentCount(lockName) + 1
                },
                release: function(lockName) {
                    var count = currentCount(lockName);
                    if (count < 1) {
                        throw errors.Error("E0014")
                    }
                    if (1 === count) {
                        delete info[lockName]
                    } else {
                        info[lockName] = count - 1
                    }
                },
                locked: function(lockName) {
                    return currentCount(lockName) > 0
                }
            }
        };
        module.exports = Locker
    },
    /*!***********************************************************!*\
      !*** ./Scripts/integration/knockout/event_registrator.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ko = __webpack_require__( /*! knockout */ 87),
            eventRegistrator = __webpack_require__( /*! ../../events/core/event_registrator */ 66),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        eventRegistrator.callbacks.add(function(name, eventObject) {
            var koBindingEventName = eventUtils.addNamespace(name, name + "Binding");
            ko.bindingHandlers[name] = {
                update: function(element, valueAccessor, allBindingsAccessor, viewModel) {
                    var $element = $(element),
                        unwrappedValue = ko.utils.unwrapObservable(valueAccessor()),
                        eventSource = unwrappedValue.execute ? unwrappedValue.execute : unwrappedValue;
                    $element.off(koBindingEventName).on(koBindingEventName, $.isPlainObject(unwrappedValue) ? unwrappedValue : {}, function(e) {
                        eventSource.call(viewModel, viewModel, e)
                    })
                }
            }
        })
    },
    /*!****************************************************!*\
      !*** ./Scripts/integration/knockout/components.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../../core/errors */ 17),
            Action = __webpack_require__( /*! ../../core/action */ 35),
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            ko = __webpack_require__( /*! knockout */ 87),
            iconUtils = __webpack_require__( /*! ../../core/utils/icon */ 99),
            inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        ko.bindingHandlers.dxAction = {
            update: function(element, valueAccessor, allBindingsAccessor, viewModel) {
                var $element = $(element);
                var unwrappedValue = ko.utils.unwrapObservable(valueAccessor()),
                    actionSource = unwrappedValue,
                    actionOptions = {
                        context: element
                    };
                if (unwrappedValue.execute) {
                    actionSource = unwrappedValue.execute;
                    $.extend(actionOptions, unwrappedValue)
                }
                var action = new Action(actionSource, actionOptions);
                $element.off(".dxActionBinding").on(clickEvent.name + ".dxActionBinding", function(e) {
                    action.execute({
                        element: $element,
                        model: viewModel,
                        evaluate: function(expression) {
                            var context = viewModel;
                            if (expression.length > 0 && "$" === expression[0]) {
                                context = ko.contextFor(element)
                            }
                            var getter = compileGetter(expression);
                            return getter(context)
                        },
                        jQueryEvent: e
                    });
                    if (!actionOptions.bubbling) {
                        e.stopPropagation()
                    }
                })
            }
        };
        ko.bindingHandlers.dxControlsDescendantBindings = {
            init: function(_, valueAccessor) {
                return {
                    controlsDescendantBindings: ko.unwrap(valueAccessor())
                }
            }
        };
        ko.bindingHandlers.dxPolymorphWidget = {
            init: function(element, valueAccessor, allBindings, viewModel, bindingContext) {
                var widgetName = ko.utils.unwrapObservable(valueAccessor()).name;
                if (!widgetName) {
                    return
                }
                ko.virtualElements.emptyNode(element);
                if ("button" === widgetName || "tabs" === widgetName || "dropDownMenu" === widgetName) {
                    var depricatedName = widgetName;
                    widgetName = inflector.camelize("dx-" + widgetName);
                    errors.log("W0001", "dxToolbar - 'widget' item field", depricatedName, "16.1", "Use: '" + widgetName + "' instead")
                }
                var markup = $('<div data-bind="' + widgetName + ': options">').get(0);
                ko.virtualElements.prepend(element, markup);
                var innerBindingContext = bindingContext.extend(valueAccessor);
                ko.applyBindingsToDescendants(innerBindingContext, element);
                return {
                    controlsDescendantBindings: true
                }
            }
        };
        ko.virtualElements.allowedBindings.dxPolymorphWidget = true;
        ko.bindingHandlers.dxIcon = {
            init: function(element, valueAccessor) {
                var options = ko.utils.unwrapObservable(valueAccessor()) || {},
                    iconElement = iconUtils.getImageContainer(options);
                ko.virtualElements.emptyNode(element);
                if (iconElement) {
                    ko.virtualElements.prepend(element, iconElement.get(0))
                }
            },
            update: function(element, valueAccessor) {
                var options = ko.utils.unwrapObservable(valueAccessor()) || {},
                    iconElement = iconUtils.getImageContainer(options);
                ko.virtualElements.emptyNode(element);
                if (iconElement) {
                    ko.virtualElements.prepend(element, iconElement.get(0))
                }
            }
        };
        ko.virtualElements.allowedBindings.dxIcon = true;
        ko.bindingHandlers.dxShorttimeDate = {
            update: function(element, valueAccessor, allBindingsAccessor) {
                return ko.bindingHandlers.text.update(element, function() {
                    var value = ko.utils.unwrapObservable(valueAccessor());
                    return dateUtils.serializeDate(dateUtils.makeDate(value), "shorttime", $.proxy(dateLocalization.format, dateLocalization))
                }, allBindingsAccessor, null, null)
            }
        }
    },
    /*!****************************************************!*\
      !*** ./Scripts/integration/knockout/validation.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            EventsMixin = __webpack_require__( /*! ../../core/events_mixin */ 39),
            ValidationEngine = __webpack_require__( /*! ../../ui/validation_engine */ 117),
            ko = __webpack_require__( /*! knockout */ 87);
        var koDxValidator = Class.inherit({
            ctor: function(target, option) {
                var that = this;
                that.target = target;
                that.validationRules = option.validationRules;
                that.name = option.name;
                that.isValid = ko.observable(true);
                that.validationError = ko.observable();
                $.each(this.validationRules, function(_, rule) {
                    rule.validator = that
                })
            },
            validate: function() {
                var result = ValidationEngine.validate(this.target(), this.validationRules, this.name);
                this._applyValidationResult(result);
                return result
            },
            reset: function() {
                this.target(null);
                var result = {
                    isValid: true,
                    brokenRule: null
                };
                this._applyValidationResult(result);
                return result
            },
            _applyValidationResult: function(result) {
                result.validator = this;
                this.target.dxValidator.isValid(result.isValid);
                this.target.dxValidator.validationError(result.brokenRule);
                this.fireEvent("validated", [result])
            }
        }).include(EventsMixin);
        ko.extenders.dxValidator = function(target, option) {
            target.dxValidator = new koDxValidator(target, option);
            target.subscribe($.proxy(target.dxValidator.validate, target.dxValidator));
            return target
        };
        ValidationEngine.registerModelForValidation = function(model) {
            $.each(model, function(name, member) {
                if (ko.isObservable(member) && member.dxValidator) {
                    ValidationEngine.registerValidatorInGroup(model, member.dxValidator)
                }
            })
        };
        ValidationEngine.unregisterModelForValidation = function(model) {
            $.each(model, function(name, member) {
                if (ko.isObservable(member) && member.dxValidator) {
                    ValidationEngine.removeRegisteredValidator(model, member.dxValidator)
                }
            })
        };
        ValidationEngine.validateModel = ValidationEngine.validateGroup
    },
    /*!*****************************************!*\
      !*** ./Scripts/ui/validation_engine.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            EventsMixin = __webpack_require__( /*! ../core/events_mixin */ 39),
            errors = __webpack_require__( /*! ../core/errors */ 17),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            numberLocalization = __webpack_require__( /*! ../localization/number */ 22),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80);
        var rulesValidators = {
            required: {
                validate: function(value, rule) {
                    if (!commonUtils.isDefined(value)) {
                        return false
                    }
                    if (false === value) {
                        return false
                    }
                    value = String(value);
                    if (rule.trim || !commonUtils.isDefined(rule.trim)) {
                        value = $.trim(value)
                    }
                    return "" !== value
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-required")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-required-formatted")(value)
                }
            },
            numeric: {
                validate: function(value, rule) {
                    if (!rulesValidators.required.validate(value, {})) {
                        return true
                    }
                    if (rule.useCultureSettings && commonUtils.isString(value)) {
                        return !isNaN(numberLocalization.parse(value))
                    } else {
                        return $.isNumeric(value)
                    }
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-numeric")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-numeric-formatted")(value)
                }
            },
            range: {
                validate: function(value, rule) {
                    if (!rulesValidators.required.validate(value, {})) {
                        return true
                    }
                    var validNumber = rulesValidators.numeric.validate(value, rule),
                        validValue = commonUtils.isDefined(value),
                        number = validNumber ? parseFloat(value) : validValue && value.valueOf(),
                        min = rule.min,
                        max = rule.max;
                    if (!(validNumber || commonUtils.isDate(value)) && !validValue) {
                        return false
                    }
                    if (commonUtils.isDefined(min)) {
                        if (commonUtils.isDefined(max)) {
                            return number >= min && number <= max
                        }
                        return number >= min
                    } else {
                        if (commonUtils.isDefined(max)) {
                            return number <= max
                        } else {
                            throw errors.Error("E0101")
                        }
                    }
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-range")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-range-formatted")(value)
                }
            },
            stringLength: {
                validate: function(value, rule) {
                    value = commonUtils.isDefined(value) ? String(value) : "";
                    if (rule.trim || !commonUtils.isDefined(rule.trim)) {
                        value = $.trim(value)
                    }
                    return rulesValidators.range.validate(value.length, $.extend({}, rule))
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-stringLength")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-stringLength-formatted")(value)
                }
            },
            custom: {
                validate: function(value, rule) {
                    return rule.validationCallback({
                        value: value,
                        validator: rule.validator,
                        rule: rule
                    })
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-custom")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-custom-formatted")(value)
                }
            },
            compare: {
                validate: function(value, rule) {
                    if (!rule.comparisonTarget) {
                        throw errors.Error("E0102")
                    }
                    $.extend(rule, {
                        reevaluate: true
                    });
                    var otherValue = rule.comparisonTarget(),
                        type = rule.comparisonType || "==";
                    switch (type) {
                        case "==":
                            return value == otherValue;
                        case "!=":
                            return value != otherValue;
                        case "===":
                            return value === otherValue;
                        case "!==":
                            return value !== otherValue;
                        case ">":
                            return value > otherValue;
                        case ">=":
                            return value >= otherValue;
                        case "<":
                            return value < otherValue;
                        case "<=":
                            return value <= otherValue
                    }
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-compare")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-compare-formatted")(value)
                }
            },
            pattern: {
                validate: function(value, rule) {
                    if (!rulesValidators.required.validate(value, {})) {
                        return true
                    }
                    var pattern = rule.pattern;
                    if (commonUtils.isString(pattern)) {
                        pattern = new RegExp(pattern)
                    }
                    return pattern.test(value)
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-pattern")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-pattern-formatted")(value)
                }
            },
            email: {
                validate: function(value, rule) {
                    if (!rulesValidators.required.validate(value, {})) {
                        return true
                    }
                    return rulesValidators.pattern.validate(value, $.extend({}, rule, {
                        pattern: /^[\d\w\._\-]+@([\d\w\._\-]+\.)+[\w]+$/i
                    }))
                },
                defaultMessage: function(value) {
                    return messageLocalization.getFormatter("validation-email")(value)
                },
                defaultFormattedMessage: function(value) {
                    return messageLocalization.getFormatter("validation-email-formatted")(value)
                }
            }
        };
        var GroupConfig = Class.inherit({
            ctor: function(group) {
                this.group = group;
                this.validators = []
            },
            validate: function() {
                var result = {
                    isValid: true,
                    brokenRules: [],
                    validators: []
                };
                $.each(this.validators, function(_, validator) {
                    var validatorResult = validator.validate();
                    result.isValid = result.isValid && validatorResult.isValid;
                    if (validatorResult.brokenRule) {
                        result.brokenRules.push(validatorResult.brokenRule)
                    }
                    result.validators.push(validator)
                });
                this.fireEvent("validated", [{
                    validators: result.validators,
                    brokenRules: result.brokenRules,
                    isValid: result.isValid
                }]);
                return result
            },
            reset: function() {
                $.each(this.validators, function(_, validator) {
                    validator.reset()
                })
            }
        }).include(EventsMixin);
        var ValidationEngine = {
            groups: [],
            getGroupConfig: function(group) {
                var result = $.grep(this.groups, function(config) {
                    return config.group === group
                });
                if (result.length) {
                    return result[0]
                }
            },
            initGroups: function() {
                this.groups = [];
                this.addGroup()
            },
            addGroup: function(group) {
                var config = this.getGroupConfig(group);
                if (!config) {
                    config = new GroupConfig(group);
                    this.groups.push(config)
                }
                return config
            },
            removeGroup: function(group) {
                var config = this.getGroupConfig(group),
                    index = $.inArray(config, this.groups);
                if (index > -1) {
                    this.groups.splice(index, 1)
                }
                return config
            },
            _setDefaultMessage: function(rule, validator, name) {
                if (!commonUtils.isDefined(rule.message)) {
                    if (validator.defaultFormattedMessage && commonUtils.isDefined(name)) {
                        rule.message = validator.defaultFormattedMessage(name)
                    } else {
                        rule.message = validator.defaultMessage()
                    }
                }
            },
            validate: function(value, rules, name) {
                var result = {
                        name: name,
                        value: value,
                        brokenRule: null,
                        isValid: true,
                        validationRules: rules
                    },
                    that = this;
                $.each(rules || [], function(_, rule) {
                    var ruleValidationResult, ruleValidator = rulesValidators[rule.type];
                    if (ruleValidator) {
                        if (commonUtils.isDefined(rule.isValid) && rule.value === value && !rule.reevaluate) {
                            if (!rule.isValid) {
                                result.isValid = false;
                                result.brokenRule = rule;
                                return false
                            }
                            return true
                        }
                        rule.value = value;
                        ruleValidationResult = ruleValidator.validate(value, rule);
                        rule.isValid = ruleValidationResult;
                        if (!ruleValidationResult) {
                            result.isValid = false;
                            that._setDefaultMessage(rule, ruleValidator, name);
                            result.brokenRule = rule
                        }
                        if (!rule.isValid) {
                            return false
                        }
                    } else {
                        throw errors.Error("E0100")
                    }
                });
                return result
            },
            registerValidatorInGroup: function(group, validator) {
                var groupConfig = ValidationEngine.addGroup(group);
                if ($.inArray(validator, groupConfig.validators) < 0) {
                    groupConfig.validators.push(validator)
                }
            },
            removeRegisteredValidator: function(group, validator) {
                var config = ValidationEngine.getGroupConfig(group),
                    validatorsInGroup = config && config.validators;
                var index = $.inArray(validator, validatorsInGroup);
                if (index > -1) {
                    validatorsInGroup.splice(index, 1)
                }
            },
            validateGroup: function(group) {
                var groupConfig = ValidationEngine.getGroupConfig(group);
                if (!groupConfig) {
                    throw errors.Error("E0110")
                }
                return groupConfig.validate()
            },
            resetGroup: function(group) {
                var groupConfig = ValidationEngine.getGroupConfig(group);
                if (!groupConfig) {
                    throw errors.Error("E0110")
                }
                return groupConfig.reset()
            }
        };
        ValidationEngine.initGroups();
        module.exports = ValidationEngine
    },
    /*!****************************************************************!*\
      !*** ./Scripts/integration/knockout/variable_wrapper_utils.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var ko = __webpack_require__( /*! knockout */ 87),
            variableWrapper = __webpack_require__( /*! ../../core/utils/variable_wrapper */ 38);
        variableWrapper.inject({
            isWrapped: ko.isObservable,
            isWritableWrapped: ko.isWritableObservable,
            wrap: ko.observable,
            unwrap: function(value) {
                if (ko.isObservable(value)) {
                    return ko.utils.unwrapObservable(value)
                }
                return this.callBase(value)
            },
            assign: function(variable, value) {
                if (ko.isObservable(variable)) {
                    variable(value)
                } else {
                    this.callBase(variable, value)
                }
            }
        })
    },
    /*!****************************************************!*\
      !*** ./Scripts/integration/knockout/clean_node.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ko = __webpack_require__( /*! knockout */ 87),
            cleanData = $.cleanData,
            compareVersion = __webpack_require__( /*! ../../core/utils/version */ 45).compare;
        if (compareVersion($.fn.jquery, [2, 0]) >= 0) {
            $.cleanData = function(nodes) {
                var result = cleanData(nodes);
                for (var i = 0; i < nodes.length; i++) {
                    nodes[i].cleanedByJquery = true
                }
                for (i = 0; i < nodes.length; i++) {
                    if (!nodes[i].cleanedByKo) {
                        ko.cleanNode(nodes[i])
                    }
                    delete nodes[i].cleanedByKo
                }
                for (i = 0; i < nodes.length; i++) {
                    delete nodes[i].cleanedByJquery
                }
                return result
            };
            ko.utils.domNodeDisposal.cleanExternalData = function(node) {
                node.cleanedByKo = true;
                if (!node.cleanedByJquery) {
                    $.cleanData([node])
                }
            }
        }
    },
    /*!********************************************************!*\
      !*** ./Scripts/integration/knockout/clean_node_old.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ko = __webpack_require__( /*! knockout */ 87),
            compareVersion = __webpack_require__( /*! ../../core/utils/version */ 45).compare;
        if (compareVersion($.fn.jquery, [2, 0]) < 0) {
            var cleanKoData = function(element, andSelf) {
                var cleanNode = function() {
                    ko.cleanNode(this)
                };
                if (andSelf) {
                    element.each(cleanNode)
                } else {
                    element.find("*").each(cleanNode)
                }
            };
            var originalEmpty = $.fn.empty;
            $.fn.empty = function() {
                cleanKoData(this, false);
                return originalEmpty.apply(this, arguments)
            };
            var originalRemove = $.fn.remove;
            $.fn.remove = function(selector, keepData) {
                if (!keepData) {
                    var subject = this;
                    if (selector) {
                        subject = subject.filter(selector)
                    }
                    cleanKoData(subject, true)
                }
                return originalRemove.call(this, selector, keepData)
            };
            var originalHtml = $.fn.html;
            $.fn.html = function(value) {
                if ("string" === typeof value) {
                    cleanKoData(this, false)
                }
                return originalHtml.apply(this, arguments)
            };
            var originalReplaceWith = $.fn.replaceWith;
            $.fn.replaceWith = function(value) {
                var result = originalReplaceWith.apply(this, arguments);
                if (!this.parent().length) {
                    cleanKoData(this, true)
                }
                return result
            }
        }
    },
    /*!**************************************!*\
      !*** ./Scripts/framework/command.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ./errors */ 122),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            DOMComponent = __webpack_require__( /*! ../core/dom_component */ 29);
        __webpack_require__( /*! ../integration/knockout */ 86);
        var Command = DOMComponent.inherit({
            ctor: function(element, options) {
                if ($.isPlainObject(element)) {
                    options = element;
                    element = $("<div />")
                }
                this.callBase(element, options)
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    iconSrc: {
                        since: "15.1",
                        alias: "icon"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    onExecute: null,
                    id: null,
                    title: "",
                    icon: "",
                    visible: true,
                    disabled: false,
                    renderStage: "onViewShown"
                })
            },
            execute: function() {
                var isDisabled = this._options.disabled;
                if ($.isFunction(isDisabled)) {
                    isDisabled = !!isDisabled.apply(this, arguments)
                }
                if (isDisabled) {
                    throw errors.Error("E3004", this._options.id)
                }
                this.fireEvent("beforeExecute", arguments);
                this._createActionByOption("onExecute").apply(this, arguments);
                this.fireEvent("afterExecute", arguments)
            },
            _render: function() {
                this.callBase();
                this.element().addClass("dx-command")
            },
            _renderDisabledState: $.noop,
            _dispose: function() {
                this.callBase();
                this.element().removeData(this.NAME)
            }
        });
        registerComponent("dxCommand", Command);
        module.exports = Command
    },
    /*!*************************************!*\
      !*** ./Scripts/framework/errors.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var errorUtils = __webpack_require__( /*! ../core/utils/error */ 11),
            errors = __webpack_require__( /*! ../core/errors */ 17);
        module.exports = errorUtils(errors.ERROR_MESSAGES, {
            E3001: "Routing rule is not found for the '{0}' URI.",
            E3002: "The passed object cannot be formatted into a URI string by the application's router. An appropriate route should be registered.",
            E3003: "Unable to navigate. Application is being initialized.",
            E3004: "Cannot execute the command: {0}.",
            E3005: "The '{0}' command {1} is not registered in the application's command mapping. Go to http://dxpr.es/1bTjfj1 for more details.",
            E3006: "Unknown navigation target: '{0}'. Use the 'current', 'back' or 'blank' values.",
            E3007: "Error while restoring the application state. The state has been cleared. Refresh the page.",
            E3008: "Unable to go back.",
            E3009: "Unable to go forward.",
            E3010: "The command's 'id' option should be specified.\r\nProcessed markup: {0}\n",
            E3011: "Layout controller cannot be resolved. There are no appropriate layout controllers for the current context. Check browser console for details.",
            E3012: "Layout controller cannot be resolved. Two or more layout controllers suit the current context. Check browser console for details.",
            E3013: "The '{0}' template with the '{1}' name is not found. Make sure the case is correct in the specified view name and the template fits the current context.",
            E3014: "All the children of the dxView element should be either of the dxCommand or dxContent type.\r\nProcessed markup: {0}",
            E3015: "The 'exec' method should be called before the 'finalize' method.",
            E3016: "Unknown transition type '{0}'.",
            E3018: "Unable to parse options.\nMessage: {0};\nOptions value: {1}.",
            E3019: "View templates should be updated according to the 13.1 changes. Go to http://dxpr.es/15ikrJA for more details.",
            E3020: "Concurrent templates are found:\r\n{0}Target device:\r\n{1}.",
            E3021: "Remote template cannot be loaded.\r\nUrl:{0}\r\nError:{1}.",
            E3022: "Cannot initialize the HtmlApplication component.",
            E3023: "Navigation item is not found",
            E3024: "Layout controller is not initialized",
            W3001: "A view with the '{0}' key doesn't exist.",
            W3002: "A view with the '{0}' key has already been released.",
            W3003: "Layout resolving context:\n{0}\nAvailable layout controller registrations:\n{1}\n",
            W3004: "Layout resolving context:\n{0}\nConcurent layout controller registrations for the context:\n{1}\n",
            W3005: 'Direct hash-based navigation is detected in a mobile application. Use data-bind="dxAction: url" instead of href="#url" to avoid navigation issues.\nFound markup:\n{0}\n'
        })
    },
    /*!*************************************!*\
      !*** ./Scripts/framework/router.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20);
        var JSON_URI_PREFIX = encodeURIComponent("json:");
        var Route = Class.inherit({
            _trimSeparators: function(str) {
                return str.replace(/^[\/.]+|\/+$/g, "")
            },
            _escapeRe: function(str) {
                return str.replace(/\W/g, "\\$1")
            },
            _checkConstraint: function(param, constraint) {
                param = String(param);
                if ("string" === typeof constraint) {
                    constraint = new RegExp(constraint)
                }
                var match = constraint.exec(param);
                if (!match || match[0] !== param) {
                    return false
                }
                return true
            },
            _ensureReady: function() {
                var that = this;
                if (this._patternRe) {
                    return false
                }
                this._pattern = this._trimSeparators(this._pattern);
                this._patternRe = "";
                this._params = [];
                this._segments = [];
                this._separators = [];
                this._pattern.replace(/[^\/]+/g, function(segment, index) {
                    that._segments.push(segment);
                    if (index) {
                        that._separators.push(that._pattern.substr(index - 1, 1))
                    }
                });
                $.each(this._segments, function(index) {
                    var isStatic = true,
                        segment = this,
                        separator = index ? that._separators[index - 1] : "";
                    if (":" === segment.charAt(0)) {
                        isStatic = false;
                        segment = segment.substr(1);
                        that._params.push(segment);
                        that._patternRe += "(?:" + separator + "([^/]*))";
                        if (segment in that._defaults) {
                            that._patternRe += "?"
                        }
                    } else {
                        that._patternRe += separator + that._escapeRe(segment)
                    }
                });
                this._patternRe = new RegExp("^" + this._patternRe + "$")
            },
            ctor: function(pattern, defaults, constraints) {
                this._pattern = pattern || "";
                this._defaults = defaults || {};
                this._constraints = constraints || {}
            },
            parse: function(uri) {
                var that = this;
                this._ensureReady();
                var matches = this._patternRe.exec(uri);
                if (!matches) {
                    return false
                }
                var result = $.extend({}, this._defaults);
                $.each(this._params, function(i) {
                    var index = i + 1;
                    if (matches.length >= index && matches[index]) {
                        result[this] = that.parseSegment(matches[index])
                    }
                });
                $.each(this._constraints, function(key) {
                    if (!that._checkConstraint(result[key], that._constraints[key])) {
                        result = false;
                        return false
                    }
                });
                return result
            },
            format: function(routeValues) {
                var that = this,
                    query = "";
                this._ensureReady();
                var mergeValues = $.extend({}, this._defaults),
                    useStatic = 0,
                    ret = [],
                    dels = [],
                    unusedRouteValues = {};
                $.each(routeValues, function(paramName, paramValue) {
                    routeValues[paramName] = that.formatSegment(paramValue);
                    if (!(paramName in mergeValues)) {
                        unusedRouteValues[paramName] = true
                    }
                });
                $.each(this._segments, function(index, segment) {
                    ret[index] = index ? that._separators[index - 1] : "";
                    if (":" === segment.charAt(0)) {
                        var paramName = segment.substr(1);
                        if (!(paramName in routeValues) && !(paramName in that._defaults)) {
                            ret = null;
                            return false
                        }
                        if (paramName in that._constraints && !that._checkConstraint(routeValues[paramName], that._constraints[paramName])) {
                            ret = null;
                            return false
                        }
                        if (paramName in routeValues) {
                            if (void 0 !== routeValues[paramName]) {
                                mergeValues[paramName] = routeValues[paramName];
                                ret[index] += routeValues[paramName];
                                useStatic = index
                            }
                            delete unusedRouteValues[paramName]
                        } else {
                            if (paramName in mergeValues) {
                                ret[index] += mergeValues[paramName];
                                dels.push(index)
                            }
                        }
                    } else {
                        ret[index] += segment;
                        useStatic = index
                    }
                });
                $.each(mergeValues, function(key, value) {
                    if (!!value && $.inArray(":" + key, that._segments) === -1 && routeValues[key] !== value) {
                        ret = null;
                        return false
                    }
                });
                var unusedCount = 0;
                if (!$.isEmptyObject(unusedRouteValues)) {
                    query = "?";
                    $.each(unusedRouteValues, function(key) {
                        query += key + "=" + routeValues[key] + "&";
                        unusedCount++
                    });
                    query = query.substr(0, query.length - 1)
                }
                if (null === ret) {
                    return false
                }
                if (dels.length) {
                    $.map(dels, function(i) {
                        if (i >= useStatic) {
                            ret[i] = ""
                        }
                    })
                }
                var path = ret.join("");
                path = path.replace(/\/+$/, "");
                return {
                    uri: path + query,
                    unusedCount: unusedCount
                }
            },
            formatSegment: function(value) {
                if ($.isArray(value) || $.isPlainObject(value)) {
                    return JSON_URI_PREFIX + encodeURIComponent(JSON.stringify(value))
                }
                return encodeURIComponent(value)
            },
            parseSegment: function(value) {
                if (value.substr(0, JSON_URI_PREFIX.length) === JSON_URI_PREFIX) {
                    try {
                        return $.parseJSON(decodeURIComponent(value.substr(JSON_URI_PREFIX.length)))
                    } catch (x) {}
                }
                return decodeURIComponent(value)
            }
        });
        var Router = Class.inherit({
            ctor: function() {
                this._registry = []
            },
            _trimSeparators: function(str) {
                return str.replace(/^[\/.]+|\/+$/g, "")
            },
            _createRoute: function(pattern, defaults, constraints) {
                return new Route(pattern, defaults, constraints)
            },
            register: function(pattern, defaults, constraints) {
                this._registry.push(this._createRoute(pattern, defaults, constraints))
            },
            _parseQuery: function(query) {
                var result = {},
                    values = query.split("&");
                $.each(values, function(index, value) {
                    var keyValuePair = value.split("=");
                    result[keyValuePair[0]] = decodeURIComponent(keyValuePair[1])
                });
                return result
            },
            parse: function(uri) {
                var ret, that = this;
                uri = this._trimSeparators(uri);
                var parts = uri.split("?", 2),
                    path = parts[0],
                    query = parts[1];
                $.each(this._registry, function() {
                    var result = this.parse(path);
                    if (false !== result) {
                        ret = result;
                        if (query) {
                            ret = $.extend(ret, that._parseQuery(query))
                        }
                        return false
                    }
                });
                return ret ? ret : false
            },
            format: function(obj) {
                var ret = false,
                    minUnusedCount = 99999;
                obj = obj || {};
                $.each(this._registry, function() {
                    var toFormat = $.extend(true, {}, obj);
                    var result = this.format(toFormat);
                    if (false !== result) {
                        if (minUnusedCount > result.unusedCount) {
                            minUnusedCount = result.unusedCount;
                            ret = result.uri
                        }
                    }
                });
                return ret
            }
        });
        Route.__internals = {
            JSON_URI_PREFIX: JSON_URI_PREFIX
        };
        module.exports = Router;
        module.exports.Route = Route
    },
    /*!********************************************!*\
      !*** ./Scripts/framework/state_manager.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var Class = __webpack_require__( /*! ../core/class */ 20),
            $ = __webpack_require__( /*! jquery */ 9);
        var MemoryKeyValueStorage = Class.inherit({
            ctor: function() {
                this.storage = {}
            },
            getItem: function(key) {
                return this.storage[key]
            },
            setItem: function(key, value) {
                this.storage[key] = value
            },
            removeItem: function(key) {
                delete this.storage[key]
            }
        });
        var StateManager = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this.storage = options.storage || new MemoryKeyValueStorage;
                this.stateSources = options.stateSources || []
            },
            addStateSource: function(stateSource) {
                this.stateSources.push(stateSource)
            },
            removeStateSource: function(stateSource) {
                var index = $.inArray(stateSource, this.stateSources);
                if (index > -1) {
                    this.stateSources.splice(index, 1);
                    stateSource.removeState(this.storage)
                }
            },
            saveState: function() {
                var that = this;
                $.each(this.stateSources, function(index, stateSource) {
                    stateSource.saveState(that.storage)
                })
            },
            restoreState: function() {
                var that = this;
                $.each(this.stateSources, function(index, stateSource) {
                    stateSource.restoreState(that.storage)
                })
            },
            clearState: function() {
                var that = this;
                $.each(this.stateSources, function(index, stateSource) {
                    stateSource.removeState(that.storage)
                })
            }
        });
        module.exports = StateManager;
        module.exports.MemoryKeyValueStorage = MemoryKeyValueStorage
    },
    /*!*****************************************!*\
      !*** ./Scripts/framework/view_cache.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            EventsMixin = __webpack_require__( /*! ../core/events_mixin */ 39);
        var ViewCache = Class.inherit({
            ctor: function() {
                this._cache = {}
            },
            setView: function(key, viewInfo) {
                this._cache[key] = viewInfo
            },
            getView: function(key) {
                return this._cache[key]
            },
            removeView: function(key) {
                var result = this._cache[key];
                if (result) {
                    delete this._cache[key];
                    this.fireEvent("viewRemoved", [{
                        viewInfo: result
                    }])
                }
                return result
            },
            clear: function() {
                var that = this;
                $.each(this._cache, function(key) {
                    that.removeView(key)
                })
            },
            hasView: function(key) {
                return key in this._cache
            }
        }).include(EventsMixin);
        var NullViewCache = ViewCache.inherit({
            setView: function(key, viewInfo) {
                this.callBase(key, viewInfo);
                this.removeView(key)
            }
        });
        var ConditionalViewCacheDecorator = Class.inherit({
            ctor: function(options) {
                this._filter = options.filter;
                this._viewCache = options.viewCache;
                this.viewRemoved = this._viewCache.viewRemoved;
                this._events = this._viewCache._events
            },
            setView: function(key, viewInfo) {
                this._viewCache.setView(key, viewInfo);
                if (!this._filter(key, viewInfo)) {
                    this._viewCache.removeView(key)
                }
            },
            getView: function(key) {
                return this._viewCache.getView(key)
            },
            removeView: function(key) {
                return this._viewCache.removeView(key)
            },
            clear: function() {
                return this._viewCache.clear()
            },
            hasView: function(key) {
                return this._viewCache.hasView(key)
            }
        }).include(EventsMixin);
        var DEFAULT_VIEW_CACHE_CAPACITY = 5;
        var CapacityViewCacheDecorator = Class.inherit({
            ctor: function(options) {
                this._keys = [];
                this._size = options.size || DEFAULT_VIEW_CACHE_CAPACITY;
                this._viewCache = options.viewCache;
                this.viewRemoved = this._viewCache.viewRemoved;
                this._events = this._viewCache._events
            },
            setView: function(key, viewInfo) {
                if (!this.hasView(key)) {
                    if (this._keys.length === this._size) {
                        this.removeView(this._keys[0])
                    }
                    this._keys.push(key)
                }
                this._viewCache.setView(key, viewInfo)
            },
            getView: function(key) {
                var index = $.inArray(key, this._keys);
                if (index < 0) {
                    return null
                }
                this._keys.push(key);
                this._keys.splice(index, 1);
                return this._viewCache.getView(key)
            },
            removeView: function(key) {
                var index = $.inArray(key, this._keys);
                if (index > -1) {
                    this._keys.splice(index, 1)
                }
                return this._viewCache.removeView(key)
            },
            clear: function() {
                this._keys = [];
                return this._viewCache.clear()
            },
            hasView: function(key) {
                return this._viewCache.hasView(key)
            }
        }).include(EventsMixin);
        var HistoryDependentViewCacheDecorator = Class.inherit({
            ctor: function(options) {
                this._viewCache = options.viewCache || new ViewCache;
                this._navigationManager = options.navigationManager;
                this._navigationManager.on("itemRemoved", $.proxy(this._onNavigationItemRemoved, this));
                this.viewRemoved = this._viewCache.viewRemoved;
                this._events = this._viewCache._events
            },
            _onNavigationItemRemoved: function(item) {
                this.removeView(item.key)
            },
            setView: function(key, viewInfo) {
                this._viewCache.setView(key, viewInfo)
            },
            getView: function(key) {
                return this._viewCache.getView(key)
            },
            removeView: function(key) {
                return this._viewCache.removeView(key)
            },
            clear: function() {
                return this._viewCache.clear()
            },
            hasView: function(key) {
                return this._viewCache.hasView(key)
            }
        }).include(EventsMixin);
        module.exports = ViewCache;
        module.exports.NullViewCache = NullViewCache;
        module.exports.ConditionalViewCacheDecorator = ConditionalViewCacheDecorator;
        module.exports.CapacityViewCacheDecorator = CapacityViewCacheDecorator;
        module.exports.HistoryDependentViewCacheDecorator = HistoryDependentViewCacheDecorator
    },
    /*!*****************************************************!*\
      !*** ./Scripts/framework/html/command_container.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            MarkupComponent = __webpack_require__( /*! ./markup_component */ 127).MarkupComponent,
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43);
        __webpack_require__( /*! ../../integration/knockout */ 86);
        var CommandContainer = MarkupComponent.inherit({
            ctor: function(element, options) {
                if ($.isPlainObject(element)) {
                    options = element;
                    element = $("<div />")
                }
                this.callBase(element, options)
            },
            _setDefaultOptions: function() {
                this.callBase();
                this.option({
                    id: null
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass("dx-command-container")
            }
        });
        registerComponent("dxCommandContainer", CommandContainer);
        module.exports = CommandContainer
    },
    /*!****************************************************!*\
      !*** ./Scripts/framework/html/markup_component.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            publicComponentUtils = __webpack_require__( /*! ../../core/utils/public_component */ 31);
        var MarkupComponent = Class.inherit({
            ctor: function(element, options) {
                this.NAME = this.constructor.publicName();
                options = options || {};
                this._$element = $(element);
                publicComponentUtils.attachInstanceToElement(this._$element, this.NAME, this, this._dispose);
                if (options.fromCache) {
                    this._options = options
                } else {
                    this._options = {};
                    this._setDefaultOptions();
                    if (options) {
                        this.option(options)
                    }
                    this._render()
                }
            },
            _setDefaultOptions: $.noop,
            _render: $.noop,
            _dispose: $.noop,
            element: function() {
                return this._$element
            },
            option: function(name, value) {
                if (0 === arguments.length) {
                    return this._options
                } else {
                    if (1 === arguments.length) {
                        if ("string" === typeof name) {
                            return this._options[name]
                        } else {
                            value = name;
                            $.extend(this._options, value)
                        }
                    } else {
                        this._options[name] = value
                    }
                }
            },
            instance: function() {
                return this
            }
        });
        MarkupComponent.publicName = publicComponentUtils.getName;
        MarkupComponent.getInstance = function($element) {
            return publicComponentUtils.getInstanceByElement($element, this.publicName())
        };
        exports.MarkupComponent = MarkupComponent
    },
    /*!**********************************************************!*\
      !*** ./Scripts/framework/html/view_engine_components.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var errors = __webpack_require__( /*! ../errors */ 122),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            MarkupComponent = __webpack_require__( /*! ./markup_component */ 127).MarkupComponent;
        __webpack_require__( /*! ../../integration/knockout */ 86);
        var View = MarkupComponent.inherit({
            _setDefaultOptions: function() {
                this.callBase();
                this.option({
                    name: null,
                    title: null
                })
            },
            ctor: function() {
                this._id = domUtils.uniqueId();
                this.callBase.apply(this, arguments)
            },
            _render: function() {
                this.callBase();
                this.element().addClass("dx-view");
                this.element().attr("dx-data-template-id", this._id)
            },
            getId: function() {
                return this._id
            }
        });
        var Layout = MarkupComponent.inherit({
            _setDefaultOptions: function() {
                this.callBase();
                this.option({
                    name: null
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass("dx-layout")
            }
        });
        var ViewPlaceholder = MarkupComponent.inherit({
            _setDefaultOptions: function() {
                this.callBase();
                this.option({
                    viewName: null
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass("dx-view-placeholder")
            }
        });
        var setupTransitionElement = function($element, transitionType, transitionName, contentCssPosition) {
            if ("absolute" === contentCssPosition) {
                $element.addClass("dx-transition-absolute")
            } else {
                $element.addClass("dx-transition-static")
            }
            $element.addClass("dx-transition").addClass("dx-transition-" + transitionName).addClass("dx-transition-" + transitionType).attr("data-dx-transition-type", transitionType).attr("data-dx-transition-name", transitionName)
        };
        var setupTransitionInnerElement = function($element) {
            $element.addClass("dx-transition-inner-wrapper")
        };
        var Transition = MarkupComponent.inherit({
            _setDefaultOptions: function() {
                this.callBase();
                this.option({
                    name: null,
                    type: void 0,
                    animation: "slide"
                })
            },
            _render: function() {
                this.callBase();
                var element = this.element();
                setupTransitionElement(element, this.option("type") || this.option("animation"), this.option("name"), "absolute");
                element.wrapInner("<div/>");
                setupTransitionInnerElement(element.children());
                if (this.option("type")) {
                    errors.log("W0003", "dxTransition", "type", "15.1", "Use the 'animation' property instead")
                }
            },
            _clean: function() {
                this.callBase();
                this.element().empty()
            }
        });
        var ContentPlaceholder = MarkupComponent.inherit({
            _setDefaultOptions: function() {
                this.callBase();
                this.option({
                    name: null,
                    transition: void 0,
                    animation: "none",
                    contentCssPosition: "absolute"
                })
            },
            _render: function() {
                this.callBase();
                var $element = this.element();
                $element.addClass("dx-content-placeholder").addClass("dx-content-placeholder-" + this.option("name"));
                $element.attr("data-dx-content-placeholder-name", this.option("name"));
                setupTransitionElement($element, this.option("transition") || this.option("animation"), this.option("name"), this.option("contentCssPosition"));
                if (this.option("transition")) {
                    errors.log("W0003", "dxContentPlaceholder", "transition", "15.1", "Use the 'animation' property instead")
                }
            }
        });
        var Content = MarkupComponent.inherit({
            _setDefaultOptions: function() {
                this.callBase();
                this.option({
                    targetPlaceholder: null
                })
            },
            _optionChanged: function() {
                this._refresh()
            },
            _clean: function() {
                this.callBase();
                this.element().removeClass(this._currentClass)
            },
            _render: function() {
                this.callBase();
                var element = this.element();
                element.addClass("dx-content");
                this._currentClass = "dx-content-" + this.option("targetPlaceholder");
                element.attr("data-dx-target-placeholder-id", this.option("targetPlaceholder"));
                element.addClass(this._currentClass);
                setupTransitionInnerElement(element)
            }
        });
        registerComponent("dxView", View);
        registerComponent("dxLayout", Layout);
        registerComponent("dxViewPlaceholder", ViewPlaceholder);
        registerComponent("dxContentPlaceholder", ContentPlaceholder);
        registerComponent("dxTransition", Transition);
        registerComponent("dxContent", Content);
        exports.dxView = View;
        exports.dxLayout = Layout;
        exports.dxViewPlaceholder = ViewPlaceholder;
        exports.dxContentPlaceholder = ContentPlaceholder;
        exports.dxTransition = Transition;
        exports.dxContent = Content
    },
    /*!****************************************************!*\
      !*** ./Scripts/framework/html/html_application.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Component = __webpack_require__( /*! ../../core/component */ 34),
            errors = __webpack_require__( /*! ../errors */ 122),
            Application = __webpack_require__( /*! ../application */ 130).Application,
            ConditionalViewCacheDecorator = __webpack_require__( /*! ../view_cache */ 125).ConditionalViewCacheDecorator,
            html = __webpack_require__( /*! ./presets */ 138),
            CommandManager = __webpack_require__( /*! ./command_manager */ 139),
            ViewEngine = __webpack_require__( /*! ./view_engine */ 141).ViewEngine,
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            viewPort = __webpack_require__( /*! ../../core/utils/view_port */ 42).value,
            initMobileViewportModule = __webpack_require__( /*! ../../mobile/init_mobile_viewport/init_mobile_viewport */ 47),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            feedbackEvents = __webpack_require__( /*! ../../events/core/emitter.feedback */ 103),
            TransitionExecutorModule = __webpack_require__( /*! ../../animation/transition_executor/transition_executor */ 63),
            animationPresetsModule = __webpack_require__( /*! ../../animation/presets/presets */ 58);
        __webpack_require__( /*! ./layout_controller */ 142);
        __webpack_require__( /*! ../../ui/themes */ 143);
        var VIEW_PORT_CLASSNAME = "dx-viewport",
            LAYOUT_CHANGE_ANIMATION_NAME = "layout-change";
        var HtmlApplication = Application.inherit({
            ctor: function(options) {
                options = options || {};
                this.callBase(options);
                this._$root = $(options.rootNode || document.body);
                this._initViewport(options.viewPort);
                if ("mobileApp" === this._applicationMode) {
                    initMobileViewportModule.initMobileViewport(options.viewPort)
                }
                this.device = options.device || devices.current();
                this.commandManager = options.commandManager || new CommandManager({
                    commandMapping: this.commandMapping
                });
                this._initTemplateContext();
                this.viewEngine = options.viewEngine || new ViewEngine({
                    $root: this._$root,
                    device: this.device,
                    templateCacheStorage: options.templateCacheStorage || window.localStorage,
                    templatesVersion: options.templatesVersion,
                    templateContext: this._templateContext
                });
                this.components.push(this.viewEngine);
                this._initMarkupFilters(this.viewEngine);
                this._layoutSet = options.layoutSet || html.layoutSets.default;
                this._animationSet = options.animationSet || html.animationSets.default;
                this._availableLayoutControllers = [];
                this._activeLayoutControllersStack = [];
                this.transitionExecutor = new TransitionExecutorModule.TransitionExecutor;
                this._initAnimations(this._animationSet)
            },
            _initAnimations: function(animationSet) {
                if (!animationSet) {
                    return
                }
                $.each(animationSet, function(name, configs) {
                    $.each(configs, function(index, config) {
                        animationPresetsModule.presets.registerPreset(name, config)
                    })
                });
                animationPresetsModule.presets.applyChanges()
            },
            _localizeMarkup: function($markup) {
                messageLocalization.localizeNode($markup)
            },
            _notifyIfBadMarkup: function($markup) {
                $markup.each(function() {
                    var html = $(this).html();
                    if (/href="#/.test(html)) {
                        errors.log("W3005", html)
                    }
                })
            },
            _initMarkupFilters: function(viewEngine) {
                var filters = [];
                filters.push(this._localizeMarkup);
                if ("mobileApp" === this._applicationMode) {
                    filters.push(this._notifyIfBadMarkup)
                }
                if (viewEngine.markupLoaded) {
                    viewEngine.markupLoaded.add(function(args) {
                        $.each(filters, function(_, filter) {
                            filter(args.markup)
                        })
                    })
                }
            },
            _createViewCache: function(options) {
                var result = this.callBase(options);
                if (!options.viewCache) {
                    result = new ConditionalViewCacheDecorator({
                        filter: function(key, viewInfo) {
                            return !viewInfo.viewTemplateInfo.disableCache
                        },
                        viewCache: result
                    })
                }
                return result
            },
            _initViewport: function() {
                this._$viewPort = this._getViewPort();
                viewPort(this._$viewPort)
            },
            _getViewPort: function() {
                var $viewPort = $("." + VIEW_PORT_CLASSNAME);
                if (!$viewPort.length) {
                    $viewPort = $("<div>").addClass(VIEW_PORT_CLASSNAME).appendTo(this._$root)
                }
                return $viewPort
            },
            _initTemplateContext: function() {
                this._templateContext = new Component({
                    orientation: devices.orientation()
                });
                devices.on("orientationChanged", $.proxy(function(args) {
                    this._templateContext.option("orientation", args.orientation)
                }, this))
            },
            _showViewImpl: function(viewInfo, direction) {
                var that = this,
                    deferred = $.Deferred(),
                    result = deferred.promise(),
                    layoutController = viewInfo.layoutController;
                that._obtainViewLink(viewInfo);
                layoutController.showView(viewInfo, direction).done(function() {
                    that._activateLayoutController(layoutController, that._getTargetNode(viewInfo), direction).done(function() {
                        deferred.resolve()
                    })
                });
                feedbackEvents.lock(result);
                return result
            },
            _resolveLayoutController: function(viewInfo) {
                var args = {
                    viewInfo: viewInfo,
                    layoutController: null,
                    availableLayoutControllers: this._availableLayoutControllers
                };
                this._processEvent("resolveLayoutController", args, viewInfo.model);
                this._checkLayoutControllerIsInitialized(args.layoutController);
                return args.layoutController || this._resolveLayoutControllerImpl(viewInfo)
            },
            _checkLayoutControllerIsInitialized: function(layoutController) {
                if (layoutController) {
                    var isControllerInited = false;
                    $.each(this._layoutSet, function(_, controllerInfo) {
                        if (controllerInfo.controller === layoutController) {
                            isControllerInited = true;
                            return false
                        }
                    });
                    if (!isControllerInited) {
                        throw errors.Error("E3024")
                    }
                }
            },
            _ensureOneLayoutControllerFound: function(target, matches) {
                var toJSONInterceptor = function(key, value) {
                    if ("controller" === key) {
                        return "[controller]: { name:" + value.name + " }"
                    }
                    return value
                };
                if (!matches.length) {
                    errors.log("W3003", JSON.stringify(target, null, 4), JSON.stringify(this._availableLayoutControllers, toJSONInterceptor, 4));
                    throw errors.Error("E3011")
                }
                if (matches.length > 1) {
                    errors.log("W3004", JSON.stringify(target, null, 4), JSON.stringify(matches, toJSONInterceptor, 4));
                    throw errors.Error("E3012")
                }
            },
            _resolveLayoutControllerImpl: function(viewInfo) {
                var templateInfo = viewInfo.viewTemplateInfo || {},
                    navigateOptions = viewInfo.navigateOptions || {},
                    target = $.extend({
                        root: !viewInfo.canBack,
                        customResolveRequired: false,
                        pane: templateInfo.pane,
                        modal: void 0 !== navigateOptions.modal ? navigateOptions.modal : templateInfo.modal || false
                    }, devices.current());
                var matches = commonUtils.findBestMatches(target, this._availableLayoutControllers);
                this._ensureOneLayoutControllerFound(target, matches);
                return matches[0].controller
            },
            _onNavigatingBack: function(args) {
                this.callBase.apply(this, arguments);
                if (!args.cancel && !this.canBack() && this._activeLayoutControllersStack.length > 1) {
                    var previousActiveLayoutController = this._activeLayoutControllersStack[this._activeLayoutControllersStack.length - 2],
                        previousViewInfo = previousActiveLayoutController.activeViewInfo();
                    args.cancel = true;
                    this._activateLayoutController(previousActiveLayoutController, void 0, "backward");
                    this.navigationManager.currentItem(previousViewInfo.key)
                }
            },
            _activeLayoutController: function() {
                return this._activeLayoutControllersStack.length ? this._activeLayoutControllersStack[this._activeLayoutControllersStack.length - 1] : void 0
            },
            _getTargetNode: function(viewInfo) {
                var jQueryEvent = (viewInfo.navigateOptions || {}).jQueryEvent;
                return jQueryEvent ? $(jQueryEvent.target) : void 0
            },
            _activateLayoutController: function(layoutController, targetNode, direction) {
                var that = this,
                    previousLayoutController = that._activeLayoutController();
                if (previousLayoutController === layoutController) {
                    return $.Deferred().resolve().promise()
                }
                return layoutController.ensureActive(targetNode).then($.proxy(this._deactivatePreviousLayoutControllers, this, layoutController, direction)).then(function() {
                    that._activeLayoutControllersStack.push(layoutController)
                })
            },
            _deactivatePreviousLayoutControllers: function(layoutController, direction) {
                var that = this,
                    tasks = [],
                    controllerToDeactivate = that._activeLayoutControllersStack.pop();
                if (!controllerToDeactivate) {
                    return $.Deferred().resolve().promise()
                }
                if (layoutController.isOverlay) {
                    that._activeLayoutControllersStack.push(controllerToDeactivate);
                    tasks.push(controllerToDeactivate.disable())
                } else {
                    var transitionDeferred = $.Deferred(),
                        skipAnimation = false;
                    var getControllerDeactivator = function(controllerToDeactivate, d) {
                        return function() {
                            controllerToDeactivate.deactivate().done(function() {
                                d.resolve()
                            })
                        }
                    };
                    while (controllerToDeactivate && controllerToDeactivate !== layoutController) {
                        var d = $.Deferred();
                        if (controllerToDeactivate.isOverlay) {
                            skipAnimation = true
                        } else {
                            that.transitionExecutor.leave(controllerToDeactivate.element(), LAYOUT_CHANGE_ANIMATION_NAME, {
                                direction: direction
                            })
                        }
                        transitionDeferred.promise().done(getControllerDeactivator(controllerToDeactivate, d));
                        tasks.push(d.promise());
                        controllerToDeactivate = that._activeLayoutControllersStack.pop()
                    }
                    if (skipAnimation) {
                        transitionDeferred.resolve()
                    } else {
                        that.transitionExecutor.enter(layoutController.element(), LAYOUT_CHANGE_ANIMATION_NAME, {
                            direction: direction
                        });
                        that.transitionExecutor.start().done(function() {
                            transitionDeferred.resolve()
                        })
                    }
                }
                return $.when.apply($, tasks)
            },
            init: function() {
                var that = this,
                    result = this.callBase();
                result.done(function() {
                    that._initLayoutControllers();
                    that.renderNavigation()
                });
                return result
            },
            _disposeView: function(viewInfo) {
                if (viewInfo.layoutController.disposeView) {
                    viewInfo.layoutController.disposeView(viewInfo)
                }
                this.callBase(viewInfo)
            },
            viewPort: function() {
                return this._$viewPort
            },
            _createViewInfo: function(navigationItem, navigateOptions) {
                var viewInfo = this.callBase.apply(this, arguments),
                    templateInfo = this.getViewTemplateInfo(viewInfo.viewName);
                if (!templateInfo) {
                    throw errors.Error("E3013", "dxView", viewInfo.viewName)
                }
                viewInfo.viewTemplateInfo = templateInfo;
                viewInfo.layoutController = this._resolveLayoutController(viewInfo);
                return viewInfo
            },
            _createViewModel: function(viewInfo) {
                this.callBase(viewInfo);
                objectUtils.extendFromObject(viewInfo.model, viewInfo.viewTemplateInfo)
            },
            _initLayoutControllers: function() {
                var that = this;
                $.each(that._layoutSet, function(index, controllerInfo) {
                    var controller = controllerInfo.controller,
                        target = devices.current();
                    if (commonUtils.findBestMatches(target, [controllerInfo]).length) {
                        that._availableLayoutControllers.push(controllerInfo);
                        if (controller.init) {
                            controller.init({
                                app: that,
                                $viewPort: that._$viewPort,
                                navigationManager: that.navigationManager,
                                viewEngine: that.viewEngine,
                                templateContext: that._templateContext,
                                commandManager: that.commandManager
                            })
                        }
                        if (controller.on) {
                            controller.on("viewReleased", function(viewInfo) {
                                that._onViewReleased(viewInfo)
                            });
                            controller.on("viewHidden", function(viewInfo) {
                                that._onViewHidden(viewInfo)
                            });
                            controller.on("viewRendered", function(viewInfo) {
                                that._processEvent("viewRendered", {
                                    viewInfo: viewInfo
                                }, viewInfo.model)
                            });
                            controller.on("viewShowing", function(viewInfo, direction) {
                                that._processEvent("viewShowing", {
                                    viewInfo: viewInfo,
                                    direction: direction,
                                    params: viewInfo.routeData
                                }, viewInfo.model)
                            });
                            controller.on("viewShown", function(viewInfo, direction) {
                                that._processEvent("viewShown", {
                                    viewInfo: viewInfo,
                                    direction: direction,
                                    params: viewInfo.routeData
                                }, viewInfo.model)
                            })
                        }
                    }
                })
            },
            _onViewReleased: function(viewInfo) {
                this._releaseViewLink(viewInfo)
            },
            renderNavigation: function() {
                var that = this;
                $.each(that._availableLayoutControllers, function(index, controllerInfo) {
                    var controller = controllerInfo.controller;
                    if (controller.renderNavigation) {
                        controller.renderNavigation(that.navigation)
                    }
                })
            },
            getViewTemplate: function(viewName) {
                return this.viewEngine.getViewTemplate(viewName)
            },
            getViewTemplateInfo: function(viewName) {
                var viewComponent = this.viewEngine.getViewTemplateInfo(viewName);
                return viewComponent && viewComponent.option()
            },
            loadTemplates: function(source) {
                return this.viewEngine.loadTemplates(source)
            },
            templateContext: function() {
                return this._templateContext
            }
        });
        module.exports = HtmlApplication
    },
    /*!******************************************!*\
      !*** ./Scripts/framework/application.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var BACK_COMMAND_TITLE, $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            abstract = Class.abstract,
            Action = __webpack_require__( /*! ../core/action */ 35),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            mergeCommands = __webpack_require__( /*! ./utils */ 131).utils.mergeCommands,
            createActionExecutors = __webpack_require__( /*! ./action_executors */ 132).createActionExecutors,
            Router = __webpack_require__( /*! ./router */ 123),
            NavigationManager = __webpack_require__( /*! ./navigation_manager */ 133),
            StateManager = __webpack_require__( /*! ./state_manager */ 124),
            dxCommand = __webpack_require__( /*! ./command */ 121),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            CommandMapping = __webpack_require__( /*! ./command_mapping */ 136),
            ViewCache = __webpack_require__( /*! ./view_cache */ 125),
            EventsMixin = __webpack_require__( /*! ../core/events_mixin */ 39),
            sessionStorage = __webpack_require__( /*! ../core/utils/storage */ 41).sessionStorage,
            dataUtils = __webpack_require__( /*! ../data/utils */ 137),
            errors = __webpack_require__( /*! ./errors */ 122),
            INIT_IN_PROGRESS = "InProgress",
            INIT_COMPLETE = "Inited";
        var Application = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this._options = options;
                this.namespace = options.namespace || window;
                this._applicationMode = options.mode ? options.mode : "mobileApp";
                this.components = [];
                BACK_COMMAND_TITLE = messageLocalization.localizeString("@Back");
                this.router = options.router || new Router;
                var navigationManagers = {
                    mobileApp: NavigationManager.StackBasedNavigationManager,
                    webSite: NavigationManager.HistoryBasedNavigationManager
                };
                this.navigationManager = options.navigationManager || new navigationManagers[this._applicationMode]({
                    keepPositionInStack: "keepHistory" === options.navigateToRootViewMode
                });
                this.navigationManager.on("navigating", $.proxy(this._onNavigating, this));
                this.navigationManager.on("navigatingBack", $.proxy(this._onNavigatingBack, this));
                this.navigationManager.on("navigated", $.proxy(this._onNavigated, this));
                this.navigationManager.on("navigationCanceled", $.proxy(this._onNavigationCanceled, this));
                this.stateManager = options.stateManager || new StateManager({
                    storage: options.stateStorage || sessionStorage()
                });
                this.stateManager.addStateSource(this.navigationManager);
                this.viewCache = this._createViewCache(options);
                this.commandMapping = this._createCommandMapping(options.commandMapping);
                this.createNavigation(options.navigation);
                this._isNavigating = false;
                this._viewLinksHash = {};
                Action.registerExecutor(createActionExecutors(this));
                this.components.push(this.router);
                this.components.push(this.navigationManager)
            },
            _createViewCache: function(options) {
                var result;
                if (options.viewCache) {
                    result = options.viewCache
                } else {
                    if (options.disableViewCache) {
                        result = new ViewCache.NullViewCache
                    } else {
                        result = new ViewCache.CapacityViewCacheDecorator({
                            size: options.viewCacheSize,
                            viewCache: new ViewCache
                        })
                    }
                }
                result.on("viewRemoved", $.proxy(function(e) {
                    this._releaseViewLink(e.viewInfo)
                }, this));
                return result
            },
            _createCommandMapping: function(commandMapping) {
                var result = commandMapping;
                if (!(commandMapping instanceof CommandMapping)) {
                    result = new CommandMapping;
                    result.load(CommandMapping.defaultMapping || {}).load(commandMapping || {})
                }
                return result
            },
            createNavigation: function(navigationConfig) {
                this.navigation = this._createNavigationCommands(navigationConfig);
                this._mapNavigationCommands(this.navigation, this.commandMapping)
            },
            _createNavigationCommands: function(commandConfig) {
                if (!commandConfig) {
                    return []
                }
                var generatedIdCount = 0;
                return $.map(commandConfig, function(item) {
                    var command;
                    if (item instanceof dxCommand) {
                        command = item
                    } else {
                        command = new dxCommand($.extend({
                            root: true
                        }, item))
                    }
                    if (!command.option("id")) {
                        command.option("id", "navigation_" + generatedIdCount++)
                    }
                    return command
                })
            },
            _mapNavigationCommands: function(navigationCommands, commandMapping) {
                var navigationCommandIds = $.map(navigationCommands, function(command) {
                    return command.option("id")
                });
                commandMapping.mapCommands("global-navigation", navigationCommandIds)
            },
            _callComponentMethod: function(methodName, args) {
                var tasks = [];
                $.each(this.components, function(index, component) {
                    if (component[methodName] && $.isFunction(component[methodName])) {
                        var result = component[methodName](args);
                        if (result && result.done) {
                            tasks.push(result)
                        }
                    }
                });
                return $.when.apply($, tasks)
            },
            init: function() {
                var that = this;
                that._initState = INIT_IN_PROGRESS;
                return that._callComponentMethod("init").done(function() {
                    that._initState = INIT_COMPLETE;
                    that._processEvent("initialized")
                }).fail(function(error) {
                    throw error || errors.Error("E3022")
                })
            },
            _onNavigatingBack: function(args) {
                this._processEvent("navigatingBack", args)
            },
            _onNavigating: function(args) {
                var that = this;
                if (that._isNavigating) {
                    that._pendingNavigationArgs = args;
                    args.cancel = true;
                    return
                } else {
                    that._isNavigating = true;
                    delete that._pendingNavigationArgs
                }
                var routeData = this.router.parse(args.uri);
                if (!routeData) {
                    throw errors.Error("E3001", args.uri)
                }
                var uri = this.router.format(routeData);
                if (args.uri !== uri && uri) {
                    args.cancel = true;
                    args.cancelReason = "redirect";
                    commonUtils.executeAsync(function() {
                        that.navigate(uri, args.options)
                    })
                } else {
                    that._processEvent("navigating", args)
                }
            },
            _onNavigated: function(args) {
                var resultDeferred, that = this,
                    direction = args.options.direction,
                    viewInfo = that._acquireViewInfo(args.item, args.options);
                if (!viewInfo.model) {
                    this._processEvent("beforeViewSetup", {
                        viewInfo: viewInfo
                    });
                    that._createViewModel(viewInfo);
                    that._createViewCommands(viewInfo);
                    this._processEvent("afterViewSetup", {
                        viewInfo: viewInfo
                    })
                }
                that._highlightCurrentNavigationCommand(viewInfo);
                resultDeferred = that._showView(viewInfo, direction).always(function() {
                    that._isNavigating = false;
                    var pendingArgs = that._pendingNavigationArgs;
                    if (pendingArgs) {
                        commonUtils.executeAsync(function() {
                            that.navigate(pendingArgs.uri, pendingArgs.options)
                        })
                    }
                });
                return resultDeferred
            },
            _isViewReadyToShow: function(viewInfo) {
                return !!viewInfo.model
            },
            _onNavigationCanceled: function(args) {
                var that = this;
                if (!that._pendingNavigationArgs || that._pendingNavigationArgs.uri !== args.uri) {
                    var currentItem = that.navigationManager.currentItem();
                    if (currentItem) {
                        commonUtils.executeAsync(function() {
                            var viewInfo = that._acquireViewInfo(currentItem, args.options);
                            that._highlightCurrentNavigationCommand(viewInfo, true)
                        })
                    }
                    that._isNavigating = false
                }
            },
            _disposeRemovedViews: function() {
                var args, that = this;
                $.each(that._viewLinksHash, function(key, link) {
                    if (!link.linkCount) {
                        args = {
                            viewInfo: link.viewInfo
                        };
                        that._processEvent("viewDisposing", args, args.viewInfo.model);
                        that._disposeView(link.viewInfo);
                        that._processEvent("viewDisposed", args, args.viewInfo.model);
                        delete that._viewLinksHash[key]
                    }
                })
            },
            _onViewHidden: function(viewInfo) {
                var args = {
                    viewInfo: viewInfo
                };
                this._processEvent("viewHidden", args, args.viewInfo.model)
            },
            _disposeView: function(viewInfo) {
                var commands = viewInfo.commands || [];
                $.each(commands, function(index, command) {
                    command._dispose()
                })
            },
            _acquireViewInfo: function(navigationItem, navigateOptions) {
                var routeData = this.router.parse(navigationItem.uri),
                    viewInfoKey = this._getViewInfoKey(navigationItem, routeData),
                    viewInfo = this.viewCache.getView(viewInfoKey);
                if (!viewInfo) {
                    viewInfo = this._createViewInfo(navigationItem, navigateOptions);
                    this._obtainViewLink(viewInfo);
                    this.viewCache.setView(viewInfoKey, viewInfo)
                } else {
                    this._updateViewInfo(viewInfo, navigationItem, navigateOptions)
                }
                return viewInfo
            },
            _getViewInfoKey: function(navigationItem, routeData) {
                var args = {
                    key: navigationItem.key,
                    navigationItem: navigationItem,
                    routeData: routeData
                };
                this._processEvent("resolveViewCacheKey", args);
                return args.key
            },
            _processEvent: function(eventName, args, model) {
                this._callComponentMethod(eventName, args);
                this.fireEvent(eventName, args && [args]);
                var modelMethod = (model || {})[eventName];
                if (modelMethod) {
                    modelMethod.call(model, args)
                }
            },
            _updateViewInfo: function(viewInfo, navigationItem, navigateOptions) {
                var uri = navigationItem.uri,
                    routeData = this.router.parse(uri);
                viewInfo.viewName = routeData.view;
                viewInfo.routeData = routeData;
                viewInfo.uri = uri;
                viewInfo.navigateOptions = navigateOptions;
                viewInfo.canBack = this.canBack(navigateOptions.stack);
                viewInfo.previousViewInfo = this._getPreviousViewInfo(navigateOptions)
            },
            _createViewInfo: function(navigationItem, navigateOptions) {
                var uri = navigationItem.uri,
                    routeData = this.router.parse(uri),
                    viewInfo = {
                        key: this._getViewInfoKey(navigationItem, routeData)
                    };
                this._updateViewInfo(viewInfo, navigationItem, navigateOptions);
                return viewInfo
            },
            _createViewModel: function(viewInfo) {
                viewInfo.model = viewInfo.model || this._callViewCodeBehind(viewInfo)
            },
            _createViewCommands: function(viewInfo) {
                viewInfo.commands = viewInfo.model.commands || [];
                if (viewInfo.canBack && "webSite" !== this._applicationMode) {
                    this._appendBackCommand(viewInfo)
                }
            },
            _callViewCodeBehind: function(viewInfo) {
                var setupFunc = $.noop,
                    routeData = viewInfo.routeData;
                if (routeData.view in this.namespace) {
                    setupFunc = this.namespace[routeData.view]
                }
                return setupFunc.call(this.namespace, routeData, viewInfo) || {}
            },
            _appendBackCommand: function(viewInfo) {
                var commands = viewInfo.commands,
                    that = this,
                    backTitle = BACK_COMMAND_TITLE;
                if (that._options.useViewTitleAsBackText) {
                    backTitle = ((viewInfo.previousViewInfo || {}).model || {}).title || backTitle
                }
                var toMergeTo = [new dxCommand({
                    id: "back",
                    title: backTitle,
                    behavior: "back",
                    onExecute: function() {
                        that.back({
                            stack: viewInfo.navigateOptions.stack
                        })
                    },
                    icon: "arrowleft",
                    type: "back",
                    renderStage: that._options.useViewTitleAsBackText ? "onViewRendering" : "onViewShown"
                })];
                var result = mergeCommands(toMergeTo, commands);
                commands.length = 0;
                commands.push.apply(commands, result)
            },
            _showView: function(viewInfo, direction) {
                var that = this;
                var eventArgs = {
                    viewInfo: viewInfo,
                    direction: direction,
                    params: viewInfo.routeData
                };
                dataUtils.processRequestResultLock.obtain();
                return that._showViewImpl(eventArgs.viewInfo, eventArgs.direction).done(function() {
                    commonUtils.executeAsync(function() {
                        dataUtils.processRequestResultLock.release();
                        that._processEvent("viewShown", eventArgs, viewInfo.model);
                        that._disposeRemovedViews()
                    })
                })
            },
            _highlightCurrentNavigationCommand: function(viewInfo, forceUpdate) {
                var selectedCommand, that = this,
                    currentNavigationItemId = viewInfo.model && viewInfo.model.currentNavigationItemId;
                if (void 0 !== currentNavigationItemId) {
                    $.each(this.navigation, function(index, command) {
                        if (command.option("id") === currentNavigationItemId) {
                            selectedCommand = command;
                            return false
                        }
                    })
                }
                if (!selectedCommand) {
                    $.each(this.navigation, function(index, command) {
                        var commandUri = command.option("onExecute");
                        if (commonUtils.isString(commandUri)) {
                            commandUri = commandUri.replace(/^#+/, "");
                            if (commandUri === that.navigationManager.rootUri()) {
                                selectedCommand = command;
                                return false
                            }
                        }
                    })
                }
                $.each(this.navigation, function(index, command) {
                    if (forceUpdate && command === selectedCommand && command.option("highlighted")) {
                        command.fireEvent("optionChanged", [{
                            name: "highlighted",
                            value: true,
                            previousValue: true
                        }])
                    }
                    command.option("highlighted", command === selectedCommand)
                })
            },
            _showViewImpl: abstract,
            _obtainViewLink: function(viewInfo) {
                var key = viewInfo.key;
                if (!this._viewLinksHash[key]) {
                    this._viewLinksHash[key] = {
                        viewInfo: viewInfo,
                        linkCount: 1
                    }
                } else {
                    this._viewLinksHash[key].linkCount++
                }
            },
            _releaseViewLink: function(viewInfo) {
                if (void 0 === this._viewLinksHash[viewInfo.key]) {
                    errors.log("W3001", viewInfo.key)
                }
                if (0 === this._viewLinksHash[viewInfo.key].linkCount) {
                    errors.log("W3002", viewInfo.key)
                }
                this._viewLinksHash[viewInfo.key].linkCount--
            },
            navigate: function(uri, options) {
                var that = this;
                if ($.isPlainObject(uri)) {
                    uri = that.router.format(uri);
                    if (false === uri) {
                        throw errors.Error("E3002")
                    }
                }
                if (!that._initState) {
                    that.init().done(function() {
                        that.restoreState();
                        that.navigate(uri, options)
                    })
                } else {
                    if (that._initState === INIT_COMPLETE) {
                        if (!that._isNavigating || uri) {
                            that.navigationManager.navigate(uri, options)
                        }
                    } else {
                        throw errors.Error("E3003")
                    }
                }
            },
            canBack: function(stackKey) {
                return this.navigationManager.canBack(stackKey)
            },
            _getPreviousViewInfo: function(navigateOptions) {
                var result, previousNavigationItem = this.navigationManager.previousItem(navigateOptions.stack);
                if (previousNavigationItem) {
                    var routeData = this.router.parse(previousNavigationItem.uri);
                    result = this.viewCache.getView(this._getViewInfoKey(previousNavigationItem, routeData))
                }
                return result
            },
            back: function(options) {
                this.navigationManager.back(options)
            },
            saveState: function() {
                this.stateManager.saveState()
            },
            restoreState: function() {
                this.stateManager.restoreState()
            },
            clearState: function() {
                this.stateManager.clearState()
            }
        }).include(EventsMixin);
        exports.Application = Application
    },
    /*!************************************!*\
      !*** ./Scripts/framework/utils.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            KoTemplateProvider = __webpack_require__( /*! ../integration/knockout/template_provider */ 104);
        var mergeWithReplace = function(targetArray, arrayToMerge, needReplaceFn) {
            var result = [];
            for (var i = 0, length = targetArray.length; i < length; i++) {
                if (!needReplaceFn(targetArray[i], arrayToMerge)) {
                    result.push(targetArray[i])
                }
            }
            result.push.apply(result, arrayToMerge);
            return result
        };
        var prepareCommandToReplace = function(targetCommand, commandsToMerge) {
            var needToReplace = false;
            $.each(commandsToMerge, function(_, commandToMerge) {
                var idEqual = targetCommand.option("id") === commandToMerge.option("id") && commandToMerge.option("id"),
                    behaviorEqual = targetCommand.option("behavior") === commandToMerge.option("behavior") && targetCommand.option("behavior");
                needToReplace = idEqual || behaviorEqual;
                if (behaviorEqual && null === commandToMerge.option("onExecute")) {
                    commandToMerge.option("onExecute", targetCommand.option("onExecute"))
                }
                if (needToReplace) {
                    targetCommand.element().remove();
                    return false
                }
            });
            return needToReplace
        };
        var mergeCommands = function(targetCommands, commandsToMerge) {
            return mergeWithReplace(targetCommands, commandsToMerge, prepareCommandToReplace)
        };
        var resolvePropertyValue = function(command, containerOptions, propertyName, defaultValue) {
            var containerOption = containerOptions ? containerOptions[propertyName] : void 0,
                defaultOption = void 0 === containerOption ? defaultValue : containerOption,
                commandOption = command.option(propertyName);
            return void 0 === commandOption || commandOption === defaultValue ? defaultOption : commandOption
        };
        var resolveTextValue = function(command, containerOptions) {
            var showText = resolvePropertyValue(command, containerOptions, "showText"),
                hasIcon = !!command.option("icon"),
                titleValue = resolvePropertyValue(command, containerOptions, "title", "");
            return showText || !hasIcon ? titleValue : ""
        };
        var resolveIconValue = function(command, containerOptions) {
            var showIcon = resolvePropertyValue(command, containerOptions, "showIcon"),
                hasText = !!command.option("title"),
                iconValue = resolvePropertyValue(command, containerOptions, "icon", "");
            return showIcon || !hasText ? iconValue : ""
        };
        exports.utils = {
            mergeCommands: mergeCommands,
            commandToContainer: {
                resolveIconValue: resolveIconValue,
                resolveTextValue: resolveTextValue,
                resolvePropertyValue: resolvePropertyValue
            }
        };
        exports.templateProvider = KoTemplateProvider
    },
    /*!***********************************************!*\
      !*** ./Scripts/framework/action_executors.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dataCoreUtils = __webpack_require__( /*! ../core/utils/data */ 36),
            Route = __webpack_require__( /*! ./router */ 123).Route;

        function prepareNavigateOptions(options, actionArguments) {
            if (actionArguments.args) {
                var sourceEventArguments = actionArguments.args[0];
                options.jQueryEvent = sourceEventArguments.jQueryEvent
            }
            if ("dxCommand" === (actionArguments.component || {}).NAME) {
                $.extend(options, actionArguments.component.option())
            }
        }

        function preventDefaultLinkBehaviour(e) {
            if (!e) {
                return
            }
            var $targetElement = $(e.target);
            if ($targetElement.attr("href")) {
                e.preventDefault()
            }
        }
        var createActionExecutors = function(app) {
            return {
                routing: {
                    execute: function(e) {
                        var routeValues, uri, action = e.action,
                            options = {};
                        if ($.isPlainObject(action)) {
                            routeValues = action.routeValues;
                            if (routeValues && $.isPlainObject(routeValues)) {
                                options = action.options
                            } else {
                                routeValues = action
                            }
                            uri = app.router.format(routeValues);
                            prepareNavigateOptions(options, e);
                            preventDefaultLinkBehaviour(options.jQueryEvent);
                            app.navigate(uri, options);
                            e.handled = true
                        }
                    }
                },
                hash: {
                    execute: function(e) {
                        if ("string" !== typeof e.action || "#" !== e.action.charAt(0)) {
                            return
                        }
                        var uriTemplate = e.action.substr(1),
                            args = e.args[0],
                            uri = uriTemplate;
                        var defaultEvaluate = function(expr) {
                            var getter = dataCoreUtils.compileGetter(expr),
                                model = e.args[0].model;
                            return getter(model)
                        };
                        var evaluate = args.evaluate || defaultEvaluate;
                        uri = uriTemplate.replace(/\{([^}]+)\}/g, function(entry, expr) {
                            expr = $.trim(expr);
                            if (expr.indexOf(",") > -1) {
                                expr = $.map(expr.split(","), $.trim)
                            }
                            var value = evaluate(expr);
                            if (void 0 === value) {
                                value = ""
                            }
                            value = Route.prototype.formatSegment(value);
                            return value
                        });
                        var options = {};
                        prepareNavigateOptions(options, e);
                        preventDefaultLinkBehaviour(options.jQueryEvent);
                        app.navigate(uri, options);
                        e.handled = true
                    }
                },
                url: {
                    execute: function(e) {
                        if ("string" === typeof e.action && "#" !== e.action.charAt(0)) {
                            document.location = e.action
                        }
                    }
                }
            }
        };
        exports.createActionExecutors = createActionExecutors
    },
    /*!*************************************************!*\
      !*** ./Scripts/framework/navigation_manager.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            navigationDevices = __webpack_require__( /*! ./navigation_devices */ 134),
            EventsMixin = __webpack_require__( /*! ../core/events_mixin */ 39),
            errors = __webpack_require__( /*! ./errors */ 122),
            hardwareBackButton = __webpack_require__( /*! ../mobile/process_hardware_back_button */ 53).processCallback,
            hideTopOverlay = __webpack_require__( /*! ../mobile/hide_top_overlay */ 54);
        var NAVIGATION_TARGETS = {
                current: "current",
                blank: "blank",
                back: "back"
            },
            STORAGE_HISTORY_KEY = "__history";
        var HistoryBasedNavigationManager = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this._currentItem = void 0;
                this._previousItem = void 0;
                this._createNavigationDevice(options)
            },
            _createNavigationDevice: function(options) {
                this._navigationDevice = options.navigationDevice || new navigationDevices.HistoryBasedNavigationDevice;
                this._navigationDevice.uriChanged.add($.proxy(this._uriChangedHandler, this))
            },
            _uriChangedHandler: function(uri) {
                while (hideTopOverlay()) {}
                this.navigate(uri)
            },
            _syncUriWithCurrentNavigationItem: function() {
                var currentUri = this._currentItem && this._currentItem.uri;
                this._navigationDevice.setUri(currentUri, true)
            },
            _cancelNavigation: function(args) {
                this._syncUriWithCurrentNavigationItem();
                this.fireEvent("navigationCanceled", [args])
            },
            _getDefaultOptions: function() {
                return {
                    direction: "none",
                    target: NAVIGATION_TARGETS.blank
                }
            },
            _updateHistory: function(uri, options) {
                this._previousItem = this._currentItem;
                this._currentItem = {
                    uri: uri,
                    key: uri
                };
                this._navigationDevice.setUri(uri, options.target === NAVIGATION_TARGETS.current)
            },
            _setCurrentItem: function(item) {
                this._currentItem = item
            },
            navigate: function(uri, options) {
                options = options || {};
                var args, that = this,
                    isFirstNavigate = !that._currentItem,
                    currentItem = that._currentItem || {},
                    targetItem = options.item || {},
                    currentUri = currentItem.uri,
                    currentKey = currentItem.key,
                    targetKey = targetItem.key;
                if (void 0 === uri) {
                    uri = that._navigationDevice.getUri()
                }
                if (/^_back$/.test(uri)) {
                    that.back();
                    return
                }
                options = $.extend(that._getDefaultOptions(), options || {});
                if (isFirstNavigate) {
                    options.target = NAVIGATION_TARGETS.current
                }
                args = {
                    currentUri: currentUri,
                    uri: uri,
                    cancel: false,
                    navigateWhen: [],
                    options: options
                };
                that.fireEvent("navigating", [args]);
                uri = args.uri;
                if (args.cancel || currentUri === uri && (void 0 === targetKey || targetKey === currentKey) && !that._forceNavigate) {
                    that._cancelNavigation(args)
                } else {
                    that._forceNavigate = false;
                    $.when.apply($, args.navigateWhen).done(function() {
                        commonUtils.executeAsync(function() {
                            that._updateHistory(uri, options);
                            that.fireEvent("navigated", [{
                                uri: uri,
                                previousUri: currentUri,
                                options: options,
                                item: that._currentItem
                            }])
                        })
                    })
                }
            },
            back: function() {
                return this._navigationDevice.back()
            },
            previousItem: function() {
                return this._previousItem
            },
            currentItem: function(item) {
                if (arguments.length > 0) {
                    if (!item) {
                        throw errors.Error("E3023")
                    }
                    this._setCurrentItem(item)
                } else {
                    return this._currentItem
                }
            },
            rootUri: function() {
                return this._currentItem && this._currentItem.uri
            },
            canBack: function() {
                return true
            },
            saveState: $.noop,
            restoreState: $.noop,
            removeState: $.noop
        }).include(EventsMixin);
        var StackBasedNavigationManager = HistoryBasedNavigationManager.inherit({
            ctor: function(options) {
                options = options || {};
                this.callBase(options);
                this._createNavigationStacks(options);
                hardwareBackButton.add($.proxy(this._deviceBackInitiated, this));
                this._stateStorageKey = options.stateStorageKey || STORAGE_HISTORY_KEY
            },
            init: function() {
                return this._navigationDevice.init()
            },
            _createNavigationDevice: function(options) {
                if (!options.navigationDevice) {
                    options.navigationDevice = new navigationDevices.StackBasedNavigationDevice
                }
                this.callBase(options);
                this._navigationDevice.backInitiated.add($.proxy(this._deviceBackInitiated, this))
            },
            _uriChangedHandler: function(uri) {
                this.navigate(uri)
            },
            _createNavigationStacks: function(options) {
                this.navigationStacks = {};
                this._keepPositionInStack = options.keepPositionInStack;
                this.currentStack = new NavigationStack
            },
            _deviceBackInitiated: function() {
                if (!hideTopOverlay()) {
                    this.back({
                        isHardwareButton: true
                    })
                } else {
                    this._syncUriWithCurrentNavigationItem()
                }
            },
            _getDefaultOptions: function() {
                return {
                    target: NAVIGATION_TARGETS.blank
                }
            },
            _createNavigationStack: function() {
                var result = new NavigationStack;
                result.itemsRemoved.add($.proxy(this._removeItems, this));
                return result
            },
            _setCurrentItem: function(item) {
                this._setCurrentStack(item.stack);
                this.currentStack.currentItem(item);
                this.callBase(item);
                this._syncUriWithCurrentNavigationItem()
            },
            _setCurrentStack: function(stackOrStackKey) {
                var stack, stackKey;
                if ("string" === typeof stackOrStackKey) {
                    stackKey = stackOrStackKey;
                    if (!(stackKey in this.navigationStacks)) {
                        this.navigationStacks[stackKey] = this._createNavigationStack()
                    }
                    stack = this.navigationStacks[stackKey]
                } else {
                    stack = stackOrStackKey;
                    stackKey = $.map(this.navigationStacks, function(stack, key) {
                        if (stack === stackOrStackKey) {
                            return key
                        }
                        return null
                    })[0]
                }
                this.currentStack = stack;
                this.currentStackKey = stackKey
            },
            _getViewTargetStackKey: function(uri, isRoot) {
                var result;
                if (isRoot) {
                    if (void 0 !== this.navigationStacks[uri]) {
                        result = uri
                    } else {
                        for (var stackKey in this.navigationStacks) {
                            if (this.navigationStacks[stackKey].items[0].uri === uri) {
                                result = stackKey;
                                break
                            }
                        }
                        result = result || uri
                    }
                } else {
                    result = this.currentStackKey || uri
                }
                return result
            },
            _updateHistory: function(uri, options) {
                var isRoot = options.root,
                    forceIsRoot = isRoot,
                    forceToRoot = false,
                    previousStack = this.currentStack,
                    keepPositionInStack = void 0 !== options.keepPositionInStack ? options.keepPositionInStack : this._keepPositionInStack;
                options.stack = options.stack || this._getViewTargetStackKey(uri, isRoot);
                this._setCurrentStack(options.stack);
                if (isRoot || !this.currentStack.items.length) {
                    forceToRoot = this.currentStack === previousStack;
                    forceIsRoot = true
                }
                if (isRoot && this.currentStack.items.length) {
                    if (!keepPositionInStack || forceToRoot) {
                        this.currentStack.currentIndex = 0;
                        if (this.currentItem().uri !== uri) {
                            this.currentStack.navigate(uri, true)
                        }
                    }
                    options.direction = options.direction || "none"
                } else {
                    var prevIndex = this.currentStack.currentIndex,
                        prevItem = this.currentItem() || {};
                    switch (options.target) {
                        case NAVIGATION_TARGETS.blank:
                            this.currentStack.navigate(uri);
                            break;
                        case NAVIGATION_TARGETS.current:
                            this.currentStack.navigate(uri, true);
                            break;
                        case NAVIGATION_TARGETS.back:
                            if (this.currentStack.currentIndex > 0) {
                                this.currentStack.back(uri)
                            } else {
                                this.currentStack.navigate(uri, true)
                            }
                            break;
                        default:
                            throw errors.Error("E3006", options.target)
                    }
                    if (void 0 === options.direction) {
                        var indexDelta = this.currentStack.currentIndex - prevIndex;
                        if (indexDelta < 0) {
                            options.direction = this.currentStack.currentItem().backDirection || "backward"
                        } else {
                            if (indexDelta > 0 && this.currentStack.currentIndex > 0) {
                                options.direction = "forward"
                            } else {
                                options.direction = "none"
                            }
                        }
                    }
                    prevItem.backDirection = "forward" === options.direction ? "backward" : "none"
                }
                options.root = forceIsRoot;
                this._currentItem = this.currentStack.currentItem();
                this._syncUriWithCurrentNavigationItem()
            },
            _removeItems: function(items) {
                var that = this;
                $.each(items, function(index, item) {
                    that.fireEvent("itemRemoved", [item])
                })
            },
            back: function(options) {
                options = options || {};
                var navigatingBackArgs = $.extend({
                    cancel: false
                }, options);
                this.fireEvent("navigatingBack", [navigatingBackArgs]);
                if (navigatingBackArgs.cancel) {
                    this._syncUriWithCurrentNavigationItem();
                    return
                }
                var item = this.previousItem(navigatingBackArgs.stack);
                if (item) {
                    this.navigate(item.uri, {
                        stack: navigatingBackArgs.stack,
                        target: NAVIGATION_TARGETS.back,
                        item: item
                    })
                } else {
                    this.callBase()
                }
            },
            rootUri: function() {
                return this.currentStack.items.length ? this.currentStack.items[0].uri : this.callBase()
            },
            canBack: function(stackKey) {
                var stack = stackKey ? this.navigationStacks[stackKey] : this.currentStack;
                return stack.canBack()
            },
            saveState: function(storage) {
                if (this.currentStack.items.length) {
                    var state = {
                        navigationStacks: {},
                        currentStackKey: this.currentStackKey
                    };
                    $.each(this.navigationStacks, function(stackKey, stack) {
                        var stackState = {};
                        state.navigationStacks[stackKey] = stackState;
                        stackState.currentIndex = stack.currentIndex;
                        stackState.items = $.map(stack.items, function(item) {
                            return {
                                key: item.key,
                                uri: item.uri
                            }
                        })
                    });
                    var json = JSON.stringify(state);
                    storage.setItem(this._stateStorageKey, json)
                } else {
                    this.removeState(storage)
                }
            },
            restoreState: function(storage) {
                if (this.disableRestoreState) {
                    return
                }
                var json = storage.getItem(this._stateStorageKey);
                if (json) {
                    try {
                        var that = this,
                            state = JSON.parse(json);
                        $.each(state.navigationStacks, function(stackKey, stackState) {
                            var stack = that._createNavigationStack();
                            that.navigationStacks[stackKey] = stack;
                            stack.currentIndex = stackState.currentIndex;
                            stack.items = $.map(stackState.items, function(item) {
                                item.stack = stack;
                                return item
                            })
                        });
                        this.currentStackKey = state.currentStackKey;
                        this.currentStack = this.navigationStacks[this.currentStackKey];
                        this._currentItem = this.currentStack.currentItem();
                        this._navigationDevice.setUri(this.currentItem().uri);
                        this._forceNavigate = true
                    } catch (e) {
                        this.removeState(storage);
                        throw errors.Error("E3007")
                    }
                }
            },
            removeState: function(storage) {
                storage.removeItem(this._stateStorageKey)
            },
            currentIndex: function() {
                return this.currentStack.currentIndex
            },
            previousItem: function(stackKey) {
                var stack = this.navigationStacks[stackKey] || this.currentStack;
                return stack.previousItem()
            },
            getItemByIndex: function(index) {
                return this.currentStack.items[index]
            },
            clearHistory: function() {
                this._createNavigationStacks({
                    keepPositionInStack: this._keepPositionInStack
                })
            },
            itemByKey: function(itemKey) {
                var result;
                $.each(this.navigationStacks, function(stackKey, stack) {
                    var item = stack.itemByKey(itemKey);
                    if (item) {
                        result = item;
                        return false
                    }
                });
                return result
            },
            currentItem: function(itemOrItemKey) {
                var item;
                if (arguments.length > 0) {
                    if ("string" === typeof itemOrItemKey) {
                        item = this.itemByKey(itemOrItemKey)
                    } else {
                        if ($.isPlainObject(itemOrItemKey)) {
                            item = itemOrItemKey
                        }
                    }
                    this.callBase(item)
                } else {
                    return this.callBase()
                }
            }
        });
        var NavigationStack = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this.itemsRemoved = $.Callbacks();
                this.clear()
            },
            currentItem: function(item) {
                if (item) {
                    for (var i = 0; i < this.items.length; i++) {
                        if (item === this.items[i]) {
                            this.currentIndex = i;
                            break
                        }
                    }
                } else {
                    return this.items[this.currentIndex]
                }
            },
            previousItem: function() {
                return this.items.length > 1 ? this.items[this.currentIndex - 1] : void 0
            },
            canBack: function() {
                return this.currentIndex > 0
            },
            clear: function() {
                this._deleteItems(this.items);
                this.items = [];
                this.currentIndex = -1
            },
            back: function(uri) {
                this.currentIndex--;
                if (this.currentIndex < 0) {
                    throw errors.Error("E3008")
                }
                var currentItem = this.currentItem();
                if (currentItem.uri !== uri) {
                    this._updateItem(this.currentIndex, uri)
                }
            },
            forward: function() {
                this.currentIndex++;
                if (this.currentIndex >= this.items.length) {
                    throw errors.Error("E3009")
                }
            },
            navigate: function(uri, replaceCurrent) {
                if (this.currentIndex < this.items.length && this.currentIndex > -1 && this.items[this.currentIndex].uri === uri) {
                    return
                }
                if (replaceCurrent && this.currentIndex > -1) {
                    this.currentIndex--
                }
                if (this.currentIndex + 1 < this.items.length && this.items[this.currentIndex + 1].uri === uri) {
                    this.currentIndex++
                } else {
                    var toDelete = this.items.splice(this.currentIndex + 1, this.items.length - this.currentIndex - 1);
                    this.items.push({
                        stack: this
                    });
                    this.currentIndex++;
                    this._updateItem(this.currentIndex, uri);
                    this._deleteItems(toDelete)
                }
                return this.currentItem()
            },
            itemByKey: function(key) {
                for (var i = 0; i < this.items.length; i++) {
                    var item = this.items[i];
                    if (item.key === key) {
                        return item
                    }
                }
            },
            _updateItem: function(index, uri) {
                var item = this.items[index];
                item.uri = uri;
                item.key = this.items[0].uri + "_" + index + "_" + uri
            },
            _deleteItems: function(items) {
                if (items) {
                    this.itemsRemoved.fire(items)
                }
            }
        });
        HistoryBasedNavigationManager.NAVIGATION_TARGETS = NAVIGATION_TARGETS;
        exports.HistoryBasedNavigationManager = HistoryBasedNavigationManager;
        exports.StackBasedNavigationManager = StackBasedNavigationManager;
        exports.NavigationStack = NavigationStack
    },
    /*!*************************************************!*\
      !*** ./Scripts/framework/navigation_devices.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            browserAdapters = __webpack_require__( /*! ./browser_adapters */ 135),
            SessionStorage = __webpack_require__( /*! ../core/utils/storage */ 41).sessionStorage,
            devices = __webpack_require__( /*! ../core/devices */ 40);
        var SESSION_KEY = "dxPhoneJSApplication";
        var HistoryBasedNavigationDevice = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this._browserAdapter = options.browserAdapter || this._createBrowserAdapter(options);
                this.uriChanged = $.Callbacks();
                this._browserAdapter.popState.add($.proxy(this._onPopState, this))
            },
            init: $.noop,
            getUri: function() {
                return this._browserAdapter.getHash()
            },
            setUri: function(uri, replaceCurrent) {
                if (replaceCurrent) {
                    return this._browserAdapter.replaceState(uri)
                } else {
                    if (uri !== this.getUri()) {
                        return this._browserAdapter.pushState(uri)
                    } else {
                        return $.Deferred().resolve().promise()
                    }
                }
            },
            back: function() {
                return this._browserAdapter.back()
            },
            _onPopState: function() {
                this.uriChanged.fire(this.getUri())
            },
            _isBuggyAndroid2: function() {
                var realDevice = devices.real();
                var version = realDevice.version;
                return "android" === realDevice.platform && version.length > 1 && (2 === version[0] && version[1] < 4 || version[0] < 2)
            },
            _isBuggyAndroid4: function() {
                var realDevice = devices.real();
                var version = realDevice.version;
                return "android" === realDevice.platform && version.length > 1 && 4 === version[0] && 0 === version[1]
            },
            _isWindowsPhone8: function() {
                var realDevice = devices.real();
                return "win" === realDevice.platform && realDevice.phone
            },
            _createBrowserAdapter: function(options) {
                var result, sourceWindow = options.window || window,
                    supportPushReplace = sourceWindow.history.replaceState && sourceWindow.history.pushState;
                if (this._isWindowsPhone8()) {
                    result = new browserAdapters.BuggyCordovaWP81BrowserAdapter(options)
                } else {
                    if (sourceWindow !== sourceWindow.top) {
                        result = new browserAdapters.HistorylessBrowserAdapter(options)
                    } else {
                        if (this._isBuggyAndroid4()) {
                            result = new browserAdapters.BuggyAndroidBrowserAdapter(options)
                        } else {
                            if (this._isBuggyAndroid2() || !supportPushReplace) {
                                result = new browserAdapters.OldBrowserAdapter(options)
                            } else {
                                result = new browserAdapters.DefaultBrowserAdapter(options)
                            }
                        }
                    }
                }
                return result
            }
        });
        var StackBasedNavigationDevice = HistoryBasedNavigationDevice.inherit({
            ctor: function(options) {
                this.callBase(options);
                this.backInitiated = $.Callbacks();
                this._rootStateHandler = null;
                $(window).on("unload", this._saveBrowserState)
            },
            init: function() {
                var that = this;
                if (that._browserAdapter.canWorkInPureBrowser) {
                    return that._initRootPage().done(function() {
                        if (that._browserAdapter.isRootPage()) {
                            that._browserAdapter.pushState("")
                        }
                    })
                } else {
                    return $.Deferred().resolve().promise()
                }
            },
            setUri: function(uri) {
                return this.callBase(uri, !this._browserAdapter.isRootPage())
            },
            _saveBrowserState: function() {
                var sessionStorage = SessionStorage();
                if (sessionStorage) {
                    sessionStorage.setItem(SESSION_KEY, true)
                }
            },
            _initRootPage: function() {
                var hash = this.getUri(),
                    sessionStorage = SessionStorage();
                if (!sessionStorage || sessionStorage.getItem(SESSION_KEY)) {
                    return $.Deferred().resolve().promise()
                }
                sessionStorage.removeItem(SESSION_KEY);
                this._browserAdapter.createRootPage();
                return this._browserAdapter.pushState(hash)
            },
            _onPopState: function() {
                if (this._browserAdapter.isRootPage()) {
                    if (this._rootStateHandler) {
                        this._rootStateHandler()
                    } else {
                        this.backInitiated.fire()
                    }
                } else {
                    if (!this._rootStateHandler) {
                        this._createRootStateHandler()
                    }
                    this.back()
                }
            },
            _createRootStateHandler: function() {
                var uri = this.getUri();
                this._rootStateHandler = function() {
                    this.uriChanged.fire(uri);
                    this._rootStateHandler = null
                }
            }
        });
        exports.HistoryBasedNavigationDevice = HistoryBasedNavigationDevice;
        exports.StackBasedNavigationDevice = StackBasedNavigationDevice
    },
    /*!***********************************************!*\
      !*** ./Scripts/framework/browser_adapters.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            queue = __webpack_require__( /*! ../core/utils/queue */ 51);
        var ROOT_PAGE_URL = "__root__",
            BUGGY_ANDROID_BUFFER_PAGE_URL = "__buffer__";
        var DefaultBrowserAdapter = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this._window = options.window || window;
                this.popState = $.Callbacks();
                $(this._window).on("hashchange", $.proxy(this._onHashChange, this));
                this._tasks = queue.create();
                this.canWorkInPureBrowser = true
            },
            replaceState: function(uri) {
                var that = this;
                return this._addTask(function() {
                    uri = that._normalizeUri(uri);
                    that._window.history.replaceState(null, null, "#" + uri);
                    that._currentTask.resolve()
                })
            },
            pushState: function(uri) {
                var that = this;
                return this._addTask(function() {
                    uri = that._normalizeUri(uri);
                    that._window.history.pushState(null, null, "#" + uri);
                    that._currentTask.resolve()
                })
            },
            createRootPage: function() {
                return this.replaceState(ROOT_PAGE_URL)
            },
            _onHashChange: function() {
                if (this._currentTask) {
                    this._currentTask.resolve()
                }
                this.popState.fire()
            },
            back: function() {
                var that = this;
                return this._addTask(function() {
                    that._window.history.back()
                })
            },
            getHash: function() {
                return this._normalizeUri(this._window.location.hash)
            },
            isRootPage: function() {
                return this.getHash() === ROOT_PAGE_URL
            },
            _normalizeUri: function(uri) {
                return (uri || "").replace(/^#+/, "")
            },
            _addTask: function(task) {
                var that = this,
                    d = $.Deferred();
                this._tasks.add(function() {
                    that._currentTask = d;
                    task();
                    return d
                });
                return d.promise()
            }
        });
        var OldBrowserAdapter = DefaultBrowserAdapter.inherit({
            ctor: function() {
                this._innerEventCount = 0;
                this.callBase.apply(this, arguments);
                this._skipNextEvent = false
            },
            replaceState: function(uri) {
                var that = this;
                uri = that._normalizeUri(uri);
                if (that.getHash() !== uri) {
                    that._addTask(function() {
                        that._skipNextEvent = true;
                        that._window.history.back()
                    });
                    return that._addTask(function() {
                        that._skipNextEvent = true;
                        that._window.location.hash = uri
                    })
                }
                return $.Deferred().resolve().promise()
            },
            pushState: function(uri) {
                var that = this;
                uri = this._normalizeUri(uri);
                if (this.getHash() !== uri) {
                    return that._addTask(function() {
                        that._skipNextEvent = true;
                        that._window.location.hash = uri
                    })
                }
                return $.Deferred().resolve().promise()
            },
            createRootPage: function() {
                return this.pushState(ROOT_PAGE_URL)
            },
            _onHashChange: function() {
                var currentTask = this._currentTask;
                this._currentTask = null;
                if (this._skipNextEvent) {
                    this._skipNextEvent = false
                } else {
                    this.popState.fire()
                }
                if (currentTask) {
                    currentTask.resolve()
                }
            }
        });
        var BuggyAndroidBrowserAdapter = OldBrowserAdapter.inherit({
            createRootPage: function() {
                this.pushState(BUGGY_ANDROID_BUFFER_PAGE_URL);
                return this.callBase()
            }
        });
        var HistorylessBrowserAdapter = DefaultBrowserAdapter.inherit({
            ctor: function(options) {
                options = options || {};
                this._window = options.window || window;
                this.popState = $.Callbacks();
                $(this._window).on("dxback", $.proxy(this._onHashChange, this));
                this._currentHash = this._window.location.hash
            },
            replaceState: function(uri) {
                this._currentHash = this._normalizeUri(uri);
                return $.Deferred().resolve().promise()
            },
            pushState: function(uri) {
                return this.replaceState(uri)
            },
            createRootPage: function() {
                return this.replaceState(ROOT_PAGE_URL)
            },
            getHash: function() {
                return this._normalizeUri(this._currentHash)
            },
            back: function() {
                return this.replaceState(ROOT_PAGE_URL)
            },
            _onHashChange: function() {
                var promise = this.back();
                this.popState.fire();
                return promise
            }
        });
        var BuggyCordovaWP81BrowserAdapter = DefaultBrowserAdapter.inherit({
            ctor: function(options) {
                this.callBase(options);
                this.canWorkInPureBrowser = false
            }
        });
        exports.DefaultBrowserAdapter = DefaultBrowserAdapter;
        exports.OldBrowserAdapter = OldBrowserAdapter;
        exports.BuggyAndroidBrowserAdapter = BuggyAndroidBrowserAdapter;
        exports.HistorylessBrowserAdapter = HistorylessBrowserAdapter;
        exports.BuggyCordovaWP81BrowserAdapter = BuggyCordovaWP81BrowserAdapter
    },
    /*!**********************************************!*\
      !*** ./Scripts/framework/command_mapping.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            errors = __webpack_require__( /*! ./errors */ 122);
        var CommandMapping = Class.inherit({
            ctor: function() {
                this._commandMappings = {};
                this._containerDefaults = {}
            },
            setDefaults: function(containerId, defaults) {
                this._containerDefaults[containerId] = defaults;
                return this
            },
            mapCommands: function(containerId, commandMappings) {
                var that = this;
                $.each(commandMappings, function(index, commandMapping) {
                    if ("string" === typeof commandMapping) {
                        commandMapping = {
                            id: commandMapping
                        }
                    }
                    var commandId = commandMapping.id;
                    var mappings = that._commandMappings[containerId] || {};
                    mappings[commandId] = $.extend({
                        showIcon: true,
                        showText: true
                    }, that._containerDefaults[containerId] || {}, commandMapping);
                    that._commandMappings[containerId] = mappings
                });
                this._initExistingCommands();
                return this
            },
            unmapCommands: function(containerId, commandIds) {
                var that = this;
                $.each(commandIds, function(index, commandId) {
                    var mappings = that._commandMappings[containerId] || {};
                    if (mappings) {
                        delete mappings[commandId]
                    }
                });
                this._initExistingCommands()
            },
            getCommandMappingForContainer: function(commandId, containerId) {
                return (this._commandMappings[containerId] || {})[commandId]
            },
            checkCommandsExist: function(commands) {
                var that = this,
                    result = $.grep(commands, function(commandName, index) {
                        return $.inArray(commandName, that._existingCommands) < 0 && $.inArray(commandName, commands) === index
                    });
                if (0 !== result.length) {
                    throw errors.Error("E3005", result.join("', '"), 1 === result.length ? " is" : "s are")
                }
            },
            load: function(config) {
                if (!config) {
                    return
                }
                var that = this;
                $.each(config, function(name, container) {
                    that.setDefaults(name, container.defaults);
                    that.mapCommands(name, container.commands)
                });
                return this
            },
            _initExistingCommands: function() {
                var that = this;
                this._existingCommands = [];
                $.each(that._commandMappings, function(name, _commands) {
                    $.each(_commands, function(index, command) {
                        if ($.inArray(command.id, that._existingCommands) < 0) {
                            that._existingCommands.push(command.id)
                        }
                    })
                })
            }
        });
        CommandMapping.defaultMapping = {
            "global-navigation": {
                defaults: {
                    showIcon: true,
                    showText: true
                },
                commands: []
            },
            "ios-header-toolbar": {
                defaults: {
                    showIcon: false,
                    showText: true,
                    location: "after"
                },
                commands: ["edit", "save", {
                    id: "back",
                    location: "before"
                }, {
                    id: "cancel",
                    location: "before"
                }, {
                    id: "create",
                    showIcon: true,
                    showText: false
                }]
            },
            "ios-action-sheet": {
                defaults: {
                    showIcon: false,
                    showText: true
                },
                commands: []
            },
            "ios-view-footer": {
                defaults: {
                    showIcon: false,
                    showText: true
                },
                commands: [{
                    id: "delete",
                    type: "danger"
                }]
            },
            "android-header-toolbar": {
                defaults: {
                    showIcon: true,
                    showText: false,
                    location: "after"
                },
                commands: [{
                    id: "back",
                    showIcon: false,
                    location: "before"
                }, "create", {
                    id: "save",
                    showText: true,
                    showIcon: false,
                    location: "after"
                }, {
                    id: "edit",
                    showText: false,
                    location: "after"
                }, {
                    id: "cancel",
                    showText: false,
                    location: "before"
                }, {
                    id: "delete",
                    showText: false,
                    location: "after"
                }]
            },
            "android-simple-toolbar": {
                defaults: {
                    showIcon: true,
                    showText: false,
                    location: "after"
                },
                commands: [{
                    id: "back",
                    showIcon: false,
                    location: "before"
                }, {
                    id: "create"
                }, {
                    id: "save",
                    showText: true,
                    showIcon: false,
                    location: "after"
                }, {
                    id: "edit",
                    showText: false,
                    location: "after"
                }, {
                    id: "cancel",
                    showText: false,
                    location: "before"
                }, {
                    id: "delete",
                    showText: false,
                    location: "after"
                }]
            },
            "android-footer-toolbar": {
                defaults: {
                    location: "after"
                },
                commands: [{
                    id: "create",
                    showText: false,
                    location: "center"
                }, {
                    id: "edit",
                    showText: false,
                    location: "before"
                }, {
                    id: "delete",
                    locateInMenu: "always"
                }, {
                    id: "save",
                    showIcon: false,
                    location: "before"
                }]
            },
            "generic-header-toolbar": {
                defaults: {
                    showIcon: false,
                    showText: true,
                    location: "after"
                },
                commands: ["edit", "save", {
                    id: "back",
                    location: "before"
                }, {
                    id: "cancel",
                    location: "before"
                }, {
                    id: "create",
                    showIcon: true,
                    showText: false
                }]
            },
            "generic-view-footer": {
                defaults: {
                    showIcon: false,
                    showText: true
                },
                commands: [{
                    id: "delete",
                    type: "danger"
                }]
            },
            "win8-appbar": {
                defaults: {
                    location: "after"
                },
                commands: ["edit", "cancel", "save", "delete", {
                    id: "create",
                    location: "before"
                }, {
                    id: "refresh",
                    location: "before"
                }]
            },
            "win8-toolbar": {
                defaults: {
                    showText: false,
                    location: "before"
                },
                commands: [{
                    id: "previousPage"
                }]
            },
            "win8-phone-appbar": {
                defaults: {
                    location: "center"
                },
                commands: ["create", "edit", "cancel", "save", "refresh", {
                    id: "delete",
                    locateInMenu: "always"
                }]
            },
            "win8-split-toolbar": {
                defaults: {
                    showIcon: true,
                    showText: false,
                    location: "after"
                },
                commands: [{
                    id: "back",
                    showIcon: false,
                    location: "before"
                }, {
                    id: "create"
                }, {
                    id: "save",
                    showText: true,
                    location: "before"
                }, {
                    id: "edit",
                    showText: true,
                    locateInMenu: "always"
                }, {
                    id: "cancel",
                    showText: true,
                    locateInMenu: "always"
                }, {
                    id: "delete",
                    showText: true,
                    locateInMenu: "always"
                }]
            },
            "win8-master-detail-toolbar": {
                defaults: {
                    showText: false,
                    location: "before"
                },
                commands: ["back"]
            },
            "win10-appbar": {
                defaults: {
                    showText: false,
                    location: "after"
                },
                commands: [{
                    id: "back",
                    location: "before"
                }, "edit", "cancel", "save", "delete", "create", "refresh"]
            },
            "win10-phone-appbar": {
                defaults: {
                    location: "after"
                },
                commands: ["create", "edit", "cancel", "save", "refresh", {
                    id: "delete",
                    locateInMenu: "always"
                }]
            },
            "desktop-toolbar": {
                defaults: {
                    showIcon: false,
                    showText: true,
                    location: "after"
                },
                commands: ["cancel", "create", "edit", "save", {
                    id: "delete",
                    type: "danger"
                }]
            }
        };
        module.exports = CommandMapping
    },
    /*!*******************************!*\
      !*** ./Scripts/data/utils.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            toComparable = __webpack_require__( /*! ../core/utils/data */ 36).toComparable;
        var normalizeBinaryCriterion = function(crit) {
            return [crit[0], crit.length < 3 ? "=" : String(crit[1]).toLowerCase(), crit.length < 2 ? true : crit[crit.length - 1]]
        };
        var normalizeSortingInfo = function(info) {
            if (!$.isArray(info)) {
                info = [info]
            }
            return $.map(info, function(i) {
                return {
                    selector: $.isFunction(i) || "string" === typeof i ? i : i.getter || i.field || i.selector,
                    desc: !!(i.desc || "d" === String(i.dir).charAt(0).toLowerCase())
                }
            })
        };
        var errorMessageFromXhr = function() {
            var textStatusMessages = {
                timeout: "Network connection timeout",
                error: "Unspecified network error",
                parsererror: "Unexpected server response"
            };
            var textStatusDetails = {
                timeout: "possible causes: the remote host is not accessible, overloaded or is not included into the domain white-list when being run in the native container",
                error: "if the remote host is located on another domain, make sure it properly supports cross-origin resource sharing (CORS), or use the JSONP approach instead",
                parsererror: "the remote host did not respond with valid JSON data"
            };
            var explainTextStatus = function(textStatus) {
                var result = textStatusMessages[textStatus];
                if (!result) {
                    return textStatus
                }
                result += " (" + textStatusDetails[textStatus] + ")";
                return result
            };
            return function(xhr, textStatus) {
                if (xhr.status < 400) {
                    return explainTextStatus(textStatus)
                }
                return xhr.statusText
            }
        }();
        var aggregators = {
            count: {
                seed: 0,
                step: function(count) {
                    return 1 + count
                }
            },
            sum: {
                seed: 0,
                step: function(sum, item) {
                    return sum + item
                }
            },
            min: {
                step: function(min, item) {
                    return item < min ? item : min
                }
            },
            max: {
                step: function(max, item) {
                    return item > max ? item : max
                }
            },
            avg: {
                seed: [0, 0],
                step: function(pair, value) {
                    return [pair[0] + value, pair[1] + 1]
                },
                finalize: function(pair) {
                    return pair[1] ? pair[0] / pair[1] : NaN
                }
            }
        };
        var processRequestResultLock = function() {
            var lockDeferred, lockCount = 0;
            var obtain = function() {
                if (0 === lockCount) {
                    lockDeferred = $.Deferred()
                }
                lockCount++
            };
            var release = function() {
                lockCount--;
                if (lockCount < 1) {
                    lockDeferred.resolve()
                }
            };
            var promise = function() {
                var deferred = 0 === lockCount ? $.Deferred().resolve() : lockDeferred;
                return deferred.promise()
            };
            var reset = function() {
                lockCount = 0;
                if (lockDeferred) {
                    lockDeferred.resolve()
                }
            };
            return {
                obtain: obtain,
                release: release,
                promise: promise,
                reset: reset
            }
        }();

        function isDisjunctiveOperator(condition) {
            return /^(or|\|\||\|)$/i.test(condition)
        }

        function isConjunctiveOperator(condition) {
            return /^(and|\&\&|\&)$/i.test(condition)
        }
        var keysEqual = function(keyExpr, key1, key2) {
            if ($.isArray(keyExpr)) {
                var name, names = $.map(key1, function(v, k) {
                    return k
                });
                for (var i = 0; i < names.length; i++) {
                    name = names[i];
                    if (toComparable(key1[name], true) != toComparable(key2[name], true)) {
                        return false
                    }
                }
                return true
            }
            return toComparable(key1, true) == toComparable(key2, true)
        };
        var BASE64_CHARS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
        var base64_encode = function(input) {
            if (!$.isArray(input)) {
                input = stringToByteArray(String(input))
            }
            var result = "";

            function getBase64Char(index) {
                return BASE64_CHARS.charAt(index)
            }
            for (var i = 0; i < input.length; i += 3) {
                var octet1 = input[i],
                    octet2 = input[i + 1],
                    octet3 = input[i + 2];
                result += $.map([octet1 >> 2, (3 & octet1) << 4 | octet2 >> 4, isNaN(octet2) ? 64 : (15 & octet2) << 2 | octet3 >> 6, isNaN(octet3) ? 64 : 63 & octet3], getBase64Char).join("")
            }
            return result
        };
        var stringToByteArray = function(str) {
            var code, i, bytes = [];
            for (i = 0; i < str.length; i++) {
                code = str.charCodeAt(i);
                if (code < 128) {
                    bytes.push(code)
                } else {
                    if (code < 2048) {
                        bytes.push(192 + (code >> 6), 128 + (63 & code))
                    } else {
                        if (code < 65536) {
                            bytes.push(224 + (code >> 12), 128 + (code >> 6 & 63), 128 + (63 & code))
                        } else {
                            if (code < 2097152) {
                                bytes.push(240 + (code >> 18), 128 + (code >> 12 & 63), 128 + (code >> 6 & 63), 128 + (63 & code))
                            }
                        }
                    }
                }
            }
            return bytes
        };
        var utils = {
            normalizeBinaryCriterion: normalizeBinaryCriterion,
            normalizeSortingInfo: normalizeSortingInfo,
            errorMessageFromXhr: errorMessageFromXhr,
            aggregators: aggregators,
            keysEqual: keysEqual,
            isDisjunctiveOperator: isDisjunctiveOperator,
            isConjunctiveOperator: isConjunctiveOperator,
            processRequestResultLock: processRequestResultLock,
            base64_encode: base64_encode
        };
        module.exports = utils
    },
    /*!*******************************************!*\
      !*** ./Scripts/framework/html/presets.js ***!
      \*******************************************/
    function(module, exports) {
        exports.layoutSets = {};
        exports.animationSets = {
            "native": {
                "view-content-change": [{
                    animation: "slide"
                }, {
                    animation: "ios7-slide",
                    device: {
                        platform: "ios"
                    }
                }, {
                    animation: "none",
                    device: {
                        deviceType: "desktop",
                        platform: "generic"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "view-header-toolbar": [{
                    animation: "ios7-toolbar"
                }, {
                    animation: "slide",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }]
            },
            "default": {
                "layout-change": [{
                    animation: "none"
                }, {
                    animation: "ios7-slide",
                    device: {
                        platform: "ios"
                    }
                }, {
                    animation: "pop",
                    device: {
                        platform: "android"
                    }
                }, {
                    animation: "openDoor",
                    device: {
                        deviceType: "phone",
                        platform: "win",
                        version: [8]
                    }
                }, {
                    animation: "win-pop",
                    device: {
                        deviceType: "phone",
                        platform: "win"
                    }
                }],
                "view-content-change": [{
                    animation: "slide"
                }, {
                    animation: "ios7-slide",
                    device: {
                        platform: "ios"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop",
                        platform: "generic"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "view-content-rendered": [{
                    animation: "fade"
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "view-header-toolbar": [{
                    animation: "ios7-toolbar"
                }, {
                    animation: "slide",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "command-rendered-top": [{
                    animation: "stagger-fade-drop"
                }, {
                    animation: "fade",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }, {
                    animation: "none",
                    device: {
                        platform: "win",
                        version: [10]
                    }
                }],
                "command-rendered-bottom": [{
                    animation: "stagger-fade-rise"
                }, {
                    animation: "fade",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }, {
                    animation: "none",
                    device: {
                        platform: "win",
                        version: [10]
                    }
                }],
                "list-item-rendered": [{
                    animation: "stagger-3d-drop",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "detail-item-rendered": [{
                    animation: "stagger-3d-drop",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "edit-item-rendered": [{
                    animation: "stagger-3d-drop",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }]
            },
            slide: {
                "view-content-change": [{
                    animation: "slide"
                }, {
                    animation: "ios7-slide",
                    device: {
                        platform: "ios"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop",
                        platform: "generic"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "view-content-rendered": [{
                    animation: "fade"
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "view-header-toolbar": [{
                    animation: "ios7-toolbar"
                }, {
                    animation: "slide",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "command-rendered-top": [{
                    animation: "stagger-fade-drop"
                }, {
                    animation: "fade",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "command-rendered-bottom": [{
                    animation: "stagger-fade-rise"
                }, {
                    animation: "fade",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "list-item-rendered": [{
                    animation: "stagger-fade-slide",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "detail-item-rendered": [{
                    animation: "stagger-fade-slide",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "edit-item-rendered": [{
                    animation: "stagger-fade-slide",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }]
            },
            zoom: {
                "view-content-change": [{
                    animation: "slide"
                }, {
                    animation: "ios7-slide",
                    device: {
                        platform: "ios"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop",
                        platform: "generic"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "view-content-rendered": [{
                    animation: "fade"
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "view-header-toolbar": [{
                    animation: "ios7-toolbar"
                }, {
                    animation: "slide",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "command-rendered-top": [{
                    animation: "stagger-fade-zoom"
                }, {
                    animation: "fade",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "command-rendered-bottom": [{
                    animation: "stagger-fade-zoom"
                }, {
                    animation: "fade",
                    device: {
                        grade: "B"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "list-item-rendered": [{
                    animation: "stagger-fade-zoom",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "detail-item-rendered": [{
                    animation: "stagger-fade-zoom",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }],
                "edit-item-rendered": [{
                    animation: "stagger-fade-zoom",
                    device: {
                        grade: "A"
                    }
                }, {
                    animation: "fade",
                    device: {
                        deviceType: "desktop"
                    }
                }, {
                    animation: "none",
                    device: {
                        grade: "C"
                    }
                }]
            }
        }
    },
    /*!***************************************************!*\
      !*** ./Scripts/framework/html/command_manager.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            errors = __webpack_require__( /*! ../errors */ 122),
            CommandMapping = __webpack_require__( /*! ../command_mapping */ 136),
            commandToDXWidgetAdapters = __webpack_require__( /*! ./widget_command_adapters */ 140);
        __webpack_require__( /*! ../command */ 121);
        __webpack_require__( /*! ./command_container */ 126);
        var CommandManager = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this.defaultWidgetAdapter = options.defaultWidgetAdapter || this._getDefaultWidgetAdapter();
                this.commandMapping = options.commandMapping || new CommandMapping
            },
            _getDefaultWidgetAdapter: function() {
                return {
                    addCommand: $.noop,
                    clearContainer: $.noop
                }
            },
            _getContainerAdapter: function($container) {
                var componentNames = $container.data("dxComponents"),
                    adapters = commandToDXWidgetAdapters;
                if (componentNames) {
                    for (var index in componentNames) {
                        var widgetName = componentNames[index];
                        if (widgetName in adapters) {
                            return adapters[widgetName]
                        }
                    }
                }
                return this.defaultWidgetAdapter
            },
            findCommands: function($view) {
                var result = $.map($view.addBack().find(".dx-command"), function(element) {
                    return $(element).dxCommand("instance")
                });
                return result
            },
            findCommandContainers: function($markup) {
                var result = $.map($markup.find(".dx-command-container"), function(element) {
                    return $(element).dxCommandContainer("instance")
                });
                return result
            },
            _checkCommandId: function(id, command) {
                if (null === id) {
                    throw errors.Error("E3010", command.element().get(0).outerHTML)
                }
            },
            renderCommandsToContainers: function(commands, containers) {
                var that = this,
                    commandHash = {},
                    commandIds = [],
                    deferreds = [];
                $.each(commands, function(i, command) {
                    var id = command.option("id");
                    that._checkCommandId(id, command);
                    commandIds.push(id);
                    commandHash[id] = command
                });
                that.commandMapping.checkCommandsExist(commandIds);
                $.each(containers, function(k, container) {
                    var commandInfos = [];
                    $.each(commandHash, function(id, command) {
                        var commandId = id;
                        var commandOptions = that.commandMapping.getCommandMappingForContainer(commandId, container.option("id"));
                        if (commandOptions) {
                            commandInfos.push({
                                command: command,
                                options: commandOptions
                            })
                        }
                    });
                    if (commandInfos.length) {
                        var deferred = that._attachCommandsToContainer(container.element(), commandInfos);
                        if (deferred) {
                            deferreds.push(deferred)
                        }
                    }
                });
                return $.when.apply($, deferreds)
            },
            clearContainer: function(container) {
                var $container = container.element(),
                    adapter = this._getContainerAdapter($container);
                adapter.clearContainer($container)
            },
            _arrangeCommandsToContainers: function(commands, containers) {
                errors.log("W0002", "CommandManager", "_arrangeCommandsToContainers", "14.1", "Use the 'renderCommandsToContainers' method instead.");
                this.renderCommandsToContainers(commands, containers)
            },
            _attachCommandsToContainer: function($container, commandInfos) {
                var result, adapter = this._getContainerAdapter($container);
                if (adapter.beginUpdate) {
                    adapter.beginUpdate($container)
                }
                $.each(commandInfos, function(index, commandInfo) {
                    adapter.addCommand($container, commandInfo.command, commandInfo.options)
                });
                if (adapter.endUpdate) {
                    result = adapter.endUpdate($container)
                }
                return result
            }
        });
        module.exports = CommandManager
    },
    /*!***********************************************************!*\
      !*** ./Scripts/framework/html/widget_command_adapters.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commandToContainer = __webpack_require__( /*! ../utils */ 131).utils.commandToContainer,
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            TransitionExecutorModule = __webpack_require__( /*! ../../animation/transition_executor/transition_executor */ 63),
            DX_COMMAND_TO_WIDGET_ADAPTER = "dxCommandToWidgetAdapter";
        var WidgetItemWrapperBase = Class.inherit({
            ctor: function(command, containerOptions) {
                this.command = command;
                this.widgetItem = this._createWidgetItem(command, containerOptions)
            },
            _createWidgetItem: function(command, containerOptions) {
                var result, itemOptions = $.extend({}, containerOptions, command.option()),
                    executeCommandCallback = function(e) {
                        command.execute(e)
                    };
                itemOptions.text = commandToContainer.resolveTextValue(command, containerOptions);
                itemOptions.icon = commandToContainer.resolveIconValue(command, containerOptions);
                itemOptions.type = commandToContainer.resolvePropertyValue(command, containerOptions, "type");
                itemOptions.location = commandToContainer.resolvePropertyValue(command, containerOptions, "location");
                itemOptions.locateInMenu = commandToContainer.resolvePropertyValue(command, containerOptions, "locateInMenu");
                result = this._createWidgetItemCore(itemOptions, executeCommandCallback);
                result.command = command;
                return result
            },
            _createWidgetItemCore: function(itemOptions, executeCommandCallback) {
                return itemOptions
            },
            dispose: function() {
                delete this.command;
                delete this.widgetItem
            }
        });
        var WidgetAdapterBase = Class.inherit({
            ctor: function($widgetElement) {
                this._commandToWidgetItemOptionNames = {};
                this.$widgetElement = $widgetElement;
                this.$widgetElement.data(DX_COMMAND_TO_WIDGET_ADAPTER, this);
                this.widget = this._getWidgetByElement($widgetElement);
                this._widgetWidgetContentReadyHandler = $.proxy(this._onWidgetContentReady, this);
                this._widgetWidgetItemRenderedHandler = $.proxy(this._onWidgetItemRendered, this);
                this._widgetDisposingHandler = $.proxy(this._onWidgetDisposing, this);
                this.widget.on("itemRendered", this._widgetWidgetItemRenderedHandler);
                this.widget.on("contentReady", this._widgetWidgetContentReadyHandler);
                this.widget.on("disposing", this._widgetDisposingHandler);
                this.itemWrappers = [];
                this._transitionExecutor = new TransitionExecutorModule.TransitionExecutor
            },
            addCommand: function(command, containerOptions) {
                var itemWrapper = this._createItemWrapper(command, containerOptions);
                this.itemWrappers.push(itemWrapper);
                this._addItemToWidget(itemWrapper);
                this._commandChangedHandler = $.proxy(this._onCommandChanged, this);
                itemWrapper.command.on("optionChanged", this._commandChangedHandler)
            },
            beginUpdate: function() {
                this.widget.beginUpdate()
            },
            endUpdate: function() {
                this.widget.endUpdate();
                return this.animationDeferred
            },
            _onWidgetItemRendered: function(e) {
                if (e.itemData.isJustAdded && e.itemData.command && e.itemData.command.option("visible") && this._commandRenderedAnimation) {
                    this._transitionExecutor.enter(e.itemElement, this._commandRenderedAnimation);
                    delete e.itemData.isJustAdded
                }
            },
            _onWidgetContentReady: function(e) {
                this.animationDeferred = this._transitionExecutor.start()
            },
            _onWidgetDisposing: function() {
                this.dispose(true)
            },
            _setWidgetItemOption: function(optionName, optionValue, itemCommand) {
                var items = this.widget.option("items"),
                    itemIndex = $.inArray(itemCommand, $.map(items, function(item) {
                        return item.command || {}
                    }));
                if (itemIndex > -1) {
                    var optionPath = "items[" + itemIndex + "].";
                    if (!this._requireWidgetRefresh(optionName) && this.widget.option("items[" + itemIndex + "]").options) {
                        optionPath += "options."
                    }
                    optionPath += this._commandToWidgetItemOptionNames[optionName] || optionName;
                    this.widget.option(optionPath, optionValue)
                }
            },
            _requireWidgetRefresh: function(optionName) {
                return "visible" === optionName || "locateInMenu" === optionName || "location" === optionName
            },
            _onCommandChanged: function(args) {
                if ("highlighted" === args.name || args.component.isOptionDeprecated(args.name)) {
                    return
                }
                this._setWidgetItemOption(args.name, args.value, args.component)
            },
            _addItemToWidget: function(itemWrapper) {
                var items = this.widget.option("items");
                items.push(itemWrapper.widgetItem);
                if (this.widget.element().is(":visible")) {
                    itemWrapper.widgetItem.isJustAdded = true
                }
                this.widget.option("items", items)
            },
            refresh: function() {
                var items = this.widget.option("items");
                this.widget.option("items", items)
            },
            clear: function(widgetDisposing) {
                var that = this;
                $.each(that.itemWrappers, function(index, itemWrapper) {
                    itemWrapper.command.off("optionChanged", that._commandChangedHandler);
                    itemWrapper.dispose()
                });
                this.itemWrappers.length = 0;
                if (!widgetDisposing) {
                    this._clearWidgetItems()
                }
            },
            _clearWidgetItems: function() {
                this.widget.option("items", [])
            },
            dispose: function(widgetDisposing) {
                this.clear(widgetDisposing);
                if (this.widget) {
                    this.widget.off("itemRendered", this._widgetWidgetItemRenderedHandler);
                    this.widget.off("contentReady", this._widgetContentReadyHandler);
                    this.widget.off("disposing", this._widgetDisposingHandler);
                    this.$widgetElement.removeData(DX_COMMAND_TO_WIDGET_ADAPTER);
                    delete this.widget;
                    delete this.$widgetElement
                }
            }
        });
        var CommandToWidgetAdapter = Class.inherit({
            ctor: function(createAdapter) {
                this.createAdapter = createAdapter
            },
            _getWidgetAdapter: function($container) {
                var widgetAdapter = $container.data(DX_COMMAND_TO_WIDGET_ADAPTER);
                if (!widgetAdapter) {
                    widgetAdapter = this.createAdapter($container)
                }
                return widgetAdapter
            },
            addCommand: function($container, command, containerOptions) {
                var widgetAdapter = this._getWidgetAdapter($container);
                widgetAdapter.addCommand(command, containerOptions)
            },
            clearContainer: function($container) {
                var widgetAdapter = this._getWidgetAdapter($container);
                widgetAdapter.clear()
            },
            beginUpdate: function($container) {
                var widgetAdapter = this._getWidgetAdapter($container);
                widgetAdapter.beginUpdate()
            },
            endUpdate: function($container) {
                var widgetAdapter = this._getWidgetAdapter($container);
                return widgetAdapter.endUpdate()
            }
        });
        var dxToolbarItemWrapper = WidgetItemWrapperBase.inherit({
            _createWidgetItemCore: function(itemOptions, executeCommandCallback) {
                var widgetItem;
                itemOptions.onClick = executeCommandCallback;
                if ("menu" === itemOptions.location || "always" === itemOptions.locateInMenu) {
                    widgetItem = itemOptions
                } else {
                    widgetItem = {
                        locateInMenu: itemOptions.locateInMenu,
                        location: itemOptions.location,
                        visible: itemOptions.visible,
                        options: itemOptions,
                        widget: "dxButton"
                    };
                    itemOptions.visible = true;
                    delete itemOptions.location
                }
                return widgetItem
            }
        });
        var dxToolbarAdapter = WidgetAdapterBase.inherit({
            ctor: function($widgetElement) {
                this.callBase($widgetElement);
                this._commandToWidgetItemOptionNames = {
                    title: "text"
                };
                if ("topToolbar" === this.widget.option("renderAs")) {
                    this._commandRenderedAnimation = "command-rendered-top"
                } else {
                    this._commandRenderedAnimation = "command-rendered-bottom"
                }
            },
            _getWidgetByElement: function($element) {
                return $element.dxToolbar("instance")
            },
            _createItemWrapper: function(command, containerOptions) {
                return new dxToolbarItemWrapper(command, containerOptions)
            },
            addCommand: function(command, containerOptions) {
                this.widget.option("visible", true);
                this.callBase(command, containerOptions)
            }
        });
        var dxListItemWrapper = WidgetItemWrapperBase.inherit({
            _createWidgetItemCore: function(itemOptions, executeCommandCallback) {
                itemOptions.title = itemOptions.text;
                itemOptions.onClick = executeCommandCallback;
                return itemOptions
            }
        });
        var dxListAdapter = WidgetAdapterBase.inherit({
            _createItemWrapper: function(command, containerOptions) {
                return new dxListItemWrapper(command, containerOptions)
            },
            _getWidgetByElement: function($element) {
                return $element.dxList("instance")
            }
        });
        var dxNavBarItemWrapper = WidgetItemWrapperBase.inherit({});
        var dxNavBarAdapter = WidgetAdapterBase.inherit({
            ctor: function($widgetElement) {
                this.callBase($widgetElement);
                this._commandToWidgetItemOptionNames = {
                    title: "text"
                };
                this.widget.option("onItemClick", $.proxy(this._onNavBarItemClick, this))
            },
            _onNavBarItemClick: function(e) {
                var items = this.widget.option("items");
                for (var i = items.length; --i;) {
                    items[i].command.option("highlighted", false)
                }
                e.itemData.command.execute(e)
            },
            _getWidgetByElement: function($element) {
                return $element.dxNavBar("instance")
            },
            _createItemWrapper: function(command, containerOptions) {
                return new dxNavBarItemWrapper(command, containerOptions)
            },
            addCommand: function(command, containerOptions) {
                this.callBase(command, containerOptions);
                this._updateSelectedIndex()
            },
            _onCommandChanged: function(args) {
                var optionName = args.name,
                    newValue = args.value;
                if ("highlighted" === optionName && newValue) {
                    this._updateSelectedIndex()
                }
                this.callBase(args)
            },
            _updateSelectedIndex: function() {
                var items = this.widget.option("items");
                for (var i = 0, itemsCount = items.length; i < itemsCount; i++) {
                    var command = items[i].command;
                    if (command && command.option("highlighted")) {
                        this.widget.option("selectedIndex", i);
                        break
                    }
                }
            }
        });
        var dxPivotItemWrapper = WidgetItemWrapperBase.inherit({
            _createWidgetItemCore: function(itemOptions, executeCommandCallback) {
                itemOptions.title = itemOptions.text;
                return itemOptions
            }
        });
        var dxPivotAdapter = WidgetAdapterBase.inherit({
            ctor: function($widgetElement) {
                this.callBase($widgetElement);
                this.widget.option("onSelectionChanged", $.proxy(this._onPivotSelectionChange, this))
            },
            _onPivotSelectionChange: function(e) {
                if (e.addedItems.length && e.removedItems.length && e.addedItems[0] && e.addedItems[0].command) {
                    e.addedItems[0].command.execute(e)
                }
            },
            _getWidgetByElement: function($element) {
                return $element.dxPivot("instance")
            },
            _createItemWrapper: function(command, containerOptions) {
                return new dxPivotItemWrapper(command, containerOptions)
            },
            addCommand: function(command, containerOptions) {
                this.callBase(command, containerOptions);
                this._updateSelectedIndex()
            },
            _onCommandChanged: function(args) {
                var optionName = args.name,
                    newValue = args.value;
                if ("visible" === optionName) {
                    this._rerenderPivot()
                } else {
                    if ("highlighted" === optionName && newValue) {
                        this._updateSelectedIndex()
                    }
                }
                this.callBase(args)
            },
            _addItemToWidget: function(itemWrapper) {
                if (itemWrapper.command.option("visible")) {
                    this.callBase(itemWrapper)
                }
            },
            _updateSelectedIndex: function() {
                var pivot = this.widget,
                    items = pivot.option("items") || [];
                fx.off = true;
                for (var i = 0, itemsCount = items.length; i < itemsCount; i++) {
                    var command = items[i].command;
                    if (command && command.option("highlighted")) {
                        pivot.option("selectedIndex", i);
                        break
                    }
                }
                fx.off = false
            },
            _rerenderPivot: function() {
                var that = this;
                that.widget.option("items", []);
                $.each(that.itemWrappers, function(index, itemWrapper) {
                    if (itemWrapper.command.option("visible")) {
                        that._addItemToWidget(itemWrapper)
                    }
                });
                that.refresh();
                that._updateSelectedIndex()
            }
        });
        var dxSlideOutItemWrapper = WidgetItemWrapperBase.inherit({});
        var dxSlideOutAdapter = WidgetAdapterBase.inherit({
            ctor: function($widgetElement) {
                this.callBase($widgetElement);
                this._commandToWidgetItemOptionNames = {
                    title: "text"
                };
                this.widget.option("onItemClick", $.proxy(this._onSlideOutItemClick, this))
            },
            _onSlideOutItemClick: function(e) {
                e.itemData.command.execute(e)
            },
            _getWidgetByElement: function($element) {
                return $element.dxSlideOut("instance")
            },
            _createItemWrapper: function(command, containerOptions) {
                return new dxSlideOutItemWrapper(command, containerOptions)
            },
            _updateSelectedIndex: function() {
                var items = this.widget.option("items") || [];
                for (var i = 0, itemsCount = items.length; i < itemsCount; i++) {
                    var command = items[i].command;
                    if (command && command.option("highlighted")) {
                        this.widget.option("selectedIndex", i);
                        break
                    }
                }
            },
            addCommand: function(command, containerOptions) {
                this.callBase(command, containerOptions);
                this._updateSelectedIndex()
            },
            _onCommandChanged: function(args) {
                var optionName = args.name,
                    newValue = args.value;
                if ("highlighted" === optionName && newValue) {
                    this._updateSelectedIndex()
                }
                this.callBase(args)
            }
        });
        exports.dxToolbar = new CommandToWidgetAdapter(function($widgetElement) {
            return new dxToolbarAdapter($widgetElement)
        });
        exports.dxList = new CommandToWidgetAdapter(function($widgetElement) {
            return new dxListAdapter($widgetElement)
        });
        exports.dxNavBar = new CommandToWidgetAdapter(function($widgetElement) {
            return new dxNavBarAdapter($widgetElement)
        });
        exports.dxPivot = new CommandToWidgetAdapter(function($widgetElement) {
            return new dxPivotAdapter($widgetElement)
        });
        exports.dxSlideOut = new CommandToWidgetAdapter(function($widgetElement) {
            return new dxSlideOutAdapter($widgetElement)
        });
        exports.WidgetItemWrapperBase = WidgetItemWrapperBase;
        exports.WidgetAdapterBase = WidgetAdapterBase
    },
    /*!***********************************************!*\
      !*** ./Scripts/framework/html/view_engine.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            version = __webpack_require__( /*! ../../core/version */ 16),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            errors = __webpack_require__( /*! ../errors */ 122),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            _VIEW_ROLE = "dxView",
            _LAYOUT_ROLE = "dxLayout",
            MARKUP_TEMPLATE_MARKER = "MarkupTemplate:";
        __webpack_require__( /*! ./view_engine_components */ 128);
        var ViewEngine = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this.$root = options.$root;
                this.device = options.device || {};
                this.dataOptionsAttributeName = options.dataOptionsAttributeName || "data-options";
                this._templateMap = {};
                this._pendingViewContainer = null;
                this.markupLoaded = $.Callbacks();
                this._templateContext = options.templateContext;
                this._$skippedMarkup = $();
                if (void 0 !== options.templatesVersion && options.templateCacheStorage && this._isReleaseVersion()) {
                    this._templateCacheEnabled = true;
                    this._templatesVersion = "v_" + options.templatesVersion;
                    this._templateCacheStorage = options.templateCacheStorage;
                    this._templateCacheKey = "dxTemplateCache_" + version + "_" + JSON.stringify(this.device)
                }
            },
            _isReleaseVersion: function() {
                return !/http:\/\/localhost/.test(location.href)
            },
            _enumerateTemplates: function(processFn) {
                var that = this;
                $.each(that._templateMap, function(name, templatesByRoleMap) {
                    $.each(templatesByRoleMap, function(role, templates) {
                        $.each(templates, function(index, template) {
                            processFn(template)
                        })
                    })
                })
            },
            _findComponent: function(name, role) {
                var components = (this._templateMap[name] || {})[role] || [],
                    filter = this._templateContext && this._templateContext.option() || {};
                components = this._filterTemplates(filter, components);
                this._checkMatchedTemplates(components);
                return components[0]
            },
            _findTemplate: function(name, role) {
                var component = this._findComponent(name, role);
                if (!component) {
                    this._clearCache();
                    throw errors.Error("E3013", role, name)
                }
                var $result, $template = component.element();
                if (!component._isStaticComponentsCreated) {
                    domUtils.createComponents($template, ["dxContent", "dxContentPlaceholder", "dxTransition"]);
                    component._isStaticComponentsCreated = true
                }
                $result = $template.clone().removeClass("dx-hidden");
                return $result
            },
            _clearCache: function() {
                this._templateCacheStorage.removeItem(this._templateCacheKey)
            },
            _loadTemplatesFromMarkupCore: function($markup) {
                var that = this;
                if ($markup.find("[data-dx-role]").length) {
                    throw errors.Error("E3019")
                }
                that.markupLoaded.fire({
                    markup: $markup
                });
                var components = domUtils.createComponents($markup, [_VIEW_ROLE, _LAYOUT_ROLE]);
                $.each(components, function(index, component) {
                    var $element = component.element();
                    $element.addClass("dx-hidden");
                    that._registerTemplateComponent(component);
                    component.element().detach()
                });
                var $skipped = $markup.filter("script");
                $skipped.appendTo(that.$root);
                that._$skippedMarkup = that._$skippedMarkup.add($skipped)
            },
            _registerTemplateComponent: function(component) {
                var role = component.NAME,
                    options = component.option(),
                    templateName = options.name,
                    componentsByRoleMap = this._templateMap[templateName] || {};
                componentsByRoleMap[role] = componentsByRoleMap[role] || [];
                componentsByRoleMap[role].push(component);
                this._templateMap[templateName] = componentsByRoleMap
            },
            _applyPartialViews: function($render) {
                var that = this;
                domUtils.createComponents($render, ["dxViewPlaceholder"]);
                $.each($render.find(".dx-view-placeholder"), function() {
                    var $partialPlaceholder = $(this);
                    if ($partialPlaceholder.children().length) {
                        return
                    }
                    var viewName = $partialPlaceholder.data("dxViewPlaceholder").option("viewName"),
                        $view = that._findTemplate(viewName, _VIEW_ROLE);
                    that._applyPartialViews($view);
                    $partialPlaceholder.append($view);
                    $view.removeClass("dx-hidden")
                })
            },
            _ajaxImpl: function() {
                return $.ajax.apply($, arguments)
            },
            _loadTemplatesFromURL: function(url) {
                var that = this,
                    options = this._getLoadOptions(),
                    deferred = $.Deferred();
                url = options.winPhonePrefix + url;
                this._ajaxImpl({
                    url: url,
                    isLocal: options.isLocal,
                    dataType: "html"
                }).done(function(data) {
                    that._loadTemplatesFromMarkupCore(domUtils.createMarkupFromString(data));
                    deferred.resolve()
                }).fail(function(jqXHR, textStatus, errorThrown) {
                    var error = errors.Error("E3021", url, errorThrown);
                    deferred.reject(error)
                });
                return deferred.promise()
            },
            _getLoadOptions: function() {
                if (location.protocol.indexOf("wmapp") >= 0) {
                    return {
                        winPhonePrefix: location.protocol + "www/",
                        isLocal: true
                    }
                }
                return {
                    winPhonePrefix: "",
                    isLocal: void 0
                }
            },
            _loadExternalTemplates: function() {
                var tasks = [],
                    that = this;
                $("head").find("link[rel='dx-template']").each(function(index, link) {
                    var task = that._loadTemplatesFromURL($(link).attr("href"));
                    tasks.push(task)
                });
                return $.when.apply($, tasks)
            },
            _processTemplates: function() {
                var that = this;
                $.each(that._templateMap, function(name, templatesByRoleMap) {
                    $.each(templatesByRoleMap, function(role, templates) {
                        that._filterTemplatesByDevice(templates)
                    })
                });
                that._enumerateTemplates(function(template) {
                    that._applyPartialViews(template.element())
                })
            },
            _filterTemplatesByDevice: function(components) {
                var filteredComponents = this._filterTemplates(this.device, components);
                $.each(components, function(index, component) {
                    if ($.inArray(component, filteredComponents) < 0) {
                        component.element().remove()
                    }
                });
                components.length = 0;
                components.push.apply(components, filteredComponents)
            },
            _filterTemplates: function(filter, components) {
                return commonUtils.findBestMatches(filter, components, function(component) {
                    return component.option()
                })
            },
            _checkMatchedTemplates: function(bestMatches) {
                if (bestMatches.length > 1) {
                    var message = "";
                    $.each(bestMatches, function(index, match) {
                        message += match.element().attr("data-options") + "\r\n"
                    });
                    throw errors.Error("E3020", message, JSON.stringify(this.device))
                }
            },
            _wrapViewDefaultContent: function($viewTemplate) {
                $viewTemplate.wrapInner('<div class="dx-full-height"></div>');
                $viewTemplate.children().eq(0).dxContent({
                    targetPlaceholder: "content"
                })
            },
            _initDefaultLayout: function() {
                this._$defaultLayoutTemplate = $('<div class="dx-full-height" data-options="dxLayout : { name: \'default\' } "> \n    <div class="dx-full-height" data-options="dxContentPlaceholder : { name: \'content\' } " ></div> \n</div>');
                domUtils.createComponents(this._$defaultLayoutTemplate)
            },
            _getDefaultLayoutTemplate: function() {
                return this._$defaultLayoutTemplate.clone()
            },
            applyLayout: function($view, $layout) {
                if (void 0 === $layout || 0 === $layout.length) {
                    $layout = this._getDefaultLayoutTemplate()
                }
                if (0 === $view.children(".dx-content").length) {
                    this._wrapViewDefaultContent($view)
                }
                var $toMerge = $().add($layout).add($view);
                var $placeholderContents = $toMerge.find(".dx-content");
                $.each($placeholderContents, function() {
                    var $placeholderContent = $(this);
                    var placeholderId = $placeholderContent.attr("data-dx-target-placeholder-id");
                    var $placeholder = $toMerge.find(".dx-content-placeholder-" + placeholderId);
                    $placeholder.empty();
                    $placeholder.append($placeholderContent)
                });
                $placeholderContents.filter(":not(.dx-content-placeholder .dx-content)").remove();
                return $layout
            },
            _loadTemplatesFromCache: function() {
                if (!this._templateCacheEnabled) {
                    return
                }
                var cache;
                var fromJSONInterceptor = function(key, value) {
                    if ("string" === typeof value && 0 === value.indexOf(MARKUP_TEMPLATE_MARKER)) {
                        var data = JSON.parse(value.substr(MARKUP_TEMPLATE_MARKER.length)),
                            type = data.type,
                            options = data.options,
                            $markup = domUtils.createMarkupFromString(data.markup);
                        options.fromCache = true;
                        return $markup[type](options)[type]("instance")
                    } else {
                        if ("skippedMarkup" === key) {
                            return $("<div>").append(domUtils.createMarkupFromString(value)).contents()
                        }
                    }
                    return value
                };
                var toParse = this._templateCacheStorage.getItem(this._templateCacheKey);
                if (toParse) {
                    try {
                        var cacheContainer = JSON.parse(toParse, fromJSONInterceptor);
                        cache = cacheContainer[this._templatesVersion]
                    } catch (e) {
                        this._clearCache()
                    }
                }
                if (!cache) {
                    return
                }
                this._templateMap = cache.templates;
                this.$root.append(cache.skippedMarkup);
                return true
            },
            _putTemplatesToCache: function() {
                if (!this._templateCacheEnabled) {
                    return
                }
                var toJSONInterceptor = function(key, value) {
                    if (value && value.element) {
                        return MARKUP_TEMPLATE_MARKER + JSON.stringify({
                            markup: value.element().prop("outerHTML"),
                            options: value.option(),
                            type: value.NAME
                        })
                    } else {
                        if ("skippedMarkup" === key) {
                            return $("<div>").append(value.clone()).html()
                        }
                    }
                    return value
                };
                var cacheContainer = {};
                cacheContainer[this._templatesVersion] = {
                    templates: this._templateMap,
                    skippedMarkup: this._$skippedMarkup
                };
                this._templateCacheStorage.setItem(this._templateCacheKey, JSON.stringify(cacheContainer, toJSONInterceptor, 4))
            },
            init: function() {
                var that = this;
                this._initDefaultLayout();
                if (!this._loadTemplatesFromCache()) {
                    that._loadTemplatesFromMarkupCore(that.$root.children());
                    return this._loadExternalTemplates().done(function() {
                        that._processTemplates();
                        that._putTemplatesToCache()
                    })
                } else {
                    return $.Deferred().resolve().promise()
                }
            },
            getViewTemplate: function(viewName) {
                return this._findTemplate(viewName, _VIEW_ROLE)
            },
            getViewTemplateInfo: function(name) {
                return this._findComponent(name, _VIEW_ROLE)
            },
            getLayoutTemplate: function(layoutName) {
                if (!layoutName) {
                    return this._getDefaultLayoutTemplate()
                }
                return this._findTemplate(layoutName, _LAYOUT_ROLE)
            },
            getLayoutTemplateInfo: function(name) {
                return this._findComponent(name, _LAYOUT_ROLE)
            },
            loadTemplates: function(source) {
                var result;
                if ("string" === typeof source) {
                    result = this._loadTemplatesFromURL(source)
                } else {
                    this._loadTemplatesFromMarkupCore(source);
                    result = $.Deferred().resolve().promise()
                }
                return result.done($.proxy(this._processTemplates, this))
            }
        });
        exports.ViewEngine = ViewEngine
    },
    /*!*****************************************************!*\
      !*** ./Scripts/framework/html/layout_controller.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            frameworkUtils = __webpack_require__( /*! ../utils */ 131),
            layoutSets = __webpack_require__( /*! ./presets */ 138).layoutSets,
            EventsMixin = __webpack_require__( /*! ../../core/events_mixin */ 39),
            errors = __webpack_require__( /*! ../errors */ 122),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            HIDDEN_BAG_ID = "__hidden-bag",
            TRANSITION_SELECTOR = ".dx-transition:not(.dx-transition .dx-transition)",
            CONTENT_SELECTOR = ".dx-content",
            DEFAULT_COMMAND_RENDER_STAGE = "onViewShown",
            CONTENT_RENDERED_EVENT_NAME = "dxcontentrendered.layoutController",
            PENDING_RENDERING_SELECTOR = ".dx-pending-rendering",
            PENDING_RENDERING_MANUAL_SELECTOR = ".dx-pending-rendering-manual",
            TransitionExecutorModule = __webpack_require__( /*! ../../animation/transition_executor/transition_executor */ 63);
        __webpack_require__( /*! ./command_container */ 126);
        __webpack_require__( /*! ./view_engine_components */ 128);
        var transitionSelector = function(transitionName) {
            return ".dx-transition-" + transitionName
        };
        var DefaultLayoutController = Class.inherit({
            ctor: function(options) {
                options = options || {};
                this.name = options.name || "";
                this._layoutModel = options.layoutModel || {};
                this._defaultPaneName = options.defaultPaneName || "content";
                this._transitionDuration = void 0 === options.transitionDuration ? 400 : options.transitionDuration;
                this._showViewFired = false
            },
            init: function(options) {
                options = options || {};
                this._visibleViews = {};
                this._$viewPort = options.$viewPort || $("body");
                this._commandManager = options.commandManager;
                this._viewEngine = options.viewEngine;
                this.transitionExecutor = new TransitionExecutorModule.TransitionExecutor;
                this._prepareTemplates();
                this._$viewPort.append(this.element());
                this._hideElements(this.element());
                if (options.templateContext) {
                    this._templateContext = options.templateContext;
                    this._proxiedTemplateContextChangedHandler = $.proxy(this._templateContextChangedHandler, this)
                }
            },
            ensureActive: function(targetNode) {
                if (this._disabledState) {
                    return this.enable()
                } else {
                    return this.activate(targetNode)
                }
            },
            activate: function() {
                this._showViewFired = false;
                var $rootElement = this.element();
                this._showElements($rootElement);
                this._attachRefreshViewRequiredHandler();
                return $.Deferred().resolve().promise()
            },
            deactivate: function() {
                this._disabledState = false;
                this._showViewFired = false;
                this._releaseVisibleViews();
                this._hideElements(this.element());
                this._detachRefreshViewRequiredHandler();
                return $.Deferred().resolve().promise()
            },
            enable: function() {
                this._disabledState = false;
                if (!this._showViewFired) {
                    this._notifyShowing()
                }
                this._showViewFired = false;
                return $.Deferred().resolve().promise()
            },
            disable: function() {
                this._disabledState = true;
                this._showViewFired = false;
                this._notifyHidden()
            },
            activeViewInfo: function() {
                return this._visibleViews[this._defaultPaneName]
            },
            _fireViewEvents: function(eventName) {
                var that = this;
                $.each(this._visibleViews, function(index, viewInfo) {
                    that.fireEvent(eventName, [viewInfo])
                })
            },
            _notifyShowing: function() {
                this._fireViewEvents("viewShowing")
            },
            _notifyShown: function() {
                this._fireViewEvents("viewShown")
            },
            _notifyHidden: function() {
                this._fireViewEvents("viewHidden")
            },
            _applyTemplate: function($elements, model) {
                $elements.each(function(i, element) {
                    frameworkUtils.templateProvider.applyTemplate(element, model)
                })
            },
            _releaseVisibleViews: function() {
                var that = this;
                $.each(this._visibleViews, function(index, viewInfo) {
                    that._hideView(viewInfo);
                    that._releaseView(viewInfo)
                });
                this._visibleViews = {}
            },
            _templateContextChangedHandler: function() {
                var that = this;
                $.when.apply($, $.map(that._visibleViews, function(viewInfo) {
                    return that.showView(viewInfo)
                })).then(function() {
                    that._notifyShown()
                })
            },
            _attachRefreshViewRequiredHandler: function() {
                if (this._templateContext) {
                    this._templateContext.on("optionChanged", this._proxiedTemplateContextChangedHandler)
                }
            },
            _detachRefreshViewRequiredHandler: function() {
                if (this._templateContextChanged) {
                    this._templateContext.off("optionChanged", this._proxiedTemplateContextChangedHandler)
                }
            },
            _getPreviousViewInfo: function(viewInfo) {
                return this._visibleViews[this._getViewPaneName(viewInfo.viewTemplateInfo)]
            },
            _prepareTemplates: function() {
                var that = this;
                var $layoutTemplate = that._viewEngine.getLayoutTemplate(this._getLayoutTemplateName());
                that._$layoutTemplate = $layoutTemplate;
                that._$mainLayout = that._createEmptyLayout();
                that._showElements(that._$mainLayout);
                that._applyTemplate(that._$mainLayout, that._layoutModel);
                that._$navigationWidget = that._createNavigationWidget()
            },
            renderNavigation: function(navigationCommands) {
                this._clearNavigationWidget();
                this._renderNavigationImpl(navigationCommands)
            },
            _renderNavigationImpl: function(navigationCommands) {
                this._renderCommands(this._$mainLayout, navigationCommands)
            },
            _createNavigationWidget: function() {
                var result, containers = this._findCommandContainers(this._$mainLayout);
                $.each(containers, function(k, container) {
                    if ("global-navigation" === container.option("id")) {
                        result = container.element();
                        return false
                    }
                });
                return result
            },
            _clearNavigationWidget: function() {
                if (this._$navigationWidget) {
                    this._commandManager.clearContainer(this._$navigationWidget.dxCommandContainer("instance"))
                }
            },
            element: function() {
                return this._$mainLayout
            },
            _getViewFrame: function(viewInfo) {
                return this._$mainLayout
            },
            _getLayoutTemplateName: function() {
                return this.name
            },
            _applyModelToTransitionElements: function($markup, model) {
                var that = this;
                this._getTransitionElements($markup).each(function(i, item) {
                    that._applyTemplate($(item).children(), model)
                })
            },
            _createViewLayoutTemplate: function() {
                var that = this;
                var $viewLayoutTemplate = that._$layoutTemplate.clone();
                this._hideElements($viewLayoutTemplate);
                return $viewLayoutTemplate
            },
            _createEmptyLayout: function() {
                var that = this;
                var $result = that._$layoutTemplate.clone();
                this._hideElements($result);
                this._getTransitionElements($result).empty();
                $result.children(CONTENT_SELECTOR).remove();
                return $result
            },
            _getTransitionElements: function($markup) {
                return $markup.find(TRANSITION_SELECTOR).addBack(TRANSITION_SELECTOR)
            },
            showView: function(viewInfo, direction) {
                direction = direction || "forward";
                var result, that = this,
                    previousViewInfo = that._getPreviousViewInfo(viewInfo),
                    previousViewTemplateId = previousViewInfo === viewInfo ? previousViewInfo.currentViewTemplateId : void 0;
                this._showViewFired = true;
                this._defineCurrentViewTemplateId(viewInfo);
                if (previousViewTemplateId && previousViewTemplateId === viewInfo.currentViewTemplateId && viewInfo === previousViewInfo) {
                    that.fireEvent("viewShowing", [viewInfo, direction]);
                    result = $.Deferred().resolve().promise()
                } else {
                    that._ensureViewRendered(viewInfo);
                    that.fireEvent("viewShowing", [viewInfo, direction]);
                    result = this._showViewImpl(viewInfo, direction, previousViewTemplateId).done(function() {
                        that._onViewShown(viewInfo)
                    })
                }
                return result
            },
            disposeView: function(viewInfo) {
                this._clearRenderResult(viewInfo)
            },
            _clearRenderResult: function(viewInfo) {
                if (viewInfo.renderResult) {
                    viewInfo.renderResult.$markup.remove();
                    viewInfo.renderResult.$viewItems.remove();
                    delete viewInfo.renderResult
                }
            },
            _renderViewImpl: function($viewTemplate, viewInfo) {
                var $viewItems, that = this,
                    allowedChildrenSelector = ".dx-command,.dx-content,script",
                    $layout = this._createViewLayoutTemplate(),
                    isSimplifiedMarkup = true,
                    outOfContentItems = $();
                if (0 === $viewTemplate.children(allowedChildrenSelector).length) {
                    this._viewEngine._wrapViewDefaultContent($viewTemplate)
                }
                $viewItems = $viewTemplate.children();
                this._applyModelToTransitionElements($layout, viewInfo.model);
                this._viewEngine.applyLayout($viewTemplate, $layout);
                $viewItems.each(function(i, item) {
                    var $item = $(item);
                    that._applyTemplate($item, viewInfo.model);
                    if ($item.is(allowedChildrenSelector)) {
                        isSimplifiedMarkup = false
                    } else {
                        outOfContentItems = outOfContentItems.add($item)
                    }
                });
                if (outOfContentItems.length && !isSimplifiedMarkup) {
                    throw errors.Error("E3014", outOfContentItems[0].outerHTML)
                }
                viewInfo.renderResult = viewInfo.renderResult || {};
                viewInfo.renderResult.$viewItems = $viewItems;
                viewInfo.renderResult.$markup = $layout
            },
            _renderCommands: function($markup, commands) {
                var commandContainers = this._findCommandContainers($markup);
                return this._commandManager.renderCommandsToContainers(commands, commandContainers)
            },
            _prepareViewCommands: function(viewInfo) {
                var $viewItems = viewInfo.renderResult.$viewItems,
                    viewCommands = this._commandManager.findCommands($viewItems),
                    commandsToRenderMap = {};
                viewInfo.commands = frameworkUtils.utils.mergeCommands(viewInfo.commands || [], viewCommands);
                viewInfo.commandsToRenderMap = commandsToRenderMap;
                $.each(viewInfo.commands, function(index, command) {
                    var renderStage = command.option("renderStage") || DEFAULT_COMMAND_RENDER_STAGE,
                        targetArray = commandsToRenderMap[renderStage] = commandsToRenderMap[renderStage] || [];
                    targetArray.push(command)
                })
            },
            _applyViewCommands: function(viewInfo, renderStage) {
                renderStage = renderStage || DEFAULT_COMMAND_RENDER_STAGE;
                var result, commandsToRender = viewInfo.commandsToRenderMap[renderStage],
                    $markup = viewInfo.renderResult.$markup;
                if (commandsToRender) {
                    result = this._renderCommands($markup, commandsToRender);
                    delete viewInfo.commandsToRenderMap[renderStage]
                } else {
                    result = $.Deferred().resolve().promise()
                }
                return result
            },
            _findCommandContainers: function($markup) {
                return domUtils.createComponents($markup, ["dxCommandContainer"])
            },
            _defineCurrentViewTemplateId: function(viewInfo) {
                var viewTemplateInstance = viewInfo.$viewTemplate ? viewInfo.$viewTemplate.dxView("instance") : this._viewEngine.getViewTemplateInfo(viewInfo.viewName),
                    currentViewTemplateId = viewTemplateInstance.getId();
                viewInfo.currentViewTemplateId = currentViewTemplateId
            },
            _ensureViewRendered: function(viewInfo) {
                var $cachedMarkup = viewInfo.renderResult && viewInfo.renderResult.markupCache[viewInfo.currentViewTemplateId];
                if ($cachedMarkup) {
                    viewInfo.renderResult.$markup = $cachedMarkup
                } else {
                    this._renderView(viewInfo);
                    viewInfo.renderResult.markupCache = viewInfo.renderResult.markupCache || {};
                    viewInfo.renderResult.markupCache[viewInfo.currentViewTemplateId] = viewInfo.renderResult.$markup
                }
            },
            _renderView: function(viewInfo) {
                var $viewTemplate = viewInfo.$viewTemplate || this._viewEngine.getViewTemplate(viewInfo.viewName);
                this._renderViewImpl($viewTemplate, viewInfo);
                this._prepareViewCommands(viewInfo);
                this._applyViewCommands(viewInfo, "onViewRendering");
                this._appendViewToLayout(viewInfo);
                $viewTemplate.remove();
                this._onRenderComplete(viewInfo);
                this.fireEvent("viewRendered", [viewInfo])
            },
            _prepareTransition: function($element, targetPlaceholderName) {
                if (0 === $element.children(".dx-content").length) {
                    $element.wrapInner("<div>");
                    $element.children().dxContent({
                        targetPlaceholder: targetPlaceholderName
                    })
                }
            },
            _appendViewToLayout: function(viewInfo) {
                var that = this,
                    $viewFrame = that._getViewFrame(viewInfo),
                    $markup = viewInfo.renderResult.$markup,
                    $transitionContentElements = $(),
                    animationItems = [];
                $.each($markup.find(".dx-content-placeholder"), function(index, el) {
                    that._prepareTransition($(el), $(el).attr("data-dx-content-placeholder-name"))
                });
                $.each(that._getTransitionElements($viewFrame), function(index, transitionElement) {
                    var $transition = $(transitionElement),
                        $viewElement = $markup.find(transitionSelector($transition.attr("data-dx-transition-name"))).children(),
                        animationItem = {
                            $element: $viewElement,
                            animation: $transition.attr("data-dx-transition-type")
                        };
                    animationItems.push(animationItem);
                    $transition.append($viewElement);
                    that._showViewElements($viewElement);
                    domUtils.triggerShownEvent($viewElement);
                    $transitionContentElements = $transitionContentElements.add($viewElement)
                });
                that._$mainLayout.append(viewInfo.renderResult.$viewItems.filter(".dx-command"));
                $markup.remove();
                viewInfo.renderResult.$markup = $transitionContentElements;
                viewInfo.renderResult.animationItems = animationItems
            },
            _onRenderComplete: function(viewInfo) {},
            _onViewShown: function(viewInfo) {
                $(document).trigger("dx.viewchanged")
            },
            _enter: function(animationItems, animationModifier) {
                var transitionExecutor = this.transitionExecutor;
                $.each(animationItems, function(index, item) {
                    transitionExecutor.enter(item.$element, item.animation, animationModifier)
                })
            },
            _leave: function(animationItems, animationModifier) {
                var transitionExecutor = this.transitionExecutor;
                $.each(animationItems, function(index, item) {
                    transitionExecutor.leave(item.$element, item.animation, animationModifier)
                })
            },
            _doTransition: function(oldViewInfo, newViewInfo, animationModifier) {
                if (oldViewInfo) {
                    this._leave(oldViewInfo.renderResult.animationItems, animationModifier)
                }
                this._enter(newViewInfo.renderResult.animationItems, animationModifier);
                this._showView(newViewInfo);
                return this.transitionExecutor.start()
            },
            _showViewImpl: function(viewInfo, direction, previousViewTemplateId) {
                var result, that = this,
                    previousViewInfo = this._getPreviousViewInfo(viewInfo),
                    animationModifier = {
                        direction: direction
                    };
                if (previousViewInfo === viewInfo) {
                    previousViewInfo = void 0
                }
                if (!previousViewInfo) {
                    animationModifier.duration = 0;
                    animationModifier.delay = 0
                }
                result = that._doTransition(previousViewInfo, viewInfo, animationModifier).then(function() {
                    return that._changeView(viewInfo, previousViewTemplateId)
                });
                return result
            },
            _releaseView: function(viewInfo) {
                this.fireEvent("viewReleased", [viewInfo])
            },
            _getReadyForRenderDeferredItems: function(viewInfo) {
                return $.Deferred().resolve().promise()
            },
            _changeView: function(viewInfo, previousViewTemplateId) {
                var that = this;
                if (previousViewTemplateId) {
                    that._hideView(viewInfo, previousViewTemplateId)
                } else {
                    var previousViewInfo = that._getPreviousViewInfo(viewInfo);
                    if (previousViewInfo && previousViewInfo !== viewInfo) {
                        that._hideView(previousViewInfo);
                        that._releaseView(previousViewInfo)
                    }
                    this._visibleViews[this._getViewPaneName(viewInfo.viewTemplateInfo)] = viewInfo
                }
                this._subscribeToDeferredItems(viewInfo);
                return this._getReadyForRenderDeferredItems(viewInfo).then(function() {
                    return that._applyViewCommands(viewInfo)
                }).then(function() {
                    return that._renderDeferredItems(viewInfo.renderResult.$markup)
                })
            },
            _subscribeToDeferredItems: function(viewInfo) {
                var that = this,
                    $markup = viewInfo.renderResult.$markup;
                $markup.find(PENDING_RENDERING_SELECTOR).add($markup.filter(PENDING_RENDERING_SELECTOR)).each(function() {
                    var eventData = {
                        viewInfo: viewInfo,
                        context: that
                    };
                    $(this).on(CONTENT_RENDERED_EVENT_NAME, eventData, that._onDeferredContentRendered)
                })
            },
            _onDeferredContentRendered: function(event) {
                var $element = $(event.target),
                    viewInfo = event.data.viewInfo,
                    that = event.data.context;
                $element.off(CONTENT_RENDERED_EVENT_NAME, that._onDeferredContentRendered);
                that._renderCommands($element, viewInfo.commands)
            },
            _renderDeferredItems: function($items) {
                var that = this,
                    result = $.Deferred();
                var $pendingItem = $items.find(PENDING_RENDERING_MANUAL_SELECTOR).add($items.filter(PENDING_RENDERING_MANUAL_SELECTOR)).first();
                if ($pendingItem.length) {
                    var render = $pendingItem.data("dx-render-delegate");
                    commonUtils.executeAsync(function() {
                        render().then(function() {
                            return that._renderDeferredItems($items)
                        }).then(function() {
                            result.resolve()
                        })
                    })
                } else {
                    result.resolve()
                }
                return result.promise()
            },
            _getViewPaneName: function(viewTemplateInfo) {
                return this._defaultPaneName
            },
            _hideElements: function($elements) {
                $elements.addClass("dx-fast-hidden")
            },
            _showElements: function($elements) {
                $elements.removeClass("dx-fast-hidden")
            },
            _hideViewElements: function($elements) {
                this._patchIDs($elements);
                this._disableInputs($elements);
                $elements.removeClass("dx-active-view").addClass("dx-inactive-view")
            },
            _hideView: function(viewInfo, templateId) {
                if (viewInfo.renderResult) {
                    var $markupToHide = void 0 === templateId ? viewInfo.renderResult.$markup : viewInfo.renderResult.markupCache[templateId];
                    this._hideViewElements($markupToHide);
                    this.fireEvent("viewHidden", [viewInfo])
                }
            },
            _showViewElements: function($elements) {
                this._unpatchIDs($elements);
                this._enableInputs($elements);
                $elements.removeClass("dx-inactive-view").addClass("dx-active-view");
                this._skipAnimation($elements)
            },
            _showView: function(viewInfo) {
                if (viewInfo.renderResult) {
                    this._showViewElements(viewInfo.renderResult.$markup)
                }
            },
            _skipAnimation: function($elements) {
                $elements.addClass("dx-skip-animation");
                for (var i = 0; i < $elements.length; i++) {
                    $elements.eq(i).css("transform")
                }
                $elements.removeClass("dx-skip-animation")
            },
            _patchIDs: function($markup) {
                this._processIDs($markup, function(id) {
                    var result = id;
                    if (id.indexOf(HIDDEN_BAG_ID) === -1) {
                        result = HIDDEN_BAG_ID + "-" + id
                    }
                    return result
                })
            },
            _unpatchIDs: function($markup) {
                this._processIDs($markup, function(id) {
                    var result = id;
                    if (0 === id.indexOf(HIDDEN_BAG_ID)) {
                        result = id.substr(HIDDEN_BAG_ID.length + 1)
                    }
                    return result
                })
            },
            _processIDs: function($markup, process) {
                var elementsWithIds = $markup.find("[id]");
                $.each(elementsWithIds, function(index, element) {
                    var $el = $(element),
                        id = $el.attr("id");
                    $el.attr("id", process(id))
                })
            },
            _enableInputs: function($markup) {
                var $inputs = $markup.find(":input[data-disabled=true]");
                $.each($inputs, function(index, input) {
                    $(input).removeAttr("disabled").removeAttr("data-disabled")
                })
            },
            _disableInputs: function($markup) {
                var $inputs = $markup.find(":input:not([disabled], [disabled=true])");
                $.each($inputs, function(index, input) {
                    $(input).attr({
                        disabled: true,
                        "data-disabled": true
                    })
                })
            }
        }).include(EventsMixin);
        layoutSets.default = layoutSets.default || [];
        layoutSets.default.push({
            controller: new DefaultLayoutController
        });
        exports.DefaultLayoutController = DefaultLayoutController;
        exports.layoutSets = layoutSets
    },
    /*!******************************!*\
      !*** ./Scripts/ui/themes.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ./widget/ui.errors */ 10),
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            viewPortUtils = __webpack_require__( /*! ../core/utils/view_port */ 42),
            viewPort = viewPortUtils.value,
            viewPortChanged = viewPortUtils.changeCallback;
        var DX_LINK_SELECTOR = "link[rel=dx-theme]",
            THEME_ATTR = "data-theme",
            ACTIVE_ATTR = "data-active",
            DX_HAIRLINES_CLASS = "dx-hairlines";
        var context, $activeThemeLink, knownThemes, currentThemeName, pendingThemeName;
        var THEME_MARKER_PREFIX = "dx.";

        function readThemeMarker() {
            var result, element = $("<div></div>", context).addClass("dx-theme-marker").appendTo(context.documentElement);
            try {
                result = element.css("font-family");
                if (!result) {
                    return null
                }
                result = result.replace(/["']/g, "");
                if (result.substr(0, THEME_MARKER_PREFIX.length) !== THEME_MARKER_PREFIX) {
                    return null
                }
                return result.substr(THEME_MARKER_PREFIX.length)
            } finally {
                element.remove()
            }
        }

        function waitForThemeLoad(themeName, callback) {
            var timerId, waitStartTime;
            pendingThemeName = themeName;

            function handleLoaded() {
                pendingThemeName = null;
                callback()
            }
            if (isPendingThemeLoaded()) {
                handleLoaded()
            } else {
                waitStartTime = $.now();
                timerId = setInterval(function() {
                    var isLoaded = isPendingThemeLoaded(),
                        isTimeout = !isLoaded && $.now() - waitStartTime > 15e3;
                    if (isTimeout) {
                        errors.log("W0004", pendingThemeName)
                    }
                    if (isLoaded || isTimeout) {
                        clearInterval(timerId);
                        handleLoaded()
                    }
                }, 10)
            }
        }

        function isPendingThemeLoaded() {
            return !pendingThemeName || readThemeMarker() === pendingThemeName
        }

        function processMarkup() {
            var $allThemeLinks = $(DX_LINK_SELECTOR, context);
            if (!$allThemeLinks.length) {
                return
            }
            knownThemes = {};
            $activeThemeLink = $(domUtils.createMarkupFromString("<link rel=stylesheet>"), context);
            $allThemeLinks.each(function() {
                var link = $(this, context),
                    fullThemeName = link.attr(THEME_ATTR),
                    url = link.attr("href"),
                    isActive = "true" === link.attr(ACTIVE_ATTR);
                knownThemes[fullThemeName] = {
                    url: url,
                    isActive: isActive
                }
            });
            $allThemeLinks.last().after($activeThemeLink);
            $allThemeLinks.remove()
        }

        function resolveFullThemeName(desiredThemeName) {
            var desiredThemeParts = desiredThemeName.split("."),
                result = null;
            if (knownThemes) {
                $.each(knownThemes, function(knownThemeName, themeData) {
                    var knownThemeParts = knownThemeName.split(".");
                    if (knownThemeParts[0] !== desiredThemeParts[0]) {
                        return
                    }
                    if (desiredThemeParts[1] && desiredThemeParts[1] !== knownThemeParts[1]) {
                        return
                    }
                    if (desiredThemeParts[2] && desiredThemeParts[2] !== knownThemeParts[2]) {
                        return
                    }
                    if (!result || themeData.isActive) {
                        result = knownThemeName
                    }
                    if (themeData.isActive) {
                        return false
                    }
                })
            }
            return result
        }

        function initContext(newContext) {
            try {
                if (newContext !== context) {
                    knownThemes = null
                }
            } catch (x) {
                knownThemes = null
            }
            context = newContext
        }

        function init(options) {
            options = options || {};
            initContext(options.context || document);
            processMarkup();
            currentThemeName = void 0;
            current(options)
        }

        function current(options) {
            if (!arguments.length) {
                currentThemeName = currentThemeName || readThemeMarker();
                return currentThemeName
            }
            detachCssClasses(viewPort(), currentThemeName);
            options = options || {};
            if ("string" === typeof options) {
                options = {
                    theme: options
                }
            }
            var currentThemeData, isAutoInit = options._autoInit,
                loadCallback = options.loadCallback;
            currentThemeName = options.theme || currentThemeName;
            if (isAutoInit && !currentThemeName) {
                currentThemeName = themeNameFromDevice(devices.current())
            }
            currentThemeName = resolveFullThemeName(currentThemeName);
            if (currentThemeName) {
                currentThemeData = knownThemes[currentThemeName]
            }
            if (currentThemeData) {
                $activeThemeLink.attr("href", knownThemes[currentThemeName].url);
                if (loadCallback) {
                    waitForThemeLoad(currentThemeName, loadCallback)
                } else {
                    if (pendingThemeName) {
                        pendingThemeName = currentThemeName
                    }
                }
            } else {
                if (isAutoInit) {
                    if (loadCallback) {
                        loadCallback()
                    }
                } else {
                    throw errors.Error("E0021", currentThemeName)
                }
            }
            attachCssClasses(viewPortUtils.originalViewPort(), currentThemeName)
        }

        function themeNameFromDevice(device) {
            var themeName = device.platform;
            var majorVersion = device.version && device.version[0];
            switch (themeName) {
                case "ios":
                    themeName += "7";
                    break;
                case "android":
                    themeName += "5";
                    break;
                case "win":
                    themeName += majorVersion && 8 === majorVersion ? "8" : "10"
            }
            return themeName
        }

        function getCssClasses(themeName) {
            themeName = themeName || current();
            var result = [],
                themeNameParts = themeName && themeName.split(".");
            if (themeNameParts) {
                result.push("dx-theme-" + themeNameParts[0], "dx-theme-" + themeNameParts[0] + "-typography");
                if (themeNameParts.length > 1) {
                    result.push("dx-color-scheme-" + themeNameParts[1])
                }
            }
            return result
        }
        var themeClasses;

        function attachCssClasses(element, themeName) {
            themeClasses = getCssClasses(themeName).join(" ");
            $(element).addClass(themeClasses);
            var activateHairlines = function() {
                var pixelRatio = window.devicePixelRatio;
                if (!pixelRatio || pixelRatio < 2) {
                    return
                }
                var $tester = $("<div>");
                $tester.css("border", ".5px solid transparent");
                $("body").append($tester);
                if (1 === $tester.outerHeight()) {
                    $(element).addClass(DX_HAIRLINES_CLASS);
                    themeClasses += " " + DX_HAIRLINES_CLASS
                }
                $tester.remove()
            };
            activateHairlines()
        }

        function detachCssClasses(element, themeName) {
            $(element).removeClass(themeClasses)
        }
        $.holdReady(true);
        init({
            _autoInit: true,
            loadCallback: function() {
                $.holdReady(false)
            }
        });
        $(function() {
            if ($(DX_LINK_SELECTOR, context).length) {
                throw errors.Error("E0022")
            }
        });
        viewPortChanged.add(function(viewPort, prevViewPort) {
            detachCssClasses(prevViewPort);
            attachCssClasses(viewPort)
        });
        devices.changed.add(function() {
            init({
                _autoInit: true
            })
        });
        exports.current = current;
        exports.init = init;
        exports.attachCssClasses = attachCssClasses;
        exports.detachCssClasses = detachCssClasses;
        exports.themeNameFromDevice = themeNameFromDevice;
        exports.waitForThemeLoad = waitForThemeLoad;
        exports.resetTheme = function() {
            $activeThemeLink && $activeThemeLink.attr("href", "about:blank");
            currentThemeName = null;
            pendingThemeName = null
        }
    },
    /*!****************************************!*\
      !*** ./Scripts/integration/angular.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var angular = __webpack_require__( /*! angular */ 145);
        if (angular) {
            __webpack_require__( /*! ./angular/component_registrator */ 146);
            __webpack_require__( /*! ./angular/event_registrator */ 168);
            __webpack_require__( /*! ./angular/components */ 169);
            __webpack_require__( /*! ./angular/action_executors */ 170)
        }
    },
    /*!*********************************!*\
      !*** external "window.angular" ***!
      \*********************************/
    function(module, exports) {
        module.exports = window.angular
    },
    /*!**************************************************************!*\
      !*** ./Scripts/integration/angular/component_registrator.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            Locker = __webpack_require__( /*! ../../core/utils/locker */ 113),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            Widget = __webpack_require__( /*! ../../ui/widget/ui.widget */ 89),
            Editor = __webpack_require__( /*! ../../ui/editor/editor */ 107),
            NgTemplateProvider = __webpack_require__( /*! ./template_provider */ 147),
            ngModule = __webpack_require__( /*! ./module */ 150),
            removeEvent = __webpack_require__( /*! ../../core/remove_event */ 33),
            CollectionWidget = __webpack_require__( /*! ../../ui/collection/ui.collection_widget.edit */ 151),
            compileSetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileSetter,
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            extendFromObject = __webpack_require__( /*! ../../core/utils/object */ 37).extendFromObject;
        var ITEM_ALIAS_ATTRIBUTE_NAME = "dxItemAlias",
            DEFAULT_MODEL_ALIAS = "dxTemplateModel",
            MODEL_IS_PRIMITIVE_FLAG_NAME = "dxTemplateModelIsPrimitive",
            SKIP_APPLY_ACTION_CATEGORIES = ["rendering"];
        var safeApply = function(func, scope) {
            if (scope.$root.$$phase) {
                return func(scope)
            } else {
                return scope.$apply(function() {
                    return func(scope)
                })
            }
        };
        var ComponentBuilder = Class.inherit({
            ctor: function(options) {
                this._componentDisposing = $.Callbacks();
                this._optionChangedCallbacks = $.Callbacks();
                this._ngLocker = new Locker;
                this._scope = options.scope;
                this._$element = options.$element;
                this._$templates = options.$templates;
                this._componentClass = options.componentClass;
                this._parse = options.parse;
                this._compile = options.compile;
                this._itemAlias = options.itemAlias;
                this._transcludeFn = options.transcludeFn;
                this._digestCallbacks = options.dxDigestCallbacks;
                this._normalizeOptions(options.ngOptions);
                this._initComponentBindings();
                this._initComponent(this._scope);
                if (options.ngOptions) {
                    this._triggerResizeEvent()
                } else {
                    this._addOptionsStringWatcher(options.ngOptionsString)
                }
            },
            _addOptionsStringWatcher: function(optionsString) {
                var that = this;
                var clearOptionsStringWatcher = that._scope.$watch(optionsString, function(newOptions) {
                    if (!newOptions) {
                        return
                    }
                    clearOptionsStringWatcher();
                    that._normalizeOptions(newOptions);
                    that._initComponentBindings();
                    that._component.option(that._evalOptions(that._scope));
                    that._triggerResizeEvent()
                });
                that._componentDisposing.add(clearOptionsStringWatcher)
            },
            _normalizeOptions: function(options) {
                var that = this;
                that._ngOptions = extendFromObject({}, options);
                if (!options) {
                    return
                }
                if (options.bindingOptions) {
                    $.each(options.bindingOptions, function(key, value) {
                        if ("string" === $.type(value)) {
                            that._ngOptions.bindingOptions[key] = {
                                dataPath: value
                            }
                        }
                    })
                }
            },
            _triggerResizeEvent: function() {
                var that = this;
                clearTimeout(that._shownEventTimer);
                that._shownEventTimer = setTimeout(function() {
                    domUtils.triggerResizeEvent(that._$element)
                });
                that._componentDisposing.add(function() {
                    clearTimeout(that._shownEventTimer)
                })
            },
            _initComponent: function(scope) {
                this._component = new this._componentClass(this._$element, this._evalOptions(scope));
                this._component._isHidden = true;
                this._handleDigestPhase()
            },
            _handleDigestPhase: function() {
                var that = this,
                    beginUpdate = function() {
                        that._component.beginUpdate()
                    },
                    endUpdate = function() {
                        that._component.endUpdate()
                    };
                that._digestCallbacks.begin.add(beginUpdate);
                that._digestCallbacks.end.add(endUpdate);
                that._componentDisposing.add(function() {
                    that._digestCallbacks.begin.remove(beginUpdate);
                    that._digestCallbacks.end.remove(endUpdate)
                })
            },
            _initComponentBindings: function() {
                var that = this,
                    optionDependencies = {};
                if (!that._ngOptions.bindingOptions) {
                    return
                }
                $.each(that._ngOptions.bindingOptions, function(optionPath, value) {
                    var prevWatchMethod, clearWatcher, separatorIndex = optionPath.search(/\[|\./),
                        optionForSubscribe = separatorIndex > -1 ? optionPath.substring(0, separatorIndex) : optionPath,
                        valuePath = value.dataPath,
                        deepWatch = true,
                        forcePlainWatchMethod = false;
                    if (void 0 !== value.deep) {
                        forcePlainWatchMethod = deepWatch = !!value.deep
                    }
                    if (!optionDependencies[optionForSubscribe]) {
                        optionDependencies[optionForSubscribe] = {}
                    }
                    optionDependencies[optionForSubscribe][optionPath] = valuePath;
                    var watchCallback = function(newValue, oldValue) {
                        if (that._ngLocker.locked(optionPath)) {
                            return
                        }
                        that._ngLocker.obtain(optionPath);
                        that._component.option(optionPath, newValue);
                        updateWatcher();
                        if (that._component._optionValuesEqual(optionPath, oldValue, newValue) && that._ngLocker.locked(optionPath)) {
                            that._ngLocker.release(optionPath)
                        }
                    };
                    var updateWatcher = function() {
                        var watchMethod = $.isArray(that._scope.$eval(valuePath)) && !forcePlainWatchMethod ? "$watchCollection" : "$watch";
                        if (prevWatchMethod !== watchMethod) {
                            if (clearWatcher) {
                                clearWatcher()
                            }
                            clearWatcher = that._scope[watchMethod](valuePath, watchCallback, deepWatch);
                            prevWatchMethod = watchMethod
                        }
                    };
                    updateWatcher();
                    that._componentDisposing.add(clearWatcher)
                });
                that._optionChangedCallbacks.add(function(args) {
                    var optionName = args.name,
                        fullName = args.fullName,
                        component = args.component;
                    if (that._ngLocker.locked(fullName)) {
                        that._ngLocker.release(fullName);
                        return
                    }
                    if (!optionDependencies || !optionDependencies[optionName]) {
                        return
                    }
                    that._ngLocker.obtain(fullName);
                    safeApply(function(scope) {
                        $.each(optionDependencies[optionName], function(optionPath, valuePath) {
                            var value = component.option(optionPath);
                            that._parse(valuePath).assign(that._scope, value);
                            var scopeValue = that._parse(valuePath)(that._scope);
                            if (scopeValue !== value) {
                                that._component.option(optionPath, scopeValue)
                            }
                        })
                    }, that._scope);
                    var releaseOption = function() {
                        if (that._ngLocker.locked(fullName)) {
                            that._ngLocker.release(fullName)
                        }
                        that._digestCallbacks.end.remove(releaseOption)
                    };
                    that._digestCallbacks.end.add(releaseOption)
                })
            },
            _compilerByTemplate: function(template) {
                var that = this,
                    scopeItemsPath = this._getScopeItemsPath();
                return function(options) {
                    var $resultMarkup = $(template).clone(),
                        dataIsScope = options.model && options.model.constructor === that._scope.$root.constructor,
                        templateScope = dataIsScope ? options.model : options.noModel ? that._scope : that._createScopeWithData(options.model);
                    if (scopeItemsPath) {
                        that._synchronizeScopes(templateScope, scopeItemsPath, options.index)
                    }
                    $resultMarkup.appendTo(options.container).on("$destroy", function() {
                        var destroyAlreadyCalled = !templateScope.$parent;
                        if (destroyAlreadyCalled) {
                            return
                        }
                        templateScope.$destroy()
                    });
                    that._applyAsync(that._compile($resultMarkup, that._transcludeFn), templateScope);
                    return $resultMarkup
                }
            },
            _applyAsync: function(func, scope) {
                var that = this;
                func(scope);
                if (!scope.$root.$$phase) {
                    clearTimeout(that._renderingTimer);
                    that._renderingTimer = setTimeout(function() {
                        scope.$apply()
                    });
                    that._componentDisposing.add(function() {
                        clearTimeout(that._renderingTimer)
                    })
                }
            },
            _getScopeItemsPath: function() {
                if (this._componentClass.subclassOf(CollectionWidget) && this._ngOptions.bindingOptions && this._ngOptions.bindingOptions.items) {
                    return this._ngOptions.bindingOptions.items.dataPath
                }
            },
            _createScopeWithData: function(data) {
                var newScope = this._scope.$new(),
                    modelIsPrimitive = data && "object" !== typeof data && "function" !== typeof data;
                newScope[DEFAULT_MODEL_ALIAS] = data;
                newScope[MODEL_IS_PRIMITIVE_FLAG_NAME] = !!modelIsPrimitive;
                if (this._itemAlias) {
                    newScope[this._itemAlias] = data
                }
                return newScope
            },
            _synchronizeScopes: function(itemScope, parentPrefix, itemIndex) {
                var that = this,
                    fieldsToSynchronize = [DEFAULT_MODEL_ALIAS];
                if (that._itemAlias && "object" !== typeof itemScope[that._itemAlias]) {
                    fieldsToSynchronize.push(that._itemAlias)
                }
                $.each(fieldsToSynchronize, function(i, fieldPath) {
                    that._synchronizeScopeField({
                        parentScope: that._scope,
                        childScope: itemScope,
                        fieldPath: fieldPath,
                        parentPrefix: parentPrefix,
                        itemIndex: itemIndex
                    })
                })
            },
            _synchronizeScopeField: function(args) {
                var parentScope = args.parentScope,
                    childScope = args.childScope,
                    fieldPath = args.fieldPath,
                    parentPrefix = args.parentPrefix,
                    itemIndex = args.itemIndex;
                var optionOuterPath, innerPathSuffix = fieldPath === (this._itemAlias || DEFAULT_MODEL_ALIAS) ? "" : "." + fieldPath,
                    collectionField = void 0 !== itemIndex,
                    optionOuterBag = [parentPrefix];
                if (collectionField) {
                    optionOuterBag.push("[", itemIndex, "]")
                }
                optionOuterBag.push(innerPathSuffix);
                optionOuterPath = optionOuterBag.join("");
                var clearParentWatcher = parentScope.$watch(optionOuterPath, function(newValue, oldValue) {
                    if (newValue !== oldValue) {
                        compileSetter(fieldPath)(childScope, newValue)
                    }
                });
                var clearItemWatcher = childScope.$watch(fieldPath, function(newValue, oldValue) {
                    if (newValue !== oldValue) {
                        if (collectionField && !compileGetter(parentPrefix)(parentScope)[itemIndex]) {
                            clearItemWatcher();
                            return
                        }
                        compileSetter(optionOuterPath)(parentScope, newValue)
                    }
                });
                this._componentDisposing.add([clearParentWatcher, clearItemWatcher])
            },
            _evalOptions: function(scope) {
                var result = extendFromObject({}, this._ngOptions);
                delete result.bindingOptions;
                if (this._ngOptions.bindingOptions) {
                    $.each(this._ngOptions.bindingOptions, function(key, value) {
                        result[key] = scope.$eval(value.dataPath)
                    })
                }
                result._optionChangedCallbacks = this._optionChangedCallbacks;
                result._disposingCallbacks = this._componentDisposing;
                result.templateProvider = NgTemplateProvider;
                result.templateCompiler = $.proxy(function($template) {
                    return this._compilerByTemplate($template)
                }, this);
                result.onActionCreated = function(component, action, config) {
                    if (config && $.inArray(config.category, SKIP_APPLY_ACTION_CATEGORIES) > -1) {
                        return action
                    }
                    var wrappedAction = function() {
                        var that = this,
                            args = arguments;
                        if (!scope || !scope.$root || scope.$root.$$phase) {
                            return action.apply(that, args)
                        }
                        return safeApply(function() {
                            return action.apply(that, args)
                        }, scope)
                    };
                    return wrappedAction
                };
                result.nestedComponentOptions = function(component) {
                    return {
                        templatesRenderAsynchronously: true,
                        templateCompiler: component.option("templateCompiler"),
                        modelByElement: component.option("modelByElement"),
                        onActionCreated: component.option("onActionCreated"),
                        nestedComponentOptions: component.option("nestedComponentOptions")
                    }
                };
                result.templatesRenderAsynchronously = true;
                result.watchMethod = function(watchValue, callback, element) {
                    var disposeWatcher = scope.$watch(watchValue, function(oldValue, newValue) {
                        if (oldValue !== newValue) {
                            disposeWatcher();
                            callback()
                        }
                    }, true);
                    $(element).on(removeEvent, function() {
                        disposeWatcher()
                    })
                };
                result.modelByElement = function() {
                    return scope
                };
                return result
            }
        });
        ComponentBuilder = ComponentBuilder.inherit({
            ctor: function(options) {
                this._componentName = options.componentName;
                this._ngModel = options.ngModel;
                this._ngModelController = options.ngModelController;
                this.callBase.apply(this, arguments)
            },
            _isNgModelRequired: function() {
                return this._componentClass.subclassOf(Editor) && this._ngModel
            },
            _initComponentBindings: function() {
                this.callBase.apply(this, arguments);
                this._initNgModelBinding()
            },
            _initNgModelBinding: function() {
                if (!this._isNgModelRequired()) {
                    return
                }
                var that = this;
                var clearNgModelWatcher = this._scope.$watch(this._ngModel, function(newValue, oldValue) {
                    if (that._ngLocker.locked(that._ngModelOption())) {
                        return
                    }
                    if (newValue === oldValue) {
                        return
                    }
                    that._component.option(that._ngModelOption(), newValue)
                });
                that._optionChangedCallbacks.add(function(args) {
                    that._ngLocker.obtain(that._ngModelOption());
                    try {
                        if (args.name !== that._ngModelOption()) {
                            return
                        }
                        that._ngModelController.$setViewValue(args.value)
                    } finally {
                        that._ngLocker.release(that._ngModelOption())
                    }
                });
                this._componentDisposing.add(clearNgModelWatcher)
            },
            _ngModelOption: function() {
                if ($.inArray(this._componentName, ["dxFileUploader", "dxTagBox"]) > -1) {
                    return "values"
                }
                return "value"
            },
            _evalOptions: function() {
                if (!this._isNgModelRequired()) {
                    return this.callBase.apply(this, arguments)
                }
                var result = this.callBase.apply(this, arguments);
                result[this._ngModelOption()] = this._parse(this._ngModel)(this._scope);
                return result
            }
        });
        var registeredComponents = {};
        var registerComponentDirective = function(name) {
            var priority = "dxValidator" !== name ? 1 : 10;
            ngModule.directive(name, ["$compile", "$parse", "dxDigestCallbacks", function($compile, $parse, dxDigestCallbacks) {
                return {
                    restrict: "A",
                    require: "^?ngModel",
                    priority: priority,
                    compile: function($element) {
                        var componentClass = registeredComponents[name],
                            $content = componentClass.subclassOf(Widget) ? $element.contents().detach() : null;
                        return function(scope, $element, attrs, ngModelController, transcludeFn) {
                            $element.append($content);
                            safeApply(function() {
                                new ComponentBuilder({
                                    componentClass: componentClass,
                                    componentName: name,
                                    compile: $compile,
                                    parse: $parse,
                                    $element: $element,
                                    scope: scope,
                                    ngOptionsString: attrs[name],
                                    ngOptions: attrs[name] ? scope.$eval(attrs[name]) : {},
                                    ngModel: attrs.ngModel,
                                    ngModelController: ngModelController,
                                    transcludeFn: transcludeFn,
                                    itemAlias: attrs[ITEM_ALIAS_ATTRIBUTE_NAME],
                                    dxDigestCallbacks: dxDigestCallbacks
                                })
                            }, scope)
                        }
                    }
                }
            }])
        };
        registerComponent.callbacks.add(function(name, componentClass) {
            if (!registeredComponents[name]) {
                registerComponentDirective(name)
            }
            registeredComponents[name] = componentClass
        })
    },
    /*!**********************************************************!*\
      !*** ./Scripts/integration/angular/template_provider.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            templateProvider = __webpack_require__( /*! ../../ui/widget/jquery.template_provider */ 94),
            NgTemplate = __webpack_require__( /*! ./template */ 148),
            defaultTemplates = __webpack_require__( /*! ./default_templates */ 149);
        var NgTemplateProvider = templateProvider.constructor.inherit({
            createTemplate: function(element, owner) {
                return new NgTemplate(element, owner)
            },
            getTemplates: function(widget) {
                var templateCompiler = widget.option("templateCompiler"),
                    templates = this.callBase.apply(this, arguments);
                $.each(templates, function(_, template) {
                    template.setCompiler && template.setCompiler(templateCompiler)
                });
                return templates
            },
            _templatesForWidget: function(widgetName) {
                var templateGenerators = defaultTemplates[widgetName];
                if (!templateGenerators) {
                    return this.callBase(widgetName)
                }
                var templates = {};
                $.each(templateGenerators, function(name, generator) {
                    var $markup = domUtils.createMarkupFromString(generator());
                    templates[name] = new NgTemplate($markup.wrap(), ngTemplateProvider)
                });
                return templates
            }
        });
        var ngTemplateProvider = new NgTemplateProvider;
        module.exports = ngTemplateProvider
    },
    /*!*************************************************!*\
      !*** ./Scripts/integration/angular/template.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            TemplateBase = __webpack_require__( /*! ../../ui/widget/ui.template_base */ 90),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50);
        var NgTemplate = TemplateBase.inherit({
            ctor: function(element, owner) {
                this.callBase(element, owner);
                this.setCompiler(this._getParentTemplateCompiler())
            },
            _getParentTemplateCompiler: function() {
                var templateCompiler = null,
                    owner = this.owner();
                while (!templateCompiler && owner) {
                    templateCompiler = $.isFunction(owner.option) ? owner.option("templateCompiler") : null;
                    owner = $.isFunction(owner.owner) ? owner.owner() : null
                }
                return templateCompiler
            },
            _renderCore: function(options) {
                var compiledTemplate = this._compiledTemplate,
                    result = $.isFunction(compiledTemplate) ? compiledTemplate(options) : compiledTemplate;
                return result
            },
            setCompiler: function(templateCompiler) {
                if (!templateCompiler) {
                    return
                }
                this._compiledTemplate = templateCompiler(domUtils.normalizeTemplateElement(this._element))
            }
        });
        module.exports = NgTemplate
    },
    /*!**********************************************************!*\
      !*** ./Scripts/integration/angular/default_templates.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var TEMPLATE_GENERATORS = {};
        var TEMPLATE_WRAPPER_CLASS = "dx-template-wrapper";
        var baseElements = {
            container: function() {
                return $("<div>").addClass(TEMPLATE_WRAPPER_CLASS)
            },
            html: function() {
                return $("<div>").attr("ng-if", "dxTemplateModel.html").attr("ng-bind-html", "dxTemplateModel.html")
            },
            text: function(element) {
                element = element || "<div>";
                return $(element).attr("ng-if", "dxTemplateModel.text").attr("ng-if", "!dxTemplateModel.html").attr("ng-bind", "dxTemplateModel.text")
            },
            primitive: function() {
                return $("<div>").attr("ng-if", "dxTemplateModelIsPrimitive").attr("ng-bind", "'' + dxTemplateModel")
            }
        };
        var emptyTemplate = function() {
            return $()
        };
        TEMPLATE_GENERATORS.CollectionWidget = {
            item: function() {
                return baseElements.container().append(baseElements.html()).append(baseElements.text()).append(baseElements.primitive())
            },
            itemFrame: function() {
                var $container = $("<div>").attr("ng-class", "{ 'dx-state-invisible': !dxTemplateModel.visible && dxTemplateModel.visible != undefined, 'dx-state-disabled': !!dxTemplateModel.disabled }"),
                    $placeholder = $("<div>").addClass("dx-item-content-placeholder");
                $container.append($placeholder);
                return $container
            }
        };
        var BUTTON_TEXT_CLASS = "dx-button-text";
        TEMPLATE_GENERATORS.dxButton = {
            content: function() {
                var $titleBinding = $("<span>").attr("ng-bind", "dxTemplateModel.text").attr("ng-class", "{ '" + BUTTON_TEXT_CLASS + "' : !!dxTemplateModel.text }"),
                    icon = $("<dx-icon>");
                return baseElements.container().append(icon).append($titleBinding).append(baseElements.primitive())
            }
        };
        var LIST_ITEM_BADGE_CONTAINER_CLASS = "dx-list-item-badge-container",
            LIST_ITEM_BADGE_CLASS = "dx-list-item-badge",
            BADGE_CLASS = "dx-badge",
            LIST_ITEM_CHEVRON_CONTAINER_CLASS = "dx-list-item-chevron-container",
            LIST_ITEM_CHEVRON_CLASS = "dx-list-item-chevron";
        TEMPLATE_GENERATORS.dxList = {
            item: function() {
                return TEMPLATE_GENERATORS.CollectionWidget.item().append($("<div>").attr("ng-if", "dxTemplateModel.key").attr("ng-bind", "dxTemplateModel.key"))
            },
            itemFrame: function() {
                var $badgeContainer = $("<div>").addClass(LIST_ITEM_BADGE_CONTAINER_CLASS).attr("ng-if", "dxTemplateModel.badge"),
                    $badge = $("<div>").addClass(LIST_ITEM_BADGE_CLASS).addClass(BADGE_CLASS).attr("ng-bind", "dxTemplateModel.badge");
                var $chevronContainer = $("<div>").addClass(LIST_ITEM_CHEVRON_CONTAINER_CLASS).attr("ng-if", "dxTemplateModel.showChevron"),
                    $chevron = $("<div>").addClass(LIST_ITEM_CHEVRON_CLASS);
                return TEMPLATE_GENERATORS.CollectionWidget.itemFrame().append($badgeContainer.append($badge)).append($chevronContainer.append($chevron))
            },
            group: function() {
                var $keyBinding = $("<div>").attr("ng-if", "dxTemplateModel.key").attr("ng-bind", "dxTemplateModel.key");
                return baseElements.container().append($keyBinding).append(baseElements.primitive())
            }
        };
        TEMPLATE_GENERATORS.dxDropDownMenu = {
            item: TEMPLATE_GENERATORS.dxList.item,
            content: TEMPLATE_GENERATORS.dxButton.content
        };
        TEMPLATE_GENERATORS.dxDropDownList = {
            item: TEMPLATE_GENERATORS.dxList.item
        };
        TEMPLATE_GENERATORS.dxRadioGroup = {
            item: TEMPLATE_GENERATORS.CollectionWidget.item
        };
        TEMPLATE_GENERATORS.dxScheduler = {
            item: function() {
                var $itemContent = TEMPLATE_GENERATORS.CollectionWidget.item();
                var $details = $("<div>").addClass("dx-scheduler-appointment-content-details");
                $("<div>").attr("ng-if", "dxTemplateModel.allDay").addClass("dx-scheduler-appointment-content-allday").text(" All day: ").appendTo($details);
                $("<div>").attr("ng-if", "dxTemplateModel.startDate").addClass("dx-scheduler-appointment-content-date").text("{{dxTemplateModel.startDate | date : 'shortTime' }}").appendTo($details);
                $("<div>").attr("ng-if", "dxTemplateModel.endDate").addClass("dx-scheduler-appointment-content-date").text(" - ").appendTo($details);
                $("<div>").attr("ng-if", "dxTemplateModel.endDate").addClass("dx-scheduler-appointment-content-date").text("{{dxTemplateModel.endDate | date : 'shortTime' }}").appendTo($details);
                $details.appendTo($itemContent);
                $("<span>").attr("ng-if", "dxTemplateModel.recurrenceRule").addClass("dx-scheduler-appointment-recurrence-icon dx-icon-repeat").appendTo($itemContent);
                return $itemContent
            },
            appointmentTooltip: emptyTemplate,
            appointmentPopup: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxOverlay = {
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxSlideOutView = {
            menu: emptyTemplate,
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxSlideOut = {
            menuItem: TEMPLATE_GENERATORS.dxList.item,
            menuGroup: TEMPLATE_GENERATORS.dxList.group,
            content: emptyTemplate
        };
        TEMPLATE_GENERATORS.dxAccordion = {
            title: function() {
                var $titleBinding = $("<span>").attr("ng-if", "dxTemplateModel.title").attr("ng-bind", "dxTemplateModel.title"),
                    icon = $("<dx-icon>");
                return baseElements.container().append(icon).append($titleBinding).append(baseElements.primitive())
            },
            content: TEMPLATE_GENERATORS.CollectionWidget.item
        };
        TEMPLATE_GENERATORS.dxPivotTabs = {
            item: function() {
                return baseElements.container().append($("<span>").attr("ng-if", "dxTemplateModel.title").attr("ng-bind", "dxTemplateModel.title")).append(baseElements.primitive())
            }
        };
        TEMPLATE_GENERATORS.dxPivot = {
            title: TEMPLATE_GENERATORS.dxPivotTabs.item,
            content: emptyTemplate
        };
        var PANORAMA_ITEM_TITLE_CLASS = "dx-panorama-item-title";
        TEMPLATE_GENERATORS.dxPanorama = {
            itemFrame: function() {
                return TEMPLATE_GENERATORS.CollectionWidget.itemFrame().prepend($("<div>").addClass(PANORAMA_ITEM_TITLE_CLASS).attr("ng-if", "dxTemplateModel.title").attr("ng-bind", "dxTemplateModel.title"))
            }
        };
        TEMPLATE_GENERATORS.dxActionSheet = {
            item: function() {
                return baseElements.container().append($("<div>").attr("dx-button", "{ bindingOptions: { text: 'dxTemplateModel.text', onClick: 'dxTemplateModel.onClick', type: 'dxTemplateModel.type', disabled: 'dxTemplateModel.disabled' } }"))
            }
        };
        TEMPLATE_GENERATORS.dxToolbarBase = {
            item: function() {
                var template = TEMPLATE_GENERATORS.CollectionWidget.item();
                $('<dx-polymorph-widget name="dxTemplateModel.widget" options="dxTemplateModel.options">').appendTo(template);
                return template
            },
            actionSheetItem: TEMPLATE_GENERATORS.dxActionSheet.item
        };
        TEMPLATE_GENERATORS.dxToolbarBase.menuItem = TEMPLATE_GENERATORS.dxToolbarBase.item;
        var GALLERY_IMAGE_CLASS = "dx-gallery-item-image";
        TEMPLATE_GENERATORS.dxGallery = {
            item: function() {
                return baseElements.container().append(baseElements.html()).append(baseElements.text()).append($("<img>").addClass(GALLERY_IMAGE_CLASS).attr("ng-if", "!dxTemplateModel.imageSrc").attr("ng-src", "{{'' + dxTemplateModel}}")).append($("<img>").addClass(GALLERY_IMAGE_CLASS).attr("ng-if", "dxTemplateModel.imageSrc").attr("ng-src", "{{dxTemplateModel.imageSrc}}").attr("ng-attr-alt", "{{dxTemplateModel.imageAlt}}"))
            }
        };
        var TABS_ITEM_TEXT_CLASS = "dx-tab-text";
        TEMPLATE_GENERATORS.dxTabs = {
            item: function() {
                var container = baseElements.container();
                var icon = $("<dx-icon>"),
                    text = baseElements.text("<span>").addClass(TABS_ITEM_TEXT_CLASS);
                return container.append(baseElements.html()).append(icon).append(text).append(baseElements.primitive().addClass(TABS_ITEM_TEXT_CLASS))
            },
            itemFrame: function() {
                var $badge = $("<div>").addClass("dx-tabs-item-badge dx-badge").attr("ng-bind", "dxTemplateModel.badge").attr("ng-if", "dxTemplateModel.badge");
                return TEMPLATE_GENERATORS.CollectionWidget.itemFrame().append($badge)
            }
        };
        var NAVBAR_ITEM_BADGE_CLASS = "dx-navbar-item-badge";
        TEMPLATE_GENERATORS.dxNavBar = {
            itemFrame: function() {
                var $badge = $("<div>").addClass(NAVBAR_ITEM_BADGE_CLASS).addClass(BADGE_CLASS).attr("ng-if", "dxTemplateModel.badge").attr("ng-bind", "dxTemplateModel.badge");
                return TEMPLATE_GENERATORS.CollectionWidget.itemFrame().append($badge)
            }
        };
        TEMPLATE_GENERATORS.dxMenuBase = {
            item: function() {
                var container = baseElements.container();
                var text = $("<span>").attr("ng-if", "dxTemplateModel.text").addClass("dx-menu-item-text").attr("ng-bind", "dxTemplateModel.text"),
                    icon = $("<dx-icon>"),
                    popout = $("<span>").addClass("dx-menu-item-popout-container").attr("ng-if", "dxTemplateModel.items").append($("<div>").addClass("dx-menu-item-popout"));
                container.append(baseElements.html()).append(icon).append(text).append(popout).append(baseElements.primitive()).appendTo(container);
                return container
            }
        };
        TEMPLATE_GENERATORS.dxTreeView = {
            item: function() {
                var content = baseElements.container(),
                    link = $("<span/>").attr("ng-bind", "dxTemplateModel.text"),
                    icon = $("<dx-icon>");
                content.append(baseElements.html()).append(icon).append(link).append(baseElements.primitive());
                return content
            }
        };
        TEMPLATE_GENERATORS.dxTabPanel = {
            item: TEMPLATE_GENERATORS.CollectionWidget.item,
            title: function() {
                var content = TEMPLATE_GENERATORS.dxTabs.item();
                content.find(".dx-tab-text").eq(0).attr("ng-bind", "dxTemplateModel.title").attr("ng-if", "dxTemplateModel.title");
                content.find("[ng-if='dxTemplateModel.html']").remove();
                return content
            }
        };
        var popupTitleAndBottom = function() {
            return $("<div>").attr("dx-toolbar-base", "{ bindingOptions: { items: 'dxTemplateModel' } }")
        };
        TEMPLATE_GENERATORS.dxPopup = {
            title: popupTitleAndBottom,
            bottom: popupTitleAndBottom
        };
        TEMPLATE_GENERATORS.dxLookup = {
            title: TEMPLATE_GENERATORS.dxPopup.title,
            group: TEMPLATE_GENERATORS.dxList.group
        };
        var TAGBOX_TAG_CONTENT_CLASS = "dx-tag-content",
            TAGBOX_TAG_REMOVE_BUTTON_CLASS = "dx-tag-remove-button";
        TEMPLATE_GENERATORS.dxTagBox = {
            tag: function() {
                return $("<div>").addClass(TAGBOX_TAG_CONTENT_CLASS).append($("<span>").attr("ng-bind", "dxTemplateModel")).append($("<div>").addClass(TAGBOX_TAG_REMOVE_BUTTON_CLASS))
            }
        };
        module.exports = TEMPLATE_GENERATORS
    },
    /*!***********************************************!*\
      !*** ./Scripts/integration/angular/module.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var angular = __webpack_require__( /*! angular */ 145);
        __webpack_require__( /*! angular-sanitize */ 145);
        module.exports = angular.module("dx", ["ngSanitize"])
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/collection/ui.collection_widget.edit.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseCollectionWidget = __webpack_require__( /*! ./ui.collection_widget.base */ 152),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            arrayUtils = __webpack_require__( /*! ../../core/utils/array */ 111),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            PlainEditStrategy = __webpack_require__( /*! ./ui.collection_widget.edit.strategy.plain */ 166),
            DataSource = __webpack_require__( /*! ../../data/data_source/data_source */ 155).DataSource;
        var ITEM_DELETING_DATA_KEY = "dxItemDeleting";
        var CollectionWidget = BaseCollectionWidget.inherit({
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    selectedItem: true
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    selectionMode: "none",
                    selectionRequired: false,
                    selectionByClick: true,
                    selectedItems: [],
                    selectedIndex: -1,
                    selectedItem: null,
                    onSelectionChanged: null,
                    onItemReordered: null,
                    onItemDeleting: null,
                    onItemDeleted: null
                })
            },
            _init: function() {
                this._initEditStrategy();
                this.callBase();
                this._selectedItemIndices = [];
                if ("multi" === this.option("selectionMode")) {
                    this._showDeprecatedSelectionMode()
                }
            },
            _initEditStrategy: function() {
                var Strategy = PlainEditStrategy;
                this._editStrategy = new Strategy(this)
            },
            _forgetNextPageLoading: function() {
                this.callBase();
                this._selectedItemIndices = this._editStrategy.selectedItemIndices()
            },
            _render: function() {
                this._syncSelectionOptions();
                this._normalizeSelectedItems();
                this._initSelectedItems();
                this.callBase();
                this._renderSelection(this._selectedItemIndices, [])
            },
            _syncSelectionOptions: function(byOption) {
                byOption = byOption || this._chooseSelectOption();
                var selectedItem, selectedItems;
                switch (byOption) {
                    case "selectedIndex":
                        selectedItem = this._editStrategy.getItemDataByIndex(this.option("selectedIndex"));
                        if (commonUtils.isDefined(selectedItem)) {
                            this._setOptionSilent("selectedItems", [selectedItem]);
                            this._setOptionSilent("selectedItem", selectedItem)
                        } else {
                            this._setOptionSilent("selectedItems", []);
                            this._setOptionSilent("selectedItem", null)
                        }
                        break;
                    case "selectedItems":
                        selectedItems = this.option("selectedItems") || [];
                        this._setOptionSilent("selectedItem", selectedItems[0]);
                        this._setOptionSilent("selectedIndex", this._editStrategy.getIndexByItemData(selectedItems[0]));
                        break;
                    case "selectedItem":
                        selectedItem = this.option("selectedItem");
                        if (commonUtils.isDefined(selectedItem)) {
                            this._setOptionSilent("selectedItems", [selectedItem]);
                            this._setOptionSilent("selectedIndex", this._editStrategy.getIndexByItemData(selectedItem))
                        } else {
                            this._setOptionSilent("selectedItems", []);
                            this._setOptionSilent("selectedIndex", -1)
                        }
                }
            },
            _chooseSelectOption: function() {
                var optionName = "selectedIndex";
                if (this.option("selectedItems").length) {
                    optionName = "selectedItems"
                } else {
                    if (commonUtils.isDefined(this.option("selectedItem"))) {
                        optionName = "selectedItem"
                    }
                }
                return optionName
            },
            _normalizeSelectedItems: function() {
                if ("none" === this.option("selectionMode")) {
                    this._setOptionSilent("selectedItems", []);
                    this._syncSelectionOptions("selectedItems")
                } else {
                    if ("single" === this.option("selectionMode")) {
                        var newSelection = this._editStrategy.selectedItemIndices(this.option("selectedItems"));
                        if (newSelection.length > 1 || !newSelection.length && this.option("selectionRequired") && this.option("items") && this.option("items").length) {
                            var normalizedSelection = [newSelection[0] || this._selectedItemIndices[0] || 0];
                            this._setOptionSilent("selectedItems", this._editStrategy.fetchSelectedItems(normalizedSelection));
                            this._syncSelectionOptions("selectedItems")
                        }
                    }
                }
            },
            _initSelectedItems: function() {
                this._selectedItemIndices = this._editStrategy.selectedItemIndices(this.option("selectedItems"))
            },
            _renderSelection: $.noop,
            _itemClickHandler: function(e) {
                this._createAction($.proxy(function(e) {
                    this._itemSelectHandler(e.jQueryEvent)
                }, this), {
                    validatingTargetName: "itemElement"
                })({
                    itemElement: $(e.currentTarget),
                    jQueryEvent: e
                });
                this.callBase.apply(this, arguments)
            },
            _itemSelectHandler: function(e) {
                if (!this.option("selectionByClick")) {
                    return
                }
                var $itemElement = e.currentTarget;
                if (this.isItemSelected($itemElement)) {
                    this.unselectItem(e.currentTarget)
                } else {
                    this.selectItem(e.currentTarget)
                }
            },
            _selectedItemElement: function(index) {
                return this._itemElements().eq(index)
            },
            _postprocessRenderItem: function(args) {
                var $itemElement = $(args.itemElement);
                if (this._isItemSelected(this._editStrategy.getNormalizedIndex($itemElement))) {
                    $itemElement.addClass(this._selectedItemClass());
                    this._setAriaSelected($itemElement, "true")
                } else {
                    this._setAriaSelected($itemElement, "false")
                }
            },
            _updateSelectedItems: function() {
                var that = this,
                    oldSelection = this._selectedItemIndices.slice(),
                    newSelection = this._editStrategy.selectedItemIndices(),
                    addedSelection = arrayUtils.removeDuplicates(newSelection, oldSelection),
                    removedSelection = arrayUtils.removeDuplicates(oldSelection, newSelection);
                $.each(removedSelection, function(_, normalizedIndex) {
                    that._removeSelection(normalizedIndex)
                });
                $.each(addedSelection, function(_, normalizedIndex) {
                    that._addSelection(normalizedIndex)
                });
                if (removedSelection.length || addedSelection.length) {
                    var selectionChangePromise = this._selectionChangePromise;
                    this._updateSelection(addedSelection, removedSelection);
                    $.when(selectionChangePromise).done(function() {
                        that._fireSelectionChangeEvent(addedSelection, removedSelection)
                    })
                }
            },
            _fireSelectionChangeEvent: function(addedSelection, removedSelection) {
                this._createActionByOption("onSelectionChanged", {
                    excludeValidators: ["disabled", "readOnly"]
                })(this._editStrategy.fetchSelectionDifference(addedSelection, removedSelection))
            },
            _updateSelection: function() {
                this._renderSelection.apply(this, arguments)
            },
            _setAriaSelected: function($target, value) {
                this.setAria("selected", value, $target)
            },
            _removeSelection: function(normalizedIndex) {
                var $itemElement = this._editStrategy.getItemElement(normalizedIndex),
                    itemSelectionIndex = $.inArray(normalizedIndex, this._selectedItemIndices);
                if (itemSelectionIndex > -1) {
                    $itemElement.removeClass(this._selectedItemClass());
                    this._setAriaSelected($itemElement, "false");
                    this._selectedItemIndices.splice(itemSelectionIndex, 1);
                    $itemElement.triggerHandler("stateChanged")
                }
            },
            _showDeprecatedSelectionMode: function() {
                errors.log("W0001", this.NAME, "selectionMode: 'multi'", "16.1", "Use selectionMode: 'multiple' instead");
                this.option("selectionMode", "multiple")
            },
            _addSelection: function(normalizedIndex) {
                var $itemElement = this._editStrategy.getItemElement(normalizedIndex);
                if (normalizedIndex > -1 && !this._isItemSelected(normalizedIndex)) {
                    $itemElement.addClass(this._selectedItemClass());
                    this._setAriaSelected($itemElement, "true");
                    this._selectedItemIndices.push(normalizedIndex);
                    $itemElement.triggerHandler("stateChanged")
                }
            },
            _isItemSelected: function(index) {
                return $.inArray(index, this._selectedItemIndices) > -1
            },
            _optionChanged: function(args) {
                if (this._cancelOptionChange === args.name) {
                    return
                }
                switch (args.name) {
                    case "selectionMode":
                        if ("multi" === args.value) {
                            this._showDeprecatedSelectionMode()
                        } else {
                            this._invalidate()
                        }
                        break;
                    case "selectedIndex":
                    case "selectedItem":
                    case "selectedItems":
                        this._syncSelectionOptions(args.name);
                        this._normalizeSelectedItems();
                        this._updateSelectedItems();
                        break;
                    case "selectionRequired":
                        this._normalizeSelectedItems();
                        this._updateSelectedItems();
                        break;
                    case "selectionByClick":
                    case "onSelectionChanged":
                    case "onItemDeleting":
                    case "onItemDeleted":
                    case "onItemReordered":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _clearSelectedItems: function() {
                this._selectedItemIndices = [];
                this._setOptionSilent("selectedItems", []);
                this._syncSelectionOptions("selectedItems")
            },
            _setOptionSilent: function(name, value) {
                this._cancelOptionChange = name;
                this.option(name, value);
                this._cancelOptionChange = false
            },
            _waitDeletingPrepare: function($itemElement) {
                if ($itemElement.data(ITEM_DELETING_DATA_KEY)) {
                    return $.Deferred().resolve().promise()
                }
                $itemElement.data(ITEM_DELETING_DATA_KEY, true);
                var deferred = $.Deferred(),
                    deletePromise = this._itemEventHandler($itemElement, "onItemDeleting", {}, {
                        excludeValidators: ["disabled", "readOnly"]
                    });
                $.when(deletePromise).always($.proxy(function(value) {
                    var deletePromiseExists = !deletePromise,
                        deletePromiseResolved = !deletePromiseExists && "resolved" === deletePromise.state(),
                        argumentsSpecified = !!arguments.length,
                        shouldDelete = deletePromiseExists || deletePromiseResolved && !argumentsSpecified || deletePromiseResolved && value;
                    $itemElement.data(ITEM_DELETING_DATA_KEY, false);
                    shouldDelete ? deferred.resolve() : deferred.reject()
                }, this));
                return deferred.promise()
            },
            _deleteItemFromDS: function($item) {
                if (!this._dataSource) {
                    return $.Deferred().resolve().promise()
                }
                var deferred = $.Deferred(),
                    disabledState = this.option("disabled"),
                    dataStore = this._dataSource.store();
                this.option("disabled", true);
                if (!dataStore.remove) {
                    throw errors.Error("E1011")
                }
                dataStore.remove(dataStore.keyOf(this._getItemData($item))).done(function(key) {
                    if (void 0 !== key) {
                        deferred.resolve()
                    } else {
                        deferred.reject()
                    }
                }).fail(function() {
                    deferred.reject()
                });
                deferred.always($.proxy(function() {
                    this.option("disabled", disabledState)
                }, this));
                return deferred
            },
            _tryRefreshLastPage: function() {
                var deferred = $.Deferred();
                if (this._isLastPage() || this.option("grouped")) {
                    deferred.resolve()
                } else {
                    this._refreshLastPage().done(function() {
                        deferred.resolve()
                    })
                }
                return deferred.promise()
            },
            _refreshLastPage: function() {
                this._expectLastItemLoading();
                return this._dataSource.load()
            },
            _updateSelectionAfterDelete: function(fromIndex) {
                var itemIndex = $.inArray(fromIndex, this._selectedItemIndices);
                if (itemIndex > -1) {
                    this._selectedItemIndices.splice(itemIndex, 1)
                }
                this._editStrategy.updateSelectionAfterDelete(fromIndex);
                this.option("selectedItems", this._editStrategy.fetchSelectedItems())
            },
            _simulateOptionChange: function(optionName) {
                var optionValue = this.option(optionName);
                if (optionValue instanceof DataSource) {
                    return
                }
                this._optionChangedAction({
                    name: optionName,
                    fullName: optionName,
                    value: optionValue
                })
            },
            isItemSelected: function(itemElement) {
                return this._isItemSelected(this._editStrategy.getNormalizedIndex(itemElement))
            },
            selectItem: function(itemElement) {
                var itemIndex = this._editStrategy.getNormalizedIndex(itemElement);
                if (itemIndex === -1) {
                    return
                }
                var itemSelectionIndex = $.inArray(itemIndex, this._selectedItemIndices);
                if (itemSelectionIndex !== -1) {
                    return
                }
                if ("single" === this.option("selectionMode")) {
                    this.option("selectedItems", this._editStrategy.fetchSelectedItems([itemIndex]))
                } else {
                    var newSelectedIndices = this._selectedItemIndices.slice();
                    newSelectedIndices.push(itemIndex);
                    this.option("selectedItems", this._editStrategy.fetchSelectedItems(newSelectedIndices))
                }
            },
            unselectItem: function(itemElement) {
                var itemIndex = this._editStrategy.getNormalizedIndex(itemElement);
                if (itemIndex === -1) {
                    return
                }
                var itemSelectionIndex = $.inArray(itemIndex, this._selectedItemIndices);
                if (itemSelectionIndex === -1) {
                    return
                }
                var newSelectedIndices = this._selectedItemIndices.slice();
                newSelectedIndices.splice(itemSelectionIndex, 1);
                if (this.option("selectionRequired") && 0 === newSelectedIndices.length) {
                    return
                }
                this.option("selectedItems", this._editStrategy.fetchSelectedItems(newSelectedIndices))
            },
            deleteItem: function(itemElement) {
                var that = this,
                    deferred = $.Deferred(),
                    $item = this._editStrategy.getItemElement(itemElement),
                    index = this._editStrategy.getNormalizedIndex(itemElement),
                    changingOption = this._dataSource ? "dataSource" : "items",
                    itemResponseWaitClass = this._itemResponseWaitClass();
                if (index > -1) {
                    this._waitDeletingPrepare($item).done(function() {
                        $item.addClass(itemResponseWaitClass);
                        var deletedActionArgs = that._extendActionArgs($item);
                        that._deleteItemFromDS($item).done(function() {
                            that._editStrategy.deleteItemAtIndex(index);
                            that._simulateOptionChange(changingOption);
                            that._updateSelectionAfterDelete(index);
                            that._itemEventHandler($item, "onItemDeleted", deletedActionArgs, {
                                beforeExecute: function() {
                                    $item.detach()
                                },
                                excludeValidators: ["disabled", "readOnly"]
                            });
                            that._renderEmptyMessage();
                            that._tryRefreshLastPage().done(function() {
                                deferred.resolveWith(that)
                            })
                        }).fail(function() {
                            $item.removeClass(itemResponseWaitClass);
                            deferred.rejectWith(that)
                        })
                    }).fail(function() {
                        deferred.rejectWith(that)
                    })
                } else {
                    deferred.rejectWith(that)
                }
                return deferred.promise()
            },
            reorderItem: function(itemElement, toItemElement) {
                var deferred = $.Deferred(),
                    that = this,
                    strategy = this._editStrategy,
                    $movingItem = strategy.getItemElement(itemElement),
                    $destinationItem = strategy.getItemElement(toItemElement),
                    movingIndex = strategy.getNormalizedIndex(itemElement),
                    destinationIndex = strategy.getNormalizedIndex(toItemElement),
                    changingOption = this._dataSource ? "dataSource" : "items";
                var canMoveItems = movingIndex > -1 && destinationIndex > -1 && movingIndex !== destinationIndex;
                if (canMoveItems) {
                    deferred.resolveWith(this)
                } else {
                    deferred.rejectWith(this)
                }
                return deferred.promise().done(function() {
                    $destinationItem[strategy.itemPlacementFunc(movingIndex, destinationIndex)]($movingItem);
                    var newSelectedItems = strategy.getSelectedItemsAfterReorderItem(movingIndex, destinationIndex);
                    strategy.moveItemAtIndexToIndex(movingIndex, destinationIndex);
                    that._selectedItemIndices = strategy.selectedItemIndices(newSelectedItems);
                    that.option("selectedItems", strategy.fetchSelectedItems());
                    if ("items" === changingOption) {
                        that._simulateOptionChange(changingOption)
                    }
                    that._itemEventHandler($movingItem, "onItemReordered", {
                        fromIndex: strategy.getIndex(movingIndex),
                        toIndex: strategy.getIndex(destinationIndex)
                    }, {
                        excludeValidators: ["disabled", "readOnly"]
                    })
                })
            }
        });
        module.exports = CollectionWidget
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/collection/ui.collection_widget.base.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Action = __webpack_require__( /*! ../../core/action */ 35),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            DataHelperMixin = __webpack_require__( /*! ./ui.data_helper */ 154),
            selectors = __webpack_require__( /*! ../widget/jquery.selectors */ 101),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            holdEvent = __webpack_require__( /*! ../../events/hold */ 164),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            contextmenuEvent = __webpack_require__( /*! ../../events/contextmenu */ 165);
        var COLLECTION_CLASS = "dx-collection",
            ITEM_CLASS = "dx-item",
            CONTENT_CLASS_POSTFIX = "-content",
            ITEM_CONTENT_PLACEHOLDER_CLASS = "dx-item-content-placeholder",
            ITEM_DATA_KEY = "dxItemData",
            ITEM_INDEX_KEY = "dxItemIndex",
            ITEM_TEMPLATE_ID_PREFIX = "tmpl-",
            ITEMS_SELECTOR = "[data-options*='dxItem']",
            SELECTED_ITEM_CLASS = "dx-item-selected",
            ITEM_RESPONSE_WAIT_CLASS = "dx-item-response-wait",
            EMPTY_COLLECTION = "dx-empty-collection",
            TEMPLATE_WRAPPER_CLASS = "dx-template-wrapper",
            DISABLED_STATE_CLASS = "dx-state-disabled",
            INVISIBLE_STATE_CLASS = "dx-state-invisible",
            ITEM_PATH_REGEX = /^([^.]+\[\d+\]\.)+(\w+)$/;
        var FOCUS_UP = "up",
            FOCUS_DOWN = "down",
            FOCUS_LEFT = "left",
            FOCUS_RIGHT = "right",
            FOCUS_PAGE_UP = "pageup",
            FOCUS_PAGE_DOWN = "pagedown",
            FOCUS_LAST = "last",
            FOCUS_FIRST = "first";
        var CollectionWidget = Widget.inherit({
            _activeStateUnit: "." + ITEM_CLASS,
            _supportedKeys: function() {
                var click = function(e) {
                        var $itemElement = this.option("focusedElement");
                        if (!$itemElement) {
                            return
                        }
                        e.target = $itemElement;
                        e.currentTarget = $itemElement;
                        this._itemClickHandler(e)
                    },
                    move = function(location, e) {
                        e.preventDefault();
                        e.stopPropagation();
                        this._moveFocus(location, e)
                    };
                return $.extend(this.callBase(), {
                    space: click,
                    enter: click,
                    leftArrow: $.proxy(move, this, FOCUS_LEFT),
                    rightArrow: $.proxy(move, this, FOCUS_RIGHT),
                    upArrow: $.proxy(move, this, FOCUS_UP),
                    downArrow: $.proxy(move, this, FOCUS_DOWN),
                    pageUp: $.proxy(move, this, FOCUS_UP),
                    pageDown: $.proxy(move, this, FOCUS_DOWN),
                    home: $.proxy(move, this, FOCUS_FIRST),
                    end: $.proxy(move, this, FOCUS_LAST)
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    selectOnFocus: false,
                    loopItemFocus: true,
                    items: [],
                    itemTemplate: "item",
                    onItemRendered: null,
                    onItemClick: null,
                    onItemHold: null,
                    itemHoldTimeout: 750,
                    onItemContextMenu: null,
                    onFocusedItemChanged: null,
                    noDataText: messageLocalization.format("dxCollectionWidget-noDataText"),
                    dataSource: null,
                    _itemAttributes: {},
                    itemTemplateProperty: "template",
                    focusOnSelectedItem: true,
                    focusedElement: null
                })
            },
            _getAnonymousTemplateName: function() {
                return "item"
            },
            _init: function() {
                this.callBase();
                this._cleanRenderedItems();
                this._refreshDataSource()
            },
            _initTemplates: function() {
                this._initItemsFromMarkup();
                this.callBase()
            },
            _initItemsFromMarkup: function() {
                var $items = this.element().contents().filter(ITEMS_SELECTOR);
                if (!$items.length || this.option("items").length) {
                    return
                }
                var items = $.map($items, $.proxy(function(item) {
                    var $item = $(item);
                    var result = domUtils.getElementOptions(item).dxItem;
                    var isTemplateRequired = $.trim($item.html()) && !result.template;
                    if (isTemplateRequired) {
                        result.template = this._prepareItemTemplate($item)
                    } else {
                        $item.remove()
                    }
                    return result
                }, this));
                this.option("items", items)
            },
            _prepareItemTemplate: function($item) {
                var templateId = ITEM_TEMPLATE_ID_PREFIX + new Guid;
                var templateOptions = 'dxTemplate: { name: "' + templateId + '" }';
                $item.detach().clone().attr("data-options", templateOptions).data("options", templateOptions).appendTo(this.element());
                return templateId
            },
            _dataSourceOptions: function() {
                return {
                    paginate: false
                }
            },
            _cleanRenderedItems: function() {
                this._renderedItemsCount = 0
            },
            _focusTarget: function() {
                return this.element()
            },
            _focusInHandler: function(e) {
                this.callBase.apply(this, arguments);
                if ($.inArray(e.target, this._focusTarget()) === -1) {
                    return
                }
                var $focusedElement = this.option("focusedElement");
                if ($focusedElement && $focusedElement.length) {
                    this._setFocusedItem($focusedElement)
                } else {
                    var $activeItem = this._getActiveItem();
                    if ($activeItem.length) {
                        this.option("focusedElement", $activeItem)
                    }
                }
            },
            _focusOutHandler: function(e) {
                this.callBase.apply(this, arguments);
                var $target = this.option("focusedElement");
                if ($target) {
                    this._toggleFocusClass(false, $target)
                }
            },
            _getActiveItem: function(last) {
                var $focusedElement = this.option("focusedElement");
                if ($focusedElement && $focusedElement.length) {
                    return $focusedElement
                }
                var index = this.option("focusOnSelectedItem") ? this.option("selectedIndex") : 0,
                    activeElements = this._getActiveElement(),
                    lastIndex = activeElements.length - 1;
                if (index < 0) {
                    index = last ? lastIndex : 0
                }
                return activeElements.eq(index)
            },
            _renderFocusTarget: function() {
                this.callBase.apply(this, arguments);
                this._refreshActiveDescendant()
            },
            _moveFocus: function(location) {
                var $newTarget, $items = this._itemElements().filter(":visible").not(".dx-state-disabled");
                switch (location) {
                    case FOCUS_PAGE_UP:
                    case FOCUS_UP:
                        $newTarget = this._prevItem($items);
                        break;
                    case FOCUS_PAGE_DOWN:
                    case FOCUS_DOWN:
                        $newTarget = this._nextItem($items);
                        break;
                    case FOCUS_RIGHT:
                        $newTarget = this.option("rtlEnabled") ? this._prevItem($items) : this._nextItem($items);
                        break;
                    case FOCUS_LEFT:
                        $newTarget = this.option("rtlEnabled") ? this._nextItem($items) : this._prevItem($items);
                        break;
                    case FOCUS_FIRST:
                        $newTarget = $items.first();
                        break;
                    case FOCUS_LAST:
                        $newTarget = $items.last();
                        break;
                    default:
                        return false
                }
                if (0 !== $newTarget.length) {
                    this.option("focusedElement", $newTarget)
                }
            },
            _prevItem: function($items) {
                var $target = this._getActiveItem(),
                    targetIndex = $items.index($target),
                    $last = $items.last(),
                    $item = $($items[targetIndex - 1]),
                    loop = this.option("loopItemFocus");
                if (0 === $item.length && loop) {
                    $item = $last
                }
                return $item
            },
            _nextItem: function($items) {
                var $target = this._getActiveItem(true),
                    targetIndex = $items.index($target),
                    $first = $items.first(),
                    $item = $($items[targetIndex + 1]),
                    loop = this.option("loopItemFocus");
                if (0 === $item.length && loop) {
                    $item = $first
                }
                return $item
            },
            _selectFocusedItem: function($target) {
                this.selectItem($target)
            },
            _removeFocusedItem: function($target) {
                if ($target && $target.length) {
                    this._toggleFocusClass(false, $target);
                    $target.removeAttr("id")
                }
            },
            _refreshActiveDescendant: function() {
                this.setAria("activedescendant", "");
                this.setAria("activedescendant", this.getFocusedItemId())
            },
            _setFocusedItem: function($target) {
                if (!$target || !$target.length) {
                    return
                }
                $target.attr("id", this.getFocusedItemId());
                this._toggleFocusClass(true, $target);
                this.onFocusedItemChanged(this.getFocusedItemId());
                this._refreshActiveDescendant();
                if (this.option("selectOnFocus")) {
                    this._selectFocusedItem($target)
                }
            },
            _findItemElementByItem: function(item) {
                var result = $(),
                    that = this;
                this.itemElements().each(function() {
                    var $item = $(this);
                    if ($item.data(that._itemDataKey()) === item) {
                        result = $item;
                        return false
                    }
                });
                return result
            },
            _getIndexByItem: function(item) {
                return this.option("items").indexOf(item)
            },
            _itemOptionChanged: function(item, property, value) {
                var $item = this._findItemElementByItem(item);
                switch (property) {
                    case "visible":
                        this._renderItemVisibleState($item, value);
                        break;
                    case "disabled":
                        this._renderItemDisableState($item, value);
                        break;
                    default:
                        var index = this._getIndexByItem(item);
                        this._renderItem(index, item, null, $item)
                }
            },
            _renderItemVisibleState: function($item, value) {
                $item.toggleClass(INVISIBLE_STATE_CLASS, !value)
            },
            _renderItemDisableState: function($item, value) {
                $item.toggleClass(DISABLED_STATE_CLASS, !!value)
            },
            _optionChanged: function(args) {
                if ("items" === args.name) {
                    var matches = args.fullName.match(ITEM_PATH_REGEX);
                    if (matches && matches.length) {
                        var property = matches[matches.length - 1],
                            itemPath = args.fullName.replace("." + property, ""),
                            item = this.option(itemPath);
                        this._itemOptionChanged(item, property, args.value);
                        return
                    }
                }
                switch (args.name) {
                    case "items":
                    case "_itemAttributes":
                    case "itemTemplateProperty":
                        this._cleanRenderedItems();
                        this._invalidate();
                        break;
                    case "dataSource":
                        this.option("items", []);
                        this._refreshDataSource();
                        this._renderEmptyMessage();
                        break;
                    case "noDataText":
                        this._renderEmptyMessage();
                        break;
                    case "itemTemplate":
                        this._invalidate();
                        break;
                    case "onItemRendered":
                        this._createItemRenderAction();
                        break;
                    case "onItemClick":
                        break;
                    case "onItemHold":
                    case "itemHoldTimeout":
                        this._attachHoldEvent();
                        break;
                    case "onItemContextMenu":
                        this._attachContextMenuEvent();
                        break;
                    case "onFocusedItemChanged":
                        this.onFocusedItemChanged = this._createActionByOption("onFocusedItemChanged");
                        break;
                    case "selectOnFocus":
                    case "loopItemFocus":
                    case "focusOnSelectedItem":
                        break;
                    case "focusedElement":
                        this._removeFocusedItem(args.previousValue);
                        this._setFocusedItem(args.value);
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _loadNextPage: function() {
                var dataSource = this._dataSource;
                this._expectNextPageLoading();
                dataSource.pageIndex(1 + dataSource.pageIndex());
                return dataSource.load()
            },
            _expectNextPageLoading: function() {
                this._startIndexForAppendedItems = 0
            },
            _expectLastItemLoading: function() {
                this._startIndexForAppendedItems = -1
            },
            _forgetNextPageLoading: function() {
                this._startIndexForAppendedItems = null
            },
            _dataSourceChangedHandler: function(newItems) {
                var items = this.option("items");
                if (this._initialized && items && this._shouldAppendItems()) {
                    this._renderedItemsCount = items.length;
                    if (!this._isLastPage() || this._startIndexForAppendedItems !== -1) {
                        this.option().items = items.concat(newItems.slice(this._startIndexForAppendedItems))
                    }
                    this._forgetNextPageLoading();
                    this._renderContent();
                    this._renderFocusTarget()
                } else {
                    this.option("items", newItems)
                }
            },
            _dataSourceLoadErrorHandler: function() {
                this._forgetNextPageLoading();
                this.option("items", this.option("items"))
            },
            _shouldAppendItems: function() {
                return null != this._startIndexForAppendedItems && this._allowDynamicItemsAppend()
            },
            _allowDynamicItemsAppend: function() {
                return false
            },
            _clean: function() {
                this._cleanFocusState();
                this._cleanItemContainer()
            },
            _cleanItemContainer: function() {
                this._itemContainer().empty()
            },
            _dispose: function() {
                this.callBase();
                clearTimeout(this._itemFocusTimeout)
            },
            _refresh: function() {
                this._cleanRenderedItems();
                this.callBase.apply(this, arguments)
            },
            _itemContainer: function() {
                return this.element()
            },
            _itemClass: function() {
                return ITEM_CLASS
            },
            _itemContentClass: function() {
                return this._itemClass() + CONTENT_CLASS_POSTFIX
            },
            _selectedItemClass: function() {
                return SELECTED_ITEM_CLASS
            },
            _itemResponseWaitClass: function() {
                return ITEM_RESPONSE_WAIT_CLASS
            },
            _itemSelector: function() {
                return "." + this._itemClass()
            },
            _itemDataKey: function() {
                return ITEM_DATA_KEY
            },
            _itemIndexKey: function() {
                return ITEM_INDEX_KEY
            },
            _itemElements: function() {
                return this._itemContainer().find(this._itemSelector())
            },
            _render: function() {
                this.onFocusedItemChanged = this._createActionByOption("onFocusedItemChanged");
                this.callBase();
                this.element().addClass(COLLECTION_CLASS);
                this._attachClickEvent();
                this._attachHoldEvent();
                this._attachContextMenuEvent()
            },
            _attachClickEvent: function() {
                var itemSelector = this._itemSelector(),
                    clickEventNamespace = eventUtils.addNamespace(clickEvent.name, this.NAME),
                    pointerDownEventNamespace = eventUtils.addNamespace(pointerEvents.down, this.NAME),
                    that = this;
                var pointerDownAction = new Action(function(args) {
                    var event = args.event;
                    that._itemPointerDownHandler(event)
                });
                this._itemContainer().off(clickEventNamespace, itemSelector).off(pointerDownEventNamespace, itemSelector).on(clickEventNamespace, itemSelector, $.proxy(function(e) {
                    this._itemClickHandler(e)
                }, this)).on(pointerDownEventNamespace, itemSelector, function(e) {
                    pointerDownAction.execute({
                        element: $(e.target),
                        event: e
                    })
                })
            },
            _itemClickHandler: function(e, args, config) {
                this._itemJQueryEventHandler(e, "onItemClick", args, config)
            },
            _itemPointerDownHandler: function(e) {
                if (!this.option("focusStateEnabled")) {
                    return
                }
                clearTimeout(this._itemFocusTimeout);
                this._itemFocusTimeout = setTimeout(function() {
                    if (e.isDefaultPrevented()) {
                        return
                    }
                    var $target = $(e.target),
                        $closestItem = $target.closest(this._itemElements()),
                        $closestFocusable = $target.closest(selectors.focusable);
                    if ($closestItem.length && $.inArray($closestFocusable.get(0), this._focusTarget()) !== -1) {
                        this.option("focusedElement", $closestItem)
                    }
                }.bind(this))
            },
            _attachHoldEvent: function() {
                var $itemContainer = this._itemContainer(),
                    itemSelector = this._itemSelector(),
                    eventName = eventUtils.addNamespace(holdEvent.name, this.NAME);
                $itemContainer.off(eventName, itemSelector);
                if (this._shouldAttachHoldEvent()) {
                    $itemContainer.on(eventName, itemSelector, {
                        timeout: this._getHoldTimeout()
                    }, $.proxy(this._itemHoldHandler, this))
                }
            },
            _getHoldTimeout: function() {
                return this.option("itemHoldTimeout")
            },
            _shouldAttachHoldEvent: function() {
                return this.option("onItemHold")
            },
            _itemHoldHandler: function(e) {
                this._itemJQueryEventHandler(e, "onItemHold")
            },
            _attachContextMenuEvent: function() {
                var $itemContainer = this._itemContainer(),
                    itemSelector = this._itemSelector(),
                    eventName = eventUtils.addNamespace(contextmenuEvent.name, this.NAME);
                $itemContainer.off(eventName, itemSelector);
                if (this._shouldAttachContextMenuEvent()) {
                    $itemContainer.on(eventName, itemSelector, $.proxy(this._itemContextMenuHandler, this))
                }
            },
            _shouldAttachContextMenuEvent: function() {
                return this.option("onItemContextMenu")
            },
            _itemContextMenuHandler: function(e) {
                this._itemJQueryEventHandler(e, "onItemContextMenu")
            },
            _renderContentImpl: function() {
                var items = this.option("items") || [];
                if (this._renderedItemsCount) {
                    this._renderItems(items.slice(this._renderedItemsCount))
                } else {
                    this._renderItems(items)
                }
            },
            _renderItems: function(items) {
                if (items.length) {
                    $.each(items, $.proxy(this._renderItem, this))
                }
                this._renderEmptyMessage()
            },
            _renderItem: function(index, itemData, $container, $itemToReplace) {
                $container = $container || this._itemContainer();
                var $itemFrame = this._renderItemFrame(index, itemData, $container, $itemToReplace);
                this._setElementData($itemFrame, itemData, index);
                $itemFrame.attr(this.option("_itemAttributes"));
                this._attachItemClickEvent(itemData, $itemFrame);
                var $itemContent = $itemFrame.find("." + ITEM_CONTENT_PLACEHOLDER_CLASS);
                $itemContent.removeClass(ITEM_CONTENT_PLACEHOLDER_CLASS);
                var renderContentPromise = this._renderItemContent({
                    index: index,
                    itemData: itemData,
                    container: $itemContent,
                    contentClass: this._itemContentClass(),
                    defaultTemplateName: this.option("itemTemplate")
                });
                var that = this;
                $.when(renderContentPromise).done(function($itemContent) {
                    that._postprocessRenderItem({
                        itemElement: $itemFrame,
                        itemContent: $itemContent,
                        itemData: itemData,
                        itemIndex: index
                    });
                    that._executeItemRenderAction(index, itemData, $itemFrame)
                });
                return $itemFrame
            },
            _attachItemClickEvent: function(itemData, $itemElement) {
                if (!itemData || !itemData.onClick) {
                    return
                }
                $itemElement.on(clickEvent.name, $.proxy(function(e) {
                    this._itemEventHandlerByHandler($itemElement, itemData.onClick, {
                        jQueryEvent: e
                    })
                }, this))
            },
            _renderItemContent: function(args) {
                var itemTemplateName = this._getItemTemplateName(args);
                var itemTemplate = this._getTemplate(itemTemplateName);
                this._addItemContentClasses(args);
                var $templateResult = this._createItemByTemplate(itemTemplate, args);
                if (!$templateResult.hasClass(TEMPLATE_WRAPPER_CLASS)) {
                    return args.container
                }
                return this._renderItemContentByNode(args, $templateResult)
            },
            _renderItemContentByNode: function(args, $node) {
                args.container.replaceWith($node);
                args.container = $node;
                this._addItemContentClasses(args);
                return $node
            },
            _addItemContentClasses: function(args) {
                var classes = [ITEM_CLASS + CONTENT_CLASS_POSTFIX, args.contentClass];
                args.container.addClass(classes.join(" "))
            },
            _renderItemFrame: function(index, itemData, $container, $itemToReplace) {
                var itemFrameTemplate = this.option("templateProvider").getTemplates(this).itemFrame,
                    $itemFrame = itemFrameTemplate.render({
                        model: commonUtils.isDefined(itemData) ? itemData : {},
                        container: $container,
                        index: index
                    });
                if ($itemToReplace && $itemToReplace.length) {
                    $itemToReplace.replaceWith($itemFrame)
                } else {
                    $itemFrame.appendTo($container)
                }
                return $itemFrame
            },
            _postprocessRenderItem: $.noop,
            _executeItemRenderAction: function(index, itemData, itemElement) {
                this._getItemRenderAction()({
                    itemElement: itemElement,
                    itemIndex: index,
                    itemData: itemData
                })
            },
            _setElementData: function(element, data, index) {
                element.addClass([ITEM_CLASS, this._itemClass()].join(" ")).data(this._itemDataKey(), data).data(this._itemIndexKey(), index)
            },
            _createItemRenderAction: function() {
                return this._itemRenderAction = this._createActionByOption("onItemRendered", {
                    element: this.element(),
                    excludeValidators: ["designMode", "disabled", "readOnly"],
                    category: "rendering"
                })
            },
            _getItemRenderAction: function() {
                return this._itemRenderAction || this._createItemRenderAction()
            },
            _getItemTemplateName: function(args) {
                var data = args.itemData,
                    templateProperty = args.templateProperty || this.option("itemTemplateProperty"),
                    template = data && data[templateProperty];
                return template || args.defaultTemplateName
            },
            _createItemByTemplate: function(itemTemplate, renderArgs) {
                return itemTemplate.render({
                    model: renderArgs.itemData,
                    container: renderArgs.container,
                    index: renderArgs.index
                })
            },
            _emptyMessageContainer: function() {
                return this._itemContainer()
            },
            _renderEmptyMessage: function() {
                var noDataText = this.option("noDataText"),
                    items = this.option("items"),
                    hideNoData = !noDataText || items && items.length || this._isDataSourceLoading();
                if (hideNoData && this._$nodata) {
                    this._$nodata.remove();
                    this._$nodata = null;
                    this.setAria("label", void 0)
                }
                if (!hideNoData) {
                    this._$nodata = this._$nodata || $("<div>").addClass("dx-empty-message");
                    this._$nodata.appendTo(this._emptyMessageContainer()).html(noDataText);
                    this.setAria("label", noDataText)
                }
                this.element().toggleClass(EMPTY_COLLECTION, !hideNoData)
            },
            _itemJQueryEventHandler: function(jQueryEvent, handlerOptionName, actionArgs, actionConfig) {
                this._itemEventHandler(jQueryEvent.target, handlerOptionName, $.extend(actionArgs, {
                    jQueryEvent: jQueryEvent
                }), actionConfig)
            },
            _itemEventHandler: function(initiator, handlerOptionName, actionArgs, actionConfig) {
                var action = this._createActionByOption(handlerOptionName, $.extend({
                    validatingTargetName: "itemElement"
                }, actionConfig));
                return this._itemEventHandlerImpl(initiator, action, actionArgs)
            },
            _itemEventHandlerByHandler: function(initiator, handler, actionArgs, actionConfig) {
                var action = this._createAction(handler, $.extend({
                    validatingTargetName: "itemElement"
                }, actionConfig));
                return this._itemEventHandlerImpl(initiator, action, actionArgs)
            },
            _itemEventHandlerImpl: function(initiator, action, actionArgs) {
                var $itemElement = this._closestItemElement($(initiator));
                return action($.extend(this._extendActionArgs($itemElement), actionArgs))
            },
            _extendActionArgs: function($itemElement) {
                return {
                    itemElement: $itemElement,
                    itemIndex: this._itemElements().index($itemElement),
                    itemData: this._getItemData($itemElement)
                }
            },
            _closestItemElement: function($element) {
                return $($element).closest(this._itemSelector())
            },
            _getItemData: function(itemElement) {
                return $(itemElement).data(this._itemDataKey())
            },
            getFocusedItemId: function() {
                if (!this._focusedItemId) {
                    this._focusedItemId = new Guid
                }
                return this._focusedItemId
            },
            itemElements: function() {
                return this._itemElements()
            },
            itemsContainer: function() {
                return this._itemContainer()
            }
        }).include(DataHelperMixin);
        CollectionWidget.publicName("CollectionWidget");
        module.exports = CollectionWidget
    },
    /*!******************************!*\
      !*** ./Scripts/core/guid.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var Class = __webpack_require__( /*! ./class */ 20);
        var Guid = Class.inherit({
            ctor: function(value) {
                if (value) {
                    value = String(value)
                }
                this._value = this._normalize(value || this._generate())
            },
            _normalize: function(value) {
                value = value.replace(/[^a-f0-9]/gi, "").toLowerCase();
                while (value.length < 32) {
                    value += "0"
                }
                return [value.substr(0, 8), value.substr(8, 4), value.substr(12, 4), value.substr(16, 4), value.substr(20, 12)].join("-")
            },
            _generate: function() {
                var value = "";
                for (var i = 0; i < 32; i++) {
                    value += Math.round(15 * Math.random()).toString(16)
                }
                return value
            },
            toString: function() {
                return this._value
            },
            valueOf: function() {
                return this._value
            },
            toJSON: function() {
                return this._value
            }
        });
        module.exports = Guid
    },
    /*!*************************************************!*\
      !*** ./Scripts/ui/collection/ui.data_helper.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            DataSource = __webpack_require__( /*! ../../data/data_source/data_source */ 155).DataSource,
            normalizeDataSourceOptions = __webpack_require__( /*! ../../data/data_source/data_source */ 155).normalizeDataSourceOptions;
        var DATA_SOURCE_OPTIONS_METHOD = "_dataSourceOptions",
            DATA_SOURCE_CHANGED_METHOD = "_dataSourceChangedHandler",
            DATA_SOURCE_LOAD_ERROR_METHOD = "_dataSourceLoadErrorHandler",
            DATA_SOURCE_LOADING_CHANGED_METHOD = "_dataSourceLoadingChangedHandler";
        var DataHelperMixin = {
            postCtor: function() {
                this.on("disposing", function() {
                    this._disposeDataSource()
                })
            },
            _refreshDataSource: function() {
                this._initDataSource();
                this._loadDataSource()
            },
            _initDataSource: function() {
                var widgetDataSourceOptions, dataSourceType, dataSourceOptions = this.option("dataSource");
                this._disposeDataSource();
                if (dataSourceOptions) {
                    if (dataSourceOptions instanceof DataSource) {
                        this._isSharedDataSource = true;
                        this._dataSource = dataSourceOptions
                    } else {
                        widgetDataSourceOptions = DATA_SOURCE_OPTIONS_METHOD in this ? this[DATA_SOURCE_OPTIONS_METHOD]() : {};
                        dataSourceType = this._dataSourceType ? this._dataSourceType() : DataSource;
                        this._dataSource = new dataSourceType($.extend(true, {}, widgetDataSourceOptions, normalizeDataSourceOptions(dataSourceOptions)))
                    }
                    this._addDataSourceHandlers()
                }
            },
            _addDataSourceHandlers: function() {
                if (DATA_SOURCE_CHANGED_METHOD in this) {
                    this._addDataSourceChangeHandler()
                }
                if (DATA_SOURCE_LOAD_ERROR_METHOD in this) {
                    this._addDataSourceLoadErrorHandler()
                }
                if (DATA_SOURCE_LOADING_CHANGED_METHOD in this) {
                    this._addDataSourceLoadingChangedHandler()
                }
                this._addReadyWatcher()
            },
            _addReadyWatcher: function() {
                this._dataSource.on("loadingChanged", $.proxy(function(isLoading) {
                    this._ready && this._ready(!isLoading)
                }, this))
            },
            _addDataSourceChangeHandler: function() {
                var dataSource = this._dataSource;
                this._proxiedDataSourceChangedHandler = $.proxy(function() {
                    this[DATA_SOURCE_CHANGED_METHOD](dataSource.items())
                }, this);
                dataSource.on("changed", this._proxiedDataSourceChangedHandler)
            },
            _addDataSourceLoadErrorHandler: function() {
                this._proxiedDataSourceLoadErrorHandler = $.proxy(this[DATA_SOURCE_LOAD_ERROR_METHOD], this);
                this._dataSource.on("loadError", this._proxiedDataSourceLoadErrorHandler)
            },
            _addDataSourceLoadingChangedHandler: function() {
                this._proxiedDataSourceLoadingChangedHandler = $.proxy(this[DATA_SOURCE_LOADING_CHANGED_METHOD], this);
                this._dataSource.on("loadingChanged", this._proxiedDataSourceLoadingChangedHandler)
            },
            _loadDataSource: function() {
                if (this._dataSource) {
                    var dataSource = this._dataSource;
                    if (dataSource.isLoaded()) {
                        this._proxiedDataSourceChangedHandler && this._proxiedDataSourceChangedHandler()
                    } else {
                        dataSource.load()
                    }
                }
            },
            _loadSingle: function(key, value) {
                key = "this" === key ? this._dataSource.key() || "this" : key;
                return this._dataSource.loadSingle(key, value)
            },
            _isLastPage: function() {
                return !this._dataSource || this._dataSource.isLastPage() || !this._dataSource._pageSize
            },
            _isDataSourceLoading: function() {
                return this._dataSource && this._dataSource.isLoading()
            },
            _disposeDataSource: function() {
                if (this._dataSource) {
                    if (this._isSharedDataSource) {
                        delete this._isSharedDataSource;
                        this._proxiedDataSourceChangedHandler && this._dataSource.off("changed", this._proxiedDataSourceChangedHandler);
                        this._proxiedDataSourceLoadErrorHandler && this._dataSource.off("loadError", this._proxiedDataSourceLoadErrorHandler);
                        this._proxiedDataSourceLoadingChangedHandler && this._dataSource.off("loadingChanged", this._proxiedDataSourceLoadingChangedHandler)
                    } else {
                        this._dataSource.dispose()
                    }
                    delete this._dataSource;
                    delete this._proxiedDataSourceChangedHandler;
                    delete this._proxiedDataSourceLoadErrorHandler;
                    delete this._proxiedDataSourceLoadingChangedHandler
                }
            }
        };
        module.exports = DataHelperMixin
    },
    /*!*************************************************!*\
      !*** ./Scripts/data/data_source/data_source.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            dataUtils = __webpack_require__( /*! ../utils */ 137),
            Store = __webpack_require__( /*! ../abstract_store */ 156),
            ArrayStore = __webpack_require__( /*! ../array_store */ 162),
            CustomStore = __webpack_require__( /*! ../custom_store */ 163),
            EventsMixin = __webpack_require__( /*! ../../core/events_mixin */ 39),
            errors = __webpack_require__( /*! ../errors */ 157).errors,
            array = __webpack_require__( /*! ../../core/utils/array */ 111),
            queue = __webpack_require__( /*! ../../core/utils/queue */ 51),
            __isString = commonUtils.isString,
            __isNumber = commonUtils.isNumber,
            __isBoolean = commonUtils.isBoolean,
            __isDefined = commonUtils.isDefined;
        var CANCELED_TOKEN = "canceled";

        function OperationManager() {
            this._counter = -1;
            this._deferreds = {}
        }
        OperationManager.prototype.constructor = OperationManager;
        OperationManager.prototype.add = function(deferred) {
            this._counter += 1;
            this._deferreds[this._counter] = deferred;
            return this._counter
        };
        OperationManager.prototype.remove = function(operationId) {
            return delete this._deferreds[operationId]
        };
        OperationManager.prototype.cancel = function(operationId) {
            if (operationId in this._deferreds) {
                this._deferreds[operationId].reject(CANCELED_TOKEN);
                return true
            }
            return false
        };
        var operationManager = new OperationManager;

        function isPending(deferred) {
            return "pending" === deferred.state()
        }

        function normalizeDataSourceOptions(options) {
            var store;

            function createCustomStoreFromLoadFunc() {
                var storeConfig = {};
                $.each(["useDefaultSearch", "key", "load", "byKey", "lookup", "totalCount", "insert", "update", "remove"], function() {
                    storeConfig[this] = options[this];
                    delete options[this]
                });
                return new CustomStore(storeConfig)
            }

            function createStoreFromConfig(storeConfig) {
                var alias = storeConfig.type;
                delete storeConfig.type;
                return Store.create(alias, storeConfig)
            }

            function createCustomStoreFromUrl(url) {
                return new CustomStore({
                    load: function() {
                        return $.getJSON(url)
                    }
                })
            }
            if ("string" === typeof options) {
                options = {
                    paginate: false,
                    store: createCustomStoreFromUrl(options)
                }
            }
            if (void 0 === options) {
                options = []
            }
            if ($.isArray(options) || options instanceof Store) {
                options = {
                    store: options
                }
            } else {
                options = $.extend({}, options)
            }
            if (void 0 === options.store) {
                options.store = []
            }
            store = options.store;
            if ("load" in options) {
                store = createCustomStoreFromLoadFunc()
            } else {
                if ($.isArray(store)) {
                    store = new ArrayStore(store)
                } else {
                    if ($.isPlainObject(store)) {
                        store = createStoreFromConfig($.extend({}, store))
                    }
                }
            }
            options.store = store;
            return options
        }

        function normalizeStoreLoadOptionAccessorArguments(originalArguments) {
            switch (originalArguments.length) {
                case 0:
                    return;
                case 1:
                    return originalArguments[0]
            }
            return $.makeArray(originalArguments)
        }

        function generateStoreLoadOptionAccessor(optionName) {
            return function() {
                var args = normalizeStoreLoadOptionAccessorArguments(arguments);
                if (void 0 === args) {
                    return this._storeLoadOptions[optionName]
                }
                this._storeLoadOptions[optionName] = args
            }
        }

        function mapDataRespectingGrouping(items, mapper, groupInfo) {
            function mapRecursive(items, level) {
                if (!commonUtils.isArray(items)) {
                    return items
                }
                return level ? mapGroup(items, level) : $.map(items, mapper)
            }

            function mapGroup(group, level) {
                return $.map(group, function(item) {
                    var result = {
                        key: item.key,
                        items: mapRecursive(item.items, level - 1)
                    };
                    if ("aggregates" in item) {
                        result.aggregates = item.aggregates
                    }
                    return result
                })
            }
            return mapRecursive(items, groupInfo ? dataUtils.normalizeSortingInfo(groupInfo).length : 0)
        }
        var DataSource = Class.inherit({
            ctor: function(options) {
                var that = this;
                options = normalizeDataSourceOptions(options);
                this._store = options.store;
                this._storeLoadOptions = this._extractLoadOptions(options);
                this._mapFunc = options.map;
                this._postProcessFunc = options.postProcess;
                this._pageIndex = void 0 !== options.pageIndex ? options.pageIndex : 0;
                this._pageSize = void 0 !== options.pageSize ? options.pageSize : 20;
                this._loadingCount = 0;
                this._loadQueue = this._createLoadQueue();
                this._searchValue = "searchValue" in options ? options.searchValue : null;
                this._searchOperation = options.searchOperation || "contains";
                this._searchExpr = options.searchExpr;
                this._paginate = options.paginate;
                $.each(["onChanged", "onLoadError", "onLoadingChanged", "onCustomizeLoadResult", "onCustomizeStoreLoadOptions"], function(_, optionName) {
                    if (optionName in options) {
                        that.on(optionName.substr(2, 1).toLowerCase() + optionName.substr(3), options[optionName])
                    }
                });
                this._init()
            },
            _init: function() {
                this._items = [];
                this._userData = {};
                this._totalCount = -1;
                this._isLoaded = false;
                if (!__isDefined(this._paginate)) {
                    this._paginate = !this.group()
                }
                this._isLastPage = !this._paginate
            },
            dispose: function() {
                this._disposeEvents();
                delete this._store;
                if (this._delayedLoadTask) {
                    this._delayedLoadTask.abort()
                }
                this._disposed = true
            },
            _extractLoadOptions: function(options) {
                var result = {},
                    names = ["sort", "filter", "select", "group", "requireTotalCount"],
                    customNames = this._store._customLoadOptions();
                if (customNames) {
                    names = names.concat(customNames)
                }
                $.each(names, function() {
                    result[this] = options[this]
                });
                return result
            },
            loadOptions: function() {
                return this._storeLoadOptions
            },
            items: function() {
                return this._items
            },
            pageIndex: function(newIndex) {
                if (!__isNumber(newIndex)) {
                    return this._pageIndex
                }
                this._pageIndex = newIndex;
                this._isLastPage = !this._paginate
            },
            paginate: function(value) {
                if (!__isBoolean(value)) {
                    return this._paginate
                }
                if (this._paginate !== value) {
                    this._paginate = value;
                    this.pageIndex(0)
                }
            },
            pageSize: function(value) {
                if (!__isNumber(value)) {
                    return this._pageSize
                }
                this._pageSize = value
            },
            isLastPage: function() {
                return this._isLastPage
            },
            sort: generateStoreLoadOptionAccessor("sort"),
            filter: function() {
                var newFilter = normalizeStoreLoadOptionAccessorArguments(arguments);
                if (void 0 === newFilter) {
                    return this._storeLoadOptions.filter
                }
                this._storeLoadOptions.filter = newFilter;
                this.pageIndex(0)
            },
            group: generateStoreLoadOptionAccessor("group"),
            select: generateStoreLoadOptionAccessor("select"),
            requireTotalCount: function(value) {
                if (!__isBoolean(value)) {
                    return this._storeLoadOptions.requireTotalCount
                }
                this._storeLoadOptions.requireTotalCount = value
            },
            searchValue: function(value) {
                if (arguments.length < 1) {
                    return this._searchValue
                }
                this._searchValue = value;
                this.pageIndex(0)
            },
            searchOperation: function(op) {
                if (!__isString(op)) {
                    return this._searchOperation
                }
                this._searchOperation = op;
                this.pageIndex(0)
            },
            searchExpr: function(expr) {
                var argc = arguments.length;
                if (0 === argc) {
                    return this._searchExpr
                }
                if (argc > 1) {
                    expr = $.makeArray(arguments)
                }
                this._searchExpr = expr;
                this.pageIndex(0)
            },
            store: function() {
                return this._store
            },
            key: function() {
                return this._store && this._store.key()
            },
            totalCount: function() {
                return this._totalCount
            },
            isLoaded: function() {
                return this._isLoaded
            },
            isLoading: function() {
                return this._loadingCount > 0
            },
            _createLoadQueue: function() {
                return queue.create()
            },
            _changeLoadingCount: function(increment) {
                var newLoading, oldLoading = this.isLoading();
                this._loadingCount += increment;
                newLoading = this.isLoading();
                if (oldLoading ^ newLoading) {
                    this.fireEvent("loadingChanged", [newLoading])
                }
            },
            _scheduleLoadCallbacks: function(deferred) {
                var that = this;
                that._changeLoadingCount(1);
                deferred.always(function() {
                    that._changeLoadingCount(-1)
                })
            },
            _scheduleFailCallbacks: function(deferred) {
                var that = this;
                deferred.fail(function() {
                    if (arguments[0] === CANCELED_TOKEN) {
                        return
                    }
                    that.fireEvent("loadError", arguments)
                })
            },
            _scheduleChangedCallbacks: function(deferred) {
                var that = this;
                deferred.done(function() {
                    that.fireEvent("changed")
                })
            },
            loadSingle: function(propName, propValue) {
                var that = this;
                var d = $.Deferred(),
                    key = this.key(),
                    store = this._store,
                    options = this._createStoreLoadOptions(),
                    handleDone = function(data) {
                        if (!__isDefined(data) || array.isEmpty(data)) {
                            d.reject(new errors.Error("E4009"))
                        } else {
                            d.resolve(that._applyMapFunction($.makeArray(data))[0])
                        }
                    };
                this._scheduleFailCallbacks(d);
                if (arguments.length < 2) {
                    propValue = propName;
                    propName = key
                }
                delete options.skip;
                delete options.group;
                delete options.refresh;
                delete options.pageIndex;
                delete options.searchString;
                (function() {
                    if (propName === key || store instanceof CustomStore) {
                        return store.byKey(propValue, options)
                    }
                    options.take = 1;
                    options.filter = options.filter ? [options.filter, [propName, propValue]] : [propName, propValue];
                    return store.load(options)
                })().fail(d.reject).done(handleDone);
                return d.promise()
            },
            load: function() {
                var loadOperation, that = this,
                    d = $.Deferred();

                function loadTask() {
                    if (that._disposed) {
                        return
                    }
                    if (!isPending(d)) {
                        return
                    }
                    return that._loadFromStore(loadOperation, d)
                }
                this._scheduleLoadCallbacks(d);
                this._scheduleFailCallbacks(d);
                this._scheduleChangedCallbacks(d);
                loadOperation = this._createLoadOperation(d);
                this.fireEvent("customizeStoreLoadOptions", [loadOperation]);
                this._loadQueue.add(function() {
                    if ("number" === typeof loadOperation.delay) {
                        that._delayedLoadTask = commonUtils.executeAsync(loadTask, loadOperation.delay)
                    } else {
                        loadTask()
                    }
                    return d.promise()
                });
                return d.promise({
                    operationId: loadOperation.operationId
                })
            },
            _createLoadOperation: function(deferred) {
                var id = operationManager.add(deferred),
                    options = this._createStoreLoadOptions();
                deferred.always(function() {
                    operationManager.remove(id)
                });
                return {
                    operationId: id,
                    storeLoadOptions: options
                }
            },
            reload: function() {
                this._init();
                return this.load()
            },
            cancel: function(operationId) {
                return operationManager.cancel(operationId)
            },
            _addSearchOptions: function(storeLoadOptions) {
                if (this._disposed) {
                    return
                }
                if (this.store()._useDefaultSearch) {
                    this._addSearchFilter(storeLoadOptions)
                } else {
                    storeLoadOptions.searchOperation = this._searchOperation;
                    storeLoadOptions.searchValue = this._searchValue;
                    storeLoadOptions.searchExpr = this._searchExpr
                }
            },
            _createStoreLoadOptions: function() {
                var result = $.extend({}, this._storeLoadOptions);
                this._addSearchOptions(result);
                if (this._paginate) {
                    if (this._pageSize) {
                        result.skip = this._pageIndex * this._pageSize;
                        result.take = this._pageSize
                    }
                }
                result.userData = this._userData;
                return result
            },
            _addSearchFilter: function(storeLoadOptions) {
                var value = this._searchValue,
                    op = this._searchOperation,
                    selector = this._searchExpr,
                    searchFilter = [];
                if (!value) {
                    return
                }
                if (!selector) {
                    selector = "this"
                }
                if (!$.isArray(selector)) {
                    selector = [selector]
                }
                $.each(selector, function(i, item) {
                    if (searchFilter.length) {
                        searchFilter.push("or")
                    }
                    searchFilter.push([item, op, value])
                });
                if (storeLoadOptions.filter) {
                    storeLoadOptions.filter = [searchFilter, storeLoadOptions.filter]
                } else {
                    storeLoadOptions.filter = searchFilter
                }
            },
            _loadFromStore: function(loadOptions, pendingDeferred) {
                var that = this;

                function handleSuccess(data, extra) {
                    function processResult() {
                        var loadResult;
                        if (data && !$.isArray(data) && data.data) {
                            extra = data;
                            data = data.data
                        }
                        loadResult = $.extend({
                            data: data,
                            extra: extra
                        }, loadOptions);
                        that.fireEvent("customizeLoadResult", [loadResult]);
                        $.when(loadResult.data).done(function(data) {
                            loadResult.data = data;
                            that._processStoreLoadResult(loadResult, pendingDeferred)
                        }).fail(pendingDeferred.reject)
                    }
                    if (that._disposed) {
                        return
                    }
                    if (!isPending(pendingDeferred)) {
                        return
                    }
                    processResult()
                }
                if (loadOptions.data) {
                    return $.Deferred().resolve(loadOptions.data).done(handleSuccess)
                }
                return this.store().load(loadOptions.storeLoadOptions).done(handleSuccess).fail(pendingDeferred.reject)
            },
            _processStoreLoadResult: function(loadResult, pendingDeferred) {
                var that = this;
                var data = $.makeArray(loadResult.data),
                    extra = loadResult.extra,
                    storeLoadOptions = loadResult.storeLoadOptions;

                function resolvePendingDeferred() {
                    that._isLoaded = true;
                    that._totalCount = isFinite(extra.totalCount) ? extra.totalCount : -1;
                    return pendingDeferred.resolve(data, extra)
                }

                function proceedLoadingTotalCount() {
                    that.store().totalCount(storeLoadOptions).done(function(count) {
                        extra.totalCount = count;
                        resolvePendingDeferred()
                    }).fail(pendingDeferred.reject)
                }
                if (that._disposed) {
                    return
                }
                data = that._applyPostProcessFunction(that._applyMapFunction(data));
                if (!$.isPlainObject(extra)) {
                    extra = {}
                }
                that._items = data;
                if (!data.length || !that._paginate || that._pageSize && data.length < that._pageSize) {
                    that._isLastPage = true
                }
                if (storeLoadOptions.requireTotalCount && !isFinite(extra.totalCount)) {
                    proceedLoadingTotalCount()
                } else {
                    resolvePendingDeferred()
                }
            },
            _applyMapFunction: function(data) {
                if (this._mapFunc) {
                    return mapDataRespectingGrouping(data, this._mapFunc, this.group())
                }
                return data
            },
            _applyPostProcessFunction: function(data) {
                if (this._postProcessFunc) {
                    return this._postProcessFunc(data)
                }
                return data
            }
        }).include(EventsMixin);
        exports.DataSource = DataSource;
        exports.normalizeDataSourceOptions = normalizeDataSourceOptions
    },
    /*!****************************************!*\
      !*** ./Scripts/data/abstract_store.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            abstract = Class.abstract,
            EventsMixin = __webpack_require__( /*! ../core/events_mixin */ 39),
            errorsModule = __webpack_require__( /*! ./errors */ 157),
            dataUtils = __webpack_require__( /*! ./utils */ 137),
            normalizeSortingInfo = dataUtils.normalizeSortingInfo,
            compileGetter = __webpack_require__( /*! ../core/utils/data */ 36).compileGetter,
            Query = __webpack_require__( /*! ./query */ 158),
            storeImpl = {};

        function multiLevelGroup(query, groupInfo) {
            query = query.groupBy(groupInfo[0].selector);
            if (groupInfo.length > 1) {
                query = query.select(function(g) {
                    return $.extend({}, g, {
                        items: multiLevelGroup(Query(g.items), groupInfo.slice(1)).toArray()
                    })
                })
            }
            return query
        }

        function arrangeSortingInfo(groupInfo, sortInfo) {
            var filteredGroup = [];
            $.each(groupInfo, function(_, group) {
                var collision = $.grep(sortInfo, function(sort) {
                    return group.selector === sort.selector
                });
                if (collision.length < 1) {
                    filteredGroup.push(group)
                }
            });
            return filteredGroup.concat(sortInfo)
        }
        var Store = Class.inherit({
            ctor: function(options) {
                var that = this;
                options = options || {};
                $.each(["onLoaded", "onLoading", "onInserted", "onInserting", "onUpdated", "onUpdating", "onRemoved", "onRemoving", "onModified", "onModifying"], function(_, optionName) {
                    if (optionName in options) {
                        that.on(optionName.slice(2).toLowerCase(), options[optionName])
                    }
                });
                this._key = options.key;
                this._errorHandler = options.errorHandler;
                this._useDefaultSearch = true
            },
            _customLoadOptions: function() {
                return null
            },
            key: function() {
                return this._key
            },
            keyOf: function(obj) {
                if (!this._keyGetter) {
                    this._keyGetter = compileGetter(this.key())
                }
                return this._keyGetter(obj)
            },
            _requireKey: function() {
                if (!this.key()) {
                    throw errorsModule.errors.Error("E4005")
                }
            },
            load: function(options) {
                var that = this;
                options = options || {};
                this.fireEvent("loading", [options]);
                return this._withLock(this._loadImpl(options)).done(function(result, extra) {
                    that.fireEvent("loaded", [result, options])
                })
            },
            _loadImpl: function(options) {
                var filter = options.filter,
                    sort = options.sort,
                    select = options.select,
                    group = options.group,
                    skip = options.skip,
                    take = options.take,
                    q = this.createQuery(options);
                if (filter) {
                    q = q.filter(filter)
                }
                if (group) {
                    group = normalizeSortingInfo(group)
                }
                if (sort || group) {
                    sort = normalizeSortingInfo(sort || []);
                    if (group) {
                        sort = arrangeSortingInfo(group, sort)
                    }
                    $.each(sort, function(index) {
                        q = q[index ? "thenBy" : "sortBy"](this.selector, this.desc)
                    })
                }
                if (select) {
                    q = q.select(select)
                }
                if (group) {
                    q = multiLevelGroup(q, group)
                }
                if (take || skip) {
                    q = q.slice(skip || 0, take)
                }
                return q.enumerate()
            },
            _withLock: function(task) {
                var result = $.Deferred();
                task.done(function() {
                    var that = this,
                        args = arguments;
                    dataUtils.processRequestResultLock.promise().done(function() {
                        result.resolveWith(that, args)
                    })
                }).fail(function() {
                    result.rejectWith(this, arguments)
                });
                return result
            },
            createQuery: abstract,
            totalCount: function(options) {
                return this._totalCountImpl(options)
            },
            _totalCountImpl: function(options) {
                options = options || {};
                var q = this.createQuery(options),
                    group = options.group,
                    filter = options.filter;
                if (filter) {
                    q = q.filter(filter)
                }
                if (group) {
                    group = normalizeSortingInfo(group);
                    q = multiLevelGroup(q, group)
                }
                return q.count()
            },
            byKey: function(key, extraOptions) {
                return this._addFailHandlers(this._withLock(this._byKeyImpl(key, extraOptions)))
            },
            _byKeyImpl: abstract,
            insert: function(values) {
                var that = this;
                that.fireEvent("modifying");
                that.fireEvent("inserting", [values]);
                return that._addFailHandlers(that._insertImpl(values).done(function(callbackValues, callbackKey) {
                    that.fireEvent("inserted", [callbackValues, callbackKey]);
                    that.fireEvent("modified")
                }))
            },
            _insertImpl: abstract,
            update: function(key, values) {
                var that = this;
                that.fireEvent("modifying");
                that.fireEvent("updating", [key, values]);
                return that._addFailHandlers(that._updateImpl(key, values).done(function(callbackKey, callbackValues) {
                    that.fireEvent("updated", [callbackKey, callbackValues]);
                    that.fireEvent("modified")
                }))
            },
            _updateImpl: abstract,
            remove: function(key) {
                var that = this;
                that.fireEvent("modifying");
                that.fireEvent("removing", [key]);
                return that._addFailHandlers(that._removeImpl(key).done(function(callbackKey) {
                    that.fireEvent("removed", [callbackKey]);
                    that.fireEvent("modified")
                }))
            },
            _removeImpl: abstract,
            _addFailHandlers: function(deferred) {
                return deferred.fail(this._errorHandler, errorsModule._errorHandler)
            }
        }).include(EventsMixin);
        Store.create = function(alias, options) {
            if (!(alias in storeImpl)) {
                throw errorsModule.errors.Error("E4020", alias)
            }
            return new storeImpl[alias](options)
        };
        Store.inherit = function(inheritor) {
            return function(members, alias) {
                var type = inheritor.apply(this, [members]);
                if (alias) {
                    storeImpl[alias] = type
                }
                return type
            }
        }(Store.inherit);
        module.exports = Store;
        module.exports.multiLevelGroup = multiLevelGroup;
        module.exports.arrangeSortingInfo = arrangeSortingInfo
    },
    /*!********************************!*\
      !*** ./Scripts/data/errors.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var errorUtils = __webpack_require__( /*! ../core/utils/error */ 11),
            coreErrors = __webpack_require__( /*! ../core/errors */ 17),
            handlers = {};
        var errors = errorUtils(coreErrors.ERROR_MESSAGES, {
            E4000: "[DevExpress.data]: {0}",
            E4001: "Unknown aggregating function is detected: '{0}'",
            E4002: "Unsupported OData protocol version is used",
            E4003: "Unknown filter operation is used: {0}",
            E4004: "The thenby() method is called before the sortby() method",
            E4005: "Store requires a key expression for this operation",
            E4006: "ArrayStore 'data' option must be an array",
            E4007: "Compound keys cannot be auto-generated",
            E4008: "Attempt to insert an item with the a duplicated key",
            E4009: "Data item cannot be found",
            E4010: "CustomStore does not support creating queries",
            E4011: "Custom Store method is not implemented or is not a function: {0}",
            E4012: "Custom Store method returns an invalid value: {0}",
            E4013: "Local Store requires the 'name' configuration option is specified",
            E4014: "Unknown key type is detected: {0}",
            E4015: "Unknown entity name or alias is used: {0}",
            E4017: "Keys cannot be modified",
            E4018: "The server has returned a non-numeric value in a response to an item count request",
            E4019: "Mixing of group operators inside a single group of filter expression is not allowed",
            E4020: "Unknown store type is detected: {0}"
        });

        function handleError(error) {
            var id = "E4000";
            if (error && "__id" in error) {
                id = error.__id
            }
            errors.log(id, error)
        }
        var errorHandler = null;
        var _errorHandler = function(error) {
            handleError(error);
            if (handlers.errorHandler) {
                handlers.errorHandler(error)
            }
        };
        handlers = {
            errors: errors,
            errorHandler: errorHandler,
            _errorHandler: _errorHandler
        };
        module.exports = handlers
    },
    /*!*******************************!*\
      !*** ./Scripts/data/query.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            arrayQueryImpl = __webpack_require__( /*! ./array_query */ 159),
            remoteQueryImpl = __webpack_require__( /*! ./remote_query */ 160);
        var queryImpl = {
            array: arrayQueryImpl,
            remote: remoteQueryImpl
        };
        var query = function() {
            var impl = $.isArray(arguments[0]) ? "array" : "remote";
            return queryImpl[impl].apply(this, arguments)
        };
        module.exports = query;
        module.exports.queryImpl = queryImpl
    },
    /*!*************************************!*\
      !*** ./Scripts/data/array_query.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            compileGetter = __webpack_require__( /*! ../core/utils/data */ 36).compileGetter,
            toComparable = __webpack_require__( /*! ../core/utils/data */ 36).toComparable,
            errorsModule = __webpack_require__( /*! ./errors */ 157),
            dataUtils = __webpack_require__( /*! ./utils */ 137);
        var Iterator = Class.inherit({
            toArray: function() {
                var result = [];
                this.reset();
                while (this.next()) {
                    result.push(this.current())
                }
                return result
            },
            countable: function() {
                return false
            }
        });
        var ArrayIterator = Iterator.inherit({
            ctor: function(array) {
                this.array = array;
                this.index = -1
            },
            next: function() {
                if (this.index + 1 < this.array.length) {
                    this.index++;
                    return true
                }
                return false
            },
            current: function() {
                return this.array[this.index]
            },
            reset: function() {
                this.index = -1
            },
            toArray: function() {
                return this.array.slice(0)
            },
            countable: function() {
                return true
            },
            count: function() {
                return this.array.length
            }
        });
        var WrappedIterator = Iterator.inherit({
            ctor: function(iter) {
                this.iter = iter
            },
            next: function() {
                return this.iter.next()
            },
            current: function() {
                return this.iter.current()
            },
            reset: function() {
                return this.iter.reset()
            }
        });
        var MapIterator = WrappedIterator.inherit({
            ctor: function(iter, mapper) {
                this.callBase(iter);
                this.index = -1;
                this.mapper = mapper
            },
            current: function() {
                return this.mapper(this.callBase(), this.index)
            },
            next: function() {
                var hasNext = this.callBase();
                if (hasNext) {
                    this.index++
                }
                return hasNext
            }
        });
        var SortIterator = Iterator.inherit({
            ctor: function(iter, getter, desc) {
                if (!(iter instanceof MapIterator)) {
                    iter = new MapIterator(iter, this._wrap)
                }
                this.iter = iter;
                this.rules = [{
                    getter: getter,
                    desc: desc
                }]
            },
            thenBy: function(getter, desc) {
                var result = new SortIterator(this.sortedIter || this.iter, getter, desc);
                if (!this.sortedIter) {
                    result.rules = this.rules.concat(result.rules)
                }
                return result
            },
            next: function() {
                this._ensureSorted();
                return this.sortedIter.next()
            },
            current: function() {
                this._ensureSorted();
                return this.sortedIter.current()
            },
            reset: function() {
                delete this.sortedIter
            },
            countable: function() {
                return this.sortedIter || this.iter.countable()
            },
            count: function() {
                if (this.sortedIter) {
                    return this.sortedIter.count()
                }
                return this.iter.count()
            },
            _ensureSorted: function() {
                var that = this;
                if (that.sortedIter) {
                    return
                }
                $.each(that.rules, function() {
                    this.getter = compileGetter(this.getter)
                });
                that.sortedIter = new MapIterator(new ArrayIterator(this.iter.toArray().sort(function(x, y) {
                    return that._compare(x, y)
                })), that._unwrap)
            },
            _wrap: function(record, index) {
                return {
                    index: index,
                    value: record
                }
            },
            _unwrap: function(wrappedItem) {
                return wrappedItem.value
            },
            _compare: function(x, y) {
                var xIndex = x.index,
                    yIndex = y.index;
                x = x.value;
                y = y.value;
                if (x === y) {
                    return xIndex - yIndex
                }
                for (var i = 0, rulesCount = this.rules.length; i < rulesCount; i++) {
                    var rule = this.rules[i],
                        xValue = toComparable(rule.getter(x)),
                        yValue = toComparable(rule.getter(y)),
                        factor = rule.desc ? -1 : 1;
                    if (null === xValue && null !== yValue) {
                        return -factor
                    }
                    if (null !== xValue && null === yValue) {
                        return factor
                    }
                    if (void 0 === xValue && void 0 !== yValue) {
                        return factor
                    }
                    if (void 0 !== xValue && void 0 === yValue) {
                        return -factor
                    }
                    if (xValue < yValue) {
                        return -factor
                    }
                    if (xValue > yValue) {
                        return factor
                    }
                }
                return xIndex - yIndex
            }
        });
        var compileCriteria = function() {
            var compileGroup = function(crit) {
                var groupOperator, nextGroupOperator, idx = 0,
                    bag = [],
                    ops = [];
                $.each(crit, function() {
                    if ($.isArray(this) || $.isFunction(this)) {
                        if (bag.length > 1 && groupOperator !== nextGroupOperator) {
                            throw new errorsModule.errors.Error("E4019")
                        }
                        ops.push(compileCriteria(this));
                        bag.push("op[" + idx + "](d)");
                        idx++;
                        groupOperator = nextGroupOperator;
                        nextGroupOperator = "&&"
                    } else {
                        nextGroupOperator = dataUtils.isConjunctiveOperator(this) ? "&&" : "||"
                    }
                });
                return new Function("op", "return function(d) { return " + bag.join(" " + groupOperator + " ") + " }")(ops)
            };
            var toString = function(value) {
                return commonUtils.isDefined(value) ? value.toString() : ""
            };
            var compileBinary = function(crit) {
                crit = dataUtils.normalizeBinaryCriterion(crit);
                var getter = compileGetter(crit[0]),
                    op = crit[1],
                    value = crit[2];
                value = toComparable(value);
                switch (op.toLowerCase()) {
                    case "=":
                        return compileEquals(getter, value);
                    case "<>":
                        return compileEquals(getter, value, true);
                    case ">":
                        return function(obj) {
                            return toComparable(getter(obj)) > value
                        };
                    case "<":
                        return function(obj) {
                            return toComparable(getter(obj)) < value
                        };
                    case ">=":
                        return function(obj) {
                            return toComparable(getter(obj)) >= value
                        };
                    case "<=":
                        return function(obj) {
                            return toComparable(getter(obj)) <= value
                        };
                    case "startswith":
                        return function(obj) {
                            return 0 === toComparable(toString(getter(obj))).indexOf(value)
                        };
                    case "endswith":
                        return function(obj) {
                            var getterValue = toComparable(toString(getter(obj))),
                                searchValue = toString(value);
                            if (getterValue.length < searchValue.length) {
                                return false
                            }
                            return getterValue.lastIndexOf(value) === getterValue.length - value.length
                        };
                    case "contains":
                        return function(obj) {
                            return toComparable(toString(getter(obj))).indexOf(value) > -1
                        };
                    case "notcontains":
                        return function(obj) {
                            return toComparable(toString(getter(obj))).indexOf(value) === -1
                        }
                }
                throw errorsModule.errors.Error("E4003", op)
            };

            function compileEquals(getter, value, negate) {
                return function(obj) {
                    obj = toComparable(getter(obj));
                    var result = useStrictComparison(value) ? obj === value : obj == value;
                    if (negate) {
                        result = !result
                    }
                    return result
                }
            }

            function useStrictComparison(value) {
                return "" === value || 0 === value || false === value
            }
            return function(crit) {
                if ($.isFunction(crit)) {
                    return crit
                }
                if ($.isArray(crit[0])) {
                    return compileGroup(crit)
                }
                return compileBinary(crit)
            }
        }();
        var FilterIterator = WrappedIterator.inherit({
            ctor: function(iter, criteria) {
                this.callBase(iter);
                this.criteria = compileCriteria(criteria)
            },
            next: function() {
                while (this.iter.next()) {
                    if (this.criteria(this.current())) {
                        return true
                    }
                }
                return false
            }
        });
        var GroupIterator = Iterator.inherit({
            ctor: function(iter, getter) {
                this.iter = iter;
                this.getter = getter
            },
            next: function() {
                this._ensureGrouped();
                return this.groupedIter.next()
            },
            current: function() {
                this._ensureGrouped();
                return this.groupedIter.current()
            },
            reset: function() {
                delete this.groupedIter
            },
            countable: function() {
                return !!this.groupedIter
            },
            count: function() {
                return this.groupedIter.count()
            },
            _ensureGrouped: function() {
                if (this.groupedIter) {
                    return
                }
                var hash = {},
                    keys = [],
                    iter = this.iter,
                    getter = compileGetter(this.getter);
                iter.reset();
                while (iter.next()) {
                    var current = iter.current(),
                        key = getter(current);
                    if (key in hash) {
                        hash[key].push(current)
                    } else {
                        hash[key] = [current];
                        keys.push(key)
                    }
                }
                this.groupedIter = new ArrayIterator($.map(keys, function(key) {
                    return {
                        key: key,
                        items: hash[key]
                    }
                }))
            }
        });
        var SelectIterator = WrappedIterator.inherit({
            ctor: function(iter, getter) {
                this.callBase(iter);
                this.getter = compileGetter(getter)
            },
            current: function() {
                return this.getter(this.callBase())
            },
            countable: function() {
                return this.iter.countable()
            },
            count: function() {
                return this.iter.count()
            }
        });
        var SliceIterator = WrappedIterator.inherit({
            ctor: function(iter, skip, take) {
                this.callBase(iter);
                this.skip = Math.max(0, skip);
                this.take = Math.max(0, take);
                this.pos = 0
            },
            next: function() {
                if (this.pos >= this.skip + this.take) {
                    return false
                }
                while (this.pos < this.skip && this.iter.next()) {
                    this.pos++
                }
                this.pos++;
                return this.iter.next()
            },
            reset: function() {
                this.callBase();
                this.pos = 0
            },
            countable: function() {
                return this.iter.countable()
            },
            count: function() {
                return Math.min(this.iter.count() - this.skip, this.take)
            }
        });
        var arrayQueryImpl = function(iter, queryOptions) {
            queryOptions = queryOptions || {};
            if (!(iter instanceof Iterator)) {
                iter = new ArrayIterator(iter)
            }
            var handleError = function(error) {
                var handler = queryOptions.errorHandler;
                if (handler) {
                    handler(error)
                }
                errorsModule._errorHandler(error)
            };
            var aggregateCore = function(aggregator) {
                var seed, d = $.Deferred().fail(handleError),
                    step = aggregator.step,
                    finalize = aggregator.finalize;
                try {
                    iter.reset();
                    if ("seed" in aggregator) {
                        seed = aggregator.seed
                    } else {
                        seed = iter.next() ? iter.current() : NaN
                    }
                    var accumulator = seed;
                    while (iter.next()) {
                        accumulator = step(accumulator, iter.current())
                    }
                    d.resolve(finalize ? finalize(accumulator) : accumulator)
                } catch (x) {
                    d.reject(x)
                }
                return d.promise()
            };
            var aggregate = function(seed, step, finalize) {
                if (arguments.length < 2) {
                    return aggregateCore({
                        step: arguments[0]
                    })
                }
                return aggregateCore({
                    seed: seed,
                    step: step,
                    finalize: finalize
                })
            };
            var standardAggregate = function(name) {
                return aggregateCore(dataUtils.aggregators[name])
            };
            var select = function(getter) {
                if (!$.isFunction(getter) && !$.isArray(getter)) {
                    getter = $.makeArray(arguments)
                }
                return chainQuery(new SelectIterator(iter, getter))
            };
            var selectProp = function(name) {
                return select(compileGetter(name))
            };
            var chainQuery = function(iter) {
                return arrayQueryImpl(iter, queryOptions)
            };
            return {
                toArray: function() {
                    return iter.toArray()
                },
                enumerate: function() {
                    var d = $.Deferred().fail(handleError);
                    try {
                        d.resolve(iter.toArray())
                    } catch (x) {
                        d.reject(x)
                    }
                    return d.promise()
                },
                sortBy: function(getter, desc) {
                    return chainQuery(new SortIterator(iter, getter, desc))
                },
                thenBy: function(getter, desc) {
                    if (iter instanceof SortIterator) {
                        return chainQuery(iter.thenBy(getter, desc))
                    }
                    throw errorsModule.errors.Error("E4004")
                },
                filter: function(criteria) {
                    if (!$.isArray(criteria)) {
                        criteria = $.makeArray(arguments)
                    }
                    return chainQuery(new FilterIterator(iter, criteria))
                },
                slice: function(skip, take) {
                    if (void 0 === take) {
                        take = Number.MAX_VALUE
                    }
                    return chainQuery(new SliceIterator(iter, skip, take))
                },
                select: select,
                groupBy: function(getter) {
                    return chainQuery(new GroupIterator(iter, getter))
                },
                aggregate: aggregate,
                count: function() {
                    if (iter.countable()) {
                        var d = $.Deferred().fail(handleError);
                        try {
                            d.resolve(iter.count())
                        } catch (x) {
                            d.reject(x)
                        }
                        return d.promise()
                    }
                    return standardAggregate("count")
                },
                sum: function(getter) {
                    if (getter) {
                        return selectProp(getter).sum()
                    }
                    return standardAggregate("sum")
                },
                min: function(getter) {
                    if (getter) {
                        return selectProp(getter).min()
                    }
                    return standardAggregate("min")
                },
                max: function(getter) {
                    if (getter) {
                        return selectProp(getter).max()
                    }
                    return standardAggregate("max")
                },
                avg: function(getter) {
                    if (getter) {
                        return selectProp(getter).avg()
                    }
                    return standardAggregate("avg")
                }
            }
        };
        module.exports = arrayQueryImpl
    },
    /*!**************************************!*\
      !*** ./Scripts/data/remote_query.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            queryAdapters = __webpack_require__( /*! ./query_adapters */ 161),
            errorsModule = __webpack_require__( /*! ./errors */ 157),
            arrayQueryImpl = __webpack_require__( /*! ./array_query */ 159);
        var remoteQueryImpl = function(url, queryOptions, tasks) {
            tasks = tasks || [];
            queryOptions = queryOptions || {};
            var createTask = function(name, args) {
                return {
                    name: name,
                    args: args
                }
            };
            var exec = function(executorTask) {
                var _adapterFactory, _adapter, _taskQueue, _currentTask, _mergedSortArgs, d = $.Deferred();
                var rejectWithNotify = function(error) {
                    var handler = queryOptions.errorHandler;
                    if (handler) {
                        handler(error)
                    }
                    errorsModule._errorHandler(error);
                    d.reject(error)
                };

                function mergeSortTask(task) {
                    switch (task.name) {
                        case "sortBy":
                            _mergedSortArgs = [task.args];
                            return true;
                        case "thenBy":
                            if (!_mergedSortArgs) {
                                throw errorsModule.errors.Error("E4004")
                            }
                            _mergedSortArgs.push(task.args);
                            return true
                    }
                    return false
                }

                function unmergeSortTasks() {
                    var head = _taskQueue[0],
                        unmergedTasks = [];
                    if (head && "multiSort" === head.name) {
                        _taskQueue.shift();
                        $.each(head.args[0], function() {
                            unmergedTasks.push(createTask(unmergedTasks.length ? "thenBy" : "sortBy", this))
                        })
                    }
                    _taskQueue = unmergedTasks.concat(_taskQueue)
                }
                try {
                    _adapterFactory = queryOptions.adapter;
                    if (!$.isFunction(_adapterFactory)) {
                        _adapterFactory = queryAdapters[_adapterFactory]
                    }
                    _adapter = _adapterFactory(queryOptions);
                    _taskQueue = [].concat(tasks).concat(executorTask);
                    while (_taskQueue.length) {
                        _currentTask = _taskQueue[0];
                        if (!mergeSortTask(_currentTask)) {
                            if (_mergedSortArgs) {
                                _taskQueue.unshift(createTask("multiSort", [_mergedSortArgs]));
                                _mergedSortArgs = null;
                                continue
                            }
                            if ("enumerate" !== String(_currentTask.name)) {
                                if (!_adapter[_currentTask.name] || false === _adapter[_currentTask.name].apply(_adapter, _currentTask.args)) {
                                    break
                                }
                            }
                        }
                        _taskQueue.shift()
                    }
                    unmergeSortTasks();
                    _adapter.exec(url).done(function(result, extra) {
                        if (!_taskQueue.length) {
                            d.resolve(result, extra)
                        } else {
                            var clientChain = arrayQueryImpl(result, {
                                errorHandler: queryOptions.errorHandler
                            });
                            $.each(_taskQueue, function() {
                                clientChain = clientChain[this.name].apply(clientChain, this.args)
                            });
                            clientChain.done(d.resolve).fail(d.reject)
                        }
                    }).fail(rejectWithNotify)
                } catch (x) {
                    rejectWithNotify(x)
                }
                return d.promise()
            };
            var query = {};
            $.each(["sortBy", "thenBy", "filter", "slice", "select", "groupBy"], function() {
                var name = String(this);
                query[name] = function() {
                    return remoteQueryImpl(url, queryOptions, tasks.concat(createTask(name, arguments)))
                }
            });
            $.each(["count", "min", "max", "sum", "avg", "aggregate", "enumerate"], function() {
                var name = String(this);
                query[name] = function() {
                    return exec.call(this, createTask(name, arguments))
                }
            });
            return query
        };
        module.exports = remoteQueryImpl
    },
    /*!****************************************!*\
      !*** ./Scripts/data/query_adapters.js ***!
      \****************************************/
    function(module, exports) {
        var queryAdapters = {};
        module.exports = queryAdapters
    },
    /*!*************************************!*\
      !*** ./Scripts/data/array_store.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../core/guid */ 153),
            objectUtils = __webpack_require__( /*! ../core/utils/object */ 37),
            keysEqual = __webpack_require__( /*! ./utils */ 137).keysEqual,
            Query = __webpack_require__( /*! ./query */ 158),
            errors = __webpack_require__( /*! ./errors */ 157).errors,
            Store = __webpack_require__( /*! ./abstract_store */ 156);
        var hasKey = function(target, keyOrKeys) {
            var key, keys = $.makeArray(keyOrKeys);
            while (keys.length) {
                key = keys.shift();
                if (key in target) {
                    return true
                }
            }
            return false
        };
        var trivialPromise = function() {
            var d = $.Deferred();
            return d.resolve.apply(d, arguments).promise()
        };
        var rejectedPromise = function() {
            var d = $.Deferred();
            return d.reject.apply(d, arguments).promise()
        };
        var ArrayStore = Store.inherit({
            ctor: function(options) {
                if ($.isArray(options)) {
                    options = {
                        data: options
                    }
                } else {
                    options = options || {}
                }
                this.callBase(options);
                var initialArray = options.data;
                if (initialArray && !$.isArray(initialArray)) {
                    throw errors.Error("E4006")
                }
                this._array = initialArray || []
            },
            createQuery: function() {
                return Query(this._array, {
                    errorHandler: this._errorHandler
                })
            },
            _byKeyImpl: function(key) {
                var index = this._indexByKey(key);
                if (index === -1) {
                    return rejectedPromise(errors.Error("E4009"))
                }
                return trivialPromise(this._array[index])
            },
            _insertImpl: function(values) {
                var keyValue, obj, keyExpr = this.key();
                if ($.isPlainObject(values)) {
                    obj = $.extend({}, values)
                } else {
                    obj = values
                }
                if (keyExpr) {
                    keyValue = this.keyOf(obj);
                    if (void 0 === keyValue || "object" === typeof keyValue && $.isEmptyObject(keyValue)) {
                        if ($.isArray(keyExpr)) {
                            throw errors.Error("E4007")
                        }
                        keyValue = obj[keyExpr] = String(new Guid)
                    } else {
                        if (void 0 !== this._array[this._indexByKey(keyValue)]) {
                            return rejectedPromise(errors.Error("E4008"))
                        }
                    }
                } else {
                    keyValue = obj
                }
                this._array.push(obj);
                return trivialPromise(values, keyValue)
            },
            _updateImpl: function(key, values) {
                var index, target, keyExpr = this.key();
                if (keyExpr) {
                    if (hasKey(values, keyExpr) && !keysEqual(keyExpr, key, this.keyOf(values))) {
                        return rejectedPromise(errors.Error("E4017"))
                    }
                    index = this._indexByKey(key);
                    if (index < 0) {
                        return rejectedPromise(errors.Error("E4009"))
                    }
                    target = this._array[index]
                } else {
                    target = key
                }
                objectUtils.deepExtendArraySafe(target, values);
                return trivialPromise(key, values)
            },
            _removeImpl: function(key) {
                var index = this._indexByKey(key);
                if (index > -1) {
                    this._array.splice(index, 1)
                }
                return trivialPromise(key)
            },
            _indexByKey: function(key) {
                for (var i = 0, arrayLength = this._array.length; i < arrayLength; i++) {
                    if (keysEqual(this.key(), this.keyOf(this._array[i]), key)) {
                        return i
                    }
                }
                return -1
            },
            clear: function() {
                this.fireEvent("modifying");
                this._array = [];
                this.fireEvent("modified")
            }
        }, "array");
        module.exports = ArrayStore
    },
    /*!**************************************!*\
      !*** ./Scripts/data/custom_store.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dataUtils = __webpack_require__( /*! ./utils */ 137),
            errors = __webpack_require__( /*! ./errors */ 157).errors,
            Store = __webpack_require__( /*! ./abstract_store */ 156);
        var TOTAL_COUNT = "totalCount",
            LOAD = "load",
            BY_KEY = "byKey",
            INSERT = "insert",
            UPDATE = "update",
            REMOVE = "remove";

        function isPromise(obj) {
            return obj && $.isFunction(obj.then)
        }

        function trivialPromise(value) {
            return $.Deferred().resolve(value).promise()
        }

        function ensureRequiredFuncOption(name, obj) {
            if (!$.isFunction(obj)) {
                throw errors.Error("E4011", name)
            }
        }

        function throwInvalidUserFuncResult(name) {
            throw errors.Error("E4012", name)
        }

        function createUserFuncFailureHandler(pendingDeferred) {
            function errorMessageFromXhr(promiseArguments) {
                var xhr = promiseArguments[0],
                    textStatus = promiseArguments[1];
                if (!xhr || !xhr.getResponseHeader) {
                    return null
                }
                return dataUtils.errorMessageFromXhr(xhr, textStatus)
            }
            return function(arg) {
                var error;
                if (arg instanceof Error) {
                    error = arg
                } else {
                    error = new Error(errorMessageFromXhr(arguments) || arg && String(arg) || "Unknown error")
                }
                pendingDeferred.reject(error)
            }
        }
        var CustomStore = Store.inherit({
            ctor: function(options) {
                options = options || {};
                this.callBase(options);
                this._useDefaultSearch = !!options.useDefaultSearch;
                this._loadFunc = options[LOAD];
                this._totalCountFunc = options[TOTAL_COUNT];
                this._byKeyFunc = options[BY_KEY];
                this._insertFunc = options[INSERT];
                this._updateFunc = options[UPDATE];
                this._removeFunc = options[REMOVE]
            },
            createQuery: function() {
                throw errors.Error("E4010")
            },
            _totalCountImpl: function(options) {
                var userResult, userFunc = this._totalCountFunc,
                    d = $.Deferred();
                ensureRequiredFuncOption(TOTAL_COUNT, userFunc);
                userResult = userFunc.apply(this, [options]);
                if (!isPromise(userResult)) {
                    userResult = Number(userResult);
                    if (!isFinite(userResult)) {
                        throwInvalidUserFuncResult(TOTAL_COUNT)
                    }
                    userResult = trivialPromise(userResult)
                }
                userResult.then(function(count) {
                    d.resolve(Number(count))
                }, createUserFuncFailureHandler(d));
                return this._addFailHandlers(d.promise())
            },
            _loadImpl: function(options) {
                var userResult, userFunc = this._loadFunc,
                    d = $.Deferred();
                ensureRequiredFuncOption(LOAD, userFunc);
                userResult = userFunc.apply(this, [options]);
                if ($.isArray(userResult)) {
                    userResult = trivialPromise(userResult)
                } else {
                    if (null === userResult || void 0 === userResult) {
                        userResult = trivialPromise([])
                    } else {
                        if (!isPromise(userResult)) {
                            throwInvalidUserFuncResult(LOAD)
                        }
                    }
                }
                userResult.then(function(data, extra) {
                    d.resolve(data, extra)
                }, createUserFuncFailureHandler(d));
                return this._addFailHandlers(d.promise())
            },
            _byKeyImpl: function(key, extraOptions) {
                var userResult, userFunc = this._byKeyFunc,
                    d = $.Deferred();
                ensureRequiredFuncOption(BY_KEY, userFunc);
                userResult = userFunc.apply(this, [key, extraOptions]);
                if (!isPromise(userResult)) {
                    userResult = trivialPromise(userResult)
                }
                userResult.then(function(obj) {
                    d.resolve(obj)
                }, createUserFuncFailureHandler(d));
                return d.promise()
            },
            _insertImpl: function(values) {
                var userResult, userFunc = this._insertFunc,
                    d = $.Deferred();
                ensureRequiredFuncOption(INSERT, userFunc);
                userResult = userFunc.apply(this, [values]);
                if (!isPromise(userResult)) {
                    userResult = trivialPromise(userResult)
                }
                userResult.then(function(newKey) {
                    d.resolve(values, newKey)
                }, createUserFuncFailureHandler(d));
                return d.promise()
            },
            _updateImpl: function(key, values) {
                var userResult, userFunc = this._updateFunc,
                    d = $.Deferred();
                ensureRequiredFuncOption(UPDATE, userFunc);
                userResult = userFunc.apply(this, [key, values]);
                if (!isPromise(userResult)) {
                    userResult = trivialPromise()
                }
                userResult.then(function() {
                    d.resolve(key, values)
                }, createUserFuncFailureHandler(d));
                return d.promise()
            },
            _removeImpl: function(key) {
                var userResult, userFunc = this._removeFunc,
                    d = $.Deferred();
                ensureRequiredFuncOption(REMOVE, userFunc);
                userResult = userFunc.apply(this, [key]);
                if (!isPromise(userResult)) {
                    userResult = trivialPromise()
                }
                userResult.then(function() {
                    d.resolve(key)
                }, createUserFuncFailureHandler(d));
                return d.promise()
            }
        });
        module.exports = CustomStore
    },
    /*!********************************!*\
      !*** ./Scripts/events/hold.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            eventUtils = __webpack_require__( /*! ./utils */ 62),
            Emitter = __webpack_require__( /*! ./core/emitter */ 75),
            registerEmitter = __webpack_require__( /*! ./core/emitter_registrator */ 76),
            abs = Math.abs;
        var HOLD_EVENT_NAME = "dxhold",
            HOLD_TIMEOUT = 750,
            TOUCH_BOUNDARY = 5;
        var HoldEmitter = Emitter.inherit({
            start: function(e) {
                this._startEventData = eventUtils.eventData(e);
                this._startTimer(e)
            },
            _startTimer: function(e) {
                var holdTimeout = "timeout" in this ? this.timeout : HOLD_TIMEOUT;
                this._holdTimer = setTimeout($.proxy(function() {
                    this._requestAccept(e);
                    this._fireEvent(HOLD_EVENT_NAME, e, {
                        target: e.target
                    });
                    this._forgetAccept()
                }, this), holdTimeout)
            },
            move: function(e) {
                if (this._touchWasMoved(e)) {
                    this._cancel(e)
                }
            },
            _touchWasMoved: function(e) {
                var delta = eventUtils.eventDelta(this._startEventData, eventUtils.eventData(e));
                return abs(delta.x) > TOUCH_BOUNDARY || abs(delta.y) > TOUCH_BOUNDARY
            },
            end: function() {
                this._stopTimer()
            },
            _stopTimer: function() {
                clearTimeout(this._holdTimer)
            },
            cancel: function() {
                this._stopTimer()
            }
        });
        registerEmitter({
            emitter: HoldEmitter,
            bubble: true,
            events: [HOLD_EVENT_NAME]
        });
        module.exports = {
            name: HOLD_EVENT_NAME
        }
    },
    /*!***************************************!*\
      !*** ./Scripts/events/contextmenu.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            support = __webpack_require__( /*! ../core/utils/support */ 48),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            Class = __webpack_require__( /*! ../core/class */ 20),
            registerEvent = __webpack_require__( /*! ./core/event_registrator */ 66),
            eventUtils = __webpack_require__( /*! ./utils */ 62),
            holdEvent = __webpack_require__( /*! ./hold */ 164);
        var CONTEXTMENU_NAMESPACE = "dxContexMenu",
            CONTEXTMENU_NAMESPACED_EVENT_NAME = eventUtils.addNamespace("contextmenu", CONTEXTMENU_NAMESPACE),
            HOLD_NAMESPACED_EVENT_NAME = eventUtils.addNamespace(holdEvent.name, CONTEXTMENU_NAMESPACE),
            CONTEXTMENU_EVENT_NAME = "dxcontextmenu";
        var ContextMenu = Class.inherit({
            setup: function(element, data) {
                var $element = $(element);
                $element.on(CONTEXTMENU_NAMESPACED_EVENT_NAME, $.proxy(this._contextMenuHandler, this));
                if (support.touch || devices.isSimulator()) {
                    $element.on(HOLD_NAMESPACED_EVENT_NAME, $.proxy(this._holdHandler, this))
                }
            },
            _holdHandler: function(e) {
                if (eventUtils.isMouseEvent(e) && !devices.isSimulator()) {
                    return
                }
                this._fireContextMenu(e)
            },
            _contextMenuHandler: function(e) {
                this._fireContextMenu(e)
            },
            _fireContextMenu: function(e) {
                return eventUtils.fireEvent({
                    type: CONTEXTMENU_EVENT_NAME,
                    originalEvent: e
                })
            },
            teardown: function(element) {
                $(element).off("." + CONTEXTMENU_NAMESPACE)
            }
        });
        registerEvent(CONTEXTMENU_EVENT_NAME, new ContextMenu);
        exports.name = CONTEXTMENU_EVENT_NAME
    },
    /*!***************************************************************************!*\
      !*** ./Scripts/ui/collection/ui.collection_widget.edit.strategy.plain.js ***!
      \***************************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            arrayUtils = __webpack_require__( /*! ../../core/utils/array */ 111),
            EditStrategy = __webpack_require__( /*! ./ui.collection_widget.edit.strategy */ 167);
        var PlainEditStrategy = EditStrategy.inherit({
            _getPlainItems: function() {
                return this._collectionWidget.option("items") || []
            },
            getIndexByItemData: function(itemData) {
                return $.inArray(itemData, this._getPlainItems())
            },
            getItemDataByIndex: function(index) {
                return this._getPlainItems()[index]
            },
            deleteItemAtIndex: function(index) {
                this._getPlainItems().splice(index, 1)
            },
            updateSelectionAfterDelete: function(fromIndex) {
                var selectedItemIndices = this._collectionWidget._selectedItemIndices;
                $.each(selectedItemIndices, function(i, index) {
                    if (index > fromIndex) {
                        selectedItemIndices[i] -= 1
                    }
                })
            },
            fetchSelectedItems: function(indices) {
                indices = indices || this._collectionWidget._selectedItemIndices;
                indices.sort(function(a, b) {
                    return a - b
                });
                var items = this._getPlainItems(),
                    selectedItems = [];
                $.each(indices, function(_, index) {
                    selectedItems.push(items[index])
                });
                if (this._collectionWidget._dataSource && "single" !== this._collectionWidget.option("selectionMode")) {
                    var allSelectedItems = this._collectionWidget.option("selectedItems"),
                        unavailableItems = $.grep(allSelectedItems, function(item) {
                            return $.inArray(item, items) === -1
                        });
                    selectedItems = selectedItems.concat(unavailableItems)
                }
                return selectedItems
            },
            fetchSelectionDifference: function(addedSelection, removedSelection) {
                var difference = this.callBase(addedSelection, removedSelection);
                if (this._collectionWidget._dataSource) {
                    var addedItems = difference.addedItems,
                        removedItems = difference.removedItems,
                        duplicatedItems = arrayUtils.intersection(addedItems, removedItems);
                    $.each(duplicatedItems, function(_, item) {
                        var addedItemIndex = $.inArray(item, addedItems),
                            removedItemIndex = $.inArray(item, removedItems);
                        addedItems.splice(addedItemIndex, 1);
                        removedItems.splice(removedItemIndex, 1)
                    })
                }
                return difference
            },
            selectedItemIndices: function() {
                var selectedIndices = [],
                    items = this._getPlainItems(),
                    selected = this._collectionWidget.option("selectedItems"),
                    dataSource = this._collectionWidget._dataSource;
                $.each(selected, function(_, selectedItem) {
                    var index = $.inArray(selectedItem, items);
                    if (index !== -1) {
                        selectedIndices.push(index)
                    } else {
                        if (!dataSource) {
                            errors.log("W1002", selectedItem)
                        }
                    }
                });
                return selectedIndices
            },
            moveItemAtIndexToIndex: function(movingIndex, destinationIndex) {
                var items = this._getPlainItems(),
                    movedItemData = items[movingIndex];
                items.splice(movingIndex, 1);
                items.splice(destinationIndex, 0, movedItemData)
            },
            _isItemIndex: function(index) {
                return "number" === typeof index && Math.round(index) === index
            },
            _getNormalizedItemIndex: function(itemElement) {
                return this._collectionWidget._itemElements().index(itemElement)
            },
            _normalizeItemIndex: function(index) {
                return index
            },
            _denormalizeItemIndex: function(index) {
                return index
            },
            _getItemByNormalizedIndex: function(index) {
                return index > -1 ? this._collectionWidget._itemElements().eq(index) : null
            },
            _itemsFromSameParent: function() {
                return true
            }
        });
        module.exports = PlainEditStrategy
    },
    /*!*********************************************************************!*\
      !*** ./Scripts/ui/collection/ui.collection_widget.edit.strategy.js ***!
      \*********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            abstract = Class.abstract;
        var EditStrategy = Class.inherit({
            ctor: function(collectionWidget) {
                this._collectionWidget = collectionWidget
            },
            getIndexByItemData: abstract,
            getItemDataByIndex: abstract,
            getNormalizedIndex: function(value) {
                if (this._isNormalizedItemIndex(value)) {
                    return value
                }
                if (this._isItemIndex(value)) {
                    return this._normalizeItemIndex(value)
                }
                if (this._isDOMNode(value)) {
                    return this._getNormalizedItemIndex(value)
                }
                return this._normalizeItemIndex(this.getIndexByItemData(value))
            },
            getIndex: function(value) {
                if (this._isNormalizedItemIndex(value)) {
                    return this._denormalizeItemIndex(value)
                }
                if (this._isItemIndex(value)) {
                    return value
                }
                if (this._isDOMNode(value)) {
                    return this._denormalizeItemIndex(this._getNormalizedItemIndex(value))
                }
                return this.getIndexByItemData(value)
            },
            getItemElement: function(value) {
                if (this._isNormalizedItemIndex(value)) {
                    return this._getItemByNormalizedIndex(value)
                }
                if (this._isItemIndex(value)) {
                    return this._getItemByNormalizedIndex(this._normalizeItemIndex(value))
                }
                if (this._isDOMNode(value)) {
                    return $(value)
                }
                return this._getItemByNormalizedIndex(this.getIndexByItemData(value))
            },
            deleteItemAtIndex: abstract,
            updateSelectionAfterDelete: abstract,
            fetchSelectedItems: abstract,
            fetchSelectionDifference: function(addedSelection, removedSelection) {
                return {
                    addedItems: this.fetchSelectedItems(addedSelection),
                    removedItems: this.fetchSelectedItems(removedSelection)
                }
            },
            selectedItemIndices: abstract,
            itemPlacementFunc: function(movingIndex, destinationIndex) {
                return this._itemsFromSameParent(movingIndex, destinationIndex) && movingIndex < destinationIndex ? "after" : "before"
            },
            moveItemAtIndexToIndex: abstract,
            getSelectedItemsAfterReorderItem: function() {
                return this._collectionWidget.option("selectedItems")
            },
            _isNormalizedItemIndex: function(index) {
                return "number" === typeof index && Math.round(index) === index
            },
            _isDOMNode: function(value) {
                var $value;
                try {
                    $value = $(value)
                } catch (error) {
                    return false
                }
                return $value && $value.length && $value.get(0).nodeType
            },
            _isItemIndex: abstract,
            _getNormalizedItemIndex: abstract,
            _normalizeItemIndex: abstract,
            _denormalizeItemIndex: abstract,
            _getItemByNormalizedIndex: abstract,
            _itemsFromSameParent: abstract
        });
        module.exports = EditStrategy
    },
    /*!**********************************************************!*\
      !*** ./Scripts/integration/angular/event_registrator.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            eventRegistrator = __webpack_require__( /*! ../../events/core/event_registrator */ 66),
            ngModule = __webpack_require__( /*! ./module */ 150);
        eventRegistrator.callbacks.add(function(name, eventObject) {
            var ngEventName = name.slice(0, 2) + name.charAt(2).toUpperCase() + name.slice(3);
            ngModule.directive(ngEventName, ["$parse", function($parse) {
                return function(scope, element, attr) {
                    var handler, attrValue = $.trim(attr[ngEventName]),
                        eventOptions = {};
                    if ("{" === attrValue.charAt(0)) {
                        eventOptions = scope.$eval(attrValue);
                        handler = $parse(eventOptions.execute)
                    } else {
                        handler = $parse(attr[ngEventName])
                    }
                    element.on(name, eventOptions, function(e) {
                        scope.$apply(function() {
                            handler(scope, {
                                $event: e
                            })
                        })
                    })
                }
            }])
        })
    },
    /*!***************************************************!*\
      !*** ./Scripts/integration/angular/components.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            MemorizedCallbacks = __webpack_require__( /*! ../../core/memorized_callbacks */ 44),
            ngModule = __webpack_require__( /*! ./module */ 150),
            iconUtils = __webpack_require__( /*! ../../core/utils/icon */ 99),
            inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49),
            errors = __webpack_require__( /*! ../../core/errors */ 17);
        ngModule.directive("dxIcon", ["$compile", function($compile) {
            return {
                restrict: "E",
                link: function($scope, $element, $attrs) {
                    var html = iconUtils.getImageContainer($scope.dxTemplateModel.icon || $scope.dxTemplateModel.iconSrc);
                    if (html) {
                        var e = $compile(html.get(0))($scope);
                        $element.replaceWith(e)
                    }
                }
            }
        }]);
        ngModule.directive("dxPolymorphWidget", ["$compile", function($compile) {
            return {
                restrict: "E",
                scope: {
                    name: "=",
                    options: "="
                },
                link: function($scope, $element, $attrs) {
                    var widgetName = $scope.name;
                    if (!widgetName) {
                        return
                    }
                    if ("button" === widgetName || "tabs" === widgetName || "dropDownMenu" === widgetName) {
                        var depricatedName = widgetName;
                        widgetName = inflector.camelize("dx-" + widgetName);
                        errors.log("W0001", "dxToolbar - 'widget' item field", depricatedName, "16.1", "Use: '" + widgetName + "' instead")
                    }
                    var markup = $("<div " + inflector.dasherize(widgetName) + '="options">').get(0);
                    $element.after(markup);
                    $compile(markup)($scope)
                }
            }
        }]);
        ngModule.service("dxDigestCallbacks", ["$rootScope", function($rootScope) {
            var begin = new MemorizedCallbacks,
                end = new MemorizedCallbacks;
            var digestPhase = false;
            $rootScope.$watch(function() {
                if (digestPhase) {
                    return
                }
                digestPhase = true;
                begin.fire();
                $rootScope.$$postDigest(function() {
                    digestPhase = false;
                    end.fire()
                })
            });
            return {
                begin: begin,
                end: end
            }
        }])
    },
    /*!*********************************************************!*\
      !*** ./Scripts/integration/angular/action_executors.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var Action = __webpack_require__( /*! ../../core/action */ 35);
        Action.registerExecutor({
            ngExpression: {
                execute: function(e) {
                    if ("string" === typeof e.action) {
                        e.context.$eval(e.action)
                    }
                }
            }
        })
    },
    /*!************************************************!*\
      !*** ./Scripts/localization/globalize/core.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var Globalize = __webpack_require__( /*! globalize */ 172);
        if (Globalize && Globalize.load) {
            var likelySubtags = {
                supplemental: {
                    version: {
                        _cldrVersion: "28",
                        _unicodeVersion: "8.0.0",
                        _number: "$Revision: 1.1 $"
                    },
                    likelySubtags: {
                        en: "en-Latn-US",
                        de: "de-Latn-DE",
                        ru: "ru-Cyrl-RU",
                        ja: "ja-Jpan-JP"
                    }
                }
            };
            if (!Globalize.locale()) {
                Globalize.load(likelySubtags);
                Globalize.locale("en")
            }
        }
    },
    /*!***********************************!*\
      !*** external "window.Globalize" ***!
      \***********************************/
    function(module, exports) {
        module.exports = window.Globalize
    },
    /*!***************************************************!*\
      !*** ./Scripts/localization/globalize/message.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./core */ 171);
        var Globalize = __webpack_require__( /*! globalize */ 172),
            messageLocalization = __webpack_require__( /*! ../message */ 80);
        __webpack_require__( /*! globalize/message */ 172);
        if (Globalize && Globalize.formatMessage) {
            var DEFAULT_LOCALE = "en";
            var originalLoadMessages = Globalize.loadMessages;
            Globalize.loadMessages = function(messages) {
                messageLocalization.load(messages)
            };
            var globalizeMessageLocalization = {
                ctor: function() {
                    this.load(this._dictionary)
                },
                load: function(messages) {
                    this.callBase(messages);
                    originalLoadMessages(messages)
                },
                locale: function(locale) {
                    if (!locale) {
                        return Globalize.locale().locale
                    }
                    Globalize.locale(locale)
                },
                getMessagesByLocales: function() {
                    return Globalize.cldr.get("globalize-messages")
                },
                getFormatter: function(key, locale) {
                    var currentLocale = locale || this.locale(),
                        formatter = this.callBase(key, locale);
                    if (!formatter) {
                        formatter = this._formatterByGlobalize(key, locale)
                    }
                    if (!formatter && currentLocale !== DEFAULT_LOCALE) {
                        formatter = this.getFormatter(key, DEFAULT_LOCALE)
                    }
                    return formatter
                },
                _formatterByGlobalize: function(key, locale) {
                    var result, currentGlobalize = !locale || locale === this.locale() ? Globalize : new Globalize(locale);
                    if (this._messageLoaded(key, locale)) {
                        result = currentGlobalize.messageFormatter(key)
                    }
                    return result
                },
                _messageLoaded: function(key, locale) {
                    var currentCldr = locale ? new Globalize(locale).cldr : Globalize.locale(),
                        value = currentCldr.get(["globalize-messages/{bundle}", key]);
                    return void 0 !== value
                },
                _loadSingle: function(key, value, locale) {
                    var data = {};
                    data[locale] = {};
                    data[locale][key] = value;
                    this.load(data)
                }
            };
            messageLocalization.inject(globalizeMessageLocalization)
        }
    },
    /*!**************************************************!*\
      !*** ./Scripts/localization/globalize/number.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./core */ 171);
        var Globalize = __webpack_require__( /*! globalize */ 172),
            numberLocalization = __webpack_require__( /*! ../number */ 22),
            errors = __webpack_require__( /*! ../../core/errors */ 17);
        __webpack_require__( /*! globalize/number */ 172);
        if (Globalize && Globalize.formatNumber) {
            var enNumbers = {
                main: {
                    en: {
                        identity: {
                            version: {
                                _cldrVersion: "28",
                                _number: "$Revision: 1.1 $"
                            },
                            language: "en"
                        },
                        numbers: {
                            defaultNumberingSystem: "latn",
                            otherNumberingSystems: {
                                "native": "latn"
                            },
                            minimumGroupingDigits: "1",
                            "symbols-numberSystem-latn": {
                                decimal: ".",
                                group: ",",
                                list: ";",
                                percentSign: "%",
                                plusSign: "+",
                                minusSign: "-",
                                exponential: "E",
                                superscriptingExponent: "×",
                                perMille: "‰",
                                infinity: "∞",
                                nan: "NaN",
                                timeSeparator: ":"
                            },
                            "decimalFormats-numberSystem-latn": {
                                standard: "#,##0.###",
                                "long": {
                                    decimalFormat: {
                                        "1000-count-one": "0 thousand",
                                        "1000-count-other": "0 thousand",
                                        "10000-count-one": "00 thousand",
                                        "10000-count-other": "00 thousand",
                                        "100000-count-one": "000 thousand",
                                        "100000-count-other": "000 thousand",
                                        "1000000-count-one": "0 million",
                                        "1000000-count-other": "0 million",
                                        "10000000-count-one": "00 million",
                                        "10000000-count-other": "00 million",
                                        "100000000-count-one": "000 million",
                                        "100000000-count-other": "000 million",
                                        "1000000000-count-one": "0 billion",
                                        "1000000000-count-other": "0 billion",
                                        "10000000000-count-one": "00 billion",
                                        "10000000000-count-other": "00 billion",
                                        "100000000000-count-one": "000 billion",
                                        "100000000000-count-other": "000 billion",
                                        "1000000000000-count-one": "0 trillion",
                                        "1000000000000-count-other": "0 trillion",
                                        "10000000000000-count-one": "00 trillion",
                                        "10000000000000-count-other": "00 trillion",
                                        "100000000000000-count-one": "000 trillion",
                                        "100000000000000-count-other": "000 trillion"
                                    }
                                },
                                "short": {
                                    decimalFormat: {
                                        "1000-count-one": "0K",
                                        "1000-count-other": "0K",
                                        "10000-count-one": "00K",
                                        "10000-count-other": "00K",
                                        "100000-count-one": "000K",
                                        "100000-count-other": "000K",
                                        "1000000-count-one": "0M",
                                        "1000000-count-other": "0M",
                                        "10000000-count-one": "00M",
                                        "10000000-count-other": "00M",
                                        "100000000-count-one": "000M",
                                        "100000000-count-other": "000M",
                                        "1000000000-count-one": "0B",
                                        "1000000000-count-other": "0B",
                                        "10000000000-count-one": "00B",
                                        "10000000000-count-other": "00B",
                                        "100000000000-count-one": "000B",
                                        "100000000000-count-other": "000B",
                                        "1000000000000-count-one": "0T",
                                        "1000000000000-count-other": "0T",
                                        "10000000000000-count-one": "00T",
                                        "10000000000000-count-other": "00T",
                                        "100000000000000-count-one": "000T",
                                        "100000000000000-count-other": "000T"
                                    }
                                }
                            },
                            "scientificFormats-numberSystem-latn": {
                                standard: "#E0"
                            },
                            "percentFormats-numberSystem-latn": {
                                standard: "#,##0%"
                            },
                            "currencyFormats-numberSystem-latn": {
                                currencySpacing: {
                                    beforeCurrency: {
                                        currencyMatch: "[:^S:]",
                                        surroundingMatch: "[:digit:]",
                                        insertBetween: " "
                                    },
                                    afterCurrency: {
                                        currencyMatch: "[:^S:]",
                                        surroundingMatch: "[:digit:]",
                                        insertBetween: " "
                                    }
                                },
                                standard: "¤#,##0.00",
                                accounting: "¤#,##0.00;(¤#,##0.00)",
                                "short": {
                                    standard: {
                                        "1000-count-one": "¤0K",
                                        "1000-count-other": "¤0K",
                                        "10000-count-one": "¤00K",
                                        "10000-count-other": "¤00K",
                                        "100000-count-one": "¤000K",
                                        "100000-count-other": "¤000K",
                                        "1000000-count-one": "¤0M",
                                        "1000000-count-other": "¤0M",
                                        "10000000-count-one": "¤00M",
                                        "10000000-count-other": "¤00M",
                                        "100000000-count-one": "¤000M",
                                        "100000000-count-other": "¤000M",
                                        "1000000000-count-one": "¤0B",
                                        "1000000000-count-other": "¤0B",
                                        "10000000000-count-one": "¤00B",
                                        "10000000000-count-other": "¤00B",
                                        "100000000000-count-one": "¤000B",
                                        "100000000000-count-other": "¤000B",
                                        "1000000000000-count-one": "¤0T",
                                        "1000000000000-count-other": "¤0T",
                                        "10000000000000-count-one": "¤00T",
                                        "10000000000000-count-other": "¤00T",
                                        "100000000000000-count-one": "¤000T",
                                        "100000000000000-count-other": "¤000T"
                                    }
                                },
                                "unitPattern-count-one": "{0} {1}",
                                "unitPattern-count-other": "{0} {1}"
                            },
                            "miscPatterns-numberSystem-latn": {
                                atLeast: "{0}+",
                                range: "{0}–{1}"
                            }
                        }
                    }
                }
            };
            if ("en" === Globalize.locale().locale) {
                Globalize.load(enNumbers);
                Globalize.locale("en")
            }
            var formattersCache = {};
            var getFormatter = function(format) {
                var formatter, formatCacheKey;
                if ("object" === typeof format) {
                    formatCacheKey = Globalize.locale().locale + ":" + JSON.stringify(format)
                } else {
                    formatCacheKey = Globalize.locale().locale + ":" + format
                }
                formatter = formattersCache[formatCacheKey];
                if (!formatter) {
                    formatter = formattersCache[formatCacheKey] = Globalize.numberFormatter(format)
                }
                return formatter
            };
            var globalizeNumberLocalization = {
                _formatNumberCore: function(value, format, formatConfig) {
                    if ("exponential" === format) {
                        return this.callBase.apply(this, arguments)
                    }
                    return getFormatter(this._normalizeFormatConfig(format, formatConfig, value))(value)
                },
                _normalizeFormatConfig: function(format, formatConfig, value) {
                    var config;
                    if ("decimal" === format) {
                        config = {
                            minimumIntegerDigits: formatConfig.precision || 1,
                            useGrouping: false,
                            maximumFractionDigits: 0,
                            round: value < 0 ? "ceil" : "floor"
                        }
                    } else {
                        config = {
                            minimumFractionDigits: formatConfig.precision || 0,
                            maximumFractionDigits: formatConfig.precision || 0
                        }
                    }
                    if ("percent" === format) {
                        config.style = "percent"
                    }
                    return config
                },
                format: function(value, format) {
                    if ("number" !== typeof value) {
                        return value
                    }
                    format = this._normalizeFormat(format);
                    if (!format || "function" !== typeof format && !format.type && !format.formatter) {
                        return getFormatter(format)(value)
                    }
                    return this.callBase.apply(this, arguments)
                },
                parse: function(text, format) {
                    if (!text) {
                        return
                    }
                    if (format && format.parser) {
                        return format.parser(text)
                    }
                    if (format) {
                        errors.log("W0011")
                    }
                    return Globalize.parseNumber(text)
                }
            };
            numberLocalization.inject(globalizeNumberLocalization)
        }
    },
    /*!************************************************!*\
      !*** ./Scripts/localization/globalize/date.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./core */ 171);
        __webpack_require__( /*! ./number */ 174);
        __webpack_require__( /*! globalize/date */ 172);
        var timeData = {
            supplemental: {
                version: {
                    _cldrVersion: "28",
                    _unicodeVersion: "8.0.0",
                    _number: "$Revision: 1.1 $"
                },
                timeData: {
                    "001": {
                        _allowed: "H h",
                        _preferred: "H"
                    },
                    DE: {
                        _allowed: "H",
                        _preferred: "H"
                    },
                    JP: {
                        _allowed: "H K h",
                        _preferred: "H"
                    },
                    RU: {
                        _allowed: "H",
                        _preferred: "H"
                    },
                    US: {
                        _allowed: "H h",
                        _preferred: "h"
                    }
                }
            }
        };
        var enCaGregorian = {
            main: {
                en: {
                    identity: {
                        version: {
                            _cldrVersion: "28",
                            _number: "$Revision: 1.1 $"
                        },
                        language: "en"
                    },
                    dates: {
                        calendars: {
                            gregorian: {
                                months: {
                                    format: {
                                        abbreviated: {
                                            1: "Jan",
                                            2: "Feb",
                                            3: "Mar",
                                            4: "Apr",
                                            5: "May",
                                            6: "Jun",
                                            7: "Jul",
                                            8: "Aug",
                                            9: "Sep",
                                            10: "Oct",
                                            11: "Nov",
                                            12: "Dec"
                                        },
                                        narrow: {
                                            1: "J",
                                            2: "F",
                                            3: "M",
                                            4: "A",
                                            5: "M",
                                            6: "J",
                                            7: "J",
                                            8: "A",
                                            9: "S",
                                            10: "O",
                                            11: "N",
                                            12: "D"
                                        },
                                        wide: {
                                            1: "January",
                                            2: "February",
                                            3: "March",
                                            4: "April",
                                            5: "May",
                                            6: "June",
                                            7: "July",
                                            8: "August",
                                            9: "September",
                                            10: "October",
                                            11: "November",
                                            12: "December"
                                        }
                                    },
                                    "stand-alone": {
                                        abbreviated: {
                                            1: "Jan",
                                            2: "Feb",
                                            3: "Mar",
                                            4: "Apr",
                                            5: "May",
                                            6: "Jun",
                                            7: "Jul",
                                            8: "Aug",
                                            9: "Sep",
                                            10: "Oct",
                                            11: "Nov",
                                            12: "Dec"
                                        },
                                        narrow: {
                                            1: "J",
                                            2: "F",
                                            3: "M",
                                            4: "A",
                                            5: "M",
                                            6: "J",
                                            7: "J",
                                            8: "A",
                                            9: "S",
                                            10: "O",
                                            11: "N",
                                            12: "D"
                                        },
                                        wide: {
                                            1: "January",
                                            2: "February",
                                            3: "March",
                                            4: "April",
                                            5: "May",
                                            6: "June",
                                            7: "July",
                                            8: "August",
                                            9: "September",
                                            10: "October",
                                            11: "November",
                                            12: "December"
                                        }
                                    }
                                },
                                days: {
                                    format: {
                                        abbreviated: {
                                            sun: "Sun",
                                            mon: "Mon",
                                            tue: "Tue",
                                            wed: "Wed",
                                            thu: "Thu",
                                            fri: "Fri",
                                            sat: "Sat"
                                        },
                                        narrow: {
                                            sun: "S",
                                            mon: "M",
                                            tue: "T",
                                            wed: "W",
                                            thu: "T",
                                            fri: "F",
                                            sat: "S"
                                        },
                                        "short": {
                                            sun: "Su",
                                            mon: "Mo",
                                            tue: "Tu",
                                            wed: "We",
                                            thu: "Th",
                                            fri: "Fr",
                                            sat: "Sa"
                                        },
                                        wide: {
                                            sun: "Sunday",
                                            mon: "Monday",
                                            tue: "Tuesday",
                                            wed: "Wednesday",
                                            thu: "Thursday",
                                            fri: "Friday",
                                            sat: "Saturday"
                                        }
                                    },
                                    "stand-alone": {
                                        abbreviated: {
                                            sun: "Sun",
                                            mon: "Mon",
                                            tue: "Tue",
                                            wed: "Wed",
                                            thu: "Thu",
                                            fri: "Fri",
                                            sat: "Sat"
                                        },
                                        narrow: {
                                            sun: "S",
                                            mon: "M",
                                            tue: "T",
                                            wed: "W",
                                            thu: "T",
                                            fri: "F",
                                            sat: "S"
                                        },
                                        "short": {
                                            sun: "Su",
                                            mon: "Mo",
                                            tue: "Tu",
                                            wed: "We",
                                            thu: "Th",
                                            fri: "Fr",
                                            sat: "Sa"
                                        },
                                        wide: {
                                            sun: "Sunday",
                                            mon: "Monday",
                                            tue: "Tuesday",
                                            wed: "Wednesday",
                                            thu: "Thursday",
                                            fri: "Friday",
                                            sat: "Saturday"
                                        }
                                    }
                                },
                                quarters: {
                                    format: {
                                        abbreviated: {
                                            1: "Q1",
                                            2: "Q2",
                                            3: "Q3",
                                            4: "Q4"
                                        },
                                        narrow: {
                                            1: "1",
                                            2: "2",
                                            3: "3",
                                            4: "4"
                                        },
                                        wide: {
                                            1: "1st quarter",
                                            2: "2nd quarter",
                                            3: "3rd quarter",
                                            4: "4th quarter"
                                        }
                                    },
                                    "stand-alone": {
                                        abbreviated: {
                                            1: "Q1",
                                            2: "Q2",
                                            3: "Q3",
                                            4: "Q4"
                                        },
                                        narrow: {
                                            1: "1",
                                            2: "2",
                                            3: "3",
                                            4: "4"
                                        },
                                        wide: {
                                            1: "1st quarter",
                                            2: "2nd quarter",
                                            3: "3rd quarter",
                                            4: "4th quarter"
                                        }
                                    }
                                },
                                dayPeriods: {
                                    format: {
                                        abbreviated: {
                                            midnight: "midnight",
                                            am: "AM",
                                            "am-alt-variant": "am",
                                            noon: "noon",
                                            pm: "PM",
                                            "pm-alt-variant": "pm",
                                            morning1: "in the morning",
                                            afternoon1: "in the afternoon",
                                            evening1: "in the evening",
                                            night1: "at night"
                                        },
                                        narrow: {
                                            midnight: "mi",
                                            am: "a",
                                            "am-alt-variant": "am",
                                            noon: "n",
                                            pm: "p",
                                            "pm-alt-variant": "pm",
                                            morning1: "in the morning",
                                            afternoon1: "in the afternoon",
                                            evening1: "in the evening",
                                            night1: "at night"
                                        },
                                        wide: {
                                            midnight: "midnight",
                                            am: "AM",
                                            "am-alt-variant": "am",
                                            noon: "noon",
                                            pm: "PM",
                                            "pm-alt-variant": "pm",
                                            morning1: "in the morning",
                                            afternoon1: "in the afternoon",
                                            evening1: "in the evening",
                                            night1: "at night"
                                        }
                                    },
                                    "stand-alone": {
                                        abbreviated: {
                                            midnight: "midnight",
                                            am: "AM",
                                            "am-alt-variant": "am",
                                            noon: "noon",
                                            pm: "PM",
                                            "pm-alt-variant": "pm",
                                            morning1: "in the morning",
                                            afternoon1: "in the afternoon",
                                            evening1: "in the evening",
                                            night1: "at night"
                                        },
                                        narrow: {
                                            midnight: "midnight",
                                            am: "AM",
                                            "am-alt-variant": "am",
                                            noon: "noon",
                                            pm: "PM",
                                            "pm-alt-variant": "pm",
                                            morning1: "in the morning",
                                            afternoon1: "in the afternoon",
                                            evening1: "in the evening",
                                            night1: "at night"
                                        },
                                        wide: {
                                            midnight: "midnight",
                                            am: "AM",
                                            "am-alt-variant": "am",
                                            noon: "noon",
                                            pm: "PM",
                                            "pm-alt-variant": "pm",
                                            morning1: "morning",
                                            afternoon1: "afternoon",
                                            evening1: "evening",
                                            night1: "night"
                                        }
                                    }
                                },
                                eras: {
                                    eraNames: {
                                        0: "Before Christ",
                                        "0-alt-variant": "Before Common Era",
                                        1: "Anno Domini",
                                        "1-alt-variant": "Common Era"
                                    },
                                    eraAbbr: {
                                        0: "BC",
                                        "0-alt-variant": "BCE",
                                        1: "AD",
                                        "1-alt-variant": "CE"
                                    },
                                    eraNarrow: {
                                        0: "B",
                                        "0-alt-variant": "BCE",
                                        1: "A",
                                        "1-alt-variant": "CE"
                                    }
                                },
                                dateFormats: {
                                    full: "EEEE, MMMM d, y",
                                    "long": "MMMM d, y",
                                    medium: "MMM d, y",
                                    "short": "M/d/yy"
                                },
                                timeFormats: {
                                    full: "h:mm:ss a zzzz",
                                    "long": "h:mm:ss a z",
                                    medium: "h:mm:ss a",
                                    "short": "h:mm a"
                                },
                                dateTimeFormats: {
                                    full: "{1} 'at' {0}",
                                    "long": "{1} 'at' {0}",
                                    medium: "{1}, {0}",
                                    "short": "{1}, {0}",
                                    availableFormats: {
                                        d: "d",
                                        E: "ccc",
                                        Ed: "d E",
                                        Ehm: "E h:mm a",
                                        EHm: "E HH:mm",
                                        Ehms: "E h:mm:ss a",
                                        EHms: "E HH:mm:ss",
                                        Gy: "y G",
                                        GyMMM: "MMM y G",
                                        GyMMMd: "MMM d, y G",
                                        GyMMMEd: "E, MMM d, y G",
                                        h: "h a",
                                        H: "HH",
                                        hm: "h:mm a",
                                        Hm: "HH:mm",
                                        hms: "h:mm:ss a",
                                        Hms: "HH:mm:ss",
                                        hmsv: "h:mm:ss a v",
                                        Hmsv: "HH:mm:ss v",
                                        hmv: "h:mm a v",
                                        Hmv: "HH:mm v",
                                        M: "L",
                                        Md: "M/d",
                                        MEd: "E, M/d",
                                        MMM: "LLL",
                                        MMMd: "MMM d",
                                        MMMEd: "E, MMM d",
                                        MMMMd: "MMMM d",
                                        ms: "mm:ss",
                                        y: "y",
                                        yM: "M/y",
                                        yMd: "M/d/y",
                                        yMEd: "E, M/d/y",
                                        yMMM: "MMM y",
                                        yMMMd: "MMM d, y",
                                        yMMMEd: "E, MMM d, y",
                                        yMMMM: "MMMM y",
                                        yQQQ: "QQQ y",
                                        yQQQQ: "QQQQ y"
                                    },
                                    appendItems: {
                                        Day: "{0} ({2}: {1})",
                                        "Day-Of-Week": "{0} {1}",
                                        Era: "{0} {1}",
                                        Hour: "{0} ({2}: {1})",
                                        Minute: "{0} ({2}: {1})",
                                        Month: "{0} ({2}: {1})",
                                        Quarter: "{0} ({2}: {1})",
                                        Second: "{0} ({2}: {1})",
                                        Timezone: "{0} {1}",
                                        Week: "{0} ({2}: {1})",
                                        Year: "{0} {1}"
                                    },
                                    intervalFormats: {
                                        intervalFormatFallback: "{0} – {1}",
                                        d: {
                                            d: "d – d"
                                        },
                                        h: {
                                            a: "h a – h a",
                                            h: "h – h a"
                                        },
                                        H: {
                                            H: "HH – HH"
                                        },
                                        hm: {
                                            a: "h:mm a – h:mm a",
                                            h: "h:mm – h:mm a",
                                            m: "h:mm – h:mm a"
                                        },
                                        Hm: {
                                            H: "HH:mm – HH:mm",
                                            m: "HH:mm – HH:mm"
                                        },
                                        hmv: {
                                            a: "h:mm a – h:mm a v",
                                            h: "h:mm – h:mm a v",
                                            m: "h:mm – h:mm a v"
                                        },
                                        Hmv: {
                                            H: "HH:mm – HH:mm v",
                                            m: "HH:mm – HH:mm v"
                                        },
                                        hv: {
                                            a: "h a – h a v",
                                            h: "h – h a v"
                                        },
                                        Hv: {
                                            H: "HH – HH v"
                                        },
                                        M: {
                                            M: "M – M"
                                        },
                                        Md: {
                                            d: "M/d – M/d",
                                            M: "M/d – M/d"
                                        },
                                        MEd: {
                                            d: "E, M/d – E, M/d",
                                            M: "E, M/d – E, M/d"
                                        },
                                        MMM: {
                                            M: "MMM – MMM"
                                        },
                                        MMMd: {
                                            d: "MMM d – d",
                                            M: "MMM d – MMM d"
                                        },
                                        MMMEd: {
                                            d: "E, MMM d – E, MMM d",
                                            M: "E, MMM d – E, MMM d"
                                        },
                                        y: {
                                            y: "y – y"
                                        },
                                        yM: {
                                            M: "M/y – M/y",
                                            y: "M/y – M/y"
                                        },
                                        yMd: {
                                            d: "M/d/y – M/d/y",
                                            M: "M/d/y – M/d/y",
                                            y: "M/d/y – M/d/y"
                                        },
                                        yMEd: {
                                            d: "E, M/d/y – E, M/d/y",
                                            M: "E, M/d/y – E, M/d/y",
                                            y: "E, M/d/y – E, M/d/y"
                                        },
                                        yMMM: {
                                            M: "MMM – MMM y",
                                            y: "MMM y – MMM y"
                                        },
                                        yMMMd: {
                                            d: "MMM d – d, y",
                                            M: "MMM d – MMM d, y",
                                            y: "MMM d, y – MMM d, y"
                                        },
                                        yMMMEd: {
                                            d: "E, MMM d – E, MMM d, y",
                                            M: "E, MMM d – E, MMM d, y",
                                            y: "E, MMM d, y – E, MMM d, y"
                                        },
                                        yMMMM: {
                                            M: "MMMM – MMMM y",
                                            y: "MMMM y – MMMM y"
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        };
        var weekData = {
            supplemental: {
                version: {
                    _cldrVersion: "28",
                    _unicodeVersion: "8.0.0",
                    _number: "$Revision: 1.1 $"
                },
                weekData: {
                    minDays: {
                        "001": "1",
                        US: "1",
                        DE: "4"
                    },
                    firstDay: {
                        "001": "mon",
                        DE: "mon",
                        RU: "mon",
                        JP: "sun",
                        US: "sun"
                    },
                    weekendStart: {
                        "001": "sat"
                    },
                    weekendEnd: {
                        "001": "sun"
                    }
                }
            }
        };
        var $ = __webpack_require__( /*! jquery */ 9),
            Globalize = __webpack_require__( /*! globalize */ 172),
            dateLocalization = __webpack_require__( /*! ../date */ 56),
            errors = __webpack_require__( /*! ../../core/errors */ 17);
        if (Globalize && Globalize.formatDate) {
            if ("en" === Globalize.locale().locale) {
                Globalize.load(weekData, timeData, enCaGregorian);
                Globalize.locale("en")
            }
            var formattersCache = {};
            var FORMATS_TO_GLOBALIZE_MAP = {
                shortdate: {
                    path: "dateTimeFormats/availableFormats/yMd"
                },
                shorttime: {
                    path: "timeFormats/short"
                },
                longdate: {
                    path: "dateFormats/full"
                },
                longtime: {
                    path: "timeFormats/medium"
                },
                monthandday: {
                    path: "dateTimeFormats/availableFormats/MMMMd"
                },
                monthandyear: {
                    path: "dateTimeFormats/availableFormats/yMMMM"
                },
                quarterandyear: {
                    path: "dateTimeFormats/availableFormats/yQQQ"
                },
                day: {
                    path: "dateTimeFormats/availableFormats/d"
                },
                year: {
                    path: "dateTimeFormats/availableFormats/y"
                },
                shortdateshorttime: {
                    path: "dateTimeFormats/short",
                    parts: ["shorttime", "shortdate"]
                },
                mediumdatemediumtime: {
                    path: "dateTimeFormats/medium",
                    parts: ["shorttime", "monthandday"]
                },
                longdatelongtime: {
                    path: "dateTimeFormats/medium",
                    parts: ["longtime", "longdate"]
                },
                month: {
                    pattern: "LLLL"
                },
                shortyear: {
                    pattern: "yy"
                },
                dayofweek: {
                    pattern: "EEEE"
                },
                quarter: {
                    pattern: "QQQ"
                },
                millisecond: {
                    pattern: "SSS"
                },
                hour: {
                    pattern: "HH"
                },
                minute: {
                    pattern: "mm"
                }
            };
            var globalizeDateLocalization = {
                getPatternByFormat: function(format) {
                    var that = this,
                        lowerFormat = format.toLowerCase(),
                        globalizeFormat = FORMATS_TO_GLOBALIZE_MAP[lowerFormat];
                    if ("datetime-local" === lowerFormat) {
                        return "yyyy-MM-ddTHH':'mm':'ss"
                    }
                    if (!globalizeFormat) {
                        return
                    }
                    var result = globalizeFormat.path && that._getFormatStringByPath(globalizeFormat.path) || globalizeFormat.pattern;
                    if (globalizeFormat.parts) {
                        $.each(globalizeFormat.parts, function(index, part) {
                            result = result.replace("{" + index + "}", that.getPatternByFormat(part))
                        })
                    }
                    return result
                },
                _getFormatStringByPath: function(path) {
                    return Globalize.locale().main("dates/calendars/gregorian/" + path)
                },
                getMonthNames: function(format) {
                    var months = Globalize.locale().main("dates/calendars/gregorian/months/stand-alone/" + (format || "wide"));
                    return $.map(months, function(month) {
                        return month
                    })
                },
                getDayNames: function(format) {
                    var days = Globalize.locale().main("dates/calendars/gregorian/days/stand-alone/" + (format || "wide"));
                    return $.map(days, function(day) {
                        return day
                    })
                },
                getTimeSeparator: function() {
                    return Globalize.locale().main("numbers/symbols-numberSystem-latn/timeSeparator")
                },
                format: function(date, format) {
                    if (!date) {
                        return
                    }
                    if (!format) {
                        return date
                    }
                    var formatter, formatCacheKey;
                    if ("function" === typeof format) {
                        return format(date)
                    }
                    if (format.formatter) {
                        return format.formatter(date)
                    }
                    format = format.type || format;
                    if ("string" === typeof format) {
                        formatCacheKey = Globalize.locale().locale + ":" + format;
                        formatter = formattersCache[formatCacheKey];
                        if (!formatter) {
                            format = {
                                raw: this.getPatternByFormat(format) || format
                            };
                            formatter = formattersCache[formatCacheKey] = Globalize.dateFormatter(format)
                        }
                    } else {
                        formatter = Globalize.dateFormatter(format)
                    }
                    return formatter(date)
                },
                parse: function(text, format) {
                    if (!text) {
                        return
                    }
                    if (!format || "function" === typeof format || format.formatter && !format.parser) {
                        if (format) {
                            errors.log("W0012")
                        }
                        return Globalize.parseDate(text)
                    }
                    if (format.parser) {
                        return format.parser(text)
                    }
                    if ("string" === typeof format) {
                        format = {
                            raw: this.getPatternByFormat(format) || format
                        }
                    }
                    return Globalize.parseDate(text, format)
                },
                firstDayOfWeekIndex: function() {
                    var firstDay = Globalize.locale().supplemental.weekData.firstDay();
                    return $.inArray(firstDay, this._getDayKeys())
                },
                _getDayKeys: function() {
                    var days = Globalize.locale().main("dates/calendars/gregorian/days/format/short");
                    return $.map(days, function(day, key) {
                        return key
                    })
                }
            };
            dateLocalization.inject(globalizeDateLocalization)
        }
    },
    /*!****************************************************!*\
      !*** ./Scripts/localization/globalize/currency.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./core */ 171);
        __webpack_require__( /*! ./number */ 174);
        __webpack_require__( /*! ../currency */ 24);
        __webpack_require__( /*! globalize/currency */ 172);
        var enCurrencyUSD = {
            main: {
                en: {
                    identity: {
                        version: {
                            _cldrVersion: "28",
                            _number: "$Revision: 1.1 $"
                        },
                        language: "en"
                    },
                    numbers: {
                        currencies: {
                            USD: {
                                displayName: "US Dollar",
                                "displayName-count-one": "US dollar",
                                "displayName-count-other": "US dollars",
                                symbol: "$",
                                "symbol-alt-narrow": "$"
                            }
                        }
                    }
                }
            }
        };
        var currencyData = {
            supplemental: {
                version: {
                    _cldrVersion: "28",
                    _unicodeVersion: "8.0.0",
                    _number: "$Revision: 1.1 $"
                },
                currencyData: {
                    fractions: {
                        DEFAULT: {
                            _rounding: "0",
                            _digits: "2"
                        }
                    }
                }
            }
        };
        var Globalize = __webpack_require__( /*! globalize */ 172),
            config = __webpack_require__( /*! ../../core/config */ 15),
            numberLocalization = __webpack_require__( /*! ../number */ 22);
        if (Globalize && Globalize.formatCurrency) {
            if ("en" === Globalize.locale().locale) {
                Globalize.load(enCurrencyUSD, currencyData);
                Globalize.locale("en")
            }
            var formattersCache = {};
            var getFormatter = function(currency, format) {
                var formatter, formatCacheKey;
                if ("object" === typeof format) {
                    formatCacheKey = Globalize.locale().locale + ":" + currency + ":" + JSON.stringify(format)
                } else {
                    formatCacheKey = Globalize.locale().locale + ":" + currency + ":" + format
                }
                formatter = formattersCache[formatCacheKey];
                if (!formatter) {
                    formatter = formattersCache[formatCacheKey] = Globalize.currencyFormatter(currency, format)
                }
                return formatter
            };
            var globalizeCurrencyLocalization = {
                _formatNumberCore: function(value, format, formatConfig) {
                    if ("currency" === format) {
                        var currency = formatConfig && formatConfig.currency || config().defaultCurrency;
                        return getFormatter(currency, this._normalizeFormatConfig(format, formatConfig, value))(value)
                    }
                    return this.callBase.apply(this, arguments)
                },
                _normalizeFormatConfig: function(format, formatConfig, value) {
                    var config = this.callBase(format, formatConfig, value);
                    if ("currency" === format) {
                        config.style = "accounting"
                    }
                    return config
                },
                format: function(value, format) {
                    if ("number" !== typeof value) {
                        return value
                    }
                    format = this._normalizeFormat(format);
                    if (format) {
                        if ("default" === format.currency) {
                            format.currency = config().defaultCurrency
                        }
                        if ("currency" === format.type) {
                            return this._formatNumber(value, this._parseNumberFormatString("currency"), format)
                        } else {
                            if (format.currency) {
                                return getFormatter(format.currency, format)(value)
                            }
                        }
                    }
                    return this.callBase.apply(this, arguments)
                },
                getCurrencySymbol: function(currency) {
                    if (!currency) {
                        currency = config().defaultCurrency
                    }
                    return Globalize.cldr.main("numbers/currencies/" + currency)
                },
                getOpenXmlCurrencyFormat: function(currency) {
                    var i, result, symbol, encodeSymbols, currencySymbol = this.getCurrencySymbol(currency).symbol,
                        currencyFormat = Globalize.cldr.main("numbers/currencyFormats-numberSystem-latn");
                    if (currencyFormat.accounting) {
                        encodeSymbols = {
                            ".00": "{0}",
                            "'": "\\'",
                            "\\(": "\\(",
                            "\\)": "\\)",
                            " ": "\\ ",
                            '"': "&quot;",
                            "\\¤": currencySymbol
                        };
                        result = currencyFormat.accounting.split(";");
                        for (i = 0; i < result.length; i++) {
                            for (symbol in encodeSymbols) {
                                if (encodeSymbols.hasOwnProperty(symbol)) {
                                    result[i] = result[i].replace(new RegExp(symbol, "g"), encodeSymbols[symbol])
                                }
                            }
                        }
                        return 2 === result.length ? result[0] + "_);" + result[1] : result[0]
                    }
                }
            };
            numberLocalization.inject(globalizeCurrencyLocalization)
        }
    },
    /*!************************************!*\
      !*** ./Scripts/events/dblclick.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            Class = __webpack_require__( /*! ../core/class */ 20),
            registerEvent = __webpack_require__( /*! ./core/event_registrator */ 66),
            clickEvent = __webpack_require__( /*! ./click */ 64),
            eventUtils = __webpack_require__( /*! ./utils */ 62);
        var DBLCLICK_EVENT_NAME = "dxdblclick",
            DBLCLICK_NAMESPACE = "dxDblClick",
            NAMESPACED_CLICK_EVENT = eventUtils.addNamespace(clickEvent.name, DBLCLICK_NAMESPACE),
            DBLCLICK_TIMEOUT = 300;
        var DblClick = Class.inherit({
            ctor: function() {
                this._handlerCount = 0;
                this._forgetLastClick()
            },
            _forgetLastClick: function() {
                this._firstClickTarget = null;
                this._lastClickTimeStamp = -DBLCLICK_TIMEOUT
            },
            add: function() {
                if (this._handlerCount <= 0) {
                    $(document).on(NAMESPACED_CLICK_EVENT, $.proxy(this._clickHandler, this))
                }
                this._handlerCount++
            },
            _clickHandler: function(e) {
                var timeStamp = e.timeStamp || $.now();
                if (timeStamp - this._lastClickTimeStamp < DBLCLICK_TIMEOUT) {
                    eventUtils.fireEvent({
                        type: DBLCLICK_EVENT_NAME,
                        target: domUtils.closestCommonParent(this._firstClickTarget, e.target),
                        originalEvent: e
                    });
                    this._forgetLastClick()
                } else {
                    this._firstClickTarget = e.target;
                    this._lastClickTimeStamp = timeStamp
                }
            },
            remove: function() {
                this._handlerCount--;
                if (this._handlerCount <= 0) {
                    this._forgetLastClick();
                    $(document).off(NAMESPACED_CLICK_EVENT)
                }
            }
        });
        registerEvent(DBLCLICK_EVENT_NAME, new DblClick);
        exports.name = DBLCLICK_EVENT_NAME
    },
    /*!*********************************!*\
      !*** ./Scripts/events/swipe.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var eventUtils = __webpack_require__( /*! ./utils */ 62),
            GestureEmitter = __webpack_require__( /*! ./gesture/emitter.gesture */ 78),
            registerEmitter = __webpack_require__( /*! ./core/emitter_registrator */ 76);
        var SWIPE_START_EVENT = "dxswipestart",
            SWIPE_EVENT = "dxswipe",
            SWIPE_END_EVENT = "dxswipeend";
        var HorizontalStrategy = {
            defaultItemSizeFunc: function() {
                return this.getElement().width()
            },
            getBounds: function() {
                return [this._maxLeftOffset, this._maxRightOffset]
            },
            calcOffsetRatio: function(e) {
                var endEventData = eventUtils.eventData(e);
                return (endEventData.x - (this._savedEventData && this._savedEventData.x || 0)) / this._itemSizeFunc().call(this, e)
            },
            isFastSwipe: function(e) {
                var endEventData = eventUtils.eventData(e);
                return this.FAST_SWIPE_SPEED_LIMIT * Math.abs(endEventData.x - this._tickData.x) >= endEventData.time - this._tickData.time
            }
        };
        var VerticalStrategy = {
            defaultItemSizeFunc: function() {
                return this.getElement().height()
            },
            getBounds: function() {
                return [this._maxTopOffset, this._maxBottomOffset]
            },
            calcOffsetRatio: function(e) {
                var endEventData = eventUtils.eventData(e);
                return (endEventData.y - (this._savedEventData && this._savedEventData.y || 0)) / this._itemSizeFunc().call(this, e)
            },
            isFastSwipe: function(e) {
                var endEventData = eventUtils.eventData(e);
                return this.FAST_SWIPE_SPEED_LIMIT * Math.abs(endEventData.y - this._tickData.y) >= endEventData.time - this._tickData.time
            }
        };
        var STRATEGIES = {
            horizontal: HorizontalStrategy,
            vertical: VerticalStrategy
        };
        var SwipeEmitter = GestureEmitter.inherit({
            TICK_INTERVAL: 300,
            FAST_SWIPE_SPEED_LIMIT: 10,
            ctor: function(element) {
                this.callBase(element);
                this.direction = "horizontal";
                this.elastic = true
            },
            _getStrategy: function() {
                return STRATEGIES[this.direction]
            },
            _defaultItemSizeFunc: function() {
                return this._getStrategy().defaultItemSizeFunc.call(this)
            },
            _itemSizeFunc: function() {
                return this.itemSizeFunc || this._defaultItemSizeFunc
            },
            _init: function(e) {
                this._tickData = eventUtils.eventData(e)
            },
            _start: function(e) {
                this._savedEventData = eventUtils.eventData(e);
                e = this._fireEvent(SWIPE_START_EVENT, e);
                if (!e.cancel) {
                    this._maxLeftOffset = e.maxLeftOffset;
                    this._maxRightOffset = e.maxRightOffset;
                    this._maxTopOffset = e.maxTopOffset;
                    this._maxBottomOffset = e.maxBottomOffset
                }
            },
            _move: function(e) {
                var strategy = this._getStrategy(),
                    moveEventData = eventUtils.eventData(e),
                    offset = strategy.calcOffsetRatio.call(this, e);
                offset = this._fitOffset(offset, this.elastic);
                if (moveEventData.time - this._tickData.time > this.TICK_INTERVAL) {
                    this._tickData = moveEventData
                }
                this._fireEvent(SWIPE_EVENT, e, {
                    offset: offset
                });
                e.preventDefault()
            },
            _end: function(e) {
                var strategy = this._getStrategy(),
                    offsetRatio = strategy.calcOffsetRatio.call(this, e),
                    isFast = strategy.isFastSwipe.call(this, e),
                    startOffset = offsetRatio,
                    targetOffset = this._calcTargetOffset(offsetRatio, isFast);
                startOffset = this._fitOffset(startOffset, this.elastic);
                targetOffset = this._fitOffset(targetOffset, false);
                this._fireEvent(SWIPE_END_EVENT, e, {
                    offset: startOffset,
                    targetOffset: targetOffset
                })
            },
            _fitOffset: function(offset, elastic) {
                var strategy = this._getStrategy(),
                    bounds = strategy.getBounds.call(this);
                if (offset < -bounds[0]) {
                    return elastic ? (-2 * bounds[0] + offset) / 3 : -bounds[0]
                }
                if (offset > bounds[1]) {
                    return elastic ? (2 * bounds[1] + offset) / 3 : bounds[1]
                }
                return offset
            },
            _calcTargetOffset: function(offsetRatio, isFast) {
                var result;
                if (isFast) {
                    result = Math.ceil(Math.abs(offsetRatio));
                    if (offsetRatio < 0) {
                        result = -result
                    }
                } else {
                    result = Math.round(offsetRatio)
                }
                return result
            }
        });
        registerEmitter({
            emitter: SwipeEmitter,
            events: [SWIPE_START_EVENT, SWIPE_EVENT, SWIPE_END_EVENT]
        });
        exports.swipe = SWIPE_EVENT;
        exports.start = SWIPE_START_EVENT;
        exports.end = SWIPE_END_EVENT
    },
    /*!*************************************!*\
      !*** ./Scripts/events/transform.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            mathUtils = __webpack_require__( /*! ../core/utils/math */ 79),
            errors = __webpack_require__( /*! ../core/errors */ 17),
            eventUtils = __webpack_require__( /*! ./utils */ 62),
            Emitter = __webpack_require__( /*! ./core/emitter */ 75),
            registerEmitter = __webpack_require__( /*! ./core/emitter_registrator */ 76);
        var DX_PREFIX = "dx",
            TRANSFORM = "transform",
            TRANSLATE = "translate",
            ZOOM = "zoom",
            PINCH = "pinch",
            ROTATE = "rotate",
            START_POSTFIX = "start",
            UPDATE_POSTFIX = "",
            END_POSTFIX = "end";
        var eventAliases = [];
        var addAlias = function(eventName, eventArgs) {
            eventAliases.push({
                name: eventName,
                args: eventArgs
            })
        };
        addAlias(TRANSFORM, {
            scale: true,
            deltaScale: true,
            rotation: true,
            deltaRotation: true,
            translation: true,
            deltaTranslation: true
        });
        addAlias(TRANSLATE, {
            translation: true,
            deltaTranslation: true
        });
        addAlias(ZOOM, {
            scale: true,
            deltaScale: true
        });
        addAlias(PINCH, {
            scale: true,
            deltaScale: true
        });
        addAlias(ROTATE, {
            rotation: true,
            deltaRotation: true
        });
        var getVector = function(first, second) {
            return {
                x: second.pageX - first.pageX,
                y: -second.pageY + first.pageY,
                centerX: .5 * (second.pageX + first.pageX),
                centerY: .5 * (second.pageY + first.pageY)
            }
        };
        var getEventVector = function(e) {
            var pointers = e.pointers;
            return getVector(pointers[0], pointers[1])
        };
        var getDistance = function(vector) {
            return Math.sqrt(vector.x * vector.x + vector.y * vector.y)
        };
        var getScale = function(firstVector, secondVector) {
            return getDistance(firstVector) / getDistance(secondVector)
        };
        var getRotation = function(firstVector, secondVector) {
            var scalarProduct = firstVector.x * secondVector.x + firstVector.y * secondVector.y;
            var distanceProduct = getDistance(firstVector) * getDistance(secondVector);
            if (0 === distanceProduct) {
                return 0
            }
            var sign = mathUtils.sign(firstVector.x * secondVector.y - secondVector.x * firstVector.y);
            var angle = Math.acos(mathUtils.fitIntoRange(scalarProduct / distanceProduct, -1, 1));
            return sign * angle
        };
        var getTranslation = function(firstVector, secondVector) {
            return {
                x: firstVector.centerX - secondVector.centerX,
                y: firstVector.centerY - secondVector.centerY
            }
        };
        var TransformEmitter = Emitter.inherit({
            configurate: function(data, eventName) {
                if (eventName.indexOf(ZOOM) > -1) {
                    errors.log("W0005", eventName, "15.1", "Use '" + eventName.replace(ZOOM, PINCH) + "' event instead")
                }
                this.callBase(data)
            },
            validatePointers: function(e) {
                return eventUtils.hasTouches(e) > 1
            },
            start: function(e) {
                this._accept(e);
                var startVector = getEventVector(e);
                this._startVector = startVector;
                this._prevVector = startVector;
                this._fireEventAliases(START_POSTFIX, e)
            },
            move: function(e) {
                var currentVector = getEventVector(e),
                    eventArgs = this._getEventArgs(currentVector);
                this._fireEventAliases(UPDATE_POSTFIX, e, eventArgs);
                this._prevVector = currentVector
            },
            end: function(e) {
                var eventArgs = this._getEventArgs(this._prevVector);
                this._fireEventAliases(END_POSTFIX, e, eventArgs)
            },
            _getEventArgs: function(vector) {
                return {
                    scale: getScale(vector, this._startVector),
                    deltaScale: getScale(vector, this._prevVector),
                    rotation: getRotation(vector, this._startVector),
                    deltaRotation: getRotation(vector, this._prevVector),
                    translation: getTranslation(vector, this._startVector),
                    deltaTranslation: getTranslation(vector, this._prevVector)
                }
            },
            _fireEventAliases: function(eventPostfix, originalEvent, eventArgs) {
                eventArgs = eventArgs || {};
                $.each(eventAliases, $.proxy(function(_, eventAlias) {
                    var args = {};
                    $.each(eventAlias.args, function(name) {
                        if (name in eventArgs) {
                            args[name] = eventArgs[name]
                        }
                    });
                    this._fireEvent(DX_PREFIX + eventAlias.name + eventPostfix, originalEvent, args)
                }, this))
            }
        });
        var eventNames = $.map(eventAliases, function(eventAlias) {
            var eventNames = [];
            $.each([START_POSTFIX, UPDATE_POSTFIX, END_POSTFIX], function(_, eventPostfix) {
                eventNames.push(DX_PREFIX + eventAlias.name + eventPostfix)
            });
            return eventNames
        });
        registerEmitter({
            emitter: TransformEmitter,
            events: eventNames
        });
        $.each(eventNames, function(_, eventName) {
            exports[eventName.substring(DX_PREFIX.length)] = eventName
        })
    },
    /*!***********************************************!*\
      !*** ./Scripts/bundles/modules/parts/data.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var DevExpress = __webpack_require__( /*! ./core */ 5);
        var data = DevExpress.data = __webpack_require__( /*! ../../../bundles/modules/data */ 181);
        data.odata = __webpack_require__( /*! ../../../bundles/modules/data.odata */ 186);
        module.exports = data
    },
    /*!*****************************************!*\
      !*** ./Scripts/bundles/modules/data.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var DevExpress = __webpack_require__( /*! ./core */ 6);
        module.exports = DevExpress.data = DevExpress.data || {};
        Object.defineProperty(DevExpress.data, "errorHandler", {
            get: function() { /*! ../../data/errors */
                return __webpack_require__(157).errorHandler
            },
            set: function(value) {
                __webpack_require__( /*! ../../data/errors */ 157).errorHandler = value
            }
        });
        Object.defineProperty(DevExpress.data, "_errorHandler", {
            get: function() { /*! ../../data/errors */
                return __webpack_require__(157)._errorHandler
            },
            set: function(value) {
                __webpack_require__( /*! ../../data/errors */ 157)._errorHandler = value
            }
        });
        DevExpress.data.DataSource = __webpack_require__( /*! ../../data/data_source */ 182);
        DevExpress.data.query = __webpack_require__( /*! ../../data/query */ 158);
        DevExpress.data.Store = __webpack_require__( /*! ../../data/abstract_store */ 156);
        DevExpress.data.ArrayStore = __webpack_require__( /*! ../../data/array_store */ 162);
        DevExpress.data.CustomStore = __webpack_require__( /*! ../../data/custom_store */ 163);
        DevExpress.data.LocalStore = __webpack_require__( /*! ../../data/local_store */ 183);
        DevExpress.data.base64_encode = __webpack_require__( /*! ../../data/utils */ 137).base64_encode;
        DevExpress.data.Guid = __webpack_require__( /*! ../../core/guid */ 153);
        DevExpress.data.utils = {};
        DevExpress.data.utils.compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter;
        DevExpress.data.utils.compileSetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileSetter;
        DevExpress.EndpointSelector = __webpack_require__( /*! ../../data/endpoint_selector */ 184);
        DevExpress.data.queryImpl = __webpack_require__( /*! ../../data/query */ 158).queryImpl;
        DevExpress.data.queryAdapters = __webpack_require__( /*! ../../data/query_adapters */ 161);
        var dataUtils = __webpack_require__( /*! ../../data/utils */ 137);
        DevExpress.data.utils.normalizeBinaryCriterion = dataUtils.normalizeBinaryCriterion;
        DevExpress.data.utils.normalizeSortingInfo = dataUtils.normalizeSortingInfo;
        DevExpress.data.utils.errorMessageFromXhr = dataUtils.errorMessageFromXhr;
        DevExpress.data.utils.aggregators = dataUtils.aggregators;
        DevExpress.data.utils.keysEqual = dataUtils.keysEqual;
        DevExpress.data.utils.isDisjunctiveOperator = dataUtils.isDisjunctiveOperator;
        DevExpress.data.utils.isConjunctiveOperator = dataUtils.isConjunctiveOperator;
        DevExpress.data.utils.processRequestResultLock = dataUtils.processRequestResultLock;
        DevExpress.data.utils.toComparable = __webpack_require__( /*! ../../core/utils/data */ 36).toComparable;
        DevExpress.data.utils.multiLevelGroup = __webpack_require__( /*! ../../data/abstract_store */ 156).multiLevelGroup;
        DevExpress.data.utils.arrangeSortingInfo = __webpack_require__( /*! ../../data/abstract_store */ 156).arrangeSortingInfo;
        DevExpress.data.utils.normalizeDataSourceOptions = __webpack_require__( /*! ../../data/data_source/data_source */ 155).normalizeDataSourceOptions
    },
    /*!*************************************!*\
      !*** ./Scripts/data/data_source.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./data_source/data_source */ 155).DataSource
    },
    /*!*************************************!*\
      !*** ./Scripts/data/local_store.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            abstract = Class.abstract,
            errors = __webpack_require__( /*! ./errors */ 157).errors,
            ArrayStore = __webpack_require__( /*! ./array_store */ 162);
        var LocalStoreBackend = Class.inherit({
            ctor: function(store, storeOptions) {
                this._store = store;
                this._dirty = false;
                var immediate = this._immediate = storeOptions.immediate;
                var flushInterval = Math.max(100, storeOptions.flushInterval || 1e4);
                if (!immediate) {
                    var saveProxy = $.proxy(this.save, this);
                    setInterval(saveProxy, flushInterval);
                    $(window).on("beforeunload", saveProxy);
                    if (window.cordova) {
                        document.addEventListener("pause", saveProxy, false)
                    }
                }
            },
            notifyChanged: function() {
                this._dirty = true;
                if (this._immediate) {
                    this.save()
                }
            },
            load: function() {
                this._store._array = this._loadImpl();
                this._dirty = false
            },
            save: function() {
                if (!this._dirty) {
                    return
                }
                this._saveImpl(this._store._array);
                this._dirty = false
            },
            _loadImpl: abstract,
            _saveImpl: abstract
        });
        var DomLocalStoreBackend = LocalStoreBackend.inherit({
            ctor: function(store, storeOptions) {
                this.callBase(store, storeOptions);
                var name = storeOptions.name;
                if (!name) {
                    throw errors.Error("E4013")
                }
                this._key = "dx-data-localStore-" + name
            },
            _loadImpl: function() {
                var raw = localStorage.getItem(this._key);
                if (raw) {
                    return JSON.parse(raw)
                }
                return []
            },
            _saveImpl: function(array) {
                if (!array.length) {
                    localStorage.removeItem(this._key)
                } else {
                    localStorage.setItem(this._key, JSON.stringify(array))
                }
            }
        });
        var localStoreBackends = {
            dom: DomLocalStoreBackend
        };
        var LocalStore = ArrayStore.inherit({
            ctor: function(options) {
                if ("string" === typeof options) {
                    options = {
                        name: options
                    }
                } else {
                    options = options || {}
                }
                this.callBase(options);
                this._backend = new localStoreBackends[options.backend || "dom"](this, options);
                this._backend.load()
            },
            clear: function() {
                this.callBase();
                this._backend.notifyChanged()
            },
            _insertImpl: function(values) {
                var b = this._backend;
                return this.callBase(values).done($.proxy(b.notifyChanged, b))
            },
            _updateImpl: function(key, values) {
                var b = this._backend;
                return this.callBase(key, values).done($.proxy(b.notifyChanged, b))
            },
            _removeImpl: function(key) {
                var b = this._backend;
                return this.callBase(key).done($.proxy(b.notifyChanged, b))
            }
        }, "local");
        module.exports = LocalStore
    },
    /*!*******************************************!*\
      !*** ./Scripts/data/endpoint_selector.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var errors = __webpack_require__( /*! ../core/errors */ 17),
            proxyUrlFormatter = __webpack_require__( /*! ./proxy_url_formatter */ 185);
        var location = window.location,
            IS_WINJS_ORIGIN = "ms-appx:" === location.protocol,
            IS_LOCAL_ORIGIN = isLocalHostName(location.hostname);

        function isLocalHostName(url) {
            return /^(localhost$|127\.)/i.test(url)
        }
        var EndpointSelector = function(config) {
            this.config = config
        };
        EndpointSelector.prototype = {
            urlFor: function(key) {
                var bag = this.config[key];
                if (!bag) {
                    throw errors.Error("E0006")
                }
                if (proxyUrlFormatter.isProxyUsed()) {
                    return proxyUrlFormatter.formatProxyUrl(bag.local)
                }
                if (bag.production) {
                    if (IS_WINJS_ORIGIN && !Debug.debuggerEnabled || !IS_WINJS_ORIGIN && !IS_LOCAL_ORIGIN) {
                        return bag.production
                    }
                }
                return bag.local
            }
        };
        module.exports = EndpointSelector
    },
    /*!*********************************************!*\
      !*** ./Scripts/data/proxy_url_formatter.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            location = window.location,
            DXPROXY_HOST = "dxproxy.devexpress.com:8000",
            IS_DXPROXY_ORIGIN = location.host === DXPROXY_HOST,
            urlMapping = {};
        var parseUrl = function() {
            var a = document.createElement("a"),
                props = ["protocol", "hostname", "port", "pathname", "search", "hash"];
            var normalizePath = function(value) {
                if ("/" !== value.charAt(0)) {
                    value = "/" + value
                }
                return value
            };
            return function(url) {
                a.href = url;
                var result = {};
                $.each(props, function() {
                    result[this] = a[this]
                });
                result.pathname = normalizePath(result.pathname);
                return result
            }
        }();
        var extractProxyAppId = function() {
            return location.pathname.split("/")[1]
        };
        module.exports = {
            parseUrl: parseUrl,
            isProxyUsed: function() {
                return IS_DXPROXY_ORIGIN
            },
            formatProxyUrl: function(localUrl) {
                var urlData = parseUrl(localUrl);
                if (!/^(localhost$|127\.)/i.test(urlData.hostname)) {
                    return localUrl
                }
                var proxyUrlPart = DXPROXY_HOST + "/" + extractProxyAppId() + "_" + urlData.port;
                urlMapping[proxyUrlPart] = urlData.hostname + ":" + urlData.port;
                var resultUrl = "http://" + proxyUrlPart + urlData.pathname + urlData.search;
                return resultUrl
            },
            formatLocalUrl: function(proxyUrl) {
                if (proxyUrl.indexOf(DXPROXY_HOST) < 0) {
                    return proxyUrl
                }
                var resultUrl = proxyUrl;
                for (var proxyUrlPart in urlMapping) {
                    if (urlMapping.hasOwnProperty(proxyUrlPart)) {
                        if (proxyUrl.indexOf(proxyUrlPart) >= 0) {
                            resultUrl = proxyUrl.replace(proxyUrlPart, urlMapping[proxyUrlPart]);
                            break
                        }
                    }
                }
                return resultUrl
            }
        }
    },
    /*!***********************************************!*\
      !*** ./Scripts/bundles/modules/data.odata.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./data */ 181);
        DevExpress.data.ODataStore = __webpack_require__( /*! ../../data/odata/store */ 187);
        DevExpress.data.ODataContext = __webpack_require__( /*! ../../data/odata/context */ 191);
        DevExpress.data.utils = DevExpress.data.utils || {};
        DevExpress.data.utils.odata = {};
        DevExpress.data.utils.odata.keyConverters = __webpack_require__( /*! ../../data/odata/utils */ 188).keyConverters;
        DevExpress.data.EdmLiteral = __webpack_require__( /*! ../../data/odata/utils */ 188).EdmLiteral;
        var ODataUtilsModule = __webpack_require__( /*! ../../data/odata/utils */ 188);
        DevExpress.data.utils.odata.serializePropName = ODataUtilsModule.serializePropName;
        DevExpress.data.utils.odata.serializeValue = ODataUtilsModule.serializeValue;
        DevExpress.data.utils.odata.serializeKey = ODataUtilsModule.serializeKey;
        DevExpress.data.utils.odata.sendRequest = ODataUtilsModule.sendRequest;
        DevExpress.data.OData__internals = ODataUtilsModule.OData__internals;
        DevExpress.data.queryAdapters = DevExpress.data.queryAdapters || {};
        DevExpress.data.queryAdapters.odata = __webpack_require__( /*! ../../data/odata/query_adapter */ 190).odata
    },
    /*!*************************************!*\
      !*** ./Scripts/data/odata/store.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            odataUtils = __webpack_require__( /*! ./utils */ 188),
            proxyUrlFormatter = __webpack_require__( /*! ../proxy_url_formatter */ 185),
            errorsModule = __webpack_require__( /*! ../errors */ 157),
            query = __webpack_require__( /*! ../query */ 158),
            Store = __webpack_require__( /*! ../abstract_store */ 156),
            mixins = __webpack_require__( /*! ./mixins */ 189);
        __webpack_require__( /*! ./query_adapter */ 190);
        var convertSimpleKey = function(keyType, keyValue) {
            var converter = odataUtils.keyConverters[keyType];
            if (!converter) {
                throw errorsModule.errors.Error("E4014", keyType)
            }
            return converter(keyValue)
        };
        var ODataStore = Store.inherit({
            ctor: function(options) {
                this.callBase(options);
                this._extractServiceOptions(options);
                this._keyType = options.keyType;
                if (2 === this.version()) {
                    this._updateMethod = "MERGE"
                } else {
                    this._updateMethod = "PATCH"
                }
            },
            _customLoadOptions: function() {
                return ["expand", "customQueryParams"]
            },
            _byKeyImpl: function(key, extraOptions) {
                var params = {};
                if (extraOptions) {
                    if (extraOptions.expand) {
                        params.$expand = $.map($.makeArray(extraOptions.expand), odataUtils.serializePropName).join()
                    }
                }
                return this._sendRequest(this._byKeyUrl(key), "GET", params)
            },
            createQuery: function(loadOptions) {
                var url, queryOptions;
                loadOptions = loadOptions || {};
                queryOptions = {
                    adapter: "odata",
                    beforeSend: this._beforeSend,
                    errorHandler: this._errorHandler,
                    jsonp: this._jsonp,
                    version: this._version,
                    withCredentials: this._withCredentials,
                    deserializeDates: this._deserializeDates,
                    expand: loadOptions.expand,
                    requireTotalCount: loadOptions.requireTotalCount
                };
                if (commonUtils.isDefined(loadOptions.urlOverride)) {
                    url = loadOptions.urlOverride
                } else {
                    url = this._url
                }
                if ("customQueryParams" in loadOptions) {
                    var params = mixins.escapeServiceOperationParams(loadOptions.customQueryParams, this.version());
                    if (4 === this.version()) {
                        url = mixins.formatFunctionInvocationUrl(url, params)
                    } else {
                        queryOptions.params = params
                    }
                }
                return query(url, queryOptions)
            },
            _insertImpl: function(values) {
                this._requireKey();
                var that = this,
                    d = $.Deferred();
                $.when(this._sendRequest(this._url, "POST", null, values)).done(function(serverResponse) {
                    d.resolve(values, that.keyOf(serverResponse))
                }).fail(d.reject);
                return d.promise()
            },
            _updateImpl: function(key, values) {
                var d = $.Deferred();
                $.when(this._sendRequest(this._byKeyUrl(key), this._updateMethod, null, values)).done(function() {
                    d.resolve(key, values)
                }).fail(d.reject);
                return d.promise()
            },
            _removeImpl: function(key) {
                var d = $.Deferred();
                $.when(this._sendRequest(this._byKeyUrl(key), "DELETE")).done(function() {
                    d.resolve(key)
                }).fail(d.reject);
                return d.promise()
            },
            _byKeyUrl: function(key, useOriginalHost) {
                var keyObj = key,
                    keyType = this._keyType,
                    baseUrl = useOriginalHost ? proxyUrlFormatter.formatLocalUrl(this._url) : this._url;
                if ($.isPlainObject(keyType)) {
                    keyObj = {};
                    $.each(keyType, function(subKeyName, subKeyType) {
                        keyObj[subKeyName] = convertSimpleKey(subKeyType, key[subKeyName])
                    })
                } else {
                    if (keyType) {
                        keyObj = convertSimpleKey(keyType, key)
                    }
                }
                return baseUrl + "(" + encodeURIComponent(odataUtils.serializeKey(keyObj, this._version)) + ")"
            }
        }, "odata").include(mixins.SharedMethods);
        module.exports = ODataStore
    },
    /*!*************************************!*\
      !*** ./Scripts/data/odata/utils.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            isDefined = commonUtils.isDefined,
            errors = __webpack_require__( /*! ../errors */ 157).errors,
            dataUtils = __webpack_require__( /*! ../utils */ 137);
        var GUID_REGEX = /^(\{{0,1}([0-9a-fA-F]){8}-([0-9a-fA-F]){4}-([0-9a-fA-F]){4}-([0-9a-fA-F]){4}-([0-9a-fA-F]){12}\}{0,1})$/;
        var VERBOSE_DATE_REGEX = /^\/Date\((-?\d+)((\+|-)?(\d+)?)\)\/$/;
        var ISO8601_DATE_REGEX = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?(Z|[-+]{1}\d{2}(:?)(\d{2})?)?$/;
        var JSON_VERBOSE_MIME_TYPE = "application/json;odata=verbose";

        function formatISO8601(date, skipZeroTime, skipTimezone) {
            var ret = [];
            var pad = function(n) {
                if (n < 10) {
                    return "0".concat(n)
                }
                return String(n)
            };
            var isZeroTime = function() {
                return date.getHours() + date.getMinutes() + date.getSeconds() + date.getMilliseconds() < 1
            };
            ret.push(date.getFullYear());
            ret.push("-");
            ret.push(pad(date.getMonth() + 1));
            ret.push("-");
            ret.push(pad(date.getDate()));
            if (!(skipZeroTime && isZeroTime())) {
                ret.push("T");
                ret.push(pad(date.getHours()));
                ret.push(":");
                ret.push(pad(date.getMinutes()));
                ret.push(":");
                ret.push(pad(date.getSeconds()));
                if (date.getMilliseconds()) {
                    ret.push(".");
                    ret.push(date.getMilliseconds())
                }
                if (!skipTimezone) {
                    ret.push("Z")
                }
            }
            return ret.join("")
        }

        function parseISO8601(isoString) {
            var result = new Date(60 * new Date(0).getTimezoneOffset() * 1e3),
                chunks = isoString.replace("Z", "").split("T"),
                date = /(\d{4})-(\d{2})-(\d{2})/.exec(chunks[0]),
                time = /(\d{2}):(\d{2}):(\d{2})\.?(\d{0,7})?/.exec(chunks[1]);
            result.setFullYear(Number(date[1]));
            result.setMonth(Number(date[2]) - 1);
            result.setDate(Number(date[3]));
            if ($.isArray(time) && time.length) {
                result.setHours(Number(time[1]));
                result.setMinutes(Number(time[2]));
                result.setSeconds(Number(time[3]));
                result.setMilliseconds(Number(String(time[4]).substr(0, 3)) || 0)
            }
            return result
        }

        function isAbsoluteUrl(url) {
            return /^(?:[a-z]+:)?\/\//i.test(url)
        }

        function toAbsoluteUrl(basePath, relativePath) {
            var part;
            var baseParts = stripParams(basePath).split("/");
            var relativeParts = relativePath.split("/");

            function stripParams(url) {
                var index = url.indexOf("?");
                if (index > -1) {
                    return url.substr(0, index)
                }
                return url
            }
            baseParts.pop();
            while (relativeParts.length) {
                part = relativeParts.shift();
                if (".." === part) {
                    baseParts.pop()
                } else {
                    baseParts.push(part)
                }
            }
            return baseParts.join("/")
        }
        var ajaxOptionsForRequest = function(protocolVersion, request, requestOptions) {
            request = $.extend({
                async: true,
                method: "get",
                url: "",
                params: {},
                payload: null,
                headers: {},
                timeout: 3e4
            }, request);
            requestOptions = requestOptions || {};
            var beforeSend = requestOptions.beforeSend;
            if (beforeSend) {
                beforeSend(request)
            }
            var method = (request.method || "get").toLowerCase(),
                isGet = "get" === method,
                useJsonp = isGet && requestOptions.jsonp,
                params = $.extend({}, request.params),
                ajaxData = isGet ? params : formatPayload(request.payload),
                qs = !isGet && $.param(params),
                url = request.url,
                contentType = !isGet && JSON_VERBOSE_MIME_TYPE;
            if (qs) {
                url += (url.indexOf("?") > -1 ? "&" : "?") + qs
            }
            if (useJsonp) {
                ajaxData.$format = "json"
            }
            return {
                url: url,
                data: ajaxData,
                dataType: useJsonp ? "jsonp" : "json",
                jsonp: useJsonp && "$callback",
                type: method,
                async: request.async,
                timeout: request.timeout,
                headers: request.headers,
                contentType: contentType,
                accepts: {
                    json: [JSON_VERBOSE_MIME_TYPE, "text/plain"].join()
                },
                xhrFields: {
                    withCredentials: requestOptions.withCredentials
                }
            };

            function formatPayload(payload) {
                return JSON.stringify(payload, function(key, value) {
                    if (!(this[key] instanceof Date)) {
                        return value
                    }
                    value = formatISO8601(this[key]);
                    switch (protocolVersion) {
                        case 2:
                            return value.substr(0, value.length - 1);
                        case 3:
                        case 4:
                            return value;
                        default:
                            throw errors.Error("E4002")
                    }
                })
            }
        };
        var sendRequest = function(protocolVersion, request, requestOptions, deserializeDates) {
            var d = $.Deferred();
            var options = ajaxOptionsForRequest(protocolVersion, request, requestOptions);
            $.ajax(options).always(function(obj, textStatus) {
                var extra, tuplet = interpretJsonFormat(obj, textStatus, deserializeDates),
                    error = tuplet.error,
                    data = tuplet.data,
                    nextUrl = tuplet.nextUrl;
                if (error) {
                    d.reject(error)
                } else {
                    if (requestOptions.countOnly) {
                        if (isFinite(tuplet.count)) {
                            d.resolve(tuplet.count)
                        } else {
                            d.reject(new errors.Error("E4018"))
                        }
                    } else {
                        if (nextUrl) {
                            if (!isAbsoluteUrl(nextUrl)) {
                                nextUrl = toAbsoluteUrl(options.url, nextUrl)
                            }
                            sendRequest(protocolVersion, {
                                url: nextUrl
                            }, requestOptions, deserializeDates).fail(d.reject).done(function(nextData) {
                                d.resolve(data.concat(nextData))
                            })
                        } else {
                            if (isFinite(tuplet.count)) {
                                extra = {
                                    totalCount: tuplet.count
                                }
                            }
                            d.resolve(data, extra)
                        }
                    }
                }
            });
            return d.promise()
        };
        var formatDotNetError = function(errorObj) {
            var message, currentError = errorObj;
            if ("message" in errorObj) {
                if (errorObj.message.value) {
                    message = errorObj.message.value
                } else {
                    message = errorObj.message
                }
            }
            while (currentError = currentError.innererror || currentError.internalexception) {
                message = currentError.message;
                if (currentError.internalexception && message.indexOf("inner exception") === -1) {
                    break
                }
            }
            return message
        };
        var errorFromResponse = function(obj, textStatus) {
            if ("nocontent" === textStatus) {
                return null
            }
            var httpStatus = 200,
                message = "Unknown error",
                response = obj;
            if ("success" !== textStatus) {
                httpStatus = obj.status;
                message = dataUtils.errorMessageFromXhr(obj, textStatus);
                try {
                    response = $.parseJSON(obj.responseText)
                } catch (x) {}
            }
            var errorObj = response && (response.error || response["odata.error"] || response["@odata.error"]);
            if (errorObj) {
                message = formatDotNetError(errorObj) || message;
                if (200 === httpStatus) {
                    httpStatus = 500
                }
                if (errorObj.code) {
                    httpStatus = Number(errorObj.code)
                }
                return $.extend(Error(message), {
                    httpStatus: httpStatus,
                    errorDetails: errorObj
                })
            } else {
                if (200 !== httpStatus) {
                    return $.extend(Error(message), {
                        httpStatus: httpStatus
                    })
                }
            }
        };
        var interpretJsonFormat = function(obj, textStatus, deserializeDates) {
            var value, error = errorFromResponse(obj, textStatus);
            if (error) {
                return {
                    error: error
                }
            }
            if (!$.isPlainObject(obj)) {
                return {
                    data: obj
                }
            }
            if ("d" in obj && (commonUtils.isArray(obj.d) || commonUtils.isObject(obj.d))) {
                value = interpretVerboseJsonFormat(obj, textStatus)
            } else {
                value = interpretLightJsonFormat(obj, textStatus)
            }
            transformTypes(value, deserializeDates);
            return value
        };
        var interpretVerboseJsonFormat = function(obj) {
            var data = obj.d;
            if (!isDefined(data)) {
                return {
                    error: Error("Malformed or unsupported JSON response received")
                }
            }
            data = data;
            if (isDefined(data.results)) {
                data = data.results
            }
            return {
                data: data,
                nextUrl: obj.d.__next,
                count: parseInt(obj.d.__count, 10)
            }
        };
        var interpretLightJsonFormat = function(obj) {
            var data = obj;
            if (isDefined(data.value)) {
                data = data.value
            }
            return {
                data: data,
                nextUrl: obj["@odata.nextLink"],
                count: parseInt(obj["@odata.count"], 10)
            }
        };
        var EdmLiteral = Class.inherit({
            ctor: function(value) {
                this._value = value
            },
            valueOf: function() {
                return this._value
            }
        });
        var transformTypes = function(obj, deserializeDates) {
            $.each(obj, function(key, value) {
                if (null !== value && "object" === typeof value) {
                    if ("results" in value) {
                        obj[key] = value.results
                    }
                    transformTypes(obj[key], deserializeDates)
                } else {
                    if ("string" === typeof value) {
                        if (GUID_REGEX.test(value)) {
                            obj[key] = new Guid(value)
                        }
                        if (false !== deserializeDates) {
                            if (value.match(VERBOSE_DATE_REGEX)) {
                                var date = new Date(Number(RegExp.$1) + 60 * RegExp.$2 * 1e3);
                                obj[key] = new Date(date.valueOf() + 60 * date.getTimezoneOffset() * 1e3)
                            } else {
                                if (ISO8601_DATE_REGEX.test(value)) {
                                    obj[key] = new Date(parseISO8601(obj[key]).valueOf())
                                }
                            }
                        }
                    }
                }
            })
        };
        var serializeDate = function(date) {
            return "datetime'" + formatISO8601(date, true, true) + "'"
        };
        var serializeString = function(value) {
            return "'" + value.replace(/'/g, "''") + "'"
        };
        var serializePropName = function(propName) {
            if (propName instanceof EdmLiteral) {
                return propName.valueOf()
            }
            return propName.replace(/\./g, "/")
        };
        var serializeValueV4 = function(value) {
            if (value instanceof Date) {
                return formatISO8601(value, false, false)
            }
            if (value instanceof Guid) {
                return value.valueOf()
            }
            if (commonUtils.isArray(value)) {
                return "[" + value.map(function(item) {
                    return serializeValueV4(item)
                }).join(",") + "]"
            }
            return serializeValueV2(value)
        };
        var serializeValueV2 = function(value) {
            if (value instanceof Date) {
                return serializeDate(value)
            }
            if (value instanceof Guid) {
                return "guid'" + value + "'"
            }
            if (value instanceof EdmLiteral) {
                return value.valueOf()
            }
            if ("string" === typeof value) {
                return serializeString(value)
            }
            return String(value)
        };
        var serializeValue = function(value, protocolVersion) {
            switch (protocolVersion) {
                case 2:
                case 3:
                    return serializeValueV2(value);
                case 4:
                    return serializeValueV4(value);
                default:
                    throw errors.Error("E4002")
            }
        };
        var serializeKey = function(key, protocolVersion) {
            if ($.isPlainObject(key)) {
                var parts = [];
                $.each(key, function(k, v) {
                    parts.push(serializePropName(k) + "=" + serializeValue(v, protocolVersion))
                });
                return parts.join()
            }
            return serializeValue(key, protocolVersion)
        };
        var keyConverters = {
            String: function(value) {
                return value + ""
            },
            Int32: function(value) {
                return Math.floor(value)
            },
            Int64: function(value) {
                if (value instanceof EdmLiteral) {
                    return value
                }
                return new EdmLiteral(value + "L")
            },
            Guid: function(value) {
                if (value instanceof Guid) {
                    return value
                }
                return new Guid(value)
            },
            Boolean: function(value) {
                return !!value
            },
            Single: function(value) {
                if (value instanceof EdmLiteral) {
                    return value
                }
                return new EdmLiteral(value + "f")
            },
            Decimal: function(value) {
                if (value instanceof EdmLiteral) {
                    return value
                }
                return new EdmLiteral(value + "m")
            }
        };
        exports.sendRequest = sendRequest;
        exports.serializePropName = serializePropName;
        exports.serializeValue = serializeValue;
        exports.serializeKey = serializeKey;
        exports.keyConverters = keyConverters;
        exports.EdmLiteral = EdmLiteral;
        exports.OData__internals = {
            interpretJsonFormat: interpretJsonFormat
        }
    },
    /*!**************************************!*\
      !*** ./Scripts/data/odata/mixins.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            odataUtils = __webpack_require__( /*! ./utils */ 188);
        __webpack_require__( /*! ./query_adapter */ 190);
        var DEFAULT_PROTOCOL_VERSION = 2;
        var formatFunctionInvocationUrl = function(baseUrl, args) {
            return stringUtils.format("{0}({1})", baseUrl, $.map(args || {}, function(value, key) {
                return stringUtils.format("{0}={1}", key, value)
            }).join(","))
        };
        var escapeServiceOperationParams = function(params, version) {
            if (!params) {
                return params
            }
            var result = {};
            $.each(params, function(k, v) {
                result[k] = odataUtils.serializeValue(v, version)
            });
            return result
        };
        var SharedMethods = {
            _extractServiceOptions: function(options) {
                options = options || {};
                this._url = String(options.url).replace(/\/+$/, "");
                this._beforeSend = options.beforeSend;
                this._jsonp = options.jsonp;
                this._version = options.version || DEFAULT_PROTOCOL_VERSION;
                this._withCredentials = options.withCredentials;
                this._deserializeDates = options.deserializeDates
            },
            _sendRequest: function(url, method, params, payload) {
                return odataUtils.sendRequest(this.version(), {
                    url: url,
                    method: method,
                    params: params || {},
                    payload: payload
                }, {
                    beforeSend: this._beforeSend,
                    jsonp: this._jsonp,
                    withCredentials: this._withCredentials
                }, this._deserializeDates)
            },
            version: function() {
                return this._version
            }
        };
        exports.SharedMethods = SharedMethods;
        exports.escapeServiceOperationParams = escapeServiceOperationParams;
        exports.formatFunctionInvocationUrl = formatFunctionInvocationUrl
    },
    /*!*********************************************!*\
      !*** ./Scripts/data/odata/query_adapter.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            queryAdapters = __webpack_require__( /*! ../query_adapters */ 161),
            odataUtils = __webpack_require__( /*! ./utils */ 188),
            serializePropName = odataUtils.serializePropName,
            errors = __webpack_require__( /*! ../errors */ 157).errors,
            dataUtils = __webpack_require__( /*! ../utils */ 137);
        var DEFAULT_PROTOCOL_VERSION = 2;
        var compileCriteria = function() {
            var createBinaryOperationFormatter = function(op) {
                return function(prop, val) {
                    return prop + " " + op + " " + val
                }
            };
            var createStringFuncFormatter = function(op, reverse) {
                return function(prop, val) {
                    var bag = [op, "("];
                    if (reverse) {
                        bag.push(val, ",", prop)
                    } else {
                        bag.push(prop, ",", val)
                    }
                    bag.push(")");
                    return bag.join("")
                }
            };
            var formatters = {
                "=": createBinaryOperationFormatter("eq"),
                "<>": createBinaryOperationFormatter("ne"),
                ">": createBinaryOperationFormatter("gt"),
                ">=": createBinaryOperationFormatter("ge"),
                "<": createBinaryOperationFormatter("lt"),
                "<=": createBinaryOperationFormatter("le"),
                startswith: createStringFuncFormatter("startswith"),
                endswith: createStringFuncFormatter("endswith")
            };
            var formattersV2 = $.extend({}, formatters, {
                contains: createStringFuncFormatter("substringof", true),
                notcontains: createStringFuncFormatter("not substringof", true)
            });
            var formattersV4 = $.extend({}, formatters, {
                contains: createStringFuncFormatter("contains"),
                notcontains: createStringFuncFormatter("not contains")
            });
            var compileBinary = function(criteria, protocolVersion) {
                criteria = dataUtils.normalizeBinaryCriterion(criteria);
                var op = criteria[1],
                    formatters = 4 === protocolVersion ? formattersV4 : formattersV2,
                    formatter = formatters[op.toLowerCase()];
                if (!formatter) {
                    throw errors.Error("E4003", op)
                }
                return formatter(serializePropName(criteria[0]), odataUtils.serializeValue(criteria[2], protocolVersion))
            };
            var compileGroup = function(criteria, protocolVersion) {
                var groupOperator, nextGroupOperator, bag = [];
                $.each(criteria, function(index, criterion) {
                    if ($.isArray(criterion)) {
                        if (bag.length > 1 && groupOperator !== nextGroupOperator) {
                            throw new errors.Error("E4019")
                        }
                        bag.push("(" + compileCore(criterion, protocolVersion) + ")");
                        groupOperator = nextGroupOperator;
                        nextGroupOperator = "and"
                    } else {
                        nextGroupOperator = dataUtils.isConjunctiveOperator(this) ? "and" : "or"
                    }
                });
                return bag.join(" " + groupOperator + " ")
            };
            var compileCore = function(criteria, protocolVersion) {
                if ($.isArray(criteria[0])) {
                    return compileGroup(criteria, protocolVersion)
                }
                return compileBinary(criteria, protocolVersion)
            };
            return function(criteria, protocolVersion) {
                return compileCore(criteria, protocolVersion)
            }
        }();
        var createODataQueryAdapter = function(queryOptions) {
            var _select, _skip, _take, _countQuery, _sorting = [],
                _criteria = [],
                _expand = queryOptions.expand,
                _oDataVersion = queryOptions.version || DEFAULT_PROTOCOL_VERSION;
            var hasSlice = function() {
                return _skip || void 0 !== _take
            };
            var hasFunction = function(criterion) {
                for (var i = 0; i < criterion.length; i++) {
                    if ($.isFunction(criterion[i])) {
                        return true
                    }
                    if ($.isArray(criterion[i]) && hasFunction(criterion[i])) {
                        return true
                    }
                }
                return false
            };
            var generateSelectExpand = function() {
                var hasDot = function(x) {
                    return /\./.test(x)
                };
                var generateSelect = function() {
                    if (!_select) {
                        return
                    }
                    if (_oDataVersion < 4) {
                        return serializePropName(_select.join())
                    }
                    return $.grep(_select, hasDot, true).join()
                };
                var generateExpand = function() {
                    var generatorV2 = function() {
                        var hash = {};
                        if (_expand) {
                            $.each($.makeArray(_expand), function() {
                                hash[serializePropName(this)] = 1
                            })
                        }
                        if (_select) {
                            $.each($.makeArray(_select), function() {
                                var path = this.split(".");
                                if (path.length < 2) {
                                    return
                                }
                                path.pop();
                                hash[serializePropName(path.join("."))] = 1
                            })
                        }
                        return $.map(hash, function(k, v) {
                            return v
                        }).join()
                    };
                    var generatorV4 = function() {
                        var format = function(hash) {
                            var formatCore = function(hash) {
                                var ret = "",
                                    select = [],
                                    expand = [];
                                $.each(hash, function(key, value) {
                                    if ($.isArray(value)) {
                                        [].push.apply(select, value)
                                    }
                                    if ($.isPlainObject(value)) {
                                        expand.push(key + formatCore(value))
                                    }
                                });
                                if (select.length || expand.length) {
                                    ret += "(";
                                    if (select.length) {
                                        ret += "$select=" + $.map(select, serializePropName).join()
                                    }
                                    if (expand.length) {
                                        if (select.length) {
                                            ret += ";"
                                        }
                                        ret += "$expand=" + $.map(expand, serializePropName).join()
                                    }
                                    ret += ")"
                                }
                                return ret
                            };
                            var ret = [];
                            $.each(hash, function(key, value) {
                                ret.push(key + formatCore(value))
                            });
                            return ret.join()
                        };
                        var parseTree = function(exprs, root, stepper) {
                            var parseCore = function(exprParts, root, stepper) {
                                var result = stepper(root, exprParts.shift(), exprParts);
                                if (false === result) {
                                    return
                                }
                                parseCore(exprParts, result, stepper)
                            };
                            $.each(exprs, function(_, x) {
                                parseCore(x.split("."), root, stepper)
                            })
                        };
                        var hash = {};
                        if (_expand || _select) {
                            if (_expand) {
                                parseTree($.makeArray(_expand), hash, function(node, key, path) {
                                    node[key] = node[key] || {};
                                    if (!path.length) {
                                        return false
                                    }
                                    return node[key]
                                })
                            }
                            if (_select) {
                                parseTree($.grep($.makeArray(_select), hasDot), hash, function(node, key, path) {
                                    if (!path.length) {
                                        node[key] = node[key] || [];
                                        node[key].push(key);
                                        return false
                                    }
                                    return node[key] = node[key] || {}
                                })
                            }
                            return format(hash)
                        }
                    };
                    if (_oDataVersion < 4) {
                        return generatorV2()
                    }
                    return generatorV4()
                };
                var tuple = {
                    $select: generateSelect() || void 0,
                    $expand: generateExpand() || void 0
                };
                return tuple
            };
            var requestData = function() {
                var result = {};
                if (!_countQuery) {
                    if (_sorting.length) {
                        result.$orderby = _sorting.join(",")
                    }
                    if (_skip) {
                        result.$skip = _skip
                    }
                    if (void 0 !== _take) {
                        result.$top = _take
                    }
                    var tuple = generateSelectExpand();
                    result.$select = tuple.$select;
                    result.$expand = tuple.$expand
                }
                if (_criteria.length) {
                    result.$filter = compileCriteria(_criteria.length < 2 ? _criteria[0] : _criteria, _oDataVersion)
                }
                if (_countQuery) {
                    result.$top = 0
                }
                if (queryOptions.requireTotalCount || _countQuery) {
                    if (4 !== _oDataVersion) {
                        result.$inlinecount = "allpages"
                    } else {
                        result.$count = "true"
                    }
                }
                return result
            };
            return {
                exec: function(url) {
                    return odataUtils.sendRequest(_oDataVersion, {
                        url: url,
                        params: $.extend(requestData(), queryOptions && queryOptions.params)
                    }, {
                        beforeSend: queryOptions.beforeSend,
                        jsonp: queryOptions.jsonp,
                        withCredentials: queryOptions.withCredentials,
                        countOnly: _countQuery
                    }, queryOptions.deserializeDates)
                },
                multiSort: function(args) {
                    var rules;
                    if (hasSlice()) {
                        return false
                    }
                    for (var i = 0; i < args.length; i++) {
                        var rule, getter = args[i][0],
                            desc = !!args[i][1];
                        if ("string" !== typeof getter) {
                            return false
                        }
                        rule = serializePropName(getter);
                        if (desc) {
                            rule += " desc"
                        }
                        rules = rules || [];
                        rules.push(rule)
                    }
                    _sorting = rules
                },
                slice: function(skipCount, takeCount) {
                    if (hasSlice()) {
                        return false
                    }
                    _skip = skipCount;
                    _take = takeCount
                },
                filter: function(criterion) {
                    if (hasSlice()) {
                        return false
                    }
                    if (!$.isArray(criterion)) {
                        criterion = $.makeArray(arguments)
                    }
                    if (hasFunction(criterion)) {
                        return false
                    }
                    if (_criteria.length) {
                        _criteria.push("and")
                    }
                    _criteria.push(criterion)
                },
                select: function(expr) {
                    if (_select || $.isFunction(expr)) {
                        return false
                    }
                    if (!$.isArray(expr)) {
                        expr = $.makeArray(arguments)
                    }
                    _select = expr
                },
                count: function() {
                    _countQuery = true
                }
            }
        };
        queryAdapters.odata = createODataQueryAdapter;
        exports.odata = createODataQueryAdapter
    },
    /*!***************************************!*\
      !*** ./Scripts/data/odata/context.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            errorsModule = __webpack_require__( /*! ../errors */ 157),
            ODataStore = __webpack_require__( /*! ./store */ 187),
            mixins = __webpack_require__( /*! ./mixins */ 189);
        __webpack_require__( /*! ./query_adapter */ 190);
        var ODataContext = Class.inherit({
            ctor: function(options) {
                var that = this;
                that._extractServiceOptions(options);
                that._errorHandler = options.errorHandler;
                $.each(options.entities || [], function(entityAlias, entityOptions) {
                    that[entityAlias] = new ODataStore($.extend({}, options, {
                        url: that._url + "/" + encodeURIComponent(entityOptions.name || entityAlias)
                    }, entityOptions))
                })
            },
            get: function(operationName, params) {
                return this.invoke(operationName, params, "GET")
            },
            invoke: function(operationName, params, httpMethod) {
                params = params || {};
                httpMethod = (httpMethod || "POST").toLowerCase();
                var payload, d = $.Deferred(),
                    url = this._url + "/" + encodeURIComponent(operationName);
                if (4 === this.version()) {
                    if ("get" === httpMethod) {
                        url = mixins.formatFunctionInvocationUrl(url, mixins.escapeServiceOperationParams(params, this.version()));
                        params = null
                    } else {
                        if ("post" === httpMethod) {
                            payload = params;
                            params = null
                        }
                    }
                }
                $.when(this._sendRequest(url, httpMethod, mixins.escapeServiceOperationParams(params, this.version()), payload)).done(function(r) {
                    if ($.isPlainObject(r) && operationName in r) {
                        r = r[operationName]
                    }
                    d.resolve(r)
                }).fail([this._errorHandler, errorsModule._errorHandler, d.reject]);
                return d.promise()
            },
            objectLink: function(entityAlias, key) {
                var store = this[entityAlias];
                if (!store) {
                    throw errorsModule.errors.Error("E4015", entityAlias)
                }
                if (!commonUtils.isDefined(key)) {
                    return null
                }
                return {
                    __metadata: {
                        uri: store._byKeyUrl(key, true)
                    }
                }
            }
        }).include(mixins.SharedMethods);
        module.exports = ODataContext
    },
    /*!***************************************!*\
      !*** ./Scripts/bundles/modules/ui.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./core */ 6);
        module.exports = DevExpress.ui = {};
        DevExpress.ui.templateRendered = __webpack_require__( /*! ../../ui/widget/ui.template_base */ 90).renderedCallbacks
    },
    /*!*******************************************!*\
      !*** ./Scripts/ui/set_template_engine.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./widget/jquery.template */ 96).setTemplateEngine
    },
    /*!******************************!*\
      !*** ./Scripts/ui/dialog.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Component = __webpack_require__( /*! ../core/component */ 34),
            Action = __webpack_require__( /*! ../core/action */ 35),
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            viewPortUtils = __webpack_require__( /*! ../core/utils/view_port */ 42),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            themes = __webpack_require__( /*! ./themes */ 143),
            errors = __webpack_require__( /*! ./widget/ui.errors */ 10),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            Popup = __webpack_require__( /*! ./popup */ 195),
            config = __webpack_require__( /*! ../core/config */ 15);
        var DEFAULT_BUTTON = {
            text: "OK",
            onClick: function() {
                return true
            }
        };
        var DX_DIALOG_CLASSNAME = "dx-dialog",
            DX_DIALOG_WRAPPER_CLASSNAME = DX_DIALOG_CLASSNAME + "-wrapper",
            DX_DIALOG_ROOT_CLASSNAME = DX_DIALOG_CLASSNAME + "-root",
            DX_DIALOG_CONTENT_CLASSNAME = DX_DIALOG_CLASSNAME + "-content",
            DX_DIALOG_MESSAGE_CLASSNAME = DX_DIALOG_CLASSNAME + "-message",
            DX_DIALOG_BUTTONS_CLASSNAME = DX_DIALOG_CLASSNAME + "-buttons",
            DX_DIALOG_BUTTON_CLASSNAME = DX_DIALOG_CLASSNAME + "-button";
        var FakeDialogComponent = Component.inherit({
            ctor: function(element, options) {
                this.callBase(options)
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "ios"
                    },
                    options: {
                        width: 276
                    }
                }, {
                    device: {
                        platform: "android"
                    },
                    options: {
                        lWidth: "60%",
                        pWidth: "80%"
                    }
                }, {
                    device: function(device) {
                        var currentTheme = (themes.current() || "").split(".")[0];
                        return !device.phone && "win8" === currentTheme
                    },
                    options: {
                        width: function() {
                            return $(window).width()
                        }
                    }
                }, {
                    device: function(device) {
                        var currentTheme = (themes.current() || "").split(".")[0];
                        return device.phone && "win8" === currentTheme
                    },
                    options: {
                        position: {
                            my: "top center",
                            at: "top center",
                            of: window,
                            offset: "0 0"
                        }
                    }
                }])
            }
        });
        var dialog = function(options) {
            var deferred = $.Deferred();
            var defaultOptions = (new FakeDialogComponent).option();
            options = $.extend(defaultOptions, options);
            var $element = $("<div>").addClass(DX_DIALOG_CLASSNAME).appendTo(viewPortUtils.value());
            var $message = $("<div>").addClass(DX_DIALOG_MESSAGE_CLASSNAME).html(String(options.message));
            var popupToolbarItems = [];
            var toolbarItemsOption = options.buttons;
            if (toolbarItemsOption) {
                errors.log("W0001", "DevExpress.ui.dialog", "buttons", "16.1", "Use the 'toolbarItems' option instead")
            } else {
                toolbarItemsOption = options.toolbarItems
            }
            $.each(toolbarItemsOption || [DEFAULT_BUTTON], function() {
                var action = new Action(this.onClick, {
                    context: popupInstance
                });
                popupToolbarItems.push({
                    toolbar: "bottom",
                    location: devices.current().android ? "after" : "center",
                    widget: "dxButton",
                    options: $.extend({}, this, {
                        onClick: function() {
                            var result = action.execute(arguments);
                            hide(result)
                        }
                    })
                })
            });
            var popupInstance = new Popup($element, {
                title: options.title || this.title,
                showTitle: function() {
                    var isTitle = void 0 === options.showTitle ? true : options.showTitle;
                    return isTitle
                }(),
                height: "auto",
                width: function() {
                    var isPortrait = $(window).height() > $(window).width(),
                        key = (isPortrait ? "p" : "l") + "Width",
                        widthOption = options.hasOwnProperty(key) ? options[key] : options.width;
                    return $.isFunction(widthOption) ? widthOption() : widthOption
                },
                showCloseButton: options.showCloseButton || false,
                focusStateEnabled: false,
                onContentReady: function(args) {
                    args.component.content().addClass(DX_DIALOG_CONTENT_CLASSNAME).append($message)
                },
                onShowing: function(e) {
                    e.component.bottomToolbar().addClass(DX_DIALOG_BUTTONS_CLASSNAME).find(".dx-button").addClass(DX_DIALOG_BUTTON_CLASSNAME);
                    domUtils.resetActiveElement()
                },
                onShown: function(e) {
                    e.component.bottomToolbar().find(".dx-button").first().focus()
                },
                onHiding: function() {
                    deferred.reject()
                },
                toolbarItems: popupToolbarItems,
                animation: {
                    show: {
                        type: "pop",
                        duration: 400
                    },
                    hide: {
                        type: "pop",
                        duration: 400,
                        to: {
                            opacity: 0,
                            scale: 0
                        },
                        from: {
                            opacity: 1,
                            scale: 1
                        }
                    }
                },
                rtlEnabled: config().rtlEnabled,
                boundaryOffset: {
                    h: 10,
                    v: 0
                }
            });
            popupInstance._wrapper().addClass(DX_DIALOG_WRAPPER_CLASSNAME);
            if (options.position) {
                popupInstance.option("position", options.position)
            }
            popupInstance._wrapper().addClass(DX_DIALOG_ROOT_CLASSNAME);

            function show() {
                popupInstance.show();
                return deferred.promise()
            }

            function hide(value) {
                deferred.resolve(value);
                popupInstance.hide().done(function() {
                    popupInstance.element().remove()
                })
            }
            return {
                show: show,
                hide: hide
            }
        };
        var alert = function(message, title, showTitle) {
            var dialogInstance, options = $.isPlainObject(message) ? message : {
                title: title,
                message: message,
                showTitle: showTitle
            };
            dialogInstance = this.custom(options);
            return dialogInstance.show()
        };
        var confirm = function(message, title, showTitle) {
            var dialogInstance, options = $.isPlainObject(message) ? message : {
                title: title,
                message: message,
                showTitle: showTitle,
                toolbarItems: [{
                    text: messageLocalization.format("Yes"),
                    onClick: function() {
                        return true
                    }
                }, {
                    text: messageLocalization.format("No"),
                    onClick: function() {
                        return false
                    }
                }]
            };
            dialogInstance = this.custom(options);
            return dialogInstance.show()
        };
        exports.custom = dialog;
        exports.alert = alert;
        exports.confirm = confirm;
        exports.FakeDialogComponent = FakeDialogComponent
    },
    /*!*****************************!*\
      !*** ./Scripts/ui/popup.js ***!
      \*****************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            camelize = __webpack_require__( /*! ../core/utils/inflector */ 49).camelize,
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Button = __webpack_require__( /*! ./button */ 196),
            themes = __webpack_require__( /*! ./themes */ 143),
            Overlay = __webpack_require__( /*! ./overlay */ 109);
        __webpack_require__( /*! ./toolbar/ui.toolbar.base */ 198);
        var POPUP_CLASS = "dx-popup",
            POPUP_WRAPPER_CLASS = "dx-popup-wrapper",
            POPUP_FULL_SCREEN_CLASS = "dx-popup-fullscreen",
            POPUP_FULL_SCREEN_WIDTH_CLASS = "dx-popup-fullscreen-width",
            POPUP_NORMAL_CLASS = "dx-popup-normal",
            POPUP_CONTENT_CLASS = "dx-popup-content",
            POPUP_DRAGGABLE_CLASS = "dx-popup-draggable",
            POPUP_TITLE_CLASS = "dx-popup-title",
            POPUP_TITLE_CLOSEBUTTON_CLASS = "dx-closebutton",
            POPUP_BOTTOM_CLASS = "dx-popup-bottom",
            TEMPLATE_WRAPPER_CLASS = "dx-template-wrapper",
            ALLOWED_TOOLBAR_ITEM_ALIASES = ["cancel", "clear", "done"];
        var getButtonPlace = function(name) {
            var device = devices.current(),
                platform = device.platform,
                toolbar = "bottom",
                location = "before";
            if ("ios" === platform) {
                switch (name) {
                    case "cancel":
                        toolbar = "top";
                        break;
                    case "clear":
                        toolbar = "top";
                        location = "after";
                        break;
                    case "done":
                        location = "after"
                }
            } else {
                if ("win" === platform) {
                    location = "after"
                } else {
                    if ("android" === platform && device.version && parseInt(device.version[0]) > 4) {
                        switch (name) {
                            case "cancel":
                                location = "after";
                                break;
                            case "done":
                                location = "after"
                        }
                    } else {
                        if ("android" === platform) {
                            location = "center"
                        }
                    }
                }
            }
            return {
                toolbar: toolbar,
                location: location
            }
        };
        var Popup = Overlay.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    fullScreen: false,
                    title: "",
                    showTitle: true,
                    titleTemplate: "title",
                    onTitleRendered: null,
                    dragEnabled: false,
                    toolbarItems: [],
                    showCloseButton: false,
                    bottomTemplate: "bottom"
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        var currentTheme = (themes.current() || "").split(".")[0];
                        return "win8" === currentTheme
                    },
                    options: {
                        width: function() {
                            return $(window).width()
                        }
                    }
                }, {
                    device: function(device) {
                        var currentTheme = (themes.current() || "").split(".")[0];
                        return device.phone && "win8" === currentTheme
                    },
                    options: {
                        position: {
                            my: "top center",
                            at: "top center",
                            offset: "0 0"
                        }
                    }
                }, {
                    device: {
                        platform: "ios"
                    },
                    options: {
                        animation: this._iosAnimation
                    }
                }, {
                    device: {
                        platform: "android"
                    },
                    options: {
                        animation: this._androidAnimation
                    }
                }, {
                    device: {
                        platform: "generic"
                    },
                    options: {
                        showCloseButton: true
                    }
                }, {
                    device: function(device) {
                        return "generic" === devices.real().platform && "generic" === device.platform
                    },
                    options: {
                        dragEnabled: true
                    }
                }, {
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    buttons: {
                        since: "16.1",
                        alias: "toolbarItems"
                    }
                })
            },
            _iosAnimation: {
                show: {
                    type: "slide",
                    duration: 400,
                    from: {
                        position: {
                            my: "top",
                            at: "bottom"
                        }
                    },
                    to: {
                        position: {
                            my: "center",
                            at: "center"
                        }
                    }
                },
                hide: {
                    type: "slide",
                    duration: 400,
                    from: {
                        opacity: 1,
                        position: {
                            my: "center",
                            at: "center"
                        }
                    },
                    to: {
                        opacity: 1,
                        position: {
                            my: "top",
                            at: "bottom"
                        }
                    }
                }
            },
            _androidAnimation: function() {
                var fullScreenConfig = {
                        show: {
                            type: "slide",
                            duration: 300,
                            from: {
                                top: "30%",
                                opacity: 0
                            },
                            to: {
                                top: 0,
                                opacity: 1
                            }
                        },
                        hide: {
                            type: "slide",
                            duration: 300,
                            from: {
                                top: 0,
                                opacity: 1
                            },
                            to: {
                                top: "30%",
                                opacity: 0
                            }
                        }
                    },
                    defaultConfig = {
                        show: {
                            type: "fade",
                            duration: 400,
                            from: 0,
                            to: 1
                        },
                        hide: {
                            type: "fade",
                            duration: 400,
                            from: 1,
                            to: 0
                        }
                    };
                return this.option("fullScreen") ? fullScreenConfig : defaultConfig
            },
            _init: function() {
                this.callBase();
                this.element().addClass(POPUP_CLASS);
                this._wrapper().addClass(POPUP_WRAPPER_CLASS);
                this._$popupContent = this._$content.wrapInner($("<div>").addClass(POPUP_CONTENT_CLASS)).children().eq(0)
            },
            _render: function() {
                var isFullscreen = this.option("fullScreen");
                this._$content.toggleClass(POPUP_FULL_SCREEN_CLASS, isFullscreen).toggleClass(POPUP_NORMAL_CLASS, !isFullscreen);
                this.callBase()
            },
            _renderContentImpl: function() {
                this.callBase();
                this._renderTitle();
                this._renderBottom()
            },
            _renderTitle: function() {
                var items = this._getToolbarItems("top"),
                    titleText = this.option("title"),
                    showTitle = this.option("showTitle");
                if (showTitle && !!titleText) {
                    items.unshift({
                        location: devices.current().ios ? "center" : "before",
                        text: titleText
                    })
                }
                if (showTitle || items.length > 0) {
                    this._$title && this._$title.remove();
                    var $title = $("<div>").addClass(POPUP_TITLE_CLASS).insertBefore(this.content());
                    this._$title = this._renderTemplateByType("titleTemplate", items, $title).addClass(POPUP_TITLE_CLASS);
                    this._renderDrag();
                    this._executeTitleRenderAction(this._$title)
                } else {
                    if (this._$title) {
                        this._$title.detach()
                    }
                }
            },
            _renderTemplateByType: function(optionName, data, $container) {
                var $result, template = this._getTemplateByOption(optionName),
                    toolbarTemplate = template.owner() === this.option("templateProvider");
                if (toolbarTemplate) {
                    $result = template.render({
                        model: data,
                        container: $container
                    });
                    $container.replaceWith($result);
                    return $result
                } else {
                    $result = template.render({
                        container: $container
                    });
                    if ($result.hasClass(TEMPLATE_WRAPPER_CLASS)) {
                        $container.replaceWith($result);
                        $container = $result
                    }
                    return $container
                }
            },
            _executeTitleRenderAction: function(titleElement) {
                this._getTitleRenderAction()({
                    titleElement: titleElement
                })
            },
            _getTitleRenderAction: function() {
                return this._titleRenderAction || this._createTitleRenderAction()
            },
            _createTitleRenderAction: function() {
                return this._titleRenderAction = this._createActionByOption("onTitleRendered", {
                    element: this.element(),
                    excludeValidators: ["designMode", "disabled", "readOnly"]
                })
            },
            _getCloseButton: function() {
                return {
                    toolbar: "top",
                    location: "after",
                    template: this._getCloseButtonRenderer()
                }
            },
            _getCloseButtonRenderer: function() {
                return $.proxy(function(_, __, $container) {
                    var $button = $("<div>").addClass(POPUP_TITLE_CLOSEBUTTON_CLASS);
                    this._createComponent($button, Button, {
                        icon: "close",
                        onClick: this._createToolbarItemAction(void 0),
                        _templates: {}
                    });
                    $container.append($button)
                }, this)
            },
            _getToolbarItems: function(toolbar) {
                var toolbarItems = this.option("toolbarItems");
                var toolbarsItems = [];
                this._toolbarItemClasses = [];
                var currentPlatform = devices.current().platform,
                    index = 0;
                $.each(toolbarItems, $.proxy(function(_, data) {
                    var isShortcut = commonUtils.isDefined(data.shortcut),
                        item = isShortcut ? getButtonPlace(data.shortcut) : data;
                    if (isShortcut && "ios" === currentPlatform && index < 2) {
                        item.toolbar = "top";
                        index++
                    }
                    $.extend(item, commonUtils.isDefined(data.toolbar) ? {
                        toolbar: data.toolbar
                    } : {});
                    if (item && item.toolbar === toolbar) {
                        if (isShortcut) {
                            $.extend(item, {
                                location: data.location
                            }, this._getToolbarItemByAlias(data))
                        }
                        var isLTROrder = "win" === currentPlatform || "generic" === currentPlatform;
                        if ("done" === data.shortcut && isLTROrder || "cancel" === data.shortcut && !isLTROrder) {
                            toolbarsItems.unshift(item)
                        } else {
                            toolbarsItems.push(item)
                        }
                    }
                }, this));
                if ("top" === toolbar && this.option("showCloseButton") && this.option("showTitle")) {
                    toolbarsItems.push(this._getCloseButton())
                }
                return toolbarsItems
            },
            _getToolbarItemByAlias: function(data) {
                var that = this,
                    itemType = data.shortcut;
                if ($.inArray(itemType, ALLOWED_TOOLBAR_ITEM_ALIASES) < 0) {
                    return false
                }
                var itemConfig = $.extend({
                    text: messageLocalization.format(camelize(itemType, true)),
                    onClick: this._createToolbarItemAction(data.onClick),
                    _templates: {}
                }, data.options || {});
                var itemClass = POPUP_CLASS + "-" + itemType;
                this._toolbarItemClasses.push(itemClass);
                return {
                    template: function(_, __, $container) {
                        var $toolbarItem = $("<div>").addClass(itemClass).appendTo($container);
                        that._createComponent($toolbarItem, Button, itemConfig)
                    }
                }
            },
            _createToolbarItemAction: function(clickAction) {
                return this._createAction(clickAction, {
                    afterExecute: function(e) {
                        e.component.hide()
                    }
                })
            },
            _renderBottom: function() {
                var items = this._getToolbarItems("bottom");
                if (items.length) {
                    this._$bottom && this._$bottom.remove();
                    var $bottom = $("<div>").addClass(POPUP_BOTTOM_CLASS).insertAfter(this.content());
                    this._$bottom = this._renderTemplateByType("bottomTemplate", items, $bottom).addClass(POPUP_BOTTOM_CLASS);
                    this._toggleClasses()
                } else {
                    this._$bottom && this._$bottom.detach()
                }
            },
            _toggleClasses: function() {
                var aliases = ALLOWED_TOOLBAR_ITEM_ALIASES;
                $.each(aliases, $.proxy(function(_, alias) {
                    var className = POPUP_CLASS + "-" + alias;
                    if ($.inArray(className, this._toolbarItemClasses) >= 0) {
                        this._wrapper().addClass(className + "-visible");
                        this._$bottom.addClass(className)
                    } else {
                        this._wrapper().removeClass(className + "-visible");
                        this._$bottom.removeClass(className)
                    }
                }, this))
            },
            _getDragTarget: function() {
                return this._$title
            },
            _renderGeometryImpl: function() {
                this._resetContentHeight();
                this.callBase.apply(this, arguments);
                this._setContentHeight()
            },
            _resetContentHeight: function() {
                this._$popupContent.css({
                    height: "auto"
                })
            },
            _renderDrag: function() {
                this.callBase();
                this._$content.toggleClass(POPUP_DRAGGABLE_CLASS, this.option("dragEnabled"))
            },
            _renderResize: function() {
                this.callBase();
                this._$content.dxResizable("option", "onResize", $.proxy(function() {
                    this._setContentHeight();
                    this._actions.onResize(arguments)
                }, this))
            },
            _setContentHeight: function() {
                if (this._disallowUpdateContentHeight()) {
                    return
                }
                var contentPaddings = this._$content.outerHeight() - this._$content.height(),
                    contentHeight = this._$content.get(0).getBoundingClientRect().height - contentPaddings;
                if (this._$title && this._$title.is(":visible")) {
                    contentHeight -= this._$title.get(0).getBoundingClientRect().height || 0
                }
                if (this._$bottom && this._$bottom.is(":visible")) {
                    contentHeight -= this._$bottom.get(0).getBoundingClientRect().height || 0
                }
                this._$popupContent.css({
                    height: contentHeight
                })
            },
            _disallowUpdateContentHeight: function() {
                var isHeightAuto = "auto" === this._$content.get(0).style.height,
                    maxHeightSpecified = "none" !== this._$content.css("maxHeight"),
                    minHeightSpecified = parseInt(this._$content.css("minHeight")) > 0;
                return isHeightAuto && !(maxHeightSpecified || minHeightSpecified)
            },
            _renderDimensions: function() {
                if (this.option("fullScreen")) {
                    this._$content.css({
                        width: "100%",
                        height: "100%"
                    })
                } else {
                    this.callBase.apply(this, arguments)
                }
                this._renderFullscreenWidthClass()
            },
            _renderFullscreenWidthClass: function() {
                this.overlayContent().toggleClass(POPUP_FULL_SCREEN_WIDTH_CLASS, this.overlayContent().outerWidth() === $(window).width())
            },
            _renderShadingDimensions: function() {
                if (this.option("fullScreen")) {
                    this._wrapper().css({
                        width: "100%",
                        height: "100%"
                    })
                } else {
                    this.callBase.apply(this, arguments)
                }
            },
            _renderPosition: function() {
                if (this.option("fullScreen")) {
                    translator.move(this._$content, {
                        top: 0,
                        left: 0
                    })
                } else {
                    return this.callBase.apply(this, arguments)
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "showTitle":
                    case "title":
                    case "titleTemplate":
                        this._renderTitle();
                        this._renderGeometry();
                        break;
                    case "bottomTemplate":
                        this._renderBottom();
                        this._renderGeometry();
                        break;
                    case "onTitleRendered":
                        this._createTitleRenderAction(args.value);
                        break;
                    case "toolbarItems":
                        this._renderTitle();
                        this._renderBottom();
                        this._renderGeometry();
                        break;
                    case "dragEnabled":
                        this._renderDrag();
                        break;
                    case "fullScreen":
                        this._$content.toggleClass(POPUP_FULL_SCREEN_CLASS, args.value);
                        this._refresh();
                        break;
                    case "showCloseButton":
                        this._renderTitle();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            bottomToolbar: function() {
                return this._$bottom
            },
            content: function() {
                return this._$popupContent
            },
            overlayContent: function() {
                return this._$content
            }
        });
        registerComponent("dxPopup", Popup);
        module.exports = Popup
    },
    /*!******************************!*\
      !*** ./Scripts/ui/button.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            iconUtils = __webpack_require__( /*! ../core/utils/icon */ 99),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            ValidationMixin = __webpack_require__( /*! ./validation/validation_mixin */ 108),
            ValidationEngine = __webpack_require__( /*! ./validation_engine */ 117),
            Widget = __webpack_require__( /*! ./widget/ui.widget */ 89),
            inkRipple = __webpack_require__( /*! ./widget/utils.ink_ripple */ 197),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            themes = __webpack_require__( /*! ./themes */ 143),
            clickEvent = __webpack_require__( /*! ../events/click */ 64);
        var BUTTON_CLASS = "dx-button",
            BUTTON_CONTENT_CLASS = "dx-button-content",
            BUTTON_HAS_TEXT_CLASS = "dx-button-has-text",
            BUTTON_HAS_ICON_CLASS = "dx-button-has-icon",
            TEMPLATE_WRAPPER_CLASS = "dx-template-wrapper",
            ANONYMOUS_TEMPLATE_NAME = "content",
            BUTTON_FEEDBACK_HIDE_TIMEOUT = 100;
        var Button = Widget.inherit({
            _supportedKeys: function() {
                var that = this,
                    click = function(e) {
                        e.preventDefault();
                        that._executeClickAction(e)
                    };
                return $.extend(this.callBase(), {
                    space: click,
                    enter: click
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    iconSrc: {
                        since: "15.1",
                        alias: "icon"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    onClick: null,
                    type: "normal",
                    text: "",
                    icon: "",
                    validationGroup: void 0,
                    activeStateEnabled: true,
                    template: "content",
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _getAnonymousTemplateName: function() {
                return ANONYMOUS_TEMPLATE_NAME
            },
            _feedbackHideTimeout: BUTTON_FEEDBACK_HIDE_TIMEOUT,
            _render: function() {
                this.element().addClass(BUTTON_CLASS);
                this._renderType();
                this.option("useInkRipple") && this._renderInkRipple();
                this._renderClick();
                this.setAria("role", "button");
                this._updateAriaLabel();
                this.callBase()
            },
            _renderInkRipple: function() {
                var isOnlyIconButton = !this.option("text") && this.option("icon") || "back" === this.option("type"),
                    config = {};
                if (isOnlyIconButton) {
                    $.extend(config, {
                        waveSizeCoefficient: 1,
                        useHoldAnimation: false,
                        isCentered: true
                    })
                }
                this._inkRipple = inkRipple.render(config)
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: this._$content,
                    jQueryEvent: e
                };
                if (value) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _renderContentImpl: function() {
                var $element = this.element(),
                    data = this._getContentData();
                if (this._$content) {
                    this._$content.empty()
                } else {
                    this._$content = $("<div>").addClass(BUTTON_CONTENT_CLASS).appendTo($element)
                }
                $element.toggleClass(BUTTON_HAS_ICON_CLASS, !!data.icon).toggleClass(BUTTON_HAS_TEXT_CLASS, !!data.text);
                var template = this._getTemplateByOption("template"),
                    $result = template.render({
                        model: data,
                        container: this._$content
                    });
                if ($result.hasClass(TEMPLATE_WRAPPER_CLASS)) {
                    this._$content.replaceWith($result);
                    this._$content = $result;
                    this._$content.addClass(BUTTON_CONTENT_CLASS)
                }
            },
            _getContentData: function() {
                var icon = this.option("icon"),
                    text = this.option("text"),
                    back = "back" === this.option("type");
                if (back && !icon) {
                    icon = "back"
                }
                return {
                    icon: icon,
                    text: text
                }
            },
            _renderClick: function() {
                var that = this,
                    eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                this._clickAction = this._createActionByOption("onClick");
                this.element().off(eventName).on(eventName, function(e) {
                    that._executeClickAction(e)
                })
            },
            _executeClickAction: function(e) {
                this._clickAction({
                    jQueryEvent: e,
                    validationGroup: ValidationEngine.getGroupConfig(this._findGroup())
                })
            },
            _updateAriaLabel: function() {
                var icon = this.option("icon"),
                    text = this.option("text");
                if ("image" === iconUtils.getImageSourceType(icon)) {
                    if (icon.indexOf("base64") === -1) {
                        icon = icon.replace(/.+\/([^\.]+)\..+$/, "$1")
                    } else {
                        icon = "Base64"
                    }
                }
                var ariaLabel = text || icon;
                this.setAria("label", $.trim(ariaLabel))
            },
            _renderType: function() {
                var type = this.option("type");
                if (type) {
                    this.element().addClass("dx-button-" + type)
                }
            },
            _refreshType: function(prevType) {
                var type = this.option("type");
                prevType && this.element().removeClass("dx-button-" + prevType).addClass("dx-button-" + type);
                if (!this.element().hasClass(BUTTON_HAS_ICON_CLASS) && "back" === type) {
                    this._renderContentImpl()
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onClick":
                        this._renderClick();
                        break;
                    case "icon":
                    case "text":
                        this._renderContentImpl();
                        this._updateAriaLabel();
                        break;
                    case "type":
                        this._refreshType(args.previousValue);
                        this._renderContentImpl();
                        this._updateAriaLabel();
                        break;
                    case "template":
                        this._renderContentImpl();
                        break;
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _clean: function() {
                this.callBase();
                delete this._$content
            }
        }).include(ValidationMixin);
        registerComponent("dxButton", Button);
        module.exports = Button
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/widget/utils.ink_ripple.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var INKRIPPLE_CLASS = "dx-inkripple",
            INKRIPPLE_WAVE_CLASS = "dx-inkripple-wave",
            INKRIPPLE_SHOWING_CLASS = "dx-inkripple-showing",
            INKRIPPLE_HIDING_CLASS = "dx-inkripple-hiding";
        var DEFAULT_WAVE_SIZE_COEFFICIENT = 2,
            MAX_WAVE_SIZE = 4e3,
            ANIMATION_DURATION = 300,
            HOLD_ANIMATION_DURATION = 1e3,
            DEFAULT_WAVE_INDEX = 0;
        var render = function(args) {
            args = args || {};
            if (void 0 === args.useHoldAnimation) {
                args.useHoldAnimation = true
            }
            var config = {
                waveSizeCoefficient: args.waveSizeCoefficient || DEFAULT_WAVE_SIZE_COEFFICIENT,
                isCentered: args.isCentered || false,
                wavesNumber: args.wavesNumber || 1,
                durations: getDurations(args.useHoldAnimation)
            };
            return {
                showWave: $.proxy(showWave, null, config),
                hideWave: $.proxy(hideWave, null, config)
            }
        };
        var getInkRipple = function(element) {
            var result = element.children("." + INKRIPPLE_CLASS);
            if (0 === result.length) {
                result = $("<div>").addClass(INKRIPPLE_CLASS).appendTo(element)
            }
            return result
        };
        var getWaves = function(element, wavesNumber) {
            var inkRipple = getInkRipple(element),
                result = inkRipple.children("." + INKRIPPLE_WAVE_CLASS);
            for (var i = result.length; i < wavesNumber; i++) {
                var $currentWave = $("<div>").appendTo(inkRipple).addClass(INKRIPPLE_WAVE_CLASS);
                result.push($currentWave[0])
            }
            return result
        };
        var getWaveStyleConfig = function(args, config) {
            var left, top, element = config.element,
                elementWidth = element.width(),
                elementHeight = element.height(),
                elementDiagonal = parseInt(Math.sqrt(elementWidth * elementWidth + elementHeight * elementHeight)),
                waveSize = Math.min(MAX_WAVE_SIZE, parseInt(elementDiagonal * args.waveSizeCoefficient));
            if (args.isCentered) {
                left = (elementWidth - waveSize) / 2;
                top = (elementHeight - waveSize) / 2
            } else {
                var event = config.jQueryEvent,
                    position = config.element.offset(),
                    x = event.pageX - position.left,
                    y = event.pageY - position.top;
                left = x - waveSize / 2;
                top = y - waveSize / 2
            }
            return {
                left: left,
                top: top,
                height: waveSize,
                width: waveSize
            }
        };
        var showWave = function(args, config) {
            var $wave = getWaves(config.element, args.wavesNumber).eq(config.wave || DEFAULT_WAVE_INDEX);
            args.hidingTimeout && clearTimeout(args.hidingTimeout);
            hideSelectedWave($wave);
            $wave.css(getWaveStyleConfig(args, config));
            setTimeout($.proxy(showingWaveHandler, null, args, $wave), 0)
        };
        var showingWaveHandler = function(args, $wave) {
            var durationCss = args.durations.showingScale + "ms";
            $wave.addClass(INKRIPPLE_SHOWING_CLASS).css("transition-duration", durationCss)
        };
        var getDurations = function(useHoldAnimation) {
            return {
                showingScale: useHoldAnimation ? HOLD_ANIMATION_DURATION : ANIMATION_DURATION,
                hidingScale: ANIMATION_DURATION,
                hidingOpacity: ANIMATION_DURATION
            }
        };
        var hideSelectedWave = function($wave) {
            $wave.removeClass(INKRIPPLE_HIDING_CLASS).css("transition-duration", "")
        };
        var hideWave = function(args, config) {
            var $wave = getWaves(config.element, config.wavesNumber).eq(config.wave || DEFAULT_WAVE_INDEX),
                durations = args.durations,
                durationCss = durations.hidingScale + "ms, " + durations.hidingOpacity + "ms";
            $wave.addClass(INKRIPPLE_HIDING_CLASS).removeClass(INKRIPPLE_SHOWING_CLASS).css("transition-duration", durationCss);
            var animationDuration = Math.max(durations.hidingScale, durations.hidingOpacity);
            args.hidingTimeout = setTimeout($.proxy(hideSelectedWave, null, $wave), animationDuration)
        };
        module.exports = {
            render: render
        }
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.base.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            CollectionWidget = __webpack_require__( /*! ../collection/ui.collection_widget.edit */ 151);
        var TOOLBAR_CLASS = "dx-toolbar",
            TOOLBAR_BOTTOM_CLASS = "dx-toolbar-bottom",
            TOOLBAR_MINI_CLASS = "dx-toolbar-mini",
            TOOLBAR_ITEM_CLASS = "dx-toolbar-item",
            TOOLBAR_LABEL_CLASS = "dx-toolbar-label",
            TOOLBAR_BUTTON_CLASS = "dx-toolbar-button",
            TOOLBAR_ITEMS_CONTAINER_CLASS = "dx-toolbar-items-container",
            TOOLBAR_GROUP_CLASS = "dx-toolbar-group",
            TOOLBAR_LABEL_SELECTOR = "." + TOOLBAR_LABEL_CLASS,
            TOOLBAR_ITEM_DATA_KEY = "dxToolbarItemDataKey";
        var ToolbarBase = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    renderAs: "topToolbar"
                })
            },
            _itemContainer: function() {
                return this._$toolbarItemsContainer.find([".dx-toolbar-before", ".dx-toolbar-center", ".dx-toolbar-after"].join(","))
            },
            _itemClass: function() {
                return TOOLBAR_ITEM_CLASS
            },
            _itemDataKey: function() {
                return TOOLBAR_ITEM_DATA_KEY
            },
            _buttonClass: function() {
                return TOOLBAR_BUTTON_CLASS
            },
            _dimensionChanged: function() {
                this._arrangeItems()
            },
            _render: function() {
                this._renderToolbar();
                this._renderSections();
                this.setAria("role", "toolbar");
                this.callBase();
                this._arrangeItems()
            },
            _renderToolbar: function() {
                this.element().addClass(TOOLBAR_CLASS).toggleClass(TOOLBAR_BOTTOM_CLASS, "bottomToolbar" === this.option("renderAs"));
                this._$toolbarItemsContainer = $("<div>").addClass(TOOLBAR_ITEMS_CONTAINER_CLASS).appendTo(this.element())
            },
            _renderSections: function() {
                var $container = this._$toolbarItemsContainer,
                    that = this;
                $.each(["before", "center", "after"], function() {
                    var sectionClass = "dx-toolbar-" + this,
                        $section = $container.find("." + sectionClass);
                    if (!$section.length) {
                        that["_$" + this + "Section"] = $section = $("<div>").addClass(sectionClass).appendTo($container)
                    }
                })
            },
            _arrangeItems: function(elementWidth) {
                elementWidth = elementWidth || this.element().width();
                this._$centerSection.css({
                    margin: "0 auto",
                    "float": "none"
                });
                var beforeRect = this._$beforeSection.get(0).getBoundingClientRect(),
                    centerRect = this._$centerSection.get(0).getBoundingClientRect(),
                    afterRect = this._$afterSection.get(0).getBoundingClientRect();
                if (beforeRect.right > centerRect.left || centerRect.right > afterRect.left) {
                    this._$centerSection.css({
                        marginLeft: Math.round(beforeRect.width),
                        marginRight: Math.round(afterRect.width),
                        "float": beforeRect.width > afterRect.width ? "none" : "right"
                    })
                }
                var $label = this._$toolbarItemsContainer.find(TOOLBAR_LABEL_SELECTOR).eq(0),
                    $section = $label.parent();
                if (!$label.length) {
                    return
                }
                var labelOffset = beforeRect.width ? Math.round(beforeRect.width) : $label.position().left,
                    widthBeforeSection = $section.hasClass("dx-toolbar-before") ? 0 : labelOffset,
                    widthAfterSection = $section.hasClass("dx-toolbar-after") ? 0 : Math.round(afterRect.width),
                    elemsAtSectionWidth = 0;
                $section.children().not(TOOLBAR_LABEL_SELECTOR).each(function() {
                    elemsAtSectionWidth += $(this).outerWidth()
                });
                var freeSpace = elementWidth - elemsAtSectionWidth,
                    labelPaddings = $label.outerWidth() - $label.width(),
                    labelMaxWidth = Math.max(freeSpace - widthBeforeSection - widthAfterSection - labelPaddings, 0);
                $label.css("max-width", labelMaxWidth)
            },
            _renderItem: function(index, item, itemContainer, $after) {
                var location = item.location || "center",
                    container = itemContainer || this._$toolbarItemsContainer.find(".dx-toolbar-" + location),
                    itemHasText = Boolean(item.text),
                    itemElement = this.callBase(index, item, container, $after);
                itemElement.toggleClass(this._buttonClass(), !itemHasText).toggleClass(TOOLBAR_LABEL_CLASS, itemHasText);
                return itemElement
            },
            _renderGroupedItems: function() {
                var that = this;
                $.each(this.option("items"), function(groupIndex, group) {
                    var groupItems = group.items,
                        $container = $("<div>", {
                            "class": TOOLBAR_GROUP_CLASS
                        }),
                        location = group.location || "center";
                    if (!groupItems.length) {
                        return
                    }
                    $.each(groupItems, function(itemIndex, item) {
                        that._renderItem(itemIndex, item, $container, null)
                    });
                    that._$toolbarItemsContainer.find(".dx-toolbar-" + location).append($container)
                })
            },
            _renderItems: function(items) {
                var grouped = items.length && items[0].items;
                grouped ? this._renderGroupedItems() : this.callBase(items)
            },
            _getToolbarItems: function() {
                return this.option("items") || []
            },
            _renderContentImpl: function() {
                var items = this._getToolbarItems();
                this.element().toggleClass(TOOLBAR_MINI_CLASS, 0 === items.length);
                if (this._renderedItemsCount) {
                    this._renderItems(items.slice(this._renderedItemsCount))
                } else {
                    this._renderItems(items)
                }
            },
            _renderEmptyMessage: $.noop,
            _clean: function() {
                this._$toolbarItemsContainer.children().empty();
                this.element().empty()
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._arrangeItems()
                }
            },
            _isVisible: function() {
                return this.element().width() > 0 && this.element().height() > 0
            },
            _getIndexByItem: function(item) {
                return $.inArray(item, this._getToolbarItems())
            },
            _itemOptionChanged: function(item, property, value) {
                this.callBase.apply(this, [item, property, value]);
                this._arrangeItems()
            },
            _optionChanged: function(args) {
                var name = args.name;
                switch (name) {
                    case "width":
                        this.callBase.apply(this, arguments);
                        this._dimensionChanged();
                        break;
                    case "renderAs":
                        this._invalidate();
                        break;
                    default:
                        this.callBase.apply(this, arguments)
                }
            }
        });
        registerComponent("dxToolbarBase", ToolbarBase);
        module.exports = ToolbarBase
    },
    /*!******************************!*\
      !*** ./Scripts/ui/notify.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Action = __webpack_require__( /*! ../core/action */ 35),
            viewPortUtils = __webpack_require__( /*! ../core/utils/view_port */ 42),
            Toast = __webpack_require__( /*! ./toast */ 200);
        var $notify = null;
        var notify = function(message, type, displayTime) {
            var options = $.isPlainObject(message) ? message : {
                message: message
            };
            var userHiddenAction = options.onHidden;
            $.extend(options, {
                type: type,
                displayTime: displayTime,
                onHidden: function(args) {
                    args.element.remove();
                    new Action(userHiddenAction, {
                        context: args.model
                    }).execute(arguments)
                }
            });
            $notify = $("<div>").appendTo(viewPortUtils.value());
            new Toast($notify, options).show()
        };
        module.exports = notify
    },
    /*!*****************************!*\
      !*** ./Scripts/ui/toast.js ***!
      \*****************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            pointerEvents = __webpack_require__( /*! ../events/pointer */ 65),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Overlay = __webpack_require__( /*! ./overlay */ 109);
        var TOAST_CLASS = "dx-toast",
            TOAST_CLASS_PREFIX = TOAST_CLASS + "-",
            TOAST_WRAPPER_CLASS = TOAST_CLASS_PREFIX + "wrapper",
            TOAST_CONTENT_CLASS = TOAST_CLASS_PREFIX + "content",
            TOAST_MESSAGE_CLASS = TOAST_CLASS_PREFIX + "message",
            TOAST_ICON_CLASS = TOAST_CLASS_PREFIX + "icon",
            WIDGET_NAME = "dxToast",
            toastTypes = ["info", "warning", "error", "success"],
            TOAST_STACK = [],
            FIRST_Z_INDEX_OFFSET = 8e3,
            visibleToastInstance = null,
            POSITION_ALIASES = {
                top: {
                    my: "top",
                    at: "top",
                    of: null,
                    offset: "0 0"
                },
                bottom: {
                    my: "bottom",
                    at: "bottom",
                    of: null,
                    offset: "0 -20"
                },
                center: {
                    my: "center",
                    at: "center",
                    of: null,
                    offset: "0 0"
                },
                right: {
                    my: "center right",
                    at: "center right",
                    of: null,
                    offset: "0 0"
                },
                left: {
                    my: "center left",
                    at: "center left",
                    of: null,
                    offset: "0 0"
                }
            };
        $(document).on(pointerEvents.down, function(e) {
            for (var i = TOAST_STACK.length - 1; i >= 0; i--) {
                if (!TOAST_STACK[i]._proxiedDocumentDownHandler(e)) {
                    return
                }
            }
        });
        var Toast = Overlay.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    message: "",
                    type: "info",
                    displayTime: 2e3,
                    position: "bottom center",
                    animation: {
                        show: {
                            type: "fade",
                            duration: 400,
                            from: 0,
                            to: 1
                        },
                        hide: {
                            type: "fade",
                            duration: 400,
                            to: 0
                        }
                    },
                    shading: false,
                    height: "auto",
                    closeOnBackButton: false,
                    closeOnSwipe: true,
                    closeOnClick: false,
                    resizeEnabled: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "win" === device.platform && device.version && 8 === device.version[0]
                    },
                    options: {
                        position: "top center",
                        width: function() {
                            return $(window).width()
                        }
                    }
                }, {
                    device: function(device) {
                        return "win" === device.platform && device.version && 10 === device.version[0]
                    },
                    options: {
                        position: "bottom right",
                        width: "auto"
                    }
                }, {
                    device: {
                        platform: "android"
                    },
                    options: {
                        closeOnOutsideClick: true,
                        width: "auto",
                        position: {
                            at: "bottom left",
                            my: "bottom left",
                            offset: "20 -20"
                        },
                        animation: {
                            show: {
                                type: "slide",
                                duration: 200,
                                from: {
                                    top: $(window).height()
                                }
                            },
                            hide: {
                                type: "slide",
                                duration: 200,
                                to: {
                                    top: $(window).height()
                                }
                            }
                        }
                    }
                }, {
                    device: function(device) {
                        var isPhone = "phone" === device.deviceType,
                            isAndroid = "android" === device.platform,
                            isWin10 = "win" === device.platform && device.version && 10 === device.version[0];
                        return isPhone && (isAndroid || isWin10)
                    },
                    options: {
                        width: function() {
                            return $(window).width()
                        },
                        position: {
                            at: "bottom center",
                            my: "bottom center",
                            offset: "0 0"
                        }
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this._posStringToObject()
            },
            _renderContentImpl: function() {
                if (this.option("message")) {
                    this._message = $("<div>").addClass(TOAST_MESSAGE_CLASS).text(this.option("message")).appendTo(this.content())
                }
                this.setAria("role", "alert", this._message);
                if ($.inArray(this.option("type").toLowerCase(), toastTypes) > -1) {
                    this.content().prepend($("<div>").addClass(TOAST_ICON_CLASS))
                }
                this.callBase()
            },
            _render: function() {
                this.callBase();
                this.element().addClass(TOAST_CLASS);
                this._wrapper().addClass(TOAST_WRAPPER_CLASS);
                this._$content.addClass(TOAST_CLASS_PREFIX + String(this.option("type")).toLowerCase());
                this.content().addClass(TOAST_CONTENT_CLASS);
                this._toggleCloseEvents("Swipe");
                this._toggleCloseEvents("Click")
            },
            _toggleCloseEvents: function(event) {
                var dxEvent = "dx" + event.toLowerCase();
                this._$content.off(dxEvent);
                this.option("closeOn" + event) && this._$content.on(dxEvent, $.proxy(this.hide, this))
            },
            _posStringToObject: function() {
                if (!commonUtils.isString(this.option("position"))) {
                    return
                }
                var verticalPosition = this.option("position").split(" ")[0],
                    horizontalPosition = this.option("position").split(" ")[1];
                this.option("position", $.extend({}, POSITION_ALIASES[verticalPosition]));
                switch (horizontalPosition) {
                    case "center":
                    case "left":
                    case "right":
                        this.option("position").at += " " + horizontalPosition;
                        this.option("position").my += " " + horizontalPosition
                }
            },
            _show: function() {
                if (visibleToastInstance) {
                    clearTimeout(visibleToastInstance._hideTimeout);
                    visibleToastInstance.hide()
                }
                visibleToastInstance = this;
                return this.callBase.apply(this, arguments).done($.proxy(function() {
                    clearTimeout(this._hideTimeout);
                    this._hideTimeout = setTimeout($.proxy(this.hide, this), this.option("displayTime"))
                }, this))
            },
            _hide: function() {
                visibleToastInstance = null;
                return this.callBase.apply(this, arguments)
            },
            _overlayStack: function() {
                return TOAST_STACK
            },
            _zIndexInitValue: function() {
                return this.callBase() + FIRST_Z_INDEX_OFFSET
            },
            _dispose: function() {
                clearTimeout(this._hideTimeout);
                visibleToastInstance = null;
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "type":
                        this._$content.removeClass(TOAST_CLASS_PREFIX + args.previousValue);
                        this._$content.addClass(TOAST_CLASS_PREFIX + String(args.value).toLowerCase());
                        break;
                    case "message":
                        if (this._message) {
                            this._message.text(args.value)
                        }
                        break;
                    case "closeOnSwipe":
                        this._toggleCloseEvents("Swipe");
                        break;
                    case "closeOnClick":
                        this._toggleCloseEvents("Click");
                        break;
                    case "displayTime":
                    case "position":
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent(WIDGET_NAME, Toast);
        module.exports = Toast
    },
    /*!************************************!*\
      !*** ./Scripts/ui/action_sheet.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Button = __webpack_require__( /*! ./button */ 196),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151),
            Popup = __webpack_require__( /*! ./popup */ 195),
            Popover = __webpack_require__( /*! ./popover */ 202);
        var ACTION_SHEET_CLASS = "dx-actionsheet",
            ACTION_SHEET_CONTAINER_CLASS = "dx-actionsheet-container",
            ACTION_SHEET_POPUP_WRAPPER_CLASS = "dx-actionsheet-popup-wrapper",
            ACTION_SHEET_POPOVER_WRAPPER_CLASS = "dx-actionsheet-popover-wrapper",
            ACTION_SHEET_CANCEL_BUTTON_CLASS = "dx-actionsheet-cancel",
            ACTION_SHEET_ITEM_CLASS = "dx-actionsheet-item",
            ACTION_SHEET_ITEM_DATA_KEY = "dxActionSheetItemData",
            ACTION_SHEET_WITHOUT_TITLE_CLASS = "dx-actionsheet-without-title";
        var ActionSheet = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    usePopover: false,
                    target: null,
                    title: "",
                    showTitle: true,
                    showCancelButton: true,
                    cancelText: messageLocalization.format("Cancel"),
                    onCancelClick: null,
                    visible: false,
                    noDataText: "",
                    focusStateEnabled: false,
                    selectionByClick: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "ios",
                        tablet: true
                    },
                    options: {
                        usePopover: true
                    }
                }])
            },
            _itemContainer: function() {
                return this._$itemContainer
            },
            _itemClass: function() {
                return ACTION_SHEET_ITEM_CLASS
            },
            _itemDataKey: function() {
                return ACTION_SHEET_ITEM_DATA_KEY
            },
            _toggleVisibility: $.noop,
            _renderDimensions: $.noop,
            _render: function() {
                this.element().addClass(ACTION_SHEET_CLASS);
                this._createItemContainer();
                this._renderPopup()
            },
            _createItemContainer: function() {
                this._$itemContainer = $("<div>").addClass(ACTION_SHEET_CONTAINER_CLASS);
                this._renderDisabled()
            },
            _renderDisabled: function() {
                this._$itemContainer.toggleClass("dx-state-disabled", this.option("disabled"))
            },
            _renderPopup: function() {
                this._$popup = $("<div>").appendTo(this.element());
                this._isPopoverMode() ? this._createPopover() : this._createPopup();
                this._renderPopupTitle();
                this._mapPopupOption("visible")
            },
            _mapPopupOption: function(optionName) {
                this._popup.option(optionName, this.option(optionName))
            },
            _isPopoverMode: function() {
                return this.option("usePopover") && this.option("target")
            },
            _renderPopupTitle: function() {
                this._mapPopupOption("showTitle");
                this._popup._wrapper().toggleClass(ACTION_SHEET_WITHOUT_TITLE_CLASS, !this.option("showTitle"))
            },
            _clean: function() {
                if (this._$popup) {
                    this._$popup.remove()
                }
                this.callBase()
            },
            _overlayConfig: function() {
                return {
                    onInitialized: $.proxy(function(args) {
                        this._popup = args.component
                    }, this),
                    disabled: false,
                    showTitle: true,
                    title: this.option("title"),
                    deferRendering: !window.angular,
                    onContentReady: $.proxy(this._popupContentReadyAction, this),
                    onHidden: $.proxy(this.hide, this)
                }
            },
            _createPopover: function() {
                this._createComponent(this._$popup, Popover, $.extend(this._overlayConfig(), {
                    width: this.option("width") || 200,
                    height: this.option("height") || "auto",
                    target: this.option("target")
                }));
                this._popup._wrapper().addClass(ACTION_SHEET_POPOVER_WRAPPER_CLASS)
            },
            _createPopup: function() {
                this._createComponent(this._$popup, Popup, $.extend(this._overlayConfig(), {
                    dragEnabled: false,
                    width: this.option("width") || "100%",
                    height: this.option("height") || "auto",
                    showCloseButton: false,
                    position: {
                        my: "bottom",
                        at: "bottom",
                        of: window
                    },
                    animation: {
                        show: {
                            type: "slide",
                            duration: 400,
                            from: {
                                position: {
                                    my: "top",
                                    at: "bottom",
                                    of: window
                                }
                            },
                            to: {
                                position: {
                                    my: "bottom",
                                    at: "bottom",
                                    of: window
                                }
                            }
                        },
                        hide: {
                            type: "slide",
                            duration: 400,
                            from: {
                                position: {
                                    my: "bottom",
                                    at: "bottom",
                                    of: window
                                }
                            },
                            to: {
                                position: {
                                    my: "top",
                                    at: "bottom",
                                    of: window
                                }
                            }
                        }
                    }
                }));
                this._popup._wrapper().addClass(ACTION_SHEET_POPUP_WRAPPER_CLASS)
            },
            _popupContentReadyAction: function() {
                this._popup.content().append(this._$itemContainer);
                this._attachClickEvent();
                this._attachHoldEvent();
                this._renderContent();
                this._renderCancelButton()
            },
            _renderCancelButton: function() {
                if (this._isPopoverMode()) {
                    return
                }
                if (this._$cancelButton) {
                    this._$cancelButton.remove()
                }
                if (this.option("showCancelButton")) {
                    var cancelClickAction = this._createActionByOption("onCancelClick") || $.noop,
                        that = this;
                    this._$cancelButton = $("<div>").addClass(ACTION_SHEET_CANCEL_BUTTON_CLASS).appendTo(this._popup.content());
                    this._createComponent(this._$cancelButton, Button, {
                        disabled: false,
                        text: this.option("cancelText"),
                        onClick: function(e) {
                            var hidingArgs = {
                                jQueryEvent: e,
                                cancel: false
                            };
                            cancelClickAction(hidingArgs);
                            if (!hidingArgs.cancel) {
                                that.hide()
                            }
                        },
                        _templates: {}
                    })
                }
            },
            _attachItemClickEvent: $.noop,
            _itemClickHandler: function(e) {
                this.callBase(e);
                if (!$(e.target).is(".dx-state-disabled, .dx-state-disabled *")) {
                    this.hide()
                }
            },
            _itemHoldHandler: function(e) {
                this.callBase(e);
                if (!$(e.target).is(".dx-state-disabled, .dx-state-disabled *")) {
                    this.hide()
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "width":
                    case "height":
                    case "visible":
                    case "title":
                        this._mapPopupOption(args.name);
                        break;
                    case "disabled":
                        this._renderDisabled();
                        break;
                    case "showTitle":
                        this._renderPopupTitle();
                        break;
                    case "showCancelButton":
                    case "onCancelClick":
                    case "cancelText":
                        this._renderCancelButton();
                        break;
                    case "target":
                    case "usePopover":
                    case "items":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            toggle: function(showing) {
                var that = this,
                    d = $.Deferred();
                that._popup.toggle(showing).done(function() {
                    that.option("visible", showing);
                    d.resolveWith(that)
                });
                return d.promise()
            },
            show: function() {
                return this.toggle(true)
            },
            hide: function() {
                return this.toggle(false)
            }
        });
        registerComponent("dxActionSheet", ActionSheet);
        module.exports = ActionSheet
    },
    /*!*******************************!*\
      !*** ./Scripts/ui/popover.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            stringUtils = __webpack_require__( /*! ../core/utils/string */ 13),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            positionUtils = __webpack_require__( /*! ../animation/position */ 61),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            mathUtils = __webpack_require__( /*! ../core/utils/math */ 79),
            Popup = __webpack_require__( /*! ./popup */ 195);
        var POPOVER_CLASS = "dx-popover",
            POPOVER_WRAPPER_CLASS = "dx-popover-wrapper",
            POPOVER_ARROW_CLASS = "dx-popover-arrow",
            POPOVER_WITHOUT_TITLE_CLASS = "dx-popover-without-title",
            POSITION_FLIP_MAP = {
                left: "right",
                top: "bottom",
                right: "left",
                bottom: "top",
                center: "center"
            },
            WEIGHT_OF_SIDES = {
                left: -1,
                top: -1,
                center: 0,
                right: 1,
                bottom: 1
            },
            POSITION_ALIASES = {
                top: {
                    my: "bottom center",
                    at: "top center",
                    collision: "fit flip"
                },
                bottom: {
                    my: "top center",
                    at: "bottom center",
                    collision: "fit flip"
                },
                right: {
                    my: "left center",
                    at: "right center",
                    collision: "flip fit"
                },
                left: {
                    my: "right center",
                    at: "left center",
                    collision: "flip fit"
                }
            };
        var Popover = Popup.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    target: window,
                    shading: false,
                    position: "bottom",
                    closeOnOutsideClick: true,
                    animation: {
                        show: {
                            type: "fade",
                            from: 0,
                            to: 1
                        },
                        hide: {
                            type: "fade",
                            to: 0
                        }
                    },
                    showTitle: false,
                    width: "auto",
                    height: "auto",
                    dragEnabled: false,
                    resizeEnabled: false,
                    fullScreen: false,
                    closeOnTargetScroll: true,
                    arrowPosition: "",
                    arrowOffset: 0,
                    boundaryOffset: {
                        h: 10,
                        v: 10
                    }
                })
            },
            _defaultOptionsRules: function() {
                return [{
                    device: {
                        platform: "ios"
                    },
                    options: {
                        arrowPosition: {
                            boundaryOffset: {
                                h: 20,
                                v: -10
                            },
                            collision: "fit"
                        }
                    }
                }]
            },
            _init: function() {
                this.callBase();
                this._renderArrow();
                this.element().addClass(POPOVER_CLASS);
                this._wrapper().addClass(POPOVER_WRAPPER_CLASS)
            },
            _renderArrow: function() {
                this._$arrow = $("<div>").addClass(POPOVER_ARROW_CLASS).prependTo(this.overlayContent())
            },
            _documentDownHandler: function(e) {
                if (this._isOutsideClick(e)) {
                    return this.callBase(e)
                }
            },
            _isOutsideClick: function(e) {
                return !$(e.target).closest(this.option("target")).length
            },
            _animate: function(animation) {
                if (animation && animation.to) {
                    $.extend(animation.to, {
                        position: this._getContainerPosition()
                    })
                }
                this.callBase.apply(this, arguments)
            },
            _stopAnimation: function() {
                this.callBase.apply(this, arguments)
            },
            _renderTitle: function() {
                this._wrapper().toggleClass(POPOVER_WITHOUT_TITLE_CLASS, !this.option("showTitle"));
                this.callBase()
            },
            _renderPosition: function() {
                this.callBase();
                this._renderOverlayPosition()
            },
            _renderOverlayBoundaryOffset: $.noop,
            _renderOverlayPosition: function() {
                this._resetOverlayPosition();
                this._updateContentSize();
                var contentPosition = this._getContainerPosition();
                var resultLocation = positionUtils.setup(this._$content, contentPosition);
                var positionSide = this._getSideByLocation(resultLocation);
                this._togglePositionClass("dx-position-" + positionSide);
                this._toggleFlippedClass(resultLocation.h.flip, resultLocation.v.flip);
                this._renderArrowPosition(positionSide)
            },
            _resetOverlayPosition: function() {
                this._setContentHeight(true);
                this._togglePositionClass("dx-position-" + this._positionSide);
                translator.move(this._$content, {
                    left: 0,
                    top: 0
                });
                this._$arrow.css({
                    top: "auto",
                    right: "auto",
                    bottom: "auto",
                    left: "auto"
                })
            },
            _updateContentSize: function() {
                if (!this._$popupContent) {
                    return
                }
                var containerLocation = positionUtils.calculate(this._$content, this._getContainerPosition());
                if (containerLocation.h.oversize > 0 && this._isHorizontalSide() && !containerLocation.h.fit) {
                    var newContainerWidth = this._$content.width() - containerLocation.h.oversize;
                    this._$content.width(newContainerWidth)
                }
                if (containerLocation.v.oversize > 0 && this._isVerticalSide() && !containerLocation.v.fit) {
                    var newOverlayContentHeight = this._$content.height() - containerLocation.v.oversize,
                        newPopupContentHeight = this._$popupContent.height() - containerLocation.v.oversize;
                    this._$content.height(newOverlayContentHeight);
                    this._$popupContent.height(newPopupContentHeight)
                }
            },
            _getContainerPosition: function() {
                var offset = stringUtils.pairToObject(this._position.offset || "");
                var hOffset = offset.h;
                var vOffset = offset.v;
                var isPopoverInside = this._isPopoverInside();
                var sign = (isPopoverInside ? -1 : 1) * WEIGHT_OF_SIDES[this._positionSide];
                var arrowSizeCorrection = this._getContentBorderWidth(this._positionSide);
                if (this._isVerticalSide()) {
                    vOffset += sign * (this._$arrow.height() - arrowSizeCorrection)
                } else {
                    if (this._isHorizontalSide()) {
                        hOffset += sign * (this._$arrow.width() - arrowSizeCorrection)
                    }
                }
                return $.extend({}, this._position, {
                    offset: hOffset + " " + vOffset
                })
            },
            _getContentBorderWidth: function(side) {
                var borderWidth = this._$content.css("border-" + side + "-width");
                return parseInt(borderWidth) || 0
            },
            _getSideByLocation: function(location) {
                var isFlippedByVertical = location.v.flip;
                var isFlippedByHorizontal = location.h.flip;
                return this._isVerticalSide() && isFlippedByVertical || this._isHorizontalSide() && isFlippedByHorizontal || this._isPopoverInside() ? POSITION_FLIP_MAP[this._positionSide] : this._positionSide
            },
            _togglePositionClass: function(positionClass) {
                this._$wrapper.removeClass("dx-position-left dx-position-right dx-position-top dx-position-bottom").addClass(positionClass)
            },
            _toggleFlippedClass: function(isFlippedHorizontal, isFlippedVertical) {
                this._$wrapper.toggleClass("dx-popover-flipped-horizontal", isFlippedHorizontal).toggleClass("dx-popover-flipped-vertical", isFlippedVertical)
            },
            _renderArrowPosition: function(side) {
                this._$arrow.css(POSITION_FLIP_MAP[side], -(this._isVerticalSide(side) ? this._$arrow.height() : this._$arrow.width()));
                var axis = this._isVerticalSide(side) ? "left" : "top";
                var sizeProperty = this._isVerticalSide(side) ? "outerWidth" : "outerHeight";
                var $target = $(this._position.of);
                var targetOffset = $target.offset() || {
                    top: 0,
                    left: 0
                };
                var contentOffset = this._$content.offset();
                var arrowSize = this._$arrow[sizeProperty]();
                var contentLocation = contentOffset[axis];
                var contentSize = this._$content[sizeProperty]();
                var targetLocation = targetOffset[axis];
                var targetSize = $target.get(0).preventDefault ? 0 : $target[sizeProperty]();
                var min = Math.max(contentLocation, targetLocation);
                var max = Math.min(contentLocation + contentSize, targetLocation + targetSize);
                var arrowLocation;
                if ("start" === this.option("arrowPosition")) {
                    arrowLocation = min - contentLocation
                } else {
                    if ("end" === this.option("arrowPosition")) {
                        arrowLocation = max - contentLocation - arrowSize
                    } else {
                        arrowLocation = (min + max) / 2 - contentLocation - arrowSize / 2
                    }
                }
                var borderWidth = this._getContentBorderWidth(side);
                var finalArrowLocation = mathUtils.fitIntoRange(arrowLocation - borderWidth + this.option("arrowOffset"), borderWidth, contentSize - arrowSize - 2 * borderWidth);
                this._$arrow.css(axis, finalArrowLocation)
            },
            _isPopoverInside: function() {
                var position = this._getPosition();
                var my = positionUtils.setup.normalizeAlign(position.my);
                var at = positionUtils.setup.normalizeAlign(position.at);
                return my.h === at.h && my.v === at.v
            },
            _getPosition: function() {
                var position = this.option("position");
                if (commonUtils.isString(position)) {
                    position = $.extend({}, POSITION_ALIASES[position])
                }
                return position
            },
            _setContentHeight: function(fullUpdate) {
                if (fullUpdate) {
                    this.callBase()
                }
            },
            _renderShadingPosition: function() {
                if (this.option("shading")) {
                    this._$wrapper.css({
                        top: 0,
                        left: 0
                    })
                }
            },
            _renderShadingDimensions: function() {
                if (this.option("shading")) {
                    this._$wrapper.css({
                        width: "100%",
                        height: "100%"
                    })
                }
            },
            _normalizePosition: function() {
                var position = $.extend({}, this._getPosition());
                if (!position.of) {
                    position.of = this.option("target")
                }
                if (!position.collision) {
                    position.collision = "flip"
                }
                if (!position.boundaryOffset) {
                    position.boundaryOffset = this.option("boundaryOffset")
                }
                this._positionSide = this._getDisplaySide(position);
                this._position = position
            },
            _getDisplaySide: function(position) {
                var my = positionUtils.setup.normalizeAlign(position.my),
                    at = positionUtils.setup.normalizeAlign(position.at);
                var weightSign = WEIGHT_OF_SIDES[my.h] === WEIGHT_OF_SIDES[at.h] && WEIGHT_OF_SIDES[my.v] === WEIGHT_OF_SIDES[at.v] ? -1 : 1,
                    horizontalWeight = Math.abs(WEIGHT_OF_SIDES[my.h] - weightSign * WEIGHT_OF_SIDES[at.h]),
                    verticalWeight = Math.abs(WEIGHT_OF_SIDES[my.v] - weightSign * WEIGHT_OF_SIDES[at.v]);
                return horizontalWeight > verticalWeight ? at.h : at.v
            },
            _isVerticalSide: function(side) {
                side = side || this._positionSide;
                return "top" === side || "bottom" === side
            },
            _isHorizontalSide: function(side) {
                side = side || this._positionSide;
                return "left" === side || "right" === side
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "showTitle":
                    case "title":
                    case "titleTemplate":
                        this.callBase(args);
                        this._renderGeometry();
                        break;
                    case "target":
                    case "boundaryOffset":
                    case "arrowPosition":
                    case "arrowOffset":
                        this._renderGeometry();
                        break;
                    case "fullScreen":
                        if (args.value) {
                            this.option("fullScreen", false)
                        }
                        break;
                    default:
                        this.callBase(args)
                }
            },
            show: function(target) {
                if (target) {
                    this.option("target", target)
                }
                return this.callBase()
            }
        });
        registerComponent("dxPopover", Popover);
        module.exports = Popover
    },
    /*!************************************!*\
      !*** ./Scripts/ui/autocomplete.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            DropDownList = __webpack_require__( /*! ./drop_down_editor/ui.drop_down_list */ 204),
            themes = __webpack_require__( /*! ./themes */ 143);
        var AUTOCOMPLETE_CLASS = "dx-autocomplete",
            AUTOCOMPLETE_POPUP_WRAPPER_CLASS = "dx-autocomplete-popup-wrapper";
        var Autocomplete = DropDownList.inherit({
            _supportedKeys: function() {
                var item = this._list ? this._list.option("focusedElement") : null;
                return $.extend(this.callBase(), {
                    upArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (item && !item.prev().length) {
                            this._clearFocusedItem();
                            return false
                        }
                        return true
                    },
                    downArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (item && !item.next().length) {
                            this._clearFocusedItem();
                            return false
                        }
                        return true
                    },
                    enter: function(e) {
                        if (!item) {
                            this.close()
                        }
                        return true
                    }
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    displayExpr: {
                        since: "15.2",
                        alias: "valueExpr"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    minSearchLength: 1,
                    maxItemCount: 10,
                    noDataText: "",
                    showDropButton: false,
                    searchEnabled: true
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        popupPosition: {
                            offset: {
                                h: -16,
                                v: -8
                            }
                        }
                    }
                }])
            },
            _render: function() {
                this.callBase();
                this.element().addClass(AUTOCOMPLETE_CLASS);
                this.setAria("autocomplete", "inline")
            },
            _loadValue: function() {
                return $.Deferred().resolve(this.option("value"))
            },
            _displayGetterExpr: function() {
                return this.option("valueExpr")
            },
            _setSelectedItem: function(item) {
                this.callBase(item);
                this.option("displayValue", this.option("value"))
            },
            _popupConfig: function() {
                return $.extend(this.callBase(), {
                    closeOnOutsideClick: $.proxy(function(e) {
                        return !$(e.target).closest(this.element()).length
                    }, this)
                })
            },
            _renderDimensions: function() {
                this.callBase();
                this._setPopupOption("width")
            },
            _popupWrapperClass: function() {
                return this.callBase() + " " + AUTOCOMPLETE_POPUP_WRAPPER_CLASS
            },
            _listConfig: function() {
                return $.extend(this.callBase(), {
                    pageLoadMode: "none",
                    indicateLoading: false
                })
            },
            _listItemClickHandler: function(e) {
                var value = this._displayGetter(e.itemData);
                this.option("value", value);
                this.close()
            },
            _setListDataSource: function() {
                if (!this._list) {
                    return
                }
                this._list.option("selectedItems", []);
                this.callBase()
            },
            _refreshSelected: $.noop,
            _searchCanceled: function() {
                this.callBase();
                this.close()
            },
            _dataSourceOptions: function() {
                return {
                    paginate: true
                }
            },
            _searchDataSource: function() {
                this._dataSource.pageSize(this.option("maxItemCount"));
                this.callBase();
                this._clearFocusedItem()
            },
            _clearFocusedItem: function() {
                if (this._list) {
                    this._list.option("focusedElement", null);
                    this._list.option("selectedIndex", -1)
                }
            },
            _renderValueEventName: function() {
                return "input keyup"
            },
            _searchHandler: function(e) {
                if (this._isControlKey(e.which || e.keyCode)) {
                    return
                }
                this.callBase(e)
            },
            _optionChanged: function(args) {
                if ("maxItemCount" === args.name) {
                    this._searchDataSource()
                } else {
                    this.callBase(args)
                }
            }
        });
        registerComponent("dxAutocomplete", Autocomplete);
        module.exports = Autocomplete
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/drop_down_editor/ui.drop_down_list.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            DropDownEditor = __webpack_require__( /*! ./ui.drop_down_editor */ 205),
            List = __webpack_require__( /*! ../list */ 213),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            DataExpressionMixin = __webpack_require__( /*! ../editor/ui.data_expression */ 244),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            themes = __webpack_require__( /*! ../themes */ 143);
        var LIST_ITEM_SELECTOR = ".dx-list-item",
            LIST_ITEM_DATA_KEY = "dxListItemData",
            DROPDOWNLIST_POPUP_WRAPPER_CLASS = "dx-dropdownlist-popup-wrapper",
            SKIP_GESTURE_EVENT_CLASS = "dx-skip-gesture-event",
            SEARCH_MODES = ["startswith", "contains", "endwith", "notcontains"];
        var DropDownList = DropDownEditor.inherit({
            _supportedKeys: function() {
                var parent = this.callBase();
                return $.extend({}, parent, {
                    tab: function(e) {
                        if (this.option("opened") && "instantly" === this.option("applyValueMode")) {
                            var $focusedItem = this._list.option("focusedElement");
                            $focusedItem && this._setSelectedElement($focusedItem)
                        } else {
                            this._focusTarget().focusout()
                        }
                        parent.tab.apply(this, arguments)
                    },
                    space: $.noop,
                    home: $.noop,
                    end: $.noop
                })
            },
            _setSelectedElement: function($element) {
                this._list.selectItem($element);
                var selectedItems = this._list.option("selectedItems");
                var value = this._valueGetter(selectedItems[selectedItems.length - 1]);
                this._setValue(value)
            },
            _setValue: function(value) {
                this.option("value", value)
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    pagingEnabled: {
                        since: "15.1",
                        message: "Use the 'dataSource.paginate' option instead"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), $.extend(DataExpressionMixin._dataExpressionDefaultOptions(), {
                    displayValue: void 0,
                    searchEnabled: false,
                    searchMode: "contains",
                    searchTimeout: 500,
                    minSearchLength: 0,
                    searchExpr: null,
                    valueChangeEvent: "input change keyup",
                    selectedItem: null,
                    pagingEnabled: void 0,
                    noDataText: messageLocalization.format("dxCollectionWidget-noDataText"),
                    onSelectionChanged: null,
                    onItemClick: $.noop,
                    showDataBeforeSearch: false,
                    popupPosition: {
                        my: "left top",
                        at: "left bottom",
                        offset: {
                            h: 0,
                            v: 0
                        },
                        collision: "flip"
                    },
                    popupWidthExtension: 0
                }))
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "win" === device.platform && device.version && 8 === device.version[0]
                    },
                    options: {
                        popupPosition: {
                            offset: {
                                v: -6
                            }
                        }
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        popupWidthExtension: 32
                    }
                }, {
                    device: {
                        platform: "ios"
                    },
                    options: {
                        popupPosition: {
                            offset: {
                                v: -1
                            }
                        }
                    }
                }, {
                    device: {
                        platform: "generic"
                    },
                    options: {
                        buttonsLocation: "bottom center"
                    }
                }])
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    value: true,
                    selectedItem: true,
                    displayValue: true
                })
            },
            _init: function() {
                this.callBase();
                this._initDataExpressions();
                this._initActions();
                this._setListDataSource();
                this._validateSearchMode();
                this._clearSelectedItem()
            },
            _initActions: function() {
                this._initContentReadyAction();
                this._initSelectionChangedAction();
                this._initItemClickAction()
            },
            _initContentReadyAction: function() {
                this._contentReadyAction = this._createActionByOption("onContentReady", {
                    excludeValidators: ["disabled", "readOnly"]
                })
            },
            _initSelectionChangedAction: function() {
                this._selectionChangedAction = this._createActionByOption("onSelectionChanged", {
                    excludeValidators: ["disabled", "readOnly"]
                })
            },
            _initItemClickAction: function() {
                this._itemClickAction = this._createActionByOption("onItemClick")
            },
            _renderField: function() {
                this.callBase();
                this._input().on("input", $.proxy(this._setFocusPolicy, this))
            },
            _preventFocusOnPopup: function(e) {
                if (this._list && this._list.initialOption("focusStateEnabled")) {
                    e.preventDefault()
                }
            },
            _createPopup: function() {
                this.callBase();
                this._popup._wrapper().addClass(this._popupWrapperClass());
                this._popup.content().off("mousedown").on("mousedown", $.proxy(this._preventFocusOnPopup, this))
            },
            _popupWrapperClass: function() {
                return DROPDOWNLIST_POPUP_WRAPPER_CLASS
            },
            _renderInputValue: function() {
                var callBase = $.proxy(this.callBase, this),
                    value = this._getCurrentValue();
                return this._loadItem(value).always($.proxy(function(item) {
                    this._setSelectedItem(item);
                    callBase(value)
                }, this))
            },
            _loadItem: function(value) {
                var selectedItem = $.grep(this.option("items") || [], $.proxy(function(item) {
                    return this._isValueEquals(this._valueGetter(item), value)
                }, this))[0];
                return void 0 !== selectedItem ? $.Deferred().resolve(selectedItem).promise() : this._loadValue(value)
            },
            _setSelectedItem: function(item) {
                var displayValue = this._displayValue(item);
                this.option("selectedItem", commonUtils.ensureDefined(item, null));
                this.option("displayValue", displayValue)
            },
            _displayValue: function(item) {
                return this._displayGetter(item)
            },
            _refreshSelected: function() {
                this._listItemElements().each($.proxy(function(_, itemElement) {
                    var $itemElement = $(itemElement);
                    var itemValue = this._valueGetter($itemElement.data(LIST_ITEM_DATA_KEY));
                    var isItemSelected = this._isSelectedValue(itemValue);
                    if (isItemSelected) {
                        this._list.selectItem($itemElement)
                    } else {
                        this._list.unselectItem($itemElement)
                    }
                }, this))
            },
            _popupShownHandler: function() {
                this.callBase();
                this._setFocusPolicy()
            },
            _setFocusPolicy: function() {
                if (!this.option("focusStateEnabled") || !this._list) {
                    return
                }
                this._list.option("focusedElement", null)
            },
            _isSelectedValue: function(value) {
                return this._isValueEquals(value, this.option("value"))
            },
            _validateSearchMode: function() {
                var searchMode = this.option("searchMode"),
                    normalizedSearchMode = searchMode.toLowerCase();
                if ($.inArray(normalizedSearchMode, SEARCH_MODES) < 0) {
                    throw errors.Error("E1019", searchMode)
                }
            },
            _clearSelectedItem: function() {
                this.option("selectedItem", null)
            },
            _processDataSourceChanging: function() {
                this._setListDataSource();
                this._renderInputValue().fail($.proxy(function() {
                    if (this._isCustomValueAllowed()) {
                        return
                    }
                    this._clearSelectedItem()
                }, this))
            },
            _isCustomValueAllowed: function() {
                return this.option("displayCustomValue")
            },
            reset: function() {
                this.callBase();
                this._clearFilter();
                this._clearSelectedItem()
            },
            _listItemElements: function() {
                return this._$list ? this._$list.find(LIST_ITEM_SELECTOR) : $()
            },
            _popupConfig: function() {
                var that = this;
                return $.extend(this.callBase(), {
                    width: this.option("width"),
                    onShowing: function() {
                        that.element().addClass(SKIP_GESTURE_EVENT_CLASS)
                    },
                    onHidden: function() {
                        that.element().removeClass(SKIP_GESTURE_EVENT_CLASS)
                    },
                    height: "auto",
                    maxHeight: $.proxy(this._getMaxHeight, this)
                })
            },
            _renderPopupContent: function() {
                this._renderList()
            },
            _attachChildKeyboardEvents: function() {
                this._childKeyboardProcessor = this._keyboardProcessor.attachChildProcessor();
                this._setListOption("_keyboardProcessor", this._childKeyboardProcessor)
            },
            _fireContentReadyAction: $.noop,
            _setAriaTargetForList: function() {
                this._list._getAriaTarget = $.proxy(this._getAriaTarget, this);
                this._list.setAria("role", "combobox")
            },
            _renderList: function() {
                this._listId = (new Guid)._value;
                var $list = this._$list = $("<div>", {
                    id: this._listId
                }).appendTo(this._popup.content());
                this._list = this._createComponent($list, List, this._listConfig());
                this._refreshList();
                this._setAriaTargetForList()
            },
            _renderOpenedState: function() {
                this.callBase();
                var opened = this.option("opened") || void 0;
                this.setAria({
                    activedescendant: opened && this._list.getFocusedItemId(),
                    owns: opened && this._listId
                })
            },
            _refreshList: function() {
                if (this._list && this._shouldRefreshDataSource()) {
                    this._setListDataSource()
                }
            },
            _shouldRefreshDataSource: function() {
                var dataSourceProvided = !!this._list.option("dataSource");
                return dataSourceProvided !== this._needPassDataSourceToList()
            },
            _isDesktopDevice: function() {
                return "desktop" === devices.real().deviceType
            },
            _listConfig: function() {
                return {
                    selectionMode: "single",
                    _templates: this.option("_templates"),
                    templateProvider: this.option("templateProvider"),
                    noDataText: this.option("noDataText"),
                    onContentReady: $.proxy(this._listContentReadyHandler, this),
                    itemTemplate: this._getTemplateByOption("itemTemplate"),
                    indicateLoading: false,
                    tabIndex: -1,
                    onItemClick: $.proxy(this._listItemClickAction, this),
                    dataSource: this._getDataSource(),
                    _keyboardProcessor: this._childKeyboardProcessor,
                    hoverStateEnabled: this._isDesktopDevice() ? this.option("hoverStateEnabled") : false,
                    focusStateEnabled: this._isDesktopDevice() ? this.option("focusStateEnabled") : false,
                    selectedItem: this.option("selectedItem")
                }
            },
            _getDataSource: function() {
                return this._needPassDataSourceToList() ? this._dataSource : null
            },
            _dataSourceOptions: function() {
                this._suppressDeprecatedWarnings();
                var pagingEnabled = this.option("pagingEnabled");
                this._resumeDeprecatedWarnings();
                return {
                    paginate: commonUtils.ensureDefined(pagingEnabled, false)
                }
            },
            _listContentReadyHandler: function() {
                this._list = this._list || this._$list.dxList("instance");
                this.option().items = this._list.option("items");
                this._dimensionChanged();
                this._contentReadyAction()
            },
            _setListOption: function(optionName, value) {
                this._setWidgetOption("_list", arguments)
            },
            _listItemClickAction: function(e) {
                this._listItemClickHandler(e);
                this._itemClickAction(e)
            },
            _listItemClickHandler: $.noop,
            _setListDataSource: function() {
                if (!this._list) {
                    return
                }
                this._setListOption("dataSource", this._getDataSource());
                if (!this._needPassDataSourceToList()) {
                    this._setListOption("items", [])
                }
            },
            _needPassDataSourceToList: function() {
                return this.option("showDataBeforeSearch") || this._isMinSearchLengthExceeded()
            },
            _isMinSearchLengthExceeded: function() {
                return this._searchValue().toString().length >= this.option("minSearchLength")
            },
            _searchValue: function() {
                return this._input().val() || ""
            },
            _getSearchEvent: function() {
                return eventUtils.addNamespace("keyup", this.NAME + "Search")
            },
            _renderEvents: function() {
                this.callBase();
                if (this._shouldRenderSearchEvent()) {
                    this._input().on(this._getSearchEvent(), $.proxy(this._searchHandler, this))
                }
            },
            _shouldRenderSearchEvent: function() {
                return this.option("searchEnabled")
            },
            _refreshEvents: function() {
                this._input().off(this._getSearchEvent());
                this.callBase()
            },
            _searchHandler: function(e) {
                if (!this._isMinSearchLengthExceeded()) {
                    this._searchCanceled();
                    return
                }
                var searchTimeout = this.option("searchTimeout");
                if (searchTimeout) {
                    if (!this._searchTimer) {
                        this._searchTimer = setTimeout($.proxy(this._searchDataSource, this), searchTimeout)
                    }
                } else {
                    this._searchDataSource()
                }
            },
            _searchCanceled: function() {
                this._clearSearchTimer();
                if (this._needPassDataSourceToList()) {
                    this._filterDataSource(null)
                }
                this._refreshList()
            },
            _searchDataSource: function() {
                this._clearSearchTimer();
                this._filterDataSource(this._searchValue())
            },
            _filterDataSource: function(searchValue) {
                var dataSource = this._dataSource;
                dataSource.searchExpr(this.option("searchExpr") || this._displayGetterExpr());
                dataSource.searchOperation(this.option("searchMode"));
                dataSource.searchValue(searchValue);
                return dataSource.load().done($.proxy(this._dataSourceFiltered, this, searchValue))
            },
            _clearFilter: function() {
                var dataSource = this._dataSource;
                dataSource && dataSource.searchValue() && dataSource.searchValue(null)
            },
            _dataSourceFiltered: function() {
                this._refreshList();
                this._refreshPopupVisibility()
            },
            _refreshPopupVisibility: function() {
                if (this.option("readOnly")) {
                    return
                }
                this.option("opened", this._hasItemsToShow());
                if (this.option("opened")) {
                    this._dimensionChanged()
                }
            },
            _hasItemsToShow: function() {
                var resultItems = this._dataSource && this._dataSource.items() || [];
                var resultAmount = resultItems.length;
                var isMinSearchLengthExceeded = this._needPassDataSourceToList();
                return isMinSearchLengthExceeded && resultAmount && this._hasFocusClass()
            },
            _clearSearchTimer: function() {
                clearTimeout(this._searchTimer);
                delete this._searchTimer
            },
            _popupShowingHandler: function() {
                this._dimensionChanged()
            },
            _dimensionChanged: function() {
                this._popup && this._updatePopupDimensions()
            },
            _updatePopupDimensions: function() {
                this._updatePopupWidth();
                this._updatePopupHeight()
            },
            _updatePopupWidth: function() {
                this._setPopupOption("width", this.element().outerWidth() + this.option("popupWidthExtension"))
            },
            _updatePopupHeight: function() {
                this._popup.repaint();
                this._list && this._list.updateDimensions()
            },
            _getMaxHeight: function() {
                var $element = this.element(),
                    offset = $element.offset(),
                    windowHeight = $(window).height(),
                    maxHeight = Math.max(offset.top, windowHeight - offset.top - $element.outerHeight());
                return Math.min(.5 * windowHeight, maxHeight)
            },
            _clean: function() {
                if (this._list) {
                    delete this._list
                }
                this.callBase()
            },
            _dispose: function() {
                this._clearSearchTimer();
                this.callBase()
            },
            _setCollectionWidgetOption: function() {
                this._setListOption.apply(this, arguments)
            },
            _optionChanged: function(args) {
                this._dataExpressionOptionChanged(args);
                switch (args.name) {
                    case "hoverStateEnabled":
                    case "focusStateEnabled":
                        this._isDesktopDevice() && this._setListOption(args.name, args.value);
                        this.callBase(args);
                        break;
                    case "items":
                        if (!this.option("dataSource")) {
                            this._processDataSourceChanging()
                        }
                        break;
                    case "dataSource":
                        this._processDataSourceChanging();
                        break;
                    case "valueExpr":
                    case "displayExpr":
                        this._renderValue();
                        break;
                    case "searchMode":
                        this._validateSearchMode();
                        break;
                    case "minSearchLength":
                        this._refreshList();
                        break;
                    case "searchEnabled":
                    case "showDataBeforeSearch":
                    case "searchExpr":
                    case "pagingEnabled":
                        this._invalidate();
                        break;
                    case "onContentReady":
                        this._initContentReadyAction();
                        break;
                    case "onSelectionChanged":
                        this._initSelectionChangedAction();
                        break;
                    case "onItemClick":
                        this._initItemClickAction();
                        break;
                    case "noDataText":
                        this._setListOption("noDataText");
                        break;
                    case "displayValue":
                        this.option("text", args.value);
                        break;
                    case "itemTemplate":
                    case "searchTimeout":
                    case "popupWidthExtension":
                        break;
                    case "selectedItem":
                        this._selectionChangedAction({
                            selectedItem: args.value
                        });
                        break;
                    default:
                        this.callBase(args)
                }
            }
        }).include(DataExpressionMixin);
        registerComponent("dxDropDownList", DropDownList);
        module.exports = DropDownList
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/drop_down_editor/ui.drop_down_editor.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            positionUtils = __webpack_require__( /*! ../../animation/position */ 61),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            Button = __webpack_require__( /*! ../button */ 196),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            TextBox = __webpack_require__( /*! ../text_box */ 206),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            Popup = __webpack_require__( /*! ../popup */ 195);
        var DROP_DOWN_EDITOR_CLASS = "dx-dropdowneditor",
            DROP_DOWN_EDITOR_INPUT_WRAPPER_CLASS = "dx-dropdowneditor-input-wrapper",
            DROP_DOWN_EDITOR_BUTTON_CLASS = "dx-dropdowneditor-button",
            DROP_DOWN_EDITOR_BUTTON_ICON = "dx-dropdowneditor-icon",
            DROP_DOWN_EDITOR_OVERLAY = "dx-dropdowneditor-overlay",
            DROP_DOWN_EDITOR_OVERLAY_FLIPPED = "dx-dropdowneditor-overlay-flipped",
            DROP_DOWN_EDITOR_ACTIVE = "dx-dropdowneditor-active",
            DROP_DOWN_EDITOR_BUTTON_VISIBLE = "dx-dropdowneditor-button-visible",
            DROP_DOWN_EDITOR_FIELD_CLICKABLE = "dx-dropdowneditor-field-clickable";
        var DropDownEditor = TextBox.inherit({
            _supportedKeys: function() {
                return $.extend({}, this.callBase(), {
                    tab: function(e) {
                        if (!this.option("opened")) {
                            return
                        }
                        if ("instantly" === this.option("applyValueMode")) {
                            this.close();
                            return
                        }
                        var $focusableElement = e.shiftKey ? this._getLastPopupElement() : this._getFirstPopupElement();
                        $focusableElement && $focusableElement.focus();
                        e.preventDefault()
                    },
                    escape: function(e) {
                        if (this.option("opened")) {
                            e.preventDefault()
                        }
                        this.close()
                    },
                    upArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (e.altKey) {
                            this.close();
                            return false
                        }
                        return true
                    },
                    downArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (e.altKey) {
                            this._validatedOpening();
                            return false
                        }
                        return true
                    },
                    enter: function(e) {
                        if (this.option("opened")) {
                            e.preventDefault();
                            this._valueChangeEventHandler(e)
                        }
                        return true
                    }
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    fieldEditEnabled: {
                        since: "16.1",
                        alias: "acceptCustomValue"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: null,
                    onOpened: null,
                    onClosed: null,
                    opened: false,
                    acceptCustomValue: true,
                    applyValueMode: "instantly",
                    deferRendering: true,
                    activeStateEnabled: true,
                    fieldTemplate: null,
                    contentTemplate: null,
                    openOnFieldClick: false,
                    showDropButton: true,
                    popupPosition: this._getDefaultPopupPosition(),
                    onPopupInitialized: null,
                    applyButtonText: messageLocalization.format("OK"),
                    cancelButtonText: messageLocalization.format("Cancel"),
                    buttonsLocation: "default",
                    showPopupTitle: false
                })
            },
            _getDefaultPopupPosition: function() {
                var position = commonUtils.getDefaultAlignment(this.option("rtlEnabled"));
                return {
                    offset: {
                        h: 0,
                        v: -1
                    },
                    my: position + " top",
                    at: position + " bottom",
                    collision: "flip flip"
                }
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        var isGeneric = "generic" === device.platform,
                            isWin10 = "win" === device.platform && device.version && 10 === device.version[0];
                        return isGeneric || isWin10
                    },
                    options: {
                        popupPosition: {
                            offset: {
                                v: 0
                            }
                        }
                    }
                }])
            },
            _inputWrapper: function() {
                return this.element().find("." + DROP_DOWN_EDITOR_INPUT_WRAPPER_CLASS)
            },
            _init: function() {
                this.callBase();
                this._initVisibilityActions();
                this._initPopupInitializedAction()
            },
            _initVisibilityActions: function() {
                this._openAction = this._createActionByOption("onOpened", {
                    excludeValidators: ["disabled", "readOnly"]
                });
                this._closeAction = this._createActionByOption("onClosed", {
                    excludeValidators: ["disabled", "readOnly"]
                })
            },
            _initPopupInitializedAction: function() {
                this._popupInitializedAction = this._createActionByOption("onPopupInitialized", {
                    excludeValidators: ["disabled", "readOnly", "designMode"]
                })
            },
            _render: function() {
                this.callBase();
                this._renderOpenHandler();
                this.element().addClass(DROP_DOWN_EDITOR_CLASS);
                this._renderOpenedState();
                this.setAria("role", "combobox")
            },
            _renderContentImpl: function() {
                if (!this.option("deferRendering")) {
                    this._createPopup()
                }
            },
            _renderInput: function() {
                this.callBase();
                this.element().wrapInner($("<div>").addClass(DROP_DOWN_EDITOR_INPUT_WRAPPER_CLASS));
                this._$container = this.element().children().eq(0);
                this.setAria({
                    haspopup: "true",
                    autocomplete: "list"
                })
            },
            _readOnlyPropValue: function() {
                return !this.option("acceptCustomValue") || this.callBase()
            },
            _cleanFocusState: function() {
                this.callBase();
                if (this.option("fieldTemplate")) {
                    this._input().off("focusin focusout beforeactivate")
                }
            },
            _renderField: function() {
                var fieldTemplate = this._getTemplateByOption("fieldTemplate");
                if (!(fieldTemplate && this.option("fieldTemplate"))) {
                    return
                }
                this._renderTemplatedField(fieldTemplate, this._fieldRenderData())
            },
            _renderTemplatedField: function(fieldTemplate, data) {
                var isFocused = this._input().is(":focus");
                this._resetFocus(isFocused);
                var $container = this._$container;
                $container.empty();
                this._$dropButton = null;
                this._$clearButton = null;
                fieldTemplate.render({
                    model: data,
                    container: $container
                });
                if (!this._input().length) {
                    throw errors.Error("E1010")
                }
                this._refreshEvents();
                this._refreshValueChangeEvent();
                isFocused && this._input().focus();
                this._renderFocusState()
            },
            _resetFocus: function(isFocused) {
                this._cleanFocusState();
                isFocused && this._input().focusout()
            },
            _fieldRenderData: function() {
                return this.option("value")
            },
            _renderInputAddons: function() {
                this._renderField();
                this.callBase();
                this._renderDropButton()
            },
            _renderDropButton: function() {
                var dropButtonVisible = this.option("showDropButton");
                this.element().toggleClass(DROP_DOWN_EDITOR_BUTTON_VISIBLE, dropButtonVisible);
                if (!dropButtonVisible) {
                    this._$dropButton && this._$dropButton.remove();
                    this._$dropButton = null;
                    return
                }
                if (!this._$dropButton) {
                    this._$dropButton = this._createDropButton().addClass(DROP_DOWN_EDITOR_BUTTON_CLASS)
                }
                this._$dropButton.prependTo(this._buttonsContainer())
            },
            _createDropButton: function() {
                var $button = $("<div>");
                this._createComponent($button, Button, {
                    focusStateEnabled: false,
                    disabled: this.option("readOnly"),
                    _templates: {},
                    useInkRipple: false
                });
                var $buttonIcon = $("<div>").addClass(DROP_DOWN_EDITOR_BUTTON_ICON);
                $button.append($buttonIcon).removeClass("dx-button").on("mousedown", function(e) {
                    e.preventDefault()
                });
                $button.find(".dx-button-content").remove();
                return $button
            },
            _renderOpenHandler: function() {
                var $inputWrapper = this.element().find("." + DROP_DOWN_EDITOR_INPUT_WRAPPER_CLASS);
                var eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                $inputWrapper.off(eventName);
                var openOnFieldClick = this.option("openOnFieldClick");
                this.element().toggleClass(DROP_DOWN_EDITOR_FIELD_CLICKABLE, openOnFieldClick);
                if (openOnFieldClick) {
                    $inputWrapper.on(eventName, $.proxy(this._openHandler, this));
                    return
                }
                if (this.option("showDropButton")) {
                    this._$dropButton.dxButton("option", "onClick", $.proxy(this._openHandler, this))
                }
            },
            _openHandler: function() {
                this._toggleOpenState()
            },
            _keyboardEventBindingTarget: function() {
                return this._input()
            },
            _toggleOpenState: function(isVisible) {
                if (this.option("disabled")) {
                    return
                }
                if (this._needFocusOnButtonClick()) {
                    this._input().focus()
                }
                if (!this.option("readOnly")) {
                    isVisible = arguments.length ? isVisible : !this.option("opened");
                    this.option("opened", isVisible)
                }
            },
            _needFocusOnButtonClick: function() {
                return "desktop" === devices.real().deviceType
            },
            _renderOpenedState: function() {
                var opened = this.option("opened");
                if (opened) {
                    this._createPopup()
                }
                this.element().toggleClass(DROP_DOWN_EDITOR_ACTIVE, opened);
                this._setPopupOption("visible", opened);
                this.setAria({
                    expanded: opened,
                    owns: (opened || void 0) && this._popupContentId
                })
            },
            _createPopup: function() {
                if (this._$popup) {
                    return
                }
                this._$popup = $("<div>").addClass(DROP_DOWN_EDITOR_OVERLAY).addClass(this.option("customOverlayCssClass")).appendTo(this.element());
                this._renderPopup();
                this._renderPopupContent()
            },
            _renderPopup: function() {
                this._popup = this._createComponent(this._$popup, Popup, this._popupConfig());
                this._popup.on({
                    showing: $.proxy(this._popupShowingHandler, this),
                    shown: $.proxy(this._popupShownHandler, this),
                    hiding: $.proxy(this._popupHidingHandler, this),
                    hidden: $.proxy(this._popupHiddenHandler, this)
                });
                this._popup.option("onContentReady", $.proxy(this._contentReadyHandler, this));
                this._contentReadyHandler();
                this._popupContentId = new Guid;
                this.setAria("id", this._popupContentId, this._popup.content())
            },
            _contentReadyHandler: $.noop,
            _popupConfig: function() {
                return {
                    onInitialized: this._popupInitializedHandler(),
                    position: $.extend(this.option("popupPosition"), {
                        of: this.element()
                    }),
                    showTitle: this.option("showPopupTitle"),
                    width: "auto",
                    height: "auto",
                    shading: false,
                    closeOnTargetScroll: true,
                    closeOnOutsideClick: $.proxy(this._closeOutsideDropDownHandler, this),
                    animation: {
                        show: {
                            type: "fade",
                            duration: 0,
                            from: 0,
                            to: 1
                        },
                        hide: {
                            type: "fade",
                            duration: 400,
                            from: 1,
                            to: 0
                        }
                    },
                    deferRendering: false,
                    focusStateEnabled: false,
                    showCloseButton: false,
                    toolbarItems: this._getPopupToolbarItems(),
                    onPositioned: $.proxy(this._popupPositionedHandler, this),
                    fullScreen: false
                }
            },
            _popupInitializedHandler: function() {
                if (!this.option("onPopupInitialized")) {
                    return
                }
                return $.proxy(function(e) {
                    this._popupInitializedAction({
                        popup: e.component
                    })
                }, this)
            },
            _popupPositionedHandler: function(e) {
                this._popup.overlayContent().toggleClass(DROP_DOWN_EDITOR_OVERLAY_FLIPPED, e.position.v.flip)
            },
            _popupShowingHandler: $.noop,
            _popupHidingHandler: function() {
                this.option("opened", false)
            },
            _popupShownHandler: function() {
                this._openAction();
                if (this._$validationMessage) {
                    this._$validationMessage.dxOverlay("option", "position", this._getValidationMessagePosition())
                }
            },
            _popupHiddenHandler: function() {
                this._closeAction();
                if (this._$validationMessage) {
                    this._$validationMessage.dxOverlay("option", "position", this._getValidationMessagePosition())
                }
            },
            _getValidationMessagePosition: function() {
                var positionRequest = "below";
                if (this._popup && this._popup.option("visible")) {
                    var myTop = positionUtils.setup(this.element()).top,
                        popupTop = positionUtils.setup(this._popup.content()).top;
                    positionRequest = myTop + this.option("popupPosition").offset.v > popupTop ? "below" : "above"
                }
                return this.callBase(positionRequest)
            },
            _renderPopupContent: function() {
                var contentTemplate = this._getTemplateByOption("contentTemplate");
                if (!(contentTemplate && this.option("contentTemplate"))) {
                    return
                }
                var $popupContent = this._popup.content();
                $popupContent.empty();
                contentTemplate.render({
                    container: $popupContent
                })
            },
            _closeOutsideDropDownHandler: function(e) {
                var $target = $(e.target);
                var isInputClicked = !!$target.closest(this.element()).length;
                var isDropButtonClicked = !!$target.closest(this._$dropButton).length;
                var isOutsideClick = !isInputClicked && !isDropButtonClicked;
                return isOutsideClick
            },
            _clean: function() {
                delete this._$dropButton;
                if (this._$popup) {
                    this._$popup.remove();
                    delete this._$popup;
                    delete this._popup
                }
                this.callBase()
            },
            _setPopupOption: function(optionName, value) {
                this._setWidgetOption("_popup", arguments)
            },
            _validatedOpening: function() {
                if (!this.option("readOnly")) {
                    this._toggleOpenState(true)
                }
            },
            _getPopupToolbarItems: function() {
                return "useButtons" === this.option("applyValueMode") ? this._popupToolbarItemsConfig() : []
            },
            _getFirstPopupElement: function() {
                return this._popup._wrapper().find(".dx-popup-done.dx-button")
            },
            _getLastPopupElement: function() {
                return this._popup._wrapper().find(".dx-popup-cancel.dx-button")
            },
            _popupElementTabHandler: function(e) {
                var $element = $(e.currentTarget);
                if (e.shiftKey && $element.is(this._getFirstPopupElement()) || !e.shiftKey && $element.is(this._getLastPopupElement())) {
                    this._input().focus();
                    e.preventDefault()
                }
            },
            _popupElementEscHandler: function(e) {
                this._input().focus();
                this.close()
            },
            _popupButtonInitializedHandler: function(e) {
                e.component.registerKeyHandler("tab", $.proxy(this._popupElementTabHandler, this));
                e.component.registerKeyHandler("escape", $.proxy(this._popupElementEscHandler, this))
            },
            _popupToolbarItemsConfig: function() {
                var buttonsConfig = [{
                    shortcut: "done",
                    options: {
                        onClick: $.proxy(this._applyButtonHandler, this),
                        text: this.option("applyButtonText"),
                        onInitialized: $.proxy(this._popupButtonInitializedHandler, this)
                    }
                }, {
                    shortcut: "cancel",
                    options: {
                        onClick: $.proxy(this._cancelButtonHandler, this),
                        text: this.option("cancelButtonText"),
                        onInitialized: $.proxy(this._popupButtonInitializedHandler, this)
                    }
                }];
                return this._applyButtonsLocation(buttonsConfig)
            },
            _applyButtonsLocation: function(buttonsConfig) {
                var buttonsLocation = this.option("buttonsLocation"),
                    resultConfig = buttonsConfig;
                if ("default" !== buttonsLocation) {
                    var position = commonUtils.splitPair(buttonsLocation);
                    $.each(resultConfig, function(_, element) {
                        $.extend(element, {
                            toolbar: position[0],
                            location: position[1]
                        })
                    })
                }
                return resultConfig
            },
            _applyButtonHandler: function() {
                this.close();
                this.option("focusStateEnabled") && this.focus()
            },
            _cancelButtonHandler: function() {
                this.close();
                this.option("focusStateEnabled") && this.focus()
            },
            _toggleReadOnlyState: function() {
                this.callBase();
                this._$dropButton && this._$dropButton.dxButton("option", "disabled", this.option("readOnly"))
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "opened":
                        this._renderOpenedState();
                        break;
                    case "onOpened":
                    case "onClosed":
                        this._initVisibilityActions();
                        break;
                    case "onPopupInitialized":
                        this._initPopupInitializedAction();
                        break;
                    case "fieldTemplate":
                        this._renderInputAddons();
                        break;
                    case "showDropButton":
                    case "contentTemplate":
                    case "acceptCustomValue":
                    case "openOnFieldClick":
                        this._invalidate();
                        break;
                    case "popupPosition":
                    case "deferRendering":
                        break;
                    case "applyValueMode":
                    case "applyButtonText":
                    case "cancelButtonText":
                    case "buttonsLocation":
                        this._setPopupOption("toolbarItems", this._getPopupToolbarItems());
                        break;
                    case "showPopupTitle":
                        this._setPopupOption("showTitle", args.value);
                        break;
                    default:
                        this.callBase(args)
                }
            },
            open: function() {
                this.option("opened", true)
            },
            close: function() {
                this.option("opened", false)
            },
            reset: function() {
                this.option("value", null)
            },
            field: function() {
                return this._input()
            },
            content: function() {
                return this._popup ? this._popup.content() : null
            }
        });
        registerComponent("dxDropDownEditor", DropDownEditor);
        module.exports = DropDownEditor
    },
    /*!********************************!*\
      !*** ./Scripts/ui/text_box.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./text_box/text_box */ 207)
    },
    /*!*****************************************!*\
      !*** ./Scripts/ui/text_box/text_box.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            TextEditor = __webpack_require__( /*! ./ui.text_editor */ 208),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        var ua = window.navigator.userAgent,
            ignoreCode = [8, 9, 13, 33, 34, 35, 36, 37, 38, 39, 40, 46],
            TEXTBOX_CLASS = "dx-textbox",
            SEARCHBOX_CLASS = "dx-searchbox",
            ICON_CLASS = "dx-icon",
            SEARCH_ICON_CLASS = "dx-icon-search";
        var TextBox = TextEditor.inherit({
            ctor: function(element, options) {
                if (options) {
                    this._showClearButton = options.showClearButton
                }
                this.callBase.apply(this, arguments)
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    mode: "text",
                    maxLength: null
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass(TEXTBOX_CLASS);
                this.setAria("role", "textbox");
                this._renderMaxLengthHandlers()
            },
            _renderInputType: function() {
                this.callBase();
                this._renderSearchMode()
            },
            _renderMaxLengthHandlers: function() {
                if (this._isAndroid()) {
                    this._input().on(eventUtils.addNamespace("keydown", this.NAME), $.proxy(this._onKeyDownAndroidHandler, this)).on(eventUtils.addNamespace("change", this.NAME), $.proxy(this._onChangeAndroidHandler, this))
                }
            },
            _renderProps: function() {
                this.callBase();
                this._toggleMaxLengthProp()
            },
            _toggleMaxLengthProp: function() {
                if (this._isAndroid()) {
                    return
                }
                var maxLength = this.option("maxLength");
                if (maxLength > 0) {
                    this._input().attr("maxLength", maxLength)
                } else {
                    this._input().removeAttr("maxLength")
                }
            },
            _renderSearchMode: function() {
                var $element = this._$element;
                if ("search" === this.option("mode")) {
                    $element.addClass(SEARCHBOX_CLASS);
                    this._renderSearchIcon();
                    if (void 0 === this._showClearButton) {
                        this._showClearButton = this.option("showClearButton");
                        this.option("showClearButton", true)
                    }
                } else {
                    $element.removeClass(SEARCHBOX_CLASS);
                    this._$searchIcon && this._$searchIcon.remove();
                    this.option("showClearButton", void 0 === this._showClearButton ? this.option("showClearButton") : this._showClearButton);
                    delete this._showClearButton
                }
            },
            _renderSearchIcon: function() {
                var $searchIcon = $("<div>").addClass(ICON_CLASS).addClass(SEARCH_ICON_CLASS);
                $searchIcon.prependTo(this._input().parent());
                this._$searchIcon = $searchIcon
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "maxLength":
                        this._toggleMaxLengthProp();
                        this._renderMaxLengthHandlers();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _onKeyDownAndroidHandler: function(e) {
                var maxLength = this.option("maxLength");
                if (maxLength) {
                    var $input = $(e.target),
                        code = e.keyCode;
                    this._cutOffExtraChar($input);
                    return $input.val().length < maxLength || $.inArray(code, ignoreCode) !== -1 || "" !== window.getSelection().toString()
                } else {
                    return true
                }
            },
            _onChangeAndroidHandler: function(e) {
                var $input = $(e.target);
                if (this.option("maxLength")) {
                    this._cutOffExtraChar($input)
                }
            },
            _cutOffExtraChar: function($input) {
                var maxLength = this.option("maxLength"),
                    textInput = $input.val();
                if (textInput.length > maxLength) {
                    $input.val(textInput.substr(0, maxLength))
                }
            },
            _isAndroid: function() {
                var realDevice = devices.real();
                var version = realDevice.version.join(".");
                return "android" === realDevice.platform && version && /^(2\.|4\.1)/.test(version) && !/chrome/i.test(ua)
            }
        });
        TextBox.__internals = {
            uaAccessor: function(value) {
                if (!arguments.length) {
                    return DevExpress.ui
                }
                ua = value
            },
            SEARCHBOX_CLASS: SEARCHBOX_CLASS,
            SEARCH_ICON_CLASS: SEARCH_ICON_CLASS
        };
        registerComponent("dxTextBox", TextBox);
        module.exports = TextBox
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/text_box/ui.text_editor.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            TextEditorMask = __webpack_require__( /*! ./ui.text_editor.mask */ 209);
        registerComponent("dxTextEditor", TextEditorMask);
        module.exports = TextEditorMask
    },
    /*!****************************************************!*\
      !*** ./Scripts/ui/text_box/ui.text_editor.mask.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            caret = __webpack_require__( /*! ./utils.caret */ 210),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            TextEditorBase = __webpack_require__( /*! ./ui.text_editor.base */ 211),
            MaskRules = __webpack_require__( /*! ./ui.text_editor.mask.rule */ 212),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        var stubCaret = function() {
            return {}
        };
        var EMPTY_CHAR = " ";
        var EMPTY_CHAR_CODE = 32;
        var ESCAPED_CHAR = "\\";
        var TEXTEDITOR_MASKED_CLASS = "dx-texteditor-masked";
        var MASK_EVENT_NAMESPACE = "dxMask";
        var FORWARD_DIRECTION = "forward";
        var BACKWARD_DIRECTION = "backward";
        var buildInMaskRules = {
            0: /[0-9]/,
            9: /[0-9\s]/,
            "#": /[-+0-9\s]/,
            L: function(char) {
                return isLiteralChar(char)
            },
            l: function(char) {
                return isLiteralChar(char) || isSpaceChar(char)
            },
            C: /\S/,
            c: /./,
            A: function(char) {
                return isLiteralChar(char) || isNumericChar(char)
            },
            a: function(char) {
                return isLiteralChar(char) || isNumericChar(char) || isSpaceChar(char)
            }
        };
        var isNumericChar = function(char) {
            return /[0-9]/.test(char)
        };
        var isLiteralChar = function(char) {
            var code = char.charCodeAt();
            return 64 < code && code < 91 || 96 < code && code < 123 || code > 127
        };
        var isSpaceChar = function(char) {
            return " " === char
        };
        var TextEditorMask = TextEditorBase.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    mask: "",
                    maskChar: "_",
                    maskRules: {},
                    maskInvalidMessage: messageLocalization.format("validation-mask"),
                    useMaskedValue: false
                })
            },
            _supportedKeys: function() {
                var that = this;
                var keyHandlerMap = {
                    backspace: that._maskBackspaceHandler,
                    del: that._maskDelHandler,
                    enter: that._changeHandler
                };
                var result = that.callBase();
                $.each(keyHandlerMap, function(key, callback) {
                    var parentHandler = result[key];
                    result[key] = function(e) {
                        that.option("mask") && callback.call(that, e);
                        parentHandler && parentHandler(e)
                    }
                });
                return result
            },
            _render: function() {
                this.callBase();
                this._renderMask()
            },
            _renderMask: function() {
                this.element().removeClass(TEXTEDITOR_MASKED_CLASS);
                this._maskRulesChain = null;
                this._detachMaskEventHandlers();
                if (!this.option("mask")) {
                    return
                }
                this.element().addClass(TEXTEDITOR_MASKED_CLASS);
                this._attachMaskEventHandlers();
                this._parseMask();
                this._renderMaskedValue();
                this._changedValue = this._input().val()
            },
            _attachMaskEventHandlers: function() {
                this._input().on(eventUtils.addNamespace("focus", MASK_EVENT_NAMESPACE), $.proxy(this._maskFocusHandler, this)).on(eventUtils.addNamespace("keydown", MASK_EVENT_NAMESPACE), $.proxy(this._maskKeyDownHandler, this)).on(eventUtils.addNamespace("keypress", MASK_EVENT_NAMESPACE), $.proxy(this._maskKeyPressHandler, this)).on(eventUtils.addNamespace("input", MASK_EVENT_NAMESPACE), $.proxy(this._maskInputHandler, this)).on(eventUtils.addNamespace("paste", MASK_EVENT_NAMESPACE), $.proxy(this._maskPasteHandler, this)).on(eventUtils.addNamespace("cut", MASK_EVENT_NAMESPACE), $.proxy(this._maskCutHandler, this)).on(eventUtils.addNamespace("drop", MASK_EVENT_NAMESPACE), $.proxy(this._maskDragHandler, this));
                this._attachChangeEventHandlers()
            },
            _detachMaskEventHandlers: function() {
                this._input().off("." + MASK_EVENT_NAMESPACE)
            },
            _attachChangeEventHandlers: function() {
                if ($.inArray("change", this.option("valueChangeEvent").split(" ")) === -1) {
                    return
                }
                this._input().on(eventUtils.addNamespace("blur", MASK_EVENT_NAMESPACE), $.proxy(function(e) {
                    this._suppressCaretChanging(this._changeHandler, [e]);
                    this._changeHandler(e)
                }, this))
            },
            _suppressCaretChanging: function(callback, args) {
                var originalCaret = caret;
                caret = stubCaret;
                try {
                    callback.apply(this, args)
                } finally {
                    caret = originalCaret
                }
            },
            _changeHandler: function(e) {
                var $input = this._input(),
                    inputValue = $input.val();
                if (inputValue === this._changedValue) {
                    return
                }
                this._changedValue = inputValue;
                var changeEvent = eventUtils.createEvent(e, {
                    type: "change"
                });
                $input.trigger(changeEvent)
            },
            _parseMask: function() {
                this._maskRules = $.extend({}, buildInMaskRules, this.option("maskRules"));
                this._maskRulesChain = this._parseMaskRule(0)
            },
            _parseMaskRule: function(index) {
                var mask = this.option("mask");
                if (index >= mask.length) {
                    return new MaskRules.EmptyMaskRule
                }
                var currentMaskChar = mask[index];
                var isEscapedChar = currentMaskChar === ESCAPED_CHAR;
                var result = isEscapedChar ? new MaskRules.StubMaskRule({
                    maskChar: mask[index + 1]
                }) : this._getMaskRule(currentMaskChar);
                result.next(this._parseMaskRule(index + 1 + isEscapedChar));
                return result
            },
            _getMaskRule: function(pattern) {
                var ruleConfig;
                $.each(this._maskRules, function(rulePattern, allowedChars) {
                    if (rulePattern === pattern) {
                        ruleConfig = {
                            pattern: rulePattern,
                            allowedChars: allowedChars
                        };
                        return false
                    }
                });
                return commonUtils.isDefined(ruleConfig) ? new MaskRules.MaskRule($.extend({
                    maskChar: this.option("maskChar")
                }, ruleConfig)) : new MaskRules.StubMaskRule({
                    maskChar: pattern
                })
            },
            _renderMaskedValue: function() {
                if (!this._maskRulesChain) {
                    return
                }
                var value = this.option("value") || "";
                this._maskRulesChain.clear(this._normalizeChainArguments());
                var chainArgs = {
                    length: value.length
                };
                chainArgs[this._isMaskedValueMode() ? "text" : "value"] = value;
                this._handleChain(chainArgs);
                this._displayMask()
            },
            _isMaskedValueMode: function() {
                return this.option("useMaskedValue")
            },
            _displayMask: function(caret) {
                caret = caret || this._caret();
                this._renderValue();
                this._caret(caret)
            },
            _renderValue: function() {
                if (this._maskRulesChain) {
                    this.option("text", this._maskRulesChain.text())
                }
                this.callBase()
            },
            _valueChangeEventHandler: function(e) {
                if (!this._maskRulesChain) {
                    this.callBase.apply(this, arguments);
                    return
                }
                this._saveValueChangeEvent(e);
                var value = this._isMaskedValueMode() ? (this._textValue || "").replace(new RegExp("[" + this.option("maskChar") + "]", "g"), " ").replace(/\s+$/, "") : (this._value || "").replace(/\s+$/, "");
                this.option("value", value)
            },
            _maskFocusHandler: function() {
                this._direction(FORWARD_DIRECTION);
                this._adjustCaret()
            },
            _maskKeyDownHandler: function() {
                this._keyPressHandled = false
            },
            _maskKeyPressHandler: function(e) {
                if (this._keyPressHandled) {
                    return
                }
                this._keyPressHandled = true;
                if (this._isControlKeyFired(e)) {
                    return
                }
                this._maskKeyHandler(e, function() {
                    this._handleKey(e.which);
                    return true
                })
            },
            _maskInputHandler: function(e) {
                if (this._keyPressHandled) {
                    return
                }
                this._keyPressHandled = true;
                var inputValue = this._input().val();
                var caret = this._caret();
                caret.start = caret.end - 1;
                var oldValue = inputValue.substring(0, caret.start) + inputValue.substring(caret.end);
                var char = inputValue[caret.start];
                this._input().val(oldValue);
                this._inputHandlerTimer = setTimeout($.proxy(function() {
                    this._caret({
                        start: caret.start,
                        end: caret.start
                    });
                    this._maskKeyHandler(e, function() {
                        this._handleKey(char.charCodeAt());
                        return true
                    })
                }, this))
            },
            _isControlKeyFired: function(e) {
                return this._isControlKey(e.keyCode) && !e.which || e.metaKey
            },
            _maskBackspaceHandler: function(e) {
                var that = this;
                that._keyPressHandled = true;
                var afterBackspaceHandler = function(needAdjustCaret, callBack) {
                    if (needAdjustCaret) {
                        that._direction(FORWARD_DIRECTION);
                        that._adjustCaret()
                    }
                    var currentCaret = that._caret();
                    clearTimeout(that._backspaceHandlerTimeout);
                    that._backspaceHandlerTimeout = setTimeout(function() {
                        callBack(currentCaret)
                    })
                };
                that._maskKeyHandler(e, function() {
                    if (that._hasSelection()) {
                        afterBackspaceHandler(true, function(currentCaret) {
                            that._displayMask(currentCaret);
                            that._maskRulesChain.reset()
                        });
                        return
                    }
                    if (that._tryMoveCaretBackward()) {
                        afterBackspaceHandler(false, function(currentCaret) {
                            that._caret(currentCaret)
                        });
                        return
                    }
                    that._handleKey(EMPTY_CHAR_CODE, BACKWARD_DIRECTION);
                    afterBackspaceHandler(true, function(currentCaret) {
                        that._displayMask(currentCaret);
                        that._maskRulesChain.reset()
                    })
                })
            },
            _maskDelHandler: function(e) {
                this._keyPressHandled = true;
                this._maskKeyHandler(e, function() {
                    !this._hasSelection() && this._handleKey(EMPTY_CHAR_CODE);
                    return true
                })
            },
            _maskPasteHandler: function(e) {
                this._keyPressHandled = true;
                var caret = this._caret();
                this._maskKeyHandler(e, function() {
                    var pastingText = domUtils.clipboardText(e);
                    var restText = this._maskRulesChain.text().substring(caret.end);
                    var accepted = this._handleChain({
                        text: pastingText,
                        start: caret.start,
                        length: pastingText.length
                    });
                    var newCaret = caret.start + accepted;
                    this._handleChain({
                        text: restText,
                        start: newCaret,
                        length: restText.length
                    });
                    this._caret({
                        start: newCaret,
                        end: newCaret
                    });
                    return true
                })
            },
            _handleChain: function(args) {
                var handledCount = this._maskRulesChain.handle(this._normalizeChainArguments(args));
                this._value = this._maskRulesChain.value();
                this._textValue = this._maskRulesChain.text();
                return handledCount
            },
            _normalizeChainArguments: function(args) {
                args = args || {};
                args.index = 0;
                args.fullText = this._maskRulesChain.text();
                return args
            },
            _maskCutHandler: function(e) {
                var caret = this._caret();
                var selectedText = this._input().val().substring(caret.start, caret.end);
                this._maskKeyHandler(e, function() {
                    domUtils.clipboardText(e, selectedText);
                    return true
                })
            },
            _maskDragHandler: function() {
                this._clearDragTimer();
                this._dragTimer = setTimeout($.proxy(function() {
                    this.option("value", this._convertToValue(this._input().val()))
                }, this))
            },
            _convertToValue: function(text) {
                return text.replace(new RegExp(this.option("maskChar"), "g"), EMPTY_CHAR)
            },
            _maskKeyHandler: function(e, tryHandleKeyCallback) {
                if (this.option("readOnly")) {
                    return
                }
                this._direction(FORWARD_DIRECTION);
                e.preventDefault();
                this._handleSelection();
                if (!tryHandleKeyCallback.call(this)) {
                    return
                }
                this._direction(FORWARD_DIRECTION);
                this._adjustCaret();
                this._displayMask();
                this._maskRulesChain.reset()
            },
            _handleKey: function(keyCode, direction) {
                var char = String.fromCharCode(keyCode);
                this._direction(direction || FORWARD_DIRECTION);
                this._adjustCaret(char);
                this._handleKeyChain(char);
                this._moveCaret()
            },
            _handleSelection: function() {
                if (!this._hasSelection()) {
                    return
                }
                var caret = this._caret();
                var emptyChars = new Array(caret.end - caret.start + 1).join(EMPTY_CHAR);
                this._handleKeyChain(emptyChars)
            },
            _handleKeyChain: function(chars) {
                var caret = this._caret();
                var start = this._isForwardDirection() ? caret.start : caret.start - 1;
                var end = this._isForwardDirection() ? caret.end : caret.end - 1;
                var length = start === end ? 1 : end - start;
                this._handleChain({
                    text: chars,
                    start: start,
                    length: length
                })
            },
            _tryMoveCaretBackward: function() {
                this._direction(BACKWARD_DIRECTION);
                var currentCaret = this._caret().start;
                this._adjustCaret();
                return !currentCaret || currentCaret !== this._caret().start
            },
            _adjustCaret: function(char) {
                var caret = this._maskRulesChain.adjustedCaret(this._caret().start, this._isForwardDirection(), char);
                this._caret({
                    start: caret,
                    end: caret
                })
            },
            _moveCaret: function() {
                var currentCaret = this._caret().start;
                var maskRuleIndex = currentCaret + (this._isForwardDirection() ? 0 : -1);
                var caret = this._maskRulesChain.isAccepted(maskRuleIndex) ? currentCaret + (this._isForwardDirection() ? 1 : -1) : currentCaret;
                this._caret({
                    start: caret,
                    end: caret
                })
            },
            _caret: function(position) {
                if (!arguments.length) {
                    return caret(this._input())
                }
                caret(this._input(), position)
            },
            _hasSelection: function() {
                var caret = this._caret();
                return caret.start !== caret.end
            },
            _direction: function(direction) {
                if (!arguments.length) {
                    return this._typingDirection
                }
                this._typingDirection = direction
            },
            _isForwardDirection: function() {
                return this._direction() === FORWARD_DIRECTION
            },
            _clearDragTimer: function() {
                clearTimeout(this._dragTimer)
            },
            _clean: function() {
                this._clearDragTimer();
                this.callBase()
            },
            _validateMask: function() {
                if (!this._maskRulesChain) {
                    return
                }
                var isValid = this._maskRulesChain.isValid(this._normalizeChainArguments());
                this.option({
                    isValid: isValid,
                    validationError: isValid ? null : {
                        editorSpecific: true,
                        message: this.option("maskInvalidMessage")
                    }
                })
            },
            _dispose: function() {
                clearTimeout(this._inputHandlerTimer);
                clearTimeout(this._backspaceHandlerTimeout);
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "mask":
                    case "maskChar":
                    case "maskRules":
                    case "useMaskedValue":
                        this._renderMask();
                        this._validateMask();
                        break;
                    case "value":
                        this._renderMaskedValue();
                        this._validateMask();
                        this.callBase(args);
                        break;
                    case "maskInvalidMessage":
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        module.exports = TextEditorMask
    },
    /*!********************************************!*\
      !*** ./Scripts/ui/text_box/utils.caret.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18);
        var isIE = browser.msie && parseInt(browser.version) <= 11;
        var getCaret = function(input) {
            if (isObsoleteBrowser(input)) {
                return getCaretForObsoleteBrowser(input)
            }
            return {
                start: input.selectionStart,
                end: input.selectionEnd
            }
        };
        var setCaret = function(input, position) {
            if (isObsoleteBrowser(input)) {
                setCaretForObsoleteBrowser(input, position);
                return
            }
            if (!$.contains(document, input)) {
                return
            }
            input.selectionStart = position.start;
            input.selectionEnd = position.end
        };
        var isObsoleteBrowser = function(input) {
            return !input.setSelectionRange
        };
        var getCaretForObsoleteBrowser = function(input) {
            var range = document.selection.createRange();
            var rangeCopy = range.duplicate();
            range.move("character", -input.value.length);
            range.setEndPoint("EndToStart", rangeCopy);
            return {
                start: range.text.length,
                end: range.text.length + rangeCopy.text.length
            }
        };
        var setCaretForObsoleteBrowser = function(input, position) {
            if (!$.contains(document, input)) {
                return
            }
            var range = input.createTextRange();
            range.collapse(true);
            range.moveStart("character", position.start);
            range.moveEnd("character", position.end - position.start);
            range.select()
        };
        var caret = function(input, position) {
            input = $(input).get(0);
            if (!commonUtils.isDefined(position)) {
                return getCaret(input)
            }
            if (isIE && document.activeElement !== input) {
                return
            }
            setCaret(input, position)
        };
        module.exports = caret
    },
    /*!****************************************************!*\
      !*** ./Scripts/ui/text_box/ui.text_editor.base.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            themes = __webpack_require__( /*! ../themes */ 143),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        var TEXTEDITOR_CLASS = "dx-texteditor",
            TEXTEDITOR_INPUT_CLASS = "dx-texteditor-input",
            TEXTEDITOR_INPUT_SELECTOR = "." + TEXTEDITOR_INPUT_CLASS,
            TEXTEDITOR_CONTAINER_CLASS = "dx-texteditor-container",
            TEXTEDITOR_BUTTONS_CONTAINER_CLASS = "dx-texteditor-buttons-container",
            TEXTEDITOR_PLACEHOLDER_CLASS = "dx-placeholder",
            TEXTEDITOR_SHOW_CLEAR_BUTTON_CLASS = "dx-show-clear-button",
            TEXTEDITOR_ICON_CLASS = "dx-icon",
            TEXTEDITOR_CLEAR_ICON_CLASS = "dx-icon-clear",
            TEXTEDITOR_CLEAR_BUTTON_CLASS = "dx-clear-button-area",
            TEXTEDITOR_EMPTY_INPUT_CLASS = "dx-texteditor-empty";
        var EVENTS_LIST = ["KeyDown", "KeyPress", "KeyUp", "Change", "Cut", "Copy", "Paste", "Input"];
        var CONTROL_KEYS = {
            9: "tab",
            13: "enter",
            16: "shift",
            17: "ctrl",
            18: "alt",
            27: "escape",
            33: "pageUp",
            34: "pageDown",
            35: "end",
            36: "home",
            37: "leftArrow",
            38: "upArrow",
            39: "rightArrow",
            40: "downArrow"
        };
        var TextEditorBase = Editor.inherit({
            _supportedKeys: function() {
                var stop = function(e) {
                    e.stopPropagation()
                };
                return {
                    space: stop,
                    enter: stop,
                    leftArrow: stop,
                    rightArrow: stop
                }
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: "",
                    spellcheck: false,
                    showClearButton: false,
                    valueChangeEvent: "change",
                    placeholder: "",
                    attr: {},
                    onFocusIn: null,
                    onFocusOut: null,
                    onKeyDown: null,
                    onKeyPress: null,
                    onKeyUp: null,
                    onChange: null,
                    onInput: null,
                    onCut: null,
                    onCopy: null,
                    onPaste: null,
                    onEnterKey: null,
                    mode: "text",
                    hoverStateEnabled: true,
                    focusStateEnabled: true,
                    text: void 0,
                    valueFormat: function(value) {
                        return value
                    }
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        var currentTheme = (themes.current() || "").split(".")[0];
                        return "android5" === currentTheme
                    },
                    options: {
                        validationMessageOffset: {
                            v: -8
                        }
                    }
                }])
            },
            _input: function() {
                return this.element().find(TEXTEDITOR_INPUT_SELECTOR).first()
            },
            _inputWrapper: function() {
                return this.element()
            },
            _buttonsContainer: function() {
                return this._inputWrapper().find("." + TEXTEDITOR_BUTTONS_CONTAINER_CLASS)
            },
            _isControlKey: function(keyCode) {
                return !!CONTROL_KEYS[keyCode]
            },
            _render: function() {
                this.element().addClass(TEXTEDITOR_CLASS);
                this._renderInput();
                this._renderInputType();
                this._renderValue();
                this._renderProps();
                this._renderPlaceholder();
                this.callBase();
                this._refreshValueChangeEvent();
                this._renderEvents();
                this._renderEnterKeyAction();
                this._renderEmptinessEvent()
            },
            _renderInput: function() {
                $("<div>").addClass(TEXTEDITOR_CONTAINER_CLASS).append(this._createInput()).append($("<div>").addClass(TEXTEDITOR_BUTTONS_CONTAINER_CLASS)).appendTo(this.element())
            },
            _createInput: function() {
                return $("<input>").addClass(TEXTEDITOR_INPUT_CLASS).attr("autocomplete", "off").attr(this.option("attr"))
            },
            _renderValue: function() {
                this._renderInputValue();
                this._renderInputAddons()
            },
            _renderInputValue: function(value) {
                value = value || this.option("value");
                var text = this.option("text"),
                    displayValue = this.option("displayValue"),
                    valueFormat = this.option("valueFormat");
                if (void 0 !== displayValue && null !== value) {
                    text = valueFormat(displayValue)
                } else {
                    if (!commonUtils.isDefined(text)) {
                        text = valueFormat(value)
                    }
                }
                this.option("text", text);
                if (this._input().val() !== (commonUtils.isDefined(text) ? text : "")) {
                    this._renderDisplayText(text)
                } else {
                    this._toggleEmptinessEventHandler()
                }
            },
            _renderDisplayText: function(text) {
                this._input().val(text);
                this._toggleEmptinessEventHandler()
            },
            _isValueValid: function() {
                if (this._input().length) {
                    var validity = this._input().get(0).validity;
                    if (validity) {
                        return validity.valid
                    }
                }
                return true
            },
            _toggleEmptiness: function(isEmpty) {
                this.element().toggleClass(TEXTEDITOR_EMPTY_INPUT_CLASS, isEmpty);
                this._togglePlaceholder(isEmpty)
            },
            _togglePlaceholder: function(isEmpty) {
                if (!this._$placeholder) {
                    return
                }
                this._$placeholder.toggleClass("dx-state-invisible", !isEmpty)
            },
            _renderProps: function() {
                this._toggleDisabledState(this.option("disabled"));
                this._toggleReadOnlyState();
                this._toggleSpellcheckState()
            },
            _toggleDisabledState: function(value) {
                this.callBase.apply(this, arguments);
                var $input = this._input();
                if (value) {
                    $input.attr("disabled", true).attr("tabindex", -1)
                } else {
                    $input.removeAttr("disabled").removeAttr("tabindex")
                }
            },
            _toggleReadOnlyState: function() {
                this._input().prop("readOnly", this._readOnlyPropValue());
                this.callBase()
            },
            _readOnlyPropValue: function() {
                return this.option("readOnly")
            },
            _toggleSpellcheckState: function() {
                this._input().prop("spellcheck", this.option("spellcheck"))
            },
            _renderPlaceholder: function() {
                if (this._$placeholder) {
                    this._$placeholder.remove();
                    this._$placeholder = null
                }
                var that = this,
                    $input = that._input(),
                    placeholderText = that.option("placeholder"),
                    $placeholder = this._$placeholder = $("<div>").attr("data-dx_placeholder", placeholderText),
                    startEvent = eventUtils.addNamespace(pointerEvents.up, this.NAME);
                $placeholder.on(startEvent, function() {
                    $input.focus()
                });
                $placeholder.insertAfter($input);
                $placeholder.addClass(TEXTEDITOR_PLACEHOLDER_CLASS);
                this._toggleEmptinessEventHandler()
            },
            _placeholder: function() {
                return this._$placeholder || $()
            },
            _renderInputAddons: function() {
                this._renderClearButton()
            },
            _renderClearButton: function() {
                var clearButtonVisibility = this._clearButtonVisibility();
                this.element().toggleClass(TEXTEDITOR_SHOW_CLEAR_BUTTON_CLASS, clearButtonVisibility);
                if (clearButtonVisibility) {
                    if (!this._$clearButton || this._$clearButton && !this._$clearButton.closest(this.element()).length) {
                        this._$clearButton = this._createClearButton()
                    }
                    this._$clearButton.prependTo(this._buttonsContainer())
                }
                if (this._$clearButton) {
                    this._$clearButton.toggleClass("dx-state-invisible", !clearButtonVisibility)
                }
            },
            _clearButtonVisibility: function() {
                return this.option("showClearButton") && !this.option("readOnly")
            },
            _createClearButton: function() {
                return $("<span>").addClass(TEXTEDITOR_CLEAR_BUTTON_CLASS).append($("<span>").addClass(TEXTEDITOR_ICON_CLASS).addClass(TEXTEDITOR_CLEAR_ICON_CLASS)).on(eventUtils.addNamespace(pointerEvents.down, this.NAME), function(e) {
                    if ("mouse" === e.pointerType) {
                        e.preventDefault()
                    }
                }).on(eventUtils.addNamespace(clickEvent.name, this.NAME), $.proxy(this._clearValueHandler, this))
            },
            _clearValueHandler: function(e) {
                var $input = this._input();
                e.stopPropagation();
                this._valueChangeEventHandler(e);
                this.reset();
                !$input.is(":focus") && $input.focus()
            },
            _renderEvents: function() {
                var that = this,
                    $input = that._input();
                $.each(EVENTS_LIST, function(_, event) {
                    var eventName = event.charAt(0).toLowerCase() + event.substr(1);
                    if (that.option("on" + event) || that.hasEvent(eventName)) {
                        var action = that._createActionByOption("on" + event, {
                            excludeValidators: ["readOnly"]
                        });
                        $input.on(eventUtils.addNamespace(event.toLowerCase(), that.NAME), function(e) {
                            if (that._disposed) {
                                return
                            }
                            action({
                                jQueryEvent: e
                            })
                        })
                    }
                })
            },
            _refreshEvents: function() {
                var that = this,
                    $input = this._input();
                $.each(EVENTS_LIST, function(_, event) {
                    $input.off(eventUtils.addNamespace(event.toLowerCase(), that.NAME))
                });
                this._renderEvents()
            },
            _keyPressHandler: function(e) {
                this.option("text", this._input().val())
            },
            _renderValueChangeEvent: function() {
                var keyPressEvent = eventUtils.addNamespace(this._renderValueEventName(), this.NAME + "TextChange"),
                    valueChangeEvent = eventUtils.addNamespace(this.option("valueChangeEvent"), this.NAME + "ValueChange");
                this._input().on(keyPressEvent, $.proxy(this._keyPressHandler, this)).on(valueChangeEvent, $.proxy(this._valueChangeEventHandler, this))
            },
            _cleanValueChangeEvent: function() {
                var eventNamespace = this.NAME + "ValueChange",
                    keyPressEvent = eventUtils.addNamespace(this._renderValueEventName(), this.NAME + "TextChange");
                this._input().off("." + eventNamespace).off(keyPressEvent)
            },
            _refreshValueChangeEvent: function() {
                this._cleanValueChangeEvent();
                this._renderValueChangeEvent()
            },
            _renderValueEventName: function() {
                return "input change keypress"
            },
            _focusTarget: function() {
                return this._input()
            },
            _focusClassTarget: function() {
                return this.element()
            },
            _toggleFocusClass: function(isFocused, $element) {
                this.callBase(isFocused, this._focusClassTarget($element))
            },
            _hasFocusClass: function(element) {
                return this.callBase($(element || this.element()))
            },
            _renderEmptinessEvent: function() {
                var $input = this._input();
                $input.on("input blur", $.proxy(this._toggleEmptinessEventHandler, this))
            },
            _toggleEmptinessEventHandler: function(value) {
                var text = this._input().val(),
                    isEmpty = ("" === text || null === text) && this._isValueValid();
                this._toggleEmptiness(isEmpty)
            },
            _valueChangeEventHandler: function(e, formattedValue) {
                this._saveValueChangeEvent(e);
                this.option("value", arguments.length > 1 ? formattedValue : this._input().val())
            },
            _renderEnterKeyAction: function() {
                this._enterKeyAction = this._createActionByOption("onEnterKey", {
                    excludeValidators: ["readOnly"]
                });
                this._input().off("keyup.onEnterKey.dxTextEditor").on("keyup.onEnterKey.dxTextEditor", $.proxy(this._enterKeyHandlerUp, this))
            },
            _enterKeyHandlerUp: function(e) {
                if (this._disposed) {
                    return
                }
                if (13 === e.which) {
                    this._enterKeyAction({
                        jQueryEvent: e
                    })
                }
            },
            _updateValue: function() {
                this.option("text", void 0);
                this._renderValue()
            },
            _dispose: function() {
                this._enterKeyAction = void 0;
                this.callBase()
            },
            _optionChanged: function(args) {
                var name = args.name;
                if ($.inArray(name.replace("on", ""), EVENTS_LIST) > -1) {
                    this._refreshEvents();
                    return
                }
                switch (name) {
                    case "valueChangeEvent":
                        this._refreshValueChangeEvent();
                        this._refreshFocusEvent();
                        this._refreshEvents();
                        break;
                    case "onValueChanged":
                        this._createValueChangeAction();
                        break;
                    case "readOnly":
                        this.callBase(args);
                        this._renderInputAddons();
                        break;
                    case "spellcheck":
                        this._toggleSpellcheckState();
                        break;
                    case "mode":
                        this._renderInputType();
                        break;
                    case "onEnterKey":
                        this._renderEnterKeyAction();
                        break;
                    case "placeholder":
                        this._renderPlaceholder();
                        break;
                    case "showClearButton":
                        this._renderInputAddons();
                        break;
                    case "text":
                        break;
                    case "value":
                        this._updateValue();
                        this.callBase(args);
                        break;
                    case "attr":
                        this._input().attr(args.value);
                        break;
                    case "valueFormat":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _renderInputType: function() {
                this._setInputType(this.option("mode"))
            },
            _setInputType: function(type) {
                var input = this._input();
                if ("search" === type) {
                    type = "text"
                }
                try {
                    input.prop("type", type)
                } catch (e) {
                    input.prop("type", "text")
                }
            },
            focus: function() {
                this._input().focus()
            },
            blur: function() {
                if (this._input().is(document.activeElement)) {
                    domUtils.resetActiveElement()
                }
            },
            reset: function() {
                this.option("value", "")
            }
        });
        var originalOnMethod = TextEditorBase.prototype.on;
        TextEditorBase.prototype.on = function(eventName, eventHandler) {
            originalOnMethod.call(this, eventName, eventHandler);
            var event = eventName.charAt(0).toUpperCase() + eventName.substr(1);
            if (EVENTS_LIST.indexOf(event) >= 0) {
                this._refreshEvents()
            }
        };
        module.exports = TextEditorBase
    },
    /*!*********************************************************!*\
      !*** ./Scripts/ui/text_box/ui.text_editor.mask.rule.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        var EMPTY_CHAR = " ";
        var BaseMaskRule = Class.inherit({
            ctor: function(config) {
                this._value = EMPTY_CHAR;
                $.extend(this, config)
            },
            next: function(rule) {
                if (!arguments.length) {
                    return this._next
                }
                this._next = rule
            },
            text: $.noop,
            value: $.noop,
            rawValue: $.noop,
            handle: $.noop,
            _prepareHandlingArgs: function(args, config) {
                config = config || {};
                var handlingProperty = args.hasOwnProperty("value") ? "value" : "text";
                args[handlingProperty] = commonUtils.isDefined(config.str) ? config.str : args[handlingProperty];
                args.start = commonUtils.isDefined(config.start) ? config.start : args.start;
                args.length = commonUtils.isDefined(config.length) ? config.length : args.length;
                args.index = args.index + 1;
                return args
            },
            reset: $.noop,
            clear: $.noop,
            isAccepted: function() {
                return false
            },
            adjustedCaret: function(caret, isForwardDirection, char) {
                return isForwardDirection ? this._adjustedForward(caret, 0, char) : this._adjustedBackward(caret, 0, char)
            },
            _adjustedForward: $.noop,
            _adjustedBackward: $.noop,
            isValid: $.noop
        });
        var EmptyMaskRule = BaseMaskRule.inherit({
            next: $.noop,
            handle: function() {
                return 0
            },
            text: function() {
                return ""
            },
            value: function() {
                return ""
            },
            rawValue: function() {
                return ""
            },
            adjustedCaret: function() {
                return 0
            },
            isValid: function() {
                return true
            }
        });
        var MaskRule = BaseMaskRule.inherit({
            text: function() {
                return (this._value !== EMPTY_CHAR ? this._value : this.maskChar) + this.next().text()
            },
            value: function() {
                return this._value + this.next().value()
            },
            rawValue: function() {
                return this._value + this.next().rawValue()
            },
            handle: function(args) {
                var str = args.hasOwnProperty("value") ? args.value : args.text;
                if (!str || !str.length || !args.length) {
                    return 0
                }
                if (args.start) {
                    return this.next().handle(this._prepareHandlingArgs(args, {
                        start: args.start - 1
                    }))
                }
                var char = str[0];
                var rest = str.substring(1);
                this._tryAcceptChar(char, args);
                return this._accepted() ? this.next().handle(this._prepareHandlingArgs(args, {
                    str: rest,
                    length: args.length - 1
                })) + 1 : this.handle(this._prepareHandlingArgs(args, {
                    str: rest,
                    length: args.length - 1
                }))
            },
            clear: function(args) {
                this._tryAcceptChar(EMPTY_CHAR, args);
                this.next().clear(this._prepareHandlingArgs(args))
            },
            reset: function() {
                this._accepted(false);
                this.next().reset()
            },
            _tryAcceptChar: function(char, args) {
                this._accepted(false);
                if (!this._isAllowed(char, args)) {
                    return
                }
                var acceptedChar = char === EMPTY_CHAR ? this.maskChar : char;
                args.fullText = args.fullText.substring(0, args.index) + acceptedChar + args.fullText.substring(args.index + 1);
                this._accepted(true);
                this._value = char
            },
            _accepted: function(value) {
                if (!arguments.length) {
                    return !!this._isAccepted
                }
                this._isAccepted = !!value
            },
            _isAllowed: function(char, args) {
                if (char === EMPTY_CHAR) {
                    return true
                }
                return this._isValid(char, args)
            },
            _isValid: function(char, args) {
                var allowedChars = this.allowedChars;
                if (allowedChars instanceof RegExp) {
                    return allowedChars.test(char)
                }
                if ($.isFunction(allowedChars)) {
                    return allowedChars(char, args.index, args.fullText)
                }
                if ($.isArray(allowedChars)) {
                    return $.inArray(char, allowedChars) > -1
                }
                return allowedChars === char
            },
            isAccepted: function(caret) {
                return 0 === caret ? this._accepted() : this.next().isAccepted(caret - 1)
            },
            _adjustedForward: function(caret, index, char) {
                if (index >= caret) {
                    return index
                }
                return this.next()._adjustedForward(caret, index + 1, char) || index + 1
            },
            _adjustedBackward: function(caret, index) {
                if (index >= caret - 1) {
                    return caret
                }
                return this.next()._adjustedBackward(caret, index + 1) || index + 1
            },
            isValid: function(args) {
                return this._isValid(this._value, args) && this.next().isValid(this._prepareHandlingArgs(args))
            }
        });
        var StubMaskRule = MaskRule.inherit({
            value: function() {
                return this.next().value()
            },
            handle: function(args) {
                var hasValueProperty = args.hasOwnProperty("value");
                var str = hasValueProperty ? args.value : args.text;
                if (!str.length || !args.length) {
                    return 0
                }
                if (args.start || hasValueProperty) {
                    return this.next().handle(this._prepareHandlingArgs(args, {
                        start: args.start && args.start - 1
                    }))
                }
                var char = str[0];
                var rest = str.substring(1);
                this._tryAcceptChar(char);
                var nextArgs = this._isAllowed(char) ? this._prepareHandlingArgs(args, {
                    str: rest,
                    length: args.length - 1
                }) : args;
                return this.next().handle(nextArgs) + 1
            },
            clear: function(args) {
                this._accepted(false);
                this.next().clear(this._prepareHandlingArgs(args))
            },
            _tryAcceptChar: function(char) {
                this._accepted(this._isValid(char))
            },
            _isValid: function(char) {
                return char === this.maskChar
            },
            _adjustedForward: function(caret, index, char) {
                if (index >= caret && char === this.maskChar) {
                    return index
                }
                if (caret === index + 1 && this._accepted()) {
                    return caret
                }
                return this.next()._adjustedForward(caret, index + 1, char)
            },
            _adjustedBackward: function(caret, index) {
                if (index >= caret - 1) {
                    return 0
                }
                return this.next()._adjustedBackward(caret, index + 1)
            },
            isValid: function(args) {
                return this.next().isValid(this._prepareHandlingArgs(args))
            }
        });
        module.exports.MaskRule = MaskRule;
        module.exports.StubMaskRule = StubMaskRule;
        module.exports.EmptyMaskRule = EmptyMaskRule
    },
    /*!****************************!*\
      !*** ./Scripts/ui/list.js ***!
      \****************************/
    function(module, exports, __webpack_require__) {
        var ListEdit = __webpack_require__( /*! ./list/ui.list.edit */ 214),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43);
        /**
         * @name dxList
         * @publicName dxList
         * @description List widget.
         * @inherits CollectionWidget
         * @module ui/list
         */
        registerComponent("dxList", ListEdit);
        module.exports = ListEdit
    },
    /*!*****************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            GroupedEditStrategy = __webpack_require__( /*! ./ui.list.edit.strategy.grouped */ 215),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            EditProvider = __webpack_require__( /*! ./ui.list.edit.provider */ 216),
            ListBase = __webpack_require__( /*! ./ui.list.base */ 226);
        var LIST_ITEM_SELECTED_CLASS = "dx-list-item-selected",
            LIST_ITEM_RESPONSE_WAIT_CLASS = "dx-list-item-response-wait";
        var ListEdit = ListBase.inherit({
            _supportedKeys: function() {
                var that = this,
                    parent = this.callBase();
                var deleteFocusedItem = function(e) {
                    if (that.option("allowItemDeleting")) {
                        e.preventDefault();
                        that.deleteItem(that.option("focusedElement"))
                    }
                };
                var moveFocusedItemUp = function(e) {
                    if (e.shiftKey && that.option("allowItemReordering")) {
                        e.preventDefault();
                        var focusedItemIndex = that._editStrategy.getNormalizedIndex(that.option("focusedElement")),
                            $prevItem = that._editStrategy.getItemElement(focusedItemIndex - 1);
                        that.reorderItem(that.option("focusedElement"), $prevItem);
                        that.scrollToItem(that.option("focusedElement"))
                    } else {
                        parent.upArrow(e)
                    }
                };
                var moveFocusedItemDown = function(e) {
                    if (e.shiftKey && that.option("allowItemReordering")) {
                        e.preventDefault();
                        var focusedItemIndex = that._editStrategy.getNormalizedIndex(that.option("focusedElement")),
                            $nextItem = that._editStrategy.getItemElement(focusedItemIndex + 1);
                        that.reorderItem(that.option("focusedElement"), $nextItem);
                        that.scrollToItem(that.option("focusedElement"))
                    } else {
                        parent.downArrow(e)
                    }
                };
                return $.extend({}, parent, {
                    del: deleteFocusedItem,
                    upArrow: moveFocusedItemUp,
                    downArrow: moveFocusedItemDown
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    showSelectionControls: false,
                    selectionMode: "none",
                    onSelectAllValueChanged: null,
                    selectAllText: messageLocalization.format("dxList-selectAll"),
                    menuItems: [],
                    menuMode: "context",
                    allowItemDeleting: false,
                    itemDeleteMode: "toggle",
                    allowItemReordering: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "ios" === device.platform
                    },
                    options: {
                        menuMode: "slide",
                        itemDeleteMode: "slideItem"
                    }
                }, {
                    device: {
                        platform: "android"
                    },
                    options: {
                        itemDeleteMode: "swipe"
                    }
                }, {
                    device: {
                        platform: "win"
                    },
                    options: {
                        itemDeleteMode: "context"
                    }
                }, {
                    device: {
                        platform: "generic"
                    },
                    options: {
                        itemDeleteMode: "static"
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this._initEditProvider()
            },
            _initEditProvider: function() {
                this._editProvider = new EditProvider(this)
            },
            _disposeEditProvider: function() {
                if (this._editProvider) {
                    this._editProvider.dispose()
                }
            },
            _refreshEditProvider: function() {
                this._disposeEditProvider();
                this._initEditProvider()
            },
            _initEditStrategy: function(grouped) {
                if (this.option("grouped")) {
                    this._editStrategy = new GroupedEditStrategy(this)
                } else {
                    this.callBase()
                }
            },
            _render: function() {
                this._refreshEditProvider();
                this.callBase()
            },
            _renderItems: function() {
                this.callBase.apply(this, arguments);
                this._editProvider.afterItemsRendered()
            },
            _selectedItemClass: function() {
                return LIST_ITEM_SELECTED_CLASS
            },
            _itemResponseWaitClass: function() {
                return LIST_ITEM_RESPONSE_WAIT_CLASS
            },
            _itemClickHandler: function(e) {
                var $itemElement = $(e.currentTarget);
                if ($itemElement.is(".dx-state-disabled, .dx-state-disabled *")) {
                    return
                }
                var handledByEditProvider = this._editProvider.handleClick($itemElement, e);
                if (handledByEditProvider) {
                    return
                }
                this.callBase.apply(this, arguments)
            },
            _shouldAttachContextMenuEvent: function() {
                return this.callBase.apply(this, arguments) || this._editProvider.contextMenuHandlerExists()
            },
            _itemHoldHandler: function(e) {
                var $itemElement = $(e.currentTarget);
                if ($itemElement.is(".dx-state-disabled, .dx-state-disabled *")) {
                    return
                }
                var isTouchEvent = eventUtils.isTouchEvent(e),
                    handledByEditProvider = isTouchEvent && this._editProvider.handleContextMenu($itemElement, e);
                if (handledByEditProvider) {
                    e.handledByEditProvider = true;
                    return
                }
                this.callBase.apply(this, arguments)
            },
            _itemContextMenuHandler: function(e) {
                var $itemElement = $(e.currentTarget);
                if ($itemElement.is(".dx-state-disabled, .dx-state-disabled *")) {
                    return
                }
                var handledByEditProvider = !e.handledByEditProvider && this._editProvider.handleContextMenu($itemElement, e);
                if (handledByEditProvider) {
                    e.preventDefault();
                    return
                }
                this.callBase.apply(this, arguments)
            },
            _postprocessRenderItem: function(args) {
                this.callBase.apply(this, arguments);
                this._editProvider.modifyItemElement(args)
            },
            _clean: function() {
                this._disposeEditProvider();
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "grouped":
                        this._clearSelectedItems();
                        delete this._renderingGroupIndex;
                        this._initEditStrategy(args.value);
                        this.callBase(args);
                        break;
                    case "showSelectionControls":
                    case "menuItems":
                    case "menuMode":
                    case "allowItemDeleting":
                    case "itemDeleteMode":
                    case "allowItemReordering":
                    case "selectAllText":
                        this._invalidate();
                        break;
                    case "onSelectAllValueChanged":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            getFlatIndexByItemElement: function(itemElement) {
                return this._itemElements().index(itemElement)
            },
            getItemElementByFlatIndex: function(flatIndex) {
                var $itemElements = this._itemElements();
                if (flatIndex < 0 || flatIndex >= $itemElements.length) {
                    return $()
                }
                return $itemElements.eq(flatIndex)
            },
            getItemByIndex: function(index) {
                return this._getItemData(this._itemElements().eq(index))
            }
        });
        module.exports = ListEdit
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.strategy.grouped.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            EditStrategy = __webpack_require__( /*! ../collection/ui.collection_widget.edit.strategy.plain */ 166);
        var LIST_ITEM_CLASS = "dx-list-item",
            LIST_GROUP_CLASS = "dx-list-group";
        var SELECTION_SHIFT = 20,
            SELECTION_MASK = 2303;
        var combineIndex = function(indices) {
            return (indices.group << SELECTION_SHIFT) + indices.item
        };
        var splitIndex = function(combinedIndex) {
            return {
                group: combinedIndex >> SELECTION_SHIFT,
                item: combinedIndex & SELECTION_MASK
            }
        };
        var createGroupSelection = function(group, selectedItems) {
            var groupItems = group.items,
                groupSelection = {
                    key: group.key,
                    items: []
                };
            $.each(selectedItems, function(_, itemIndex) {
                groupSelection.items.push(groupItems[itemIndex])
            });
            return groupSelection
        };
        var groupByKey = function(groups, key) {
            var length = groups.length;
            for (var i = 0; i < length; i++) {
                if (groups[i].key === key) {
                    return groups[i]
                }
            }
        };
        var GroupedEditStrategy = EditStrategy.inherit({
            _groupElements: function() {
                return this._collectionWidget._itemContainer().find("." + LIST_GROUP_CLASS)
            },
            _groupItemElements: function($group) {
                return $group.find("." + LIST_ITEM_CLASS)
            },
            getIndexByItemData: function(itemData) {
                var groups = this._collectionWidget.option("items"),
                    index = false;
                $.each(groups, function(groupIndex, group) {
                    if (!group.items) {
                        return false
                    }
                    $.each(group.items, function(itemIndex, item) {
                        if (item !== itemData) {
                            return true
                        }
                        index = {
                            group: groupIndex,
                            item: itemIndex
                        };
                        return false
                    });
                    if (index) {
                        return false
                    }
                });
                return index
            },
            getItemDataByIndex: function(index) {
                if (!index || !index.group || !index.item) {
                    return null
                }
                var items = this._collectionWidget.option("items");
                return items.length && items[index.group].items[index.item] || null
            },
            deleteItemAtIndex: function(index) {
                var indices = splitIndex(index),
                    itemGroup = this._collectionWidget.option("items")[indices.group].items;
                itemGroup.splice(indices.item, 1)
            },
            updateSelectionAfterDelete: function(fromIndex) {
                var deletedIndices = splitIndex(fromIndex),
                    selectedItemIndices = this._collectionWidget._selectedItemIndices;
                $.each(selectedItemIndices, function(i, index) {
                    var indices = splitIndex(index);
                    if (indices.group === deletedIndices.group && indices.item > deletedIndices.item) {
                        selectedItemIndices[i] -= 1
                    }
                })
            },
            fetchSelectedItems: function(indices) {
                indices = indices || this._collectionWidget._selectedItemIndices;
                indices.sort(function(a, b) {
                    return a - b
                });
                var items = this._collectionWidget.option("items"),
                    selectedItems = [];
                var currentGroupIndex = 0,
                    groupSelectedIndices = [];
                $.each(indices, function(_, combinedIndex) {
                    var index = splitIndex(combinedIndex);
                    if (index.group !== currentGroupIndex && groupSelectedIndices.length) {
                        selectedItems.push(createGroupSelection(items[currentGroupIndex], groupSelectedIndices));
                        groupSelectedIndices.length = 0
                    }
                    currentGroupIndex = index.group;
                    groupSelectedIndices.push(index.item)
                });
                if (groupSelectedIndices.length) {
                    selectedItems.push(createGroupSelection(items[currentGroupIndex], groupSelectedIndices))
                }
                return selectedItems
            },
            selectedItemIndices: function() {
                var selectedIndices = [],
                    items = this._collectionWidget.option("items"),
                    selected = this._collectionWidget.option("selectedItems"),
                    dataSource = this._collectionWidget._dataSource;
                $.each(selected, function(_, selectionInGroup) {
                    var group = groupByKey(items, selectionInGroup.key),
                        groupIndex = $.inArray(group, items);
                    if (!group) {
                        if (!dataSource) {
                            errors.log("W1003", selectionInGroup.key)
                        }
                        return
                    }
                    $.each(selectionInGroup.items, function(_, selectedGroupItem) {
                        var itemIndex = $.inArray(selectedGroupItem, group.items);
                        if (itemIndex !== -1) {
                            selectedIndices.push(combineIndex({
                                group: groupIndex,
                                item: itemIndex
                            }))
                        } else {
                            if (!dataSource) {
                                errors.log("W1004", selectedGroupItem, selectionInGroup.key)
                            }
                        }
                    })
                });
                return selectedIndices
            },
            moveItemAtIndexToIndex: function(movingIndex, destinationIndex) {
                var items = this._collectionWidget.option("items"),
                    movingIndices = splitIndex(movingIndex),
                    destinationIndices = splitIndex(destinationIndex),
                    movingItemGroup = items[movingIndices.group].items,
                    destinationItemGroup = items[destinationIndices.group].items,
                    movedItemData = movingItemGroup[movingIndices.item];
                movingItemGroup.splice(movingIndices.item, 1);
                destinationItemGroup.splice(destinationIndices.item, 0, movedItemData)
            },
            getSelectedItemsAfterReorderItem: function(movingIndex, destinationIndex) {
                if (this._itemsFromSameParent(movingIndex, destinationIndex) || $.inArray(movingIndex, this._collectionWidget._selectedItemIndices)) {
                    return this.callBase()
                }
                var items = this._collectionWidget.option("items"),
                    selectedItems = this._collectionWidget.option("selectedItems"),
                    movingIndices = splitIndex(movingIndex),
                    destinationIndices = splitIndex(destinationIndex),
                    movingSelectedItemGroup = selectedItems[movingIndices.group].items,
                    destinationSelectedItemGroup = selectedItems[destinationIndices.group].items,
                    movedItemData = items[movingIndices.group].items[movingIndices.item],
                    movedItemSelectedIndex = $.inArray(movedItemData, movingSelectedItemGroup);
                movingSelectedItemGroup.splice(movedItemSelectedIndex, 1);
                destinationSelectedItemGroup.push(movedItemData);
                return selectedItems
            },
            _isItemIndex: function(index) {
                return $.isNumeric(index.group) && $.isNumeric(index.item)
            },
            _getNormalizedItemIndex: function(itemElement) {
                var $item = $(itemElement),
                    $group = $item.closest("." + LIST_GROUP_CLASS);
                if (!$group.length) {
                    return -1
                }
                return combineIndex({
                    group: this._groupElements().index($group),
                    item: this._groupItemElements($group).index($item)
                })
            },
            _normalizeItemIndex: function(index) {
                return combineIndex(index)
            },
            _denormalizeItemIndex: function(index) {
                return splitIndex(index)
            },
            _getItemByNormalizedIndex: function(index) {
                var indices = splitIndex(index),
                    $group = this._groupElements().eq(indices.group);
                return this._groupItemElements($group).eq(indices.item)
            },
            _itemsFromSameParent: function(firstIndex, secondIndex) {
                return splitIndex(firstIndex).group === splitIndex(secondIndex).group
            }
        });
        module.exports = GroupedEditStrategy
    },
    /*!**************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.provider.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            decoratorRegistry = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217);
        __webpack_require__( /*! ./ui.list.edit.decorator.static */ 218);
        __webpack_require__( /*! ./ui.list.edit.decorator.switchable.button */ 220);
        __webpack_require__( /*! ./ui.list.edit.decorator.switchable.slide */ 222);
        __webpack_require__( /*! ./ui.list.edit.decorator.swipe */ 224);
        __webpack_require__( /*! ./ui.list.edit.decorator.context */ 225);
        __webpack_require__( /*! ./ui.list.edit.decorator.selection */ 240);
        __webpack_require__( /*! ./ui.list.edit.decorator.reorder */ 243);
        var editOptionsRegistry = [];
        var registerOption = function(enabledFunc, decoratorTypeFunc, decoratorSubTypeFunc) {
            editOptionsRegistry.push({
                enabled: enabledFunc,
                decoratorType: decoratorTypeFunc,
                decoratorSubType: decoratorSubTypeFunc
            })
        };
        registerOption(function() {
            return this.option("menuItems").length
        }, function() {
            return "menu"
        }, function() {
            return this.option("menuMode")
        });
        registerOption(function() {
            return !this.option("menuItems").length && this.option("allowItemDeleting")
        }, function() {
            var mode = this.option("itemDeleteMode");
            return "toggle" === mode || "slideButton" === mode || "swipe" === mode || "static" === mode ? "delete" : "menu"
        }, function() {
            var mode = this.option("itemDeleteMode");
            if ("slideItem" === mode) {
                mode = "slide"
            }
            if ("hold" === mode) {
                mode = "context"
            }
            return mode
        });
        registerOption(function() {
            return "none" !== this.option("selectionMode") && this.option("showSelectionControls")
        }, function() {
            return "selection"
        }, function() {
            return "default"
        });
        registerOption(function() {
            return this.option("allowItemReordering")
        }, function() {
            return "reorder"
        }, function() {
            return "default"
        });
        var LIST_ITEM_BEFORE_BAG_CLASS = "dx-list-item-before-bag",
            LIST_ITEM_AFTER_BAG_CLASS = "dx-list-item-after-bag",
            DECORATOR_BEFORE_BAG_CREATE_METHOD = "beforeBag",
            DECORATOR_AFTER_BAG_CREATE_METHOD = "afterBag",
            DECORATOR_MODIFY_ELEMENT_METHOD = "modifyElement",
            DECORATOR_AFTER_RENDER_METHOD = "afterRender";
        var EditProvider = Class.inherit({
            ctor: function(list) {
                this._list = list;
                this._fetchRequiredDecorators()
            },
            dispose: function() {
                if (this._decorators && this._decorators.length) {
                    $.each(this._decorators, function(_, decorator) {
                        decorator.dispose()
                    })
                }
            },
            _fetchRequiredDecorators: function() {
                this._decorators = [];
                $.each(editOptionsRegistry, $.proxy(function(_, option) {
                    var optionEnabled = option.enabled.call(this._list);
                    if (optionEnabled) {
                        var decoratorType = option.decoratorType.call(this._list),
                            decoratorSubType = option.decoratorSubType.call(this._list),
                            decorator = this._createDecorator(decoratorType, decoratorSubType);
                        this._decorators.push(decorator)
                    }
                }, this))
            },
            _createDecorator: function(type, subType) {
                var decoratorClass = this._findDecorator(type, subType);
                return new decoratorClass(this._list)
            },
            _findDecorator: function(type, subType) {
                var foundDecorator = decoratorRegistry.registry[type][subType];
                if (!foundDecorator) {
                    throw errors.Error("E1012", type, subType)
                }
                return foundDecorator
            },
            modifyItemElement: function(args) {
                var $itemElement = $(args.itemElement);
                var config = {
                    $itemElement: $itemElement
                };
                this._prependBeforeBags($itemElement, config);
                this._appendAfterBags($itemElement, config);
                this._applyDecorators(DECORATOR_MODIFY_ELEMENT_METHOD, config)
            },
            afterItemsRendered: function() {
                this._applyDecorators(DECORATOR_AFTER_RENDER_METHOD)
            },
            _prependBeforeBags: function($itemElement, config) {
                var $beforeBags = this._collectDecoratorsMarkup(DECORATOR_BEFORE_BAG_CREATE_METHOD, config, LIST_ITEM_BEFORE_BAG_CLASS);
                $itemElement.prepend($beforeBags)
            },
            _appendAfterBags: function($itemElement, config) {
                var $afterBags = this._collectDecoratorsMarkup(DECORATOR_AFTER_BAG_CREATE_METHOD, config, LIST_ITEM_AFTER_BAG_CLASS);
                $itemElement.append($afterBags)
            },
            _collectDecoratorsMarkup: function(method, config, containerClass) {
                var $collector = $("<div />");
                $.each(this._decorators, function() {
                    var $container = $("<div />").addClass(containerClass);
                    this[method]($.extend({
                        $container: $container
                    }, config));
                    if ($container.children().length) {
                        $collector.append($container)
                    }
                });
                return $collector.children()
            },
            _applyDecorators: function(method, config) {
                $.each(this._decorators, function() {
                    this[method](config)
                })
            },
            _handlerExists: function(name) {
                if (!this._decorators) {
                    return false
                }
                var decorators = this._decorators,
                    length = decorators.length;
                for (var i = 0; i < length; i++) {
                    if (decorators[i][name] !== $.noop) {
                        return true
                    }
                }
                return false
            },
            _eventHandler: function(name, $itemElement, e) {
                if (!this._decorators) {
                    return false
                }
                var response = false,
                    decorators = this._decorators,
                    length = decorators.length;
                for (var i = 0; i < length; i++) {
                    response = decorators[i][name]($itemElement, e);
                    if (response) {
                        break
                    }
                }
                return response
            },
            handleClick: function($itemElement, e) {
                return this._eventHandler("handleClick", $itemElement, e)
            },
            contextMenuHandlerExists: function() {
                return this._handlerExists("handleContextMenu")
            },
            handleContextMenu: function($itemElement, e) {
                return this._eventHandler("handleContextMenu", $itemElement, e)
            }
        });
        module.exports = EditProvider
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator_registry.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        exports.registry = {};
        exports.register = function(option, type, decoratorClass) {
            var decoratorsRegistry = exports.registry;
            var decoratorConfig = {};
            decoratorConfig[option] = decoratorsRegistry[option] ? decoratorsRegistry[option] : {};
            decoratorConfig[option][type] = decoratorClass;
            decoratorsRegistry = $.extend(decoratorsRegistry, decoratorConfig)
        }
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.static.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Button = __webpack_require__( /*! ../button */ 196),
            registerDecorator = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217).register,
            EditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator */ 219);
        var STATIC_DELETE_BUTTON_CONTAINER_CLASS = "dx-list-static-delete-button-container",
            STATIC_DELETE_BUTTON_CLASS = "dx-list-static-delete-button";
        registerDecorator("delete", "static", EditDecorator.inherit({
            afterBag: function(config) {
                var $itemElement = config.$itemElement,
                    $container = config.$container;
                var $button = $("<div>").addClass(STATIC_DELETE_BUTTON_CLASS);
                this._list._createComponent($button, Button, {
                    icon: "remove",
                    onClick: $.proxy(function(args) {
                        args.jQueryEvent.stopPropagation();
                        this._deleteItem($itemElement)
                    }, this),
                    _templates: {}
                });
                $container.addClass(STATIC_DELETE_BUTTON_CONTAINER_CLASS).append($button)
            },
            _deleteItem: function($itemElement) {
                if ($itemElement.is(".dx-state-disabled, .dx-state-disabled *")) {
                    return
                }
                this._list.deleteItem($itemElement)
            }
        }))
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            swipeEvents = __webpack_require__( /*! ../../events/swipe */ 178),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        var LIST_EDIT_DECORATOR = "dxListEditDecorator",
            SWIPE_START_EVENT_NAME = eventUtils.addNamespace(swipeEvents.start, LIST_EDIT_DECORATOR),
            SWIPE_UPDATE_EVENT_NAME = eventUtils.addNamespace(swipeEvents.swipe, LIST_EDIT_DECORATOR),
            SWIPE_END_EVENT_NAME = eventUtils.addNamespace(swipeEvents.end, LIST_EDIT_DECORATOR);
        var EditDecorator = Class.inherit({
            ctor: function(list) {
                this._list = list;
                this._init()
            },
            _init: $.noop,
            _shouldHandleSwipe: false,
            _attachSwipeEvent: function(config) {
                var swipeConfig = {
                    itemSizeFunc: $.proxy(function() {
                        if (this._clearSwipeCache) {
                            this._itemWidthCache = this._list.element().width();
                            this._clearSwipeCache = false
                        }
                        return this._itemWidthCache
                    }, this)
                };
                config.$itemElement.on(SWIPE_START_EVENT_NAME, swipeConfig, $.proxy(this._itemSwipeStartHandler, this)).on(SWIPE_UPDATE_EVENT_NAME, $.proxy(this._itemSwipeUpdateHandler, this)).on(SWIPE_END_EVENT_NAME, $.proxy(this._itemSwipeEndHandler, this))
            },
            _itemSwipeStartHandler: function(e) {
                var $itemElement = $(e.currentTarget);
                if ($itemElement.is(".dx-state-disabled, .dx-state-disabled *")) {
                    e.cancel = true;
                    return
                }
                this._swipeStartHandler($itemElement, e)
            },
            _itemSwipeUpdateHandler: function(e) {
                var $itemElement = $(e.currentTarget);
                this._swipeUpdateHandler($itemElement, e)
            },
            _itemSwipeEndHandler: function(e) {
                var $itemElement = $(e.currentTarget);
                this._swipeEndHandler($itemElement, e);
                this._clearSwipeCache = true
            },
            beforeBag: $.noop,
            afterBag: $.noop,
            _commonOptions: function() {
                return {
                    activeStateEnabled: this._list.option("activeStateEnabled"),
                    hoverStateEnabled: this._list.option("hoverStateEnabled"),
                    focusStateEnabled: this._list.option("focusStateEnabled")
                }
            },
            modifyElement: function(config) {
                if (this._shouldHandleSwipe) {
                    this._attachSwipeEvent(config);
                    this._clearSwipeCache = true
                }
            },
            afterRender: $.noop,
            handleClick: $.noop,
            handleContextMenu: $.noop,
            _swipeStartHandler: $.noop,
            _swipeUpdateHandler: $.noop,
            _swipeEndHandler: $.noop,
            visibilityChange: $.noop,
            dispose: $.noop
        });
        module.exports = EditDecorator
    },
    /*!*********************************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.switchable.button.js ***!
      \*********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            Button = __webpack_require__( /*! ../button */ 196),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            registerDecorator = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217).register,
            SwitchableEditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator.switchable */ 221);
        var SWITCHABLE_DELETE_BUTTON_CONTAINER_CLASS = "dx-list-switchable-delete-button-container",
            SWITCHABLE_DELETE_BUTTON_WRAPPER_CLASS = "dx-list-switchable-delete-button-wrapper",
            SWITCHABLE_DELETE_BUTTON_INNER_WRAPPER_CLASS = "dx-list-switchable-delete-button-inner-wrapper",
            SWITCHABLE_DELETE_BUTTON_CLASS = "dx-list-switchable-delete-button",
            SWITCHABLE_DELETE_BUTTON_ANIMATION_DURATION = 200;
        var SwitchableButtonEditDecorator = SwitchableEditDecorator.inherit({
            _init: function() {
                this.callBase.apply(this, arguments);
                var $buttonContainer = $("<div >").addClass(SWITCHABLE_DELETE_BUTTON_CONTAINER_CLASS),
                    $buttonWrapper = $("<div />").addClass(SWITCHABLE_DELETE_BUTTON_WRAPPER_CLASS),
                    $buttonInnerWrapper = $("<div />").addClass(SWITCHABLE_DELETE_BUTTON_INNER_WRAPPER_CLASS),
                    $button = $("<div />").addClass(SWITCHABLE_DELETE_BUTTON_CLASS);
                this._list._createComponent($button, Button, {
                    text: messageLocalization.format("dxListEditDecorator-delete"),
                    type: "danger",
                    onClick: $.proxy(function(e) {
                        this._deleteItem();
                        e.jQueryEvent.stopPropagation()
                    }, this),
                    _templates: {}
                });
                $buttonContainer.append($buttonWrapper);
                $buttonWrapper.append($buttonInnerWrapper);
                $buttonInnerWrapper.append($button);
                this._$buttonContainer = $buttonContainer
            },
            _enablePositioning: function($itemElement) {
                this.callBase.apply(this, arguments);
                fx.stop(this._$buttonContainer, true);
                this._$buttonContainer.appendTo($itemElement)
            },
            _disablePositioning: function() {
                this.callBase.apply(this, arguments);
                this._$buttonContainer.detach()
            },
            _animatePrepareDeleteReady: function() {
                var rtl = this._isRtlEnabled(),
                    listWidth = this._list.element().width(),
                    buttonWidth = this._buttonWidth(),
                    fromValue = rtl ? listWidth : -buttonWidth,
                    toValue = rtl ? listWidth - buttonWidth : 0;
                return fx.animate(this._$buttonContainer, {
                    type: "custom",
                    duration: SWITCHABLE_DELETE_BUTTON_ANIMATION_DURATION,
                    from: {
                        right: fromValue
                    },
                    to: {
                        right: toValue
                    }
                })
            },
            _animateForgetDeleteReady: function() {
                var rtl = this._isRtlEnabled(),
                    listWidth = this._list.element().width(),
                    buttonWidth = this._buttonWidth(),
                    fromValue = rtl ? listWidth - buttonWidth : 0,
                    toValue = rtl ? listWidth : -buttonWidth;
                return fx.animate(this._$buttonContainer, {
                    type: "custom",
                    duration: SWITCHABLE_DELETE_BUTTON_ANIMATION_DURATION,
                    from: {
                        right: fromValue
                    },
                    to: {
                        right: toValue
                    }
                })
            },
            _buttonWidth: function() {
                if (!this._buttonContainerWidth) {
                    this._buttonContainerWidth = this._$buttonContainer.outerWidth()
                }
                return this._buttonContainerWidth
            },
            dispose: function() {
                if (this._$buttonContainer) {
                    this._$buttonContainer.remove()
                }
                this.callBase.apply(this, arguments)
            }
        });
        var TOGGLE_DELETE_SWITCH_CONTAINER_CLASS = "dx-list-toggle-delete-switch-container",
            TOGGLE_DELETE_SWITCH_CLASS = "dx-list-toggle-delete-switch";
        registerDecorator("delete", "toggle", SwitchableButtonEditDecorator.inherit({
            beforeBag: function(config) {
                var $itemElement = config.$itemElement,
                    $container = config.$container;
                var $toggle = $("<div />").addClass(TOGGLE_DELETE_SWITCH_CLASS);
                this._list._createComponent($toggle, Button, {
                    icon: "toggle-delete",
                    onClick: $.proxy(function(e) {
                        this._toggleDeleteReady($itemElement);
                        e.jQueryEvent.stopPropagation()
                    }, this),
                    _templates: {}
                });
                $container.addClass(TOGGLE_DELETE_SWITCH_CONTAINER_CLASS);
                $container.append($toggle)
            }
        }));
        registerDecorator("delete", "slideButton", SwitchableButtonEditDecorator.inherit({
            _shouldHandleSwipe: true,
            _swipeEndHandler: function($itemElement, args) {
                if (0 !== args.targetOffset) {
                    this._toggleDeleteReady($itemElement)
                }
                return true
            }
        }));
        module.exports = SwitchableButtonEditDecorator
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.switchable.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            EditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator */ 219),
            abstract = EditDecorator.abstract,
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            feedbackEvents = __webpack_require__( /*! ../../events/core/emitter.feedback */ 103);
        var LIST_EDIT_DECORATOR = "dxListEditDecorator",
            POINTER_DOWN_EVENT_NAME = eventUtils.addNamespace(pointerEvents.down, LIST_EDIT_DECORATOR),
            ACTIVE_EVENT_NAME = eventUtils.addNamespace(feedbackEvents.active, LIST_EDIT_DECORATOR),
            LIST_ITEM_CONTENT_CLASS = "dx-list-item-content",
            SWITCHABLE_DELETE_READY_CLASS = "dx-list-switchable-delete-ready",
            SWITCHABLE_MENU_SHIELD_POSITIONING_CLASS = "dx-list-switchable-menu-shield-positioning",
            SWITCHABLE_DELETE_TOP_SHIELD_CLASS = "dx-list-switchable-delete-top-shield",
            SWITCHABLE_DELETE_BOTTOM_SHIELD_CLASS = "dx-list-switchable-delete-bottom-shield",
            SWITCHABLE_MENU_ITEM_SHIELD_POSITIONING_CLASS = "dx-list-switchable-menu-item-shield-positioning",
            SWITCHABLE_DELETE_ITEM_CONTENT_SHIELD_CLASS = "dx-list-switchable-delete-item-content-shield";
        var SwitchableEditDecorator = EditDecorator.inherit({
            _init: function() {
                this._$topShield = $("<div />").addClass(SWITCHABLE_DELETE_TOP_SHIELD_CLASS);
                this._$bottomShield = $("<div />").addClass(SWITCHABLE_DELETE_BOTTOM_SHIELD_CLASS);
                this._$itemContentShield = $("<div />").addClass(SWITCHABLE_DELETE_ITEM_CONTENT_SHIELD_CLASS);
                this._$topShield.on(POINTER_DOWN_EVENT_NAME, $.proxy(this._cancelDeleteReadyItem, this));
                this._$bottomShield.on(POINTER_DOWN_EVENT_NAME, $.proxy(this._cancelDeleteReadyItem, this));
                this._list.element().append(this._$topShield.toggle(false)).append(this._$bottomShield.toggle(false))
            },
            handleClick: function($itemElement) {
                return this._cancelDeleteReadyItem()
            },
            _cancelDeleteReadyItem: function() {
                if (!this._$readyToDeleteItem) {
                    return false
                }
                this._cancelDelete(this._$readyToDeleteItem);
                return true
            },
            _cancelDelete: function($itemElement) {
                this._toggleDeleteReady($itemElement, false)
            },
            _toggleDeleteReady: function($itemElement, readyToDelete) {
                if (void 0 === readyToDelete) {
                    readyToDelete = !this._isReadyToDelete($itemElement)
                }
                this._toggleShields($itemElement, readyToDelete);
                this._toggleScrolling(readyToDelete);
                this._cacheReadyToDeleteItem($itemElement, readyToDelete);
                this._animateToggleDelete($itemElement, readyToDelete)
            },
            _isReadyToDelete: function($itemElement) {
                return $itemElement.hasClass(SWITCHABLE_DELETE_READY_CLASS)
            },
            _toggleShields: function($itemElement, enabled) {
                this._list.element().toggleClass(SWITCHABLE_MENU_SHIELD_POSITIONING_CLASS, enabled);
                this._$topShield.toggle(enabled);
                this._$bottomShield.toggle(enabled);
                if (enabled) {
                    this._updateShieldsHeight($itemElement)
                }
                this._toggleContentShield($itemElement, enabled)
            },
            _updateShieldsHeight: function($itemElement) {
                var $list = this._list.element(),
                    listTopOffset = $list.offset().top,
                    listHeight = $list.outerHeight(),
                    itemTopOffset = $itemElement.offset().top,
                    itemHeight = $itemElement.outerHeight(),
                    dirtyTopShieldHeight = itemTopOffset - listTopOffset,
                    dirtyBottomShieldHeight = listHeight - itemHeight - dirtyTopShieldHeight;
                this._$topShield.height(Math.max(dirtyTopShieldHeight, 0));
                this._$bottomShield.height(Math.max(dirtyBottomShieldHeight, 0))
            },
            _toggleContentShield: function($itemElement, enabled) {
                if (enabled) {
                    $itemElement.find("." + LIST_ITEM_CONTENT_CLASS).first().append(this._$itemContentShield)
                } else {
                    this._$itemContentShield.detach()
                }
            },
            _toggleScrolling: function(readyToDelete) {
                var scrollView = this._list.element().dxScrollView("instance");
                if (readyToDelete) {
                    scrollView.on("start", this._cancelScrolling)
                } else {
                    scrollView.off("start", this._cancelScrolling)
                }
            },
            _cancelScrolling: function(args) {
                args.jQueryEvent.cancel = true
            },
            _cacheReadyToDeleteItem: function($itemElement, cache) {
                if (cache) {
                    this._$readyToDeleteItem = $itemElement
                } else {
                    delete this._$readyToDeleteItem
                }
            },
            _animateToggleDelete: function($itemElement, readyToDelete) {
                if (readyToDelete) {
                    this._enablePositioning($itemElement);
                    this._prepareDeleteReady($itemElement);
                    this._animatePrepareDeleteReady($itemElement)
                } else {
                    this._forgetDeleteReady($itemElement);
                    this._animateForgetDeleteReady($itemElement).done($.proxy(this._disablePositioning, this, $itemElement))
                }
            },
            _enablePositioning: function($itemElement) {
                $itemElement.addClass(SWITCHABLE_MENU_ITEM_SHIELD_POSITIONING_CLASS);
                $itemElement.on(ACTIVE_EVENT_NAME, $.noop)
            },
            _disablePositioning: function($itemElement) {
                $itemElement.removeClass(SWITCHABLE_MENU_ITEM_SHIELD_POSITIONING_CLASS);
                $itemElement.off(ACTIVE_EVENT_NAME)
            },
            _prepareDeleteReady: function($itemElement) {
                $itemElement.addClass(SWITCHABLE_DELETE_READY_CLASS)
            },
            _forgetDeleteReady: function($itemElement) {
                $itemElement.removeClass(SWITCHABLE_DELETE_READY_CLASS)
            },
            _animatePrepareDeleteReady: abstract,
            _animateForgetDeleteReady: abstract,
            _deleteItem: function($itemElement) {
                $itemElement = $itemElement || this._$readyToDeleteItem;
                if ($itemElement.is(".dx-state-disabled, .dx-state-disabled *")) {
                    return
                }
                this._list.deleteItem($itemElement).always($.proxy(this._cancelDelete, this, $itemElement))
            },
            _isRtlEnabled: function() {
                return this._list.option("rtlEnabled")
            },
            dispose: function() {
                if (this._$topShield) {
                    this._$topShield.remove()
                }
                if (this._$bottomShield) {
                    this._$bottomShield.remove()
                }
                this.callBase.apply(this, arguments)
            }
        });
        module.exports = SwitchableEditDecorator
    },
    /*!********************************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.switchable.slide.js ***!
      \********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            feedbackEvents = __webpack_require__( /*! ../../events/core/emitter.feedback */ 103),
            EditDecoratorMenuHelperMixin = __webpack_require__( /*! ./ui.list.edit.decorator_menu_helper */ 223),
            registerDecorator = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217).register,
            SwitchableEditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator.switchable */ 221),
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            ActionSheet = __webpack_require__( /*! ../action_sheet */ 201);
        var LIST_EDIT_DECORATOR = "dxListEditDecorator",
            CLICK_EVENT_NAME = eventUtils.addNamespace(clickEvent.name, LIST_EDIT_DECORATOR),
            ACTIVE_EVENT_NAME = eventUtils.addNamespace(feedbackEvents.active, LIST_EDIT_DECORATOR),
            SLIDE_MENU_CLASS = "dx-list-slide-menu",
            SLIDE_MENU_WRAPPER_CLASS = "dx-list-slide-menu-wrapper",
            SLIDE_MENU_CONTENT_CLASS = "dx-list-slide-menu-content",
            SLIDE_MENU_BUTTONS_CONTAINER_CLASS = "dx-list-slide-menu-buttons-container",
            SLIDE_MENU_BUTTONS_CLASS = "dx-list-slide-menu-buttons",
            SLIDE_MENU_BUTTON_CLASS = "dx-list-slide-menu-button",
            SLIDE_MENU_BUTTON_MENU_CLASS = "dx-list-slide-menu-button-menu",
            SLIDE_MENU_BUTTON_DELETE_CLASS = "dx-list-slide-menu-button-delete",
            SLIDE_MENU_ANIMATION_DURATION = 400,
            SLIDE_MENU_ANIMATION_EASING = "cubic-bezier(0.075, 0.82, 0.165, 1)";
        registerDecorator("menu", "slide", SwitchableEditDecorator.inherit({
            _shouldHandleSwipe: true,
            _init: function() {
                this.callBase.apply(this, arguments);
                this._$buttonsContainer = $("<div/>").addClass(SLIDE_MENU_BUTTONS_CONTAINER_CLASS).on(ACTIVE_EVENT_NAME, $.noop);
                this._$buttons = $("<div/>").addClass(SLIDE_MENU_BUTTONS_CLASS).appendTo(this._$buttonsContainer);
                this._renderMenu();
                this._renderDeleteButton()
            },
            _renderMenu: function() {
                if (!this._menuEnabled()) {
                    return
                }
                var menuItems = this._menuItems();
                if (1 === menuItems.length) {
                    var menuItem = menuItems[0];
                    this._renderMenuButton(menuItem.text, $.proxy(function(e) {
                        e.stopPropagation();
                        this._fireAction(menuItem)
                    }, this))
                } else {
                    var $menu = $("<div />").addClass(SLIDE_MENU_CLASS);
                    this._menu = this._list._createComponent($menu, ActionSheet, {
                        showTitle: false,
                        items: menuItems,
                        onItemClick: $.proxy(function(args) {
                            this._fireAction(args.itemData)
                        }, this),
                        _templates: {}
                    });
                    $menu.appendTo(this._list.element());
                    var $menuButton = this._renderMenuButton(messageLocalization.format("dxListEditDecorator-more"), $.proxy(function(e) {
                        e.stopPropagation();
                        this._menu.show()
                    }, this));
                    this._menu.option("target", $menuButton)
                }
            },
            _renderMenuButton: function(text, action) {
                var $menuButton = $("<div/>").addClass(SLIDE_MENU_BUTTON_CLASS).addClass(SLIDE_MENU_BUTTON_MENU_CLASS).text(text);
                this._$buttons.append($menuButton);
                $menuButton.on(CLICK_EVENT_NAME, action);
                return $menuButton
            },
            _renderDeleteButton: function() {
                if (!this._deleteEnabled()) {
                    return
                }
                var $deleteButton = $("<div/>").addClass(SLIDE_MENU_BUTTON_CLASS).addClass(SLIDE_MENU_BUTTON_DELETE_CLASS).text(messageLocalization.format("dxListEditDecorator-delete"));
                $deleteButton.on(CLICK_EVENT_NAME, $.proxy(function(e) {
                    e.stopPropagation();
                    this._deleteItem()
                }, this));
                this._$buttons.append($deleteButton)
            },
            _fireAction: function(menuItem) {
                this._fireMenuAction($(this._cachedNode), menuItem.action);
                this._cancelDeleteReadyItem()
            },
            modifyElement: function(config) {
                this.callBase.apply(this, arguments);
                var $itemElement = config.$itemElement;
                $itemElement.addClass(SLIDE_MENU_WRAPPER_CLASS);
                var $slideMenuContent = $("<div/>").addClass(SLIDE_MENU_CONTENT_CLASS);
                $itemElement.wrapInner($slideMenuContent)
            },
            handleClick: function(_, e) {
                if ($(e.target).closest("." + SLIDE_MENU_CONTENT_CLASS).length) {
                    return this.callBase.apply(this, arguments)
                }
                return false
            },
            _swipeStartHandler: function($itemElement) {
                this._enablePositioning($itemElement);
                this._cacheItemData($itemElement);
                this._setPositions(this._getPositions(0))
            },
            _swipeUpdateHandler: function($itemElement, args) {
                var rtl = this._isRtlEnabled(),
                    signCorrection = rtl ? -1 : 1,
                    isItemReadyToDelete = this._isReadyToDelete($itemElement),
                    moveJustStarted = this._getCurrentPositions().content === this._getStartPositions().content;
                if (moveJustStarted && !isItemReadyToDelete && args.offset * signCorrection > 0) {
                    args.cancel = true;
                    return
                }
                var offset = this._cachedItemWidth * args.offset,
                    startOffset = isItemReadyToDelete ? -this._cachedButtonWidth * signCorrection : 0,
                    correctedOffset = (offset + startOffset) * signCorrection,
                    percent = correctedOffset < 0 ? Math.abs((offset + startOffset) / this._cachedButtonWidth) : 0;
                this._setPositions(this._getPositions(percent));
                return true
            },
            _getStartPositions: function() {
                var rtl = this._isRtlEnabled(),
                    signCorrection = rtl ? -1 : 1;
                return {
                    content: 0,
                    buttonsContainer: rtl ? -this._cachedButtonWidth : this._cachedItemWidth,
                    buttons: -this._cachedButtonWidth * signCorrection
                }
            },
            _getPositions: function(percent) {
                var rtl = this._isRtlEnabled(),
                    signCorrection = rtl ? -1 : 1,
                    startPositions = this._getStartPositions();
                return {
                    content: startPositions.content - percent * this._cachedButtonWidth * signCorrection,
                    buttonsContainer: startPositions.buttonsContainer - Math.min(percent, 1) * this._cachedButtonWidth * signCorrection,
                    buttons: startPositions.buttons + Math.min(percent, 1) * this._cachedButtonWidth * signCorrection
                }
            },
            _getCurrentPositions: function() {
                return {
                    content: translator.locate(this._$cachedContent).left,
                    buttonsContainer: translator.locate(this._$buttonsContainer).left,
                    buttons: translator.locate(this._$buttons).left
                }
            },
            _setPositions: function(positions) {
                translator.move(this._$cachedContent, {
                    left: positions.content
                });
                translator.move(this._$buttonsContainer, {
                    left: positions.buttonsContainer
                });
                translator.move(this._$buttons, {
                    left: positions.buttons
                })
            },
            _cacheItemData: function($itemElement) {
                if ($itemElement[0] === this._cachedNode) {
                    return
                }
                this._$cachedContent = $itemElement.find("." + SLIDE_MENU_CONTENT_CLASS);
                this._cachedItemWidth = $itemElement.outerWidth();
                this._cachedButtonWidth = this._cachedButtonWidth || this._$buttons.outerWidth();
                this._$buttonsContainer.width(this._cachedButtonWidth);
                if (this._$cachedContent.length) {
                    this._cachedNode = $itemElement[0]
                }
            },
            _minButtonContainerLeftOffset: function() {
                return this._cachedItemWidth - this._cachedButtonWidth
            },
            _swipeEndHandler: function($itemElement, args) {
                this._cacheItemData($itemElement);
                var signCorrection = this._isRtlEnabled() ? 1 : -1,
                    offset = this._cachedItemWidth * args.offset,
                    endedAtReadyToDelete = !this._isReadyToDelete($itemElement) && offset * signCorrection > .2 * this._cachedButtonWidth,
                    readyToDelete = args.targetOffset === signCorrection && endedAtReadyToDelete;
                this._toggleDeleteReady($itemElement, readyToDelete);
                return true
            },
            _enablePositioning: function($itemElement) {
                fx.stop(this._$cachedContent, true);
                this.callBase.apply(this, arguments);
                this._$buttonsContainer.appendTo($itemElement)
            },
            _disablePositioning: function($itemElement) {
                this.callBase.apply(this, arguments);
                this._$buttonsContainer.detach()
            },
            _animatePrepareDeleteReady: function() {
                return this._animateToPositions(this._getPositions(1))
            },
            _animateForgetDeleteReady: function($itemElement) {
                this._cacheItemData($itemElement);
                return this._animateToPositions(this._getPositions(0))
            },
            _animateToPositions: function(positions) {
                var that = this,
                    currentPosition = this._getCurrentPositions(),
                    durationTimePart = Math.min(Math.abs(currentPosition.content - positions.content) / this._cachedButtonWidth, 1);
                return fx.animate(this._$cachedContent, {
                    from: currentPosition,
                    to: positions,
                    easing: SLIDE_MENU_ANIMATION_EASING,
                    duration: SLIDE_MENU_ANIMATION_DURATION * durationTimePart,
                    strategy: "frame",
                    draw: function(positions) {
                        that._setPositions(positions)
                    }
                })
            },
            dispose: function() {
                if (this._menu) {
                    this._menu.element().remove()
                }
                if (this._$buttonsContainer) {
                    this._$buttonsContainer.remove()
                }
                this.callBase.apply(this, arguments)
            }
        }).include(EditDecoratorMenuHelperMixin))
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator_menu_helper.js ***!
      \***************************************************************/
    function(module, exports) {
        var EditDecoratorMenuHelperMixin = {
            _menuEnabled: function() {
                return !!this._menuItems().length
            },
            _menuItems: function() {
                return this._list.option("menuItems")
            },
            _deleteEnabled: function() {
                return this._list.option("allowItemDeleting")
            },
            _fireMenuAction: function($itemElement, action) {
                this._list._itemEventHandlerByHandler($itemElement, action, {}, {
                    excludeValidators: ["disabled", "readOnly"]
                })
            }
        };
        module.exports = EditDecoratorMenuHelperMixin
    },
    /*!*********************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.swipe.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            registerDecorator = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217).register,
            EditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator */ 219);
        registerDecorator("delete", "swipe", EditDecorator.inherit({
            _shouldHandleSwipe: true,
            _renderItemPosition: function($itemElement, offset, animate) {
                var deferred = $.Deferred(),
                    itemOffset = offset * this._itemElementWidth;
                if (animate) {
                    fx.animate($itemElement, {
                        to: {
                            left: itemOffset
                        },
                        type: "slide",
                        complete: function() {
                            deferred.resolve($itemElement, offset)
                        }
                    })
                } else {
                    translator.move($itemElement, {
                        left: itemOffset
                    });
                    deferred.resolve()
                }
                return deferred.promise()
            },
            _swipeStartHandler: function($itemElement) {
                this._itemElementWidth = $itemElement.width();
                return true
            },
            _swipeUpdateHandler: function($itemElement, args) {
                this._renderItemPosition($itemElement, args.offset);
                return true
            },
            _swipeEndHandler: function($itemElement, args) {
                var offset = args.targetOffset;
                this._renderItemPosition($itemElement, offset, true).done($.proxy(function($itemElement, offset) {
                    if (Math.abs(offset)) {
                        this._list.deleteItem($itemElement).fail($.proxy(function() {
                            this._renderItemPosition($itemElement, 0, true)
                        }, this))
                    }
                }, this));
                return true
            }
        }))
    },
    /*!***********************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.context.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            EditDecoratorMenuHelperMixin = __webpack_require__( /*! ./ui.list.edit.decorator_menu_helper */ 223),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            registerDecorator = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217).register,
            EditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator */ 219),
            Overlay = __webpack_require__( /*! ../overlay */ 109),
            ListBase = __webpack_require__( /*! ./ui.list.base */ 226);
        var CONTEXTMENU_CLASS = "dx-list-context-menu",
            CONTEXTMENU_MENUCONTENT_CLASS = "dx-list-context-menucontent";
        registerDecorator("menu", "context", EditDecorator.inherit({
            _init: function() {
                var $menu = $("<div/>").addClass(CONTEXTMENU_CLASS);
                this._list.element().append($menu);
                this._menu = this._renderOverlay($menu)
            },
            _renderOverlay: function($element) {
                return this._list._createComponent($element, Overlay, {
                    shading: false,
                    deferRendering: true,
                    closeOnTargetScroll: true,
                    closeOnOutsideClick: function(e) {
                        return !$(e.target).closest("." + CONTEXTMENU_CLASS).length
                    },
                    animation: {
                        show: {
                            type: "slide",
                            duration: 300,
                            from: {
                                height: 0,
                                opacity: 1
                            },
                            to: {
                                height: $.proxy(function() {
                                    return this._$menuList.outerHeight()
                                }, this),
                                opacity: 1
                            }
                        },
                        hide: {
                            type: "slide",
                            duration: 0,
                            from: {
                                opacity: 1
                            },
                            to: {
                                opacity: 0
                            }
                        }
                    },
                    height: $.proxy(function() {
                        return this._$menuList ? this._$menuList.outerHeight() : 0
                    }, this),
                    width: $.proxy(function() {
                        return this._list.element().outerWidth()
                    }, this),
                    onContentReady: $.proxy(this._renderMenuContent, this)
                })
            },
            _renderMenuContent: function(e) {
                var $overlayContent = e.component.content();
                var items = this._menuItems().slice();
                if (this._deleteEnabled()) {
                    items.push({
                        text: messageLocalization.format("dxListEditDecorator-delete"),
                        action: $.proxy(this._deleteItem, this)
                    })
                }
                this._$menuList = $("<div>");
                this._list._createComponent(this._$menuList, ListBase, {
                    items: items,
                    onItemClick: $.proxy(this._menuItemClickHandler, this),
                    height: "auto",
                    _templates: {}
                });
                $overlayContent.addClass(CONTEXTMENU_MENUCONTENT_CLASS);
                $overlayContent.append(this._$menuList)
            },
            _menuItemClickHandler: function(args) {
                this._menu.hide();
                this._fireMenuAction(this._$itemWithMenu, args.itemData.action)
            },
            _deleteItem: function() {
                this._list.deleteItem(this._$itemWithMenu)
            },
            handleContextMenu: function($itemElement) {
                this._$itemWithMenu = $itemElement;
                this._menu.option({
                    position: {
                        my: "top",
                        at: "bottom",
                        of: $itemElement,
                        collision: "flip"
                    }
                });
                this._menu.show();
                return true
            },
            dispose: function() {
                if (this._menu) {
                    this._menu.element().remove()
                }
                this.callBase.apply(this, arguments)
            }
        }).include(EditDecoratorMenuHelperMixin))
    },
    /*!*****************************************!*\
      !*** ./Scripts/ui/list/ui.list.base.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            swipeEvents = __webpack_require__( /*! ../../events/swipe */ 178),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            inkRipple = __webpack_require__( /*! ../widget/utils.ink_ripple */ 197),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            Button = __webpack_require__( /*! ../button */ 196),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            themes = __webpack_require__( /*! ../themes */ 143),
            ScrollModule = __webpack_require__( /*! ../scroll_view/ui.scroll_view */ 227),
            deviceDependentOptions = __webpack_require__( /*! ../scroll_view/ui.scrollable */ 237).deviceDependentOptions,
            CollectionWidget = __webpack_require__( /*! ../collection/ui.collection_widget.edit */ 151);
        var LIST_CLASS = "dx-list",
            LIST_ITEM_CLASS = "dx-list-item",
            LIST_ITEM_SELECTOR = "." + LIST_ITEM_CLASS,
            LIST_GROUP_CLASS = "dx-list-group",
            LIST_GROUP_HEADER_CLASS = "dx-list-group-header",
            LIST_GROUP_BODY_CLASS = "dx-list-group-body",
            LIST_COLLAPSIBLE_GROUPS_CLASS = "dx-list-collapsible-groups",
            LIST_GROUP_COLLAPSED_CLASS = "dx-list-group-collapsed",
            LIST_HAS_NEXT_CLASS = "dx-has-next",
            LIST_NEXT_BUTTON_CLASS = "dx-list-next-button",
            LIST_ITEM_DATA_KEY = "dxListItemData",
            LIST_FEEDBACK_SHOW_TIMEOUT = 70;
        var groupItemsGetter = compileGetter("items");
        var ListBase = CollectionWidget.inherit({
            _activeStateUnit: LIST_ITEM_SELECTOR,
            _supportedKeys: function() {
                var that = this;
                var moveFocusPerPage = function(direction) {
                    var $item = getEdgeVisibleItem(direction),
                        isFocusedItem = $item.is(that.option("focusedElement"));
                    if (isFocusedItem) {
                        scrollListTo($item, direction);
                        $item = getEdgeVisibleItem(direction)
                    }
                    that.option("focusedElement", $item);
                    that.scrollToItem($item)
                };
                var getEdgeVisibleItem = function(direction) {
                    var scrollTop = that.scrollTop(),
                        containerHeight = that.element().height();
                    var $item = that.option("focusedElement"),
                        isItemVisible = true;
                    if (!$item) {
                        return $()
                    }
                    while (isItemVisible) {
                        var $nextItem = $item[direction]();
                        if (!$nextItem.length) {
                            break
                        }
                        var nextItemLocation = $nextItem.position().top + $nextItem.outerHeight() / 2;
                        isItemVisible = nextItemLocation < containerHeight + scrollTop && nextItemLocation > scrollTop;
                        if (isItemVisible) {
                            $item = $nextItem
                        }
                    }
                    return $item
                };
                var scrollListTo = function($item, direction) {
                    var resultPosition = $item.position().top;
                    if ("prev" === direction) {
                        resultPosition = $item.position().top - that.element().height() + $item.outerHeight()
                    }
                    that.scrollTo(resultPosition)
                };
                return $.extend(this.callBase(), {
                    leftArrow: $.noop,
                    rightArrow: $.noop,
                    pageUp: function() {
                        moveFocusPerPage("prev");
                        return false
                    },
                    pageDown: function() {
                        moveFocusPerPage("next");
                        return false
                    }
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    autoPagingEnabled: {
                        since: "15.1",
                        message: "Use the 'pageLoadMode' option instead"
                    },
                    showNextButton: {
                        since: "15.1",
                        message: "Use the 'pageLoadMode' option instead"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    pullRefreshEnabled: false,
                    scrollingEnabled: true,
                    showScrollbar: "onScroll",
                    useNativeScrolling: true,
                    bounceEnabled: true,
                    scrollByContent: true,
                    scrollByThumb: false,
                    pullingDownText: messageLocalization.format("dxList-pullingDownText"),
                    pulledDownText: messageLocalization.format("dxList-pulledDownText"),
                    refreshingText: messageLocalization.format("dxList-refreshingText"),
                    pageLoadingText: messageLocalization.format("dxList-pageLoadingText"),
                    onScroll: null,
                    onPullRefresh: null,
                    onPageLoading: null,
                    pageLoadMode: "scrollBottom",
                    nextButtonText: messageLocalization.format("dxList-nextButtonText"),
                    onItemSwipe: null,
                    grouped: false,
                    onGroupRendered: null,
                    collapsibleGroups: false,
                    groupTemplate: "group",
                    indicateLoading: true,
                    activeStateEnabled: true,
                    _itemAttributes: {
                        role: "option"
                    },
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat(deviceDependentOptions(), [{
                    device: function(device) {
                        return !support.nativeScrolling
                    },
                    options: {
                        useNativeScrolling: false
                    }
                }, {
                    device: function(device) {
                        return !support.nativeScrolling && !devices.isSimulator() && "generic" === devices.real().platform && "generic" === device.platform
                    },
                    options: {
                        showScrollbar: "onHover",
                        pageLoadMode: "nextButton"
                    }
                }, {
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }, {
                    device: function(device) {
                        return "win" === devices.current().platform && devices.isSimulator()
                    },
                    options: {
                        bounceEnabled: false
                    }
                }])
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._updateLoadingState(true)
                }
            },
            _itemClass: function() {
                return LIST_ITEM_CLASS
            },
            _itemDataKey: function() {
                return LIST_ITEM_DATA_KEY
            },
            _itemContainer: function() {
                return this._$container
            },
            _itemElements: function() {
                if (!this.option("grouped")) {
                    return this._itemContainer().children(this._itemSelector())
                }
                return this._itemContainer().children("." + LIST_GROUP_CLASS).children("." + LIST_GROUP_BODY_CLASS).children(this._itemSelector())
            },
            _itemSelectHandler: function(e) {
                if ("single" === this.option("selectionMode") && this.isItemSelected(e.currentTarget)) {
                    return
                }
                this.callBase(e)
            },
            _allowDynamicItemsAppend: function() {
                return true
            },
            _init: function() {
                this.callBase();
                this._$container = this.element();
                this._initScrollView();
                this._feedbackShowTimeout = LIST_FEEDBACK_SHOW_TIMEOUT;
                this._createGroupRenderAction();
                this.setAria("role", "listbox")
            },
            _dataSourceOptions: function() {
                this._suppressDeprecatedWarnings();
                var pagingEnabled = this.option("autoPagingEnabled");
                pagingEnabled = commonUtils.isDefined(this.option("showNextButton")) ? pagingEnabled || this.option("showNextButton") : pagingEnabled;
                this._resumeDeprecatedWarnings();
                return $.extend(this.callBase(), {
                    paginate: commonUtils.isDefined(pagingEnabled) ? pagingEnabled : true
                })
            },
            _initScrollView: function() {
                this._suppressDeprecatedWarnings();
                var scrollingEnabled = this.option("scrollingEnabled"),
                    pullRefreshEnabled = scrollingEnabled && this.option("pullRefreshEnabled"),
                    autoPagingEnabled = scrollingEnabled && commonUtils.ensureDefined(this.option("autoPagingEnabled"), "scrollBottom" === this.option("pageLoadMode")) && !!this._dataSource;
                this._resumeDeprecatedWarnings();
                this._scrollView = this._createComponent(this.element(), ScrollModule.ScrollView, {
                    disabled: this.option("disabled") || !scrollingEnabled,
                    onScroll: $.proxy(this._scrollHandler, this),
                    onPullDown: pullRefreshEnabled ? $.proxy(this._pullDownHandler, this) : null,
                    onReachBottom: autoPagingEnabled ? $.proxy(this._scrollBottomHandler, this) : null,
                    showScrollbar: this.option("showScrollbar"),
                    useNative: this.option("useNativeScrolling"),
                    bounceEnabled: this.option("bounceEnabled"),
                    scrollByContent: this.option("scrollByContent"),
                    scrollByThumb: this.option("scrollByThumb"),
                    pullingDownText: this.option("pullingDownText"),
                    pulledDownText: this.option("pulledDownText"),
                    refreshingText: this.option("refreshingText"),
                    reachBottomText: this.option("pageLoadingText"),
                    useKeyboard: false
                });
                this._$container = this._scrollView.content();
                this._createScrollViewActions()
            },
            _createScrollViewActions: function() {
                this._scrollAction = this._createActionByOption("onScroll");
                this._pullRefreshAction = this._createActionByOption("onPullRefresh");
                this._pageLoadingAction = this._createActionByOption("onPageLoading")
            },
            _scrollHandler: function(e) {
                this._scrollAction(e)
            },
            _updateLoadingState: function(tryLoadMore) {
                this._suppressDeprecatedWarnings();
                var isDataLoaded = !tryLoadMore || this._isLastPage(),
                    autoPagingEnabled = commonUtils.ensureDefined(this.option("autoPagingEnabled"), "scrollBottom" === this.option("pageLoadMode")),
                    stopLoading = isDataLoaded || !autoPagingEnabled,
                    hideLoadIndicator = stopLoading && !this._isDataSourceLoading();
                this._resumeDeprecatedWarnings();
                if (stopLoading || this._scrollViewIsFull()) {
                    this._scrollView.release(hideLoadIndicator);
                    this._toggleNextButton(this._shouldRenderNextButton() && !isDataLoaded);
                    this._loadIndicationSuppressed(false)
                } else {
                    this._infiniteDataLoading()
                }
            },
            _shouldRenderNextButton: function() {
                this._suppressDeprecatedWarnings();
                var result = commonUtils.ensureDefined(this.option("showNextButton"), "nextButton" === this.option("pageLoadMode")) && this._dataSource && this._dataSource.isLoaded();
                this._resumeDeprecatedWarnings();
                return result
            },
            _dataSourceLoadingChangedHandler: function(isLoading) {
                if (this._loadIndicationSuppressed()) {
                    return
                }
                if (isLoading && this.option("indicateLoading")) {
                    this._showLoadingIndicatorTimer = setTimeout($.proxy(function() {
                        var isEmpty = !this._itemElements().length;
                        if (this._scrollView && !isEmpty) {
                            this._scrollView.startLoading()
                        }
                    }, this))
                } else {
                    clearTimeout(this._showLoadingIndicatorTimer);
                    this._scrollView && this._scrollView.finishLoading()
                }
            },
            _dataSourceChangedHandler: function(newItems) {
                if (!this._shouldAppendItems()) {
                    this._scrollView && this._scrollView.scrollTo(0)
                }
                this.callBase(newItems)
            },
            _hideLoadingIfLoadIndicationOff: function() {
                if (!this.option("indicateLoading")) {
                    this._dataSourceLoadingChangedHandler(false)
                }
            },
            _loadIndicationSuppressed: function(value) {
                if (!arguments.length) {
                    return this._isLoadIndicationSuppressed
                }
                this._isLoadIndicationSuppressed = value
            },
            _scrollViewIsFull: function() {
                return !this._scrollView || this._scrollView.isFull()
            },
            _pullDownHandler: function(e) {
                this._pullRefreshAction(e);
                if (this._dataSource && !this._isDataSourceLoading()) {
                    this._clearSelectedItems();
                    this._dataSource.pageIndex(0);
                    this._dataSource.load()
                } else {
                    this._updateLoadingState()
                }
            },
            _infiniteDataLoading: function() {
                var isElementVisible = this.element().is(":visible");
                if (isElementVisible && !this._scrollViewIsFull() && !this._isDataSourceLoading() && !this._isLastPage()) {
                    clearTimeout(this._loadNextPageTimer);
                    this._loadNextPageTimer = setTimeout($.proxy(this._loadNextPage, this))
                }
            },
            _scrollBottomHandler: function(e) {
                this._pageLoadingAction(e);
                if (!this._isDataSourceLoading() && !this._isLastPage()) {
                    this._loadNextPage()
                } else {
                    this._updateLoadingState()
                }
            },
            _renderItems: function(items) {
                if (this.option("grouped")) {
                    $.each(items, $.proxy(this._renderGroup, this));
                    this._attachGroupCollapseEvent();
                    this._renderEmptyMessage()
                } else {
                    this.callBase.apply(this, arguments)
                }
                this._updateLoadingState(true)
            },
            _attachGroupCollapseEvent: function() {
                var eventName = eventUtils.addNamespace(clickEvent.name, this.NAME),
                    selector = "." + LIST_GROUP_HEADER_CLASS,
                    $element = this.element(),
                    collapsibleGroups = this.option("collapsibleGroups");
                $element.toggleClass(LIST_COLLAPSIBLE_GROUPS_CLASS, collapsibleGroups);
                $element.off(eventName, selector);
                if (collapsibleGroups) {
                    $element.on(eventName, selector, $.proxy(function(e) {
                        this._createAction($.proxy(function(e) {
                            var $group = $(e.jQueryEvent.currentTarget).parent();
                            this._collapseGroupHandler($group);
                            if (this.option("focusStateEnabled")) {
                                this.option("focusedElement", $group.find("." + LIST_ITEM_CLASS).eq(0))
                            }
                        }, this), {
                            validatingTargetName: "element"
                        })({
                            jQueryEvent: e
                        })
                    }, this))
                }
            },
            _collapseGroupHandler: function($group, toggle) {
                var deferred = $.Deferred(),
                    $groupBody = $group.children("." + LIST_GROUP_BODY_CLASS);
                $group.toggleClass(LIST_GROUP_COLLAPSED_CLASS, toggle);
                var slideMethod = "slideToggle";
                if (true === toggle) {
                    slideMethod = "slideUp"
                }
                if (false === toggle) {
                    slideMethod = "slideDown"
                }
                $groupBody[slideMethod]({
                    duration: 200,
                    complete: $.proxy(function() {
                        this.updateDimensions();
                        this._updateLoadingState(true);
                        deferred.resolve()
                    }, this)
                });
                return deferred.promise()
            },
            _dataSourceLoadErrorHandler: function() {
                this._forgetNextPageLoading();
                if (this._initialized) {
                    this._renderEmptyMessage();
                    this._updateLoadingState()
                }
            },
            _render: function() {
                this.element().addClass(LIST_CLASS);
                this.callBase();
                this.option("useInkRipple") && this._renderInkRipple()
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render()
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: $element,
                    jQueryEvent: e
                };
                if (value) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _postprocessRenderItem: function(args) {
                this.callBase.apply(this, arguments);
                if (this.option("onItemSwipe")) {
                    this._attachSwipeEvent($(args.itemElement))
                }
            },
            _attachSwipeEvent: function($itemElement) {
                var endEventName = eventUtils.addNamespace(swipeEvents.end, this.NAME);
                $itemElement.on(endEventName, $.proxy(this._itemSwipeEndHandler, this))
            },
            _itemSwipeEndHandler: function(e) {
                this._itemJQueryEventHandler(e, "onItemSwipe", {
                    direction: e.offset < 0 ? "left" : "right"
                })
            },
            _nextButtonHandler: function() {
                var source = this._dataSource;
                if (source && !source.isLoading()) {
                    this._scrollView.toggleLoading(true);
                    this._$nextButton.detach();
                    this._loadIndicationSuppressed(true);
                    this._loadNextPage()
                }
            },
            _renderGroup: function(index, group) {
                var $groupElement = $("<div>").addClass(LIST_GROUP_CLASS).appendTo(this._itemContainer());
                var $groupHeaderElement = $("<div>").addClass(LIST_GROUP_HEADER_CLASS).appendTo($groupElement);
                var groupTemplateName = this.option("groupTemplate"),
                    groupTemplate = this._getTemplate(group.template || groupTemplateName, group, index, $groupHeaderElement),
                    renderArgs = {
                        index: index,
                        itemData: group,
                        container: $groupHeaderElement
                    };
                this._createItemByTemplate(groupTemplate, renderArgs);
                this._renderingGroupIndex = index;
                var $groupBody = $("<div>").addClass(LIST_GROUP_BODY_CLASS).appendTo($groupElement);
                $.each(groupItemsGetter(group) || [], $.proxy(function(index, item) {
                    this._renderItem(index, item, $groupBody)
                }, this));
                this._groupRenderAction({
                    groupElement: $groupElement,
                    groupIndex: index,
                    groupData: group
                })
            },
            _createGroupRenderAction: function() {
                this._groupRenderAction = this._createActionByOption("onGroupRendered")
            },
            _clean: function() {
                if (this._$nextButton) {
                    this._$nextButton.remove();
                    this._$nextButton = null
                }
                this.callBase.apply(this, arguments)
            },
            _dispose: function() {
                clearTimeout(this._holdTimer);
                clearTimeout(this._loadNextPageTimer);
                clearTimeout(this._showLoadingIndicatorTimer);
                this.callBase()
            },
            _toggleDisabledState: function(value) {
                this.callBase(value);
                this._scrollView.option("disabled", value || !this.option("scrollingEnabled"))
            },
            _toggleNextButton: function(value) {
                var dataSource = this._dataSource,
                    $nextButton = this._getNextButton();
                this.element().toggleClass(LIST_HAS_NEXT_CLASS, value);
                if (value && dataSource && dataSource.isLoaded()) {
                    $nextButton.appendTo(this._itemContainer())
                }
                if (!value) {
                    $nextButton.detach()
                }
            },
            _getNextButton: function() {
                if (!this._$nextButton) {
                    this._$nextButton = this._createNextButton()
                }
                return this._$nextButton
            },
            _createNextButton: function() {
                var $result = $("<div>").addClass(LIST_NEXT_BUTTON_CLASS);
                var $button = $("<div>").appendTo($result);
                this._createComponent($button, Button, {
                    text: this.option("nextButtonText"),
                    onClick: $.proxy(this._nextButtonHandler, this),
                    _templates: {}
                });
                return $result
            },
            _moveFocus: function(location) {
                this.callBase.apply(this, arguments);
                this.scrollToItem(this.option("focusedElement"))
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "pageLoadMode":
                        this._toggleNextButton(args.value);
                        this._initScrollView();
                        break;
                    case "showNextButton":
                        this._toggleNextButton(args.value);
                        break;
                    case "dataSource":
                        this.callBase(args);
                        this._initScrollView();
                        break;
                    case "pullingDownText":
                    case "pulledDownText":
                    case "refreshingText":
                    case "pageLoadingText":
                    case "useNative":
                    case "showScrollbar":
                    case "bounceEnabled":
                    case "scrollByContent":
                    case "scrollByThumb":
                    case "scrollingEnabled":
                    case "pullRefreshEnabled":
                    case "autoPagingEnabled":
                        this._initScrollView();
                        this._updateLoadingState();
                        break;
                    case "nextButtonText":
                    case "onItemSwipe":
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    case "onScroll":
                    case "onPullRefresh":
                    case "onPageLoading":
                        this._createScrollViewActions();
                        this._invalidate();
                        break;
                    case "grouped":
                    case "collapsibleGroups":
                    case "groupTemplate":
                        this._invalidate();
                        break;
                    case "onGroupRendered":
                        this._createGroupRenderAction();
                        break;
                    case "width":
                    case "height":
                        this.callBase(args);
                        this._scrollView.update();
                        break;
                    case "indicateLoading":
                        this._hideLoadingIfLoadIndicationOff();
                        break;
                    case "visible":
                        this.callBase(args);
                        this._scrollView.update();
                        break;
                    case "rtlEnabled":
                        this._initScrollView();
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _extendActionArgs: function($itemElement) {
                if (!this.option("grouped")) {
                    return this.callBase($itemElement)
                }
                var $group = $itemElement.closest("." + LIST_GROUP_CLASS);
                var $item = $group.find("." + LIST_ITEM_CLASS);
                return $.extend(this.callBase($itemElement), {
                    itemIndex: {
                        group: $group.index(),
                        item: $item.index($itemElement)
                    }
                })
            },
            expandGroup: function(groupIndex) {
                var deferred = $.Deferred(),
                    $group = this._itemContainer().find("." + LIST_GROUP_CLASS).eq(groupIndex);
                this._collapseGroupHandler($group, false).done($.proxy(function() {
                    deferred.resolveWith(this)
                }, this));
                return deferred.promise()
            },
            collapseGroup: function(groupIndex) {
                var deferred = $.Deferred(),
                    $group = this._itemContainer().find("." + LIST_GROUP_CLASS).eq(groupIndex);
                this._collapseGroupHandler($group, true).done($.proxy(function() {
                    deferred.resolveWith(this)
                }, this));
                return deferred
            },
            updateDimensions: function() {
                var that = this,
                    deferred = $.Deferred();
                if (that._scrollView) {
                    that._scrollView.update().done(function() {
                        deferred.resolveWith(that)
                    })
                } else {
                    deferred.resolveWith(that)
                }
                return deferred.promise()
            },
            reload: function() {
                this.scrollTo(0);
                this._pullDownHandler()
            },
            repaint: function() {
                this.scrollTo(0);
                this.callBase()
            },
            scrollTop: function() {
                return this._scrollView.scrollOffset().top
            },
            clientHeight: function() {
                return this._scrollView.clientHeight()
            },
            scrollHeight: function() {
                return this._scrollView.scrollHeight()
            },
            scrollBy: function(distance) {
                this._scrollView.scrollBy(distance)
            },
            scrollTo: function(location) {
                this._scrollView.scrollTo(location)
            },
            scrollToItem: function(itemElement) {
                var $item = this._editStrategy.getItemElement(itemElement);
                this._scrollView.scrollToElement($item)
            }
        });
        module.exports = ListBase
    },
    /*!**************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scroll_view.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            PullDownStrategy = __webpack_require__( /*! ./ui.scroll_view.native.pull_down */ 228),
            SwipeDownStrategy = __webpack_require__( /*! ./ui.scroll_view.native.swipe_down */ 232),
            SlideDownStrategy = __webpack_require__( /*! ./ui.scroll_view.native.slide_down */ 233),
            SimulatedStrategy = __webpack_require__( /*! ./ui.scroll_view.simulated */ 234),
            Scrollable = __webpack_require__( /*! ./ui.scrollable */ 237).default,
            LoadIndicator = __webpack_require__( /*! ../load_indicator */ 231),
            config = __webpack_require__( /*! ../../core/config */ 15),
            LoadPanel = __webpack_require__( /*! ../load_panel */ 239);
        var SCROLLVIEW_CLASS = "dx-scrollview",
            SCROLLVIEW_CONTENT_CLASS = SCROLLVIEW_CLASS + "-content",
            SCROLLVIEW_TOP_POCKET_CLASS = SCROLLVIEW_CLASS + "-top-pocket",
            SCROLLVIEW_BOTTOM_POCKET_CLASS = SCROLLVIEW_CLASS + "-bottom-pocket",
            SCROLLVIEW_PULLDOWN_CLASS = SCROLLVIEW_CLASS + "-pull-down",
            SCROLLVIEW_REACHBOTTOM_CLASS = SCROLLVIEW_CLASS + "-scrollbottom",
            SCROLLVIEW_REACHBOTTOM_INDICATOR_CLASS = SCROLLVIEW_REACHBOTTOM_CLASS + "-indicator",
            SCROLLVIEW_REACHBOTTOM_TEXT_CLASS = SCROLLVIEW_REACHBOTTOM_CLASS + "-text",
            SCROLLVIEW_LOADPANEL = SCROLLVIEW_CLASS + "-loadpanel";
        var refreshStrategies = {
            pullDown: PullDownStrategy,
            swipeDown: SwipeDownStrategy,
            slideDown: SlideDownStrategy,
            simulated: SimulatedStrategy
        };
        var ScrollView = Scrollable.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    pullingDownText: messageLocalization.format("dxScrollView-pullingDownText"),
                    pulledDownText: messageLocalization.format("dxScrollView-pulledDownText"),
                    refreshingText: messageLocalization.format("dxScrollView-refreshingText"),
                    reachBottomText: messageLocalization.format("dxScrollView-reachBottomText"),
                    onPullDown: null,
                    onReachBottom: null,
                    refreshStrategy: "pullDown"
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        var realDevice = devices.real();
                        return "android" === realDevice.platform
                    },
                    options: {
                        refreshStrategy: "swipeDown"
                    }
                }, {
                    device: function(device) {
                        return "win" === devices.real().platform
                    },
                    options: {
                        refreshStrategy: "slideDown"
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this._loadingIndicatorEnabled = true
            },
            _initMarkup: function() {
                this.callBase();
                this.element().addClass(SCROLLVIEW_CLASS);
                this._initContent();
                this._initTopPocket();
                this._initBottomPocket();
                this._initLoadPanel()
            },
            _initContent: function() {
                var $content = $("<div>").addClass(SCROLLVIEW_CONTENT_CLASS);
                this._$content.wrapInner($content)
            },
            _initTopPocket: function() {
                var $topPocket = this._$topPocket = $("<div>").addClass(SCROLLVIEW_TOP_POCKET_CLASS),
                    $pullDown = this._$pullDown = $("<div>").addClass(SCROLLVIEW_PULLDOWN_CLASS);
                $topPocket.append($pullDown);
                this._$content.prepend($topPocket)
            },
            _initBottomPocket: function() {
                var $bottomPocket = this._$bottomPocket = $("<div>").addClass(SCROLLVIEW_BOTTOM_POCKET_CLASS),
                    $reachBottom = this._$reachBottom = $("<div>").addClass(SCROLLVIEW_REACHBOTTOM_CLASS),
                    $loadContainer = $("<div>").addClass(SCROLLVIEW_REACHBOTTOM_INDICATOR_CLASS),
                    $loadIndicator = $("<div>")[LoadIndicator.publicName()](),
                    $text = this._$reachBottomText = $("<div>").addClass(SCROLLVIEW_REACHBOTTOM_TEXT_CLASS);
                this._updateReachBottomText();
                $reachBottom.append($loadContainer.append($loadIndicator)).append($text);
                $bottomPocket.append($reachBottom);
                this._$content.append($bottomPocket)
            },
            _initLoadPanel: function() {
                this._loadPanel = this._createComponent($("<div>").addClass(SCROLLVIEW_LOADPANEL).appendTo(this.element()), LoadPanel, {
                    shading: false,
                    delay: 400,
                    message: this.option("refreshingText"),
                    position: {
                        of: this.element()
                    }
                })
            },
            _updateReachBottomText: function() {
                this._$reachBottomText.text(this.option("reachBottomText"))
            },
            _createStrategy: function() {
                var strategyName = this.option("useNative") ? this.option("refreshStrategy") : "simulated";
                var strategyClass = refreshStrategies[strategyName];
                if (!strategyClass) {
                    throw Error("E1030", this.option("refreshStrategy"))
                }
                this._strategy = new strategyClass(this);
                this._strategy.pullDownCallbacks.add($.proxy(this._pullDownHandler, this));
                this._strategy.releaseCallbacks.add($.proxy(this._releaseHandler, this));
                this._strategy.reachBottomCallbacks.add($.proxy(this._reachBottomHandler, this))
            },
            _createActions: function() {
                this.callBase();
                this._pullDownAction = this._createActionByOption("onPullDown");
                this._reachBottomAction = this._createActionByOption("onReachBottom");
                this._pullDownEnable(!!this.option("onPullDown") && !config().designMode);
                this._reachBottomEnable(!!this.option("onReachBottom") && !config().designMode)
            },
            _pullDownEnable: function(enabled) {
                if (0 === arguments.length) {
                    return this._pullDownEnabled
                }
                this._$pullDown.toggle(enabled);
                this._strategy.pullDownEnable(enabled);
                this._pullDownEnabled = enabled
            },
            _reachBottomEnable: function(enabled) {
                if (0 === arguments.length) {
                    return this._reachBottomEnabled
                }
                this._$reachBottom.toggle(enabled);
                this._strategy.reachBottomEnable(enabled);
                this._reachBottomEnabled = enabled
            },
            _pullDownHandler: function() {
                this._loadingIndicator(false);
                this._pullDownLoading()
            },
            _loadingIndicator: function(value) {
                if (arguments.length < 1) {
                    return this._loadingIndicatorEnabled
                }
                this._loadingIndicatorEnabled = value
            },
            _pullDownLoading: function() {
                this.startLoading();
                this._pullDownAction()
            },
            _reachBottomHandler: function() {
                this._loadingIndicator(false);
                this._reachBottomLoading()
            },
            _reachBottomLoading: function() {
                this.startLoading();
                this._reachBottomAction()
            },
            _releaseHandler: function() {
                this.finishLoading();
                this._loadingIndicator(true)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onPullDown":
                    case "onReachBottom":
                        this._createActions();
                        break;
                    case "pullingDownText":
                    case "pulledDownText":
                    case "refreshingText":
                    case "refreshStrategy":
                        this._invalidate();
                        break;
                    case "reachBottomText":
                        this._updateReachBottomText();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            isEmpty: function() {
                return !this.content().children().length
            },
            content: function() {
                return this._$content.children().eq(1)
            },
            release: function(preventReachBottom) {
                if (void 0 !== preventReachBottom) {
                    this.toggleLoading(!preventReachBottom)
                }
                return this._strategy.release()
            },
            toggleLoading: function(showOrHide) {
                this._reachBottomEnable(showOrHide)
            },
            isFull: function() {
                return this.content().height() > this._$container.height()
            },
            refresh: function() {
                if (!this.option("onPullDown")) {
                    return
                }
                this._strategy.pendingRelease();
                this._pullDownLoading()
            },
            startLoading: function() {
                if (this._loadingIndicator() && this.element().is(":visible")) {
                    this._loadPanel.show()
                }
                this._lock()
            },
            finishLoading: function() {
                this._loadPanel.hide();
                this._unlock()
            },
            _dispose: function() {
                this._strategy.dispose();
                this.callBase();
                if (this._loadPanel) {
                    this._loadPanel.element().remove()
                }
            }
        });
        registerComponent("dxScrollView", ScrollView);
        exports.ScrollView = ScrollView
    },
    /*!*******************************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scroll_view.native.pull_down.js ***!
      \*******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            NativeStrategy = __webpack_require__( /*! ./ui.scrollable.native */ 229),
            LoadIndicator = __webpack_require__( /*! ../load_indicator */ 231);
        var SCROLLVIEW_PULLDOWN_REFRESHING_CLASS = "dx-scrollview-pull-down-loading",
            SCROLLVIEW_PULLDOWN_READY_CLASS = "dx-scrollview-pull-down-ready",
            SCROLLVIEW_PULLDOWN_IMAGE_CLASS = "dx-scrollview-pull-down-image",
            SCROLLVIEW_PULLDOWN_INDICATOR_CLASS = "dx-scrollview-pull-down-indicator",
            SCROLLVIEW_PULLDOWN_TEXT_CLASS = "dx-scrollview-pull-down-text",
            STATE_RELEASED = 0,
            STATE_READY = 1,
            STATE_REFRESHING = 2,
            STATE_LOADING = 3;
        var PullDownNativeScrollViewStrategy = NativeStrategy.inherit({
            _init: function(scrollView) {
                this.callBase(scrollView);
                this._$topPocket = scrollView._$topPocket;
                this._$pullDown = scrollView._$pullDown;
                this._$bottomPocket = scrollView._$bottomPocket;
                this._$refreshingText = scrollView._$refreshingText;
                this._$scrollViewContent = scrollView.content();
                this._initCallbacks()
            },
            _initCallbacks: function() {
                this.pullDownCallbacks = $.Callbacks();
                this.releaseCallbacks = $.Callbacks();
                this.reachBottomCallbacks = $.Callbacks()
            },
            render: function() {
                this.callBase();
                this._renderPullDown();
                this._releaseState()
            },
            _renderPullDown: function() {
                var $image = $("<div>").addClass(SCROLLVIEW_PULLDOWN_IMAGE_CLASS),
                    $loadContainer = $("<div>").addClass(SCROLLVIEW_PULLDOWN_INDICATOR_CLASS),
                    $loadIndicator = $("<div>")[LoadIndicator.publicName()](),
                    $text = this._$pullDownText = $("<div>").addClass(SCROLLVIEW_PULLDOWN_TEXT_CLASS);
                this._$pullingDownText = $("<div>").text(this.option("pullingDownText")).appendTo($text);
                this._$pulledDownText = $("<div>").text(this.option("pulledDownText")).appendTo($text);
                this._$refreshingText = $("<div>").text(this.option("refreshingText")).appendTo($text);
                this._$pullDown.empty().append($image).append($loadContainer.append($loadIndicator)).append($text)
            },
            _releaseState: function() {
                this._state = STATE_RELEASED;
                this._refreshPullDownText()
            },
            _pushBackFromBoundary: function() {
                if (!this._isLocked() && !this._component.isEmpty()) {
                    this.callBase()
                }
            },
            _refreshPullDownText: function() {
                this._$pullingDownText.css("opacity", this._state === STATE_RELEASED ? 1 : 0);
                this._$pulledDownText.css("opacity", this._state === STATE_READY ? 1 : 0);
                this._$refreshingText.css("opacity", this._state === STATE_REFRESHING ? 1 : 0)
            },
            update: function() {
                this.callBase();
                this._setTopPocketOffset()
            },
            _updateDimensions: function() {
                this.callBase();
                this._topPocketSize = this._$topPocket.height();
                this._bottomPocketSize = this._$bottomPocket.height();
                this._scrollOffset = this._$container.height() - this._$content.height()
            },
            _allowedDirections: function() {
                var allowedDirections = this.callBase();
                allowedDirections.vertical = allowedDirections.vertical || this._pullDownEnabled;
                return allowedDirections
            },
            _setTopPocketOffset: function() {
                this._$topPocket.css({
                    top: -this._topPocketSize
                })
            },
            handleEnd: function() {
                this.callBase();
                this._complete()
            },
            handleStop: function() {
                this.callBase();
                this._complete()
            },
            _complete: function() {
                if (this._state === STATE_READY) {
                    this._setPullDownOffset(this._topPocketSize);
                    clearTimeout(this._pullDownRefreshTimeout);
                    this._pullDownRefreshTimeout = setTimeout($.proxy(function() {
                        this._pullDownRefreshing()
                    }, this), 400)
                }
            },
            _setPullDownOffset: function(offset) {
                translator.move(this._$topPocket, {
                    top: offset
                });
                translator.move(this._$scrollViewContent, {
                    top: offset
                })
            },
            handleScroll: function(e) {
                this.callBase(e);
                if (this._state === STATE_REFRESHING) {
                    return
                }
                this._location = this.location().top;
                if (this._isPullDown()) {
                    this._pullDownReady()
                } else {
                    if (this._isReachBottom()) {
                        this._reachBottom()
                    } else {
                        this._stateReleased()
                    }
                }
            },
            _isPullDown: function() {
                return this._pullDownEnabled && this._location >= this._topPocketSize
            },
            _isReachBottom: function() {
                return this._reachBottomEnabled && this._location <= this._scrollOffset + this._bottomPocketSize
            },
            _reachBottom: function() {
                if (this._state === STATE_LOADING) {
                    return
                }
                this._state = STATE_LOADING;
                this.reachBottomCallbacks.fire()
            },
            _pullDownReady: function() {
                if (this._state === STATE_READY) {
                    return
                }
                this._state = STATE_READY;
                this._$pullDown.addClass(SCROLLVIEW_PULLDOWN_READY_CLASS);
                this._refreshPullDownText()
            },
            _stateReleased: function() {
                if (this._state === STATE_RELEASED) {
                    return
                }
                this._$pullDown.removeClass(SCROLLVIEW_PULLDOWN_REFRESHING_CLASS).removeClass(SCROLLVIEW_PULLDOWN_READY_CLASS);
                this._releaseState()
            },
            _pullDownRefreshing: function() {
                if (this._state === STATE_REFRESHING) {
                    return
                }
                this._state = STATE_REFRESHING;
                this._$pullDown.addClass(SCROLLVIEW_PULLDOWN_REFRESHING_CLASS).removeClass(SCROLLVIEW_PULLDOWN_READY_CLASS);
                this._refreshPullDownText();
                this.pullDownCallbacks.fire()
            },
            pullDownEnable: function(enabled) {
                if (enabled) {
                    this._updateDimensions();
                    this._setTopPocketOffset()
                }
                this._pullDownEnabled = enabled
            },
            reachBottomEnable: function(enabled) {
                this._reachBottomEnabled = enabled
            },
            pendingRelease: function() {
                this._state = STATE_READY
            },
            release: function() {
                var deferred = $.Deferred();
                this._updateDimensions();
                clearTimeout(this._releaseTimeout);
                this._releaseTimeout = setTimeout($.proxy(function() {
                    this._setPullDownOffset(0);
                    this._stateReleased();
                    this.releaseCallbacks.fire();
                    this._updateAction();
                    deferred.resolve()
                }, this), 400);
                return deferred.promise()
            },
            dispose: function() {
                clearTimeout(this._pullDownRefreshTimeout);
                clearTimeout(this._releaseTimeout);
                this.callBase()
            }
        });
        module.exports = PullDownNativeScrollViewStrategy
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scrollable.native.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            Scrollbar = __webpack_require__( /*! ./ui.scrollbar */ 230);
        var SCROLLABLE_NATIVE = "dxNativeScrollable",
            SCROLLABLE_NATIVE_CLASS = "dx-scrollable-native",
            SCROLLABLE_SCROLLBAR_SIMULATED = "dx-scrollable-scrollbar-simulated",
            SCROLLABLE_SCROLLBARS_HIDDEN = "dx-scrollable-scrollbars-hidden",
            VERTICAL = "vertical",
            HORIZONTAL = "horizontal",
            HIDE_SCROLLBAR_TIMOUT = 500;
        var NativeStrategy = Class.inherit({
            ctor: function(scrollable) {
                this._init(scrollable)
            },
            _init: function(scrollable) {
                this._component = scrollable;
                this._$element = scrollable.element();
                this._$container = scrollable._$container;
                this._$content = scrollable._$content;
                this._direction = scrollable.option("direction");
                this._useSimulatedScrollbar = scrollable.option("useSimulatedScrollbar");
                this._showScrollbar = scrollable.option("showScrollbar");
                this.option = $.proxy(scrollable.option, scrollable);
                this._createActionByOption = $.proxy(scrollable._createActionByOption, scrollable);
                this._isLocked = $.proxy(scrollable._isLocked, scrollable);
                this._isDirection = $.proxy(scrollable._isDirection, scrollable);
                this._allowedDirection = $.proxy(scrollable._allowedDirection, scrollable)
            },
            render: function() {
                var device = devices.real(),
                    deviceType = device.platform;
                this._$element.addClass(SCROLLABLE_NATIVE_CLASS).addClass(SCROLLABLE_NATIVE_CLASS + "-" + deviceType).toggleClass(SCROLLABLE_SCROLLBARS_HIDDEN, !this._showScrollbar);
                if (this._showScrollbar && this._useSimulatedScrollbar) {
                    this._renderScrollbars()
                }
            },
            _renderScrollbars: function() {
                this._scrollbars = {};
                this._hideScrollbarTimeout = 0;
                this._$element.addClass(SCROLLABLE_SCROLLBAR_SIMULATED);
                this._renderScrollbar(VERTICAL);
                this._renderScrollbar(HORIZONTAL)
            },
            _renderScrollbar: function(direction) {
                if (!this._isDirection(direction)) {
                    return
                }
                this._scrollbars[direction] = new Scrollbar($("<div>").appendTo(this._$element), {
                    direction: direction,
                    expandable: this._component.option("scrollByThumb")
                })
            },
            handleInit: $.noop,
            handleStart: function() {
                this._disablePushBack = true
            },
            handleMove: function(e) {
                if (this._isLocked()) {
                    e.cancel = true;
                    return
                }
                if (this._allowedDirection()) {
                    e.originalEvent.isScrollingEvent = true
                }
            },
            handleEnd: function() {
                this._disablePushBack = false
            },
            handleStop: $.noop,
            _eachScrollbar: function(callback) {
                callback = $.proxy(callback, this);
                $.each(this._scrollbars || {}, function(direction, scrollbar) {
                    callback(scrollbar, direction)
                })
            },
            createActions: function() {
                this._scrollAction = this._createActionByOption("onScroll");
                this._updateAction = this._createActionByOption("onUpdated")
            },
            _createActionArgs: function() {
                var location = this.location();
                return {
                    jQueryEvent: this._eventForUserAction,
                    scrollOffset: {
                        top: -location.top,
                        left: -location.left
                    },
                    reachedLeft: this._isDirection(HORIZONTAL) ? location.left >= 0 : void 0,
                    reachedRight: this._isDirection(HORIZONTAL) ? location.left <= this._containerSize.width - this._componentContentSize.width : void 0,
                    reachedTop: this._isDirection(VERTICAL) ? location.top >= 0 : void 0,
                    reachedBottom: this._isDirection(VERTICAL) ? location.top <= this._containerSize.height - this._componentContentSize.height : void 0
                }
            },
            handleScroll: function(e) {
                if (!this._isScrollLocationChanged()) {
                    e.stopImmediatePropagation();
                    return
                }
                this._eventForUserAction = e;
                this._moveScrollbars();
                this._scrollAction(this._createActionArgs());
                this._lastLocation = this.location();
                this._pushBackFromBoundary()
            },
            _pushBackFromBoundary: function() {
                var pushBackValue = this.option("pushBackValue");
                if (!pushBackValue || this._disablePushBack) {
                    return
                }
                var scrollOffset = this._containerSize.height - this._contentSize.height,
                    scrollTopPos = this._$container.scrollTop(),
                    scrollBottomPos = scrollOffset + scrollTopPos - 2 * pushBackValue;
                if (!scrollTopPos) {
                    this._$container.scrollTop(pushBackValue)
                } else {
                    if (!scrollBottomPos) {
                        this._$container.scrollTop(pushBackValue - scrollOffset)
                    }
                }
            },
            _isScrollLocationChanged: function() {
                var currentLocation = this.location(),
                    lastLocation = this._lastLocation || {},
                    isTopChanged = lastLocation.top !== currentLocation.top,
                    isLeftChanged = lastLocation.left !== currentLocation.left;
                return isTopChanged || isLeftChanged
            },
            _moveScrollbars: function() {
                this._eachScrollbar(function(scrollbar) {
                    scrollbar.moveTo(this.location());
                    scrollbar.option("visible", true)
                });
                this._hideScrollbars()
            },
            _hideScrollbars: function() {
                clearTimeout(this._hideScrollbarTimeout);
                this._hideScrollbarTimeout = setTimeout($.proxy(function() {
                    this._eachScrollbar(function(scrollbar) {
                        scrollbar.option("visible", false)
                    })
                }, this), HIDE_SCROLLBAR_TIMOUT)
            },
            location: function() {
                return {
                    left: -this._$container.scrollLeft(),
                    top: this.option("pushBackValue") - this._$container.scrollTop()
                }
            },
            disabledChanged: $.noop,
            update: function() {
                this._update();
                this._updateAction(this._createActionArgs())
            },
            _update: function() {
                this._updateDimensions();
                this._updateScrollbars()
            },
            _updateDimensions: function() {
                this._containerSize = {
                    height: this._$container.height(),
                    width: this._$container.width()
                };
                this._componentContentSize = {
                    height: this._component.content().height(),
                    width: this._component.content().width()
                };
                this._contentSize = {
                    height: this._$content.height(),
                    width: this._$content.width()
                };
                this._pushBackFromBoundary()
            },
            _updateScrollbars: function() {
                this._eachScrollbar(function(scrollbar, direction) {
                    var dimension = direction === VERTICAL ? "height" : "width";
                    scrollbar.option({
                        containerSize: this._containerSize[dimension],
                        contentSize: this._componentContentSize[dimension]
                    });
                    scrollbar.update()
                })
            },
            _allowedDirections: function() {
                return {
                    vertical: this._isDirection(VERTICAL) && this._contentSize.height > this._containerSize.height,
                    horizontal: this._isDirection(HORIZONTAL) && this._contentSize.width > this._containerSize.width
                }
            },
            dispose: function() {
                this._$element.removeClass(function(index, className) {
                    var scrollableNativeRegexp = new RegExp(SCROLLABLE_NATIVE_CLASS + "\\S*", "g");
                    if (scrollableNativeRegexp.test(className)) {
                        return className.match(scrollableNativeRegexp).join(" ")
                    }
                });
                this._$element.off("." + SCROLLABLE_NATIVE);
                this._$container.off("." + SCROLLABLE_NATIVE);
                this._removeScrollbars();
                clearTimeout(this._gestureEndTimer);
                clearTimeout(this._hideScrollbarTimeout)
            },
            _removeScrollbars: function() {
                this._eachScrollbar(function(scrollbar) {
                    scrollbar.element().remove()
                })
            },
            scrollBy: function(distance) {
                var location = this.location();
                this._$container.scrollTop(-location.top - distance.top + this.option("pushBackValue"));
                this._$container.scrollLeft(-location.left - distance.left)
            },
            validate: function() {
                return !this.option("disabled") && this._allowedDirection()
            },
            getDirection: function() {
                return this._allowedDirection()
            }
        });
        module.exports = NativeStrategy
    },
    /*!************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scrollbar.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65);
        var SCROLLBAR = "dxScrollbar",
            SCROLLABLE_SCROLLBAR_CLASS = "dx-scrollable-scrollbar",
            SCROLLABLE_SCROLLBAR_ACTIVE_CLASS = SCROLLABLE_SCROLLBAR_CLASS + "-active",
            SCROLLABLE_SCROLL_CLASS = "dx-scrollable-scroll",
            SCROLLABLE_SCROLL_CONTENT_CLASS = "dx-scrollable-scroll-content",
            HOVER_ENABLED_STATE = "dx-scrollbar-hoverable",
            HORIZONTAL = "horizontal",
            THUMB_MIN_SIZE = 15;
        var SCROLLBAR_VISIBLE = {
            onScroll: "onScroll",
            onHover: "onHover",
            always: "always",
            never: "never"
        };
        var Scrollbar = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    direction: null,
                    visible: false,
                    activeStateEnabled: false,
                    visibilityMode: SCROLLBAR_VISIBLE.onScroll,
                    containerSize: 0,
                    contentSize: 0,
                    expandable: true
                })
            },
            _init: function() {
                this.callBase();
                this._isHovered = false
            },
            _render: function() {
                this._renderThumb();
                this.callBase();
                this._renderDirection();
                this._update();
                this._attachPointerDownHandler();
                this.option("hoverStateEnabled", this._isHoverMode());
                this.element().toggleClass(HOVER_ENABLED_STATE, this.option("hoverStateEnabled"))
            },
            _renderThumb: function() {
                this._$thumb = $("<div>").addClass(SCROLLABLE_SCROLL_CLASS);
                $("<div>").addClass(SCROLLABLE_SCROLL_CONTENT_CLASS).appendTo(this._$thumb);
                this.element().addClass(SCROLLABLE_SCROLLBAR_CLASS).append(this._$thumb)
            },
            isThumb: function($element) {
                return !!this.element().find($element).length
            },
            _isHoverMode: function() {
                var visibilityMode = this.option("visibilityMode");
                return (visibilityMode === SCROLLBAR_VISIBLE.onHover || visibilityMode === SCROLLBAR_VISIBLE.always) && this.option("expandable")
            },
            _renderDirection: function() {
                var direction = this.option("direction");
                this.element().addClass("dx-scrollbar-" + direction);
                this._dimension = direction === HORIZONTAL ? "width" : "height";
                this._prop = direction === HORIZONTAL ? "left" : "top"
            },
            _attachPointerDownHandler: function() {
                this._$thumb.on(eventUtils.addNamespace(pointerEvents.down, SCROLLBAR), $.proxy(this.feedbackOn, this))
            },
            feedbackOn: function() {
                this.element().addClass(SCROLLABLE_SCROLLBAR_ACTIVE_CLASS);
                activeScrollbar = this
            },
            feedbackOff: function() {
                this.element().removeClass(SCROLLABLE_SCROLLBAR_ACTIVE_CLASS);
                activeScrollbar = null
            },
            cursorEnter: function() {
                this._isHovered = true;
                this.option("visible", true)
            },
            cursorLeave: function() {
                this._isHovered = false;
                this.option("visible", false)
            },
            _renderDimensions: function() {
                this._$thumb.css({
                    width: this.option("width"),
                    height: this.option("height")
                })
            },
            _toggleVisibility: function(visible) {
                if (this.option("visibilityMode") === SCROLLBAR_VISIBLE.onScroll) {
                    this._$thumb.css("opacity")
                }
                visible = this._adjustVisibility(visible);
                this.option().visible = visible;
                this._$thumb.toggleClass("dx-state-invisible", !visible)
            },
            _adjustVisibility: function(visible) {
                if (this.containerToContentRatio() && !this._needScrollbar()) {
                    return false
                }
                switch (this.option("visibilityMode")) {
                    case SCROLLBAR_VISIBLE.onScroll:
                        break;
                    case SCROLLBAR_VISIBLE.onHover:
                        visible = visible || !!this._isHovered;
                        break;
                    case SCROLLBAR_VISIBLE.never:
                        visible = false;
                        break;
                    case SCROLLBAR_VISIBLE.always:
                        visible = true
                }
                return visible
            },
            moveTo: function(location) {
                if (this._isHidden()) {
                    return
                }
                if ($.isPlainObject(location)) {
                    location = location[this._prop] || 0
                }
                var scrollBarLocation = {
                    left: 0,
                    top: 0
                };
                scrollBarLocation[this._prop] = this._calculateScrollBarPosition(location);
                translator.move(this._$thumb, scrollBarLocation)
            },
            _calculateScrollBarPosition: function(location) {
                return -location * this._thumbRatio
            },
            _update: function() {
                var containerSize = this.option("containerSize"),
                    contentSize = this.option("contentSize");
                this._containerToContentRatio = contentSize ? containerSize / contentSize : containerSize;
                var thumbSize = Math.round(Math.max(Math.round(containerSize * this._containerToContentRatio), THUMB_MIN_SIZE));
                this._thumbRatio = (containerSize - thumbSize) / (contentSize - containerSize);
                this.option(this._dimension, thumbSize);
                this.element().css("display", this._needScrollbar() ? "" : "none")
            },
            _isHidden: function() {
                return this.option("visibilityMode") === SCROLLBAR_VISIBLE.never
            },
            _needScrollbar: function() {
                return !this._isHidden() && this._containerToContentRatio < 1
            },
            containerToContentRatio: function() {
                return this._containerToContentRatio
            },
            _normalizeSize: function(size) {
                return $.isPlainObject(size) ? size[this._dimension] || 0 : size
            },
            _clean: function() {
                this.callBase();
                if (this === activeScrollbar) {
                    activeScrollbar = null
                }
                this._$thumb.off("." + SCROLLBAR)
            },
            _optionChanged: function(args) {
                if (this._isHidden()) {
                    return
                }
                switch (args.name) {
                    case "containerSize":
                    case "contentSize":
                        this.option()[args.name] = this._normalizeSize(args.value);
                        this._update();
                        break;
                    case "visibilityMode":
                    case "direction":
                        this._invalidate();
                        break;
                    default:
                        this.callBase.apply(this, arguments)
                }
            },
            update: commonUtils.deferRenderer(function() {
                this._adjustVisibility() && this.option("visible", true)
            })
        });
        Scrollbar.publicName(SCROLLBAR);
        var activeScrollbar = null;
        $(document).on(eventUtils.addNamespace(pointerEvents.up, SCROLLBAR), function() {
            if (activeScrollbar) {
                activeScrollbar.feedbackOff()
            }
        });
        module.exports = Scrollbar
    },
    /*!**************************************!*\
      !*** ./Scripts/ui/load_indicator.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            support = __webpack_require__( /*! ../core/utils/support */ 48),
            themes = __webpack_require__( /*! ./themes */ 143),
            browser = __webpack_require__( /*! ../core/utils/browser */ 18),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Widget = __webpack_require__( /*! ./widget/ui.widget */ 89);
        var LOADINDICATOR_CLASS = "dx-loadindicator",
            LOADINDICATOR_WRAPPER_CLASS = "dx-loadindicator-wrapper",
            LOADINDICATOR_CONTENT_CLASS = "dx-loadindicator-content",
            LOADINDICATOR_ICON_CLASS = "dx-loadindicator-icon",
            LOADINDICATOR_SEGMENT_CLASS = "dx-loadindicator-segment",
            LOADINDICATOR_SEGMENT_INNER_CLASS = "dx-loadindicator-segment-inner",
            LOADINDICATOR_IMAGE_CLASS = "dx-loadindicator-image";
        var LoadIndicator = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    indicatorSrc: "",
                    activeStateEnabled: false,
                    hoverStateEnabled: false,
                    _animatingSegmentCount: 1,
                    _animatingSegmentInner: false
                })
            },
            _defaultOptionsRules: function() {
                var themeName = function() {
                    var currentTheme = themes.current();
                    return currentTheme && currentTheme.split(".")[0]
                };
                return this.callBase().concat([{
                    device: function() {
                        var realDevice = devices.real(),
                            obsoleteAndroid = "android" === realDevice.platform && !/chrome/i.test(navigator.userAgent);
                        return browser.msie && browser.version < 10 || obsoleteAndroid
                    },
                    options: {
                        viaImage: true
                    }
                }, {
                    device: function() {
                        return "win8" === themeName() || "win10" === themeName()
                    },
                    options: {
                        _animatingSegmentCount: 5
                    }
                }, {
                    device: function() {
                        return "ios7" === themeName()
                    },
                    options: {
                        _animatingSegmentCount: 11
                    }
                }, {
                    device: function() {
                        return "android5" === themeName()
                    },
                    options: {
                        _animatingSegmentCount: 2,
                        _animatingSegmentInner: true
                    }
                }, {
                    device: function() {
                        return "generic" === themeName()
                    },
                    options: {
                        _animatingSegmentCount: 7
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this.element().addClass(LOADINDICATOR_CLASS)
            },
            _render: function() {
                this._renderWrapper();
                this._renderIndicatorContent();
                this._renderMarkup();
                this.callBase()
            },
            _renderWrapper: function() {
                this._$wrapper = $("<div>").addClass(LOADINDICATOR_WRAPPER_CLASS);
                this.element().append(this._$wrapper)
            },
            _renderIndicatorContent: function() {
                this._$content = $("<div>").addClass(LOADINDICATOR_CONTENT_CLASS);
                this._$wrapper.append(this._$content)
            },
            _renderMarkup: function() {
                if (support.animation && !this.option("viaImage") && !this.option("indicatorSrc")) {
                    this._renderMarkupForAnimation()
                } else {
                    this._renderMarkupForImage()
                }
            },
            _renderMarkupForAnimation: function() {
                var animatingSegmentInner = this.option("_animatingSegmentInner");
                this._$indicator = $("<div>").addClass(LOADINDICATOR_ICON_CLASS);
                this._$content.append(this._$indicator);
                for (var i = this.option("_animatingSegmentCount"); i >= 0; --i) {
                    var $segment = $("<div>").addClass(LOADINDICATOR_SEGMENT_CLASS).addClass(LOADINDICATOR_SEGMENT_CLASS + i);
                    if (animatingSegmentInner) {
                        $segment.append($("<div>").addClass(LOADINDICATOR_SEGMENT_INNER_CLASS))
                    }
                    this._$indicator.append($segment)
                }
            },
            _renderMarkupForImage: function() {
                var indicatorSrc = this.option("indicatorSrc");
                this._$wrapper.addClass(LOADINDICATOR_IMAGE_CLASS);
                if (indicatorSrc) {
                    this._$wrapper.css("background-image", "url(" + indicatorSrc + ")")
                }
            },
            _renderDimensions: function() {
                this.callBase();
                this._updateContentSizeForAnimation()
            },
            _updateContentSizeForAnimation: function() {
                if (!this._$indicator) {
                    return
                }
                var width = this.option("width"),
                    height = this.option("height");
                if (width || height) {
                    width = this.element().width();
                    height = this.element().height();
                    var minDimension = Math.min(height, width);
                    this._$wrapper.css({
                        height: minDimension,
                        width: minDimension,
                        "font-size": minDimension
                    })
                }
            },
            _clean: function() {
                this.callBase();
                this._removeMarkupForAnimation();
                this._removeMarkupForImage()
            },
            _removeMarkupForAnimation: function() {
                if (!this._$indicator) {
                    return
                }
                this._$indicator.remove();
                delete this._$indicator
            },
            _removeMarkupForImage: function() {
                this._$wrapper.css("background-image", "none")
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "_animatingSegmentCount":
                    case "_animatingSegmentInner":
                    case "indicatorSrc":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxLoadIndicator", LoadIndicator);
        module.exports = LoadIndicator
    },
    /*!********************************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scroll_view.native.swipe_down.js ***!
      \********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            NativeStrategy = __webpack_require__( /*! ./ui.scrollable.native */ 229),
            LoadIndicator = __webpack_require__( /*! ../load_indicator */ 231);
        var SCROLLVIEW_PULLDOWN_DOWN_LOADING_CLASS = "dx-scrollview-pull-down-loading",
            SCROLLVIEW_PULLDOWN_INDICATOR_CLASS = "dx-scrollview-pull-down-indicator",
            SCROLLVIEW_PULLDOWN_REFRESHING_CLASS = "dx-scrollview-pull-down-refreshing",
            PULLDOWN_ICON_CLASS = "dx-icon-pulldown",
            STATE_RELEASED = 0,
            STATE_READY = 1,
            STATE_REFRESHING = 2,
            STATE_TOUCHED = 4,
            STATE_PULLED = 5;
        var SwipeDownNativeScrollViewStrategy = NativeStrategy.inherit({
            _init: function(scrollView) {
                this.callBase(scrollView);
                this._$topPocket = scrollView._$topPocket;
                this._$bottomPocket = scrollView._$bottomPocket;
                this._$pullDown = scrollView._$pullDown;
                this._$scrollViewContent = scrollView.content();
                this._initCallbacks();
                this._location = 0
            },
            _initCallbacks: function() {
                this.pullDownCallbacks = $.Callbacks();
                this.releaseCallbacks = $.Callbacks();
                this.reachBottomCallbacks = $.Callbacks()
            },
            render: function() {
                this.callBase();
                this._renderPullDown();
                this._releaseState()
            },
            _renderPullDown: function() {
                var $loadContainer = $("<div>").addClass(SCROLLVIEW_PULLDOWN_INDICATOR_CLASS),
                    $loadIndicator = $("<div>")[LoadIndicator.publicName()]();
                this._$icon = $("<div>").addClass(PULLDOWN_ICON_CLASS);
                this._$pullDown.empty().append(this._$icon).append($loadContainer.append($loadIndicator))
            },
            _releaseState: function() {
                this._state = STATE_RELEASED;
                this._releasePullDown();
                this._updateDimensions()
            },
            _releasePullDown: function() {
                this._$pullDown.css({
                    opacity: 0
                })
            },
            _updateDimensions: function() {
                this.callBase();
                this._topPocketSize = this._$topPocket.height();
                this._bottomPocketSize = this._$bottomPocket.height();
                this._scrollOffset = this._$container.height() - this._$content.height()
            },
            _allowedDirections: function() {
                var allowedDirections = this.callBase();
                allowedDirections.vertical = allowedDirections.vertical || this._pullDownEnabled;
                return allowedDirections
            },
            handleInit: function(e) {
                this.callBase(e);
                if (this._state === STATE_RELEASED && 0 === this._location) {
                    this._startClientY = eventUtils.eventData(e.originalEvent).y;
                    this._state = STATE_TOUCHED
                }
            },
            handleMove: function(e) {
                this.callBase(e);
                this._deltaY = eventUtils.eventData(e.originalEvent).y - this._startClientY;
                if (this._state === STATE_TOUCHED) {
                    if (this._pullDownEnabled && this._deltaY > 0) {
                        this._state = STATE_PULLED
                    } else {
                        this._complete()
                    }
                }
                if (this._state === STATE_PULLED) {
                    e.preventDefault();
                    this._movePullDown()
                }
            },
            _movePullDown: function() {
                var pullDownHeight = this._getPullDownHeight(),
                    top = Math.min(3 * pullDownHeight, this._deltaY + this._getPullDownStartPosition()),
                    angle = 180 * top / pullDownHeight / 3;
                this._$pullDown.css({
                    opacity: 1
                }).toggleClass(SCROLLVIEW_PULLDOWN_REFRESHING_CLASS, top < pullDownHeight);
                translator.move(this._$pullDown, {
                    top: top
                });
                this._$icon.css({
                    transform: "rotate(" + angle + "deg)"
                })
            },
            _isPullDown: function() {
                return this._pullDownEnabled && this._state === STATE_PULLED && this._deltaY >= this._getPullDownHeight() - this._getPullDownStartPosition()
            },
            _getPullDownHeight: function() {
                return Math.round(.05 * this._$element.outerHeight())
            },
            _getPullDownStartPosition: function() {
                return -Math.round(1.5 * this._$pullDown.outerHeight())
            },
            handleEnd: function() {
                if (this._isPullDown()) {
                    this._pullDownRefreshing()
                }
                this._complete()
            },
            handleStop: function() {
                this._complete()
            },
            _complete: function() {
                if (this._state === STATE_TOUCHED || this._state === STATE_PULLED) {
                    this._releaseState()
                }
            },
            handleScroll: function(e) {
                this.callBase(e);
                if (this._state === STATE_REFRESHING) {
                    return
                }
                var currentLocation = this.location().top,
                    scrollDelta = this._location - currentLocation;
                this._location = currentLocation;
                if (scrollDelta > 0 && this._isReachBottom()) {
                    this._reachBottom()
                } else {
                    this._stateReleased()
                }
            },
            _isReachBottom: function() {
                return this._reachBottomEnabled && this._location <= this._scrollOffset + this._bottomPocketSize
            },
            _reachBottom: function() {
                this.reachBottomCallbacks.fire()
            },
            _stateReleased: function() {
                if (this._state === STATE_RELEASED) {
                    return
                }
                this._$pullDown.removeClass(SCROLLVIEW_PULLDOWN_DOWN_LOADING_CLASS);
                this._releaseState()
            },
            _pullDownRefreshing: function() {
                this._state = STATE_REFRESHING;
                this._pullDownRefreshHandler()
            },
            _pullDownRefreshHandler: function() {
                this._refreshPullDown();
                this.pullDownCallbacks.fire()
            },
            _refreshPullDown: function() {
                this._$pullDown.addClass(SCROLLVIEW_PULLDOWN_DOWN_LOADING_CLASS);
                translator.move(this._$pullDown, {
                    top: this._getPullDownHeight()
                })
            },
            pullDownEnable: function(enabled) {
                this._$topPocket.toggle(enabled);
                this._pullDownEnabled = enabled
            },
            reachBottomEnable: function(enabled) {
                this._reachBottomEnabled = enabled
            },
            pendingRelease: function() {
                this._state = STATE_READY
            },
            release: function() {
                var deferred = $.Deferred();
                this._updateDimensions();
                clearTimeout(this._releaseTimeout);
                this._releaseTimeout = setTimeout($.proxy(function() {
                    this._stateReleased();
                    this.releaseCallbacks.fire();
                    this._updateAction();
                    deferred.resolve()
                }, this), 800);
                return deferred.promise()
            },
            dispose: function() {
                clearTimeout(this._pullDownRefreshTimeout);
                clearTimeout(this._releaseTimeout);
                this.callBase()
            }
        });
        module.exports = SwipeDownNativeScrollViewStrategy
    },
    /*!********************************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scroll_view.native.slide_down.js ***!
      \********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            NativeStrategy = __webpack_require__( /*! ./ui.scrollable.native */ 229);
        var STATE_RELEASED = 0,
            STATE_READY = 1,
            STATE_LOADING = 2,
            LOADING_HEIGHT = 80;
        var SlideDownNativeScrollViewStrategy = NativeStrategy.inherit({
            _init: function(scrollView) {
                this.callBase(scrollView);
                this._$topPocket = scrollView._$topPocket;
                this._$bottomPocket = scrollView._$bottomPocket;
                this._initCallbacks()
            },
            _initCallbacks: function() {
                this.pullDownCallbacks = $.Callbacks();
                this.releaseCallbacks = $.Callbacks();
                this.reachBottomCallbacks = $.Callbacks()
            },
            render: function() {
                this.callBase();
                this._renderPullDown();
                this._renderBottom();
                this._releaseState();
                this._updateDimensions()
            },
            _renderPullDown: function() {
                this._$topPocket.empty()
            },
            _renderBottom: function() {
                this._$bottomPocket.empty().append("<progress>")
            },
            _releaseState: function() {
                if (this._state === STATE_RELEASED) {
                    return
                }
                this._state = STATE_RELEASED
            },
            _updateDimensions: function() {
                this._scrollOffset = this._$container.prop("scrollHeight") - this._$container.prop("clientHeight");
                this._containerSize = {
                    height: this._$container.prop("clientHeight"),
                    width: this._$container.prop("clientWidth")
                };
                this._contentSize = this._componentContentSize = {
                    height: this._$container.prop("scrollHeight"),
                    width: this._$container.prop("scrollWidth")
                }
            },
            handleScroll: function(e) {
                this.callBase(e);
                if (this._isReachBottom(this._lastLocation.top)) {
                    this._reachBottom()
                }
            },
            _isReachBottom: function(location) {
                this._scrollContent = this._$container.prop("scrollHeight") - this._$container.prop("clientHeight");
                return this._reachBottomEnabled && location < -this._scrollContent + LOADING_HEIGHT
            },
            _reachBottom: function() {
                if (this._state === STATE_LOADING) {
                    return
                }
                this._state = STATE_LOADING;
                this.reachBottomCallbacks.fire()
            },
            pullDownEnable: function(enabled) {
                this._pullDownEnabled = enabled
            },
            reachBottomEnable: function(enabled) {
                this._reachBottomEnabled = enabled;
                this._$bottomPocket.toggle(enabled)
            },
            pendingRelease: function() {
                this._state = STATE_READY
            },
            release: function() {
                var deferred = $.Deferred();
                this._state = STATE_RELEASED;
                this.releaseCallbacks.fire();
                this.update();
                return deferred.resolve().promise()
            }
        });
        module.exports = SlideDownNativeScrollViewStrategy
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scroll_view.simulated.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            math = Math,
            simulatedStrategy = __webpack_require__( /*! ./ui.scrollable.simulated */ 235),
            LoadIndicator = __webpack_require__( /*! ../load_indicator */ 231);
        var SCROLLVIEW_PULLDOWN_REFRESHING_CLASS = "dx-scrollview-pull-down-loading",
            SCROLLVIEW_PULLDOWN_READY_CLASS = "dx-scrollview-pull-down-ready",
            SCROLLVIEW_PULLDOWN_IMAGE_CLASS = "dx-scrollview-pull-down-image",
            SCROLLVIEW_PULLDOWN_INDICATOR_CLASS = "dx-scrollview-pull-down-indicator",
            SCROLLVIEW_PULLDOWN_TEXT_CLASS = "dx-scrollview-pull-down-text",
            STATE_RELEASED = 0,
            STATE_READY = 1,
            STATE_REFRESHING = 2,
            STATE_LOADING = 3;
        var ScrollViewScroller = simulatedStrategy.Scroller.inherit({
            ctor: function() {
                this.callBase.apply(this, arguments);
                this._initCallbacks();
                this._releaseState()
            },
            _releaseState: function() {
                this._state = STATE_RELEASED;
                this._refreshPullDownText()
            },
            _refreshPullDownText: function() {
                this._$pullingDownText.css("opacity", this._state === STATE_RELEASED ? 1 : 0);
                this._$pulledDownText.css("opacity", this._state === STATE_READY ? 1 : 0);
                this._$refreshingText.css("opacity", this._state === STATE_REFRESHING ? 1 : 0)
            },
            _initCallbacks: function() {
                this.pullDownCallbacks = $.Callbacks();
                this.releaseCallbacks = $.Callbacks();
                this.reachBottomCallbacks = $.Callbacks()
            },
            _updateBounds: function() {
                var considerPockets = "horizontal" !== this._direction;
                this._topPocketSize = considerPockets ? this._$topPocket[this._dimension]() : 0;
                this._bottomPocketSize = considerPockets ? this._$bottomPocket[this._dimension]() : 0;
                this.callBase();
                this._bottomBound = this._minOffset + this._bottomPocketSize
            },
            _updateScrollbar: function() {
                this._scrollbar.option({
                    containerSize: this._containerSize(),
                    contentSize: this._contentSize() - this._topPocketSize - this._bottomPocketSize
                })
            },
            _moveContent: function() {
                this.callBase();
                if (this._isPullDown()) {
                    this._pullDownReady()
                } else {
                    if (this._isReachBottom()) {
                        this._reachBottomReady()
                    } else {
                        if (this._state !== STATE_RELEASED) {
                            this._stateReleased()
                        }
                    }
                }
            },
            _moveScrollbar: function() {
                this._scrollbar.moveTo(this._topPocketSize + this._location)
            },
            _isPullDown: function() {
                return this._pullDownEnabled && this._location >= 0
            },
            _isReachBottom: function() {
                return this._reachBottomEnabled && this._location <= this._bottomBound
            },
            _scrollComplete: function() {
                if (this._inBounds() && this._state === STATE_READY) {
                    this._pullDownRefreshing()
                } else {
                    if (this._inBounds() && this._state === STATE_LOADING) {
                        this._reachBottomLoading()
                    } else {
                        this.callBase()
                    }
                }
            },
            _reachBottomReady: function() {
                if (this._state === STATE_LOADING) {
                    return
                }
                this._state = STATE_LOADING;
                this._minOffset = this._getMinOffset()
            },
            _getMaxOffset: function() {
                return -this._topPocketSize
            },
            _getMinOffset: function() {
                return math.min(this.callBase(), -this._topPocketSize)
            },
            _reachBottomLoading: function() {
                this.reachBottomCallbacks.fire()
            },
            _pullDownReady: function() {
                if (this._state === STATE_READY) {
                    return
                }
                this._state = STATE_READY;
                this._maxOffset = 0;
                this._$pullDown.addClass(SCROLLVIEW_PULLDOWN_READY_CLASS);
                this._refreshPullDownText()
            },
            _stateReleased: function() {
                if (this._state === STATE_RELEASED) {
                    return
                }
                this._releaseState();
                this._updateBounds();
                this._$pullDown.removeClass(SCROLLVIEW_PULLDOWN_REFRESHING_CLASS).removeClass(SCROLLVIEW_PULLDOWN_READY_CLASS);
                this.releaseCallbacks.fire()
            },
            _pullDownRefreshing: function() {
                if (this._state === STATE_REFRESHING) {
                    return
                }
                this._state = STATE_REFRESHING;
                this._$pullDown.addClass(SCROLLVIEW_PULLDOWN_REFRESHING_CLASS).removeClass(SCROLLVIEW_PULLDOWN_READY_CLASS);
                this._refreshPullDownText();
                this.pullDownCallbacks.fire()
            },
            _releaseHandler: function() {
                if (this._state === STATE_RELEASED) {
                    this._moveToBounds()
                }
                this._update();
                if (this._releaseTask) {
                    this._releaseTask.abort()
                }
                this._releaseTask = commonUtils.executeAsync($.proxy(this._release, this));
                return this._releaseTask.promise
            },
            _release: function() {
                this._stateReleased();
                this._scrollComplete()
            },
            _reachBottomEnablingHandler: function(enabled) {
                if (this._reachBottomEnabled === enabled) {
                    return
                }
                this._reachBottomEnabled = enabled;
                this._updateBounds()
            },
            _pullDownEnablingHandler: function(enabled) {
                if (this._pullDownEnabled === enabled) {
                    return
                }
                this._pullDownEnabled = enabled;
                this._considerTopPocketChange();
                this._updateHandler()
            },
            _considerTopPocketChange: function() {
                this._location -= this._$topPocket.height() || -this._topPocketSize;
                this._move()
            },
            _pendingReleaseHandler: function() {
                this._state = STATE_READY
            },
            dispose: function() {
                if (this._releaseTask) {
                    this._releaseTask.abort()
                }
                this.callBase()
            }
        });
        var SimulatedScrollViewStrategy = simulatedStrategy.SimulatedStrategy.inherit({
            _init: function(scrollView) {
                this.callBase(scrollView);
                this._$pullDown = scrollView._$pullDown;
                this._$topPocket = scrollView._$topPocket;
                this._$bottomPocket = scrollView._$bottomPocket;
                this._initCallbacks()
            },
            _initCallbacks: function() {
                this.pullDownCallbacks = $.Callbacks();
                this.releaseCallbacks = $.Callbacks();
                this.reachBottomCallbacks = $.Callbacks()
            },
            render: function() {
                this._renderPullDown();
                this.callBase()
            },
            _renderPullDown: function() {
                var $image = $("<div>").addClass(SCROLLVIEW_PULLDOWN_IMAGE_CLASS),
                    $loadContainer = $("<div>").addClass(SCROLLVIEW_PULLDOWN_INDICATOR_CLASS),
                    $loadIndicator = $("<div>")[LoadIndicator.publicName()](),
                    $text = this._$pullDownText = $("<div>").addClass(SCROLLVIEW_PULLDOWN_TEXT_CLASS);
                this._$pullingDownText = $("<div>").text(this.option("pullingDownText")).appendTo($text);
                this._$pulledDownText = $("<div>").text(this.option("pulledDownText")).appendTo($text);
                this._$refreshingText = $("<div>").text(this.option("refreshingText")).appendTo($text);
                this._$pullDown.empty().append($image).append($loadContainer.append($loadIndicator)).append($text)
            },
            pullDownEnable: function(enabled) {
                this._eventHandler("pullDownEnabling", enabled)
            },
            reachBottomEnable: function(enabled) {
                this._eventHandler("reachBottomEnabling", enabled)
            },
            _createScroller: function(direction) {
                var that = this;
                var scroller = that._scrollers[direction] = new ScrollViewScroller(that._scrollerOptions(direction));
                scroller.pullDownCallbacks.add(function() {
                    that.pullDownCallbacks.fire()
                });
                scroller.releaseCallbacks.add(function() {
                    that.releaseCallbacks.fire()
                });
                scroller.reachBottomCallbacks.add(function() {
                    that.reachBottomCallbacks.fire()
                })
            },
            _scrollerOptions: function(direction) {
                return $.extend(this.callBase(direction), {
                    $topPocket: this._$topPocket,
                    $bottomPocket: this._$bottomPocket,
                    $pullDown: this._$pullDown,
                    $pullDownText: this._$pullDownText,
                    $pullingDownText: this._$pullingDownText,
                    $pulledDownText: this._$pulledDownText,
                    $refreshingText: this._$refreshingText
                })
            },
            pendingRelease: function() {
                this._eventHandler("pendingRelease")
            },
            release: function() {
                return this._eventHandler("release").done(this._updateAction)
            },
            location: function() {
                var location = this.callBase();
                location.top += this._$topPocket.height();
                return location
            },
            dispose: function() {
                $.each(this._scrollers, function() {
                    this.dispose()
                });
                this.callBase()
            }
        });
        module.exports = SimulatedScrollViewStrategy
    },
    /*!***********************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scrollable.simulated.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            math = Math,
            titleize = __webpack_require__( /*! ../../core/utils/inflector */ 49).titleize,
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            Animator = __webpack_require__( /*! ./animator */ 236),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            Scrollbar = __webpack_require__( /*! ./ui.scrollbar */ 230);
        var realDevice = devices.real;
        var isSluggishPlatform = "win" === realDevice.platform || "android" === realDevice.platform;
        var SCROLLABLE_SIMULATED = "dxSimulatedScrollable",
            SCROLLABLE_STRATEGY = "dxScrollableStrategy",
            SCROLLABLE_SIMULATED_CURSOR = SCROLLABLE_SIMULATED + "Cursor",
            SCROLLABLE_SIMULATED_KEYBOARD = SCROLLABLE_SIMULATED + "Keyboard",
            SCROLLABLE_SIMULATED_CLASS = "dx-scrollable-simulated",
            SCROLLABLE_SCROLLBARS_HIDDEN = "dx-scrollable-scrollbars-hidden",
            SCROLLABLE_SCROLLBARS_ALWAYSVISIBLE = "dx-scrollable-scrollbars-alwaysvisible",
            SCROLLABLE_SCROLLBAR_CLASS = "dx-scrollable-scrollbar",
            VERTICAL = "vertical",
            HORIZONTAL = "horizontal",
            ACCELERATION = isSluggishPlatform ? .95 : .92,
            OUT_BOUNDS_ACCELERATION = .5,
            MIN_VELOCITY_LIMIT = 1,
            FRAME_DURATION = math.round(1e3 / 60),
            SCROLL_LINE_HEIGHT = 20,
            BOUNCE_MIN_VELOCITY_LIMIT = MIN_VELOCITY_LIMIT / 5,
            BOUNCE_DURATION = isSluggishPlatform ? 300 : 400,
            BOUNCE_FRAMES = BOUNCE_DURATION / FRAME_DURATION,
            BOUNCE_ACCELERATION_SUM = (1 - math.pow(ACCELERATION, BOUNCE_FRAMES)) / (1 - ACCELERATION);
        var KEY_CODES = {
            PAGE_UP: 33,
            PAGE_DOWN: 34,
            END: 35,
            HOME: 36,
            LEFT: 37,
            UP: 38,
            RIGHT: 39,
            DOWN: 40
        };
        var scrollIntoViewIfNeededCallbacks = function() {
            var callbacks = $.Callbacks();
            var FOCUS_TIMEOUT = 50,
                cancelChangeTimestamp = null;
            $(window).on(eventUtils.addNamespace("focus", SCROLLABLE_STRATEGY), function() {
                cancelChangeTimestamp = $.now()
            });
            $(document).on(eventUtils.addNamespace(pointerEvents.down, SCROLLABLE_STRATEGY), function() {
                cancelChangeTimestamp = $.now()
            });
            var focusChange = function(e) {
                var keyboardElementChange = $.now() - cancelChangeTimestamp > FOCUS_TIMEOUT,
                    focusedCorrectElement = e.target === document.activeElement;
                if (keyboardElementChange && focusedCorrectElement) {
                    callbacks.fire(e.target)
                }
            };
            if (window.addEventListener) {
                var asyncFocus = "onactivate" in document;
                if (asyncFocus) {
                    window.addEventListener("activate", focusChange, true)
                } else {
                    window.addEventListener("focus", focusChange, true)
                }
            } else {
                window.attachEvent("onfocusin", focusChange)
            }
            return callbacks
        }();
        var InertiaAnimator = Animator.inherit({
            ctor: function(scroller) {
                this.callBase();
                this.scroller = scroller
            },
            VELOCITY_LIMIT: MIN_VELOCITY_LIMIT,
            _isFinished: function() {
                return math.abs(this.scroller._velocity) <= this.VELOCITY_LIMIT
            },
            _step: function() {
                this.scroller._scrollStep(this.scroller._velocity);
                this.scroller._velocity *= this._acceleration()
            },
            _acceleration: function() {
                return this.scroller._inBounds() ? ACCELERATION : OUT_BOUNDS_ACCELERATION
            },
            _complete: function() {
                this.scroller._scrollComplete()
            },
            _stop: function() {
                this.scroller._stopComplete()
            }
        });
        var BounceAnimator = InertiaAnimator.inherit({
            VELOCITY_LIMIT: BOUNCE_MIN_VELOCITY_LIMIT,
            _isFinished: function() {
                return this.scroller._crossBoundOnNextStep() || this.callBase()
            },
            _acceleration: function() {
                return ACCELERATION
            },
            _complete: function() {
                this.scroller._move(this.scroller._bounceLocation);
                this.callBase()
            }
        });
        var isWheelEvent = function(e) {
            return "dxmousewheel" === e.type
        };
        var Scroller = Class.inherit({
            ctor: function(options) {
                this._initOptions(options);
                this._initAnimators();
                this._initScrollbar()
            },
            _initOptions: function(options) {
                this._location = 0;
                this._topReached = false;
                this._bottomReached = false;
                this._axis = options.direction === HORIZONTAL ? "x" : "y";
                this._prop = options.direction === HORIZONTAL ? "left" : "top";
                this._dimension = options.direction === HORIZONTAL ? "width" : "height";
                this._scrollProp = options.direction === HORIZONTAL ? "scrollLeft" : "scrollTop";
                this._pushBackCorrection = options.direction === VERTICAL ? 2 * options.pushBackValue : 0;
                $.each(options, $.proxy(function(optionName, optionValue) {
                    this["_" + optionName] = optionValue
                }, this))
            },
            _initAnimators: function() {
                this._inertiaAnimator = new InertiaAnimator(this);
                this._bounceAnimator = new BounceAnimator(this)
            },
            _initScrollbar: function() {
                this._scrollbar = new Scrollbar($("<div>").appendTo(this._$container), {
                    direction: this._direction,
                    visible: this._scrollByThumb,
                    visibilityMode: this._visibilityModeNormalize(this._scrollbarVisible),
                    expandable: this._scrollByThumb
                });
                this._$scrollbar = this._scrollbar.element()
            },
            _visibilityModeNormalize: function(mode) {
                return true === mode ? "onScroll" : false === mode ? "never" : mode
            },
            _scrollStep: function(delta) {
                var prevLocation = this._location;
                this._location += delta;
                this._suppressBounce();
                this._move();
                if (Math.abs(prevLocation - this._location) < 1) {
                    return
                }
                this._scrollAction();
                this._$container.triggerHandler({
                    type: "scroll",
                    simulated: true
                })
            },
            _suppressBounce: function() {
                if (this._bounceEnabled || this._inBounds(this._location)) {
                    return
                }
                this._velocity = 0;
                this._location = this._boundLocation()
            },
            _boundLocation: function(location) {
                location = void 0 !== location ? location : this._location;
                return math.max(math.min(location, this._maxOffset), this._minOffset)
            },
            _move: function(location) {
                this._location = void 0 !== location ? location : this._location;
                this._moveContent();
                this._moveScrollbar()
            },
            _moveContent: function() {
                var targetLocation = {};
                targetLocation[this._prop] = this._location;
                translator.move(this._$content, targetLocation)
            },
            _moveScrollbar: function() {
                this._scrollbar.moveTo(this._location)
            },
            _scrollComplete: function() {
                if (this._inBounds()) {
                    this._hideScrollbar();
                    this._correctLocation();
                    if (this._completeDeferred) {
                        this._completeDeferred.resolve()
                    }
                }
                this._scrollToBounds()
            },
            _correctLocation: function() {
                this._location = math.round(this._location);
                this._move()
            },
            _scrollToBounds: function() {
                if (this._inBounds()) {
                    return
                }
                this._bounceAction();
                this._setupBounce();
                this._bounceAnimator.start()
            },
            _setupBounce: function() {
                var boundLocation = this._bounceLocation = this._boundLocation(),
                    bounceDistance = boundLocation - this._location;
                this._velocity = bounceDistance / BOUNCE_ACCELERATION_SUM
            },
            _inBounds: function(location) {
                location = void 0 !== location ? location : this._location;
                return this._boundLocation(location) === location
            },
            _crossBoundOnNextStep: function() {
                var location = this._location,
                    nextLocation = location + this._velocity;
                return location < this._minOffset && nextLocation >= this._minOffset || location > this._maxOffset && nextLocation <= this._maxOffset
            },
            _initHandler: function(e) {
                this._stopDeferred = $.Deferred();
                this._stopScrolling();
                this._prepareThumbScrolling(e);
                return this._stopDeferred.promise()
            },
            _stopScrolling: commonUtils.deferRenderer(function() {
                this._hideScrollbar();
                this._inertiaAnimator.stop();
                this._bounceAnimator.stop()
            }),
            _prepareThumbScrolling: function(e) {
                if (isWheelEvent(e.originalEvent)) {
                    return
                }
                var $target = $(e.originalEvent.target);
                var scrollbarClicked = this._isScrollbar($target);
                if (scrollbarClicked) {
                    this._moveToMouseLocation(e)
                }
                this._thumbScrolling = scrollbarClicked || this._isThumb($target);
                this._crossThumbScrolling = !this._thumbScrolling && this._isAnyThumbScrolling($target);
                if (this._thumbScrolling) {
                    this._scrollbar.feedbackOn()
                }
            },
            _isThumbScrollingHandler: function($target) {
                return this._isThumb($target)
            },
            _moveToMouseLocation: function(e) {
                var mouseLocation = e["page" + this._axis.toUpperCase()] - this._$element.offset()[this._prop];
                var location = this._location + mouseLocation / this._containerToContentRatio() - this._$container.height() / 2;
                this._scrollStep(-location)
            },
            _stopComplete: function() {
                if (this._stopDeferred) {
                    this._stopDeferred.resolve()
                }
            },
            _startHandler: function() {
                this._showScrollbar()
            },
            _moveHandler: function(delta) {
                if (this._crossThumbScrolling) {
                    return
                }
                if (this._thumbScrolling) {
                    delta[this._axis] = -delta[this._axis] / this._containerToContentRatio()
                }
                this._scrollBy(delta)
            },
            _scrollBy: function(delta) {
                delta = delta[this._axis];
                if (!this._inBounds()) {
                    delta *= OUT_BOUNDS_ACCELERATION
                }
                this._scrollStep(delta)
            },
            _scrollByHandler: function(delta) {
                this._scrollBy(delta);
                this._scrollComplete()
            },
            _containerToContentRatio: function() {
                return this._scrollbar.containerToContentRatio()
            },
            _endHandler: function(velocity) {
                this._completeDeferred = $.Deferred();
                this._velocity = velocity[this._axis];
                this._inertiaHandler();
                this._resetThumbScrolling();
                return this._completeDeferred.promise()
            },
            _inertiaHandler: function() {
                this._suppressInertia();
                this._inertiaAnimator.start()
            },
            _suppressInertia: function() {
                if (!this._inertiaEnabled || this._thumbScrolling) {
                    this._velocity = 0
                }
            },
            _resetThumbScrolling: function() {
                this._thumbScrolling = false;
                this._crossThumbScrolling = false
            },
            _stopHandler: function() {
                if (this._thumbScrolling) {
                    this._scrollComplete()
                }
                this._resetThumbScrolling();
                this._scrollToBounds()
            },
            _disposeHandler: function() {
                this._stopScrolling();
                this._$scrollbar.remove()
            },
            _updateHandler: function() {
                this._update();
                this._moveToBounds()
            },
            _update: function() {
                var that = this;
                that._stopScrolling();
                commonUtils.deferUpdate(function() {
                    that._updateLocation();
                    that._updateBounds();
                    that._updateScrollbar();
                    commonUtils.deferRender(function() {
                        that._moveScrollbar();
                        that._scrollbar.update()
                    })
                })
            },
            _updateLocation: function() {
                this._location = translator.locate(this._$content)[this._prop]
            },
            _updateBounds: function() {
                this._maxOffset = this._getMaxOffset();
                this._minOffset = this._getMinOffset()
            },
            _getMaxOffset: function() {
                return 0
            },
            _getMinOffset: function() {
                return math.min(this._containerSize() - this._contentSize(), 0)
            },
            _updateScrollbar: commonUtils.deferUpdater(function() {
                var that = this,
                    containerSize = that._containerSize(),
                    contentSize = that._contentSize();
                commonUtils.deferRender(function() {
                    that._scrollbar.option({
                        containerSize: containerSize,
                        contentSize: contentSize
                    })
                })
            }),
            _moveToBounds: commonUtils.deferRenderer(commonUtils.deferUpdater(commonUtils.deferRenderer(function() {
                var location = this._boundLocation();
                var locationChanged = location !== this._location;
                this._location = location;
                this._move();
                if (locationChanged) {
                    this._scrollAction()
                }
            }))),
            _createActionsHandler: function(actions) {
                this._scrollAction = actions.scroll;
                this._bounceAction = actions.bounce
            },
            _showScrollbar: function() {
                this._scrollbar.option("visible", true)
            },
            _hideScrollbar: function() {
                this._scrollbar.option("visible", false)
            },
            _containerSize: function() {
                return this._$container[this._dimension]()
            },
            _contentSize: function() {
                var isOverflowHidden = "hidden" === this._$content.css("overflow-" + this._axis),
                    contentSize = this._$content[this._dimension]();
                if (!isOverflowHidden) {
                    var containerScrollSize = this._$content[0]["scroll" + titleize(this._dimension)];
                    contentSize = math.max(containerScrollSize - this._pushBackCorrection, contentSize)
                }
                return contentSize
            },
            _validateEvent: function(e) {
                var $target = $(e.originalEvent.target);
                if (this._isThumb($target) || this._isScrollbar($target)) {
                    e.preventDefault();
                    return true
                }
                return this._isContent($target)
            },
            _isThumb: function($element) {
                return this._scrollByThumb && this._scrollbar.isThumb($element)
            },
            _isScrollbar: function($element) {
                return this._scrollByThumb && $element && $element.is(this._$scrollbar)
            },
            _isContent: function($element) {
                return this._scrollByContent && !!$element.closest(this._$element).length
            },
            _reachedMin: function() {
                return this._location <= this._minOffset
            },
            _reachedMax: function() {
                return this._location >= this._maxOffset
            },
            _cursorEnterHandler: function() {
                this._scrollbar.cursorEnter()
            },
            _cursorLeaveHandler: function() {
                this._scrollbar.cursorLeave()
            },
            dispose: $.noop
        });
        var hoveredScrollable, activeScrollable;
        var SimulatedStrategy = Class.inherit({
            ctor: function(scrollable) {
                this._init(scrollable)
            },
            _init: function(scrollable) {
                this._component = scrollable;
                this._$element = scrollable.element();
                this._$container = scrollable._$container;
                this._$content = scrollable._$content;
                this.option = $.proxy(scrollable.option, scrollable);
                this._createActionByOption = $.proxy(scrollable._createActionByOption, scrollable);
                this._isLocked = $.proxy(scrollable._isLocked, scrollable);
                this._isDirection = $.proxy(scrollable._isDirection, scrollable);
                this._allowedDirection = $.proxy(scrollable._allowedDirection, scrollable);
                this._proxiedActiveElementChangeHandler = $.proxy(this._activeElementChangeHandler, this);
                scrollIntoViewIfNeededCallbacks.add(this._proxiedActiveElementChangeHandler)
            },
            _activeElementChangeHandler: function(activeElement) {
                this._component.scrollToElement(activeElement)
            },
            render: function() {
                this._$element.addClass(SCROLLABLE_SIMULATED_CLASS);
                this._createScrollers();
                if (this.option("useKeyboard")) {
                    this._$container.prop("tabindex", 0)
                }
                this._attachKeyboardHandler();
                this._attachCursorHandlers()
            },
            _createScrollers: function() {
                this._scrollers = {};
                if (this._isDirection(HORIZONTAL)) {
                    this._createScroller(HORIZONTAL)
                }
                if (this._isDirection(VERTICAL)) {
                    this._createScroller(VERTICAL)
                }
                this._$element.toggleClass(SCROLLABLE_SCROLLBARS_ALWAYSVISIBLE, "always" === this.option("showScrollbar"));
                this._$element.toggleClass(SCROLLABLE_SCROLLBARS_HIDDEN, !this.option("showScrollbar"))
            },
            _createScroller: function(direction) {
                this._scrollers[direction] = new Scroller(this._scrollerOptions(direction))
            },
            _scrollerOptions: function(direction) {
                return {
                    direction: direction,
                    $content: this._$content,
                    $container: this._$container,
                    $element: this._$element,
                    scrollByContent: this.option("scrollByContent"),
                    scrollByThumb: this.option("scrollByThumb"),
                    scrollbarVisible: this.option("showScrollbar"),
                    bounceEnabled: this.option("bounceEnabled"),
                    inertiaEnabled: this.option("inertiaEnabled"),
                    isAnyThumbScrolling: $.proxy(this._isAnyThumbScrolling, this),
                    pushBackValue: this.option("pushBackValue")
                }
            },
            _isAnyThumbScrolling: function($target) {
                var result = false;
                this._eventHandler("isThumbScrolling", $target).done(function(isThumbScrollingVertical, isThumbScrollingHorizontal) {
                    result = isThumbScrollingVertical || isThumbScrollingHorizontal
                });
                return result
            },
            handleInit: function(e) {
                this._suppressDirections(e);
                this._eventForUserAction = e;
                this._eventHandler("init", e).done(this._stopAction)
            },
            _suppressDirections: function(e) {
                if (isWheelEvent(e.originalEvent)) {
                    this._prepareDirections(true);
                    return
                }
                this._prepareDirections();
                this._eachScroller(function(scroller, direction) {
                    var isValid = scroller._validateEvent(e);
                    this._validDirections[direction] = isValid
                })
            },
            _prepareDirections: function(value) {
                value = value || false;
                this._validDirections = {};
                this._validDirections[HORIZONTAL] = value;
                this._validDirections[VERTICAL] = value
            },
            _eachScroller: function(callback) {
                callback = $.proxy(callback, this);
                $.each(this._scrollers, function(direction, scroller) {
                    callback(scroller, direction)
                })
            },
            handleStart: function(e) {
                this._eventForUserAction = e;
                this._eventHandler("start").done(this._startAction)
            },
            _saveActive: function() {
                activeScrollable = this
            },
            _resetActive: function() {
                if (activeScrollable === this) {
                    activeScrollable = null
                }
            },
            handleMove: function(e) {
                if (this._isLocked()) {
                    e.cancel = true;
                    this._resetActive();
                    return
                }
                this._saveActive();
                e.preventDefault && e.preventDefault();
                this._adjustDistance(e.delta);
                this._eventForUserAction = e;
                this._eventHandler("move", e.delta)
            },
            _adjustDistance: function(distance) {
                distance.x *= this._validDirections[HORIZONTAL];
                distance.y *= this._validDirections[VERTICAL]
            },
            handleEnd: function(e) {
                this._resetActive();
                this._refreshCursorState(e.originalEvent && e.originalEvent.target);
                this._adjustDistance(e.velocity);
                this._eventForUserAction = e;
                return this._eventHandler("end", e.velocity).done(this._endAction)
            },
            handleCancel: function(e) {
                this._resetActive();
                this._eventForUserAction = e;
                return this._eventHandler("end", {
                    x: 0,
                    y: 0
                })
            },
            handleStop: function() {
                this._resetActive();
                this._eventHandler("stop")
            },
            handleScroll: function(e) {
                if (e.simulated) {
                    return
                }
                var distance = {
                    left: this.option("direction") !== VERTICAL ? -this._$container.scrollLeft() : 0,
                    top: this.option("direction") !== HORIZONTAL ? -this._$container.scrollTop() : 0
                };
                if (!distance.left && !distance.top) {
                    return
                }
                this._$container.scrollLeft(0);
                this._$container.scrollTop(0);
                this.scrollBy(distance)
            },
            _attachKeyboardHandler: function() {
                this._$element.off("." + SCROLLABLE_SIMULATED_KEYBOARD);
                if (!this.option("disabled") && this.option("useKeyboard")) {
                    this._$element.on(eventUtils.addNamespace("keydown", SCROLLABLE_SIMULATED_KEYBOARD), $.proxy(this._keyDownHandler, this))
                }
            },
            _keyDownHandler: function(e) {
                if (!this._$container.is(document.activeElement)) {
                    return
                }
                var handled = true;
                switch (e.keyCode) {
                    case KEY_CODES.DOWN:
                        this._scrollByLine({
                            y: 1
                        });
                        break;
                    case KEY_CODES.UP:
                        this._scrollByLine({
                            y: -1
                        });
                        break;
                    case KEY_CODES.RIGHT:
                        this._scrollByLine({
                            x: 1
                        });
                        break;
                    case KEY_CODES.LEFT:
                        this._scrollByLine({
                            x: -1
                        });
                        break;
                    case KEY_CODES.PAGE_DOWN:
                        this._scrollByPage(1);
                        break;
                    case KEY_CODES.PAGE_UP:
                        this._scrollByPage(-1);
                        break;
                    case KEY_CODES.HOME:
                        this._scrollToHome();
                        break;
                    case KEY_CODES.END:
                        this._scrollToEnd();
                        break;
                    default:
                        handled = false
                }
                if (handled) {
                    e.stopPropagation();
                    e.preventDefault()
                }
            },
            _scrollByLine: function(lines) {
                this.scrollBy({
                    top: (lines.y || 0) * -SCROLL_LINE_HEIGHT,
                    left: (lines.x || 0) * -SCROLL_LINE_HEIGHT
                })
            },
            _scrollByPage: function(page) {
                var prop = this._wheelProp(),
                    dimension = this._dimensionByProp(prop);
                var distance = {};
                distance[prop] = page * -this._$container[dimension]();
                this.scrollBy(distance)
            },
            _dimensionByProp: function(prop) {
                return "left" === prop ? "width" : "height"
            },
            _scrollToHome: function() {
                var prop = this._wheelProp();
                var distance = {};
                distance[prop] = 0;
                this._component.scrollTo(distance)
            },
            _scrollToEnd: function() {
                var prop = this._wheelProp(),
                    dimension = this._dimensionByProp(prop);
                var distance = {};
                distance[prop] = this._$content[dimension]() - this._$container[dimension]();
                this._component.scrollTo(distance)
            },
            createActions: function() {
                this._startAction = this._createActionHandler("onStart");
                this._stopAction = this._createActionHandler("onStop");
                this._endAction = this._createActionHandler("onEnd");
                this._updateAction = this._createActionHandler("onUpdated");
                this._createScrollerActions()
            },
            _createScrollerActions: function() {
                this._eventHandler("createActions", {
                    scroll: this._createActionHandler("onScroll"),
                    bounce: this._createActionHandler("onBounce")
                })
            },
            _createActionHandler: function(optionName) {
                var that = this,
                    actionHandler = that._createActionByOption(optionName);
                return function() {
                    actionHandler($.extend(that._createActionArgs(), arguments))
                }
            },
            _createActionArgs: function() {
                var scrollerX = this._scrollers[HORIZONTAL],
                    scrollerY = this._scrollers[VERTICAL];
                return {
                    jQueryEvent: this._eventForUserAction,
                    scrollOffset: {
                        top: scrollerY && -scrollerY._location,
                        left: scrollerX && -scrollerX._location
                    },
                    reachedLeft: scrollerX && scrollerX._reachedMax(),
                    reachedRight: scrollerX && scrollerX._reachedMin(),
                    reachedTop: scrollerY && scrollerY._reachedMax(),
                    reachedBottom: scrollerY && scrollerY._reachedMin()
                }
            },
            _eventHandler: function(eventName) {
                var args = $.makeArray(arguments).slice(1),
                    deferreds = $.map(this._scrollers, function(scroller) {
                        return scroller["_" + eventName + "Handler"].apply(scroller, args)
                    });
                return $.when.apply($, deferreds).promise()
            },
            location: function() {
                return translator.locate(this._$content)
            },
            disabledChanged: function() {
                this._attachCursorHandlers()
            },
            _attachCursorHandlers: function() {
                this._$element.off("." + SCROLLABLE_SIMULATED_CURSOR);
                if (!this.option("disabled") && this._isHoverMode()) {
                    this._$element.on(eventUtils.addNamespace("mouseenter", SCROLLABLE_SIMULATED_CURSOR), $.proxy(this._cursorEnterHandler, this)).on(eventUtils.addNamespace("mouseleave", SCROLLABLE_SIMULATED_CURSOR), $.proxy(this._cursorLeaveHandler, this))
                }
            },
            _isHoverMode: function() {
                return "onHover" === this.option("showScrollbar")
            },
            _cursorEnterHandler: function(e) {
                e = e || {};
                e.originalEvent = e.originalEvent || {};
                if (activeScrollable || e.originalEvent._hoverHandled) {
                    return
                }
                if (hoveredScrollable) {
                    hoveredScrollable._cursorLeaveHandler()
                }
                hoveredScrollable = this;
                this._eventHandler("cursorEnter");
                e.originalEvent._hoverHandled = true
            },
            _cursorLeaveHandler: function(e) {
                if (hoveredScrollable !== this || activeScrollable === hoveredScrollable) {
                    return
                }
                this._eventHandler("cursorLeave");
                hoveredScrollable = null;
                this._refreshCursorState(e && e.relatedTarget)
            },
            _refreshCursorState: function(target) {
                if (!this._isHoverMode() && (!target || activeScrollable)) {
                    return
                }
                var $target = $(target);
                var $scrollable = $target.closest("." + SCROLLABLE_SIMULATED_CLASS + ":not(.dx-state-disabled)");
                var targetScrollable = $scrollable.length && $scrollable.data(SCROLLABLE_STRATEGY);
                if (hoveredScrollable && hoveredScrollable !== targetScrollable) {
                    hoveredScrollable._cursorLeaveHandler()
                }
                if (targetScrollable) {
                    targetScrollable._cursorEnterHandler()
                }
            },
            update: function() {
                var that = this;
                var result = this._eventHandler("update").done(this._updateAction);
                return $.when(result, commonUtils.deferUpdate(function() {
                    var allowedDirections = that._allowedDirections();
                    var allowedScroll = allowedDirections.vertical || allowedDirections.horizontal;
                    commonUtils.deferRender(function() {
                        that._$container.css("touchAction", allowedScroll ? "none" : "")
                    });
                    return $.when().promise()
                }))
            },
            _allowedDirections: function() {
                var bounceEnabled = this.option("bounceEnabled"),
                    verticalScroller = this._scrollers[VERTICAL],
                    horizontalScroller = this._scrollers[HORIZONTAL];
                return {
                    vertical: verticalScroller && (verticalScroller._minOffset < 0 || bounceEnabled),
                    horizontal: horizontalScroller && (horizontalScroller._minOffset < 0 || bounceEnabled)
                }
            },
            scrollBy: function(distance) {
                var verticalScroller = this._scrollers[VERTICAL],
                    horizontalScroller = this._scrollers[HORIZONTAL];
                if (verticalScroller) {
                    distance.top = verticalScroller._boundLocation(distance.top + verticalScroller._location) - verticalScroller._location
                }
                if (horizontalScroller) {
                    distance.left = horizontalScroller._boundLocation(distance.left + horizontalScroller._location) - horizontalScroller._location
                }
                this._prepareDirections(true);
                this._startAction();
                this._eventHandler("scrollBy", {
                    x: distance.left,
                    y: distance.top
                });
                this._endAction()
            },
            validate: function(e) {
                if (this.option("disabled")) {
                    return false
                }
                if (this.option("bounceEnabled")) {
                    return true
                }
                return isWheelEvent(e) ? this._validateWheel(e) : this._validateMove(e)
            },
            _validateWheel: function(e) {
                var scroller = this._scrollers[this._wheelDirection(e)];
                var reachedMin = scroller._reachedMin();
                var reachedMax = scroller._reachedMax();
                var contentGreaterThanContainer = !reachedMin || !reachedMax;
                var locatedNotAtBound = !reachedMin && !reachedMax;
                var scrollFromMin = reachedMin && e.delta > 0;
                var scrollFromMax = reachedMax && e.delta < 0;
                return contentGreaterThanContainer && (locatedNotAtBound || scrollFromMin || scrollFromMax)
            },
            _validateMove: function(e) {
                if (!this.option("scrollByContent") && !$(e.target).closest("." + SCROLLABLE_SCROLLBAR_CLASS).length) {
                    return false
                }
                return this._allowedDirection()
            },
            getDirection: function(e) {
                return isWheelEvent(e) ? this._wheelDirection(e) : this._allowedDirection()
            },
            _wheelProp: function() {
                return this._wheelDirection() === HORIZONTAL ? "left" : "top"
            },
            _wheelDirection: function(e) {
                switch (this.option("direction")) {
                    case HORIZONTAL:
                        return HORIZONTAL;
                    case VERTICAL:
                        return VERTICAL;
                    default:
                        return e && e.shiftKey ? HORIZONTAL : VERTICAL
                }
            },
            dispose: function() {
                scrollIntoViewIfNeededCallbacks.remove(this._proxiedActiveElementChangeHandler);
                this._resetActive();
                if (hoveredScrollable === this) {
                    hoveredScrollable = null
                }
                this._eventHandler("dispose");
                this._detachEventHandlers();
                this._$element.removeClass(SCROLLABLE_SIMULATED_CLASS);
                this._eventForUserAction = null;
                clearTimeout(this._gestureEndTimer)
            },
            _detachEventHandlers: function() {
                this._$element.off("." + SCROLLABLE_SIMULATED_CURSOR);
                this._$container.off("." + SCROLLABLE_SIMULATED_KEYBOARD)
            }
        });
        exports.SimulatedStrategy = SimulatedStrategy;
        exports.Scroller = Scroller;
        exports.ACCELERATION = ACCELERATION;
        exports.MIN_VELOCITY_LIMIT = MIN_VELOCITY_LIMIT;
        exports.FRAME_DURATION = FRAME_DURATION;
        exports.SCROLL_LINE_HEIGHT = SCROLL_LINE_HEIGHT;
        exports.scrollIntoViewIfNeededCallbacks = scrollIntoViewIfNeededCallbacks
    },
    /*!********************************************!*\
      !*** ./Scripts/ui/scroll_view/animator.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            abstract = Class.abstract,
            animationFrame = __webpack_require__( /*! ../../animation/frame */ 46);
        var Animator = Class.inherit({
            ctor: function() {
                this._finished = true;
                this._stopped = false;
                this._proxiedStepCore = $.proxy(this._stepCore, this)
            },
            start: function() {
                this._stopped = false;
                this._finished = false;
                this._stepCore()
            },
            stop: function() {
                this._stopped = true;
                animationFrame.cancelAnimationFrame(this._stepAnimationFrame)
            },
            _stepCore: function() {
                if (this._isStopped()) {
                    this._stop();
                    return
                }
                if (this._isFinished()) {
                    this._finished = true;
                    this._complete();
                    return
                }
                this._step();
                this._stepAnimationFrame = animationFrame.requestAnimationFrame(this._proxiedStepCore)
            },
            _step: abstract,
            _isFinished: $.noop,
            _stop: $.noop,
            _complete: $.noop,
            _isStopped: function() {
                return this._stopped
            },
            inProgress: function() {
                return !(this._stopped || this._finished)
            }
        });
        module.exports = Animator
    },
    /*!*************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.scrollable.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            DOMComponent = __webpack_require__( /*! ../../core/dom_component */ 29),
            selectors = __webpack_require__( /*! ../widget/jquery.selectors */ 101),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            scrollEvents = __webpack_require__( /*! ./ui.events.emitter.gesture.scroll */ 238),
            simulatedStrategy = __webpack_require__( /*! ./ui.scrollable.simulated */ 235),
            NativeStrategy = __webpack_require__( /*! ./ui.scrollable.native */ 229);
        var SCROLLABLE = "dxScrollable",
            SCROLLABLE_STRATEGY = "dxScrollableStrategy",
            SCROLLABLE_CLASS = "dx-scrollable",
            SCROLLABLE_DISABLED_CLASS = "dx-scrollable-disabled",
            SCROLLABLE_CONTAINER_CLASS = "dx-scrollable-container",
            SCROLLABLE_CONTENT_CLASS = "dx-scrollable-content",
            VERTICAL = "vertical",
            HORIZONTAL = "horizontal",
            BOTH = "both";
        var beforeActivateExists = void 0 !== document.onbeforeactivate;
        var deviceDependentOptions = function() {
            return [{
                device: function(device) {
                    return !support.nativeScrolling
                },
                options: {
                    useNative: false
                }
            }, {
                device: function(device) {
                    return !support.nativeScrolling && !devices.isSimulator() && "generic" === devices.real().platform && "generic" === device.platform
                },
                options: {
                    bounceEnabled: false,
                    scrollByThumb: true,
                    scrollByContent: support.touch,
                    showScrollbar: "onHover"
                }
            }]
        };
        var Scrollable = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    disabled: false,
                    onScroll: null,
                    direction: VERTICAL,
                    showScrollbar: "onScroll",
                    useNative: true,
                    bounceEnabled: true,
                    scrollByContent: true,
                    scrollByThumb: false,
                    onUpdated: null,
                    onStart: null,
                    onEnd: null,
                    onBounce: null,
                    onStop: null,
                    useSimulatedScrollbar: false,
                    useKeyboard: true,
                    inertiaEnabled: true,
                    pushBackValue: 0,
                    updateManually: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat(deviceDependentOptions(), [{
                    device: function(device) {
                        return support.nativeScrolling && "android" === devices.real().platform
                    },
                    options: {
                        useSimulatedScrollbar: true
                    }
                }, {
                    device: function(device) {
                        return "ios" === devices.real().platform
                    },
                    options: {
                        pushBackValue: 1
                    }
                }])
            },
            _initOptions: function(options) {
                this.callBase(options);
                if (!("useSimulatedScrollbar" in options)) {
                    this._setUseSimulatedScrollbar()
                }
            },
            _setUseSimulatedScrollbar: function() {
                if (!this.initialOption("useSimulatedScrollbar")) {
                    this.option("useSimulatedScrollbar", !this.option("useNative"))
                }
            },
            _init: function() {
                this.callBase();
                this._initMarkup();
                this._attachNativeScrollbarsCustomizationCss();
                this._locked = false
            },
            _visibilityChanged: function(visible) {
                if (this.element().is(":hidden")) {
                    return
                }
                if (visible) {
                    this.update();
                    this._toggleRTLDirection(this.option("rtlEnabled"));
                    this._savedScrollOffset && this.scrollTo(this._savedScrollOffset);
                    delete this._savedScrollOffset
                } else {
                    this._savedScrollOffset = this.scrollOffset()
                }
            },
            _initMarkup: function() {
                var $element = this.element().addClass(SCROLLABLE_CLASS),
                    $container = this._$container = $("<div>").addClass(SCROLLABLE_CONTAINER_CLASS),
                    $content = this._$content = $("<div>").addClass(SCROLLABLE_CONTENT_CLASS);
                if (beforeActivateExists) {
                    $element.on(eventUtils.addNamespace("beforeactivate", SCROLLABLE), function(e) {
                        if (!$(e.target).is(selectors.focusable)) {
                            e.preventDefault()
                        }
                    })
                }
                $content.append($element.contents()).appendTo($container);
                $container.appendTo($element)
            },
            _dimensionChanged: function() {
                this.update()
            },
            _attachNativeScrollbarsCustomizationCss: function() {
                if (!(navigator.platform.indexOf("Mac") > -1 && browser.webkit)) {
                    this.element().addClass("dx-scrollable-customizable-scrollbars")
                }
            },
            _render: function() {
                this._renderPushBackOffset();
                this._renderDirection();
                this._renderStrategy();
                this._attachEventHandlers();
                this._renderDisabledState();
                this._createActions();
                this.update();
                this.callBase()
            },
            _renderPushBackOffset: function() {
                var pushBackValue = this.option("pushBackValue");
                if (!pushBackValue && !this._lastPushBackValue) {
                    return
                }
                this._$content.css({
                    paddingTop: pushBackValue,
                    paddingBottom: pushBackValue
                });
                this._lastPushBackValue = pushBackValue
            },
            _toggleRTLDirection: function(rtl) {
                var that = this;
                this.callBase(rtl);
                if (rtl && this.option("direction") !== VERTICAL) {
                    commonUtils.deferUpdate(function() {
                        var left = that.scrollWidth() - that.clientWidth();
                        commonUtils.deferRender(function() {
                            that.scrollTo({
                                left: left
                            })
                        })
                    })
                }
            },
            _attachEventHandlers: function() {
                var strategy = this._strategy;
                var initEventData = {
                    getDirection: $.proxy(strategy.getDirection, strategy),
                    validate: $.proxy(this._validate, this),
                    isNative: this.option("useNative")
                };
                this._$container.off("." + SCROLLABLE).on(eventUtils.addNamespace("scroll", SCROLLABLE), $.proxy(strategy.handleScroll, strategy)).on(eventUtils.addNamespace(scrollEvents.init, SCROLLABLE), initEventData, $.proxy(this._initHandler, this)).on(eventUtils.addNamespace(scrollEvents.start, SCROLLABLE), $.proxy(strategy.handleStart, strategy)).on(eventUtils.addNamespace(scrollEvents.move, SCROLLABLE), $.proxy(strategy.handleMove, strategy)).on(eventUtils.addNamespace(scrollEvents.end, SCROLLABLE), $.proxy(strategy.handleEnd, strategy)).on(eventUtils.addNamespace(scrollEvents.cancel, SCROLLABLE), $.proxy(strategy.handleCancel, strategy)).on(eventUtils.addNamespace(scrollEvents.stop, SCROLLABLE), $.proxy(strategy.handleStop, strategy))
            },
            _validate: function(e) {
                if (this._isLocked()) {
                    return false
                }
                this._updateIfNeed();
                return this._strategy.validate(e)
            },
            _initHandler: function() {
                var strategy = this._strategy;
                strategy.handleInit.apply(strategy, arguments)
            },
            _renderDisabledState: function() {
                this.element().toggleClass(SCROLLABLE_DISABLED_CLASS, this.option("disabled"));
                if (this.option("disabled")) {
                    this._lock()
                } else {
                    this._unlock()
                }
            },
            _renderDirection: function() {
                this.element().removeClass("dx-scrollable-" + HORIZONTAL).removeClass("dx-scrollable-" + VERTICAL).removeClass("dx-scrollable-" + BOTH).addClass("dx-scrollable-" + this.option("direction"))
            },
            _renderStrategy: function() {
                this._createStrategy();
                this._strategy.render();
                this.element().data(SCROLLABLE_STRATEGY, this._strategy)
            },
            _createStrategy: function() {
                this._strategy = this.option("useNative") ? new NativeStrategy(this) : new simulatedStrategy.SimulatedStrategy(this)
            },
            _createActions: function() {
                this._strategy.createActions()
            },
            _clean: function() {
                this._strategy.dispose()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onStart":
                    case "onEnd":
                    case "onStop":
                    case "onUpdated":
                    case "onScroll":
                    case "onBounce":
                        this._createActions();
                        break;
                    case "direction":
                        this._resetInactiveDirection();
                        this._invalidate();
                        break;
                    case "useNative":
                        this._setUseSimulatedScrollbar();
                        this._invalidate();
                        break;
                    case "inertiaEnabled":
                    case "bounceEnabled":
                    case "scrollByContent":
                    case "scrollByThumb":
                    case "bounceEnabled":
                    case "useKeyboard":
                    case "showScrollbar":
                    case "useSimulatedScrollbar":
                    case "pushBackValue":
                        this._invalidate();
                        break;
                    case "disabled":
                        this._renderDisabledState();
                        break;
                    case "updateManually":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _resetInactiveDirection: function() {
                var inactiveProp = this._getInactiveProp();
                if (!inactiveProp) {
                    return
                }
                var scrollOffset = this.scrollOffset();
                scrollOffset[inactiveProp] = 0;
                this.scrollTo(scrollOffset)
            },
            _getInactiveProp: function() {
                var direction = this.option("direction");
                if (direction === VERTICAL) {
                    return "left"
                }
                if (direction === HORIZONTAL) {
                    return "top"
                }
            },
            _location: function() {
                return this._strategy.location()
            },
            _normalizeLocation: function(location) {
                if ($.isPlainObject(location)) {
                    var left = commonUtils.ensureDefined(location.left, location.x);
                    var top = commonUtils.ensureDefined(location.top, location.y);
                    return {
                        left: commonUtils.isDefined(left) ? -left : void 0,
                        top: commonUtils.isDefined(top) ? -top : void 0
                    }
                } else {
                    var direction = this.option("direction");
                    return {
                        left: direction !== VERTICAL ? -location : void 0,
                        top: direction !== HORIZONTAL ? -location : void 0
                    }
                }
            },
            _isLocked: function() {
                return this._locked
            },
            _lock: function() {
                this._locked = true
            },
            _unlock: function() {
                if (!this.option("disabled")) {
                    this._locked = false
                }
            },
            _isDirection: function(direction) {
                var current = this.option("direction");
                if (direction === VERTICAL) {
                    return current !== HORIZONTAL
                }
                if (direction === HORIZONTAL) {
                    return current !== VERTICAL
                }
                return current === direction
            },
            _updateAllowedDirection: function() {
                var allowedDirections = this._strategy._allowedDirections();
                if (this._isDirection(BOTH) && allowedDirections.vertical && allowedDirections.horizontal) {
                    this._allowedDirectionValue = BOTH
                } else {
                    if (this._isDirection(HORIZONTAL) && allowedDirections.horizontal) {
                        this._allowedDirectionValue = HORIZONTAL
                    } else {
                        if (this._isDirection(VERTICAL) && allowedDirections.vertical) {
                            this._allowedDirectionValue = VERTICAL
                        } else {
                            this._allowedDirectionValue = null
                        }
                    }
                }
            },
            _allowedDirection: function() {
                return this._allowedDirectionValue
            },
            _container: function() {
                return this._$container
            },
            content: function() {
                return this._$content
            },
            scrollOffset: function() {
                var location = this._location();
                return {
                    top: -location.top,
                    left: -location.left
                }
            },
            scrollTop: function() {
                return this.scrollOffset().top
            },
            scrollLeft: function() {
                return this.scrollOffset().left
            },
            clientHeight: function() {
                return this._$container.height()
            },
            scrollHeight: function() {
                return this.content().outerHeight() - 2 * this.option("pushBackValue")
            },
            clientWidth: function() {
                return this._$container.width()
            },
            scrollWidth: function() {
                return this.content().outerWidth()
            },
            update: function() {
                var that = this;
                return $.when(that._strategy.update()).done(function() {
                    that._updateAllowedDirection()
                })
            },
            scrollBy: function(distance) {
                distance = this._normalizeLocation(distance);
                if (!distance.top && !distance.left) {
                    return
                }
                this._updateIfNeed();
                this._strategy.scrollBy(distance)
            },
            scrollTo: function(targetLocation) {
                targetLocation = this._normalizeLocation(targetLocation);
                this._updateIfNeed();
                var location = this._location();
                var distance = this._normalizeLocation({
                    left: location.left - commonUtils.ensureDefined(targetLocation.left, location.left),
                    top: location.top - commonUtils.ensureDefined(targetLocation.top, location.top)
                });
                if (!distance.top && !distance.left) {
                    return
                }
                this._strategy.scrollBy(distance)
            },
            scrollToElement: function(element, offset) {
                offset = offset || {};
                var $element = $(element);
                var elementInsideContent = this.content().find(element).length;
                var elementIsInsideContent = $element.parents("." + SCROLLABLE_CLASS).length - $element.parents("." + SCROLLABLE_CONTENT_CLASS).length === 0;
                if (!elementInsideContent || !elementIsInsideContent) {
                    return
                }
                var scrollPosition = {
                    top: 0,
                    left: 0
                };
                var direction = this.option("direction");
                if (direction !== VERTICAL) {
                    scrollPosition.left = this._scrollToElementPosition($element, HORIZONTAL, offset)
                }
                if (direction !== HORIZONTAL) {
                    scrollPosition.top = this._scrollToElementPosition($element, VERTICAL, offset)
                }
                this.scrollTo(scrollPosition)
            },
            _scrollToElementPosition: function($element, direction, offset) {
                var isVertical = direction === VERTICAL;
                var startOffset = (isVertical ? offset.top : offset.left) || 0;
                var endOffset = (isVertical ? offset.bottom : offset.right) || 0;
                var pushBackOffset = isVertical ? this.option("pushBackValue") : 0;
                var elementPositionRelativeToContent = this._elementPositionRelativeToContent($element, isVertical ? "top" : "left");
                var elementPosition = elementPositionRelativeToContent - pushBackOffset;
                var elementSize = $element[isVertical ? "outerHeight" : "outerWidth"]();
                var scrollLocation = isVertical ? this.scrollTop() : this.scrollLeft();
                var clientSize = isVertical ? this.clientHeight() : this.clientWidth();
                var startDistance = scrollLocation - elementPosition + startOffset;
                var endDistance = scrollLocation - elementPosition - elementSize + clientSize - endOffset;
                if (startDistance <= 0 && endDistance >= 0) {
                    return scrollLocation
                }
                return scrollLocation - (Math.abs(startDistance) > Math.abs(endDistance) ? endDistance : startDistance)
            },
            _elementPositionRelativeToContent: function($element, prop) {
                var result = 0;
                while (this._hasScrollContent($element)) {
                    result += $element.position()[prop];
                    $element = $element.offsetParent()
                }
                return result
            },
            _hasScrollContent: function($element) {
                var $content = this.content();
                return $element.closest($content).length && !$element.is($content)
            },
            _updateIfNeed: function() {
                if (!this.option("updateManually")) {
                    this.update()
                }
            }
        });
        registerComponent(SCROLLABLE, Scrollable);
        exports.default = Scrollable;
        exports.deviceDependentOptions = deviceDependentOptions
    },
    /*!********************************************************************!*\
      !*** ./Scripts/ui/scroll_view/ui.events.emitter.gesture.scroll.js ***!
      \********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            abstract = Class.abstract,
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            GestureEmitter = __webpack_require__( /*! ../../events/gesture/emitter.gesture */ 78),
            registerEmitter = __webpack_require__( /*! ../../events/core/emitter_registrator */ 76),
            animationFrame = __webpack_require__( /*! ../../animation/frame */ 46),
            realDevice = __webpack_require__( /*! ../../core/devices */ 40).real(),
            compareVersions = __webpack_require__( /*! ../../core/utils/version */ 45).compare;
        var SCROLL_INIT_EVENT = "dxscrollinit",
            SCROLL_START_EVENT = "dxscrollstart",
            SCROLL_MOVE_EVENT = "dxscroll",
            SCROLL_END_EVENT = "dxscrollend",
            SCROLL_STOP_EVENT = "dxscrollstop",
            SCROLL_CANCEL_EVENT = "dxscrollcancel";
        var isWheelEvent = function(e) {
            return "dxmousewheel" === e.type
        };
        var Locker = Class.inherit(function() {
            var NAMESPACED_SCROLL_EVENT = eventUtils.addNamespace("scroll", "dxScrollEmitter");
            return {
                ctor: function(element) {
                    this._element = element;
                    this._locked = false;
                    var that = this;
                    this._proxiedScroll = function(e) {
                        that._scroll(e)
                    };
                    $(this._element).on(NAMESPACED_SCROLL_EVENT, this._proxiedScroll)
                },
                _scroll: abstract,
                check: function(e, callback) {
                    if (this._locked) {
                        callback()
                    }
                },
                dispose: function() {
                    $(this._element).off(NAMESPACED_SCROLL_EVENT, this._proxiedScroll)
                }
            }
        }());
        var TimeoutLocker = Locker.inherit(function() {
            return {
                ctor: function(element, timeout) {
                    this.callBase(element);
                    this._timeout = timeout
                },
                _scroll: function() {
                    this._prepare();
                    this._forget()
                },
                _prepare: function() {
                    if (this._timer) {
                        this._clearTimer()
                    }
                    this._locked = true
                },
                _clearTimer: function() {
                    clearTimeout(this._timer);
                    this._locked = false;
                    this._timer = null
                },
                _forget: function() {
                    var that = this;
                    this._timer = setTimeout(function() {
                        that._clearTimer()
                    }, this._timeout)
                },
                dispose: function() {
                    this.callBase();
                    this._clearTimer()
                }
            }
        }());
        var WheelLocker = TimeoutLocker.inherit(function() {
            var WHEEL_UNLOCK_TIMEOUT = 400;
            return {
                ctor: function(element) {
                    this.callBase(element, WHEEL_UNLOCK_TIMEOUT);
                    this._lastWheelDirection = null
                },
                check: function(e, callback) {
                    this._checkDirectionChanged(e);
                    this.callBase(e, callback)
                },
                _checkDirectionChanged: function(e) {
                    if (!isWheelEvent(e)) {
                        this._lastWheelDirection = null;
                        return
                    }
                    var direction = e.shiftKey || false,
                        directionChange = null !== this._lastWheelDirection && direction !== this._lastWheelDirection;
                    this._lastWheelDirection = direction;
                    this._locked = this._locked && !directionChange
                }
            }
        }());
        var PointerLocker = TimeoutLocker.inherit(function() {
            var POINTER_UNLOCK_TIMEOUT = 400;
            return {
                ctor: function(element) {
                    this.callBase(element, POINTER_UNLOCK_TIMEOUT)
                }
            }
        }());
        ! function() {
            var ios8_greater = realDevice.ios && compareVersions(realDevice.version, [8]) >= 0,
                android5_greater = realDevice.android && compareVersions(realDevice.version, [5]) >= 0;
            if (!(ios8_greater || android5_greater)) {
                return
            }
            PointerLocker = Locker.inherit(function() {
                return {
                    _scroll: function() {
                        this._locked = true;
                        var that = this;
                        this._scrollFrame = animationFrame.requestAnimationFrame(function() {
                            that._locked = false
                        })
                    },
                    check: function(e, callback) {
                        animationFrame.cancelAnimationFrame(this._scrollFrame);
                        animationFrame.cancelAnimationFrame(this._checkFrame);
                        var that = this,
                            callBase = this.callBase;
                        this._checkFrame = animationFrame.requestAnimationFrame(function() {
                            callBase.call(that, e, callback);
                            that._locked = false
                        })
                    },
                    dispose: function() {
                        this.callBase();
                        animationFrame.cancelAnimationFrame(this._scrollFrame);
                        animationFrame.cancelAnimationFrame(this._checkFrame)
                    }
                }
            }())
        }();
        var ScrollEmitter = GestureEmitter.inherit(function() {
            var INERTIA_TIMEOUT = 100,
                VELOCITY_CALC_TIMEOUT = 200,
                FRAME_DURATION = Math.round(1e3 / 60);
            return {
                ctor: function(element) {
                    this.callBase.apply(this, arguments);
                    this.direction = "both";
                    this._pointerLocker = new PointerLocker(element);
                    this._wheelLocker = new WheelLocker(element)
                },
                validate: function() {
                    return true
                },
                _init: function(e) {
                    var that = this;
                    this._wheelLocker.check(e, function() {
                        isWheelEvent(e) && that._accept(e)
                    });
                    this._pointerLocker.check(e, function() {
                        !isWheelEvent(e) && that._accept(e)
                    });
                    this._fireEvent(SCROLL_INIT_EVENT, e)
                },
                move: function(e) {
                    this.callBase.apply(this, arguments);
                    e.isScrollingEvent = this.isNative || e.isScrollingEvent
                },
                _start: function(e) {
                    this._savedEventData = eventUtils.eventData(e);
                    this._fireEvent(SCROLL_START_EVENT, e, {
                        delta: eventUtils.eventDelta(this._savedEventData, eventUtils.eventData(e))
                    })
                },
                _move: function(e) {
                    var currentEventData = eventUtils.eventData(e);
                    this._fireEvent(SCROLL_MOVE_EVENT, e, {
                        delta: eventUtils.eventDelta(this._prevEventData, currentEventData)
                    });
                    var eventDelta = eventUtils.eventDelta(this._savedEventData, currentEventData);
                    if (eventDelta.time > VELOCITY_CALC_TIMEOUT) {
                        this._savedEventData = this._prevEventData
                    }
                },
                _end: function(e) {
                    var endEventDelta = eventUtils.eventDelta(this._prevEventData, eventUtils.eventData(e));
                    var velocity = {
                        x: 0,
                        y: 0
                    };
                    if (!isWheelEvent(e) && endEventDelta.time < INERTIA_TIMEOUT) {
                        var eventDelta = eventUtils.eventDelta(this._savedEventData, this._prevEventData),
                            velocityMultiplier = FRAME_DURATION / eventDelta.time;
                        velocity = {
                            x: eventDelta.x * velocityMultiplier,
                            y: eventDelta.y * velocityMultiplier
                        }
                    }
                    this._fireEvent(SCROLL_END_EVENT, e, {
                        velocity: velocity
                    })
                },
                _stop: function(e) {
                    this._fireEvent(SCROLL_STOP_EVENT, e)
                },
                cancel: function(e) {
                    this.callBase.apply(this, arguments);
                    this._fireEvent(SCROLL_CANCEL_EVENT, e)
                },
                dispose: function() {
                    this.callBase.apply(this, arguments);
                    this._pointerLocker.dispose();
                    this._wheelLocker.dispose()
                }
            }
        }());
        registerEmitter({
            emitter: ScrollEmitter,
            events: [SCROLL_INIT_EVENT, SCROLL_START_EVENT, SCROLL_MOVE_EVENT, SCROLL_END_EVENT, SCROLL_STOP_EVENT, SCROLL_CANCEL_EVENT]
        });
        module.exports = {
            init: SCROLL_INIT_EVENT,
            start: SCROLL_START_EVENT,
            move: SCROLL_MOVE_EVENT,
            end: SCROLL_END_EVENT,
            stop: SCROLL_STOP_EVENT,
            cancel: SCROLL_CANCEL_EVENT
        }
    },
    /*!**********************************!*\
      !*** ./Scripts/ui/load_panel.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            LoadIndicator = __webpack_require__( /*! ./load_indicator */ 231),
            Overlay = __webpack_require__( /*! ./overlay */ 109);
        var LOADPANEL_CLASS = "dx-loadpanel",
            LOADPANEL_WRAPPER_CLASS = "dx-loadpanel-wrapper",
            LOADPANEL_INDICATOR_CLASS = "dx-loadpanel-indicator",
            LOADPANEL_MESSAGE_CLASS = "dx-loadpanel-message",
            LOADPANEL_CONTENT_CLASS = "dx-loadpanel-content",
            LOADPANEL_CONTENT_WRAPPER_CLASS = "dx-loadpanel-content-wrapper",
            LOADPANEL_PANE_HIDDEN_CLASS = "dx-loadpanel-pane-hidden";
        var LoadPanel = Overlay.inherit({
            _supportedKeys: function() {
                return $.extend(this.callBase(), {
                    escape: $.noop
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    message: messageLocalization.format("Loading"),
                    width: 222,
                    height: 90,
                    animation: null,
                    showIndicator: true,
                    indicatorSrc: "",
                    showPane: true,
                    delay: 0,
                    closeOnBackButton: false,
                    resizeEnabled: false,
                    focusStateEnabled: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "generic"
                    },
                    options: {
                        shadingColor: "transparent"
                    }
                }])
            },
            _init: function() {
                this.callBase.apply(this, arguments)
            },
            _initOptions: function() {
                this.callBase.apply(this, arguments);
                this.option("templatesRenderAsynchronously", false)
            },
            _render: function() {
                this.callBase();
                this.element().addClass(LOADPANEL_CLASS);
                this._wrapper().addClass(LOADPANEL_WRAPPER_CLASS)
            },
            _renderContentImpl: function() {
                this.callBase();
                this.content().addClass(LOADPANEL_CONTENT_CLASS);
                this._$contentWrapper = $("<div>").addClass(LOADPANEL_CONTENT_WRAPPER_CLASS);
                this._$contentWrapper.appendTo(this._$content);
                this._togglePaneVisible();
                this._cleanPreviousContent();
                this._renderLoadIndicator();
                this._renderMessage()
            },
            _show: function() {
                var delay = this.option("delay");
                if (!delay) {
                    return this.callBase()
                }
                var deferred = $.Deferred();
                var callBase = $.proxy(this.callBase, this);
                this._clearShowTimeout();
                this._showTimeout = setTimeout(function() {
                    callBase().done(function() {
                        deferred.resolve()
                    })
                }, delay);
                return deferred.promise()
            },
            _hide: function() {
                this._clearShowTimeout();
                return this.callBase()
            },
            _clearShowTimeout: function() {
                clearTimeout(this._showTimeout)
            },
            _renderMessage: function() {
                if (!this._$contentWrapper) {
                    return
                }
                var message = this.option("message");
                if (!message) {
                    return
                }
                var $message = $("<div>").addClass(LOADPANEL_MESSAGE_CLASS).text(message);
                this._$contentWrapper.append($message)
            },
            _renderLoadIndicator: function() {
                if (!this._$contentWrapper || !this.option("showIndicator")) {
                    return
                }
                this._$indicator = $("<div>").addClass(LOADPANEL_INDICATOR_CLASS).appendTo(this._$contentWrapper);
                this._createComponent(this._$indicator, LoadIndicator, {
                    indicatorSrc: this.option("indicatorSrc")
                })
            },
            _cleanPreviousContent: function() {
                this.content().find("." + LOADPANEL_MESSAGE_CLASS).remove();
                this.content().find("." + LOADPANEL_INDICATOR_CLASS).remove()
            },
            _togglePaneVisible: function() {
                this.content().toggleClass(LOADPANEL_PANE_HIDDEN_CLASS, !this.option("showPane"))
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "delay":
                        break;
                    case "message":
                    case "showIndicator":
                        this._cleanPreviousContent();
                        this._renderLoadIndicator();
                        this._renderMessage();
                        break;
                    case "showPane":
                        this._togglePaneVisible();
                        break;
                    case "indicatorSrc":
                        if (this._$indicator) {
                            this._createComponent(this._$indicator, LoadIndicator, {
                                indicatorSrc: this.option("indicatorSrc")
                            })
                        }
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _dispose: function() {
                this._clearShowTimeout();
                this.callBase()
            }
        });
        registerComponent("dxLoadPanel", LoadPanel);
        module.exports = LoadPanel
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.selection.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            CheckBox = __webpack_require__( /*! ../check_box */ 241),
            RadioButton = __webpack_require__( /*! ../radio_group/radio_button */ 242),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            registerDecorator = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217).register,
            EditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator */ 219);
        var SELECT_DECORATOR_ENABLED_CLASS = "dx-list-select-decorator-enabled",
            SELECT_DECORATOR_SELECT_ALL_CLASS = "dx-list-select-all",
            SELECT_DECORATOR_SELECT_ALL_CHECKBOX_CLASS = "dx-list-select-all-checkbox",
            SELECT_DECORATOR_SELECT_ALL_LABEL_CLASS = "dx-list-select-all-label",
            SELECT_CHECKBOX_CONTAINER_CLASS = "dx-list-select-checkbox-container",
            SELECT_CHECKBOX_CLASS = "dx-list-select-checkbox",
            SELECT_RADIO_BUTTON_CONTAINER_CLASS = "dx-list-select-radiobutton-container",
            SELECT_RADIO_BUTTON_CLASS = "dx-list-select-radiobutton";
        var CLICK_EVENT_NAME = eventUtils.addNamespace(clickEvent.name, "dxListEditDecorator");
        registerDecorator("selection", "default", EditDecorator.inherit({
            _init: function() {
                this.callBase.apply(this, arguments);
                var selectionMode = this._list.option("selectionMode");
                this._singleStrategy = "single" === selectionMode;
                this._containerClass = this._singleStrategy ? SELECT_RADIO_BUTTON_CONTAINER_CLASS : SELECT_CHECKBOX_CONTAINER_CLASS;
                this._controlClass = this._singleStrategy ? SELECT_RADIO_BUTTON_CLASS : SELECT_CHECKBOX_CLASS;
                this._controlWidget = this._singleStrategy ? RadioButton.publicName() : CheckBox.publicName();
                this._list.element().addClass(SELECT_DECORATOR_ENABLED_CLASS)
            },
            beforeBag: function(config) {
                var $itemElement = config.$itemElement,
                    $container = config.$container;
                var $control = $("<div />").addClass(this._controlClass);
                $control[this._controlWidget]($.extend(this._commonOptions(), {
                    value: this._isSelected($itemElement),
                    focusStateEnabled: false,
                    hoverStateEnabled: false,
                    onValueChanged: $.proxy(function(e) {
                        this._processCheckedState($itemElement, e.value);
                        e.jQueryEvent && e.jQueryEvent.stopPropagation()
                    }, this)
                }));
                $container.addClass(this._containerClass);
                $container.append($control)
            },
            modifyElement: function(config) {
                this.callBase.apply(this, arguments);
                var $itemElement = config.$itemElement,
                    control = $itemElement.find("." + this._controlClass)[this._controlWidget]("instance");
                $itemElement.on("stateChanged", $.proxy(function() {
                    control.option("value", this._isSelected($itemElement));
                    this._updateSelectAllState()
                }, this))
            },
            _updateSelectAllState: function() {
                if (!this._$selectAll) {
                    return
                }
                var items = this._list.option("items");
                var selectedItems = this._list.option("selectedItems");
                var dataSource = this._list._dataSource;
                var itemsCount = dataSource && dataSource.totalCount() >= 0 ? dataSource.totalCount() : items.length;
                var isSelectedAll = itemsCount > 0 && itemsCount === selectedItems.length ? true : 0 === selectedItems.length ? false : void 0;
                this._selectAllCheckBox.option("value", isSelectedAll)
            },
            afterRender: function() {
                if ("all" !== this._list.option("selectionMode")) {
                    return
                }
                if (!this._$selectAll) {
                    this._renderSelectAll()
                }
            },
            _renderSelectAll: function() {
                var $selectAll = this._$selectAll = $("<div>").addClass(SELECT_DECORATOR_SELECT_ALL_CLASS);
                this._selectAllCheckBox = this._list._createComponent($("<div>").addClass(SELECT_DECORATOR_SELECT_ALL_CHECKBOX_CLASS).appendTo($selectAll), CheckBox);
                $("<div>").addClass(SELECT_DECORATOR_SELECT_ALL_LABEL_CLASS).text(this._list.option("selectAllText")).appendTo($selectAll);
                this._list.itemsContainer().prepend($selectAll);
                this._updateSelectAllState();
                this._attachSelectAllHandler()
            },
            _attachSelectAllHandler: function() {
                this._selectAllCheckBox.option("onValueChanged", $.proxy(this._selectAllHandler, this));
                this._$selectAll.off(CLICK_EVENT_NAME).on(CLICK_EVENT_NAME, $.proxy(this._selectAllClickHandler, this))
            },
            _selectAllHandler: function(e) {
                e.jQueryEvent && e.jQueryEvent.stopPropagation();
                var isSelectedAll = this._selectAllCheckBox.option("value");
                var result = this._list._createActionByOption("onSelectAllValueChanged")({
                    value: isSelectedAll
                });
                if (false === result) {
                    return
                }
                if (true === isSelectedAll) {
                    this._selectAllItems()
                } else {
                    if (false === isSelectedAll) {
                        this._unselectAllItems()
                    }
                }
            },
            _selectAllItems: function() {
                this._list.option("selectedItems", this._list.option("items").slice())
            },
            _unselectAllItems: function() {
                this._list.option("selectedItems", [])
            },
            _selectAllClickHandler: function() {
                this._selectAllCheckBox.option("value", !this._selectAllCheckBox.option("value"))
            },
            _isSelected: function($itemElement) {
                return this._list.isItemSelected($itemElement)
            },
            _processCheckedState: function($itemElement, checked) {
                if (checked) {
                    this._list.selectItem($itemElement)
                } else {
                    this._list.unselectItem($itemElement)
                }
            },
            dispose: function() {
                this._disposeSelectAll();
                this._list.element().removeClass(SELECT_DECORATOR_ENABLED_CLASS);
                this.callBase.apply(this, arguments)
            },
            _disposeSelectAll: function() {
                if (this._$selectAll) {
                    this._$selectAll.remove();
                    this._$selectAll = null
                }
            },
            handleClick: function($itemElement) {
                var newState = !this._isSelected($itemElement) || this._singleStrategy;
                this._processCheckedState($itemElement, newState);
                return true
            }
        }))
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/check_box.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            inkRipple = __webpack_require__( /*! ./widget/utils.ink_ripple */ 197),
            Editor = __webpack_require__( /*! ./editor/editor */ 107),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            themes = __webpack_require__( /*! ./themes */ 143),
            clickEvent = __webpack_require__( /*! ../events/click */ 64);
        var CHECKBOX_CLASS = "dx-checkbox",
            CHECKBOX_ICON_CLASS = "dx-checkbox-icon",
            CHECKBOX_CHECKED_CLASS = "dx-checkbox-checked",
            CHECKBOX_CONTAINER_CLASS = "dx-checkbox-container",
            CHECKBOX_TEXT_CLASS = "dx-checkbox-text",
            CHECKBOX_HAS_TEXT_CLASS = "dx-checkbox-has-text",
            CHECKBOX_INDETERMINATE_CLASS = "dx-checkbox-indeterminate",
            CHECKBOX_FEEDBACK_HIDE_TIMEOUT = 100;
        var CheckBox = Editor.inherit({
            _supportedKeys: function() {
                var click = function(e) {
                    e.preventDefault();
                    this._clickAction({
                        jQueryEvent: e
                    })
                };
                return $.extend(this.callBase(), {
                    space: click
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    activeStateEnabled: true,
                    value: false,
                    text: "",
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _feedbackHideTimeout: CHECKBOX_FEEDBACK_HIDE_TIMEOUT,
            _render: function() {
                this.callBase();
                this._$container = $("<div>").addClass(CHECKBOX_CONTAINER_CLASS);
                this.setAria("role", "checkbox");
                this._renderClick();
                this._renderValue();
                this._renderIcon();
                this._renderText();
                this.option("useInkRipple") && this._renderInkRipple();
                this.element().addClass(CHECKBOX_CLASS).append(this._$container)
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render({
                    waveSizeCoefficient: 2.5,
                    useHoldAnimation: false,
                    wavesNumber: 2,
                    isCentered: true
                })
            },
            _renderInkWave: function(element, jQueryEvent, doRender, waveIndex) {
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: element,
                    jQueryEvent: jQueryEvent,
                    wave: waveIndex
                };
                if (doRender) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _updateFocusState: function(e, value) {
                this.callBase.apply(this, arguments);
                this._renderInkWave(this._$icon, e, value, 0)
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                this._renderInkWave(this._$icon, e, value, 1)
            },
            _renderIcon: function() {
                this._$icon = $("<span>").addClass(CHECKBOX_ICON_CLASS).prependTo(this._$container)
            },
            _renderText: function() {
                var textValue = this.option("text");
                if (!textValue) {
                    if (this._$text) {
                        this._$text.remove();
                        this.element().removeClass(CHECKBOX_HAS_TEXT_CLASS)
                    }
                    return
                }
                if (!this._$text) {
                    this._$text = $("<span>").addClass(CHECKBOX_TEXT_CLASS)
                }
                this._$text.text(textValue);
                this._$container.append(this._$text);
                this.element().addClass(CHECKBOX_HAS_TEXT_CLASS)
            },
            _renderClick: function() {
                var that = this,
                    eventName = eventUtils.addNamespace(clickEvent.name, that.NAME);
                that._clickAction = that._createAction(that._clickHandler);
                that.element().off(eventName).on(eventName, function(e) {
                    that._clickAction({
                        jQueryEvent: e
                    })
                })
            },
            _clickHandler: function(args) {
                var that = args.component;
                that._saveValueChangeEvent(args.jQueryEvent);
                that.option("value", !that.option("value"))
            },
            _renderValue: function() {
                var $element = this.element(),
                    checked = this.option("value"),
                    indeterminate = void 0 === checked;
                $element.toggleClass(CHECKBOX_CHECKED_CLASS, Boolean(checked));
                $element.toggleClass(CHECKBOX_INDETERMINATE_CLASS, indeterminate);
                this.setAria("checked", indeterminate ? "mixed" : checked || "false")
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    case "value":
                        this._renderValue();
                        this.callBase(args);
                        break;
                    case "text":
                        this._renderText();
                        this._renderDimensions();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxCheckBox", CheckBox);
        module.exports = CheckBox
    },
    /*!************************************************!*\
      !*** ./Scripts/ui/radio_group/radio_button.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            inkRipple = __webpack_require__( /*! ../widget/utils.ink_ripple */ 197),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            themes = __webpack_require__( /*! ../themes */ 143),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        var RADIO_BUTTON_CLASS = "dx-radiobutton",
            RADIO_BUTTON_ICON_CLASS = "dx-radiobutton-icon",
            RADIO_BUTTON_ICON_DOT_CLASS = "dx-radiobutton-icon-dot",
            RADIO_BUTTON_CHECKED_CLASS = "dx-radiobutton-checked";
        var RadioButton = Editor.inherit({
            _supportedKeys: function() {
                var click = function(e) {
                    e.preventDefault();
                    this._clickAction({
                        jQueryEvent: e
                    })
                };
                return $.extend(this.callBase(), {
                    space: click
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    activeStateEnabled: true,
                    value: false,
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this.element().addClass(RADIO_BUTTON_CLASS)
            },
            _render: function() {
                this.callBase();
                this._renderIcon();
                this.option("useInkRipple") && this._renderInkRipple();
                this._renderCheckedState(this.option("value"));
                this._renderClick();
                this.setAria("role", "radio")
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render({
                    waveSizeCoefficient: 3.3,
                    useHoldAnimation: false,
                    wavesNumber: 2,
                    isCentered: true
                })
            },
            _renderInkWave: function(element, jQueryEvent, doRender, waveIndex) {
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: element,
                    jQueryEvent: jQueryEvent,
                    wave: waveIndex
                };
                if (doRender) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _updateFocusState: function(e, value) {
                this.callBase.apply(this, arguments);
                this._renderInkWave(this._$icon, e, value, 0)
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                this._renderInkWave(this._$icon, e, value, 1)
            },
            _renderIcon: function() {
                this._$icon = $("<div>").addClass(RADIO_BUTTON_ICON_CLASS);
                $("<div>").addClass(RADIO_BUTTON_ICON_DOT_CLASS).appendTo(this._$icon);
                this.element().append(this._$icon)
            },
            _renderCheckedState: function(checked) {
                this.element().toggleClass(RADIO_BUTTON_CHECKED_CLASS, checked);
                this.setAria("checked", checked)
            },
            _renderClick: function() {
                var eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                this._clickAction = this._createAction($.proxy(function(args) {
                    this._clickHandler(args.jQueryEvent)
                }, this));
                this.element().off(eventName).on(eventName, $.proxy(function(e) {
                    this._clickAction({
                        jQueryEvent: e
                    })
                }, this))
            },
            _clickHandler: function(e) {
                this._saveValueChangeEvent(e);
                this.option("value", true)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    case "value":
                        this._renderCheckedState(args.value);
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxRadioButton", RadioButton);
        module.exports = RadioButton
    },
    /*!***********************************************************!*\
      !*** ./Scripts/ui/list/ui.list.edit.decorator.reorder.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            dragEvents = __webpack_require__( /*! ../../events/drag */ 110),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            mathUtils = __webpack_require__( /*! ../../core/utils/math */ 79),
            Animator = __webpack_require__( /*! ../scroll_view/animator */ 236),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            registerDecorator = __webpack_require__( /*! ./ui.list.edit.decorator_registry */ 217).register,
            EditDecorator = __webpack_require__( /*! ./ui.list.edit.decorator */ 219);
        var ReorderScrollAnimator = Animator.inherit({
            ctor: function(strategy) {
                this.callBase();
                this._strategy = strategy
            },
            _isFinished: function() {
                return this._strategy.scrollFinished()
            },
            _step: function() {
                this._strategy.scrollByStep()
            }
        });
        var LIST_EDIT_DECORATOR = "dxListEditDecorator",
            DRAG_START_EVENT_NAME = eventUtils.addNamespace(dragEvents.start, LIST_EDIT_DECORATOR),
            DRAG_UPDATE_EVENT_NAME = eventUtils.addNamespace(dragEvents.move, LIST_EDIT_DECORATOR),
            DRAG_END_EVENT_NAME = eventUtils.addNamespace(dragEvents.end, LIST_EDIT_DECORATOR),
            REORDER_HANDLE_CONTAINER_CLASS = "dx-list-reorder-handle-container",
            REORDER_HANDLE_CLASS = "dx-list-reorder-handle",
            REOREDERING_ITEM_CLASS = "dx-list-item-reordering",
            REOREDERING_ITEM_GHOST_CLASS = "dx-list-item-ghost-reordering",
            LIST_REORDER_COMPATIBILITY_MODE_CLASS = "dx-list-reorder-compatibility-mode";
        registerDecorator("reorder", "default", EditDecorator.inherit({
            _init: function() {
                this._groupedEnabled = this._list.option("grouped");
                this._initAnimator()
            },
            _initAnimator: function() {
                this._scrollAnimator = new ReorderScrollAnimator(this)
            },
            _startAnimator: function() {
                if (!this._scrollAnimator.inProgress()) {
                    this._scrollAnimator.start()
                }
            },
            _stopAnimator: function() {
                this._scrollAnimator.stop()
            },
            afterBag: function(config) {
                var $itemElement = config.$itemElement,
                    $container = config.$container;
                var $handle = $("<div>").addClass(REORDER_HANDLE_CLASS);
                var lockedDrag = false;
                $handle.on("dxpointerdown", function() {
                    lockedDrag = true
                });
                $handle.on("dxhold", {
                    timeout: 30
                }, function(e) {
                    e.cancel = true;
                    lockedDrag = false
                });
                $handle.on(DRAG_START_EVENT_NAME, {
                    direction: "vertical",
                    immediate: true
                }, $.proxy(function(e) {
                    if (lockedDrag) {
                        e.cancel = true;
                        return
                    }
                    this._dragStartHandler($itemElement, e)
                }, this));
                $handle.on(DRAG_UPDATE_EVENT_NAME, $.proxy(this._dragHandler, this, $itemElement));
                $handle.on(DRAG_END_EVENT_NAME, $.proxy(this._dragEndHandler, this, $itemElement));
                $container.addClass(REORDER_HANDLE_CONTAINER_CLASS);
                $container.append($handle)
            },
            _dragStartHandler: function($itemElement, e) {
                if ($itemElement.is(".dx-state-disabled, .dx-state-disabled *")) {
                    e.cancel = true;
                    return
                }
                this._stopPreviousAnimation();
                e.targetElements = [];
                this._cacheItemsPositions();
                this._startPointerOffset = e.pageY - $itemElement.offset().top;
                this._elementHeight = $itemElement.outerHeight();
                var itemIndex = this._list.getFlatIndexByItemElement($itemElement);
                this._startIndex = itemIndex;
                this._lastIndex = itemIndex;
                this._cacheScrollData();
                this._toggleCompatibilityMode(true);
                var that = this;
                this._createGhostTimeout = setTimeout(function() {
                    that._createGhost($itemElement);
                    that._updateGhostPosition();
                    $itemElement.addClass(REOREDERING_ITEM_CLASS)
                })
            },
            _stopPreviousAnimation: function() {
                fx.stop(this._$ghostItem, true)
            },
            _toggleCompatibilityMode: function(enabled) {
                this._list.element().toggleClass(LIST_REORDER_COMPATIBILITY_MODE_CLASS, !support.transform && enabled)
            },
            _cacheItemsPositions: function() {
                var itemPositions = this._itemPositions = [];
                $.each(this._list.itemElements(), function(index, item) {
                    var cachedPosition = null;
                    itemPositions.push(function() {
                        cachedPosition = null === cachedPosition ? $(item).position().top : cachedPosition;
                        return cachedPosition
                    })
                })
            },
            _getDraggingElementPosition: function() {
                return this._itemPositions[this._startIndex]()
            },
            _getLastElementPosition: function() {
                return this._itemPositions[this._lastIndex]()
            },
            _cacheScrollData: function() {
                this._list.updateDimensions();
                this._startScrollTop = this._list.scrollTop();
                this._scrollOffset = 0;
                this._scrollHeight = this._list.scrollHeight();
                this._clientHeight = this._list.clientHeight()
            },
            _scrollTop: function() {
                return this._startScrollTop + this._scrollOffset
            },
            _createGhost: function($itemElement) {
                this._$ghostItem = $itemElement.clone();
                this._$ghostItem.addClass(REOREDERING_ITEM_GHOST_CLASS).appendTo(this._list.itemsContainer());
                this._startGhostPosition = this._getDraggingElementPosition() - this._$ghostItem.position().top;
                translator.move(this._$ghostItem, {
                    top: this._startGhostPosition
                })
            },
            _dragHandler: function($itemElement, e) {
                this._topOffset = e.offset.y;
                this._updateItemPositions();
                var pointerPosition = this._getPointerPosition();
                this._toggleScroll(pointerPosition)
            },
            _getPointerPosition: function() {
                return this._getDraggingElementPosition() + this._startPointerOffset + this._scrollOffset + this._topOffset
            },
            _toggleScroll: function(pointerPosition) {
                if (this._scrollHeight <= this._clientHeight) {
                    return
                }
                var minOffset = .7 * this._elementHeight,
                    topOffset = this._clientHeight - (pointerPosition - this._scrollTop()),
                    topOffsetRatio = topOffset / minOffset,
                    bottomOffset = pointerPosition - this._scrollTop(),
                    bottomOffsetRatio = bottomOffset / minOffset;
                if (topOffsetRatio < 1) {
                    this._stepSize = this._adjustRationIntoRange(topOffsetRatio);
                    this._startAnimator()
                } else {
                    if (bottomOffsetRatio < 1) {
                        this._stepSize = -this._adjustRationIntoRange(bottomOffsetRatio);
                        this._startAnimator()
                    } else {
                        this._stopAnimator()
                    }
                }
            },
            _adjustRationIntoRange: function(ratio) {
                return mathUtils.fitIntoRange(Math.round(7 * Math.abs(ratio - 1)), 1, 7)
            },
            _updateItemPositions: function() {
                this._updateGhostPosition();
                this._updateOthersPositions()
            },
            _updateGhostPosition: function() {
                if (!this._$ghostItem) {
                    return
                }
                translator.move(this._$ghostItem, {
                    top: this._startGhostPosition + this._scrollOffset + this._topOffset
                })
            },
            _updateOthersPositions: function() {
                var currentIndex = this._findItemIndexByPosition(this._getPointerPosition());
                if (this._lastIndex === currentIndex || this._groupedEnabled && !this._sameParent(currentIndex)) {
                    return
                }
                var currentIndexOffset = currentIndex - this._startIndex,
                    currentDirection = mathUtils.sign(currentIndexOffset),
                    minIndex = Math.min(currentIndex, this._lastIndex),
                    maxIndex = Math.max(currentIndex, this._lastIndex);
                for (var itemIndex = minIndex; itemIndex <= maxIndex; itemIndex++) {
                    if (itemIndex === this._startIndex) {
                        continue
                    }
                    var $item = this._list.getItemElementByFlatIndex(itemIndex),
                        itemIndexOffset = itemIndex - this._startIndex,
                        itemDirection = mathUtils.sign(itemIndexOffset),
                        offsetsDifference = Math.abs(itemIndexOffset) <= Math.abs(currentIndexOffset),
                        sameDirections = currentDirection === itemDirection,
                        setupPosition = offsetsDifference && sameDirections,
                        resetPosition = !offsetsDifference || !sameDirections;
                    fx.stop($item);
                    if (setupPosition) {
                        fx.animate($item, {
                            type: "slide",
                            to: {
                                top: this._elementHeight * -currentDirection
                            },
                            duration: 300
                        })
                    }
                    if (resetPosition) {
                        fx.animate($item, {
                            type: "slide",
                            to: {
                                top: 0
                            },
                            duration: 300
                        })
                    }
                }
                this._lastIndex = currentIndex
            },
            _sameParent: function(index) {
                var $dragging = this._list.getItemElementByFlatIndex(this._startIndex),
                    $over = this._list.getItemElementByFlatIndex(index);
                return $over.parent().get(0) === $dragging.parent().get(0)
            },
            scrollByStep: function() {
                this._scrollOffset += this._stepSize;
                this._list.scrollBy(this._stepSize);
                this._updateItemPositions()
            },
            scrollFinished: function() {
                var scrollTop = this._scrollTop(),
                    rejectScrollTop = scrollTop <= 0 && this._stepSize < 0,
                    rejectScrollBottom = scrollTop >= this._scrollHeight - this._clientHeight && this._stepSize > 0;
                return rejectScrollTop || rejectScrollBottom
            },
            _dragEndHandler: function($itemElement) {
                this._scrollAnimator.stop();
                fx.animate(this._$ghostItem, {
                    type: "slide",
                    to: {
                        top: this._startGhostPosition + this._getLastElementPosition() - this._getDraggingElementPosition()
                    },
                    duration: 300
                }).done($.proxy(function() {
                    $itemElement.removeClass(REOREDERING_ITEM_CLASS);
                    this._resetPositions();
                    this._list.reorderItem($itemElement, this._list.getItemElementByFlatIndex(this._lastIndex));
                    this._deleteGhost();
                    this._toggleCompatibilityMode(false)
                }, this))
            },
            _deleteGhost: function() {
                if (!this._$ghostItem) {
                    return
                }
                this._$ghostItem.remove()
            },
            _resetPositions: function() {
                var minIndex = Math.min(this._startIndex, this._lastIndex),
                    maxIndex = Math.max(this._startIndex, this._lastIndex);
                for (var itemIndex = minIndex; itemIndex <= maxIndex; itemIndex++) {
                    var $item = this._list.getItemElementByFlatIndex(itemIndex);
                    translator.resetPosition($item)
                }
            },
            _findItemIndexByPosition: function(position) {
                var minIndex = 0;
                var maxIndex = this._itemPositions.length - 1;
                var currentIndex;
                var currentPosition;
                while (minIndex <= maxIndex) {
                    currentIndex = (minIndex + maxIndex) / 2 | 0;
                    currentPosition = this._itemPositions[currentIndex]();
                    if (currentPosition < position) {
                        minIndex = currentIndex + 1
                    } else {
                        if (currentPosition > position) {
                            maxIndex = currentIndex - 1
                        } else {
                            return currentIndex
                        }
                    }
                }
                return mathUtils.fitIntoRange(minIndex, 0, Math.max(maxIndex, 0))
            },
            dispose: function() {
                clearTimeout(this._createGhostTimeout);
                this.callBase.apply(this, arguments)
            }
        }))
    },
    /*!*************************************************!*\
      !*** ./Scripts/ui/editor/ui.data_expression.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            variableWrapper = __webpack_require__( /*! ../../core/utils/variable_wrapper */ 38),
            dataCoreUtils = __webpack_require__( /*! ../../core/utils/data */ 36),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            FunctionTemplate = __webpack_require__( /*! ../widget/ui.template.function */ 97),
            DataHelperMixin = __webpack_require__( /*! ../collection/ui.data_helper */ 154),
            DataSourceModule = __webpack_require__( /*! ../../data/data_source/data_source */ 155),
            ArrayStore = __webpack_require__( /*! ../../data/array_store */ 162);
        var DataExpressionMixin = $.extend(DataHelperMixin, {
            _dataExpressionDefaultOptions: function() {
                return {
                    items: [],
                    dataSource: null,
                    itemTemplate: "item",
                    value: null,
                    valueExpr: "this",
                    displayExpr: void 0
                }
            },
            _initDataExpressions: function() {
                this._compileValueGetter();
                this._compileDisplayGetter();
                this._initDynamicTemplates();
                this._initDataSource();
                this._itemsToDataSource()
            },
            _itemsToDataSource: function() {
                if (!this.option("dataSource")) {
                    this._dataSource = new DataSourceModule.DataSource({
                        store: new ArrayStore(this.option("items")),
                        pageSize: 0
                    })
                }
            },
            _compileDisplayGetter: function() {
                this._displayGetter = dataCoreUtils.compileGetter(this._displayGetterExpr())
            },
            _displayGetterExpr: function() {
                return this.option("displayExpr")
            },
            _compileValueGetter: function() {
                this._valueGetter = dataCoreUtils.compileGetter(this._valueGetterExpr())
            },
            _valueGetterExpr: function() {
                return this.option("valueExpr") || "this"
            },
            _loadValue: function(value) {
                var deferred = $.Deferred();
                value = this._unwrappedValue(value);
                if (!commonUtils.isDefined(value)) {
                    return deferred.reject().promise()
                }
                this._loadSingle(this._valueGetterExpr(), value).done($.proxy(function(item) {
                    this._isValueEquals(this._valueGetter(item), value) ? deferred.resolve(item) : deferred.reject()
                }, this)).fail(function() {
                    deferred.reject()
                });
                return deferred.promise()
            },
            _getCurrentValue: function() {
                return this.option("value")
            },
            _unwrappedValue: function(value) {
                value = commonUtils.isDefined(value) ? value : this._getCurrentValue();
                if (value && this._dataSource && "this" === this._valueGetterExpr()) {
                    var key = this._dataSource.key();
                    if (key && "object" === typeof value) {
                        value = value[key]
                    }
                }
                return variableWrapper.unwrap(value)
            },
            _isValueEquals: function(value1, value2) {
                var isDefined = commonUtils.isDefined;
                var ensureDefined = commonUtils.ensureDefined;
                var unwrapObservable = variableWrapper.unwrap;
                var dataSourceKey = this._dataSource && this._dataSource.key();
                var result = this._compareValues(value1, value2);
                if (!result && isDefined(value1) && isDefined(value2) && dataSourceKey) {
                    var valueKey1 = ensureDefined(unwrapObservable(value1[dataSourceKey]), value1);
                    var valueKey2 = ensureDefined(unwrapObservable(value2[dataSourceKey]), value2);
                    result = this._compareValues(valueKey1, valueKey2)
                }
                return result
            },
            _compareValues: function(value1, value2) {
                return dataCoreUtils.toComparable(value1) === dataCoreUtils.toComparable(value2)
            },
            _initDynamicTemplates: function() {
                if (this._displayGetterExpr()) {
                    this._dynamicTemplates.item = new FunctionTemplate($.proxy(function(data) {
                        return $("<div/>").text(this._displayGetter(data)).html()
                    }, this))
                } else {
                    delete this._dynamicTemplates.item
                }
            },
            _setCollectionWidgetItemTemplate: function() {
                this._initDynamicTemplates();
                this._setCollectionWidgetOption("itemTemplate", this._getTemplateByOption("itemTemplate"))
            },
            _dataExpressionOptionChanged: function(args) {
                switch (args.name) {
                    case "items":
                        this._itemsToDataSource();
                        this._setCollectionWidgetOption("items");
                        break;
                    case "dataSource":
                        this._initDataSource();
                        break;
                    case "itemTemplate":
                        this._setCollectionWidgetItemTemplate();
                        break;
                    case "valueExpr":
                        this._compileValueGetter();
                        break;
                    case "displayExpr":
                        this._compileDisplayGetter();
                        this._setCollectionWidgetItemTemplate()
                }
            }
        });
        module.exports = DataExpressionMixin
    },
    /*!***************************!*\
      !*** ./Scripts/ui/box.js ***!
      \***************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../core/class */ 20),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            support = __webpack_require__( /*! ../core/utils/support */ 48),
            browser = __webpack_require__( /*! ../core/utils/browser */ 18),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151);
        var BOX_CLASS = "dx-box",
            BOX_SELECTOR = ".dx-box",
            BOX_ITEM_CLASS = "dx-box-item",
            BOX_ITEM_DATA_KEY = "dxBoxItemData";
        var flexGrowProp = support.styleProp("flexGrow");
        var flexShrinkProp = support.styleProp("flexShrink");
        var flexPropPrefix = support.stylePropPrefix("flexDirection");
        var MINSIZE_MAP = {
            row: "minWidth",
            col: "minHeight"
        };
        var MAXSIZE_MAP = {
            row: "maxWidth",
            col: "maxHeight"
        };
        var SHRINK = 1;
        var FLEX_JUSTIFY_CONTENT_MAP = {
            start: "flex-start",
            end: "flex-end",
            center: "center",
            "space-between": "space-between",
            "space-around": "space-around"
        };
        var FLEX_ALIGN_ITEMS_MAP = {
            start: "flex-start",
            end: "flex-end",
            center: "center",
            stretch: "stretch"
        };
        var FLEX_DIRECTION_MAP = {
            row: "row",
            col: "column"
        };
        var FlexLayoutStrategy = Class.inherit({
            ctor: function($element, option) {
                this._$element = $element;
                this._option = option
            },
            renderBox: function() {
                this._$element.css({
                    display: support.stylePropPrefix("flexDirection") + "flex",
                    flexDirection: FLEX_DIRECTION_MAP[this._option("direction")]
                })
            },
            renderAlign: function() {
                this._$element.css({
                    justifyContent: this._normalizedAlign()
                })
            },
            _normalizedAlign: function() {
                var align = this._option("align");
                return align in FLEX_JUSTIFY_CONTENT_MAP ? FLEX_JUSTIFY_CONTENT_MAP[align] : align
            },
            renderCrossAlign: function() {
                this._$element.css({
                    alignItems: this._normalizedCrossAlign()
                })
            },
            _normalizedCrossAlign: function() {
                var crossAlign = this._option("crossAlign");
                return crossAlign in FLEX_ALIGN_ITEMS_MAP ? FLEX_ALIGN_ITEMS_MAP[crossAlign] : crossAlign
            },
            renderItems: function($items) {
                var direction = this._option("direction");
                $.each($items, function() {
                    var $item = $(this);
                    var item = $item.data(BOX_ITEM_DATA_KEY);
                    $item.css({
                        display: flexPropPrefix + "flex",
                        flexBasis: item.baseSize || 0
                    }).css(MAXSIZE_MAP[direction], item.maxSize || "none").css(MINSIZE_MAP[direction], item.minSize || "0");
                    var itemStyle = $item.get(0).style;
                    itemStyle[flexGrowProp] = item.ratio;
                    itemStyle[flexShrinkProp] = commonUtils.isDefined(item.shrink) ? item.shrink : SHRINK;
                    $item.children().each(function(_, itemContent) {
                        $(itemContent).css({
                            width: "auto",
                            height: "auto",
                            display: support.stylePropPrefix("flexDirection") + "flex",
                            flexDirection: $item.children().css("flexDirection") || "column"
                        });
                        itemContent.style[flexGrowProp] = 1
                    })
                })
            },
            initSize: $.noop,
            update: $.noop
        });
        var BOX_EVENTNAMESPACE = "dxBox",
            UPDATE_EVENT = "dxupdate." + BOX_EVENTNAMESPACE,
            FALLBACK_BOX_ITEM = "dx-box-fallback-item";
        var FALLBACK_WRAP_MAP = {
            row: "nowrap",
            col: "normal"
        };
        var FALLBACK_MAIN_SIZE_MAP = {
            row: "width",
            col: "height"
        };
        var FALLBACK_CROSS_SIZE_MAP = {
            row: "height",
            col: "width"
        };
        var FALLBACK_PRE_MARGIN_MAP = {
            row: "marginLeft",
            col: "marginTop"
        };
        var FALLBACK_POST_MARGIN_MAP = {
            row: "marginRight",
            col: "marginBottom"
        };
        var FALLBACK_CROSS_PRE_MARGIN_MAP = {
            row: "marginTop",
            col: "marginLeft"
        };
        var FALLBACK_CROSS_POST_MARGIN_MAP = {
            row: "marginBottom",
            col: "marginRight"
        };
        var MARGINS_RTL_FLIP_MAP = {
            marginLeft: "marginRight",
            marginRight: "marginLeft"
        };
        var FallbackLayoutStrategy = Class.inherit({
            ctor: function($element, option) {
                this._$element = $element;
                this._option = option
            },
            renderBox: function() {
                this._$element.css({
                    fontSize: 0,
                    whiteSpace: FALLBACK_WRAP_MAP[this._option("direction")],
                    verticalAlign: "top"
                });
                this._$element.off(UPDATE_EVENT).on(UPDATE_EVENT, $.proxy(this.update, this))
            },
            renderAlign: function() {
                var $items = this._$items;
                if (!$items) {
                    return
                }
                var align = this._option("align"),
                    shift = 0,
                    totalItemSize = this.totalItemSize,
                    direction = this._option("direction"),
                    boxSize = this._$element[FALLBACK_MAIN_SIZE_MAP[direction]](),
                    freeSpace = boxSize - totalItemSize;
                this._setItemsMargins($items, direction, 0);
                switch (align) {
                    case "start":
                        break;
                    case "end":
                        shift = freeSpace;
                        $items.first().css(this._chooseMarginSide(FALLBACK_PRE_MARGIN_MAP[direction]), shift);
                        break;
                    case "center":
                        shift = .5 * freeSpace;
                        $items.first().css(this._chooseMarginSide(FALLBACK_PRE_MARGIN_MAP[direction]), shift);
                        $items.last().css(this._chooseMarginSide(FALLBACK_POST_MARGIN_MAP[direction]), shift);
                        break;
                    case "space-between":
                        shift = .5 * freeSpace / ($items.length - 1);
                        this._setItemsMargins($items, direction, shift);
                        $items.first().css(this._chooseMarginSide(FALLBACK_PRE_MARGIN_MAP[direction]), 0);
                        $items.last().css(this._chooseMarginSide(FALLBACK_POST_MARGIN_MAP[direction]), 0);
                        break;
                    case "space-around":
                        shift = .5 * freeSpace / $items.length;
                        this._setItemsMargins($items, direction, shift)
                }
            },
            _setItemsMargins: function($items, direction, shift) {
                $items.css(this._chooseMarginSide(FALLBACK_PRE_MARGIN_MAP[direction]), shift).css(this._chooseMarginSide(FALLBACK_POST_MARGIN_MAP[direction]), shift)
            },
            renderCrossAlign: function() {
                var $items = this._$items;
                if (!$items) {
                    return
                }
                var crossAlign = this._option("crossAlign"),
                    direction = this._option("direction"),
                    size = this._$element[FALLBACK_CROSS_SIZE_MAP[direction]]();
                var that = this;
                switch (crossAlign) {
                    case "start":
                        break;
                    case "end":
                        $.each($items, function() {
                            var $item = $(this),
                                itemSize = $item[FALLBACK_CROSS_SIZE_MAP[direction]](),
                                shift = size - itemSize;
                            $item.css(that._chooseMarginSide(FALLBACK_CROSS_PRE_MARGIN_MAP[direction]), shift)
                        });
                        break;
                    case "center":
                        $.each($items, function() {
                            var $item = $(this),
                                itemSize = $item[FALLBACK_CROSS_SIZE_MAP[direction]](),
                                shift = .5 * (size - itemSize);
                            $item.css(that._chooseMarginSide(FALLBACK_CROSS_PRE_MARGIN_MAP[direction]), shift).css(that._chooseMarginSide(FALLBACK_CROSS_POST_MARGIN_MAP[direction]), shift)
                        });
                        break;
                    case "stretch":
                        $items.css(that._chooseMarginSide(FALLBACK_CROSS_PRE_MARGIN_MAP[direction]), 0).css(that._chooseMarginSide(FALLBACK_CROSS_POST_MARGIN_MAP[direction]), 0).css(FALLBACK_CROSS_SIZE_MAP[direction], "100%")
                }
            },
            _chooseMarginSide: function(value) {
                if (!this._option("rtlEnabled")) {
                    return value
                }
                return MARGINS_RTL_FLIP_MAP[value] || value
            },
            renderItems: function($items) {
                this._$items = $items;
                var direction = this._option("direction"),
                    totalRatio = 0,
                    totalWeightedShrink = 0,
                    totalBaseSize = 0;
                $.each($items, $.proxy(function(_, item) {
                    var $item = $(item);
                    $item.css({
                        display: "inline-block",
                        verticalAlign: "top"
                    });
                    $item[FALLBACK_MAIN_SIZE_MAP[direction]]("auto");
                    $item.removeClass(FALLBACK_BOX_ITEM);
                    var itemData = $item.data(BOX_ITEM_DATA_KEY),
                        ratio = itemData.ratio || 0,
                        size = this._baseSize($item),
                        shrink = commonUtils.isDefined(itemData.shrink) ? itemData.shrink : SHRINK;
                    totalRatio += ratio;
                    totalWeightedShrink += shrink * size;
                    totalBaseSize += size
                }, this));
                var freeSpaceSize = this._boxSize() - totalBaseSize;
                var itemSize = $.proxy(function($item) {
                    var itemData = $item.data(BOX_ITEM_DATA_KEY),
                        size = this._baseSize($item),
                        factor = freeSpaceSize >= 0 ? itemData.ratio || 0 : (commonUtils.isDefined(itemData.shrink) ? itemData.shrink : SHRINK) * size,
                        totalFactor = freeSpaceSize >= 0 ? totalRatio : totalWeightedShrink,
                        shift = totalFactor ? Math.round(freeSpaceSize * factor / totalFactor) : 0;
                    return size + shift
                }, this);
                var totalItemSize = 0;
                $.each($items, function(_, item) {
                    var $item = $(item),
                        itemData = $(item).data(BOX_ITEM_DATA_KEY),
                        size = itemSize($item);
                    totalItemSize += size;
                    $item.css(MAXSIZE_MAP[direction], itemData.maxSize || "none").css(MINSIZE_MAP[direction], itemData.minSize || "0").css(FALLBACK_MAIN_SIZE_MAP[direction], size);
                    $item.addClass(FALLBACK_BOX_ITEM)
                });
                this.totalItemSize = totalItemSize
            },
            _baseSize: function(item) {
                var itemData = $(item).data(BOX_ITEM_DATA_KEY);
                return null == itemData.baseSize ? 0 : "auto" === itemData.baseSize ? this._contentSize(item) : this._parseSize(itemData.baseSize)
            },
            _contentSize: function(item) {
                return $(item)[FALLBACK_MAIN_SIZE_MAP[this._option("direction")]]()
            },
            _parseSize: function(size) {
                return String(size).match(/.+%$/) ? .01 * parseFloat(size) * this._boxSizeValue : size
            },
            _boxSize: function(value) {
                if (!arguments.length) {
                    this._boxSizeValue = this._boxSizeValue || this._totalBaseSize();
                    return this._boxSizeValue
                }
                this._boxSizeValue = value
            },
            _totalBaseSize: function() {
                var result = 0;
                $.each(this._$items, $.proxy(function(_, item) {
                    result += this._baseSize(item)
                }, this));
                return result
            },
            initSize: function() {
                this._boxSize(this._$element[FALLBACK_MAIN_SIZE_MAP[this._option("direction")]]())
            },
            update: function() {
                if (!this._$items || this._$element.is(":hidden")) {
                    return
                }
                this._$items.detach();
                this.initSize();
                this._$element.append(this._$items);
                this.renderItems(this._$items);
                this.renderAlign();
                this.renderCrossAlign();
                var element = this._$element.get(0);
                this._$items.find(BOX_SELECTOR).each(function() {
                    if (element === $(this).parent().closest(BOX_SELECTOR).get(0)) {
                        $(this).triggerHandler(UPDATE_EVENT)
                    }
                })
            }
        });
        var Box = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    direction: "row",
                    align: "start",
                    crossAlign: "stretch",
                    activeStateEnabled: false,
                    focusStateEnabled: false,
                    _layoutStrategy: "flex",
                    _queue: void 0
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        var device = devices.real();
                        var isOldAndroid = "android" === device.platform && (device.version[0] < 4 || 4 === device.version[0] && device.version[1] < 4),
                            isOldIos = "ios" === device.platform && device.version[0] < 7;
                        return "win" === device.platform || browser.msie || isOldAndroid || isOldIos
                    },
                    options: {
                        _layoutStrategy: "fallback"
                    }
                }])
            },
            _itemClass: function() {
                return BOX_ITEM_CLASS
            },
            _itemDataKey: function() {
                return BOX_ITEM_DATA_KEY
            },
            _itemElements: function() {
                return this._itemContainer().children(this._itemSelector())
            },
            _init: function() {
                this.callBase();
                this.element().addClass(BOX_CLASS + "-" + this.option("_layoutStrategy"));
                this._initLayout();
                this._initBoxQueue()
            },
            _initLayout: function() {
                this._layout = "fallback" === this.option("_layoutStrategy") ? new FallbackLayoutStrategy(this.element(), $.proxy(this.option, this)) : new FlexLayoutStrategy(this.element(), $.proxy(this.option, this))
            },
            _initBoxQueue: function() {
                this._queue = this.option("_queue") || []
            },
            _queueIsNotEmpty: function() {
                return this.option("_queue") ? false : !!this._queue.length
            },
            _pushItemToQueue: function($item, config) {
                this._queue.push({
                    $item: $item,
                    config: config
                })
            },
            _shiftItemFromQueue: function() {
                return this._queue.shift()
            },
            _render: function() {
                this.callBase();
                this.element().addClass(BOX_CLASS);
                this._renderBox()
            },
            _renderBox: function() {
                this._layout.renderBox();
                this._layout.renderAlign();
                this._layout.renderCrossAlign()
            },
            _renderItems: function(items) {
                this._layout.initSize();
                this.callBase(items);
                while (this._queueIsNotEmpty()) {
                    var item = this._shiftItemFromQueue();
                    this._createComponent(item.$item, Box, $.extend({
                        _layoutStrategy: this.option("_layoutStrategy"),
                        itemTemplate: this.option("itemTemplate"),
                        itemHoldTimeout: this.option("itemHoldTimeout"),
                        onItemHold: this.option("onItemHold"),
                        onItemClick: this.option("onItemClick"),
                        onItemContextMenu: this.option("onItemContextMenu"),
                        onItemRendered: this.option("onItemRendered"),
                        _queue: this._queue
                    }, item.config))
                }
                this._layout.renderItems(this._itemElements());
                clearTimeout(this._updateTimer);
                this._updateTimer = setTimeout($.proxy(function() {
                    if (!this._isUpdated) {
                        this._layout.update()
                    }
                    this._isUpdated = false;
                    this._updateTimer = null
                }, this))
            },
            _renderItemContent: function(args) {
                var $itemNode = args.itemData && args.itemData.node;
                if ($itemNode) {
                    return this._renderItemContentByNode(args, $itemNode)
                }
                return this.callBase(args)
            },
            _postprocessRenderItem: function(args) {
                var boxConfig = args.itemData.box;
                if (!boxConfig) {
                    return
                }
                this._pushItemToQueue(args.itemContent, boxConfig)
            },
            _createItemByTemplate: function(itemTemplate, args) {
                return args.itemData.box ? itemTemplate.source() : this.callBase(itemTemplate, args)
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _dimensionChanged: function() {
                if (this._updateTimer) {
                    return
                }
                this._isUpdated = true;
                this._layout.update()
            },
            _dispose: function() {
                clearTimeout(this._updateTimer);
                this.callBase.apply(this, arguments)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "_layoutStrategy":
                    case "_queue":
                    case "direction":
                        this._invalidate();
                        break;
                    case "align":
                        this._layout.renderAlign();
                        break;
                    case "crossAlign":
                        this._layout.renderCrossAlign();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            repaint: function() {
                this._dimensionChanged()
            }
        });
        registerComponent("dxBox", Box);
        module.exports = Box
    },
    /*!********************************!*\
      !*** ./Scripts/ui/calendar.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./calendar/ui.calendar */ 247)
    },
    /*!********************************************!*\
      !*** ./Scripts/ui/calendar/ui.calendar.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Button = __webpack_require__( /*! ../button */ 196),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            Swipeable = __webpack_require__( /*! ../../events/gesture/swipeable */ 248),
            Navigator = __webpack_require__( /*! ./ui.calendar.navigator */ 249),
            Views = __webpack_require__( /*! ./ui.calendar.views */ 250),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            config = __webpack_require__( /*! ../../core/config */ 15),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var CALENDAR_CLASS = "dx-calendar",
            CALENDAR_BODY_CLASS = "dx-calendar-body",
            CALENDAR_CELL_CLASS = "dx-calendar-cell",
            CALENDAR_FOOTER_CLASS = "dx-calendar-footer",
            CALENDAR_TODAY_BUTTON_CLASS = "dx-calendar-today-button",
            CALENDAR_HAS_FOOTER_CLASS = "dx-calendar-with-footer",
            CALENDAR_VIEWS_WRAPPER_CLASS = "dx-calendar-views-wrapper",
            CALENDAR_VIEW_CLASS = "dx-calendar-view",
            FOCUSED_STATE_CLASS = "dx-state-focused",
            ANIMATION_DURATION_SHOW_VIEW = 250,
            POP_ANIMATION_FROM = .6,
            POP_ANIMATION_TO = 1,
            CALENDAR_DATE_VALUE_KEY = "dxDateValueKey",
            LEVEL_COMPARE_MAP = {
                month: 3,
                year: 2,
                decade: 1,
                century: 0
            };
        var Calendar = Editor.inherit({
            _activeStateUnit: "." + CALENDAR_CELL_CLASS,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    activeStateEnabled: true,
                    currentDate: new Date,
                    value: null,
                    min: new Date(1e3, 0),
                    max: new Date(3e3, 0),
                    firstDayOfWeek: void 0,
                    zoomLevel: "month",
                    maxZoomLevel: "month",
                    minZoomLevel: "century",
                    showTodayButton: false,
                    cellTemplate: "cell",
                    onCellClick: null,
                    onContouredChanged: null,
                    hasFocus: function(element) {
                        return element.hasClass(FOCUSED_STATE_CLASS)
                    }
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _supportedKeys: function() {
                return $.extend(this.callBase(), {
                    rightArrow: function(e) {
                        e.preventDefault();
                        if (e.ctrlKey) {
                            this._waitRenderView(1)
                        } else {
                            this._moveCurrentDate(1 * this._getRtlCorrection())
                        }
                    },
                    leftArrow: function(e) {
                        e.preventDefault();
                        if (e.ctrlKey) {
                            this._waitRenderView(-1)
                        } else {
                            this._moveCurrentDate(-1 * this._getRtlCorrection())
                        }
                    },
                    upArrow: function(e) {
                        e.preventDefault();
                        if (e.ctrlKey) {
                            this._navigateUp()
                        } else {
                            if (fx.isAnimating(this._view.element())) {
                                return
                            }
                            this._moveCurrentDate(-1 * this._view.option("colCount"))
                        }
                    },
                    downArrow: function(e) {
                        e.preventDefault();
                        if (e.ctrlKey) {
                            this._navigateDown()
                        } else {
                            if (fx.isAnimating(this._view.element())) {
                                return
                            }
                            this._moveCurrentDate(1 * this._view.option("colCount"))
                        }
                    },
                    home: function(e) {
                        e.preventDefault();
                        var zoomLevel = this.option("zoomLevel");
                        var currentDate = this.option("currentDate");
                        var min = this._dateOption("min");
                        var date = dateUtils.sameView(zoomLevel, currentDate, min) ? min : dateUtils.getViewFirstCellDate(zoomLevel, currentDate);
                        this.option("currentDate", date)
                    },
                    end: function(e) {
                        e.preventDefault();
                        var zoomLevel = this.option("zoomLevel");
                        var currentDate = this.option("currentDate");
                        var max = this._dateOption("max");
                        var date = dateUtils.sameView(zoomLevel, currentDate, max) ? max : dateUtils.getViewLastCellDate(zoomLevel, currentDate);
                        this.option("currentDate", date)
                    },
                    pageUp: function(e) {
                        e.preventDefault();
                        this._waitRenderView(-1)
                    },
                    pageDown: function(e) {
                        e.preventDefault();
                        this._waitRenderView(1)
                    },
                    tab: $.noop,
                    enter: function(e) {
                        if (!this._isMaxZoomLevel()) {
                            this._navigateDown()
                        } else {
                            var value = this._updateTimeComponent(this.option("currentDate"));
                            this._dateOption("value", value)
                        }
                    }
                })
            },
            _getSerializationFormat: function() {
                var value = this.option("value");
                if (commonUtils.isNumber(value)) {
                    return "number"
                }
                if (!commonUtils.isString(value)) {
                    return
                }
                return dateUtils.getDateSerializationFormat(value)
            },
            _convertToDate: function(value) {
                var serializationFormat = this._getSerializationFormat();
                var date = dateUtils.deserializeDate(value, serializationFormat, $.proxy(dateLocalization.parse, dateLocalization));
                return date
            },
            _dateOption: function(optionName, optionValue) {
                if (1 === arguments.length) {
                    return this._convertToDate(this.option(optionName))
                }
                var serializationFormat = this._getSerializationFormat();
                this.option(optionName, dateUtils.serializeDate(optionValue, serializationFormat, $.proxy(dateLocalization.format, dateLocalization)))
            },
            _moveCurrentDate: function(offset) {
                var currentDate = new Date(this.option("currentDate"));
                var newDate = new Date(currentDate);
                var zoomLevel = this.option("zoomLevel");
                switch (zoomLevel) {
                    case "month":
                        newDate.setDate(currentDate.getDate() + offset);
                        break;
                    case "year":
                        newDate.setMonth(currentDate.getMonth() + offset);
                        break;
                    case "decade":
                        newDate.setFullYear(currentDate.getFullYear() + offset);
                        break;
                    case "century":
                        newDate.setFullYear(currentDate.getFullYear() + 10 * offset)
                }
                var offsetCorrection = 2 * offset / Math.abs(offset);
                if (Math.abs(offset) > 1 && !dateUtils.sameView(zoomLevel, currentDate, newDate)) {
                    if ("decade" === zoomLevel) {
                        newDate.setFullYear(currentDate.getFullYear() + offset - offsetCorrection)
                    }
                    if ("century" === zoomLevel) {
                        newDate.setFullYear(currentDate.getFullYear() + 10 * (offset - offsetCorrection))
                    }
                }
                this.option("currentDate", newDate)
            },
            _init: function() {
                this.callBase();
                this._correctZoomLevel();
                this._initCurrentDate();
                this._initActions()
            },
            _correctZoomLevel: function() {
                var minZoomLevel = this.option("minZoomLevel"),
                    maxZoomLevel = this.option("maxZoomLevel"),
                    zoomLevel = this.option("zoomLevel");
                if (LEVEL_COMPARE_MAP[maxZoomLevel] < LEVEL_COMPARE_MAP[minZoomLevel]) {
                    return
                }
                if (LEVEL_COMPARE_MAP[zoomLevel] > LEVEL_COMPARE_MAP[maxZoomLevel]) {
                    this.option("zoomLevel", maxZoomLevel)
                } else {
                    if (LEVEL_COMPARE_MAP[zoomLevel] < LEVEL_COMPARE_MAP[minZoomLevel]) {
                        this.option("zoomLevel", minZoomLevel)
                    }
                }
            },
            _initCurrentDate: function() {
                var currentDate = this._getNormalizedDate(this._dateOption("value")) || this._getNormalizedDate(this.option("currentDate"));
                this.option("currentDate", currentDate)
            },
            _getNormalizedDate: function(date) {
                date = dateUtils.normalizeDate(date, this._getMinDate(), this._getMaxDate());
                return commonUtils.isDefined(date) ? new Date(date) : date
            },
            _initActions: function() {
                this._cellClickAction = this._createActionByOption("onCellClick");
                this._onContouredChanged = this._createActionByOption("onContouredChanged")
            },
            _updateCurrentDate: function(date) {
                if (fx.isAnimating(this._$viewsWrapper)) {
                    fx.stop(this._$viewsWrapper, true)
                }
                var min = this._getMinDate(),
                    max = this._getMaxDate();
                if (min > max) {
                    this.option("currentDate", new Date);
                    return
                }
                var normalizedDate = this._getNormalizedDate(date);
                if (date.getTime() !== normalizedDate.getTime()) {
                    this.option("currentDate", new Date(normalizedDate));
                    return
                }
                var offset = this._getViewsOffset(this._view.option("date"), normalizedDate);
                if (0 !== offset && !this._isMaxZoomLevel() && this._isOtherViewCellClicked) {
                    offset = 0
                }
                if (this._view && 0 !== offset && !this._suppressNavigation) {
                    this._navigate(offset, normalizedDate)
                } else {
                    this._renderNavigator();
                    this._setViewContoured(normalizedDate);
                    this._updateAriaId(normalizedDate)
                }
            },
            _setViewContoured: function(date) {
                if (this.option("hasFocus")(this._focusTarget())) {
                    this._view.option("contouredDate", date)
                }
            },
            _getMinDate: function() {
                if (this.min) {
                    return this.min
                }
                this.min = this._dateOption("min") || new Date(1e3, 0);
                return this.min
            },
            _getMaxDate: function() {
                if (this.max) {
                    return this.max
                }
                this.max = this._dateOption("max") || new Date(3e3, 0);
                return this.max
            },
            _getViewsOffset: function(startDate, endDate) {
                var zoomLevel = this.option("zoomLevel");
                if ("month" === zoomLevel) {
                    return this._getMonthsOffset(startDate, endDate)
                }
                var zoomCorrection;
                switch (zoomLevel) {
                    case "century":
                        zoomCorrection = 100;
                        break;
                    case "decade":
                        zoomCorrection = 10;
                        break;
                    default:
                        zoomCorrection = 1
                }
                return parseInt(endDate.getFullYear() / zoomCorrection) - parseInt(startDate.getFullYear() / zoomCorrection)
            },
            _getMonthsOffset: function(startDate, endDate) {
                var yearOffset = endDate.getFullYear() - startDate.getFullYear(),
                    monthOffset = endDate.getMonth() - startDate.getMonth();
                return 12 * yearOffset + monthOffset
            },
            _waitRenderView: function(offset) {
                if (this._alreadyViewRender) {
                    return
                }
                this._alreadyViewRender = true;
                var date = this._getDateByOffset(offset * this._getRtlCorrection());
                this.option("currentDate", date);
                setTimeout($.proxy(function() {
                    this._alreadyViewRender = false
                }, this))
            },
            _getRtlCorrection: function() {
                return this.option("rtlEnabled") ? -1 : 1
            },
            _getDateByOffset: function(offset, date) {
                date = new Date(date || this.option("currentDate"));
                var currentDay = date.getDate();
                var difference = dateUtils.getDifferenceInMonth(this.option("zoomLevel")) * offset;
                date.setDate(1);
                date.setMonth(date.getMonth() + difference);
                var lastDay = dateUtils.getLastMonthDate(date).getDate();
                date.setDate(currentDay > lastDay ? lastDay : currentDay);
                return date
            },
            _focusTarget: function() {
                return this.element()
            },
            _render: function() {
                this.callBase();
                this.element().addClass(CALENDAR_CLASS);
                this._renderBody();
                this.element().append(this.$body);
                this._renderViews();
                this._renderNavigator();
                this._renderSwipeable();
                this._renderFooter();
                this.setAria({
                    role: "listbox",
                    label: messageLocalization.format("dxCalendar-ariaWidgetName")
                });
                this._updateAriaSelected();
                this._updateAriaId();
                this._setViewContoured(this.option("currentDate"));
                this.element().append(this._navigator.element())
            },
            _renderBody: function() {
                if (!this._$viewsWrapper) {
                    this.$body = $("<div>").addClass(CALENDAR_BODY_CLASS);
                    this._$viewsWrapper = $("<div>").addClass(CALENDAR_VIEWS_WRAPPER_CLASS);
                    this.$body.append(this._$viewsWrapper)
                }
            },
            _renderViews: function() {
                this.element().addClass(CALENDAR_VIEW_CLASS + "-" + this.option("zoomLevel"));
                var currentDate = this.option("currentDate");
                this._view = this._renderSpecificView(currentDate);
                this._view.option("_keyboardProcessor", this._viewKeyboardProcessor);
                var beforeDate = this._getDateByOffset(-1, currentDate);
                this._beforeView = this._isViewAvailable(beforeDate) ? this._renderSpecificView(beforeDate) : null;
                var afterDate = this._getDateByOffset(1, currentDate);
                this._afterView = this._isViewAvailable(afterDate) ? this._renderSpecificView(afterDate) : null;
                this._translateViews()
            },
            _renderSpecificView: function(date) {
                var specificView = Views[this.option("zoomLevel")],
                    $view = $("<div>").appendTo(this._$viewsWrapper),
                    config = this._viewConfig(date);
                return new specificView($view, config)
            },
            _viewConfig: function(date) {
                return {
                    date: date,
                    min: this._getMinDate(),
                    max: this._getMaxDate(),
                    firstDayOfWeek: this.option("firstDayOfWeek"),
                    value: this._dateOption("value"),
                    rtl: this.option("rtlEnabled"),
                    disabled: this.option("disabled") || config().designMode,
                    tabIndex: void 0,
                    focusStateEnabled: this.option("focusStateEnabled"),
                    hoverStateEnabled: this.option("hoverStateEnabled"),
                    onCellClick: $.proxy(this._cellClickHandler, this),
                    cellTemplate: this._getTemplateByOption("cellTemplate"),
                    allowValueSelection: this._isMaxZoomLevel()
                }
            },
            _isViewAvailable: function(date) {
                var zoomLevel = this.option("zoomLevel");
                var min = dateUtils.getViewMinBoundaryDate(zoomLevel, this._getMinDate());
                var max = dateUtils.getViewMaxBoundaryDate(zoomLevel, this._getMaxDate());
                return dateUtils.dateInRange(date, min, max)
            },
            _translateViews: function() {
                translator.move(this._view.element(), {
                    left: 0,
                    top: 0
                });
                this._beforeView && translator.move(this._beforeView.element(), {
                    left: this._getViewPosition(-1),
                    top: 0
                });
                this._afterView && translator.move(this._afterView.element(), {
                    left: this._getViewPosition(1),
                    top: 0
                })
            },
            _getViewPosition: function(coefficient) {
                var rtlCorrection = this.option("rtlEnabled") && !(browser.msie && "8" !== browser.version[0]) ? -1 : 1;
                return 100 * coefficient * rtlCorrection + "%"
            },
            _cellClickHandler: function(e) {
                var zoomLevel = this.option("zoomLevel"),
                    nextView = dateUtils.getViewDown(zoomLevel);
                var isMaxZoomLevel = this._isMaxZoomLevel();
                if (nextView && !isMaxZoomLevel) {
                    this._navigateDown(e.jQueryEvent.currentTarget)
                } else {
                    var newValue = this._updateTimeComponent(e.value);
                    this._dateOption("value", newValue);
                    this._cellClickAction(e)
                }
            },
            _updateTimeComponent: function(date) {
                var result = new Date(date);
                var currentValue = this._dateOption("value");
                if (currentValue) {
                    result.setHours(currentValue.getHours());
                    result.setMinutes(currentValue.getMinutes());
                    result.setSeconds(currentValue.getSeconds());
                    result.setMilliseconds(currentValue.getMilliseconds())
                }
                return result
            },
            _isMaxZoomLevel: function() {
                return this.option("zoomLevel") === this.option("maxZoomLevel")
            },
            _navigateDown: function(cell) {
                var zoomLevel = this.option("zoomLevel");
                if (this._isMaxZoomLevel()) {
                    return
                }
                var nextView = dateUtils.getViewDown(zoomLevel);
                if (!nextView) {
                    return
                }
                var newCurrentDate = this._view.option("contouredDate") || this._view.option("date");
                if (cell) {
                    newCurrentDate = $(cell).data(CALENDAR_DATE_VALUE_KEY)
                }
                this._isOtherViewCellClicked = true;
                this.option("currentDate", newCurrentDate);
                this.option("zoomLevel", nextView);
                this._isOtherViewCellClicked = false;
                this._renderNavigator();
                this._animateShowView();
                this._setViewContoured(this._getNormalizedDate(newCurrentDate))
            },
            _renderNavigator: function() {
                if (!this._navigator) {
                    this._navigator = new Navigator($("<div>"), this._navigatorConfig())
                }
                this._navigator.option("text", this._view.getNavigatorCaption());
                this._updateButtonsVisibility()
            },
            _navigatorConfig: function() {
                return {
                    text: this._view.getNavigatorCaption(),
                    onClick: $.proxy(this._navigatorClickHandler, this),
                    onCaptionClick: $.proxy(this._navigateUp, this),
                    rtlEnabled: this.option("rtlEnabled")
                }
            },
            _navigatorClickHandler: function(e) {
                var currentDate = this._getDateByOffset(e.direction, this.option("currentDate"));
                this.option("currentDate", currentDate);
                this._updateNavigatorCaption(-e.direction * this._getRtlCorrection())
            },
            _navigateUp: function() {
                var zoomLevel = this.option("zoomLevel"),
                    nextView = dateUtils.getViewUp(zoomLevel);
                if (!nextView || this._isMinZoomLevel(zoomLevel)) {
                    return
                }
                var contouredDate = this._view.option("contouredDate");
                this.option("zoomLevel", nextView);
                this.option("currentDate", contouredDate || this._view.option("date"));
                this._renderNavigator();
                this._animateShowView().done($.proxy(function() {
                    this._setViewContoured(contouredDate)
                }, this))
            },
            _isMinZoomLevel: function(zoomLevel) {
                var min = this._getMinDate(),
                    max = this._getMaxDate();
                return dateUtils.sameView(zoomLevel, min, max) || this.option("minZoomLevel") === zoomLevel
            },
            _updateButtonsVisibility: function() {
                this._navigator.toggleButton("next", !commonUtils.isDefined(this._getRequiredView("next")));
                this._navigator.toggleButton("prev", !commonUtils.isDefined(this._getRequiredView("prev")))
            },
            _renderSwipeable: function() {
                if (!this._swipeable) {
                    this._swipeable = this._createComponent(this.element(), Swipeable, {
                        onStart: $.proxy(this._swipeStartHandler, this),
                        onUpdated: $.proxy(this._swipeUpdateHandler, this),
                        onEnd: $.proxy(this._swipeEndHandler, this),
                        itemSizeFunc: $.proxy(this._viewWidth, this)
                    })
                }
            },
            _swipeStartHandler: function(e) {
                fx.stop(this._$viewsWrapper, true);
                e.jQueryEvent.maxLeftOffset = this._getRequiredView("next") ? 1 : 0;
                e.jQueryEvent.maxRightOffset = this._getRequiredView("prev") ? 1 : 0
            },
            _getRequiredView: function(name) {
                var view;
                var isRtl = this.option("rtlEnabled");
                if ("next" === name) {
                    view = isRtl ? this._beforeView : this._afterView
                } else {
                    if ("prev" === name) {
                        view = isRtl ? this._afterView : this._beforeView
                    }
                }
                return view
            },
            _swipeUpdateHandler: function(e) {
                var offset = e.jQueryEvent.offset;
                translator.move(this._$viewsWrapper, {
                    left: offset * this._viewWidth(),
                    top: 0
                });
                this._updateNavigatorCaption(offset)
            },
            _swipeEndHandler: function(e) {
                var targetOffset = e.jQueryEvent.targetOffset,
                    moveOffset = !targetOffset ? 0 : targetOffset / Math.abs(targetOffset);
                if (0 === moveOffset) {
                    this._animateWrapper(0, ANIMATION_DURATION_SHOW_VIEW);
                    return
                }
                var date = this._getDateByOffset(-moveOffset * this._getRtlCorrection());
                if (this._isDateInInvalidRange(date)) {
                    if (moveOffset >= 0) {
                        date = new Date(this._getMinDate())
                    } else {
                        date = new Date(this._getMaxDate())
                    }
                }
                this.option("currentDate", date)
            },
            _viewWidth: function() {
                if (!this._viewWidthValue) {
                    this._viewWidthValue = this.element().width()
                }
                return this._viewWidthValue
            },
            _updateNavigatorCaption: function(offset) {
                offset *= this._getRtlCorrection();
                var view = this._view;
                if (offset > .5 && this._beforeView) {
                    view = this._beforeView
                } else {
                    if (offset < -.5 && this._afterView) {
                        view = this._afterView
                    }
                }
                this._navigator.option("text", view.getNavigatorCaption())
            },
            _isDateInInvalidRange: function(date) {
                if (this._view.isBoundary(date)) {
                    return
                }
                var min = this._getMinDate(),
                    max = this._getMaxDate(),
                    normalizedDate = dateUtils.normalizeDate(date, min, max);
                return normalizedDate === min || normalizedDate === max
            },
            _renderFooter: function() {
                var showTodayButton = this.option("showTodayButton");
                if (showTodayButton) {
                    var $todayButton = this._createComponent($("<a>"), Button, {
                        focusStateEnabled: false,
                        text: messageLocalization.format("dxCalendar-todayButtonText"),
                        onClick: $.proxy(function() {
                            this._toTodayView()
                        }, this),
                        _templates: {}
                    }).element().addClass(CALENDAR_TODAY_BUTTON_CLASS);
                    this._$footer = $("<div>").addClass(CALENDAR_FOOTER_CLASS).append($todayButton);
                    this.element().append(this._$footer)
                }
                this.element().toggleClass(CALENDAR_HAS_FOOTER_CLASS, showTodayButton)
            },
            _animateShowView: function() {
                fx.stop(this._view.element(), true);
                return this._popAnimationView(this._view, POP_ANIMATION_FROM, POP_ANIMATION_TO, ANIMATION_DURATION_SHOW_VIEW).promise()
            },
            _popAnimationView: function(view, from, to, duration) {
                return fx.animate(view.element(), {
                    type: "pop",
                    from: {
                        scale: from,
                        opacity: from
                    },
                    to: {
                        scale: to,
                        opacity: to
                    },
                    duration: duration
                })
            },
            _navigate: function(offset, value) {
                if (0 !== offset && 1 !== Math.abs(offset) && this._isViewAvailable(value)) {
                    var newView = this._renderSpecificView(value);
                    if (offset > 0) {
                        this._afterView && this._afterView.element().remove();
                        this._afterView = newView
                    } else {
                        this._beforeView && this._beforeView.element().remove();
                        this._beforeView = newView
                    }
                    this._translateViews()
                }
                var rtlCorrection = this._getRtlCorrection(),
                    offsetSign = offset > 0 ? 1 : offset < 0 ? -1 : 0,
                    endPosition = -rtlCorrection * offsetSign * this._viewWidth();
                var viewsWrapperPosition = this._$viewsWrapper.position().left;
                if (viewsWrapperPosition !== endPosition) {
                    if (this._preventViewChangeAnimation) {
                        this._wrapperAnimationEndHandler(offset, value)
                    } else {
                        this._animateWrapper(endPosition, ANIMATION_DURATION_SHOW_VIEW).done($.proxy(this._wrapperAnimationEndHandler, this, offset, value))
                    }
                }
            },
            _animateWrapper: function(to, duration) {
                return fx.animate(this._$viewsWrapper, {
                    type: "slide",
                    from: {
                        left: this._$viewsWrapper.position().left
                    },
                    to: {
                        left: to
                    },
                    duration: duration
                })
            },
            _toTodayView: function() {
                var today = new Date;
                if (this._isMaxZoomLevel()) {
                    this._dateOption("value", today);
                    return
                }
                this._preventViewChangeAnimation = true;
                this.option("zoomLevel", this.option("maxZoomLevel"));
                this._dateOption("value", today);
                this._animateShowView();
                this._preventViewChangeAnimation = false
            },
            _wrapperAnimationEndHandler: function(offset, newDate) {
                this._rearrangeViews(offset);
                this._translateViews();
                this._resetLocation();
                this._renderNavigator();
                this._setViewContoured(newDate);
                this._updateAriaId(newDate, this.option(""))
            },
            _rearrangeViews: function(offset) {
                if (0 === offset) {
                    return
                }
                var viewOffset, viewToCreateKey, viewToRemoveKey;
                if (offset < 0) {
                    viewOffset = 1;
                    viewToCreateKey = "_beforeView";
                    viewToRemoveKey = "_afterView"
                } else {
                    viewOffset = -1;
                    viewToCreateKey = "_afterView";
                    viewToRemoveKey = "_beforeView"
                }
                if (!this[viewToCreateKey]) {
                    return
                }
                var destinationDate = this[viewToCreateKey].option("date");
                if (this[viewToRemoveKey]) {
                    this[viewToRemoveKey].element().remove()
                }
                if (offset === viewOffset) {
                    this[viewToRemoveKey] = this._view
                } else {
                    this[viewToRemoveKey] = this._renderSpecificView(this._getDateByOffset(viewOffset, destinationDate));
                    this._view.element().remove()
                }
                this._view = this[viewToCreateKey];
                var dateByOffset = this._getDateByOffset(-viewOffset, destinationDate);
                this[viewToCreateKey] = this._isViewAvailable(dateByOffset) ? this._renderSpecificView(dateByOffset) : null
            },
            _resetLocation: function() {
                translator.move(this._$viewsWrapper, {
                    left: 0,
                    top: 0
                })
            },
            _clean: function() {
                this.callBase();
                this._clearViewWidthCache();
                delete this._$viewsWrapper;
                delete this._navigator;
                delete this._$footer
            },
            _clearViewWidthCache: function() {
                delete this._viewWidthValue
            },
            _disposeViews: function() {
                this._view.element().remove();
                this._beforeView && this._beforeView.element().remove();
                this._afterView && this._afterView.element().remove();
                delete this._view;
                delete this._beforeView;
                delete this._afterView
            },
            _refreshViews: function() {
                this._disposeViews();
                this._renderViews()
            },
            _visibilityChanged: function() {
                this._translateViews()
            },
            _focusInHandler: function() {
                this.callBase.apply(this, arguments);
                this._view.option("contouredDate", this.option("currentDate"))
            },
            _focusOutHandler: function() {
                this.callBase.apply(this, arguments);
                this._view.option("contouredDate", null)
            },
            _updateViewsValue: function(value) {
                var newValue = value ? new Date(value) : null;
                this._view.option("value", newValue);
                this._beforeView && this._beforeView.option("value", newValue);
                this._afterView && this._afterView.option("value", newValue)
            },
            _updateAriaSelected: function(value, previousValue) {
                value = value || this._dateOption("value");
                var $prevSelectedCell = this._view._getCellByDate(previousValue);
                var $selectedCell = this._view._getCellByDate(value);
                this.setAria("selected", void 0, $prevSelectedCell);
                this.setAria("selected", true, $selectedCell);
                if (value && this.option("currentDate").getTime() === value.getTime()) {
                    this._updateAriaId(value, previousValue)
                }
            },
            _updateAriaId: function(value, previousValue) {
                value = value || this.option("currentDate");
                var ariaId = new Guid;
                var $newCell = this._view._getCellByDate(value);
                this.setAria("id", ariaId, $newCell);
                this.setAria("activedescendant", ariaId);
                this._onContouredChanged(ariaId)
            },
            _suppressingNavigation: function(callback, args) {
                this._suppressNavigation = true;
                callback.apply(this, args);
                delete this._suppressNavigation
            },
            _optionChanged: function(args) {
                var value = args.value;
                var previousValue = args.previousValue;
                switch (args.name) {
                    case "width":
                        this.callBase(args);
                        this._clearViewWidthCache();
                        break;
                    case "min":
                    case "max":
                        this.min = void 0;
                        this.max = void 0;
                        this._suppressingNavigation(this._updateCurrentDate, [this.option("currentDate")]);
                        this._refreshViews();
                        this._renderNavigator();
                        break;
                    case "firstDayOfWeek":
                        this._refreshViews();
                        this._updateButtonsVisibility();
                        break;
                    case "currentDate":
                        this.setAria("id", void 0, this._view._getCellByDate(previousValue));
                        this._updateCurrentDate(value);
                        break;
                    case "zoomLevel":
                        this.element().removeClass(CALENDAR_VIEW_CLASS + "-" + previousValue);
                        this._correctZoomLevel();
                        this._refreshViews();
                        this._renderNavigator();
                        this._updateAriaId();
                        break;
                    case "minZoomLevel":
                    case "maxZoomLevel":
                        this._correctZoomLevel();
                        this._updateButtonsVisibility();
                        break;
                    case "value":
                        value = this._convertToDate(value);
                        previousValue = this._convertToDate(previousValue);
                        this._updateAriaSelected(value, previousValue);
                        this.option("currentDate", commonUtils.isDefined(value) ? new Date(value) : new Date);
                        this._updateViewsValue(value);
                        this.callBase(args);
                        break;
                    case "disabled":
                        this._view.option("disabled", value);
                        this.callBase(args);
                        break;
                    case "showTodayButton":
                        this._invalidate();
                        break;
                    case "onCellClick":
                        this._view.option("onCellClick", value);
                        break;
                    case "onContouredChanged":
                        this._onContouredChanged = this._createActionByOption("onContouredChanged");
                        break;
                    case "cellTemplate":
                        this._invalidate();
                        break;
                    case "hasFocus":
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxCalendar", Calendar);
        module.exports = Calendar
    },
    /*!*********************************************!*\
      !*** ./Scripts/events/gesture/swipeable.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            swipeEvents = __webpack_require__( /*! ../swipe */ 178),
            DOMComponent = __webpack_require__( /*! ../../core/dom_component */ 29),
            eventUtils = __webpack_require__( /*! ../utils */ 62);
        var DX_SWIPEABLE = "dxSwipeable",
            SWIPEABLE_CLASS = "dx-swipeable",
            ACTION_TO_EVENT_MAP = {
                onStart: swipeEvents.start,
                onUpdated: swipeEvents.swipe,
                onEnd: swipeEvents.end,
                onCancel: "dxswipecancel"
            };
        var Swipeable = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    elastic: true,
                    immediate: false,
                    direction: "horizontal",
                    itemSizeFunc: null,
                    onStart: null,
                    onUpdated: null,
                    onEnd: null,
                    onCancel: null
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass(SWIPEABLE_CLASS);
                this._attachEventHandlers()
            },
            _attachEventHandlers: function() {
                this._detachEventHandlers();
                if (this.option("disabled")) {
                    return
                }
                var NAME = this.NAME;
                this._createEventData();
                $.each(ACTION_TO_EVENT_MAP, $.proxy(function(actionName, eventName) {
                    var action = this._createActionByOption(actionName, {
                        context: this
                    });
                    eventName = eventUtils.addNamespace(eventName, NAME);
                    this.element().on(eventName, this._eventData, function(e) {
                        return action({
                            jQueryEvent: e
                        })
                    })
                }, this))
            },
            _createEventData: function() {
                this._eventData = {
                    elastic: this.option("elastic"),
                    itemSizeFunc: this.option("itemSizeFunc"),
                    direction: this.option("direction"),
                    immediate: this.option("immediate")
                }
            },
            _detachEventHandlers: function() {
                this.element().off("." + DX_SWIPEABLE)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "disabled":
                    case "onStart":
                    case "onUpdated":
                    case "onEnd":
                    case "onCancel":
                    case "elastic":
                    case "immediate":
                    case "itemSizeFunc":
                    case "direction":
                        this._detachEventHandlers();
                        this._attachEventHandlers();
                        break;
                    case "rtlEnabled":
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        Swipeable.publicName(DX_SWIPEABLE);
        module.exports = Swipeable
    },
    /*!******************************************************!*\
      !*** ./Scripts/ui/calendar/ui.calendar.navigator.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            Button = __webpack_require__( /*! ../button */ 196);
        var CALENDAR_NAVIGATOR_CLASS = "dx-calendar-navigator",
            CALENDAR_NAVIGATOR_PREVIOUS_MONTH_CLASS = "dx-calendar-navigator-previous-month",
            CALENDAR_NAVIGATOR_NEXT_MONTH_CLASS = "dx-calendar-navigator-next-month",
            CALENDAR_NAVIGATOR_PREVIOUS_VIEW_CLASS = "dx-calendar-navigator-previous-view",
            CALENDAR_NAVIGATOR_NEXT_VIEW_CLASS = "dx-calendar-navigator-next-view",
            CALENDAR_NAVIGATOR_DISABLED_LINK_CLASS = "dx-calendar-disabled-navigator-link",
            CALENDAR_NAVIGATOR_CAPTION_BUTTON_CLASS = "dx-calendar-caption-button";
        var Navigator = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    onClick: null,
                    onCaptionClick: null,
                    text: ""
                })
            },
            _init: function() {
                this.callBase();
                this._initActions()
            },
            _initActions: function() {
                this._clickAction = this._createActionByOption("onClick");
                this._captionClickAction = this._createActionByOption("onCaptionClick")
            },
            _render: function() {
                this.callBase();
                this.element().addClass(CALENDAR_NAVIGATOR_CLASS);
                this._renderButtons();
                this._renderCaption()
            },
            _renderButtons: function() {
                var that = this,
                    direction = this.option("rtlEnabled") ? -1 : 1;
                this._prevButton = this._createComponent($("<a>"), Button, {
                    focusStateEnabled: false,
                    icon: "chevronleft",
                    onClick: function(e) {
                        that._clickAction({
                            direction: -direction,
                            jQueryEvent: e
                        })
                    },
                    _templates: {}
                });
                var $prevButton = this._prevButton.element().addClass(CALENDAR_NAVIGATOR_PREVIOUS_VIEW_CLASS).addClass(CALENDAR_NAVIGATOR_PREVIOUS_MONTH_CLASS);
                this._nextButton = this._createComponent($("<a>"), Button, {
                    focusStateEnabled: false,
                    icon: "chevronright",
                    onClick: function(e) {
                        that._clickAction({
                            direction: direction,
                            jQueryEvent: e
                        })
                    },
                    _templates: {}
                });
                var $nextButton = this._nextButton.element().addClass(CALENDAR_NAVIGATOR_NEXT_VIEW_CLASS).addClass(CALENDAR_NAVIGATOR_NEXT_MONTH_CLASS);
                this._caption = this._createComponent($("<a>").addClass(CALENDAR_NAVIGATOR_CAPTION_BUTTON_CLASS), Button, {
                    focusStateEnabled: false,
                    onClick: function(e) {
                        that._captionClickAction({
                            jQueryEvent: e
                        })
                    },
                    _templates: {}
                });
                var $caption = this._caption.element();
                this.element().append($prevButton, $caption, $nextButton)
            },
            _renderCaption: function(caption) {
                this._caption.option("text", this.option("text"))
            },
            toggleButton: function(buttonPrefix, value) {
                var buttonName = "_" + buttonPrefix + "Button",
                    button = this[buttonName];
                if (button) {
                    button.option("disabled", value);
                    button.element().toggleClass(CALENDAR_NAVIGATOR_DISABLED_LINK_CLASS, value)
                }
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "text":
                        this._renderCaption(value);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        module.exports = Navigator
    },
    /*!**************************************************!*\
      !*** ./Scripts/ui/calendar/ui.calendar.views.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseView = __webpack_require__( /*! ./ui.calendar.base_view */ 251),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var CALENDAR_OTHER_MONTH_CLASS = "dx-calendar-other-month",
            CALENDAR_OTHER_VIEW_CLASS = "dx-calendar-other-view";
        var Views = {
            month: BaseView.inherit({
                _getViewName: function() {
                    return "month"
                },
                _getDefaultOptions: function() {
                    return $.extend(this.callBase(), {
                        firstDayOfWeek: void 0,
                        rowCount: 6,
                        colCount: 7
                    })
                },
                _renderImpl: function() {
                    this.callBase();
                    this._renderHeader()
                },
                _renderBody: function() {
                    this.callBase();
                    this._$table.find("." + CALENDAR_OTHER_VIEW_CLASS).addClass(CALENDAR_OTHER_MONTH_CLASS)
                },
                _renderFocusTarget: $.noop,
                getCellAriaLabel: function(date) {
                    return dateLocalization.format(date, "longdate")
                },
                _renderHeader: function() {
                    var that = this;
                    var $header = $("<thead>");
                    this._$table.prepend($header);
                    var $headerRow = $("<tr>");
                    $header.append($headerRow);
                    var appendCell = this.option("rtl") ? function(row, cell) {
                        row.prepend(cell)
                    } : function(row, cell) {
                        row.append(cell)
                    };
                    this._iterateCells(this.option("colCount"), function(i) {
                        var $cell = $("<th>").text(that._getDayCaption(that._getFirstDayOfWeek() + i));
                        appendCell($headerRow, $cell)
                    })
                },
                getNavigatorCaption: function() {
                    return dateLocalization.format(this.option("date"), "monthandyear")
                },
                _isTodayCell: function(cellDate) {
                    var today = new Date;
                    return dateUtils.sameDate(cellDate, today)
                },
                _isDateOutOfRange: function(cellDate) {
                    var minDate = this.option("min"),
                        maxDate = this.option("max");
                    return !dateUtils.dateInRange(cellDate, minDate, maxDate, "date")
                },
                _isOtherView: function(cellDate) {
                    return cellDate.getMonth() !== this.option("date").getMonth()
                },
                _getCellText: function(cellDate) {
                    return cellDate.getDate()
                },
                _getDayCaption: function(day) {
                    var daysInWeek = this.option("colCount");
                    return dateLocalization.getDayNames("abbreviated")[day % daysInWeek]
                },
                _getFirstCellData: function() {
                    var firstDay = dateUtils.getFirstMonthDate(this.option("date")),
                        firstMonthDayOffset = this._getFirstDayOfWeek() - firstDay.getDay(),
                        daysInWeek = this.option("colCount");
                    if (firstMonthDayOffset >= 0) {
                        firstMonthDayOffset -= daysInWeek
                    }
                    firstDay.setDate(firstDay.getDate() + firstMonthDayOffset);
                    return firstDay
                },
                _getNextCellData: function(date) {
                    date = new Date(date);
                    date.setDate(date.getDate() + 1);
                    return date
                },
                _getFirstDayOfWeek: function() {
                    return this.option("firstDayOfWeek") || dateLocalization.firstDayOfWeekIndex()
                },
                _getCellByDate: function(date) {
                    return this._$table.find("td[data-value='" + dateLocalization.format(date, dateUtils.getShortDateFormat()) + "']")
                },
                isBoundary: function(date) {
                    return dateUtils.sameMonthAndYear(date, this.option("min")) || dateUtils.sameMonthAndYear(date, this.option("max"))
                }
            }),
            year: BaseView.inherit({
                _getViewName: function() {
                    return "year"
                },
                _isTodayCell: function(cellDate) {
                    return dateUtils.sameMonthAndYear(cellDate, new Date)
                },
                _isDateOutOfRange: function(cellDate) {
                    return !dateUtils.dateInRange(cellDate, dateUtils.getFirstMonthDate(this.option("min")), dateUtils.getLastMonthDate(this.option("max")))
                },
                _isOtherView: function(cellDate) {
                    return false
                },
                _getCellText: function(cellDate) {
                    return dateLocalization.getMonthNames()[cellDate.getMonth()].slice(0, 3)
                },
                _getFirstCellData: function() {
                    var data = new Date(this.option("date"));
                    data.setDate(1);
                    data.setMonth(0);
                    return data
                },
                _getNextCellData: function(date) {
                    date = new Date(date);
                    date.setMonth(date.getMonth() + 1);
                    return date
                },
                _getCellByDate: function(date) {
                    var foundDate = new Date(date);
                    foundDate.setDate(1);
                    return this._$table.find("td[data-value='" + dateLocalization.format(foundDate, dateUtils.getShortDateFormat()) + "']")
                },
                getCellAriaLabel: function(date) {
                    return dateLocalization.format(date, "monthandyear")
                },
                getNavigatorCaption: function() {
                    return this.option("date").getFullYear()
                },
                isBoundary: function(date) {
                    return dateUtils.sameYear(date, this.option("min")) || dateUtils.sameYear(date, this.option("max"))
                }
            }),
            decade: BaseView.inherit({
                _getViewName: function() {
                    return "decade"
                },
                _isTodayCell: function(cellDate) {
                    return dateUtils.sameYear(cellDate, new Date)
                },
                _isDateOutOfRange: function(cellDate) {
                    var min = this.option("min"),
                        max = this.option("max");
                    return !dateUtils.dateInRange(cellDate.getFullYear(), min && min.getFullYear(), max && max.getFullYear())
                },
                _isOtherView: function(cellDate) {
                    var date = new Date(cellDate);
                    date.setMonth(1);
                    return !dateUtils.sameDecade(date, this.option("date"))
                },
                _getCellText: function(cellDate) {
                    return cellDate.getFullYear()
                },
                _getFirstCellData: function() {
                    var year = dateUtils.getFirstYearInDecade(this.option("date")) - 1;
                    return new Date(year, 0, 1)
                },
                _getNextCellData: function(date) {
                    date = new Date(date);
                    date.setFullYear(date.getFullYear() + 1);
                    return date
                },
                getNavigatorCaption: function() {
                    var year = dateUtils.getFirstYearInDecade(this.option("date"));
                    return year + "-" + (year + 9)
                },
                _isValueOnCurrentView: function(currentDate, value) {
                    return dateUtils.sameDecade(currentDate, value)
                },
                _getCellByDate: function(date) {
                    var foundDate = new Date(date);
                    foundDate.setDate(1);
                    foundDate.setMonth(0);
                    return this._$table.find("td[data-value='" + dateLocalization.format(foundDate, dateUtils.getShortDateFormat()) + "']")
                },
                isBoundary: function(date) {
                    return dateUtils.sameDecade(date, this.option("min")) || dateUtils.sameDecade(date, this.option("max"))
                }
            }),
            century: BaseView.inherit({
                _getViewName: function() {
                    return "century"
                },
                _isTodayCell: function(cellDate) {
                    return dateUtils.sameDecade(cellDate, new Date)
                },
                _isDateOutOfRange: function(cellDate) {
                    var decade = dateUtils.getFirstYearInDecade(cellDate),
                        minDecade = dateUtils.getFirstYearInDecade(this.option("min")),
                        maxDecade = dateUtils.getFirstYearInDecade(this.option("max"));
                    return !dateUtils.dateInRange(decade, minDecade, maxDecade)
                },
                _isOtherView: function(cellDate) {
                    var date = new Date(cellDate);
                    date.setMonth(1);
                    return !dateUtils.sameCentury(date, this.option("date"))
                },
                _getCellText: function(cellDate) {
                    var decade = cellDate.getFullYear();
                    return decade + " - " + (decade + 9)
                },
                _getFirstCellData: function(indexRow, cellIndex) {
                    var decade = dateUtils.getFirstDecadeInCentury(this.option("date")) - 10;
                    return new Date(decade, 0, 1)
                },
                _getNextCellData: function(date) {
                    date = new Date(date);
                    date.setFullYear(date.getFullYear() + 10);
                    return date
                },
                _getCellByDate: function(date) {
                    var foundDate = new Date(date);
                    foundDate.setDate(1);
                    foundDate.setMonth(0);
                    foundDate.setFullYear(dateUtils.getFirstYearInDecade(foundDate));
                    return this._$table.find("td[data-value='" + dateLocalization.format(foundDate, dateUtils.getShortDateFormat()) + "']")
                },
                getNavigatorCaption: function() {
                    var decade = dateUtils.getFirstDecadeInCentury(this.option("date"));
                    return decade + "-" + (decade + 99)
                },
                isBoundary: function(date) {
                    return dateUtils.sameCentury(date, this.option("min")) || dateUtils.sameCentury(date, this.option("max"))
                }
            })
        };
        module.exports = Views
    },
    /*!******************************************************!*\
      !*** ./Scripts/ui/calendar/ui.calendar.base_view.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        var abstract = Widget.abstract,
            CALENDAR_OTHER_VIEW_CLASS = "dx-calendar-other-view",
            CALENDAR_CELL_CLASS = "dx-calendar-cell",
            CALENDAR_EMPTY_CELL_CLASS = "dx-calendar-empty-cell",
            CALENDAR_TODAY_CLASS = "dx-calendar-today",
            CALENDAR_SELECTED_DATE_CLASS = "dx-calendar-selected-date",
            CALENDAR_CONTOURED_DATE_CLASS = "dx-calendar-contoured-date",
            CALENDAR_DXCLICK_EVENT_NAME = eventUtils.addNamespace(clickEvent.name, "dxCalendar"),
            CALENDAR_DATE_VALUE_KEY = "dxDateValueKey";
        var BaseView = Widget.inherit({
            _getViewName: function() {
                return "base"
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    date: new Date,
                    focusStateEnabled: false,
                    cellTemplate: null,
                    onCellClick: null,
                    rowCount: 3,
                    colCount: 4,
                    allowValueSelection: true
                })
            },
            _init: function() {
                this.callBase();
                var value = this.option("value");
                this.option("value", new Date(value));
                if (!this.option("value").valueOf()) {
                    this.option("value", new Date(0, 0, 0, 0, 0, 0))
                }
            },
            _render: function() {
                this.callBase();
                this._renderImpl()
            },
            _renderImpl: function() {
                this._$table = $("<table>");
                this.element().append(this._$table);
                this._renderBody();
                this._renderContouredDate();
                this._renderValue();
                this._renderEvents()
            },
            _renderBody: function() {
                this.$body = $("<tbody>").appendTo(this._$table);
                var that = this,
                    cellTemplate = this.option("cellTemplate");
                var appendChild = this.option("rtl") ? function(row, cell) {
                    row.insertBefore(cell, row.firstChild)
                } : function(row, cell) {
                    row.appendChild(cell)
                };

                function renderCell(cellIndex) {
                    var cell = document.createElement("td"),
                        className = CALENDAR_CELL_CLASS;
                    if (that._isTodayCell(cellDate)) {
                        className = className + " " + CALENDAR_TODAY_CLASS
                    }
                    if (that._isDateOutOfRange(cellDate)) {
                        className = className + " " + CALENDAR_EMPTY_CELL_CLASS
                    }
                    if (that._isOtherView(cellDate)) {
                        className = className + " " + CALENDAR_OTHER_VIEW_CLASS
                    }
                    cell.className = className;
                    cell.setAttribute("data-value", dateLocalization.format(cellDate, dateUtils.getShortDateFormat()));
                    $.data(cell, CALENDAR_DATE_VALUE_KEY, cellDate);
                    that.setAria({
                        role: "option",
                        label: that.getCellAriaLabel(cellDate)
                    }, $(cell));
                    appendChild(row, cell);
                    if (cellTemplate) {
                        cellTemplate.render({
                            model: {
                                text: that._getCellText(cellDate),
                                date: cellDate,
                                view: that._getViewName()
                            },
                            container: $(cell),
                            index: cellIndex
                        })
                    } else {
                        cell.innerHTML = that._getCellText(cellDate)
                    }
                    cellDate = that._getNextCellData(cellDate)
                }
                var cellDate = this._getFirstCellData(),
                    colCount = this.option("colCount");
                for (var indexRow = 0, len = this.option("rowCount"); indexRow < len; indexRow++) {
                    var row = document.createElement("tr");
                    this.$body.get(0).appendChild(row);
                    this._iterateCells(colCount, renderCell)
                }
            },
            _iterateCells: function(colCount, delegate) {
                var i = 0;
                while (i < colCount) {
                    delegate(i);
                    ++i
                }
            },
            _renderEvents: function() {
                this._createCellClickAction();
                this._$table.off(CALENDAR_DXCLICK_EVENT_NAME).on(CALENDAR_DXCLICK_EVENT_NAME, "td", $.proxy(function(e) {
                    if (!$(e.currentTarget).hasClass(CALENDAR_EMPTY_CELL_CLASS)) {
                        this._cellClickAction({
                            jQueryEvent: e,
                            value: $(e.currentTarget).data(CALENDAR_DATE_VALUE_KEY)
                        })
                    }
                }, this))
            },
            _createCellClickAction: function(e) {
                this._cellClickAction = this._createActionByOption("onCellClick")
            },
            _isTodayCell: abstract,
            _isDateOutOfRange: abstract,
            _isOtherView: abstract,
            _getCellText: abstract,
            _getFirstCellData: abstract,
            _getNextCellData: abstract,
            _renderContouredDate: function(contouredDate) {
                if (!this.option("focusStateEnabled")) {
                    return
                }
                contouredDate = contouredDate || this.option("contouredDate");
                var $oldContouredCell = this._$table.find("." + CALENDAR_CONTOURED_DATE_CLASS);
                var $newContouredCell = this._getCellByDate(contouredDate);
                $oldContouredCell.removeClass(CALENDAR_CONTOURED_DATE_CLASS);
                $newContouredCell.addClass(CALENDAR_CONTOURED_DATE_CLASS)
            },
            _dispose: function() {
                this._keyboardProcessor = void 0;
                this.callBase()
            },
            _changeValue: function(cellDate) {
                if (cellDate) {
                    var value = this.option("value"),
                        newValue = value ? new Date(value) : new Date;
                    newValue.setDate(cellDate.getDate());
                    newValue.setMonth(cellDate.getMonth());
                    newValue.setFullYear(cellDate.getFullYear());
                    newValue.setDate(cellDate.getDate());
                    this.option("value", newValue)
                } else {
                    this.option("value", null)
                }
            },
            _renderValue: function() {
                if (!this.option("allowValueSelection")) {
                    return
                }
                var value = this.option("value"),
                    selectedCell = this._getCellByDate(value);
                if (this._selectedCell) {
                    this._selectedCell.removeClass(CALENDAR_SELECTED_DATE_CLASS)
                }
                selectedCell.addClass(CALENDAR_SELECTED_DATE_CLASS);
                this._selectedCell = selectedCell
            },
            getCellAriaLabel: function(date) {
                return this._getCellText(date)
            },
            _getFirstAvailableDate: function() {
                var date = this.option("date"),
                    min = this.option("min");
                date = dateUtils.getFirstDateView(this._getViewName(), date);
                return new Date(min && date < min ? min : date)
            },
            _getCellByDate: abstract,
            isBoundary: abstract,
            _optionChanged: function(args) {
                var name = args.name;
                switch (name) {
                    case "value":
                        this._renderValue();
                        break;
                    case "contouredDate":
                        this._renderContouredDate(args.value);
                        break;
                    case "onCellClick":
                        this._createCellClickAction();
                        break;
                    case "cellTemplate":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        module.exports = BaseView
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/color_box.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./color_box/color_box */ 253)
    },
    /*!*******************************************!*\
      !*** ./Scripts/ui/color_box/color_box.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Color = __webpack_require__( /*! ../../color */ 26),
            ColorView = __webpack_require__( /*! ./color_view */ 254),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            DropDownEditor = __webpack_require__( /*! ../drop_down_editor/ui.drop_down_editor */ 205);
        var COLOR_BOX_CLASS = "dx-colorbox",
            COLOR_BOX_INPUT_CLASS = COLOR_BOX_CLASS + "-input",
            COLOR_BOX_INPUT_CONTAINER_CLASS = COLOR_BOX_INPUT_CLASS + "-container",
            COLOR_BOX_COLOR_RESULT_PREVIEW_CLASS = COLOR_BOX_CLASS + "-color-result-preview",
            COLOR_BOX_COLOR_IS_NOT_DEFINED = COLOR_BOX_CLASS + "-color-is-not-defined",
            COLOR_BOX_OVERLAY_CLASS = COLOR_BOX_CLASS + "-overlay",
            COLOR_BOX_CONTAINER_CELL_CLASS = "dx-colorview-container-cell",
            COLOR_BOX_BUTTON_CELL_CLASS = "dx-colorview-button-cell",
            COLOR_BOX_BUTTONS_CONTAINER_CLASS = "dx-colorview-buttons-container",
            COLOR_BOX_APPLY_BUTTON_CLASS = "dx-colorview-apply-button",
            COLOR_BOX_CANCEL_BUTTON_CLASS = "dx-colorview-cancel-button";
        var colorEditorPrototype = ColorView.prototype,
            colorUtils = {
                makeTransparentBackground: $.proxy(colorEditorPrototype._makeTransparentBackground, colorEditorPrototype),
                makeRgba: $.proxy(colorEditorPrototype._makeRgba, colorEditorPrototype)
            };
        var ColorBox = DropDownEditor.inherit({
            _supportedKeys: function() {
                var arrowHandler = function(e) {
                    e.stopPropagation();
                    if (this.option("opened")) {
                        e.preventDefault();
                        return true
                    }
                };
                var upArrowHandler = function(e) {
                    if (!this.option("opened")) {
                        e.preventDefault();
                        return false
                    }
                    if (e.altKey) {
                        this.close();
                        return false
                    }
                    return true
                };
                var downArrowHandler = function(e) {
                    if (!this.option("opened") && !e.altKey) {
                        e.preventDefault();
                        return false
                    }
                    if (!this.option("opened") && e.altKey) {
                        this._validatedOpening();
                        return false
                    }
                    return true
                };
                return $.extend(this.callBase(), {
                    tab: function(e) {
                        if (this.option("opened")) {
                            e.preventDefault();
                            this._colorView._rgbInputs[0].focus()
                        }
                    },
                    enter: this._enterKeyHandler,
                    leftArrow: arrowHandler,
                    rightArrow: arrowHandler,
                    upArrow: upArrowHandler,
                    downArrow: downArrowHandler
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    editAlphaChannel: false,
                    applyValueMode: "useButtons",
                    keyStep: 1,
                    onApplyButtonClick: null,
                    onCancelButtonClick: null,
                    buttonsLocation: "bottom after"
                })
            },
            _popupConfig: function() {
                return $.extend(this.callBase(), {
                    height: "auto",
                    width: ""
                })
            },
            _contentReadyHandler: function() {
                this._createColorView();
                this._addPopupBottomClasses()
            },
            _addPopupBottomClasses: function() {
                var $popupBottom = this._popup.bottomToolbar();
                if ($popupBottom) {
                    $popupBottom.addClass(COLOR_BOX_CONTAINER_CELL_CLASS).addClass(COLOR_BOX_BUTTON_CELL_CLASS).find(".dx-toolbar-items-container").addClass(COLOR_BOX_BUTTONS_CONTAINER_CLASS);
                    $popupBottom.find(".dx-popup-done").addClass(COLOR_BOX_APPLY_BUTTON_CLASS);
                    $popupBottom.find(".dx-popup-cancel").addClass(COLOR_BOX_CANCEL_BUTTON_CLASS)
                }
            },
            _createColorView: function() {
                this._popup.overlayContent().addClass(COLOR_BOX_OVERLAY_CLASS);
                var $colorView = $("<div>").appendTo(this._popup.content());
                this._colorView = this._createComponent($colorView, ColorView, this._colorViewConfig());
                this._colorView._enterKeyHandler = $.proxy(this._enterKeyHandler, this);
                $colorView.on("focus", $.proxy(function() {
                    this.focus()
                }, this))
            },
            _colorViewConfig: function() {
                var that = this;
                return {
                    value: that.option("value"),
                    editAlphaChannel: that.option("editAlphaChannel"),
                    applyValueMode: that.option("applyValueMode"),
                    focusStateEnabled: that.option("focusStateEnabled"),
                    onValueChanged: function(args) {
                        var value = args.value;
                        that.option("value", value);
                        if (value) {
                            colorUtils.makeTransparentBackground(that._$colorResultPreview, value)
                        }
                    },
                    _keyboardProcessor: that._colorViewProcessor
                }
            },
            _enterKeyHandler: function(e) {
                var newValue = this._input().val(),
                    oldValue = this.option("editAlphaChannel") ? colorUtils.makeRgba(this.option("value")) : this.option("value");
                var color = new Color(newValue);
                if (color.colorIsInvalid && "" !== newValue) {
                    this._input().val(oldValue);
                    return
                }
                if (newValue && newValue !== oldValue) {
                    this._applyColorFromInput(newValue);
                    this.option("value", this.option("editAlphaChannel") ? colorUtils.makeRgba(newValue) : newValue);
                    return false
                }
                if (this._colorView && "useButtons" === this.option("applyValueMode")) {
                    this._colorView.applyColor()
                }
                if (this.option("opened")) {
                    e.preventDefault();
                    this.close()
                }
                return false
            },
            _applyButtonHandler: function() {
                this._colorView.applyColor();
                if ($.isFunction(this.option("onApplyButtonClick"))) {
                    this.option("onApplyButtonClick")()
                }
                this.callBase()
            },
            _cancelButtonHandler: function() {
                this._colorView.cancelColor();
                if ($.isFunction(this.option("onCancelButtonClick"))) {
                    this.option("onCancelButtonClick")()
                }
                this.callBase()
            },
            _attachChildKeyboardEvents: function() {
                this._colorViewProcessor = this._keyboardProcessor.attachChildProcessor();
                if (this._colorView) {
                    this._colorView.option("_keyboardProcessor", this._colorViewProcessor);
                    return
                }
            },
            _init: function() {
                this.callBase()
            },
            _render: function() {
                this.callBase();
                this.element().addClass(COLOR_BOX_CLASS)
            },
            _renderInput: function() {
                this.callBase();
                this._input().addClass(COLOR_BOX_INPUT_CLASS);
                this._renderColorPreview()
            },
            _renderColorPreview: function() {
                this.element().wrapInner($("<div/>").addClass(COLOR_BOX_INPUT_CONTAINER_CLASS));
                this._$colorBoxInputContainer = this.element().children().eq(0);
                this._$colorResultPreview = $("<div>", {
                    "class": COLOR_BOX_COLOR_RESULT_PREVIEW_CLASS,
                    appendTo: this._$colorBoxInputContainer
                });
                if (!this.option("value")) {
                    this._$colorBoxInputContainer.addClass(COLOR_BOX_COLOR_IS_NOT_DEFINED)
                } else {
                    colorUtils.makeTransparentBackground(this._$colorResultPreview, this.option("value"))
                }
            },
            _renderValue: function() {
                var value = this.option("value");
                this.option("text", this.option("editAlphaChannel") ? colorUtils.makeRgba(value) : value);
                this.callBase()
            },
            _valueChangeEventHandler: function(e) {
                var value = this._input().val();
                if (value) {
                    value = this._applyColorFromInput(value);
                    if (this._colorView) {
                        this._colorView._setCurrentColor(value);
                        this._colorView._refreshMarkup()
                    }
                }
                this.callBase(e, value)
            },
            _applyColorFromInput: function(value) {
                var newColor = new Color(value);
                if (newColor.colorIsInvalid) {
                    value = this.option("value");
                    this._input().val(value)
                }
                return value
            },
            _optionChanged: function(args) {
                var value = args.value,
                    name = args.name;
                switch (name) {
                    case "value":
                        this._$colorBoxInputContainer.toggleClass(COLOR_BOX_COLOR_IS_NOT_DEFINED, !value);
                        if (value) {
                            colorUtils.makeTransparentBackground(this._$colorResultPreview, value)
                        } else {
                            this._$colorResultPreview.removeAttr("style")
                        }
                        if (this._colorView) {
                            this._colorView.option("value", value)
                        }
                        this.callBase(args);
                        break;
                    case "applyButtonText":
                    case "cancelButtonText":
                        this.callBase(args);
                        this._popup && this._addPopupBottomClasses();
                        break;
                    case "editAlphaChannel":
                    case "onCancelButtonClick":
                    case "onApplyButtonClick":
                    case "keyStep":
                        if (this._colorView) {
                            this._colorView.option(name, value)
                        }
                        break;
                    case "applyValueMode":
                        if (this._colorView) {
                            this._colorView.option(name, value)
                        }
                        this.callBase(args);
                        break;
                    case "rtlEnabled":
                        if (this._colorView) {
                            this._colorView.option(name, value)
                        }
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxColorBox", ColorBox);
        module.exports = ColorBox
    },
    /*!********************************************!*\
      !*** ./Scripts/ui/color_box/color_view.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            Color = __webpack_require__( /*! ../../color */ 26),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            NumberBox = __webpack_require__( /*! ../number_box */ 255),
            TextBox = __webpack_require__( /*! ../text_box */ 206),
            Draggable = __webpack_require__( /*! ../draggable */ 258),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        var COLOR_VIEW_CLASS = "dx-colorview",
            COLOR_VIEW_CONTAINER_CLASS = "dx-colorview-container",
            COLOR_VIEW_ROW_CLASS = "dx-colorview-container-row",
            COLOR_VIEW_CELL_CLASS = "dx-colorview-container-cell",
            COLOR_VIEW_PALETTE_CLASS = "dx-colorview-palette",
            COLOR_VIEW_PALETTE_CELL_CLASS = "dx-colorview-palette-cell",
            COLOR_VIEW_PALETTE_HANDLE_CLASS = "dx-colorview-palette-handle",
            COLOR_VIEW_PALETTE_GRADIENT_CLASS = "dx-colorview-palette-gradient",
            COLOR_VIEW_PALETTE_GRADIENT_WHITE_CLASS = "dx-colorview-palette-gradient-white",
            COLOR_VIEW_PALETTE_GRADIENT_BLACK_CLASS = "dx-colorview-palette-gradient-black",
            COLOR_VIEW_HUE_SCALE_CLASS = "dx-colorview-hue-scale",
            COLOR_VIEW_HUE_SCALE_CELL_CLASS = "dx-colorview-hue-scale-cell",
            COLOR_VIEW_HUE_SCALE_HANDLE_CLASS = "dx-colorview-hue-scale-handle",
            COLOR_VIEW_HUE_SCALE_WRAPPER_CLASS = "dx-colorview-hue-scale-wrapper",
            COLOR_VIEW_CONTROLS_CONTAINER_CLASS = "dx-colorview-controls-container",
            COLOR_VIEW_RED_LABEL_CLASS = "dx-colorview-label-red",
            COLOR_VIEW_GREEN_LABEL_CLASS = "dx-colorview-label-green",
            COLOR_VIEW_BLUE_LABEL_CLASS = "dx-colorview-label-blue",
            COLOR_VIEW_HEX_LABEL_CLASS = "dx-colorview-label-hex",
            COLOR_VIEW_ALPHA_CHANNEL_SCALE_CLASS = "dx-colorview-alpha-channel-scale",
            COLOR_VIEW_APLHA_CHANNEL_ROW_CLASS = "dx-colorview-alpha-channel-row",
            COLOR_VIEW_ALPHA_CHANNEL_SCALE_WRAPPER_CLASS = "dx-colorview-alpha-channel-wrapper",
            COLOR_VIEW_ALPHA_CHANNEL_LABEL_CLASS = "dx-colorview-alpha-channel-label",
            COLOR_VIEW_ALPHA_CHANNEL_HANDLE_CLASS = "dx-colorview-alpha-channel-handle",
            COLOR_VIEW_ALPHA_CHANNEL_CELL_CLASS = "dx-colorview-alpha-channel-cell",
            COLOR_VIEW_ALPHA_CHANNEL_BORDER_CLASS = "dx-colorview-alpha-channel-border",
            COLOR_VIEW_COLOR_PREVIEW = "dx-colorview-color-preview",
            COLOR_VIEW_COLOR_PREVIEW_CONTAINER_CLASS = "dx-colorview-color-preview-container",
            COLOR_VIEW_COLOR_PREVIEW_CONTAINER_INNER_CLASS = "dx-colorview-color-preview-container-inner",
            COLOR_VIEW_COLOR_PREVIEW_COLOR_CURRENT = "dx-colorview-color-preview-color-current",
            COLOR_VIEW_COLOR_PREVIEW_COLOR_NEW = "dx-colorview-color-preview-color-new";
        var ColorView = Editor.inherit({
            _supportedKeys: function() {
                var isRTL = this.option("rtlEnabled");
                var that = this,
                    getHorizontalPaletteStep = function(e) {
                        var step = 100 / that._paletteWidth;
                        if (e.shiftKey) {
                            step *= that.option("keyStep")
                        }
                        step = step > 1 ? step : 1;
                        return Math.round(step)
                    },
                    updateHorizontalPaletteValue = function(step) {
                        var value = that._currentColor.hsv.s + step;
                        if (value > 100) {
                            value = 100
                        } else {
                            if (value < 0) {
                                value = 0
                            }
                        }
                        that._currentColor.hsv.s = value;
                        updatePaletteValue()
                    },
                    getVerticalPaletteStep = function(e) {
                        var step = 100 / that._paletteHeight;
                        if (e.shiftKey) {
                            step *= that.option("keyStep")
                        }
                        step = step > 1 ? step : 1;
                        return Math.round(step)
                    },
                    updateVerticalPaletteValue = function(step) {
                        var value = that._currentColor.hsv.v + step;
                        if (value > 100) {
                            value = 100
                        } else {
                            if (value < 0) {
                                value = 0
                            }
                        }
                        that._currentColor.hsv.v = value;
                        updatePaletteValue()
                    },
                    updatePaletteValue = function() {
                        that._placePaletteHandle();
                        that._updateColorFromHsv(that._currentColor.hsv.h, that._currentColor.hsv.s, that._currentColor.hsv.v)
                    },
                    getHueScaleStep = function(e) {
                        var step = 360 / (that._hueScaleWrapperHeight - that._hueScaleHandleHeight);
                        if (e.shiftKey) {
                            step *= that.option("keyStep")
                        }
                        step = step > 1 ? step : 1;
                        return step
                    },
                    updateHueScaleValue = function(step) {
                        that._currentColor.hsv.h += step;
                        that._placeHueScaleHandle();
                        var handleLocation = translator.locate(that._$hueScaleHandle);
                        that._updateColorHue(handleLocation.top + that._hueScaleHandleHeight / 2)
                    },
                    getAlphaScaleStep = function(e) {
                        var step = 1 / that._alphaChannelScaleWorkWidth;
                        if (e.shiftKey) {
                            step *= that.option("keyStep")
                        }
                        step = step > .01 ? step : .01;
                        step = isRTL ? -step : step;
                        return step
                    },
                    updateAlphaScaleValue = function(step) {
                        that._currentColor.a += step;
                        that._placeAlphaChannelHandle();
                        var handleLocation = translator.locate(that._$alphaChannelHandle);
                        that._calculateColorTransparencyByScaleWidth(handleLocation.left + that._alphaChannelHandleWidth / 2)
                    };
                return $.extend(this.callBase(), {
                    upArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (e.ctrlKey) {
                            if (this._currentColor.hsv.h <= 360 && !this._isTopColorHue) {
                                updateHueScaleValue(getHueScaleStep(e))
                            }
                        } else {
                            if (this._currentColor.hsv.v < 100) {
                                updateVerticalPaletteValue(getVerticalPaletteStep(e))
                            }
                        }
                    },
                    downArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (e.ctrlKey) {
                            if (this._currentColor.hsv.h >= 0) {
                                if (this._isTopColorHue) {
                                    this._currentColor.hsv.h = 360
                                }
                                updateHueScaleValue(-getHueScaleStep(e))
                            }
                        } else {
                            if (this._currentColor.hsv.v > 0) {
                                updateVerticalPaletteValue(-getVerticalPaletteStep(e))
                            }
                        }
                    },
                    rightArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (e.ctrlKey) {
                            if (isRTL ? this._currentColor.a < 1 : this._currentColor.a > 0 && this.option("editAlphaChannel")) {
                                updateAlphaScaleValue(-getAlphaScaleStep(e))
                            }
                        } else {
                            if (this._currentColor.hsv.s < 100) {
                                updateHorizontalPaletteValue(getHorizontalPaletteStep(e))
                            }
                        }
                    },
                    leftArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (e.ctrlKey) {
                            if (isRTL ? this._currentColor.a > 0 : this._currentColor.a < 1 && this.option("editAlphaChannel")) {
                                updateAlphaScaleValue(getAlphaScaleStep(e))
                            }
                        } else {
                            if (this._currentColor.hsv.s > 0) {
                                updateHorizontalPaletteValue(-getHorizontalPaletteStep(e))
                            }
                        }
                    },
                    enter: function(e) {
                        if ("useButtons" === this.option("applyValueMode")) {
                            this.applyColor()
                        }
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: null,
                    editAlphaChannel: false,
                    applyValueMode: "useButtons",
                    keyStep: 1
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this._initColorAndOpacity()
            },
            _initColorAndOpacity: function() {
                this._setCurrentColor(this.option("value"))
            },
            _setCurrentColor: function(value) {
                value = value || "#000000";
                var newColor = new Color(value);
                if (!newColor.colorIsInvalid) {
                    if (!this._currentColor || this._makeRgba(this._currentColor) !== this._makeRgba(newColor)) {
                        this._currentColor = newColor;
                        if (this._$currentColor) {
                            this._makeTransparentBackground(this._$currentColor, newColor)
                        }
                    }
                } else {
                    this.option("value", this._currentColor.baseColor)
                }
            },
            _render: function() {
                this.callBase();
                this.element().addClass(COLOR_VIEW_CLASS);
                this._renderColorPickerContainer()
            },
            _enterKeyHandler: function() {
                if ("useButtons" === this.option("applyValueMode")) {
                    this.applyColor()
                }
            },
            _makeTransparentBackground: function($el, color) {
                if (!(color instanceof Color)) {
                    color = new Color(color)
                }
                if (browser.msie && "8.0" === browser.version) {
                    $el.css({
                        background: color.toHex(),
                        filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=" + 100 * color.a + ")"
                    })
                } else {
                    $el.css("backgroundColor", this._makeRgba(color))
                }
            },
            _makeRgba: function(color) {
                if (!(color instanceof Color)) {
                    color = new Color(color)
                }
                return "rgba(" + [color.r, color.g, color.b, color.a].join(", ") + ")"
            },
            _renderValue: function() {
                this.callBase(this.option("editAlphaChannel") ? this._makeRgba(this._currentColor) : this.option("value"))
            },
            _renderColorPickerContainer: function() {
                var $parent = this.element();
                this._$colorPickerContainer = $("<div>", {
                    "class": COLOR_VIEW_CONTAINER_CLASS,
                    appendTo: $parent
                });
                this._renderHtmlRows();
                this._renderPalette();
                this._renderHueScale();
                this._renderControlsContainer();
                this._renderControls();
                this._renderAlphaChannelElements()
            },
            _renderHtmlRows: function(updatedOption) {
                var $renderedRows = this._$colorPickerContainer.find("." + COLOR_VIEW_ROW_CLASS),
                    renderedRowsCount = $renderedRows.length,
                    rowCount = this._calculateRowsCount(),
                    delta = renderedRowsCount - rowCount;
                if (delta > 0) {
                    var index = this._calculateRemovedHtmlRowIndex(renderedRowsCount, updatedOption);
                    $renderedRows.eq(index).remove()
                }
                if (delta < 0) {
                    delta = Math.abs(delta);
                    var rows = [];
                    for (var i = 0; i < delta; i++) {
                        rows.push($("<div>", {
                            "class": COLOR_VIEW_ROW_CLASS
                        }))
                    }
                    if (renderedRowsCount) {
                        var previousRowIndex = this._calculateHtmlRowIndex(renderedRowsCount, updatedOption);
                        $renderedRows.eq(previousRowIndex).after(rows)
                    } else {
                        this._$colorPickerContainer.append(rows)
                    }
                }
            },
            _renderHtmlCellInsideRow: function(rowSelector, $rowParent, additionalClass) {
                return $("<div>", {
                    "class": COLOR_VIEW_CELL_CLASS,
                    addClass: additionalClass,
                    appendTo: $rowParent.find("." + COLOR_VIEW_ROW_CLASS + rowSelector)
                })
            },
            _calculateRowsCount: function() {
                if (this.option("editAlphaChannel")) {
                    return "instantly" === this.option("applyValueMode") ? 2 : 3
                }
                return "instantly" === this.option("applyValueMode") ? 1 : 2
            },
            _calculateRemovedHtmlRowIndex: function(renderedRowsCount, updatedOption) {
                var index = -1;
                if (3 === renderedRowsCount) {
                    if ("editAlphaChannel" === updatedOption) {
                        index = -2
                    }
                    if ("applyValueMode" === updatedOption) {
                        index = -1
                    }
                }
                return index
            },
            _calculateHtmlRowIndex: function(renderedRowsCount, updatedOption) {
                var index = 0;
                if (2 === renderedRowsCount) {
                    if ("applyValueMode" === updatedOption) {
                        index = 1
                    }
                }
                return index
            },
            _renderPalette: function() {
                var $paletteCell = this._renderHtmlCellInsideRow(":first", this._$colorPickerContainer, COLOR_VIEW_PALETTE_CELL_CLASS),
                    $paletteGradientWhite = $("<div>", {
                        "class": [COLOR_VIEW_PALETTE_GRADIENT_CLASS, COLOR_VIEW_PALETTE_GRADIENT_WHITE_CLASS].join(" ")
                    }),
                    $paletteGradientBlack = $("<div>", {
                        "class": [COLOR_VIEW_PALETTE_GRADIENT_CLASS, COLOR_VIEW_PALETTE_GRADIENT_BLACK_CLASS].join(" ")
                    });
                this._$palette = $("<div>", {
                    "class": COLOR_VIEW_PALETTE_CLASS,
                    css: {
                        backgroundColor: this._currentColor.getPureColor().toHex()
                    },
                    appendTo: $paletteCell
                });
                this._paletteHeight = this._$palette.height();
                this._paletteWidth = this._$palette.width();
                this._renderPaletteHandle();
                this._$palette.append([$paletteGradientWhite, $paletteGradientBlack])
            },
            _renderPaletteHandle: function() {
                this._createComponent(this._$paletteHandle = $("<div>", {
                    "class": COLOR_VIEW_PALETTE_HANDLE_CLASS,
                    appendTo: this._$palette
                }), Draggable, {
                    area: this._$palette,
                    allowMoveByClick: true,
                    boundOffset: $.proxy(function() {
                        return -this._paletteHandleHeight / 2
                    }, this),
                    onDrag: $.proxy(function(e) {
                        var paletteHandlePosition = translator.locate(this._$paletteHandle);
                        this._updateByDrag = true;
                        this._updateColorFromHsv(this._currentColor.hsv.h, this._calculateColorSaturation(paletteHandlePosition), this._calculateColorValue(paletteHandlePosition))
                    }, this)
                });
                this._paletteHandleWidth = this._$paletteHandle.width();
                this._paletteHandleHeight = this._$paletteHandle.height();
                this._placePaletteHandle()
            },
            _placePaletteHandle: function() {
                translator.move(this._$paletteHandle, {
                    left: Math.round(this._paletteWidth * this._currentColor.hsv.s / 100 - this._paletteHandleWidth / 2),
                    top: Math.round(this._paletteHeight - this._paletteHeight * this._currentColor.hsv.v / 100 - this._paletteHandleHeight / 2)
                })
            },
            _calculateColorValue: function(paletteHandlePosition) {
                var value = Math.floor(paletteHandlePosition.top + this._paletteHandleHeight / 2);
                return 100 - Math.round(100 * value / this._paletteHeight)
            },
            _calculateColorSaturation: function(paletteHandlePosition) {
                var saturation = Math.floor(paletteHandlePosition.left + this._paletteHandleWidth / 2);
                return Math.round(100 * saturation / this._paletteWidth)
            },
            _updateColorFromHsv: function(hue, saturation, value) {
                var a = this._currentColor.a;
                this._currentColor = new Color("hsv(" + [hue, saturation, value].join(",") + ")");
                this._currentColor.a = a;
                this._updateColorParamsAndColorPreview();
                if ("instantly" === this.option("applyValueMode")) {
                    this.applyColor()
                }
            },
            _renderHueScale: function() {
                var $hueScaleCell = this._renderHtmlCellInsideRow(":first", this._$colorPickerContainer, COLOR_VIEW_HUE_SCALE_CELL_CLASS);
                this._$hueScaleWrapper = $("<div>", {
                    "class": COLOR_VIEW_HUE_SCALE_WRAPPER_CLASS,
                    appendTo: $hueScaleCell
                });
                this._$hueScale = $("<div>", {
                    "class": COLOR_VIEW_HUE_SCALE_CLASS,
                    appendTo: this._$hueScaleWrapper
                });
                this._hueScaleHeight = this._$hueScale.height();
                this._hueScaleWrapperHeight = this._$hueScaleWrapper.outerHeight();
                this._renderHueScaleHandle()
            },
            _renderHueScaleHandle: function() {
                this._createComponent(this._$hueScaleHandle = $("<div>", {
                    "class": COLOR_VIEW_HUE_SCALE_HANDLE_CLASS,
                    appendTo: this._$hueScaleWrapper
                }), Draggable, {
                    area: this._$hueScaleWrapper,
                    allowMoveByClick: true,
                    direction: "vertical",
                    onDrag: $.proxy(function(e) {
                        this._updateByDrag = true;
                        this._updateColorHue(translator.locate(this._$hueScaleHandle).top + this._hueScaleHandleHeight / 2)
                    }, this)
                });
                this._hueScaleHandleHeight = this._$hueScaleHandle.height();
                this._placeHueScaleHandle()
            },
            _placeHueScaleHandle: function() {
                var hueScaleHeight = this._hueScaleWrapperHeight,
                    handleHeight = this._hueScaleHandleHeight,
                    top = (hueScaleHeight - handleHeight) * (360 - this._currentColor.hsv.h) / 360;
                if (hueScaleHeight < top + handleHeight) {
                    top = hueScaleHeight - handleHeight
                }
                if (top < 0) {
                    top = 0
                }
                translator.move(this._$hueScaleHandle, {
                    top: Math.round(top)
                })
            },
            _updateColorHue: function(handlePosition) {
                var hue = 360 - Math.round(360 * (handlePosition - this._hueScaleHandleHeight / 2) / (this._hueScaleWrapperHeight - this._hueScaleHandleHeight)),
                    saturation = this._currentColor.hsv.s,
                    value = this._currentColor.hsv.v;
                this._isTopColorHue = false;
                hue = hue < 0 ? 0 : hue;
                if (hue >= 360) {
                    this._isTopColorHue = true;
                    hue = 0
                }
                this._updateColorFromHsv(hue, saturation, value);
                this._$palette.css("backgroundColor", this._currentColor.getPureColor().toHex())
            },
            _renderControlsContainer: function() {
                var $controlsContainerCell = this._renderHtmlCellInsideRow(":first", this._$colorPickerContainer);
                this._$controlsContainer = $("<div>", {
                    "class": COLOR_VIEW_CONTROLS_CONTAINER_CLASS,
                    appendTo: $controlsContainerCell
                })
            },
            _renderControls: function() {
                this._renderColorsPreview();
                this._renderRgbInputs();
                this._renderHexInput()
            },
            _renderColorsPreview: function() {
                var $colorsPreviewContainer = $("<div>", {
                        "class": COLOR_VIEW_COLOR_PREVIEW_CONTAINER_CLASS,
                        appendTo: this._$controlsContainer
                    }),
                    $colorsPreviewContainerInner = $("<div>", {
                        "class": COLOR_VIEW_COLOR_PREVIEW_CONTAINER_INNER_CLASS,
                        appendTo: $colorsPreviewContainer
                    });
                this._$currentColor = $("<div>", {
                    "class": [COLOR_VIEW_COLOR_PREVIEW, COLOR_VIEW_COLOR_PREVIEW_COLOR_CURRENT].join(" ")
                });
                this._$newColor = $("<div>", {
                    "class": [COLOR_VIEW_COLOR_PREVIEW, COLOR_VIEW_COLOR_PREVIEW_COLOR_NEW].join(" ")
                });
                this._makeTransparentBackground(this._$currentColor, this._currentColor);
                this._makeTransparentBackground(this._$newColor, this._currentColor);
                $colorsPreviewContainerInner.append([this._$currentColor, this._$newColor])
            },
            _renderAlphaChannelElements: function() {
                if (this.option("editAlphaChannel")) {
                    this._$colorPickerContainer.find("." + COLOR_VIEW_ROW_CLASS).eq(1).addClass(COLOR_VIEW_APLHA_CHANNEL_ROW_CLASS);
                    this._renderAlphaChannelScale();
                    this._renderAlphaChannelInput()
                }
            },
            _renderRgbInputs: function() {
                this._rgbInputsWithLabels = [this._renderEditorWithLabel({
                    editorType: NumberBox.publicName(),
                    value: this._currentColor.r,
                    onValueChanged: $.proxy(this._updateColor, this, false),
                    labelText: "R",
                    labelAriaText: messageLocalization.format("dxColorView-ariaRed"),
                    labelClass: COLOR_VIEW_RED_LABEL_CLASS
                }), this._renderEditorWithLabel({
                    editorType: NumberBox.publicName(),
                    value: this._currentColor.g,
                    onValueChanged: $.proxy(this._updateColor, this, false),
                    labelText: "G",
                    labelAriaText: messageLocalization.format("dxColorView-ariaGreen"),
                    labelClass: COLOR_VIEW_GREEN_LABEL_CLASS
                }), this._renderEditorWithLabel({
                    editorType: NumberBox.publicName(),
                    value: this._currentColor.b,
                    onValueChanged: $.proxy(this._updateColor, this, false),
                    labelText: "B",
                    labelAriaText: messageLocalization.format("dxColorView-ariaBlue"),
                    labelClass: COLOR_VIEW_BLUE_LABEL_CLASS
                })];
                this._$controlsContainer.append(this._rgbInputsWithLabels);
                this._rgbInputs = [this._rgbInputsWithLabels[0].find(".dx-numberbox").dxNumberBox("instance"), this._rgbInputsWithLabels[1].find(".dx-numberbox").dxNumberBox("instance"), this._rgbInputsWithLabels[2].find(".dx-numberbox").dxNumberBox("instance")];
                $.each(this._rgbInputs, $.proxy(function(_, instance) {
                    this._attachEnterKeyHandler(instance)
                }, this))
            },
            _renderEditorWithLabel: function(options) {
                var $editor = $("<div>"),
                    $label = $("<label>", {
                        "class": options.labelClass,
                        text: options.labelText + ":",
                        append: $editor
                    }).off(clickEvent.name).on(clickEvent.name, function(e) {
                        e.preventDefault()
                    }),
                    editorType = options.editorType,
                    editorOptions = {
                        value: options.value,
                        onValueChanged: options.onValueChanged
                    };
                if (editorType === NumberBox.publicName()) {
                    editorOptions.min = options.min || 0;
                    editorOptions.max = options.max || 255;
                    editorOptions.step = options.step || 1
                }
                $editor[editorType](editorOptions);
                this.setAria("label", options.labelAriaText, $editor);
                return $label
            },
            hexInputOptions: function() {
                return {
                    editorType: TextBox.publicName(),
                    value: this._currentColor.toHex().replace("#", ""),
                    onValueChanged: $.proxy(this._updateColor, this, true),
                    labelClass: COLOR_VIEW_HEX_LABEL_CLASS,
                    labelText: "#",
                    labelAriaText: messageLocalization.format("dxColorView-ariaHex")
                }
            },
            _renderHexInput: function() {
                this._hexInput = TextBox.getInstance(this._renderEditorWithLabel(this.hexInputOptions()).appendTo(this._$controlsContainer).find(".dx-textbox"));
                this._attachEnterKeyHandler(this._hexInput)
            },
            _attachEnterKeyHandler: function(instance) {
                instance.registerKeyHandler("enter", $.proxy(function(e) {
                    this._enterKeyHandler(e)
                }, this))
            },
            _renderAlphaChannelScale: function() {
                var $alphaChannelScaleCell = this._renderHtmlCellInsideRow(":eq(1)", this._$colorPickerContainer, COLOR_VIEW_ALPHA_CHANNEL_CELL_CLASS),
                    $alphaChannelBorder = $("<div>", {
                        "class": COLOR_VIEW_ALPHA_CHANNEL_BORDER_CLASS,
                        appendTo: $alphaChannelScaleCell
                    }),
                    $alphaChannelScaleWrapper = $("<div>", {
                        "class": COLOR_VIEW_ALPHA_CHANNEL_SCALE_WRAPPER_CLASS,
                        appendTo: $alphaChannelBorder
                    });
                this._$alphaChannelScale = $("<div>", {
                    "class": COLOR_VIEW_ALPHA_CHANNEL_SCALE_CLASS,
                    appendTo: $alphaChannelScaleWrapper
                });
                this._makeCSSLinearGradient(this._$alphaChannelScale);
                this._renderAlphaChannelHandle($alphaChannelScaleCell)
            },
            _makeCSSLinearGradient: function($el) {
                var color = this._currentColor,
                    colorAsRgb = [color.r, color.g, color.b].join(","),
                    colorAsHex = color.toHex().replace("#", "");
                var combineGradientString = function(colorAsRgb, colorAsHex) {
                    var rtlEnabled = this.option("rtlEnabled"),
                        startColor = "rgba(" + colorAsRgb + ", " + (rtlEnabled ? "1" : "0") + ")",
                        finishColor = "rgba(" + colorAsRgb + ", " + (rtlEnabled ? "0" : "1") + ")",
                        startColorIE = "'#" + (rtlEnabled ? "00" : "") + colorAsHex + "'",
                        finishColorIE = "'#" + (rtlEnabled ? "" : "00") + colorAsHex + "'";
                    return ["background-image: -webkit-linear-gradient(180deg, " + startColor + ", " + finishColor + ")", "background-image: -moz-linear-gradient(-90deg, " + startColor + ", " + finishColor + ")", "background-image: -ms-linear-gradient(-90deg, " + startColor + ", " + finishColor + ")", "background-image: -o-linear-gradient(-90deg, " + startColor + ", " + finishColor + ")", "background-image: linear-gradient(-90deg, " + startColor + ", " + finishColor + ")", "filter: progid:DXImageTransform.Microsoft.gradient(GradientType=1,startColorstr=" + startColorIE + ", endColorstr=" + finishColorIE + ")"].join(";")
                };
                $el.attr("style", combineGradientString.call(this, colorAsRgb, colorAsHex))
            },
            _renderAlphaChannelInput: function() {
                var that = this,
                    $alphaChannelInputCell = this._renderHtmlCellInsideRow(":eq(1)", this._$colorPickerContainer);
                that._alphaChannelInput = this._renderEditorWithLabel({
                    editorType: NumberBox.publicName(),
                    value: this._currentColor.a,
                    max: 1,
                    step: .1,
                    onValueChanged: function(e) {
                        var value = e.value;
                        value = that._currentColor.isValidAlpha(value) ? value : that._currentColor.a;
                        that._updateColorTransparency(value);
                        that._placeAlphaChannelHandle()
                    },
                    labelClass: COLOR_VIEW_ALPHA_CHANNEL_LABEL_CLASS,
                    labelText: "Alpha",
                    labelAriaText: messageLocalization.format("dxColorView-ariaAlpha")
                }).appendTo($alphaChannelInputCell).find(".dx-numberbox").dxNumberBox("instance");
                this._attachEnterKeyHandler(that._alphaChannelInput)
            },
            _updateColorTransparency: function(transparency) {
                this._currentColor.a = transparency;
                this._makeTransparentBackground(this._$newColor, this._currentColor);
                if ("instantly" === this.option("applyValueMode")) {
                    this.applyColor()
                }
            },
            _renderAlphaChannelHandle: function($parent) {
                this._createComponent(this._$alphaChannelHandle = $("<div>", {
                    "class": COLOR_VIEW_ALPHA_CHANNEL_HANDLE_CLASS,
                    appendTo: $parent
                }), Draggable, {
                    area: $parent,
                    allowMoveByClick: true,
                    direction: "horizontal",
                    onDrag: $.proxy(function(e) {
                        this._updateByDrag = true;
                        var $alphaChannelHandle = this._$alphaChannelHandle,
                            alphaChannelHandlePosition = translator.locate($alphaChannelHandle).left + this._alphaChannelHandleWidth / 2;
                        this._calculateColorTransparencyByScaleWidth(alphaChannelHandlePosition)
                    }, this)
                });
                this._alphaChannelHandleWidth = this._$alphaChannelHandle.width();
                this._alphaChannelScaleWorkWidth = $parent.width() - this._alphaChannelHandleWidth;
                this._placeAlphaChannelHandle()
            },
            _calculateColorTransparencyByScaleWidth: function(handlePosition) {
                var transparency = (handlePosition - this._alphaChannelHandleWidth / 2) / this._alphaChannelScaleWorkWidth,
                    rtlEnabled = this.option("rtlEnabled");
                transparency = rtlEnabled ? transparency : 1 - transparency;
                if (handlePosition >= this._alphaChannelScaleWorkWidth + this._alphaChannelHandleWidth / 2) {
                    transparency = rtlEnabled ? 1 : 0
                } else {
                    if (transparency < 1) {
                        transparency = transparency.toFixed(2)
                    }
                }
                transparency = Math.max(transparency, 0);
                transparency = Math.min(transparency, 1);
                this._alphaChannelInput.option("value", transparency)
            },
            _placeAlphaChannelHandle: function() {
                var left = this._alphaChannelScaleWorkWidth * (1 - this._currentColor.a);
                if (left < 0) {
                    left = 0
                }
                if (this._alphaChannelScaleWorkWidth < left) {
                    left = this._alphaChannelScaleWorkWidth
                }
                translator.move(this._$alphaChannelHandle, {
                    left: this.option("rtlEnabled") ? this._alphaChannelScaleWorkWidth - left : left
                })
            },
            applyColor: function() {
                var colorValue = this.option("editAlphaChannel") ? this._makeRgba(this._currentColor) : this._currentColor.toHex();
                this._makeTransparentBackground(this._$currentColor, this._currentColor);
                this.option("value", colorValue)
            },
            cancelColor: function() {
                this._initColorAndOpacity();
                this._refreshMarkup()
            },
            _updateColor: function(isHex) {
                var rgba, newColor;
                if (isHex) {
                    newColor = this._validateHex("#" + this._hexInput.option("value"))
                } else {
                    rgba = this._validateRgb();
                    if (this._alphaChannelInput) {
                        rgba.push(this._alphaChannelInput.option("value"));
                        newColor = "rgba(" + rgba.join(", ") + ")"
                    } else {
                        newColor = "rgb(" + rgba.join(", ") + ")"
                    }
                }
                if (!this._suppressEditorsValueUpdating) {
                    this._currentColor = new Color(newColor);
                    this._refreshMarkup();
                    if ("instantly" === this.option("applyValueMode")) {
                        this.applyColor()
                    }
                }
            },
            _validateHex: function(hex) {
                return this._currentColor.isValidHex(hex) ? hex : this._currentColor.toHex()
            },
            _validateRgb: function() {
                var r = this._rgbInputs[0].option("value"),
                    g = this._rgbInputs[1].option("value"),
                    b = this._rgbInputs[2].option("value");
                if (!this._currentColor.isValidRGB(r, g, b)) {
                    r = this._currentColor.r;
                    g = this._currentColor.g;
                    b = this._currentColor.b
                }
                return [r, g, b]
            },
            _refreshMarkup: function() {
                this._placeHueScaleHandle();
                this._placePaletteHandle();
                this._updateColorParamsAndColorPreview();
                this._$palette.css("backgroundColor", this._currentColor.getPureColor().toHex());
                if (this._$alphaChannelHandle) {
                    this._updateColorTransparency(this._currentColor.a);
                    this._placeAlphaChannelHandle()
                }
            },
            _updateColorParamsAndColorPreview: function() {
                this._suppressEditorsValueUpdating = true;
                this._hexInput.option("value", this._currentColor.toHex().replace("#", ""));
                this._rgbInputs[0].option("value", this._currentColor.r);
                this._rgbInputs[1].option("value", this._currentColor.g);
                this._rgbInputs[2].option("value", this._currentColor.b);
                this._suppressEditorsValueUpdating = false;
                this._makeTransparentBackground(this._$newColor, this._currentColor);
                if (this.option("editAlphaChannel")) {
                    this._makeCSSLinearGradient.call(this, this._$alphaChannelScale);
                    this._alphaChannelInput.option("value", this._currentColor.a)
                }
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "value":
                        this._setCurrentColor(value);
                        if (!this._updateByDrag) {
                            this._refreshMarkup()
                        }
                        this._updateByDrag = false;
                        this.callBase(args);
                        break;
                    case "editAlphaChannel":
                        if (this._$colorPickerContainer) {
                            this._renderHtmlRows("editAlphaChannel");
                            this._renderAlphaChannelElements()
                        }
                        break;
                    case "applyValueMode":
                        if (this._$colorPickerContainer) {
                            this._renderHtmlRows("applyValueMode")
                        }
                        break;
                    case "keyStep":
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxColorView", ColorView);
        module.exports = ColorView
    },
    /*!**********************************!*\
      !*** ./Scripts/ui/number_box.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./number_box/number_box */ 256)
    },
    /*!*********************************************!*\
      !*** ./Scripts/ui/number_box/number_box.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            TextEditor = __webpack_require__( /*! ../text_box/ui.text_editor */ 208),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            wheelEvent = __webpack_require__( /*! ../../events/core/wheel */ 77),
            SpinButton = __webpack_require__( /*! ./number_box.spin */ 257),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var math = Math;
        var WIDGET_CLASS = "dx-numberbox",
            SPIN_CLASS = "dx-numberbox-spin",
            SPIN_CONTAINER_CLASS = "dx-numberbox-spin-container",
            SPIN_TOUCH_FRIENDLY_CLASS = "dx-numberbox-spin-touch-friendly";
        var FIREFOX_CONTROL_KEYS = ["Tab", "Del", "Delete", "Backspace", "Left", "ArrowLeft", "Right", "ArrowRight", "Home", "End"];
        var NumberBox = TextEditor.inherit({
            _supportedKeys: function() {
                return $.extend(this.callBase(), {
                    upArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        this._spinUpChangeHandler(e)
                    },
                    downArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        this._spinDownChangeHandler(e)
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: 0,
                    min: void 0,
                    max: void 0,
                    step: 1,
                    showSpinButtons: false,
                    useTouchSpinButtons: true,
                    mode: "text",
                    invalidValueMessage: messageLocalization.format("dxNumberBox-invalidValueMessage")
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return devices.real().generic && !devices.isSimulator()
                    },
                    options: {
                        useTouchSpinButtons: false
                    }
                }, {
                    device: function() {
                        return "generic" !== devices.real().platform
                    },
                    options: {
                        mode: "number"
                    }
                }])
            },
            _render: function() {
                this.callBase();
                if (this.option("isValid")) {
                    this._validateValue(this.option("value"))
                }
                this.element().addClass(WIDGET_CLASS);
                this.setAria("role", "spinbutton");
                this._renderMouseWheelHandler()
            },
            _keyPressHandler: function(e) {
                this.callBase(e);
                var ch = String.fromCharCode(e.which),
                    validCharRegExp = /[\d.,eE\-+]/,
                    isInputCharValid = validCharRegExp.test(ch);
                if (!isInputCharValid) {
                    if (e.metaKey || e.ctrlKey || e.key && $.inArray(e.key, FIREFOX_CONTROL_KEYS) >= 0) {
                        return
                    }
                    e.preventDefault();
                    return false
                }
                this._keyPressed = true
            },
            _renderMouseWheelHandler: function(e) {
                var eventName = eventUtils.addNamespace(wheelEvent.name, this.NAME);
                var mouseWheelAction = this._createAction($.proxy(function(e) {
                    this._mouseWheelHandler(e.jQueryEvent)
                }, this));
                this._input().off(eventName).on(eventName, function(e) {
                    mouseWheelAction({
                        jQueryEvent: e
                    })
                })
            },
            _mouseWheelHandler: function(jQueryEvent) {
                if (!this._input().is(":focus")) {
                    return
                }
                jQueryEvent.delta > 0 ? this._spinValueChange(1, jQueryEvent) : this._spinValueChange(-1, jQueryEvent);
                jQueryEvent.preventDefault();
                jQueryEvent.stopPropagation()
            },
            _renderValue: function() {
                var inputValue = this._input().val();
                if (!inputValue.length || Number(inputValue) !== this.option("value")) {
                    this._forceValueRender();
                    this._toggleEmptinessEventHandler()
                }
                var value = this.option("value");
                this._renderInputAddons();
                this.setAria("valuenow", value)
            },
            _renderValueEventName: function() {
                return this.callBase() + " keypress"
            },
            _toggleDisabledState: function(value) {
                if (this._$spinUp) {
                    SpinButton.getInstance(this._$spinUp).option("disabled", value)
                }
                if (this._$spinDown) {
                    SpinButton.getInstance(this._$spinDown).option("disabled", value)
                }
                this.callBase.apply(this, arguments)
            },
            _forceValueRender: function() {
                var value = this.option("value"),
                    number = Number(value),
                    valueFormat = this.option("valueFormat"),
                    formattedValue = isNaN(number) ? "" : valueFormat(value);
                this._renderDisplayText(formattedValue)
            },
            _renderProps: function() {
                this.callBase();
                this._input().prop({
                    min: this.option("min"),
                    max: this.option("max"),
                    step: this.option("step")
                });
                this.setAria({
                    valuemin: this.option("min") || "undefined",
                    valuemax: this.option("max") || "undefined"
                })
            },
            _renderInputAddons: function() {
                this.callBase();
                this._renderSpinButtons()
            },
            _renderSpinButtons: function() {
                var spinButtonsVisible = this.option("showSpinButtons");
                this.element().toggleClass(SPIN_CLASS, spinButtonsVisible);
                this._toggleTouchFriendlyClass();
                if (!spinButtonsVisible) {
                    this._$spinContainer && this._$spinContainer.remove();
                    this._$spinContainer = null;
                    return
                }
                if (!this._$spinContainer) {
                    this._$spinContainer = this._createSpinButtons()
                }
                this._$spinContainer.prependTo(this._buttonsContainer())
            },
            _toggleTouchFriendlyClass: function() {
                this.element().toggleClass(SPIN_TOUCH_FRIENDLY_CLASS, this.option("showSpinButtons") && this.option("useTouchSpinButtons"))
            },
            _createSpinButtons: function() {
                var eventName = eventUtils.addNamespace(pointerEvents.down, this.NAME);
                var pointerDownAction = this._createAction($.proxy(this._spinButtonsPointerDownHandler, this));
                var $spinContainer = $("<div>").addClass(SPIN_CONTAINER_CLASS).off(eventName).on(eventName, function(e) {
                    pointerDownAction({
                        jQueryEvent: e
                    })
                });
                this._$spinUp = $("<div>").appendTo($spinContainer);
                this._createComponent(this._$spinUp, SpinButton, {
                    direction: "up",
                    onChange: $.proxy(this._spinUpChangeHandler, this)
                });
                this._$spinDown = $("<div>").appendTo($spinContainer);
                this._createComponent(this._$spinDown, SpinButton, {
                    direction: "down",
                    onChange: $.proxy(this._spinDownChangeHandler, this)
                });
                return $spinContainer
            },
            _spinButtonsPointerDownHandler: function(e) {
                var $input = this._input();
                if (!this.option("useTouchSpinButtons") && document.activeElement !== $input[0]) {
                    $input.trigger("focus")
                }
            },
            _spinUpChangeHandler: function(e) {
                if (!this.option("readOnly")) {
                    this._spinValueChange(1, e.jQueryEvent || e)
                }
            },
            _spinDownChangeHandler: function(e) {
                if (!this.option("readOnly")) {
                    this._spinValueChange(-1, e.jQueryEvent || e)
                }
            },
            _spinValueChange: function(sign, jQueryEvent) {
                var value = parseFloat(this._normalizeInputValue()) || 0,
                    step = parseFloat(this.option("step"));
                value = this._correctRounding(value, step * sign);
                var min = this.option("min"),
                    max = this.option("max");
                if (void 0 !== min) {
                    value = Math.max(min, value)
                }
                if (void 0 !== max) {
                    value = Math.min(max, value)
                }
                this._saveValueChangeEvent(jQueryEvent);
                this.option("value", value)
            },
            _correctRounding: function(value, step) {
                var regex = /[,|.](.*)/;
                var isFloatValue = regex.test(value),
                    isFloatStep = regex.test(step);
                if (isFloatValue || isFloatStep) {
                    var valueAccuracy = isFloatValue ? regex.exec(value)[0].length : 0,
                        stepAccuracy = isFloatStep ? regex.exec(step)[0].length : 0,
                        accuracy = math.max(valueAccuracy, stepAccuracy);
                    value = this._round(value + step, accuracy);
                    return value
                }
                return value + step
            },
            _round: function(value, precision) {
                precision = precision || 0;
                var multiplier = Math.pow(10, precision);
                value *= multiplier;
                value = Math.round(value) / multiplier;
                return value
            },
            _renderValueChangeEvent: function() {
                this.callBase();
                this._input().focusout($.proxy(this._forceRefreshInputValue, this))
            },
            _forceRefreshInputValue: function() {
                if ("number" === this.option("mode")) {
                    return
                }
                var $input = this._input(),
                    valueFormat = this.option("valueFormat");
                $input.val(null);
                $input.val(valueFormat(this.option("value")))
            },
            _valueChangeEventHandler: function(e) {
                var $input = this._input(),
                    inputValue = $input.val(),
                    value = this._normalizeInputValue(),
                    valueFormat = this.option("valueFormat");
                if (this._shouldBeValidated() && !this._validateValue(value)) {
                    $input.val(valueFormat(this.option("value")));
                    return
                }
                if ("number" === this.option("mode")) {
                    this.callBase(e, isNaN(value) ? null : value);
                    return
                }
                if ("." === inputValue || "-" === inputValue) {
                    return
                }
                this.callBase(e, value);
                if (this._isValueIncomplete(inputValue)) {
                    return
                }
                if (Number(inputValue) !== value) {
                    $input.val(valueFormat(value))
                }
            },
            _inputIsInvalid: function() {
                var isNumberMode = "number" === this.option("mode");
                var validityState = this._input().get(0).validity;
                return isNumberMode && validityState && validityState.badInput
            },
            _renderDisplayText: function(text) {
                if (this._inputIsInvalid()) {
                    return
                }
                this.callBase(text)
            },
            _isValueIncomplete: function(value) {
                var incompleteRegex = /^(([+-])|([+-]?(0|[1-9]\d*)?[.,])|([+-]?(0|[1-9]\d*)?([.,]\d+)[eE][+-]?)|([+-]?(0|[1-9]\d*)[eE][+-]?))$/;
                return incompleteRegex.test(value)
            },
            _shouldBeValidated: function() {
                var inputValue = this._normalizeText();
                return !!inputValue && !isNaN(Number(inputValue)) && this._isValueValid()
            },
            _validateValue: function(value) {
                var inputValue = this._normalizeText(),
                    isValueValid = this._isValueValid(),
                    isValid = true,
                    isNumber = /^[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?$/.test(inputValue);
                if (isNaN(Number(value))) {
                    isValid = false
                }
                if (!value && isValueValid) {
                    isValid = true
                } else {
                    if (!isNumber && !isValueValid) {
                        isValid = false
                    }
                }
                this.option({
                    isValid: isValid,
                    validationError: isValid ? null : {
                        editorSpecific: true,
                        message: this.option("invalidValueMessage")
                    }
                });
                return isValid
            },
            _normalizeInputValue: function() {
                return this._normalizeValue()
            },
            _normalizeValue: function(value) {
                return this._parseValue(this._normalizeText(value))
            },
            _normalizeText: function(value) {
                value = $.trim(commonUtils.isDefined(value) ? value : this._input().val());
                return value.replace(",", ".")
            },
            _parseValue: function(value) {
                if ("" === value) {
                    return null
                }
                var number = parseFloat(value);
                if (isNaN(number)) {
                    return null
                }
                if (void 0 !== this.option("min")) {
                    number = math.max(number, this.option("min"))
                }
                if (void 0 !== this.option("max")) {
                    number = math.min(number, this.option("max"))
                }
                return number
            },
            _clean: function() {
                delete this._$spinContainer;
                delete this._$spinUp;
                delete this._$spinDown;
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "value":
                        this._validateValue(args.value);
                        this.callBase(args);
                        this._resumeValueChangeAction();
                        break;
                    case "step":
                    case "min":
                    case "max":
                        this._renderProps();
                        break;
                    case "showSpinButtons":
                        this._renderInputAddons();
                        break;
                    case "useTouchSpinButtons":
                        this._toggleTouchFriendlyClass();
                        break;
                    case "invalidValueMessage":
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxNumberBox", NumberBox);
        module.exports = NumberBox
    },
    /*!**************************************************!*\
      !*** ./Scripts/ui/number_box/number_box.spin.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            feedbackEvents = __webpack_require__( /*! ../../events/core/emitter.feedback */ 103),
            holdEvent = __webpack_require__( /*! ../../events/hold */ 164);
        var SPIN_CLASS = "dx-numberbox-spin",
            SPIN_BUTTON_CLASS = "dx-numberbox-spin-button",
            SPIN_HOLD_DELAY = 100,
            NUMBER_BOX = "dxNumberBox",
            POINTERUP_EVENT_NAME = eventUtils.addNamespace(pointerEvents.up, NUMBER_BOX),
            POINTERCANCEL_EVENT_NAME = eventUtils.addNamespace(pointerEvents.cancel, NUMBER_BOX);
        var SpinButton = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    direction: "up",
                    onChange: null,
                    activeStateEnabled: true,
                    hoverStateEnabled: true
                })
            },
            _render: function() {
                this.callBase();
                var $element = this.element(),
                    direction = SPIN_CLASS + "-" + this.option("direction");
                var eventName = eventUtils.addNamespace(pointerEvents.down, this.NAME);
                $element.addClass(SPIN_BUTTON_CLASS).addClass(direction).off(eventName).on(eventName, $.proxy(this._spinDownHandler, this));
                this._spinIcon = $("<div>").addClass(direction + "-icon").appendTo(this.element());
                this._spinChangeHandler = this._createActionByOption("onChange")
            },
            _spinDownHandler: function(e) {
                e.preventDefault();
                this._clearTimer();
                $(document).on(holdEvent.name, $.proxy(function() {
                    this._feedBackDeferred = $.Deferred();
                    feedbackEvents.lock(this._feedBackDeferred);
                    this._spinChangeHandler({
                        jQueryEvent: e
                    });
                    this._holdTimer = setInterval(this._spinChangeHandler, SPIN_HOLD_DELAY, {
                        jQueryEvent: e
                    })
                }, this)).on(POINTERUP_EVENT_NAME, $.proxy(this._clearTimer, this)).on(POINTERCANCEL_EVENT_NAME, $.proxy(this._clearTimer, this));
                this._spinChangeHandler({
                    jQueryEvent: e
                })
            },
            _dispose: function() {
                this._clearTimer();
                this.callBase()
            },
            _clearTimer: function(e) {
                $(document).off(POINTERUP_EVENT_NAME).off(POINTERCANCEL_EVENT_NAME).off(holdEvent.name);
                if (this._feedBackDeferred) {
                    this._feedBackDeferred.resolve()
                }
                if (this._holdTimer) {
                    clearInterval(this._holdTimer)
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onChange":
                    case "direction":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        module.exports = SpinButton
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/draggable.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            stringUtils = __webpack_require__( /*! ../core/utils/string */ 13),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            dasherize = __webpack_require__( /*! ../core/utils/inflector */ 49).dasherize,
            DOMComponent = __webpack_require__( /*! ../core/dom_component */ 29),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../events/pointer */ 65),
            dragEvents = __webpack_require__( /*! ../events/drag */ 110);
        var DRAGGABLE = "dxDraggable",
            DRAGSTART_EVENT_NAME = eventUtils.addNamespace(dragEvents.start, DRAGGABLE),
            DRAG_EVENT_NAME = eventUtils.addNamespace(dragEvents.move, DRAGGABLE),
            DRAGEND_EVENT_NAME = eventUtils.addNamespace(dragEvents.end, DRAGGABLE),
            POINTERDOWN_EVENT_NAME = eventUtils.addNamespace(pointerEvents.down, DRAGGABLE),
            DRAGGABLE_CLASS = dasherize(DRAGGABLE),
            DRAGGABLE_DRAGGING_CLASS = DRAGGABLE_CLASS + "-dragging";
        var Draggable = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    onDragStart: $.noop,
                    onDrag: $.noop,
                    onDragEnd: $.noop,
                    direction: "both",
                    area: window,
                    boundOffset: 0,
                    allowMoveByClick: false
                })
            },
            _init: function() {
                this.callBase();
                this._attachEventHandlers()
            },
            _attachEventHandlers: function() {
                if (this.option("disabled")) {
                    return
                }
                var $element = this.element().css("position", "absolute"),
                    eventHandlers = {},
                    allowMoveByClick = this.option("allowMoveByClick");
                eventHandlers[DRAGSTART_EVENT_NAME] = $.proxy(this._dragStartHandler, this);
                eventHandlers[DRAG_EVENT_NAME] = $.proxy(this._dragHandler, this);
                eventHandlers[DRAGEND_EVENT_NAME] = $.proxy(this._dragEndHandler, this);
                if (allowMoveByClick) {
                    eventHandlers[POINTERDOWN_EVENT_NAME] = $.proxy(this._pointerDownHandler, this);
                    $element = this._getArea()
                }
                $element.on(eventHandlers, {
                    direction: this.option("direction"),
                    immediate: true
                })
            },
            _detachEventHandlers: function() {
                this.element().off("." + DRAGGABLE);
                this._getArea().off("." + DRAGGABLE)
            },
            _move: function(position) {
                translator.move(this.element(), position)
            },
            _pointerDownHandler: function(e) {
                if (eventUtils.needSkipEvent(e)) {
                    return
                }
                var areaOffset = this._getAreaOffset($(e.currentTarget)),
                    direction = this.option("direction"),
                    position = {};
                if ("horizontal" === direction || "both" === direction) {
                    position.left = e.pageX - this.element().width() / 2 - areaOffset.left
                }
                if ("vertical" === direction || "both" === direction) {
                    position.top = e.pageY - this.element().height() / 2 - areaOffset.top
                }
                this._move(position);
                this._getAction("onDrag")({
                    jQueryEvent: e
                })
            },
            _dragStartHandler: function(e) {
                var $element = this.element();
                if ($element.is(".dx-state-disabled, .dx-state-disabled *")) {
                    e.cancel = true;
                    return
                }
                var $area = this._getArea(),
                    areaOffset = this._getAreaOffset($area),
                    boundOffset = this._getBoundOffset(),
                    areaWidth = $area.outerWidth(),
                    areaHeight = $area.outerHeight(),
                    elementWidth = $element.width(),
                    elementHeight = $element.height();
                this._toggleDraggingClass(true);
                var startOffset = {
                    left: $element.offset().left - areaOffset.left,
                    top: $element.offset().top - areaOffset.top
                };
                this._startPosition = translator.locate($element);
                e.maxLeftOffset = startOffset.left - boundOffset.left;
                e.maxRightOffset = areaWidth - startOffset.left - elementWidth - boundOffset.right;
                e.maxTopOffset = startOffset.top - boundOffset.top;
                e.maxBottomOffset = areaHeight - startOffset.top - elementHeight - boundOffset.bottom;
                this._getAction("onDragStart")({
                    jQueryEvent: e
                })
            },
            _getAreaOffset: function($area) {
                var offset = $area && $area.offset();
                return offset ? offset : {
                    left: 0,
                    top: 0
                }
            },
            _toggleDraggingClass: function(value) {
                this.element().toggleClass(DRAGGABLE_DRAGGING_CLASS, value)
            },
            _getBoundOffset: function() {
                var boundOffset = this.option("boundOffset");
                if ($.isFunction(boundOffset)) {
                    boundOffset = boundOffset.call(this)
                }
                return stringUtils.quadToObject(boundOffset)
            },
            _getArea: function() {
                var area = this.option("area");
                if ($.isFunction(area)) {
                    area = area.call(this)
                }
                return $(area)
            },
            _dragHandler: function(e) {
                var offset = e.offset,
                    startPosition = this._startPosition;
                this._move({
                    left: startPosition.left + offset.x,
                    top: startPosition.top + offset.y
                });
                this._getAction("onDrag")({
                    jQueryEvent: e
                })
            },
            _dragEndHandler: function(e) {
                this._toggleDraggingClass(false);
                this._getAction("onDragEnd")({
                    jQueryEvent: e
                })
            },
            _getAction: function(name) {
                return this["_" + name + "Action"] || this._createActionByOption(name)
            },
            _render: function() {
                this.callBase();
                this.element().addClass(DRAGGABLE_CLASS)
            },
            _optionChanged: function(args) {
                var name = args.name;
                switch (name) {
                    case "onDragStart":
                    case "onDrag":
                    case "onDragEnd":
                        this["_" + name + "Action"] = this._createActionByOption(name);
                        break;
                    case "allowMoveByClick":
                    case "direction":
                    case "disabled":
                        this._detachEventHandlers();
                        this._attachEventHandlers();
                        break;
                    case "boundOffset":
                    case "area":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _dispose: function() {
                this.callBase();
                this._detachEventHandlers()
            }
        });
        registerComponent(DRAGGABLE, Draggable);
        module.exports = Draggable
    },
    /*!********************************!*\
      !*** ./Scripts/ui/date_box.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./date_box/ui.date_box */ 260)
    },
    /*!********************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_box.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            compareVersions = __webpack_require__( /*! ../../core/utils/version */ 45).compare,
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            uiDateUtils = __webpack_require__( /*! ./ui.date_utils */ 261),
            DropDownEditor = __webpack_require__( /*! ../drop_down_editor/ui.drop_down_editor */ 205),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            DATEBOX_CLASS = "dx-datebox",
            DATEBOX_WRAPPER_CLASS = "dx-datebox-wrapper";
        var PICKER_TYPE = {
            calendar: "calendar",
            rollers: "rollers",
            list: "list",
            "native": "native"
        };
        var TYPE = {
            date: "date",
            datetime: "datetime",
            time: "time"
        };
        var STRATEGY_NAME = {
            calendar: "Calendar",
            dateview: "DateView",
            "native": "Native",
            calendarWithTime: "CalendarWithTime",
            list: "List"
        };
        var STRATEGY_CLASSES = {
            Calendar: __webpack_require__( /*! ./ui.date_box.strategy.calendar */ 262),
            DateView: __webpack_require__( /*! ./ui.date_box.strategy.date_view */ 264),
            Native: __webpack_require__( /*! ./ui.date_box.strategy.native */ 267),
            CalendarWithTime: __webpack_require__( /*! ./ui.date_box.strategy.calendar_with_time */ 268),
            List: __webpack_require__( /*! ./ui.date_box.strategy.list */ 270)
        };
        var realWidthSetted = function($element) {
            var explicitWidth = $element[0].style.width;
            if (explicitWidth && "auto" !== explicitWidth && "inherit" !== explicitWidth) {
                return true
            }
            return false
        };
        var calculateWidth = function(value, $input, $element) {
            var IE_ROUNDING_ERROR = 10;
            var NATIVE_BUTTONS_WIDTH = 48;
            var $longestValueElement = $("<div>").text(value).css({
                "font-style": $input.css("font-style"),
                "font-variant": $input.css("font-variant"),
                "font-weight": $input.css("font-weight"),
                "font-size": $input.css("font-size"),
                "font-family": $input.css("font-family"),
                "letter-spacing": $input.css("letter-spacing"),
                "padding-left": $input.css("padding-left"),
                "padding-right": $input.css("padding-right"),
                border: $input.css("border"),
                visibility: "hidden",
                "white-space": "nowrap",
                position: "absolute",
                "float": "left"
            });
            $longestValueElement.appendTo($element);
            var width = $longestValueElement.outerWidth() + IE_ROUNDING_ERROR + ("text" !== $input.prop("type") ? NATIVE_BUTTONS_WIDTH : 0);
            $longestValueElement.remove();
            return width
        };
        var DateBox = DropDownEditor.inherit({
            _supportedKeys: function() {
                return $.extend(this.callBase(), this._strategy.supportedKeys())
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    format: {
                        since: "16.1",
                        alias: "type"
                    },
                    formatString: {
                        since: "16.1",
                        alias: "displayFormat"
                    },
                    useNative: {
                        since: "15.1",
                        message: "'useNative' option is deprecated in 15.1. Use the 'pickerType' option instead"
                    },
                    useCalendar: {
                        since: "15.1",
                        message: "'useCalendar' option is deprecated in 15.1. Use the 'pickerType' option instead"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    type: "date",
                    value: null,
                    min: void 0,
                    max: void 0,
                    useCalendar: false,
                    displayFormat: null,
                    interval: 30,
                    maxZoomLevel: "month",
                    minZoomLevel: "century",
                    useNative: true,
                    pickerType: PICKER_TYPE.native,
                    invalidDateMessage: messageLocalization.format("dxDateBox-validation-datetime"),
                    dateOutOfRangeMessage: messageLocalization.format("validation-range"),
                    applyButtonText: messageLocalization.format("Done"),
                    adaptivityEnabled: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "ios"
                    },
                    options: {
                        showPopupTitle: true
                    }
                }, {
                    device: function(device) {
                        return "android" === device.platform
                    },
                    options: {
                        buttonsLocation: "bottom after"
                    }
                }, {
                    device: function(device) {
                        return "win" === device.platform && device.version && 8 === device.version[0]
                    },
                    options: {
                        buttonsLocation: "bottom after"
                    }
                }, {
                    device: function(device) {
                        return "win" === device.platform && device.version && 10 === device.version[0]
                    },
                    options: {
                        buttonsLocation: "bottom center"
                    }
                }, {
                    device: function() {
                        var realDevice = devices.real(),
                            platform = realDevice.platform,
                            version = realDevice.version;
                        return "generic" === platform || "win" === platform || "android" === platform && compareVersions(version, [4, 4]) < 0
                    },
                    options: {
                        pickerType: PICKER_TYPE.rollers
                    }
                }, {
                    device: {
                        platform: "generic",
                        deviceType: "desktop"
                    },
                    options: {
                        pickerType: PICKER_TYPE.calendar,
                        buttonsLocation: "bottom after"
                    }
                }, {
                    device: function() {
                        var realDevice = devices.real(),
                            platform = realDevice.platform,
                            isPhone = realDevice.phone;
                        return "win" === platform && !isPhone
                    },
                    options: {
                        pickerType: PICKER_TYPE.calendar
                    }
                }])
            },
            _initOptions: function(options) {
                this._userOptions = $.extend({}, options);
                this.callBase(options);
                this._updatePickerOptions(this._userOptions)
            },
            _updatePickerOptions: function(userOptions) {
                var pickerType = this._getPickerTypeByDepricatedOptions(userOptions);
                var type = this.option("type");
                if (pickerType === PICKER_TYPE.list && (type === TYPE.datetime || type === TYPE.date)) {
                    pickerType = PICKER_TYPE.calendar
                }
                if (type === TYPE.time && pickerType === PICKER_TYPE.calendar) {
                    pickerType = PICKER_TYPE.list
                }
                this.option("showDropButton", "generic" !== devices.real().platform || pickerType !== PICKER_TYPE.native);
                this._pickerType = pickerType
            },
            _getPickerTypeByDepricatedOptions: function(userOptions) {
                return userOptions.pickerType ? userOptions.pickerType : commonUtils.isDefined(userOptions.useCalendar) || commonUtils.isDefined(userOptions.useNative) ? this._getPickerType() : this._pickerType || this.option("pickerType")
            },
            _getPickerType: function() {
                if (this.option().useCalendar) {
                    return this.option("type") === TYPE.time ? PICKER_TYPE.list : PICKER_TYPE.calendar
                }
                if (this.option().useNative) {
                    return PICKER_TYPE.native
                }
                return PICKER_TYPE.rollers
            },
            _init: function() {
                this._initStrategy();
                this.option($.extend({}, this._strategy.getDefaultOptions(), this._userOptions));
                delete this._userOptions;
                this.callBase()
            },
            _toLowerCaseFirstLetter: function(string) {
                return string.charAt(0).toLowerCase() + string.substr(1)
            },
            _initStrategy: function() {
                var strategyName = this._getStrategyName(this._getFormatType()),
                    strategy = STRATEGY_CLASSES[strategyName];
                if (!(this._strategy && this._strategy.NAME === strategyName)) {
                    this._strategy = new strategy(this)
                }
            },
            _getFormatType: function() {
                var currentType = this.option("type");
                var isTime = /h|m|s/g.test(currentType),
                    isDate = /d|M|Y/g.test(currentType);
                var type = "";
                if (isDate) {
                    type += TYPE.date
                }
                if (isTime) {
                    type += TYPE.time
                }
                return type
            },
            _getStrategyName: function(type) {
                var pickerType = this._pickerType;
                if (pickerType === PICKER_TYPE.rollers) {
                    return this.option().useCalendar ? STRATEGY_NAME.calendar : STRATEGY_NAME.dateview
                }
                if (pickerType === PICKER_TYPE.native) {
                    return STRATEGY_NAME.native
                }
                if (type === TYPE.date) {
                    return STRATEGY_NAME.calendar
                }
                if (type === TYPE.datetime) {
                    return STRATEGY_NAME.calendarWithTime
                }
                return STRATEGY_NAME.list
            },
            _render: function() {
                this.element().addClass(DATEBOX_CLASS);
                this._refreshFormatClass();
                this._refreshPickerTypeClass();
                this.callBase();
                this._updateSize();
                this._strategy.renderInputMinMax(this._input())
            },
            _refreshFormatClass: function() {
                var $element = this.element();
                $.each(TYPE, $.proxy(function(_, item) {
                    $element.removeClass(DATEBOX_CLASS + "-" + item)
                }, null));
                $element.addClass(DATEBOX_CLASS + "-" + this.option("type"))
            },
            _refreshPickerTypeClass: function() {
                var $element = this.element();
                $.each(PICKER_TYPE, $.proxy(function(_, item) {
                    $element.removeClass(DATEBOX_CLASS + "-" + item)
                }, null));
                $element.addClass(DATEBOX_CLASS + "-" + this._pickerType)
            },
            _updateSize: function() {
                var $element = this.element(),
                    widthOption = this.option("width"),
                    isWidthSet = commonUtils.isDefined(widthOption) || realWidthSetted($element) && !this._isSizeUpdatable,
                    isElementVisible = $element.is(":visible"),
                    pickerType = this._pickerType,
                    shouldCalculateWidth = pickerType !== PICKER_TYPE.rollers && "generic" === devices.current().platform;
                if (isWidthSet || !(shouldCalculateWidth && isElementVisible)) {
                    return
                }
                var $input = this._input(),
                    format = this._strategy.getDisplayFormat(this.option("displayFormat")),
                    longestValue = dateLocalization.format(uiDateUtils.getLongestDate(format, dateLocalization.getMonthNames(), dateLocalization.getDayNames()), format);
                $element.width(calculateWidth(longestValue, $input, this.element()));
                this._isSizeUpdatable = true
            },
            _attachChildKeyboardEvents: function() {
                this._strategy.attachKeyboardEvents(this._keyboardProcessor)
            },
            _renderPopup: function() {
                this.callBase();
                this._popup._wrapper().addClass(DATEBOX_WRAPPER_CLASS);
                this._renderPopupWrapper()
            },
            _popupConfig: function() {
                var popupConfig = this.callBase();
                return $.extend(this._strategy.popupConfig(popupConfig), {
                    title: this._getPopupTitle(),
                    dragEnabled: false
                })
            },
            _renderPopupWrapper: function() {
                if (!this._popup) {
                    return
                }
                var $element = this.element();
                var classPostfixes = $.extend({}, TYPE, PICKER_TYPE);
                $.each(classPostfixes, $.proxy(function(_, item) {
                    $element.removeClass(DATEBOX_WRAPPER_CLASS + "-" + item)
                }, this));
                this._popup._wrapper().addClass(DATEBOX_WRAPPER_CLASS + "-" + this.option("type")).addClass(DATEBOX_WRAPPER_CLASS + "-" + this._pickerType)
            },
            _renderPopupContent: function() {
                this.callBase();
                this._strategy.renderPopupContent()
            },
            _getFirstPopupElement: function() {
                return this._strategy.getFirstPopupElement() || this.callBase()
            },
            _getLastPopupElement: function() {
                return this._strategy.getLastPopupElement() || this.callBase()
            },
            _popupShowingHandler: function() {
                this.callBase();
                this._strategy.popupShowingHandler()
            },
            _popupHiddenHandler: function() {
                this.callBase();
                this._strategy.popupHiddenHandler()
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._updateSize()
                }
            },
            _readOnlyPropValue: function() {
                return this.callBase() || this._pickerType === PICKER_TYPE.rollers
            },
            _clearButtonVisibility: function() {
                return this.callBase() && !this._isNativeType()
            },
            _renderValue: function() {
                var pattern, mode = this.option("mode"),
                    value = this.dateOption("value");
                if ("text" !== mode) {
                    pattern = this._getPattern(uiDateUtils.FORMATS_MAP[mode]);
                    this.option("text", uiDateUtils.toStandardDateFormat(value, mode, pattern))
                } else {
                    var displayFormat = this._strategy.getDisplayFormat(this.option("displayFormat"));
                    this.option("text", dateLocalization.format(value, displayFormat))
                }
                this._strategy.renderValue();
                this.callBase()
            },
            _getPattern: function(type) {
                return !support.inputType(this.option("mode")) ? dateLocalization.getPatternByFormat(type) : null
            },
            _valueChangeEventHandler: function(e) {
                var displayFormat = this._strategy.getDisplayFormat(this.option("displayFormat")),
                    date = this._strategy.getParsedText(this.option("text"), displayFormat),
                    value = this.dateOption("value"),
                    modelValue = new Date(value && value.valueOf()),
                    type = this.option("type"),
                    newValue = uiDateUtils.mergeDates(modelValue, date, type) || null;
                if (this._validateValue(date)) {
                    this.dateOption("value", newValue)
                }
                this.validationRequest.fire({
                    value: newValue,
                    editor: this
                })
            },
            _validateValue: function(value) {
                var text = this.option("text"),
                    hasText = !!text,
                    isDate = !!value && !isNaN(value.getTime()),
                    isDateInRange = isDate && dateUtils.dateInRange(value, this.dateOption("min"), this.dateOption("max"), this.option("type")),
                    isValid = !hasText || !hasText && !value || isDateInRange,
                    validationMessage = "";
                if (!isDate) {
                    validationMessage = this.option("invalidDateMessage")
                } else {
                    if (!isDateInRange) {
                        validationMessage = this.option("dateOutOfRangeMessage")
                    }
                }
                this.option({
                    isValid: isValid,
                    validationError: isValid ? null : {
                        editorSpecific: true,
                        message: validationMessage
                    }
                });
                return isValid
            },
            _renderProps: function() {
                this.callBase();
                this._input().attr("autocomplete", "off")
            },
            _renderOpenedState: function() {
                if (!this._isNativeType()) {
                    this.callBase()
                }
                if (this._strategy.isAdaptivityChanged()) {
                    this._refreshStrategy()
                }
                this._strategy.renderOpenedState()
            },
            _getPopupTitle: function() {
                var placeholder = this.option("placeholder");
                if (placeholder) {
                    return placeholder
                }
                var type = this.option("type");
                if (type === TYPE.time) {
                    return messageLocalization.format("dxDateBox-simulatedDataPickerTitleTime")
                }
                if (type === TYPE.date || type === TYPE.datetime) {
                    return messageLocalization.format("dxDateBox-simulatedDataPickerTitleDate")
                }
                return ""
            },
            _renderPlaceholder: function() {
                this._popup && this._popup.option("title", this._getPopupTitle());
                this.callBase()
            },
            _refreshStrategy: function() {
                this._strategy.dispose();
                this._initStrategy();
                this.option(this._strategy.getDefaultOptions());
                this._refresh()
            },
            _applyButtonHandler: function() {
                this.dateOption("value", this._strategy.getValue());
                this.callBase()
            },
            _dispose: function() {
                this._strategy && this._strategy.dispose();
                this.callBase()
            },
            _isNativeType: function() {
                return this._pickerType === PICKER_TYPE.native
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "useCalendar":
                        this._updatePickerOptions({
                            useCalendar: args.value
                        });
                        this._refreshStrategy();
                        break;
                    case "useNative":
                        this._updatePickerOptions({
                            useNative: args.value
                        });
                        this._refreshStrategy();
                        break;
                    case "showClearButton":
                        this.callBase.apply(this, arguments);
                        this._updateSize();
                        break;
                    case "pickerType":
                        this._updatePickerOptions({
                            pickerType: args.value
                        });
                        this._refreshStrategy();
                        this._refreshPickerTypeClass();
                        this._invalidate();
                        break;
                    case "type":
                        this._updatePickerOptions({
                            format: args.value
                        });
                        this._refreshStrategy();
                        this._refreshFormatClass();
                        this._renderPopupWrapper();
                        this._updateSize();
                        break;
                    case "placeholder":
                        this._renderPlaceholder();
                        break;
                    case "readOnly":
                    case "min":
                    case "max":
                    case "interval":
                    case "minZoomLevel":
                    case "maxZoomLevel":
                        this._invalidate();
                        break;
                    case "displayFormat":
                        this._updateValue();
                        break;
                    case "formatWidthCalculator":
                        break;
                    case "closeOnValueChange":
                        var applyValueMode = args.value ? "instantly" : "useButtons";
                        this.option("applyValueMode", applyValueMode);
                        break;
                    case "applyValueMode":
                        this._suppressDeprecatedWarnings();
                        this.option("closeOnValueChange", "instantly" === args.value);
                        this._resumeDeprecatedWarnings();
                        this.callBase.apply(this, arguments);
                        break;
                    case "text":
                        this._strategy.textChangedHandler(args.value);
                        this.callBase.apply(this, arguments);
                        break;
                    case "isValid":
                        this.callBase.apply(this, arguments);
                        this._updateSize();
                        break;
                    case "value":
                        this._validateValue(dateUtils.deserializeDate(this.option("value"), this._getSerializationFormat(this.option("value"))));
                        this.callBase.apply(this, arguments);
                        break;
                    case "showDropButton":
                    case "invalidDateMessage":
                    case "dateOutOfRangeMessage":
                    case "adaptivityEnabled":
                        break;
                    default:
                        this.callBase.apply(this, arguments)
                }
            },
            _getSerializationFormat: function() {
                var value = this.option("value");
                if (commonUtils.isNumber(value)) {
                    return "number"
                }
                if (!commonUtils.isString(value)) {
                    return
                }
                return "date" === this.option("type") ? "yyyy'/'MM'/'dd" : "yyyy'/'MM'/'dd HH:mm:ss"
            },
            dateOption: function(optionName, value) {
                var serializationFormat = this._getSerializationFormat();
                if (1 === arguments.length) {
                    return dateUtils.deserializeDate(this.option(optionName), serializationFormat, $.proxy(dateLocalization.parse, dateLocalization))
                }
                this.option(optionName, dateUtils.serializeDate(value, serializationFormat, $.proxy(dateLocalization.format, dateLocalization)))
            },
            reset: function() {
                this.callBase();
                this._updateValue()
            }
        });
        registerComponent("dxDateBox", DateBox);
        module.exports = DateBox
    },
    /*!**********************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_utils.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var dateComponents = function() {
            return ["year", "day", "month", "day"]
        };
        var ONE_MINUTE = 6e4;
        var ONE_DAY = 60 * ONE_MINUTE * 24;
        var ONE_YEAR = 365 * ONE_DAY;
        var getStringFormat = function(format) {
            var formatType = typeof format;
            if ("string" === formatType) {
                return "format"
            }
            if ("object" === formatType && void 0 !== format.type) {
                return format.type
            }
            return null
        };
        var dateUtils = {
            SUPPORTED_FORMATS: ["date", "time", "datetime"],
            DEFAULT_FORMATTER: function(value) {
                return value
            },
            DATE_COMPONENT_TEXT_FORMATTER: function(value, name) {
                var $container = $("<div>").addClass("dx-dateview-formatter-container");
                $("<span>").text(value).addClass("dx-dateview-value-formatter").appendTo($container);
                $("<span>").text(name).addClass("dx-dateview-name-formatter").appendTo($container);
                return $container
            },
            ONE_MINUTE: ONE_MINUTE,
            ONE_DAY: ONE_DAY,
            ONE_YEAR: ONE_YEAR,
            MIN_DATEVIEW_DEFAULT_DATE: new Date(1900, 0, 1),
            MAX_DATEVIEW_DEFAULT_DATE: function() {
                var newDate = new Date;
                return new Date(newDate.getFullYear() + 50, newDate.getMonth(), newDate.getDate(), 23, 59, 59)
            }(),
            FORMATS_INFO: {
                date: {
                    getStandardPattern: function() {
                        return "yyyy-MM-dd"
                    },
                    components: dateComponents()
                },
                time: {
                    getStandardPattern: function() {
                        return "HH':'mm"
                    },
                    components: ["hours", "minutes"]
                },
                datetime: {
                    getStandardPattern: function() {
                        var standardPattern;
                        ! function() {
                            var androidFormatPattern = "yyyy-MM-ddTHH':'mm'Z'";
                            var $input = $("<input>").attr("type", "datetime");
                            $input.val(dateUtils.toStandardDateFormat(new Date, "datetime", androidFormatPattern));
                            if ($input.val()) {
                                standardPattern = androidFormatPattern
                            }
                        }();
                        if (!standardPattern) {
                            standardPattern = "yyyy-MM-ddTHH':'mm':'ss'Z'"
                        }
                        dateUtils.FORMATS_INFO.datetime.getStandardPattern = function() {
                            return standardPattern
                        };
                        return standardPattern
                    },
                    components: dateComponents().concat(["hours", "minutes", "seconds", "milliseconds"])
                },
                "datetime-local": {
                    getStandardPattern: function() {
                        return "yyyy-MM-ddTHH':'mm':'ss"
                    },
                    components: dateComponents().concat(["hours", "minutes", "seconds"])
                }
            },
            FORMATS_MAP: {
                date: "shortdate",
                time: "shorttime",
                datetime: "shortdateshorttime",
                "datetime-local": "datetime-local"
            },
            toStandardDateFormat: function(date, mode, pattern) {
                pattern = pattern || dateUtils.FORMATS_INFO[mode].getStandardPattern();
                return dateLocalization.format(date, pattern)
            },
            fromStandardDateFormat: function(date) {
                return dateLocalization.parse(date, dateUtils.FORMATS_INFO.datetime.getStandardPattern()) || dateLocalization.parse(date, dateUtils.FORMATS_INFO["datetime-local"].getStandardPattern()) || dateLocalization.parse(date, dateUtils.FORMATS_INFO.time.getStandardPattern()) || dateLocalization.parse(date, dateUtils.FORMATS_INFO.date.getStandardPattern()) || Date.parse && Date.parse(date) && new Date(Date.parse(date))
            },
            getMaxMonthDay: function(year, month) {
                return new Date(year, month + 1, 0).getDate()
            },
            mergeDates: function(target, source, format) {
                if (!source) {
                    return
                }
                if (isNaN(target.getTime())) {
                    target = new Date(0, 0, 0, 0, 0, 0)
                }
                var formatInfo = dateUtils.FORMATS_INFO[format];
                $.each(formatInfo.components, function() {
                    var componentInfo = dateUtils.DATE_COMPONENTS_INFO[this];
                    target[componentInfo.setter](source[componentInfo.getter]())
                });
                return target
            },
            getLongestCaptionIndex: function(captionArray) {
                var i, longestIndex = 0,
                    longestCaptionLength = 0;
                for (i = 0; i < captionArray.length; ++i) {
                    if (captionArray[i].length > longestCaptionLength) {
                        longestIndex = i;
                        longestCaptionLength = captionArray[i].length
                    }
                }
                return longestIndex
            },
            expandPattern: function(pattern) {
                return dateLocalization.getPatternByFormat(pattern) || pattern
            },
            formatUsesMonthName: function(format) {
                return dateUtils.expandPattern(format).indexOf("MMMM") !== -1
            },
            formatUsesDayName: function(format) {
                return dateUtils.expandPattern(format).indexOf("EEEE") !== -1
            },
            getLongestDate: function(format, monthNames, dayNames) {
                var stringFormat = getStringFormat(format),
                    month = 9;
                if (!stringFormat || dateUtils.formatUsesMonthName(stringFormat)) {
                    month = dateUtils.getLongestCaptionIndex(monthNames)
                }
                var longestDate = new Date(1888, month, 21, 23, 59, 59, 999);
                if (!stringFormat || dateUtils.formatUsesDayName(stringFormat)) {
                    var date = longestDate.getDate() - longestDate.getDay() + dateUtils.getLongestCaptionIndex(dayNames);
                    longestDate.setDate(date)
                }
                return longestDate
            }
        };
        dateUtils.DATE_COMPONENTS_INFO = {
            year: {
                getter: "getFullYear",
                setter: "setFullYear",
                possibleFormats: ["y", "yy", "yyyy"],
                formatter: dateUtils.DEFAULT_FORMATTER,
                startValue: void 0,
                endValue: void 0
            },
            day: {
                getter: "getDate",
                setter: "setDate",
                possibleFormats: ["d", "dd"],
                formatter: function(value, showNames, date) {
                    if (!showNames) {
                        return value
                    }
                    var formatDate = new Date(date.getTime());
                    formatDate.setDate(value);
                    return dateUtils.DATE_COMPONENT_TEXT_FORMATTER(value, dateLocalization.getDayNames()[formatDate.getDay()])
                },
                startValue: 1,
                endValue: void 0
            },
            month: {
                getter: "getMonth",
                setter: "setMonth",
                possibleFormats: ["M", "MM", "MMM", "MMMM"],
                formatter: function(value, showNames) {
                    var monthName = dateLocalization.getMonthNames()[value];
                    return showNames ? dateUtils.DATE_COMPONENT_TEXT_FORMATTER(value + 1, monthName) : monthName
                },
                startValue: 0,
                endValue: 11
            },
            hours: {
                getter: "getHours",
                setter: "setHours",
                possibleFormats: ["H", "HH", "h", "hh"],
                formatter: function(value) {
                    return dateLocalization.format(new Date(0, 0, 0, value), "hour")
                },
                startValue: 0,
                endValue: 23
            },
            minutes: {
                getter: "getMinutes",
                setter: "setMinutes",
                possibleFormats: ["m", "mm"],
                formatter: function(value) {
                    return dateLocalization.format(new Date(0, 0, 0, 0, value), "minute")
                },
                startValue: 0,
                endValue: 59
            },
            seconds: {
                getter: "getSeconds",
                setter: "setSeconds",
                possibleFormats: ["s", "ss"],
                formatter: function(value) {
                    return dateLocalization.format(new Date(0, 0, 0, 0, 0, value), "second")
                },
                startValue: 0,
                endValue: 59
            },
            milliseconds: {
                getter: "getMilliseconds",
                setter: "setMilliseconds",
                possibleFormats: ["S", "SS", "SSS"],
                formatter: function(value) {
                    return dateLocalization.format(new Date(0, 0, 0, 0, 0, 0, value), "millisecond")
                },
                startValue: 0,
                endValue: 999
            }
        };
        module.exports = dateUtils
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_box.strategy.calendar.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Calendar = __webpack_require__( /*! ../calendar */ 246),
            DateBoxStrategy = __webpack_require__( /*! ./ui.date_box.strategy */ 263),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var CalendarStrategy = DateBoxStrategy.inherit({
            NAME: "Calendar",
            supportedKeys: function() {
                return {
                    rightArrow: function() {
                        if (this.option("opened")) {
                            return true
                        }
                    },
                    leftArrow: function() {
                        if (this.option("opened")) {
                            return true
                        }
                    },
                    enter: $.proxy(function(e) {
                        if (this.dateBox.option("opened")) {
                            e.preventDefault();
                            if (this._widget.option("zoomLevel") === this._widget.option("maxZoomLevel")) {
                                var contouredDate = this._widget._view.option("contouredDate");
                                contouredDate && this.dateBoxValue(contouredDate);
                                this.dateBox.close();
                                this.dateBox._valueChangeEventHandler(e)
                            } else {
                                return true
                            }
                        }
                    }, this)
                }
            },
            getDisplayFormat: function(displayFormat) {
                return displayFormat || dateLocalization.getPatternByFormat("shortdate")
            },
            _getWidgetName: function() {
                return Calendar.publicName()
            },
            _getWidgetOptions: function() {
                return $.extend(this.dateBox.option("calendarOptions"), {
                    value: this.dateBoxValue() || null,
                    _keyboardProcessor: this._widgetKeyboardProcessor,
                    min: this.dateBox.dateOption("min"),
                    max: this.dateBox.dateOption("max"),
                    onValueChanged: $.proxy(this._valueChangedHandler, this),
                    onCellClick: $.proxy(this._cellClickHandler, this),
                    tabIndex: null,
                    maxZoomLevel: this.dateBox.option("maxZoomLevel"),
                    minZoomLevel: this.dateBox.option("minZoomLevel"),
                    onContouredChanged: $.proxy(this._refreshActiveDescendant, this),
                    hasFocus: function() {
                        return true
                    }
                })
            },
            _refreshActiveDescendant: function(e) {
                this.dateBox.setAria("activedescendant", e.actionValue)
            },
            popupConfig: function(popupConfig) {
                var toolbarItems = popupConfig.toolbarItems,
                    buttonsLocation = this.dateBox.option("buttonsLocation");
                var position = [];
                if ("default" !== buttonsLocation) {
                    position = commonUtils.splitPair(buttonsLocation)
                } else {
                    position = ["bottom", "center"]
                }
                if ("useButtons" === this.dateBox.option("applyValueMode")) {
                    toolbarItems.unshift({
                        widget: "dxButton",
                        toolbar: position[0],
                        location: "after" === position[1] ? "before" : position[1],
                        options: {
                            onClick: $.proxy(function() {
                                this._widget._toTodayView()
                            }, this),
                            text: messageLocalization.format("dxCalendar-todayButtonText"),
                            type: "today"
                        }
                    })
                }
                return $.extend(true, popupConfig, {
                    toolbarItems: toolbarItems,
                    position: {
                        collision: "flipfit flip"
                    }
                })
            },
            _valueChangedHandler: function(e) {
                var dateBox = this.dateBox,
                    value = e.value,
                    prevValue = e.previousValue;
                if (dateUtils.sameDate(value, prevValue)) {
                    return
                }
                if ("instantly" === dateBox.option("applyValueMode")) {
                    this.dateBoxValue(this.getValue())
                }
            },
            _updateValue: function() {
                if (!this._widget) {
                    return
                }
                this._widget.option("value", this.dateBoxValue())
            },
            textChangedHandler: function() {
                if (this.dateBox.option("opened") && this._widget) {
                    this._updateValue(true)
                }
            },
            _cellClickHandler: function() {
                var dateBox = this.dateBox;
                if ("instantly" === dateBox.option("applyValueMode")) {
                    dateBox.option("opened", false);
                    this.dateBoxValue(this.getValue())
                }
            },
            dispose: function() {
                this.dateBox.off("optionChanged");
                this.callBase()
            }
        });
        module.exports = CalendarStrategy
    },
    /*!*****************************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_box.strategy.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var abstract = Class.abstract;
        var DateBoxStrategy = Class.inherit({
            ctor: function(dateBox) {
                this.dateBox = dateBox
            },
            widgetOption: function() {
                return this._widget && this._widget.option.apply(this._widget, arguments)
            },
            _renderWidget: function(element) {
                element = element || $("<div>");
                this._widget = this._createWidget(element);
                this._widget.element().appendTo(this._getWidgetContainer())
            },
            _createWidget: function(element) {
                var widgetName = this._getWidgetName();
                var widgetOptions = this._getWidgetOptions();
                return this.dateBox._createComponent(element, widgetName, widgetOptions)
            },
            _getWidgetOptions: abstract,
            _getWidgetName: abstract,
            getDefaultOptions: function() {
                return {
                    mode: "text"
                }
            },
            getDisplayFormat: abstract,
            supportedKeys: $.noop,
            attachKeyboardEvents: function(keyboardProcessor) {
                this._widgetKeyboardProcessor = keyboardProcessor.attachChildProcessor()
            },
            getParsedText: function(text, format) {
                return dateLocalization.parse(text, format)
            },
            renderInputMinMax: $.noop,
            renderOpenedState: function() {
                if (this.dateBox.option("opened")) {
                    this._updateValue()
                }
            },
            popupConfig: abstract,
            renderPopupContent: function() {
                var popup = this._getPopup();
                this._renderWidget();
                popup.content().parent().off("mousedown").on("mousedown", $.proxy(this._preventFocusOnPopup, this))
            },
            getFirstPopupElement: $.noop,
            getLastPopupElement: $.noop,
            _preventFocusOnPopup: function(e) {
                e.preventDefault()
            },
            _getWidgetContainer: function() {
                return this._getPopup().content()
            },
            _getPopup: function() {
                return this.dateBox._popup
            },
            popupShowingHandler: $.noop,
            popupHiddenHandler: $.noop,
            _updateValue: function() {
                this._widget && this._widget.option("value", this.dateBoxValue())
            },
            _valueChangedHandler: function(args) {
                if (this.dateBox.option("opened") && "instantly" === this.dateBox.option("applyValueMode")) {
                    this.dateBoxValue(args.value)
                }
            },
            textChangedHandler: $.noop,
            renderValue: function() {
                if (this.dateBox.option("opened")) {
                    this._updateValue()
                }
            },
            getValue: function() {
                return this._widget.option("value")
            },
            isAdaptivityChanged: function() {
                return false
            },
            dispose: function() {
                var popup = this._getPopup();
                if (popup) {
                    popup.content().empty()
                }
            },
            dateBoxValue: function() {
                var args = ["value"];
                arguments.length && args.push(arguments[0]);
                return this.dateBox.dateOption.apply(this.dateBox, args)
            }
        });
        module.exports = DateBoxStrategy
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_box.strategy.date_view.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            DateView = __webpack_require__( /*! ./ui.date_view */ 265),
            DateBoxStrategy = __webpack_require__( /*! ./ui.date_box.strategy */ 263),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            themes = __webpack_require__( /*! ../themes */ 143),
            dateUtils = __webpack_require__( /*! ./ui.date_utils */ 261),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var DateViewStrategy = DateBoxStrategy.inherit({
            NAME: "DateView",
            getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    openOnFieldClick: true,
                    applyButtonText: messageLocalization.format("Done")
                })
            },
            getDisplayFormat: function(displayFormat) {
                return displayFormat || dateUtils.FORMATS_MAP[this.dateBox.option("type")]
            },
            popupConfig: function() {
                return {
                    showTitle: true,
                    toolbarItems: this.dateBox._popupToolbarItemsConfig(),
                    defaultOptionsRules: [{
                        device: function(device) {
                            return "win" === device.platform && device.version && 8 === device.version[0]
                        },
                        options: {
                            showNames: true
                        }
                    }, {
                        device: function(device) {
                            return "win" === device.platform && device.phone && device.version && 8 === device.version[0]
                        },
                        options: {
                            animation: null
                        }
                    }, {
                        device: function() {
                            var currentTheme = (themes.current() || "").split(".")[0];
                            return "win8" === currentTheme
                        },
                        options: {
                            fullScreen: true
                        }
                    }, {
                        device: {
                            platform: "android"
                        },
                        options: {
                            width: 333,
                            height: 331
                        }
                    }, {
                        device: function(device) {
                            var platform = device.platform,
                                version = device.version;
                            return "generic" === platform || "ios" === platform || "win" === platform && version && 10 === version[0]
                        },
                        options: {
                            width: "auto",
                            height: "auto"
                        }
                    }, {
                        device: function(device) {
                            var platform = device.platform,
                                phone = device.phone;
                            return "generic" === platform && phone
                        },
                        options: {
                            width: 333,
                            height: "auto",
                            position: {
                                collision: "flipfit flip"
                            }
                        }
                    }, {
                        device: function(device) {
                            var currentTheme = (themes.current() || "").split(".")[0];
                            return device.phone && "win10" === currentTheme
                        },
                        options: {
                            width: 333,
                            height: "auto"
                        }
                    }, {
                        device: {
                            platform: "ios",
                            phone: true
                        },
                        options: {
                            width: "100%",
                            position: {
                                my: "bottom",
                                at: "bottom",
                                of: window
                            }
                        }
                    }]
                }
            },
            _renderWidget: function() {
                if (support.inputType(this.dateBox.option("mode")) && this.dateBox._isNativeType() || this.dateBox.option("readOnly")) {
                    if (this._widget) {
                        this._widget.element().remove();
                        this._widget = null
                    }
                    return
                }
                var popup = this._getPopup();
                if (this._widget) {
                    this._widget.option(this._getWidgetOptions())
                } else {
                    var element = $("<div>").appendTo(popup.content());
                    this._widget = this._createWidget(element)
                }
                this._widget.element().appendTo(this._getWidgetContainer())
            },
            _getWidgetName: function() {
                return DateView.publicName()
            },
            _getWidgetOptions: function() {
                return {
                    value: this.dateBoxValue() || new Date,
                    type: this.dateBox.option("type"),
                    minDate: this.dateBox.dateOption("min") || new Date(1900, 1, 1),
                    maxDate: this.dateBox.dateOption("max") || new Date($.now() + 50 * dateUtils.ONE_YEAR),
                    onDisposing: $.proxy(function() {
                        this._widget = null
                    }, this)
                }
            },
            _updateValue: function() {
                this._widget && this._widget.option("value", this.dateBoxValue())
            }
        });
        module.exports = DateViewStrategy
    },
    /*!*********************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_view.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            DateViewRoller = __webpack_require__( /*! ./ui.date_view_roller */ 266),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            uiDateUtils = __webpack_require__( /*! ./ui.date_utils */ 261),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var DATEVIEW_CLASS = "dx-dateview",
            DATEVIEW_WRAPPER_CLASS = "dx-dateview-wrapper",
            DATEVIEW_ROLLER_CONTAINER_CLASS = "dx-dateview-rollers",
            DATEVIEW_ROLLER_CLASS = "dx-dateviewroller";
        var TYPE = {
            date: "date",
            datetime: "datetime",
            time: "time"
        };
        var ROLLER_TYPE = {
            year: "year",
            month: "month",
            day: "day"
        };
        var DateView = Editor.inherit({
            _valueOption: function() {
                var value = this.option("value"),
                    date = new Date(value);
                return !value || isNaN(date) ? this._getDefaultDate() : date
            },
            _getDefaultDate: function() {
                var date = new Date;
                if (this.option("type") === TYPE.date) {
                    return new Date(date.getFullYear(), date.getMonth(), date.getDate())
                }
                return date
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    minDate: uiDateUtils.MIN_DATEVIEW_DEFAULT_DATE,
                    maxDate: uiDateUtils.MAX_DATEVIEW_DEFAULT_DATE,
                    type: TYPE.date,
                    value: new Date,
                    showNames: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "win" === device.platform && device.version && 8 === device.version[0]
                    },
                    options: {
                        showNames: true
                    }
                }])
            },
            _render: function() {
                this.callBase();
                this.element().addClass(DATEVIEW_CLASS);
                this._toggleFormatClasses(this.option("type"))
            },
            _toggleFormatClasses: function(currentFormat, previousFormat) {
                this.element().addClass(DATEVIEW_CLASS + "-" + currentFormat);
                previousFormat && this.element().removeClass(DATEVIEW_CLASS + "-" + previousFormat)
            },
            _wrapper: function() {
                return this._$wrapper
            },
            _renderContentImpl: function() {
                this._$wrapper = $("<div>").addClass(DATEVIEW_WRAPPER_CLASS);
                this._renderRollers();
                this._$wrapper.appendTo(this.element())
            },
            _renderRollers: function() {
                if (!this._$rollersContainer) {
                    this._$rollersContainer = $("<div>").addClass(DATEVIEW_ROLLER_CONTAINER_CLASS)
                }
                this._$rollersContainer.empty();
                this._createRollerConfigs();
                this._rollers = {};
                var that = this;
                $.each(that._rollerConfigs, function(name) {
                    var $roller = $("<div>").appendTo(that._$rollersContainer).addClass(DATEVIEW_ROLLER_CLASS + "-" + that._rollerConfigs[name].type);
                    that._rollers[that._rollerConfigs[name].type] = that._createComponent($roller, DateViewRoller, {
                        items: that._rollerConfigs[name].displayItems,
                        selectedIndex: that._rollerConfigs[name].selectedIndex,
                        showScrollbar: false,
                        onStart: function(e) {
                            var roller = e.component;
                            roller._toggleActive(true);
                            that._setActiveRoller(that._rollerConfigs[name], roller.option("selectedIndex"))
                        },
                        onEnd: function(e) {
                            var roller = e.component;
                            roller._toggleActive(false)
                        },
                        onClick: function(e) {
                            var roller = e.component;
                            roller._toggleActive(true);
                            that._setActiveRoller(that._rollerConfigs[name], roller.option("selectedIndex"));
                            that._setRollerState(that._rollerConfigs[name], roller.option("selectedIndex"));
                            roller._toggleActive(false)
                        },
                        onSelectedIndexChanged: function(e) {
                            var roller = e.component;
                            that._setRollerState(that._rollerConfigs[name], roller.option("selectedIndex"))
                        }
                    })
                });
                that._$rollersContainer.appendTo(that._wrapper())
            },
            _createRollerConfigs: function(type) {
                var that = this;
                type = type || that.option("type");
                that._rollerConfigs = {};
                $.each(that._getFormatPattern(uiDateUtils.FORMATS_MAP[type]).split(/\W+/), function(_, formatPart) {
                    $.each(uiDateUtils.DATE_COMPONENTS_INFO, function(componentName, componentInfo) {
                        if ($.inArray(formatPart, componentInfo.possibleFormats) > -1) {
                            that._createRollerConfig(componentName)
                        }
                    })
                })
            },
            _createRollerConfig: function(componentName) {
                var componentInfo = uiDateUtils.DATE_COMPONENTS_INFO[componentName],
                    valueRange = this._calculateRollerConfigValueRange(componentName),
                    startValue = valueRange.startValue,
                    endValue = valueRange.endValue,
                    formatter = componentInfo.formatter,
                    showNames = this.option("showNames"),
                    curDate = this._getCurrentDate();
                var config = {
                    type: componentName,
                    setValue: componentInfo.setter,
                    valueItems: [],
                    displayItems: [],
                    getIndex: function(value) {
                        return value[componentInfo.getter]() - startValue
                    }
                };
                for (var i = startValue; i <= endValue; i++) {
                    config.valueItems.push(i);
                    config.displayItems.push(formatter(i, showNames, curDate))
                }
                config.selectedIndex = config.getIndex(curDate);
                this._rollerConfigs[componentName] = config
            },
            _setActiveRoller: function(currentRoller) {
                var activeRoller = currentRoller && this._rollers[currentRoller.type];
                $.each(this._rollers, function() {
                    this.toggleActiveState(this === activeRoller)
                })
            },
            _updateRollersPosition: function() {
                var that = this;
                $.each(this._rollers, function(type) {
                    var correctIndex = that._rollerConfigs[type].getIndex(that._getCurrentDate());
                    this.option("selectedIndex", correctIndex)
                })
            },
            _setRollerState: function(roller, selectedIndex) {
                if (selectedIndex !== roller.selectedIndex) {
                    var rollerValue = roller.valueItems[selectedIndex],
                        setValue = roller.setValue,
                        currentValue = new Date(this._getCurrentDate()),
                        currentDate = currentValue.getDate();
                    if (roller.type === ROLLER_TYPE.month) {
                        currentDate = Math.min(currentDate, uiDateUtils.getMaxMonthDay(currentValue.getFullYear(), rollerValue))
                    } else {
                        if (roller.type === ROLLER_TYPE.year) {
                            currentDate = Math.min(currentDate, uiDateUtils.getMaxMonthDay(rollerValue, currentValue.getMonth()))
                        }
                    }
                    currentValue.setDate(currentDate);
                    currentValue[setValue](rollerValue);
                    this.option("value", currentValue);
                    roller.selectedIndex = selectedIndex
                }
                if (roller.type === ROLLER_TYPE.year) {
                    this._refreshMonthRoller();
                    this._refreshDayRoller()
                }
                if (roller.type === ROLLER_TYPE.month) {
                    this._refreshDayRoller()
                }
            },
            _refreshMonthRoller: function() {
                var monthRoller = this._rollers[ROLLER_TYPE.month];
                if (monthRoller) {
                    this._createRollerConfig(ROLLER_TYPE.month);
                    var monthRollerConfig = this._rollerConfigs[ROLLER_TYPE.month];
                    if (monthRollerConfig.displayItems.length !== monthRoller.option("items").length) {
                        monthRoller.option({
                            items: monthRollerConfig.displayItems,
                            selectedIndex: monthRollerConfig.selectedIndex
                        })
                    }
                }
            },
            _refreshDayRoller: function() {
                var dayRoller = this._rollers[ROLLER_TYPE.day];
                if (dayRoller) {
                    this._createRollerConfig(ROLLER_TYPE.day);
                    var dayRollerConfig = this._rollerConfigs[ROLLER_TYPE.day];
                    dayRoller.option({
                        items: dayRollerConfig.displayItems,
                        selectedIndex: dayRollerConfig.selectedIndex
                    })
                }
            },
            _getFormatPattern: function(type) {
                return dateLocalization.getPatternByFormat(type)
            },
            _getCurrentDate: function() {
                var curDate = this._valueOption(),
                    minDate = this.option("minDate"),
                    maxDate = this.option("maxDate");
                if (minDate && curDate.getTime() <= minDate.getTime()) {
                    curDate = minDate
                } else {
                    if (maxDate && curDate.getTime() >= maxDate.getTime()) {
                        curDate = maxDate
                    }
                }
                return curDate
            },
            _calculateRollerConfigValueRange: function(componentName) {
                var curDate = this._getCurrentDate(),
                    minDate = this.option("minDate"),
                    maxDate = this.option("maxDate"),
                    minYear = dateUtils.sameYear(curDate, minDate),
                    minMonth = minYear && curDate.getMonth() === minDate.getMonth(),
                    maxYear = dateUtils.sameYear(curDate, maxDate),
                    maxMonth = maxYear && curDate.getMonth() === maxDate.getMonth(),
                    componentInfo = uiDateUtils.DATE_COMPONENTS_INFO[componentName],
                    startValue = componentInfo.startValue,
                    endValue = componentInfo.endValue;
                if (componentName === ROLLER_TYPE.year) {
                    startValue = minDate.getFullYear();
                    endValue = maxDate.getFullYear()
                }
                if (componentName === ROLLER_TYPE.month) {
                    if (minYear) {
                        startValue = minDate.getMonth()
                    }
                    if (maxYear) {
                        endValue = maxDate.getMonth()
                    }
                }
                if (componentName === ROLLER_TYPE.day) {
                    endValue = uiDateUtils.getMaxMonthDay(curDate.getFullYear(), curDate.getMonth());
                    if (minYear && minMonth) {
                        startValue = minDate.getDate()
                    }
                    if (maxYear && maxMonth) {
                        endValue = maxDate.getDate()
                    }
                }
                return {
                    startValue: startValue,
                    endValue: endValue
                }
            },
            _refreshRollers: function() {
                this._refreshMonthRoller();
                this._refreshDayRoller()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "showNames":
                    case "minDate":
                    case "maxDate":
                    case "type":
                        this._renderRollers();
                        this._toggleFormatClasses(args.value, args.previousValue);
                        break;
                    case "visible":
                        this.callBase(args);
                        if (args.value) {
                            this._renderRollers()
                        }
                        break;
                    case "value":
                        this.option("value", this._valueOption());
                        this._refreshRollers();
                        this._updateRollersPosition();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _clean: function() {
                this.callBase();
                delete this._$rollersContainer
            },
            _dispose: function() {
                clearTimeout(this._deferredRenderDayTimeout);
                clearTimeout(this._deferredRenderMonthTimeout);
                this.callBase()
            }
        });
        registerComponent("dxDateView", DateView);
        module.exports = DateView
    },
    /*!****************************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_view_roller.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            Scrollable = __webpack_require__( /*! ../scroll_view/ui.scrollable */ 237).default,
            fx = __webpack_require__( /*! ../../animation/fx */ 59);
        var DATEVIEW_ROLLER_CLASS = "dx-dateviewroller",
            DATEVIEW_ROLLER_ACTIVE_CLASS = "dx-state-active",
            DATEVIEW_ROLLER_CURRENT_CLASS = "dx-dateviewroller-current",
            DATEVIEW_ROLLER_ITEM_CLASS = "dx-dateview-item",
            DATEVIEW_ROLLER_ITEM_SELECTED_CLASS = "dx-dateview-item-selected",
            DATEVIEW_ROLLER_ITEM_SELECTED_FRAME_CLASS = "dx-dateview-item-selected-frame",
            DATEVIEW_ROLLER_ITEM_SELECTED_BORDER_CLASS = "dx-dateview-item-selected-border";
        var DateViewRoller = Scrollable.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    showScrollbar: false,
                    useNative: false,
                    selectedIndex: 0,
                    bounceEnabled: false,
                    items: [],
                    showOnClick: false,
                    onClick: null,
                    onSelectedIndexChanged: null
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "win" === device.platform && device.version && 8 === device.version[0]
                    },
                    options: {
                        showOnClick: true
                    }
                }, {
                    device: {
                        platform: "generic"
                    },
                    options: {
                        scrollByContent: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this._renderSelectedItemFrame()
            },
            _render: function() {
                this.callBase();
                $.each(this._strategy._scrollers, function(index, scroller) {
                    scroller._correctLocation = $.noop
                });
                this.element().addClass(DATEVIEW_ROLLER_CLASS);
                this._renderContainerClick();
                this._renderItems();
                this._renderSelectedValue();
                this._renderItemsClick();
                this._wrapAction("_endAction", $.proxy(this._endActionHandler, this));
                this._renderSelectedIndexChanged()
            },
            _renderSelectedIndexChanged: function() {
                this._selectedIndexChanged = this._createActionByOption("onSelectedIndexChanged")
            },
            _renderContainerClick: function() {
                if (!this.option("showOnClick")) {
                    return
                }
                var eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                var clickAction = this._createActionByOption("onClick");
                this._$container.off(eventName).on(eventName, function(e) {
                    clickAction({
                        jQueryEvent: e
                    })
                })
            },
            _wrapAction: function(actionName, callback) {
                var strategy = this._strategy,
                    originalAction = strategy[actionName];
                strategy[actionName] = function() {
                    callback.apply(this, arguments);
                    return originalAction.apply(this, arguments)
                }
            },
            _renderItems: function() {
                var items = this.option("items") || [],
                    $items = $();
                this._$content.empty();
                $.each(items, function() {
                    $items = $items.add($("<div>").addClass(DATEVIEW_ROLLER_ITEM_CLASS).append(this))
                });
                this._$content.append($items);
                this._$items = $items;
                this.update()
            },
            _renderSelectedItemFrame: function() {
                $("<div>").addClass(DATEVIEW_ROLLER_ITEM_SELECTED_FRAME_CLASS).append($("<div>").addClass(DATEVIEW_ROLLER_ITEM_SELECTED_BORDER_CLASS)).appendTo(this._$container)
            },
            _renderSelectedValue: function(selectedIndex) {
                var index = this._fitIndex(selectedIndex || this.option("selectedIndex"));
                this._moveTo({
                    top: this._getItemPosition(index)
                });
                this._renderActiveStateItem()
            },
            _fitIndex: function(index) {
                var items = this.option("items") || [],
                    itemCount = items.length;
                if (index >= itemCount) {
                    return itemCount - 1
                }
                if (index < 0) {
                    return 0
                }
                return index
            },
            _getItemPosition: function(index) {
                return Math.round(this._itemHeight() * index)
            },
            _renderItemsClick: function() {
                var itemSelector = this._getItemSelector(),
                    eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                this.element().off(eventName, itemSelector);
                this.element().on(eventName, itemSelector, $.proxy(this._itemClickHandler, this))
            },
            _getItemSelector: function() {
                return "." + DATEVIEW_ROLLER_ITEM_CLASS
            },
            _itemClickHandler: function(e) {
                this.option("selectedIndex", this._itemElementIndex(e.currentTarget))
            },
            _itemElementIndex: function(itemElement) {
                return this._itemElements().index(itemElement)
            },
            _itemElements: function() {
                return this.element().find(this._getItemSelector())
            },
            _renderActiveStateItem: function() {
                var selectedIndex = this.option("selectedIndex");
                $.each(this._$items, function(index) {
                    $(this).toggleClass(DATEVIEW_ROLLER_ITEM_SELECTED_CLASS, selectedIndex === index)
                })
            },
            _moveTo: function(targetLocation) {
                targetLocation = this._normalizeLocation(targetLocation);
                var location = this._location(),
                    delta = {
                        x: -(location.left - targetLocation.left),
                        y: -(location.top - targetLocation.top)
                    };
                if (this._isVisible() && (delta.x || delta.y)) {
                    this._strategy._prepareDirections(true);
                    if (this._animation) {
                        fx.stop(this._$content);
                        fx.animate(this._$content, {
                            duration: 200,
                            type: "slide",
                            to: {
                                top: targetLocation.top
                            }
                        });
                        delete this._animation
                    } else {
                        this._strategy.handleMove({
                            delta: delta
                        })
                    }
                }
            },
            _validate: function(e) {
                return this._strategy.validate(e)
            },
            _endActionHandler: function() {
                var currentSelectedIndex = this.option("selectedIndex"),
                    ratio = -this._location().top / this._itemHeight(),
                    newSelectedIndex = Math.round(ratio);
                this._animation = true;
                if (newSelectedIndex === currentSelectedIndex) {
                    this._renderSelectedValue(newSelectedIndex)
                } else {
                    this.option("selectedIndex", newSelectedIndex)
                }
            },
            _itemHeight: function() {
                var $item = this._$items.first();
                return $item.get(0) && $item.get(0).getBoundingClientRect().height || 0
            },
            _toggleActive: function(state) {
                this.element().toggleClass(DATEVIEW_ROLLER_ACTIVE_CLASS, state)
            },
            _isVisible: function() {
                return this._$container.is(":visible")
            },
            _fireSelectedIndexChanged: function(value, previousValue) {
                this._selectedIndexChanged({
                    value: value,
                    previousValue: previousValue,
                    jQueryEvent: void 0
                })
            },
            _visibilityChanged: function(visible) {
                this.callBase(visible);
                if (visible) {
                    this._renderSelectedValue(this.option("selectedIndex"))
                } else {
                    this.toggleActiveState(false)
                }
            },
            toggleActiveState: function(state) {
                this.element().toggleClass(DATEVIEW_ROLLER_CURRENT_CLASS, state)
            },
            _refreshSelectedIndex: function() {
                var selectedIndex = this.option("selectedIndex");
                var fitIndex = this._fitIndex(selectedIndex);
                fitIndex === selectedIndex ? this._renderActiveStateItem() : this.option("selectedIndex", fitIndex)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "selectedIndex":
                        this._fireSelectedIndexChanged(args.value, args.previousValue);
                        this._renderSelectedValue(args.value);
                        break;
                    case "items":
                        this._renderItems();
                        this._refreshSelectedIndex();
                        break;
                    case "onClick":
                    case "showOnClick":
                        this._renderContainerClick();
                        break;
                    case "onSelectedIndexChanged":
                        this._renderSelectedIndexChanged();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxDateViewRoller", DateViewRoller);
        module.exports = DateViewRoller
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_box.strategy.native.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            DateBoxStrategy = __webpack_require__( /*! ./ui.date_box.strategy */ 263),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            dateUtils = __webpack_require__( /*! ./ui.date_utils */ 261),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var NativeStrategy = DateBoxStrategy.inherit({
            NAME: "Native",
            popupConfig: $.noop,
            getParsedText: function(text) {
                return dateUtils.fromStandardDateFormat(text)
            },
            renderPopupContent: $.noop,
            _getWidgetName: $.noop,
            _getWidgetOptions: $.noop,
            _getDateBoxType: function() {
                var type = this.dateBox.option("type");
                if ($.inArray(type, dateUtils.SUPPORTED_FORMATS) === -1) {
                    type = "date"
                } else {
                    if ("datetime" === type && !support.inputType(type)) {
                        type = "datetime-local"
                    }
                }
                return type
            },
            getDefaultOptions: function() {
                return {
                    mode: this._getDateBoxType()
                }
            },
            getDisplayFormat: function(displayFormat) {
                var type = this._getDateBoxType();
                return displayFormat || dateLocalization.getPatternByFormat(dateUtils.FORMATS_MAP[type])
            },
            renderInputMinMax: function($input) {
                $input.attr({
                    min: dateLocalization.format(this.dateBox.dateOption("min"), "yyyy-MM-dd"),
                    max: dateLocalization.format(this.dateBox.dateOption("max"), "yyyy-MM-dd")
                })
            }
        });
        module.exports = NativeStrategy
    },
    /*!************************************************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_box.strategy.calendar_with_time.js ***!
      \************************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            CalendarStrategy = __webpack_require__( /*! ./ui.date_box.strategy.calendar */ 262),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            TimeView = __webpack_require__( /*! ./ui.time_view */ 269),
            Box = __webpack_require__( /*! ../box */ 245);
        var SHRINK_VIEW_SCREEN_WIDTH = 573,
            DATEBOX_ADAPTIVITY_MODE_CLASS = "dx-datebox-adaptivity-mode";
        var CalendarWithTimeStrategy = CalendarStrategy.inherit({
            NAME: "CalendarWithTime",
            getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    applyValueMode: "useButtons",
                    buttonsLocation: "bottom after",
                    showPopupTitle: false
                })
            },
            getDisplayFormat: function(displayFormat) {
                return displayFormat || dateLocalization.getPatternByFormat("shortdateshorttime")
            },
            _renderWidget: function() {
                this.callBase();
                this._timeView = this.dateBox._createComponent($("<div>"), TimeView, {
                    value: this.dateBoxValue(),
                    _showClock: !this._isShrinkView(),
                    onValueChanged: $.proxy(this._valueChangedHandler, this)
                })
            },
            renderOpenedState: function() {
                this.callBase();
                var popup = this._getPopup();
                if (popup) {
                    popup._wrapper().toggleClass(DATEBOX_ADAPTIVITY_MODE_CLASS, this._isSmallScreen())
                }
                clearTimeout(this._repaintTimer);
                this._repaintTimer = setTimeout($.proxy(function() {
                    this._getPopup() && this._getPopup().repaint()
                }, this), 0)
            },
            isAdaptivityChanged: function() {
                var isAdaptiveMode = this._isShrinkView();
                if (isAdaptiveMode !== this._currentAdaptiveMode) {
                    this._currentAdaptiveMode = isAdaptiveMode;
                    return true
                }
                return this.callBase()
            },
            _updateValue: function(preventDefaultValue) {
                var date = this.dateBoxValue();
                if (!date && !preventDefaultValue) {
                    date = new Date
                }
                this.callBase();
                if (this._timeView && date) {
                    this._timeView.option("value", date)
                }
            },
            _isSmallScreen: function() {
                return $(window).width() <= SHRINK_VIEW_SCREEN_WIDTH
            },
            _isShrinkView: function() {
                return this.dateBox.option("adaptivityEnabled") && this._isSmallScreen()
            },
            _getBoxItems: function() {
                var items = [{
                    ratio: 0,
                    shrink: 0,
                    baseSize: "auto",
                    name: "calendar"
                }];
                if (!this._isShrinkView()) {
                    items.push({
                        ratio: 0,
                        shrink: 0,
                        baseSize: "auto",
                        name: "time"
                    })
                }
                return items
            },
            renderPopupContent: function() {
                this.callBase();
                this._currentAdaptiveMode = this._isShrinkView();
                var $popupContent = this._getPopup().content();
                var box = this.dateBox._createComponent($("<div>").appendTo($popupContent), Box, {
                    direction: "row",
                    crossAlign: "start",
                    items: this._getBoxItems(),
                    itemTemplate: $.proxy(function(data) {
                        var $container = $("<div>");
                        switch (data.name) {
                            case "calendar":
                                $container.append(this._widget.element());
                                if (this._isShrinkView()) {
                                    $container.append(this._timeView.element())
                                }
                                break;
                            case "time":
                                $container.append(this._timeView.element())
                        }
                        return $container
                    }, this)
                });
                clearTimeout(this._removeMinWidthTimer);
                this._removeMinWidthTimer = setTimeout(function() {
                    if ("fallback" === box.option("_layoutStrategy")) {
                        $popupContent.find(".dx-timeview-clock").css("minWidth", 0)
                    }
                }, 0);
                this._attachTabHandler()
            },
            getFirstPopupElement: function() {
                return this._timeView._hourBox.element().find("input")
            },
            _attachTabHandler: function() {
                var dateBox = this.dateBox,
                    handler = function(e) {
                        if (e.shiftKey) {
                            e.preventDefault();
                            dateBox.focus()
                        }
                    };
                this._timeView._hourBox.registerKeyHandler("tab", handler)
            },
            _preventFocusOnPopup: function(e) {
                if (!$(e.target).hasClass("dx-texteditor-input")) {
                    this.callBase.apply(this, arguments);
                    if (!this.dateBox._hasFocusClass()) {
                        this.dateBox.focus()
                    }
                }
            },
            getValue: function() {
                var date = this._widget.option("value"),
                    time = this._timeView.option("value");
                date = date ? new Date(date) : new Date;
                date.setHours(time.getHours(), time.getMinutes(), time.getSeconds());
                return date
            },
            dispose: function() {
                clearTimeout(this._removeMinWidthTimer);
                clearTimeout(this._repaintTimer);
                this.callBase()
            }
        });
        module.exports = CalendarWithTimeStrategy
    },
    /*!*********************************************!*\
      !*** ./Scripts/ui/date_box/ui.time_view.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            NumberBox = __webpack_require__( /*! ../number_box */ 255),
            Box = __webpack_require__( /*! ../box */ 245),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var TIMEVIEW_CLASS = "dx-timeview",
            TIMEVIEW_CLOCK_CLASS = "dx-timeview-clock",
            TIMEVIEW_FIELD_CLASS = "dx-timeview-field",
            TIMEVIEW_HOURARROW_CLASS = "dx-timeview-hourarrow",
            TIMEVIEW_TIME_SEPARATOR_CLASS = "dx-timeview-time-separator",
            TIMEVIEW_MINUTEARROW_CLASS = "dx-timeview-minutearrow";
        var rotateArrow = function($arrow, angle, offset) {
            if (!support.transform) {
                filterRotate($arrow, angle, offset)
            } else {
                cssRotate($arrow, angle, offset)
            }
        };
        var filterRotate = function($arrow, angle, offset) {
            angle = angle / 180 * Math.PI;
            var sin = Math.sin(angle),
                cos = Math.cos(angle);
            $arrow.css("filter", "none");
            var originalWidth = $arrow.width(),
                originalHeight = $arrow.height();
            $arrow.css("filter", 'progid:DXImageTransform.Microsoft.Matrix(sizingMethod="auto expand", M11 = ' + cos + ", M12 = " + -sin + ", M21 = " + sin + ", M22 = " + cos + ")");
            var width = $arrow.width(),
                height = $arrow.height();
            var sx = (width - originalWidth) / 2,
                sy = (height - originalHeight) / 2;
            $arrow.css("margin-left", -originalWidth / 2 + (originalHeight / 2 - offset) * sin - sx);
            $arrow.css("margin-top", originalHeight / 2 - (originalHeight / 2 - offset) * cos - sy)
        };
        var cssRotate = function($arrow, angle, offset) {
            $arrow.css("transform", "rotate(" + angle + "deg) translate(0," + offset + "px)")
        };
        var TimeView = Editor.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: new Date($.now()),
                    _showClock: true,
                    _arrowOffset: 0
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "android"
                    },
                    options: {
                        _arrowOffset: 15
                    }
                }, {
                    device: {
                        platform: "generic"
                    },
                    options: {
                        _arrowOffset: 5
                    }
                }])
            },
            _getValue: function() {
                return this.option("value") || new Date
            },
            _init: function() {
                this.callBase();
                this.element().addClass(TIMEVIEW_CLASS)
            },
            _render: function() {
                this.callBase();
                this._renderBox();
                this._updateTime()
            },
            _renderBox: function() {
                var $box = $("<div>").appendTo(this.element()),
                    items = [];
                if (this.option("_showClock")) {
                    items.push({
                        ratio: 1,
                        shrink: 0,
                        baseSize: "auto",
                        template: $.proxy(this._renderClock, this)
                    })
                }
                items.push({
                    ratio: 0,
                    shrink: 0,
                    baseSize: 50,
                    template: $.proxy(this._renderField, this)
                });
                this._createComponent($box, Box, {
                    height: "100%",
                    width: "100%",
                    direction: "col",
                    items: items
                })
            },
            _renderClock: function(_, __, $container) {
                this._$hourArrow = $("<div>").addClass(TIMEVIEW_HOURARROW_CLASS);
                this._$minuteArrow = $("<div>").addClass(TIMEVIEW_MINUTEARROW_CLASS);
                $container.addClass(TIMEVIEW_CLOCK_CLASS).append(this._$hourArrow).append(this._$minuteArrow);
                this.setAria("role", "presentation", $container)
            },
            _updateClock: function() {
                var time = this._getValue(),
                    hourArrowAngle = time.getHours() / 12 * 360 + time.getMinutes() / 60 * 30,
                    minuteArrowAngle = time.getMinutes() / 60 * 360;
                rotateArrow(this._$hourArrow, hourArrowAngle, this.option("_arrowOffset"));
                rotateArrow(this._$minuteArrow, minuteArrowAngle, this.option("_arrowOffset"))
            },
            _renderField: function() {
                this._createHourBox();
                this._createMinuteBox();
                return this._createComponent($("<div>").addClass(TIMEVIEW_FIELD_CLASS), Box, {
                    direction: "row",
                    align: "center",
                    crossAlign: "center",
                    items: [{
                        ratio: 0,
                        shrink: 0,
                        baseSize: "auto",
                        template: $.proxy(function() {
                            return this._hourBox.element()
                        }, this)
                    }, {
                        ratio: 0,
                        shrink: 0,
                        baseSize: "auto",
                        template: $("<div>", {
                            "class": TIMEVIEW_TIME_SEPARATOR_CLASS
                        }).text(dateLocalization.getTimeSeparator())
                    }, {
                        ratio: 0,
                        shrink: 0,
                        baseSize: "auto",
                        template: $.proxy(function() {
                            return this._minuteBox.element()
                        }, this)
                    }]
                }).element()
            },
            _createHourBox: function() {
                this._hourBox = this._createComponent($("<div>"), NumberBox, $.extend({
                    min: -1,
                    max: 24,
                    value: this._getValue().getHours(),
                    onValueChanged: $.proxy(function(args) {
                        var newHours = (24 + args.value) % 24;
                        this._hourBox.option("value", newHours);
                        var time = new Date(this._getValue());
                        time.setHours(newHours);
                        this.option("value", time)
                    }, this)
                }, this._getNumberBoxConfig()));
                this._hourBox.setAria("label", "hours")
            },
            _createMinuteBox: function() {
                this._minuteBox = this._createComponent($("<div>"), NumberBox, $.extend({
                    min: -1,
                    max: 60,
                    value: this._getValue().getMinutes(),
                    onValueChanged: $.proxy(function(args) {
                        var newMinutes = (60 + args.value) % 60;
                        this._minuteBox.option("value", newMinutes);
                        var time = new Date(this._getValue());
                        time.setMinutes(newMinutes);
                        this.option("value", time)
                    }, this)
                }, this._getNumberBoxConfig()));
                this._minuteBox.setAria("label", "minutes")
            },
            _getNumberBoxConfig: function() {
                return {
                    showSpinButtons: true,
                    disabled: this.option("disabled"),
                    valueFormat: function(value) {
                        return (value < 10 ? "0" : "") + value
                    }
                }
            },
            _updateField: function() {
                this._hourBox && this._hourBox.option("value", this._getValue().getHours());
                this._minuteBox && this._minuteBox.option("value", this._getValue().getMinutes())
            },
            _updateTime: function() {
                if (this.option("_showClock")) {
                    this._updateClock()
                }
                this._updateField()
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._updateTime()
                }
            },
            _toggleDisabledState: function(value) {
                this._hourBox && this._hourBox.option("disabled", value);
                this._minuteBox && this._minuteBox.option("disabled", value)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "value":
                        this._updateTime();
                        this.callBase(args);
                        break;
                    case "_arrowOffset":
                        break;
                    case "_showClock":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxTimeView", TimeView);
        module.exports = TimeView
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/date_box/ui.date_box.strategy.list.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            List = __webpack_require__( /*! ../list */ 213),
            DateBoxStrategy = __webpack_require__( /*! ./ui.date_box.strategy */ 263),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            dateUtils = __webpack_require__( /*! ./ui.date_utils */ 261),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var BOUNDARY_VALUES = {
            min: new Date(0, 0, 0, 0, 0),
            max: new Date(0, 0, 0, 23, 59)
        };
        var ListStrategy = DateBoxStrategy.inherit({
            NAME: "List",
            supportedKeys: function() {
                return {
                    tab: function(e) {
                        if (this.option("opened")) {
                            this.close()
                        }
                    },
                    space: $.noop,
                    home: $.noop,
                    end: $.noop
                }
            },
            getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    applyValueMode: "instantly"
                })
            },
            getDisplayFormat: function(displayFormat) {
                return displayFormat || dateLocalization.getPatternByFormat("shorttime")
            },
            popupConfig: function(popupConfig) {
                var device = devices.current(),
                    result = $.extend(popupConfig, {
                        width: this._getPopupWidth()
                    });
                if ("android" === device.platform) {
                    $.extend(result, {
                        position: {
                            offset: {
                                h: -16,
                                v: -10
                            }
                        }
                    })
                }
                return result
            },
            _getPopupWidth: function() {
                var device = devices.current(),
                    result = this.dateBox.element().outerWidth();
                if ("android" === device.platform) {
                    result += 32
                }
                return result
            },
            popupShowingHandler: function() {
                this._dimensionChanged()
            },
            _renderWidget: function() {
                this.callBase();
                this._refreshItems()
            },
            _getWidgetName: function() {
                return List
            },
            _getWidgetOptions: function() {
                var keyboardProcessor = this.dateBox._keyboardProcessor;
                return {
                    _keyboardProcessor: keyboardProcessor ? keyboardProcessor.attachChildProcessor() : null,
                    itemTemplate: $.proxy(this._timeListItemTemplate, this),
                    onItemClick: $.proxy(this._listItemClickHandler, this),
                    tabIndex: -1,
                    onFocusedItemChanged: $.proxy(this._refreshActiveDescendant, this),
                    selectionMode: "single"
                }
            },
            _refreshActiveDescendant: function(e) {
                this.dateBox.setAria("activedescendant", "");
                this.dateBox.setAria("activedescendant", e.actionValue)
            },
            _refreshItems: function() {
                this._widgetItems = this._getTimeListItems();
                this._widget.option("items", this._widgetItems)
            },
            renderOpenedState: function() {
                this.callBase();
                this._widget && this._widget.option("focusedElement", null)
            },
            _updateValue: function() {
                if (!this._widget) {
                    return
                }
                this._refreshItems();
                var value = this.dateBoxValue();
                var dateIndex = this._getDateIndex(value);
                if (dateIndex === -1) {
                    this._widget.option("selectedItems", [])
                } else {
                    this._widget.option("selectedIndex", dateIndex)
                }
                this._scrollToSelectedItem()
            },
            _scrollToSelectedItem: function() {
                this._widget.scrollToItem(this._widget.option("selectedIndex"))
            },
            _getDateIndex: function(date) {
                var result = -1;
                for (var i = 0, n = this._widgetItems.length; i < n; i++) {
                    if (this._areDatesEqual(date, this._widgetItems[i])) {
                        result = i;
                        break
                    }
                }
                return result
            },
            _areDatesEqual: function(first, second) {
                return commonUtils.isDate(first) && commonUtils.isDate(second) && first.getHours() === second.getHours() && first.getMinutes() === second.getMinutes()
            },
            _getTimeListItems: function() {
                var min = this.dateBox.dateOption("min") || this._getBoundaryDate("min"),
                    max = this.dateBox.dateOption("max") || this._getBoundaryDate("max"),
                    value = this.dateBox.dateOption("value"),
                    delta = max - min,
                    minutes = min.getMinutes() % this.dateBox.option("interval");
                if (delta < 0) {
                    return []
                }
                if (delta > dateUtils.ONE_DAY) {
                    delta = dateUtils.ONE_DAY
                }
                if (value - min < dateUtils.ONE_DAY) {
                    return this._getRangeItems(min, new Date(min), delta)
                }
                min = this._getBoundaryDate("min");
                min.setMinutes(minutes);
                if (value && Math.abs(value - max) < dateUtils.ONE_DAY) {
                    delta = (60 * max.getHours() + Math.abs(max.getMinutes() - minutes)) * dateUtils.ONE_MINUTE
                }
                return this._getRangeItems(min, new Date(min), delta)
            },
            _getRangeItems: function(startValue, currentValue, rangeDuration) {
                var rangeItems = [];
                var interval = this.dateBox.option("interval");
                while (currentValue - startValue < rangeDuration) {
                    rangeItems.push(new Date(currentValue));
                    currentValue.setMinutes(currentValue.getMinutes() + interval)
                }
                return rangeItems
            },
            _getBoundaryDate: function(boundary) {
                var boundaryValue = BOUNDARY_VALUES[boundary],
                    currentValue = this.dateBox.dateOption("value") || new Date;
                return new Date(currentValue.getFullYear(), currentValue.getMonth(), currentValue.getDate(), boundaryValue.getHours(), boundaryValue.getMinutes())
            },
            _timeListItemTemplate: function(itemData) {
                var displayFormat = this.dateBox.option("displayFormat");
                return dateLocalization.format(itemData, this.getDisplayFormat(displayFormat))
            },
            _listItemClickHandler: function(e) {
                this.dateBox.option("opened", false);
                var date = this.dateBox.option("value");
                date = date ? new Date(date) : new Date;
                date.setHours(e.itemData.getHours());
                date.setMinutes(e.itemData.getMinutes());
                date.setSeconds(e.itemData.getSeconds());
                this.dateBoxValue(date)
            },
            attachKeyboardEvents: function(keyboardProcessor) {
                var child = keyboardProcessor.attachChildProcessor();
                if (this._widget) {
                    this._widget.option("_keyboardProcessor", child)
                }
            },
            _dimensionChanged: function() {
                this._getPopup() && this._updatePopupDimensions()
            },
            _updatePopupDimensions: function() {
                this._updatePopupWidth();
                this._updatePopupHeight()
            },
            _updatePopupWidth: function() {
                this.dateBox._setPopupOption("width", this._getPopupWidth())
            },
            _updatePopupHeight: function() {
                this.dateBox._setPopupOption("height", "auto");
                var popupHeight = this._widget.element().outerHeight();
                var maxHeight = .45 * $(window).height();
                this.dateBox._setPopupOption("height", Math.min(popupHeight, maxHeight));
                this.dateBox._timeList && this.dateBox._timeList.updateDimensions()
            }
        });
        module.exports = ListStrategy
    },
    /*!***************************************!*\
      !*** ./Scripts/ui/defer_rendering.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            TransitionExecutorModule = __webpack_require__( /*! ../animation/transition_executor/transition_executor */ 63),
            Widget = __webpack_require__( /*! ./widget/ui.widget */ 89),
            LoadIndicator = __webpack_require__( /*! ./load_indicator */ 231);
        var WIDGET_CLASS = "dx-widget",
            DEFER_RENDERING_CLASS = "dx-deferrendering",
            PENDING_RENDERING_CLASS = "dx-pending-rendering",
            PENDING_RENDERING_MANUAL_CLASS = "dx-pending-rendering-manual",
            PENDING_RENDERING_ACTIVE_CLASS = "dx-pending-rendering-active",
            VISIBLE_WHILE_PENDING_RENDERING_CLASS = "dx-visible-while-pending-rendering",
            INVISIBLE_WHILE_PENDING_RENDERING_CLASS = "dx-invisible-while-pending-rendering",
            LOADINDICATOR_CONTAINER_CLASS = "dx-loadindicator-container",
            DEFER_DEFER_RENDERING_LOAD_INDICATOR = "dx-deferrendering-load-indicator",
            ANONYMOUS_TEMPLATE_NAME = "content",
            ACTIONS = ["onRendered", "onShown"];
        var DeferRendering = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    showLoadIndicator: false,
                    renderWhen: void 0,
                    animation: void 0,
                    staggerItemSelector: void 0,
                    onRendered: null,
                    onShown: null
                })
            },
            _getAnonymousTemplateName: function() {
                return ANONYMOUS_TEMPLATE_NAME
            },
            _init: function() {
                this.transitionExecutor = new TransitionExecutorModule.TransitionExecutor;
                this._initElement();
                this._initRender();
                this._$initialContent = this.element().clone().contents();
                this._initActions();
                this.callBase()
            },
            _initElement: function() {
                this.element().addClass(DEFER_RENDERING_CLASS).addClass(LOADINDICATOR_CONTAINER_CLASS)
            },
            _initRender: function() {
                var that = this,
                    $element = this.element(),
                    renderWhen = this.option("renderWhen");
                var doRender = function() {
                    return that._renderDeferredContent()
                };
                if (renderWhen && renderWhen.done) {
                    renderWhen.done(doRender)
                } else {
                    $element.data("dx-render-delegate", doRender);
                    if (void 0 === renderWhen) {
                        $element.addClass(PENDING_RENDERING_MANUAL_CLASS)
                    }
                }
            },
            _initActions: function() {
                this._actions = {};
                $.each(ACTIONS, $.proxy(function(_, action) {
                    this._actions[action] = this._createActionByOption(action) || $.noop
                }, this))
            },
            _renderContentImpl: function() {
                this.element().removeClass(WIDGET_CLASS);
                this.element().append(this._$initialContent);
                this._setLoadingState()
            },
            _renderDeferredContent: function() {
                var that = this,
                    $element = this.element(),
                    result = $.Deferred();
                $element.removeClass(PENDING_RENDERING_MANUAL_CLASS);
                $element.addClass(PENDING_RENDERING_ACTIVE_CLASS);
                this._renderTask = commonUtils.executeAsync(function() {
                    that._renderImpl().done(function() {
                        var shownArgs = {
                            element: $element
                        };
                        that._actions.onShown([shownArgs]);
                        result.resolve(shownArgs)
                    }).fail(function() {
                        result.rejectWith(result, arguments)
                    })
                });
                return result.promise()
            },
            _isElementInViewport: function(element) {
                var rect = element.getBoundingClientRect();
                return rect.bottom >= 0 && rect.right >= 0 && rect.top <= (window.innerHeight || document.documentElement.clientHeight) && rect.left <= (window.innerWidth || document.documentElement.clientWidth)
            },
            _animate: function() {
                var animatePromise, that = this,
                    $element = this.element(),
                    animation = this.option("animation"),
                    staggerItemSelector = this.option("staggerItemSelector");
                that.transitionExecutor.stop();
                if (animation) {
                    if (staggerItemSelector) {
                        $element.find(staggerItemSelector).each(function() {
                            if (that._isElementInViewport(this)) {
                                that.transitionExecutor.enter($(this), animation)
                            }
                        })
                    } else {
                        that.transitionExecutor.enter($element, animation)
                    }
                    animatePromise = that.transitionExecutor.start()
                } else {
                    animatePromise = $.Deferred().resolve().promise()
                }
                return animatePromise
            },
            _renderImpl: function() {
                var $element = this.element(),
                    renderedArgs = {
                        element: $element
                    };
                var contentTemplate = this._getTemplate(this._getAnonymousTemplateName());
                if (contentTemplate) {
                    contentTemplate.render({
                        container: $element.empty(),
                        noModel: true
                    })
                }
                this._setRenderedState($element);
                $element.trigger("dxcontentrendered");
                this._actions.onRendered([renderedArgs]);
                this._isRendered = true;
                return this._animate()
            },
            _setLoadingState: function() {
                var $element = this.element(),
                    hasCustomLoadIndicator = !!$element.find("." + VISIBLE_WHILE_PENDING_RENDERING_CLASS).length;
                $element.addClass(PENDING_RENDERING_CLASS);
                if (!hasCustomLoadIndicator) {
                    $element.children().addClass(INVISIBLE_WHILE_PENDING_RENDERING_CLASS)
                }
                if (this.option("showLoadIndicator")) {
                    this._showLoadIndicator($element)
                }
            },
            _showLoadIndicator: function($container) {
                this._$loadIndicator = $("<div/>")[LoadIndicator.publicName()]({
                    visible: true
                }).addClass(DEFER_DEFER_RENDERING_LOAD_INDICATOR);
                $container.append(this._$loadIndicator)
            },
            _setRenderedState: function() {
                var $element = this.element();
                if (this._$loadIndicator) {
                    this._$loadIndicator.remove()
                }
                $element.removeClass(PENDING_RENDERING_CLASS);
                $element.removeClass(PENDING_RENDERING_ACTIVE_CLASS);
                domUtils.triggerShownEvent($element.children())
            },
            _optionChanged: function(args) {
                var value = args.value,
                    previousValue = args.previousValue;
                switch (args.name) {
                    case "renderWhen":
                        if (false === previousValue && true === value) {
                            this._renderOrAnimate()
                        } else {
                            if (true === previousValue && false === value) {
                                this._setLoadingState()
                            }
                        }
                        break;
                    case "showLoadIndicator":
                    case "onRendered":
                    case "onShown":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _renderOrAnimate: function() {
                var result;
                if (this._isRendered) {
                    this._setRenderedState();
                    result = this._animate()
                } else {
                    result = this._renderDeferredContent()
                }
                return result
            },
            renderContent: function() {
                return this._renderOrAnimate()
            },
            _dispose: function() {
                this.transitionExecutor.stop(true);
                if (this._renderTask) {
                    this._renderTask.abort()
                }
                this._actions = null;
                this._$initialContent = null;
                this.callBase()
            }
        });
        registerComponent("dxDeferRendering", DeferRendering);
        module.exports = DeferRendering
    },
    /*!**************************************!*\
      !*** ./Scripts/ui/drop_down_menu.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Widget = __webpack_require__( /*! ./widget/ui.widget */ 89),
            Button = __webpack_require__( /*! ./button */ 196),
            Popover = __webpack_require__( /*! ./popover */ 202),
            DataHelperMixin = __webpack_require__( /*! ./collection/ui.data_helper */ 154),
            List = __webpack_require__( /*! ./list */ 213);
        var DROP_DOWN_MENU_CLASS = "dx-dropdownmenu",
            DROP_DOWN_MENU_POPUP_CLASS = "dx-dropdownmenu-popup",
            DROP_DOWN_MENU_POPUP_WRAPPER_CLASS = "dx-dropdownmenu-popup-wrapper",
            DROP_DOWN_MENU_LIST_CLASS = "dx-dropdownmenu-list",
            DROP_DOWN_MENU_BUTTON_CLASS = "dx-dropdownmenu-button";
        var POPUP_OPTION_MAP = {
            popupWidth: "width",
            popupHeight: "height"
        };
        var BUTTON_OPTION_MAP = {
            buttonIcon: "icon",
            buttonText: "text",
            buttonWidth: "width",
            buttonHeight: "height",
            buttonTemplate: "template"
        };
        var DropDownMenu = Widget.inherit({
            _supportedKeys: function() {
                var extension = {};
                if (!this.option("opened") || !this._list.option("focusedElement")) {
                    extension = this._button._supportedKeys()
                }
                return $.extend(this.callBase(), extension, {
                    tab: function(e) {
                        this._popup.hide()
                    }
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    buttonIconSrc: {
                        since: "15.1",
                        alias: "buttonIcon"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    items: [],
                    onItemClick: null,
                    dataSource: null,
                    itemTemplate: "item",
                    buttonText: "",
                    buttonIcon: "overflow",
                    buttonWidth: void 0,
                    buttonHeight: void 0,
                    buttonTemplate: "content",
                    onButtonClick: null,
                    usePopover: false,
                    popupWidth: "auto",
                    popupHeight: "auto",
                    activeStateEnabled: true,
                    hoverStateEnabled: true,
                    opened: false,
                    deferRendering: false,
                    popupPosition: {
                        my: "top center",
                        at: "bottom center",
                        collision: "fit flip",
                        offset: {
                            v: 1
                        }
                    },
                    popupAnimation: void 0,
                    onItemRendered: null,
                    menuWidget: List
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: [{
                        platform: "ios"
                    }],
                    options: {
                        usePopover: true
                    }
                }, {
                    device: [{
                        platform: "generic"
                    }],
                    options: {
                        popupPosition: {
                            offset: {
                                v: 4
                            }
                        }
                    }
                }, {
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: [{
                        platform: "android"
                    }],
                    options: {
                        popupPosition: {
                            my: "top " + (this.option("rtlEnabled") ? "left" : "right"),
                            at: "top " + (this.option("rtlEnabled") ? "left" : "right"),
                            collision: "flipfit"
                        },
                        popupAnimation: {
                            show: {
                                type: "pop",
                                duration: 200,
                                from: {
                                    scale: 0
                                },
                                to: {
                                    scale: 1
                                }
                            },
                            hide: {
                                type: "pop",
                                duration: 200,
                                from: {
                                    scale: 1
                                },
                                to: {
                                    scale: 0
                                }
                            }
                        }
                    }
                }])
            },
            _initOptions: function(options) {
                if ("android" === devices.current().platform) {
                    if (!options.popupPosition) {
                        options.popupPosition = {
                            at: (options.usePopover ? "bottom " : "top ") + (options.rtlEnabled ? "left" : "right")
                        }
                    }
                }
                this.callBase(options)
            },
            _dataSourceOptions: function() {
                return {
                    paginate: false
                }
            },
            _init: function() {
                this.callBase();
                this.element().addClass(DROP_DOWN_MENU_CLASS);
                this._initDataSource();
                this._initItemClickAction();
                this._initButtonClickAction()
            },
            _initItemClickAction: function() {
                this._itemClickAction = this._createActionByOption("onItemClick")
            },
            _initButtonClickAction: function() {
                this._buttonClickAction = this._createActionByOption("onButtonClick")
            },
            _render: function() {
                this._renderButton();
                this.callBase();
                this.setAria({
                    role: "menubar",
                    haspopup: true,
                    expanded: this.option("opened")
                })
            },
            _renderContentImpl: function() {
                if (this.option("opened")) {
                    this._renderPopup()
                }
            },
            _clean: function() {
                this._cleanFocusState();
                if (this._popup) {
                    this._popup.element().remove();
                    delete this._$popup
                }
            },
            _renderButton: function() {
                var $button = this.element().addClass(DROP_DOWN_MENU_BUTTON_CLASS),
                    config = this._buttonOptions();
                this._button = this._createComponent($button, Button, config)
            },
            _buttonOptions: function() {
                return {
                    text: this.option("buttonText"),
                    icon: this.option("buttonIcon"),
                    width: this.option("buttonWidth"),
                    height: this.option("buttonHeight"),
                    template: this.option("buttonTemplate"),
                    focusStateEnabled: false,
                    onClick: $.proxy(function(e) {
                        this.option("opened", !this.option("opened"));
                        this._buttonClickAction(e)
                    }, this)
                }
            },
            _toggleMenuVisibility: function(opened) {
                var state = void 0 === opened ? !this._popup.option("visible") : opened;
                if (opened) {
                    this._renderPopup()
                }
                this._popup.toggle(state);
                this.setAria("expanded", state)
            },
            _renderPopup: function() {
                if (this._$popup) {
                    return
                }
                var $popup = this._$popup = $("<div>").appendTo(this.element()),
                    config = this._popupOptions();
                this._popup = this._createComponent($popup, Popover, config)
            },
            _popupOptions: function() {
                var usePopup = !this.option("usePopover");
                return {
                    onInitialized: function(args) {
                        args.component._wrapper().addClass(DROP_DOWN_MENU_POPUP_WRAPPER_CLASS).toggleClass(DROP_DOWN_MENU_POPUP_CLASS, usePopup)
                    },
                    visible: this.option("opened"),
                    onContentReady: $.proxy(this._popupContentReadyHandler, this),
                    deferRendering: false,
                    position: this.option("popupPosition"),
                    animation: this.option("popupAnimation"),
                    onOptionChanged: $.proxy(function(args) {
                        if ("visible" === args.name) {
                            this.option("opened", args.value)
                        }
                    }, this),
                    target: this.element(),
                    height: this.option("popupHeight"),
                    width: this.option("popupWidth")
                }
            },
            _popupContentReadyHandler: function() {
                var popup = Popover.getInstance(this._$popup);
                this._renderList(popup)
            },
            _renderList: function(instance) {
                var $content = instance.content(),
                    listConfig = this._listOptions();
                $content.addClass(DROP_DOWN_MENU_LIST_CLASS);
                this._list = this._createComponent($content, this.option("menuWidget"), listConfig);
                this._list._getAriaTarget = $.proxy(function() {
                    return this.element()
                }, this);
                this._setListDataSource();
                var listMaxHeight = .5 * $(window).height();
                if ($content.height() > listMaxHeight) {
                    $content.height(listMaxHeight)
                }
            },
            _listOptions: function() {
                return {
                    _keyboardProcessor: this._listProcessor,
                    pageLoadMode: "scrollBottom",
                    indicateLoading: false,
                    noDataText: "",
                    itemTemplate: this._getTemplateByOption("itemTemplate"),
                    onItemClick: $.proxy(function(e) {
                        this.option("opened", false);
                        this._itemClickAction(e)
                    }, this),
                    tabIndex: -1,
                    focusStateEnabled: this.option("focusStateEnabled"),
                    activeStateEnabled: this.option("activeStateEnabled"),
                    onItemRendered: this.option("onItemRendered"),
                    _itemAttributes: {
                        role: "menuitem"
                    }
                }
            },
            _setListDataSource: function() {
                if (this._list) {
                    this._list.option("dataSource", this._dataSource || this.option("items"))
                }
                delete this._deferRendering
            },
            _attachKeyboardEvents: function() {
                this.callBase.apply(this, arguments);
                this._listProcessor = this._keyboardProcessor.attachChildProcessor();
                if (this._list) {
                    this._list.option("_keyboardProcessor", this._listProcessor)
                }
            },
            _cleanFocusState: function() {
                this.callBase.apply(this, arguments);
                delete this._listProcessor
            },
            _toggleVisibility: function(visible) {
                this.callBase(visible);
                this._button.option("visible", visible)
            },
            _optionChanged: function(args) {
                var name = args.name;
                var value = args.value;
                switch (name) {
                    case "items":
                    case "dataSource":
                        if (this.option("deferRendering") && !this.option("opened")) {
                            this._deferRendering = true
                        } else {
                            this._refreshDataSource();
                            this._setListDataSource()
                        }
                        break;
                    case "itemTemplate":
                        if (this._list) {
                            this._list.option(name, this._getTemplate(value))
                        }
                        break;
                    case "onItemClick":
                        this._initItemClickAction();
                        break;
                    case "onButtonClick":
                        this._buttonClickAction();
                        break;
                    case "buttonIcon":
                    case "buttonText":
                    case "buttonWidth":
                    case "buttonHeight":
                    case "buttonTemplate":
                        this._button.option(BUTTON_OPTION_MAP[name], value);
                        this._renderPopup();
                        break;
                    case "popupWidth":
                    case "popupHeight":
                        this._popup.option(POPUP_OPTION_MAP[name], value);
                        break;
                    case "usePopover":
                    case "menuWidget":
                        this._invalidate();
                        break;
                    case "focusStateEnabled":
                    case "activeStateEnabled":
                        if (this._list) {
                            this._list.option(name, value)
                        }
                        this.callBase(args);
                        break;
                    case "onItemRendered":
                        if (this._list) {
                            this._list.option(name, value)
                        }
                        break;
                    case "opened":
                        if (this._deferRendering) {
                            this._refreshDataSource();
                            this._setListDataSource()
                        }
                        this._toggleMenuVisibility(value);
                        break;
                    case "deferRendering":
                    case "popupPosition":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            open: function() {
                this.option("opened", true)
            },
            close: function() {
                this.option("opened", false)
            }
        }).include(DataHelperMixin);
        registerComponent("dxDropDownMenu", DropDownMenu);
        module.exports = DropDownMenu
    },
    /*!*************************************!*\
      !*** ./Scripts/ui/file_uploader.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            Editor = __webpack_require__( /*! ./editor/editor */ 107),
            Button = __webpack_require__( /*! ./button */ 196),
            ProgressBar = __webpack_require__( /*! ./progress_bar */ 274),
            browser = __webpack_require__( /*! ../core/utils/browser */ 18),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80);
        var FILEUPLOADER_CLASS = "dx-fileuploader",
            FILEUPLOADER_EMPTY_CLASS = "dx-fileuploader-empty",
            FILEUPLOADER_SHOW_FILE_LIST_CLASS = "dx-fileuploader-show-file-list",
            FILEUPLOADER_DRAGOVER_CLASS = "dx-fileuploader-dragover",
            FILEUPLOADER_FILEINPUT_TAG = "<input type='file'>",
            FILEUPLOADER_WRAPPER_CLASS = "dx-fileuploader-wrapper",
            FILEUPLOADER_CONTAINER_CLASS = "dx-fileuploader-container",
            FILEUPLOADER_CONTENT_CLASS = "dx-fileuploader-content",
            FILEUPLOADER_INPUT_WRAPPER_CLASS = "dx-fileuploader-input-wrapper",
            FILEUPLOADER_INPUT_CONTAINER_CLASS = "dx-fileuploader-input-container",
            FILEUPLOADER_INPUT_LABEL_CLASS = "dx-fileuploader-input-label",
            FILEUPLOADER_INPUT_CLASS = "dx-fileuploader-input",
            FILEUPLOADER_FILES_CONTAINER_CLASS = "dx-fileuploader-files-container",
            FILEUPLOADER_FILE_CONTAINER_CLASS = "dx-fileuploader-file-container",
            FILEUPLOADER_FILE_INFO_CLASS = "dx-fileuploader-file-info",
            FILEUPLOADER_FILE_STATUS_MESSAGE_CLASS = "dx-fileuploader-file-status-message",
            FILEUPLOADER_FILE_CLASS = "dx-fileuploader-file",
            FILEUPLOADER_FILE_NAME_CLASS = "dx-fileuploader-file-name",
            FILEUPLOADER_FILE_SIZE_CLASS = "dx-fileuploader-file-size",
            FILEUPLOADER_BUTTON_CLASS = "dx-fileuploader-button",
            FILEUPLOADER_BUTTON_CONTAINER_CLASS = "dx-fileuploader-button-container",
            FILEUPLOADER_CANCEL_BUTTON_CLASS = "dx-fileuploader-cancel-button",
            FILEUPLOADER_UPLOAD_BUTTON_CLASS = "dx-fileuploader-upload-button",
            FILEUPLOADER_AFTER_LOAD_DELAY = 400;
        var isFormDataSupported = function() {
            return !!window.FormData
        };
        var FileUploader = Editor.inherit({
            _supportedKeys: function() {
                var click = function(e) {
                    e.preventDefault();
                    var $selectButton = this._selectButton.element();
                    $selectButton.trigger(clickEvent.name)
                };
                return $.extend(this.callBase(), {
                    space: click,
                    enter: click
                })
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    value: true
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    buttonText: {
                        since: "15.1",
                        alias: "selectButtonText"
                    },
                    values: {
                        since: "16.1",
                        alias: "value"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: [],
                    selectButtonText: messageLocalization.format("dxFileUploader-selectFile"),
                    uploadButtonText: messageLocalization.format("dxFileUploader-upload"),
                    labelText: messageLocalization.format("dxFileUploader-dropFile"),
                    name: "files[]",
                    multiple: false,
                    accept: "",
                    uploadUrl: "/",
                    allowCanceling: true,
                    showFileList: true,
                    progress: 0,
                    readyToUploadMessage: messageLocalization.format("dxFileUploader-readyToUpload"),
                    uploadedMessage: messageLocalization.format("dxFileUploader-uploaded"),
                    uploadFailedMessage: messageLocalization.format("dxFileUploader-uploadFailedMessage"),
                    uploadMode: "instantly",
                    uploadMethod: "POST",
                    uploadHeaders: {},
                    onUploadStarted: null,
                    onUploaded: null,
                    onProgress: null,
                    onUploadError: null,
                    onUploadAborted: null,
                    extendSelection: true,
                    validationMessageMode: "always",
                    validationMessageOffset: {
                        h: 0,
                        v: 0
                    },
                    useNativeInputClick: false,
                    useDragOver: true,
                    nativeDropSupported: true
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: [{
                        platform: "android"
                    }, {
                        platform: "win"
                    }],
                    options: {
                        validationMessageOffset: {
                            v: 0
                        }
                    }
                }, {
                    device: function() {
                        return browser.msie && browser.version <= 10
                    },
                    options: {
                        useNativeInputClick: true
                    }
                }, {
                    device: function(device) {
                        return "generic" !== devices.real().platform
                    },
                    options: {
                        useDragOver: false
                    }
                }, {
                    device: function() {
                        return !isFormDataSupported()
                    },
                    options: {
                        uploadMode: "useForm"
                    }
                }, {
                    device: function() {
                        return browser.msie || "generic" !== devices.real().platform
                    },
                    options: {
                        nativeDropSupported: false
                    }
                }])
            },
            _init: function() {
                this.option("value", []);
                this.callBase.apply(this, arguments);
                this._initFileInput();
                this._initLabel();
                this._createFiles();
                this._createUploadStartedAction();
                this._createUploadedAction();
                this._createProgressAction();
                this._createUploadErrorAction();
                this._createUploadAbortedAction()
            },
            _initFileInput: function() {
                this._isCustomClickEvent = false;
                if (!this._$fileInput) {
                    this._$fileInput = $(FILEUPLOADER_FILEINPUT_TAG);
                    this._$fileInput.on("change", $.proxy(this._inputChangeHandler, this)).on("click", $.proxy(function() {
                        return this.option("useNativeInputClick") || this._isCustomClickEvent
                    }, this))
                }
                this._$fileInput.prop({
                    multiple: this.option("multiple"),
                    name: this.option("name"),
                    accept: this.option("accept"),
                    tabindex: -1
                })
            },
            _inputChangeHandler: function(e) {
                if (this._doPreventInputChange) {
                    return
                }
                var fileName = this._$fileInput.val().replace(/^.*\\/, ""),
                    files = this._$fileInput.prop("files");
                if (files && !files.length) {
                    return
                }
                var value = files ? this._getFiles(files) : [{
                    name: fileName
                }];
                this._changeValue(value);
                if ("instantly" === this.option("uploadMode")) {
                    this._uploadFiles()
                }
            },
            _shouldFileListBeExtended: function() {
                return this.option("extendSelection") && this.option("multiple")
            },
            _changeValue: function(value) {
                this._shouldChangeValue = true;
                var files = this._shouldFileListBeExtended() ? this.option("value").slice() : [];
                this.option("value", files.concat(value));
                delete this._shouldChangeValue
            },
            _getFiles: function(fileList) {
                var values = [];
                $.each(fileList, function(_, value) {
                    values.push(value)
                });
                return values
            },
            _initLabel: function() {
                if (!this._$inputLabel) {
                    this._$inputLabel = $("<div>")
                }
                this._$inputLabel.text(this.option("labelText"))
            },
            _focusTarget: function() {
                return this.element().find("." + FILEUPLOADER_BUTTON_CLASS)
            },
            _render: function() {
                this.element().addClass(FILEUPLOADER_CLASS);
                this._renderWrapper();
                this._renderInputWrapper();
                this._renderDragEvents();
                this._renderSelectButton();
                this._renderInputContainer();
                this._renderFiles();
                this._renderUploadButton();
                this.callBase.apply(this, arguments)
            },
            _createFiles: function() {
                var value = this.option("value");
                if (!this._files || 0 === value.length || !this._shouldFileListBeExtended()) {
                    this._files = []
                }
                $.each(value.slice(this._files.length), $.proxy(function(_, value) {
                    this._files.push(this._createFile(value))
                }, this))
            },
            _createUploadStartedAction: function() {
                this._uploadStartedAction = this._createActionByOption("onUploadStarted")
            },
            _createUploadedAction: function() {
                this._uploadedAction = this._createActionByOption("onUploaded")
            },
            _createProgressAction: function() {
                this._progressAction = this._createActionByOption("onProgress")
            },
            _createUploadAbortedAction: function() {
                this._uploadAbortedAction = this._createActionByOption("onUploadAborted")
            },
            _createUploadErrorAction: function() {
                this._uploadErrorAction = this._createActionByOption("onUploadError")
            },
            _createFile: function(value) {
                return {
                    value: value,
                    loadedSize: 0,
                    onProgress: $.Callbacks(),
                    onAbort: $.Callbacks(),
                    onLoad: $.Callbacks(),
                    onError: $.Callbacks(),
                    onLoadStart: $.Callbacks()
                }
            },
            _renderFiles: function() {
                var value = this.option("value");
                if (!this._$filesContainer) {
                    this._$filesContainer = $("<div>").addClass(FILEUPLOADER_FILES_CONTAINER_CLASS).appendTo(this._$content)
                } else {
                    if (!this._shouldFileListBeExtended() || 0 === value.length) {
                        this._$filesContainer.empty()
                    }
                }
                var showFileList = this.option("showFileList");
                if (showFileList) {
                    var that = this;
                    $.each(this._files, function(_, file) {
                        if (!file.$file) {
                            that._renderFile(file)
                        }
                    })
                }
                this.element().toggleClass(FILEUPLOADER_SHOW_FILE_LIST_CLASS, showFileList);
                this.element().toggleClass(FILEUPLOADER_EMPTY_CLASS, !this._files.length);
                this._updateFileNameMaxWidth();
                this._$validationMessage && this._$validationMessage.dxOverlay("repaint")
            },
            _renderFile: function(file) {
                var value = file.value;
                var $fileContainer = $("<div>").addClass(FILEUPLOADER_FILE_CONTAINER_CLASS).appendTo(this._$filesContainer);
                this._renderFileButtons(file, $fileContainer);
                file.$file = $("<div>").addClass(FILEUPLOADER_FILE_CLASS).appendTo($fileContainer);
                var $fileInfo = $("<div>").addClass(FILEUPLOADER_FILE_INFO_CLASS).appendTo(file.$file);
                file.$statusMessage = $("<div>").addClass(FILEUPLOADER_FILE_STATUS_MESSAGE_CLASS).text(this.option("readyToUploadMessage")).appendTo(file.$file);
                $("<div>").addClass(FILEUPLOADER_FILE_NAME_CLASS).text(value.name).appendTo($fileInfo);
                if (commonUtils.isDefined(value.size)) {
                    $("<div>").addClass(FILEUPLOADER_FILE_SIZE_CLASS).text(this._getFileSize(value.size)).appendTo($fileInfo)
                }
            },
            _updateFileNameMaxWidth: function() {
                var cancelButtonsCount = this.option("allowCanceling") ? 1 : 0,
                    uploadButtonsCount = "useButtons" === this.option("uploadMode") ? 1 : 0,
                    filesContainerWidth = this._$filesContainer.width(),
                    $buttonContainer = this._$filesContainer.find("." + FILEUPLOADER_BUTTON_CONTAINER_CLASS).eq(0),
                    buttonsWidth = $buttonContainer.width() * (cancelButtonsCount + uploadButtonsCount),
                    $fileSize = this._$filesContainer.find("." + FILEUPLOADER_FILE_SIZE_CLASS).eq(0);
                var prevFileSize = $fileSize.text();
                $fileSize.text("1000 Mb");
                var fileSizeWidth = $fileSize.width();
                $fileSize.text(prevFileSize);
                this._$filesContainer.find("." + FILEUPLOADER_FILE_NAME_CLASS).css("max-width", filesContainerWidth - buttonsWidth - fileSizeWidth)
            },
            _renderFileButtons: function(file, $container) {
                file.cancelButton = this._createComponent($("<div>").addClass(FILEUPLOADER_BUTTON_CLASS + " " + FILEUPLOADER_CANCEL_BUTTON_CLASS), Button, {
                    onClick: $.proxy(function() {
                        this._removeFile(file)
                    }, this),
                    icon: "close",
                    visible: this.option("allowCanceling"),
                    _templates: {}
                });
                $("<div>").addClass(FILEUPLOADER_BUTTON_CONTAINER_CLASS).append(file.cancelButton.element()).appendTo($container);
                if ("useButtons" === this.option("uploadMode")) {
                    file.uploadButton = this._createComponent($("<div>").addClass(FILEUPLOADER_BUTTON_CLASS + " " + FILEUPLOADER_UPLOAD_BUTTON_CLASS), Button, {
                        onClick: $.proxy(function(e) {
                            this._uploadFile(file)
                        }, this),
                        icon: "upload"
                    });
                    $("<div>").addClass(FILEUPLOADER_BUTTON_CONTAINER_CLASS).append(file.uploadButton.element()).appendTo($container);
                    file.onLoadStart.add($.proxy(function() {
                        file.uploadButton.element().remove()
                    }, this))
                }
            },
            _removeFile: function(file) {
                file.$file.parent().remove();
                this._files.splice($.inArray(file, this._files), 1);
                var value = this.option("value").slice();
                value.splice($.inArray(file.value, value), 1);
                this._shouldChangeValue = this._doPreventRecreatingFiles = true;
                this.option("value", value);
                this._shouldChangeValue = this._doPreventRecreatingFiles = false;
                this.element().toggleClass(FILEUPLOADER_EMPTY_CLASS, !this._files.length);
                this._doPreventInputChange = true;
                this._$fileInput.val("");
                this._doPreventInputChange = false
            },
            _getFileSize: function(size) {
                var i = 0,
                    labels = [messageLocalization.format("dxFileUploader-bytes"), messageLocalization.format("dxFileUploader-kb"), messageLocalization.format("dxFileUploader-Mb"), messageLocalization.format("dxFileUploader-Gb")],
                    count = labels.length - 1;
                while (i < count && size >= 1024) {
                    size /= 1024;
                    i++
                }
                return Math.round(size) + " " + labels[i]
            },
            _renderSelectButton: function() {
                var $button = $("<div>").addClass(FILEUPLOADER_BUTTON_CLASS).appendTo(this._$inputWrapper);
                this._selectButton = this._createComponent($button, Button, {
                    text: this.option("selectButtonText"),
                    focusStateEnabled: false,
                    _templates: {}
                });
                if ("desktop" === devices.real().deviceType) {
                    this._selectButton.option("onClick", $.proxy(this._selectButtonClickHandler, this))
                } else {
                    $button.off("click").on("click", $.proxy(this._selectButtonClickHandler, this))
                }
            },
            _selectButtonClickHandler: function() {
                var that = this;
                if (that.option("useNativeInputClick")) {
                    return
                }
                if (that.option("disabled")) {
                    return false
                }
                setTimeout(function() {
                    that._isCustomClickEvent = true;
                    that._$fileInput.click();
                    that._isCustomClickEvent = false
                }, 0)
            },
            _renderUploadButton: function() {
                if ("useButtons" !== this.option("uploadMode")) {
                    return
                }
                var $uploadButton = $("<div>").addClass(FILEUPLOADER_BUTTON_CLASS).addClass(FILEUPLOADER_UPLOAD_BUTTON_CLASS).appendTo(this._$content);
                this._uploadButton = this._createComponent($uploadButton, Button, {
                    text: this.option("uploadButtonText"),
                    onClick: $.proxy(this._uploadButtonClickHandler, this),
                    _templates: {}
                })
            },
            _uploadButtonClickHandler: function() {
                this._uploadFiles()
            },
            _shouldDragOverBeRendered: function() {
                return "useForm" !== this.option("uploadMode") || this.option("nativeDropSupported")
            },
            _renderInputContainer: function() {
                this._$inputContainer = $("<div>").addClass(FILEUPLOADER_INPUT_CONTAINER_CLASS).appendTo(this._$inputWrapper);
                if (!this._shouldDragOverBeRendered()) {
                    this._$inputContainer.css("display", "none")
                }
                this._$fileInput.addClass(FILEUPLOADER_INPUT_CLASS);
                this._renderInput();
                this._$inputLabel.addClass(FILEUPLOADER_INPUT_LABEL_CLASS).appendTo(this._$inputContainer)
            },
            _renderInput: function() {
                if (this.option("useNativeInputClick") && "useForm" === this.option("uploadMode")) {
                    this._selectButton.option("template", $.proxy(this._selectButtonInputTemplate, this))
                } else {
                    this._$fileInput.appendTo(this._$inputContainer);
                    this._selectButton.option("template", "content")
                }
            },
            _selectButtonInputTemplate: function(data, $content) {
                var $text = $("<span>").addClass("dx-button-text").text(data.text);
                $content.append($text).append(this._$fileInput);
                return $content
            },
            _renderInputWrapper: function() {
                this._$inputWrapper = $("<div>").addClass(FILEUPLOADER_INPUT_WRAPPER_CLASS).appendTo(this._$content)
            },
            _renderDragEvents: function() {
                this._$inputWrapper.off("." + this.NAME);
                if (!this._shouldDragOverBeRendered()) {
                    return
                }
                this._dragEventsCount = 0;
                this._$inputWrapper.on(eventUtils.addNamespace("dragenter", this.NAME), $.proxy(this._dragEnterHandler, this)).on(eventUtils.addNamespace("dragover", this.NAME), $.proxy(this._dragOverHandler, this)).on(eventUtils.addNamespace("dragleave", this.NAME), $.proxy(this._dragLeaveHandler, this)).on(eventUtils.addNamespace("drop", this.NAME), $.proxy(this._dropHandler, this))
            },
            _useInputForDrop: function() {
                return this.option("nativeDropSupported") && "useForm" === this.option("uploadMode")
            },
            _dragEnterHandler: function(e) {
                if (this.option("disabled")) {
                    return false
                }
                if (!this._useInputForDrop()) {
                    e.preventDefault()
                }
                this._dragEventsCount++;
                this.element().addClass(FILEUPLOADER_DRAGOVER_CLASS)
            },
            _dragOverHandler: function(e) {
                if (!this._useInputForDrop()) {
                    e.preventDefault()
                }
            },
            _dragLeaveHandler: function(e) {
                if (!this._useInputForDrop()) {
                    e.preventDefault()
                }
                this._dragEventsCount--;
                if (this._dragEventsCount <= 0) {
                    this.element().removeClass(FILEUPLOADER_DRAGOVER_CLASS)
                }
            },
            _dropHandler: function(e) {
                this._dragEventsCount = 0;
                this.element().removeClass(FILEUPLOADER_DRAGOVER_CLASS);
                if (this._useInputForDrop()) {
                    return
                }
                e.preventDefault();
                var fileList = e.originalEvent.dataTransfer.files,
                    files = this._getFiles(fileList);
                if (!this.option("multiple") && files.length > 1) {
                    return
                }
                this._changeValue(this._filterFiles(files));
                if ("instantly" === this.option("uploadMode")) {
                    this._uploadFiles()
                }
            },
            _filterFiles: function(files) {
                if (!files.length) {
                    return files
                }
                var accept = this.option("accept");
                if (!accept.length) {
                    return files
                }
                var result = [],
                    allowedTypes = this._getAllowedFileTypes(accept);
                for (var i = 0, n = files.length; i < n; i++) {
                    if (this._isFileTypeAllowed(files[i], allowedTypes)) {
                        result.push(files[i])
                    }
                }
                return result
            },
            _getAllowedFileTypes: function(acceptSting) {
                if (!acceptSting.length) {
                    return []
                }
                return acceptSting.split(",").map(function(item) {
                    return item.trim()
                })
            },
            _isFileTypeAllowed: function(file, allowedTypes) {
                for (var i = 0, n = allowedTypes.length; i < n; i++) {
                    var allowedType = allowedTypes[i];
                    if ("." === allowedType[0]) {
                        allowedType = allowedType.replace(".", "\\.");
                        if (file.name.match(allowedType)) {
                            return true
                        }
                    } else {
                        allowedType = allowedType.replace("*", "");
                        if (file.type.match(allowedType)) {
                            return true
                        }
                    }
                }
                return false
            },
            _renderWrapper: function() {
                var $wrapper = $("<div>").addClass(FILEUPLOADER_WRAPPER_CLASS).appendTo(this.element());
                var $container = $("<div>").addClass(FILEUPLOADER_CONTAINER_CLASS).appendTo($wrapper);
                this._$content = $("<div>").addClass(FILEUPLOADER_CONTENT_CLASS).appendTo($container)
            },
            _clean: function() {
                this._$fileInput.detach();
                delete this._$filesContainer;
                this.callBase.apply(this, arguments)
            },
            _uploadFiles: function() {
                if (!isFormDataSupported()) {
                    return
                }
                $.each(this._files, $.proxy(function(_, file) {
                    this._uploadFile(file)
                }, this))
            },
            _uploadFile: function(file) {
                if (file.uploadStarted) {
                    return
                }
                var $file = file.$file,
                    value = file.value;
                this._initUploadRequest(file);
                if ($file) {
                    file.progressBar = this._createProgressBar(value.size);
                    file.progressBar.element().appendTo($file);
                    this._initStatusMessage(file);
                    this._initCancelButton(file)
                }
                file.onLoadStart.add($.proxy(this._onUploadStarted, this, file));
                file.onLoad.add($.proxy(this._onLoadedHandler, this, file));
                file.onError.add($.proxy(this._onErrorHandler, this, file));
                file.onAbort.add($.proxy(this._onAbortHandler, this, file));
                file.onProgress.add($.proxy(this._onProgressHandler, this, file));
                file.request.send(this._createFormData(this.option("name"), value))
            },
            _onUploadStarted: function(file, e) {
                file.uploadStarted = true;
                this._uploadStartedAction({
                    file: file.value,
                    jQueryEvent: e
                })
            },
            _onErrorHandler: function(file, e) {
                var that = this;
                setTimeout(function() {
                    if (that.option("showFileList")) {
                        file.$statusMessage.text(that.option("uploadFailedMessage"));
                        file.$statusMessage.css("display", "");
                        file.progressBar.element().remove()
                    }
                }, FILEUPLOADER_AFTER_LOAD_DELAY);
                this._uploadErrorAction({
                    file: file.value,
                    jQueryEvent: e
                })
            },
            _onAbortHandler: function(file, e) {
                this._uploadAbortedAction({
                    file: file.value,
                    jQueryEvent: e
                })
            },
            _onLoadedHandler: function(file, e) {
                var that = this;
                setTimeout(function() {
                    if (that.option("showFileList")) {
                        file.$statusMessage.text(that.option("uploadedMessage"));
                        file.$statusMessage.css("display", "");
                        file.progressBar.element().remove()
                    }
                }, FILEUPLOADER_AFTER_LOAD_DELAY);
                this._uploadedAction({
                    file: file.value,
                    jQueryEvent: e
                })
            },
            _onProgressHandler: function(file, e) {
                var totalSize = this._getTotalSize(),
                    currentLoadedSize = 0,
                    loadedSize = this._getLoadedSize(),
                    progress = 0;
                if (file) {
                    currentLoadedSize = Math.min(e.loaded, file.value.size);
                    var segmentSize = currentLoadedSize - file.loadedSize;
                    loadedSize += segmentSize;
                    file.progressBar && file.progressBar.option({
                        value: currentLoadedSize,
                        showStatus: true
                    });
                    this._progressAction({
                        file: file.value,
                        segmentSize: segmentSize,
                        bytesLoaded: e.loaded,
                        jQueryEvent: e
                    });
                    file.loadedSize = currentLoadedSize
                }
                if (totalSize) {
                    progress = Math.round(loadedSize / totalSize * 100)
                }
                this.option("progress", progress);
                this._setLoadedSize(loadedSize)
            },
            _initStatusMessage: function(file) {
                file.$statusMessage.css("display", "none")
            },
            _initCancelButton: function(file) {
                var cancelClickHandler = $.proxy(function() {
                    file.request.abort();
                    this._removeFile(file)
                }, this);
                file.cancelButton.option("onClick", cancelClickHandler);
                var hideCancelButton = function() {
                    setTimeout(function() {
                        file.cancelButton.option({
                            visible: false
                        })
                    }, FILEUPLOADER_AFTER_LOAD_DELAY)
                };
                file.onLoad.add(hideCancelButton);
                file.onError.add(hideCancelButton)
            },
            _initUploadRequest: function(file) {
                var that = this;
                file.request = this._createRequest(this.option("uploadUrl"));
                file.loadedSize = 0;
                this._initUploadHeaders(file.request);
                file.request.onreadystatechange = $.proxy(function(e) {
                    if (4 === e.currentTarget.readyState) {
                        var status = e.currentTarget.status;
                        if (that._isStatusSuccess(status)) {
                            this.onLoad.fire(e)
                        } else {
                            if (that._isStatusError(status) || !this._isProgressStarted) {
                                this._isError = true;
                                this.onError.fire(e)
                            }
                        }
                    }
                }, file);
                file.request.upload.onprogress = $.proxy(function(e) {
                    if (this._isError) {
                        return
                    }
                    this._isProgressStarted = true;
                    this.onProgress.fire(e)
                }, file);
                file.request.upload.onloadstart = $.proxy(function(e) {
                    this.onLoadStart.fire(e)
                }, file);
                file.request.upload.onabort = $.proxy(function(e) {
                    this.onAbort.fire(e)
                }, file)
            },
            _initUploadHeaders: function(request) {
                var headers = this.option("uploadHeaders");
                for (var name in headers) {
                    if (headers.hasOwnProperty(name)) {
                        request.setRequestHeader(name, headers[name])
                    }
                }
            },
            _isStatusSuccess: function(status) {
                return 200 <= status && status < 300
            },
            _isStatusError: function(status) {
                return 400 <= status && status < 500 || 500 <= status && status < 600
            },
            _createRequest: function(url) {
                var request = new XMLHttpRequest;
                request.open(this.option("uploadMethod"), url, true);
                return request
            },
            _createFormData: function(fieldName, fieldValue) {
                var formData = new FormData;
                formData.append(fieldName, fieldValue);
                return formData
            },
            _createProgressBar: function(fileSize) {
                return this._createComponent($("<div>"), ProgressBar, {
                    value: void 0,
                    min: 0,
                    max: fileSize,
                    statusFormat: function(ratio) {
                        return Math.round(100 * ratio) + "%"
                    },
                    showStatus: false,
                    statusPosition: "right"
                })
            },
            _getTotalSize: function() {
                if (!this._totalSize) {
                    var value = this.option("value"),
                        totalSize = 0;
                    $.each(value, function(_, file) {
                        totalSize += file.size
                    });
                    this._totalSize = totalSize
                }
                return this._totalSize
            },
            _getLoadedSize: function() {
                if (!this._loadedSize) {
                    var loadedSize = 0;
                    $.each(this._files, function(_, file) {
                        loadedSize += file.loadedSize
                    });
                    this._loadedSize = loadedSize
                }
                return this._loadedSize
            },
            _setLoadedSize: function(value) {
                this._loadedSize = value
            },
            _recalculateProgress: function() {
                delete this._totalSize;
                delete this._loadedSize;
                this._onProgressHandler()
            },
            _getValidationMessageTarget: function() {
                return this._$inputWrapper
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "height":
                    case "width":
                        this._updateFileNameMaxWidth();
                        this.callBase(args);
                        break;
                    case "value":
                        if (!this._shouldChangeValue && value.length > 0) {
                            this._$fileInput.val("");
                            this.option("value", [])
                        } else {
                            !value.length && this._$fileInput.val("");
                            if (!this._doPreventRecreatingFiles) {
                                this._createFiles();
                                this._renderFiles()
                            }
                            this._recalculateProgress()
                        }
                        this.callBase(args);
                        break;
                    case "name":
                    case "accept":
                        this._initFileInput();
                        break;
                    case "multiple":
                        this._initFileInput();
                        if (!args.value) {
                            this.reset()
                        }
                        break;
                    case "selectButtonText":
                        this._selectButton.option("text", value);
                        break;
                    case "uploadButtonText":
                        this._uploadButton && this._uploadButton.option("text", value);
                        break;
                    case "readyToUploadMessage":
                    case "uploadedMessage":
                    case "uploadFailedMessage":
                        this._invalidate();
                        break;
                    case "labelText":
                        this._$inputLabel.text(value);
                        break;
                    case "showFileList":
                        this._renderFiles();
                        break;
                    case "uploadUrl":
                    case "progress":
                    case "uploadMethod":
                    case "uploadHeaders":
                    case "extendSelection":
                        break;
                    case "allowCanceling":
                    case "uploadMode":
                        this.reset();
                        this._invalidate();
                        break;
                    case "onUploadStarted":
                        this._createUploadStartedAction();
                        break;
                    case "onUploaded":
                        this._createUploadedAction();
                        break;
                    case "onProgress":
                        this._createProgressAction();
                        break;
                    case "onUploadError":
                        this._createUploadErrorAction();
                        break;
                    case "onUploadAborted":
                        this._createUploadAbortedAction();
                        break;
                    case "useNativeInputClick":
                        this._renderInput();
                        break;
                    case "useDragOver":
                        this._renderDragEvents();
                        break;
                    case "nativeDropSupported":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            reset: function() {
                this.option("value", [])
            }
        });
        FileUploader.__internals = {
            changeFileInputTag: function(tag) {
                FILEUPLOADER_FILEINPUT_TAG = tag
            },
            resetFileInputTag: function() {
                FILEUPLOADER_FILEINPUT_TAG = "<input type='file'>"
            }
        };
        registerComponent("dxFileUploader", FileUploader);
        module.exports = FileUploader
    },
    /*!************************************!*\
      !*** ./Scripts/ui/progress_bar.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            TrackBar = __webpack_require__( /*! ./track_bar */ 275),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43);
        var PROGRESSBAR_CLASS = "dx-progressbar",
            PROGRESSBAR_CONTAINER_CLASS = "dx-progressbar-container",
            PROGRESSBAR_RANGE_CONTAINER_CLASS = "dx-progressbar-range-container",
            PROGRESSBAR_RANGE_CLASS = "dx-progressbar-range",
            PROGRESSBAR_WRAPPER_CLASS = "dx-progressbar-wrapper",
            PROGRESSBAR_STATUS_CLASS = "dx-progressbar-status",
            PROGRESSBAR_INDETERMINATE_SEGMENT_CONTAINER = "dx-progressbar-animating-container",
            PROGRESSBAR_INDETERMINATE_SEGMENT = "dx-progressbar-animating-segment";
        var ProgressBar = TrackBar.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    statusFormat: function(ratio, value) {
                        return "Progress: " + Math.round(100 * ratio) + "%"
                    },
                    showStatus: true,
                    onComplete: null,
                    activeStateEnabled: false,
                    statusPosition: "bottom left",
                    _animatingSegmentCount: 0
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "win"
                    },
                    options: {
                        _animatingSegmentCount: 5
                    }
                }, {
                    device: function(device) {
                        return "android" === device.platform
                    },
                    options: {
                        _animatingSegmentCount: 2
                    }
                }])
            },
            _init: function() {
                this.callBase()
            },
            _render: function() {
                this._createCompleteAction();
                this._renderStatus();
                this.callBase();
                this.element().addClass(PROGRESSBAR_CLASS);
                this.setAria("role", "progressbar");
                this._$wrapper.addClass(PROGRESSBAR_WRAPPER_CLASS);
                this._$bar.addClass(PROGRESSBAR_CONTAINER_CLASS);
                $("<div>").addClass(PROGRESSBAR_RANGE_CONTAINER_CLASS).appendTo(this._$wrapper).append(this._$bar);
                this._$range.addClass(PROGRESSBAR_RANGE_CLASS);
                this._toggleStatus(this.option("showStatus"))
            },
            _createCompleteAction: function() {
                this._completeAction = this._createActionByOption("onComplete")
            },
            _renderStatus: function() {
                this._$status = $("<div>").addClass(PROGRESSBAR_STATUS_CLASS)
            },
            _renderIndeterminateState: function() {
                this._$segmentContainer = $("<div>").addClass(PROGRESSBAR_INDETERMINATE_SEGMENT_CONTAINER);
                var segments = this.option("_animatingSegmentCount");
                for (var i = 0; i < segments; i++) {
                    $("<div>").addClass(PROGRESSBAR_INDETERMINATE_SEGMENT).addClass(PROGRESSBAR_INDETERMINATE_SEGMENT + "-" + (i + 1)).appendTo(this._$segmentContainer)
                }
                this._$segmentContainer.appendTo(this._$wrapper)
            },
            _toggleStatus: function(value) {
                var splittedPosition = this.option("statusPosition").split(" ");
                if (value) {
                    if ("top" === splittedPosition[0] || "left" === splittedPosition[0]) {
                        this._$status.prependTo(this._$wrapper)
                    } else {
                        this._$status.appendTo(this._$wrapper)
                    }
                } else {
                    this._$status.detach()
                }
                this._togglePositionClass()
            },
            _togglePositionClass: function() {
                var position = this.option("statusPosition"),
                    splittedPosition = position.split(" ");
                this._$wrapper.removeClass("dx-position-top-left dx-position-top-right dx-position-bottom-left dx-position-bottom-right dx-position-left dx-position-right");
                var positionClass = "dx-position-" + splittedPosition[0];
                if (splittedPosition[1]) {
                    positionClass += "-" + splittedPosition[1]
                }
                this._$wrapper.addClass(positionClass)
            },
            _toggleIndeterminateState: function(value) {
                if (value) {
                    this._renderIndeterminateState();
                    this._$bar.toggle(false)
                } else {
                    this._$bar.toggle(true);
                    this._$segmentContainer.remove();
                    delete this._$segmentContainer
                }
            },
            _renderValue: function() {
                var val = this.option("value"),
                    max = this.option("max");
                if (!val && 0 !== val) {
                    this._toggleIndeterminateState(true);
                    return
                }
                if (this._$segmentContainer) {
                    this._toggleIndeterminateState(false)
                }
                if (val === max) {
                    this._completeAction()
                }
                this.callBase();
                this._setStatus()
            },
            _setStatus: function() {
                var format = this.option("statusFormat");
                if ($.isFunction(format)) {
                    format = $.proxy(format, this)
                } else {
                    format = function(value) {
                        return value
                    }
                }
                var statusText = format(this._currentRatio, this.option("value"));
                this._$status.text(statusText)
            },
            _dispose: function() {
                this._$status.remove();
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "statusFormat":
                        this._setStatus();
                        break;
                    case "showStatus":
                        this._toggleStatus(args.value);
                        break;
                    case "statusPosition":
                        this._toggleStatus(this.option("showStatus"));
                        break;
                    case "onComplete":
                        this._createCompleteAction();
                        break;
                    case "_animatingSegmentCount":
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxProgressBar", ProgressBar);
        module.exports = ProgressBar
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/track_bar.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Editor = __webpack_require__( /*! ./editor/editor */ 107),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            fx = __webpack_require__( /*! ../animation/fx */ 59);
        var TRACKBAR_CLASS = "dx-trackbar",
            TRACKBAR_CONTAINER_CLASS = "dx-trackbar-container",
            TRACKBAR_RANGE_CLASS = "dx-trackbar-range",
            TRACKBAR_WRAPPER_CLASS = "dx-trackbar-wrapper";
        var TrackBar = Editor.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    min: 0,
                    max: 100,
                    value: 0
                })
            },
            _render: function() {
                this.element().addClass(TRACKBAR_CLASS);
                this._renderWrapper();
                this._renderContainer();
                this._renderRange();
                this.callBase();
                this._renderValue()
            },
            _renderWrapper: function() {
                this._$wrapper = $("<div>").addClass(TRACKBAR_WRAPPER_CLASS).appendTo(this.element())
            },
            _renderContainer: function() {
                this._$bar = $("<div>").addClass(TRACKBAR_CONTAINER_CLASS).appendTo(this._$wrapper)
            },
            _renderRange: function() {
                this._$range = $("<div>").addClass(TRACKBAR_RANGE_CLASS).appendTo(this._$bar)
            },
            _renderValue: function() {
                var val = this.option("value"),
                    min = this.option("min"),
                    max = this.option("max");
                if (min > max) {
                    return
                }
                if (val < min) {
                    this.option("value", min);
                    this._currentRatio = 0;
                    return
                }
                if (val > max) {
                    this.option("value", max);
                    this._currentRatio = 1;
                    return
                }
                var ratio = min === max ? 0 : (val - min) / (max - min);
                !this._needPreventAnimation && this._setRangeStyles({
                    width: 100 * ratio + "%"
                });
                this.setAria({
                    valuemin: this.option("min"),
                    valuemax: max,
                    valuenow: val
                });
                this._currentRatio = ratio
            },
            _setRangeStyles: function(options) {
                fx.stop(this._$range);
                if (!this._needPreventAnimation) {
                    fx.animate(this._$range, {
                        type: "custom",
                        duration: 100,
                        to: options
                    })
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "value":
                        this._renderValue();
                        this.callBase(args);
                        break;
                    case "max":
                    case "min":
                        this._renderValue();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _dispose: function() {
                fx.stop(this._$range);
                this.callBase()
            }
        });
        registerComponent("dxTrackBar", TrackBar);
        module.exports = TrackBar
    },
    /*!****************************!*\
      !*** ./Scripts/ui/form.js ***!
      \****************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./form/ui.form */ 277)
    },
    /*!************************************!*\
      !*** ./Scripts/ui/form/ui.form.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            utils = __webpack_require__( /*! ../../core/utils/common */ 14),
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            windowUtils = __webpack_require__( /*! ../../core/utils/window */ 30),
            ValidationEngine = __webpack_require__( /*! ../validation_engine */ 117),
            LayoutManager = __webpack_require__( /*! ./ui.form.layout_manager */ 278),
            TabPanel = __webpack_require__( /*! ../tab_panel */ 282),
            Scrollable = __webpack_require__( /*! ../scroll_view/ui.scrollable */ 237).default;
        __webpack_require__( /*! ../validation_summary */ 285);
        __webpack_require__( /*! ../validation_group */ 286);
        var FORM_CLASS = "dx-form",
            FIELD_ITEM_CLASS = "dx-field-item",
            FIELD_ITEM_LABEL_TEXT_CLASS = "dx-field-item-label-text",
            FORM_GROUP_CLASS = "dx-form-group",
            FORM_GROUP_CONTENT_CLASS = "dx-form-group-content",
            FORM_GROUP_WITH_CAPTION_CLASS = "dx-form-group-with-caption",
            FORM_GROUP_CAPTION_CLASS = "dx-form-group-caption",
            HIDDEN_LABEL_CLASS = "dx-layout-manager-hidden-label",
            FIELD_ITEM_LABEL_CLASS = "dx-field-item-label",
            FIELD_ITEM_LABEL_CONTENT_CLASS = "dx-field-item-label-content",
            FIELD_ITEM_TAB_CLASS = "dx-field-item-tab",
            FORM_FIELD_ITEM_COL_CLASS = "dx-col-",
            GROUP_COL_COUNT_CLASS = "dx-group-colcount-",
            FIELD_ITEM_CONTENT_CLASS = "dx-field-item-content",
            FORM_VALIDATION_SUMMARY = "dx-form-validation-summary",
            WIDGET_CLASS = "dx-widget";
        var Form = Widget.inherit({
            _init: function() {
                this.callBase();
                this._groupsColCount = []
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    formID: new Guid,
                    formData: {},
                    colCount: 1,
                    screenByWidth: null,
                    colCountByScreen: void 0,
                    labelLocation: "left",
                    readOnly: false,
                    onFieldDataChanged: null,
                    customizeItem: null,
                    onEditorEnterKey: null,
                    minColWidth: 200,
                    alignItemLabels: true,
                    alignItemLabelsInAllGroups: true,
                    showColonAfterLabel: true,
                    showRequiredMark: true,
                    showOptionalMark: false,
                    requiredMark: "*",
                    optionalMark: messageLocalization.format("dxForm-optionalMark"),
                    requiredMessage: messageLocalization.getFormatter("dxForm-requiredMessage"),
                    showValidationSummary: false,
                    items: void 0,
                    scrollingEnabled: false
                })
            },
            _getColCount: function($element) {
                var $cols, index = 0,
                    isFinding = true;
                while (isFinding) {
                    $cols = $element.find("." + FORM_FIELD_ITEM_COL_CLASS + index);
                    if (!$cols.length) {
                        isFinding = false
                    } else {
                        index++
                    }
                }
                return index
            },
            _createHiddenElement: function(rootLayoutManager) {
                this._$hiddenElement = $("<div/>").addClass(WIDGET_CLASS).addClass(HIDDEN_LABEL_CLASS).appendTo(document.body);
                var $hiddenLabel = rootLayoutManager._renderLabel({
                    text: " ",
                    location: this.option("labelLocation")
                }).appendTo(this._$hiddenElement);
                this._hiddenLabelText = $hiddenLabel.find("." + FIELD_ITEM_LABEL_TEXT_CLASS)[0]
            },
            _removeHiddenElement: function() {
                this._$hiddenElement.remove();
                this._hiddenLabelText = null
            },
            _getLabelWidthByText: function(text) {
                this._hiddenLabelText.innerHTML = text;
                return this._hiddenLabelText.offsetWidth
            },
            _getLabelsSelectorByCol: function(index, options) {
                options = options || {};
                var cssExcludeTabbedSelector = options.excludeTabbed ? ":not(." + FIELD_ITEM_TAB_CLASS + ")" : "";
                return "." + (options.inOneColumn ? FIELD_ITEM_CLASS : FORM_FIELD_ITEM_COL_CLASS + index) + cssExcludeTabbedSelector + "> ." + FIELD_ITEM_LABEL_CLASS + " > ." + FIELD_ITEM_LABEL_CONTENT_CLASS
            },
            _getLabelText: function(labelText) {
                var child, i, length = labelText.children.length,
                    result = "";
                for (i = 0; i < length; i++) {
                    child = labelText.children[i];
                    result += !stringUtils.isEmpty(child.innerText) ? child.innerText : child.innerHTML
                }
                return result
            },
            _applyLabelsWidthByCol: function($container, index, options) {
                var labelWidth, i, $labelTexts = $container.find(this._getLabelsSelectorByCol(index, options)),
                    $labelTextsLength = $labelTexts.length,
                    maxWidth = 0;
                for (i = 0; i < $labelTextsLength; i++) {
                    labelWidth = this._getLabelWidthByText(this._getLabelText($labelTexts[i]));
                    if (labelWidth > maxWidth) {
                        maxWidth = labelWidth
                    }
                }
                for (i = 0; i < $labelTextsLength; i++) {
                    $labelTexts[i].style.width = maxWidth + "px"
                }
            },
            _applyLabelsWidth: function($container, excludeTabbed, inOneColumn) {
                var i, colCount = inOneColumn ? 1 : this._getColCount($container),
                    applyLabelsOptions = {
                        excludeTabbed: excludeTabbed,
                        inOneColumn: inOneColumn
                    };
                for (i = 0; i < colCount; i++) {
                    this._applyLabelsWidthByCol($container, i, applyLabelsOptions)
                }
            },
            _getGroupElementsInColumn: function($container, columnIndex, colCount) {
                var cssColCountSelector = utils.isDefined(colCount) ? "." + GROUP_COL_COUNT_CLASS + colCount : "";
                return $container.find("." + FORM_FIELD_ITEM_COL_CLASS + columnIndex + " > ." + FIELD_ITEM_CONTENT_CLASS + " > ." + FORM_GROUP_CLASS + cssColCountSelector)
            },
            _applyLabelsWidthWithGroups: function($container, colCount, excludeTabbed) {
                var i, j, $groups, groupColCount, $groupsByCol, alignItemLabelsInAllGroups = this.option("alignItemLabelsInAllGroups"),
                    applyLabelsOptions = {
                        excludeTabbed: excludeTabbed
                    };
                if (alignItemLabelsInAllGroups) {
                    for (i = 0; i < colCount; i++) {
                        $groupsByCol = this._getGroupElementsInColumn($container, i);
                        this._applyLabelsWidthByCol($groupsByCol, 0, applyLabelsOptions);
                        for (j = 0; j < this._groupsColCount.length; j++) {
                            $groupsByCol = this._getGroupElementsInColumn($container, i, this._groupsColCount[j]);
                            groupColCount = this._getColCount($groupsByCol);
                            for (var k = 1; k < groupColCount; k++) {
                                this._applyLabelsWidthByCol($groupsByCol, k, applyLabelsOptions)
                            }
                        }
                    }
                } else {
                    $groups = this.element().find("." + FORM_GROUP_CLASS);
                    for (i = 0; i < $groups.length; i++) {
                        this._applyLabelsWidth($groups.eq(i), excludeTabbed)
                    }
                }
            },
            _alignLabelsInColumn: function(options) {
                this._createHiddenElement(options.layoutManager);
                if (options.inOneColumn) {
                    this._applyLabelsWidth(options.$container, options.excludeTabbed, true)
                } else {
                    if (this._checkGrouping(options.items)) {
                        this._applyLabelsWidthWithGroups(options.$container, options.layoutManager._getColCount(), options.excludeTabbed)
                    } else {
                        this._applyLabelsWidth(options.$container, options.excludeTabbed)
                    }
                }
                this._removeHiddenElement()
            },
            _render: function() {
                this._clearEditorInstances();
                this.callBase();
                this.element().addClass(FORM_CLASS);
                this._cachedScreenFactor = windowUtils.getCurrentScreenFactor(this.option("screenByWidth"))
            },
            _clearEditorInstances: function() {
                this._editorInstancesByField = {}
            },
            _alignLabels: function(layoutManager, inOneColumn) {
                this._alignLabelsInColumn({
                    $container: this.element(),
                    layoutManager: layoutManager,
                    excludeTabbed: true,
                    items: this.option("items"),
                    inOneColumn: inOneColumn
                })
            },
            _clean: function() {
                this.callBase();
                this._groupsColCount = []
            },
            _renderContentImpl: function() {
                this.callBase();
                this._renderForm();
                this._renderValidationGroup();
                if (this.option("scrollingEnabled")) {
                    this._renderScrollable()
                }
                this._renderLayout();
                this._renderValidationSummary()
            },
            _renderScrollable: function() {
                var useNativeScrolling = this.option("useNativeScrolling");
                this._scrollable = new Scrollable(this._$form, {
                    useNative: !!useNativeScrolling,
                    useSimulatedScrollbar: !useNativeScrolling,
                    useKeyboard: false,
                    direction: "both",
                    bounceEnabled: false
                })
            },
            _getContent: function() {
                return this.option("scrollingEnabled") ? this._scrollable.content() : this._$form
            },
            _renderForm: function() {
                var $element = this.element();
                this._$form = $("<form>").appendTo($element);
                this.setAria("role", "form", $element)
            },
            _renderValidationGroup: function() {
                this._$form.dxValidationGroup()
            },
            _renderValidationSummary: function() {
                var that = this,
                    $validationSummary = that._$form.find("." + FORM_VALIDATION_SUMMARY);
                if ($validationSummary.length > 0) {
                    $validationSummary.remove()
                }
                if (this.option("showValidationSummary")) {
                    $("<div/>").addClass(FORM_VALIDATION_SUMMARY).dxValidationSummary({
                        validationGroup: that
                    }).appendTo(that._getContent())
                }
            },
            _prepareItems: function(items, isTabbed) {
                if (items) {
                    var i, item, clonedItem, that = this,
                        extendedItems = [];
                    for (i = 0; i < items.length; i++) {
                        item = items[i];
                        clonedItem = utils.isObject(item) ? $.extend({}, item) : item;
                        that._prepareGroupItem(clonedItem);
                        that._prepareTabbedItem(clonedItem);
                        that._prepareItemTemplate(clonedItem);
                        if (utils.isObject(clonedItem)) {
                            if (isTabbed) {
                                clonedItem.cssItemClass = FIELD_ITEM_TAB_CLASS
                            }
                            clonedItem.items = this._prepareItems(clonedItem.items, isTabbed)
                        }
                        extendedItems.push(clonedItem)
                    }
                    return extendedItems
                }
            },
            _prepareGroupItem: function(item) {
                if ("group" === item.itemType) {
                    item.alignItemLabels = utils.ensureDefined(item.alignItemLabels, true);
                    if (item.template) {
                        item.groupContentTemplate = this._getTemplate(item.template)
                    }
                    item.template = $.proxy(this._itemGroupTemplate, this, item)
                }
            },
            _prepareTabbedItem: function(item) {
                if ("tabbed" === item.itemType) {
                    item.template = $.proxy(this._itemTabbedTemplate, this, item);
                    item.tabs = this._prepareItems(item.tabs, true)
                }
            },
            _prepareItemTemplate: function(item) {
                if (item.template) {
                    item.template = this._getTemplate(item.template)
                }
            },
            _checkGrouping: function(items) {
                if (items) {
                    for (var i = 0; i < items.length; i++) {
                        var item = items[i];
                        if ("group" === item.itemType) {
                            return true
                        }
                    }
                }
            },
            _renderLayout: function() {
                var that = this,
                    items = that.option("items"),
                    $content = that._getContent();
                items = that._prepareItems(items);
                that._testResultItems = items;
                that._rootLayoutManager = that._renderLayoutManager(items, $content, {
                    colCount: that.option("colCount"),
                    width: this.option("width"),
                    alignItemLabels: that.option("alignItemLabels"),
                    screenByWidth: this.option("screenByWidth"),
                    colCountByScreen: this.option("colCountByScreen"),
                    onLayoutChanged: function(inOneColumn) {
                        $.proxy(that._alignLabels, that)(that._rootLayoutManager, inOneColumn)
                    },
                    onContentReady: function(e) {
                        that._alignLabels(e.component, e.component.isLayoutChanged())
                    }
                })
            },
            _itemTabbedTemplate: function(item, e, $container) {
                var that = this,
                    $tabPanel = $("<div/>").appendTo($container),
                    tabPanelOptions = $.extend({}, item.tabPanelOptions, {
                        dataSource: item.tabs,
                        onItemRendered: function(args) {
                            domUtils.triggerShownEvent(args.itemElement)
                        },
                        itemTemplate: function(itemData, e, $container) {
                            var layoutManager, alignItemLabels = utils.ensureDefined(itemData.alignItemLabels, true);
                            layoutManager = that._renderLayoutManager(itemData.items, $container, {
                                colCount: itemData.colCount,
                                alignItemLabels: alignItemLabels,
                                screenByWidth: this.option("screenByWidth"),
                                colCountByScreen: itemData.colCountByScreen,
                                cssItemClass: itemData.cssItemClass,
                                onLayoutChanged: function(inOneColumn) {
                                    $.proxy(that._alignLabelsInColumn, that)({
                                        $container: $container,
                                        layoutManager: layoutManager,
                                        items: itemData.items,
                                        inOneColumn: inOneColumn
                                    })
                                }
                            });
                            if (alignItemLabels) {
                                $.proxy(that._alignLabelsInColumn, that)({
                                    $container: $container,
                                    layoutManager: layoutManager,
                                    items: itemData.items,
                                    inOneColumn: layoutManager.isLayoutChanged()
                                })
                            }
                        }
                    });
                that._createComponent($tabPanel, TabPanel, tabPanelOptions)
            },
            _itemGroupTemplate: function(item, e, $container) {
                var $groupContent, colCount, layoutManager, $group = $("<div/>").appendTo($container).toggleClass(FORM_GROUP_WITH_CAPTION_CLASS, utils.isDefined(item.caption) && item.caption.length).addClass(FORM_GROUP_CLASS);
                if (item.caption) {
                    $("<span/>").addClass(FORM_GROUP_CAPTION_CLASS).text(item.caption).appendTo($group)
                }
                $groupContent = $("<div/>").addClass(FORM_GROUP_CONTENT_CLASS).appendTo($group);
                if (item.groupContentTemplate) {
                    var data = {
                        formData: this.option("formData"),
                        component: this
                    };
                    item.groupContentTemplate.render({
                        model: data,
                        container: $groupContent
                    })
                } else {
                    layoutManager = this._renderLayoutManager(item.items, $groupContent, {
                        colCount: item.colCount,
                        colCountByScreen: item.colCountByScreen,
                        alignItemLabels: item.alignItemLabels,
                        cssItemClass: item.cssItemClass
                    });
                    colCount = layoutManager._getColCount();
                    if ($.inArray(colCount, this._groupsColCount) === -1) {
                        this._groupsColCount.push(colCount)
                    }
                    $group.addClass(GROUP_COL_COUNT_CLASS + colCount)
                }
            },
            _renderLayoutManager: function(items, $rootElement, options) {
                var instance, $element = $("<div />"),
                    that = this,
                    config = $.extend({
                        items: items,
                        showRequiredMark: this.option("showRequiredMark"),
                        showOptionalMark: this.option("showOptionalMark"),
                        requiredMark: this.option("requiredMark"),
                        optionalMark: this.option("optionalMark"),
                        requiredMessage: this.option("requiredMessage"),
                        screenByWidth: this.option("screenByWidth"),
                        form: that,
                        layoutData: this.option("formData"),
                        labelLocation: this.option("labelLocation"),
                        customizeItem: this.option("customizeItem"),
                        minColWidth: this.option("minColWidth"),
                        showColonAfterLabel: this.option("showColonAfterLabel"),
                        onEditorEnterKey: this.option("onEditorEnterKey"),
                        onContentReady: function(args) {
                            that._updateEditorInstancesFromLayoutManager(args.component._editorInstancesByField);
                            options.onContentReady && options.onContentReady(args)
                        },
                        onFieldDataChanged: function(args) {
                            that._updateFieldValue(args.dataField, args.value)
                        }
                    }, {
                        colCount: options.colCount,
                        alignItemLabels: options.alignItemLabels,
                        cssItemClass: options.cssItemClass,
                        colCountByScreen: options.colCountByScreen,
                        onLayoutChanged: options.onLayoutChanged,
                        width: options.width,
                        validationBoundary: that.option("scrollingEnabled") ? that.element() : void 0
                    });
                $element.appendTo($rootElement);
                instance = that._createComponent($element, "dxLayoutManager", config);
                that._attachSyncSubscriptions(instance);
                return instance
            },
            _updateEditorInstancesFromLayoutManager: function(instancesByDataFields) {
                $.extend(this._editorInstancesByField, instancesByDataFields)
            },
            _createComponent: function($element, type, config) {
                var that = this;
                config = config || {};
                that._extendConfig(config, {
                    readOnly: that.option("readOnly")
                });
                return that.callBase($element, type, config)
            },
            _attachSyncSubscriptions: function(instance) {
                var that = this;
                that.on("optionChanged", function(args) {
                    var formDataFieldStart = "formData.";
                    if (0 === args.fullName.search(formDataFieldStart)) {
                        var layoutDataField = args.fullName.replace(formDataFieldStart, "layoutData.");
                        instance.option(layoutDataField, args.value)
                    }
                    if (utils.isDefined(that.option("items")) && "formData" === args.fullName) {
                        instance.updateData(args.value)
                    }
                    if ("readOnly" === args.name) {
                        instance.option(args.fullName, args.value)
                    }
                })
            },
            _optionChanged: function(args) {
                var rootNameOfComplexOption = this._getRootLevelOfExpectedComplexOption(args.fullName, ["formData", "items"]);
                if (rootNameOfComplexOption) {
                    this._customHandlerOfComplexOption(args, rootNameOfComplexOption);
                    return
                }
                switch (args.name) {
                    case "formData":
                        if (!utils.isDefined(this._options.items)) {
                            this._options[args.name] = args.value;
                            this._invalidate();
                            this._triggerOnFieldDataChangedByDataSet(args.value)
                        } else {
                            if ($.isEmptyObject(args.value)) {
                                this._resetValues()
                            }
                        }
                        break;
                    case "items":
                    case "colCount":
                    case "onFieldDataChanged":
                    case "onEditorEnterKey":
                    case "labelLocation":
                    case "alignItemLabels":
                    case "showColonAfterLabel":
                    case "customizeItem":
                    case "alignItemLabelsInAllGroups":
                    case "showRequiredMark":
                    case "showOptionalMark":
                    case "requiredMark":
                    case "optionalMark":
                    case "requiredMessage":
                    case "scrollingEnabled":
                    case "formID":
                    case "colCountByScreen":
                    case "screenByWidth":
                        this._invalidate();
                        break;
                    case "showValidationSummary":
                        this._renderValidationSummary();
                        break;
                    case "minColWidth":
                        if ("auto" === this.option("colCount")) {
                            this._invalidate()
                        }
                        break;
                    case "readOnly":
                        break;
                    case "width":
                        this.callBase(args);
                        this._rootLayoutManager.option(args.name, args.value);
                        this._alignLabels(this._rootLayoutManager, this._rootLayoutManager.isLayoutChanged());
                        break;
                    case "visible":
                        this.callBase(args);
                        if (args.value) {
                            domUtils.triggerShownEvent(this.element())
                        }
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _getRootLevelOfExpectedComplexOption: function(fullOptionName, expectedRootNames) {
                var result, splitedFullName = fullOptionName.split(".");
                if (splitedFullName.length > 1) {
                    var i, rootOptionName = splitedFullName[0];
                    for (i = 0; i < expectedRootNames.length; i++) {
                        if (rootOptionName.search(expectedRootNames[i]) !== -1) {
                            result = expectedRootNames[i]
                        }
                    }
                }
                return result
            },
            _customHandlerOfComplexOption: function(args, rootOptionName) {
                var nameParts = args.fullName.split(".");
                switch (rootOptionName) {
                    case "items":
                        var instance, items, name, itemPath = this._getItemPath(nameParts),
                            item = this.option(itemPath);
                        if (args.fullName.search("editorOptions") !== -1) {
                            instance = this.getEditor(item.dataField);
                            instance && instance.option(item.editorOptions)
                        } else {
                            if (item) {
                                name = args.fullName.replace(itemPath + ".", "");
                                this._changeItemOption(item, name, args.value);
                                items = this._generateItemsFromData(this.option("items"));
                                this.option("items", items)
                            }
                        }
                        break;
                    case "formData":
                        var dataField = nameParts.slice(1).join(".");
                        this._triggerOnFieldDataChanged({
                            dataField: dataField,
                            value: args.value
                        })
                }
            },
            _getItemPath: function(nameParts) {
                var i, itemPath = nameParts[0];
                for (i = 1; i < nameParts.length; i++) {
                    if (nameParts[i].search("items") !== -1) {
                        itemPath += "." + nameParts[i]
                    } else {
                        break
                    }
                }
                return itemPath
            },
            _triggerOnFieldDataChanged: function(args) {
                this._createActionByOption("onFieldDataChanged")(args)
            },
            _triggerOnFieldDataChangedByDataSet: function(data) {
                var that = this;
                if (data && utils.isObject(data)) {
                    $.each(data, function(dataField, value) {
                        that._triggerOnFieldDataChanged({
                            dataField: dataField,
                            value: value
                        })
                    })
                }
            },
            _updateFieldValue: function(dataField, value) {
                if (utils.isDefined(this.option("formData"))) {
                    this.option("formData." + dataField, value)
                }
            },
            _generateItemsFromData: function(items) {
                var formData = this.option("formData"),
                    result = [];
                if (!items && utils.isDefined(formData)) {
                    $.each(formData, function(dataField, value) {
                        result.push({
                            dataField: dataField
                        })
                    })
                }
                if (items) {
                    $.each(items, function(index, item) {
                        if (utils.isObject(item)) {
                            result.push(item)
                        } else {
                            result.push({
                                dataField: item
                            })
                        }
                    })
                }
                return result
            },
            _getItemByField: function(field, items) {
                var resultItem, that = this,
                    fieldParts = utils.isObject(field) ? field : that._getFieldParts(field),
                    fieldName = fieldParts.fieldName,
                    fieldPath = fieldParts.fieldPath;
                if (items.length) {
                    $.each(items, function(index, item) {
                        var itemType = item.itemType;
                        if (fieldPath.length) {
                            var path = fieldPath.slice();
                            item = that._getItemByFieldPath(path, fieldName, item)
                        } else {
                            if ("group" === itemType && !item.caption) {
                                item.items = that._generateItemsFromData(item.items);
                                item = that._getItemByField({
                                    fieldName: fieldName,
                                    fieldPath: fieldPath
                                }, item.items)
                            }
                        }
                        if (item && (item.dataField === fieldName || item.name === fieldName || "group" === item.itemType && that._getTextWithoutSpaces(item.caption) === fieldName || that._getTextWithoutSpaces(item.title) === fieldName)) {
                            resultItem = item;
                            return false
                        }
                    })
                }
                return resultItem
            },
            _getFieldParts: function(field) {
                var fieldSeparator = ".",
                    fieldName = field,
                    separatorIndex = fieldName.indexOf(fieldSeparator),
                    resultPath = [];
                while (separatorIndex !== -1) {
                    resultPath.push(fieldName.substr(0, separatorIndex));
                    fieldName = fieldName.substr(separatorIndex + 1);
                    separatorIndex = fieldName.indexOf(fieldSeparator)
                }
                return {
                    fieldName: fieldName,
                    fieldPath: resultPath.reverse()
                }
            },
            _getItemByFieldPath: function(path, fieldName, item) {
                var result, that = this,
                    itemType = item.itemType,
                    subItemsField = that._getSubItemField(itemType),
                    isItemWithSubItems = "group" === itemType || "tabbed" === itemType || item.title;
                do {
                    if (isItemWithSubItems) {
                        var pathNode, isGroupWithCaption = utils.isDefined(item.caption || item.title),
                            captionWithoutSpaces = that._getTextWithoutSpaces(item.caption || item.title);
                        item[subItemsField] = that._generateItemsFromData(item[subItemsField]);
                        if (isGroupWithCaption) {
                            pathNode = path.pop()
                        }
                        if (!path.length) {
                            result = that._getItemByField(fieldName, item[subItemsField]);
                            if (result) {
                                break
                            }
                        }
                        if (!isGroupWithCaption || isGroupWithCaption && captionWithoutSpaces === pathNode) {
                            if (path.length) {
                                result = that._searchItemInEverySubitem(path, fieldName, item[subItemsField])
                            }
                        }
                    } else {
                        break
                    }
                } while (path.length && false !== result);
                return result
            },
            _getSubItemField: function(itemType) {
                return "tabbed" === itemType ? "tabs" : "items"
            },
            _searchItemInEverySubitem: function(path, fieldName, items) {
                var result, that = this;
                $.each(items, function(index, groupItem) {
                    result = that._getItemByFieldPath(path, fieldName, groupItem);
                    if (result) {
                        return false
                    }
                });
                if (!result) {
                    result = false
                }
                return result
            },
            _getTextWithoutSpaces: function(text) {
                return text ? text.replace(" ", "") : void 0
            },
            _changeItemOption: function(item, option, value) {
                if (utils.isObject(item)) {
                    item[option] = value
                }
            },
            _dimensionChanged: function() {
                var currentScreenFactor = windowUtils.getCurrentScreenFactor(this.option("screenByWidth"));
                if (this._cachedScreenFactor !== currentScreenFactor) {
                    this._cachedScreenFactor = currentScreenFactor;
                    this._refresh();
                    return
                }
                if ("auto" === this.option("colCount")) {
                    this._refresh()
                }
            },
            _refresh: function() {
                this.element().find(".dx-state-focused input, .dx-state-focused textarea").trigger("change");
                this.callBase()
            },
            _resetValues: function() {
                $.each(this._editorInstancesByField, function(dataField, editor) {
                    editor.reset();
                    editor.option("isValid", true)
                })
            },
            _updateData: function(data, value, isComplexData) {
                var that = this,
                    _data = isComplexData ? value : data;
                if (utils.isObject(_data)) {
                    $.each(_data, function(dataField, fieldValue) {
                        that._updateData(isComplexData ? data + "." + dataField : dataField, fieldValue, utils.isObject(fieldValue))
                    })
                } else {
                    if (utils.isString(data)) {
                        that._updateFieldValue(data, value)
                    }
                }
            },
            registerKeyHandler: function(key, handler) {
                this.callBase(key, handler);
                $.each(this._editorInstancesByField, function(dataField, editor) {
                    editor.registerKeyHandler(key, handler)
                })
            },
            _focusTarget: function() {
                return this.element().find(".dx-field-item-content [tabindex]").first()
            },
            resetValues: function() {
                this._resetValues()
            },
            updateData: function(data, value) {
                this._updateData(data, value)
            },
            getEditor: function(field) {
                return this._editorInstancesByField[field]
            },
            updateDimensions: function() {
                var that = this,
                    deferred = $.Deferred();
                if (that._scrollable) {
                    that._scrollable.update().done(function() {
                        deferred.resolveWith(that)
                    })
                } else {
                    deferred.resolveWith(that)
                }
                return deferred.promise()
            },
            itemOption: function(field, option, value) {
                var that = this,
                    argsCount = arguments.length,
                    items = that._generateItemsFromData(that.option("items")),
                    item = that._getItemByField(field, items);
                if (1 === argsCount) {
                    return item
                } else {
                    if (3 === argsCount) {
                        that._changeItemOption(item, option, value)
                    } else {
                        if (utils.isObject(option)) {
                            $.each(option, function(optionName, optionValue) {
                                that._changeItemOption(item, optionName, optionValue)
                            })
                        }
                    }
                    this.option("items", items)
                }
            },
            validate: function() {
                try {
                    return ValidationEngine.validateGroup(this)
                } catch (e) {
                    errors.log("E1036", e.message)
                }
            }
        });
        registerComponent("dxForm", Form);
        module.exports = Form;
        module.exports.__internals = $.extend({
            FORM_CLASS: FORM_CLASS,
            FORM_GROUP_CLASS: FORM_GROUP_CLASS,
            FORM_GROUP_CAPTION_CLASS: FORM_GROUP_CAPTION_CLASS,
            FORM_FIELD_ITEM_COL_CLASS: FORM_FIELD_ITEM_COL_CLASS
        }, LayoutManager.__internals)
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/form/ui.form.layout_manager.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            utils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isWrapped = __webpack_require__( /*! ../../core/utils/variable_wrapper */ 38).isWrapped,
            isWritableWrapped = __webpack_require__( /*! ../../core/utils/variable_wrapper */ 38).isWritableWrapped,
            windowUtils = __webpack_require__( /*! ../../core/utils/window */ 30),
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            normalizeIndexes = __webpack_require__( /*! ../../core/utils/array */ 111).normalizeIndexes,
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            Validator = __webpack_require__( /*! ../validator */ 279),
            ResponsiveBox = __webpack_require__( /*! ../responsive_box */ 281);
        __webpack_require__( /*! ../text_box */ 206);
        __webpack_require__( /*! ../number_box */ 255);
        __webpack_require__( /*! ../check_box */ 241);
        __webpack_require__( /*! ../date_box */ 259);
        var FORM_EDITOR_BY_DEFAULT = "dxTextBox",
            FIELD_ITEM_CLASS = "dx-field-item",
            FIELD_EMPTY_ITEM_CLASS = "dx-field-empty-item",
            FIELD_ITEM_REQUIRED_CLASS = "dx-field-item-required",
            FIELD_ITEM_OPTIONAL_CLASS = "dx-field-item-optional",
            FIELD_ITEM_REQUIRED_MARK_CLASS = "dx-field-item-required-mark",
            FIELD_ITEM_OPTIONAL_MARK_CLASS = "dx-field-item-optional-mark",
            FIELD_ITEM_LABEL_CLASS = "dx-field-item-label",
            FIELD_ITEM_LABEL_ALIGN_CLASS = "dx-field-item-label-align",
            FIELD_ITEM_LABEL_CONTENT_CLASS = "dx-field-item-label-content",
            FIELD_ITEM_LABEL_TEXT_CLASS = "dx-field-item-label-text",
            FIELD_ITEM_LABEL_LOCATION_CLASS = "dx-field-item-label-location-",
            FIELD_ITEM_CONTENT_CLASS = "dx-field-item-content",
            FIELD_ITEM_CONTENT_LOCATION_CLASS = "dx-field-item-content-location-",
            FIELD_ITEM_CONTENT_WRAPPER_CLASS = "dx-field-item-content-wrapper",
            FIELD_ITEM_HELP_TEXT_CLASS = "dx-field-item-help-text",
            FORM_LAYOUT_MANAGER_CLASS = "dx-layout-manager",
            LABEL_HORIZONTAL_ALIGNMENT_CLASS = "dx-label-h-align",
            LABEL_VERTICAL_ALIGNMENT_CLASS = "dx-label-v-align",
            LAYOUT_MANAGER_FIRST_ROW_CLASS = "dx-first-row",
            LAYOUT_MANAGER_FIRST_COL_CLASS = "dx-first-col",
            LAYOUT_MANAGER_LAST_COL_CLASS = "dx-last-col",
            FLEX_LAYOUT_CLASS = "dx-flex-layout",
            LAYOUT_MANAGER_ONE_COLUMN = "dx-layout-manager-one-col";
        var LayoutManager = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    layoutData: {},
                    readOnly: false,
                    colCount: 1,
                    colCountByScreen: void 0,
                    labelLocation: "left",
                    onFieldDataChanged: null,
                    onEditorEnterKey: null,
                    customizeItem: null,
                    alignItemLabels: true,
                    minColWidth: 200,
                    showRequiredMark: true,
                    screenByWidth: null,
                    showOptionalMark: false,
                    requiredMark: "*",
                    optionalMark: messageLocalization.format("dxForm-optionalMark"),
                    requiredMessage: messageLocalization.getFormatter("dxForm-requiredMessage")
                })
            },
            _init: function() {
                this.callBase();
                this._syncDataWithItems();
                this._updateItems(this.option("layoutData"))
            },
            _syncDataWithItems: function() {
                var that = this,
                    userItems = that.option("items");
                if (utils.isDefined(userItems)) {
                    $.each(userItems, function(index, item) {
                        var value;
                        if (item.dataField && void 0 === that._getDataByField(item.dataField)) {
                            if (item.editorOptions) {
                                value = item.editorOptions.value
                            }
                            that._updateFieldValue(item.dataField, value)
                        }
                    })
                }
            },
            _getDataByField: function(dataField) {
                return dataField ? this.option("layoutData." + dataField) : null
            },
            _updateFieldValue: function(dataField, value) {
                var layoutData = this.option("layoutData");
                if (!isWrapped(layoutData[dataField]) && utils.isDefined(dataField)) {
                    this.option("layoutData." + dataField, value);
                    this._triggerOnFieldDataChanged({
                        dataField: dataField,
                        value: value
                    })
                } else {
                    if (isWritableWrapped(layoutData[dataField])) {
                        var newValue = utils.isFunction(value) ? value() : value;
                        layoutData[dataField](newValue)
                    }
                }
            },
            _triggerOnFieldDataChanged: function(args) {
                this._createActionByOption("onFieldDataChanged")(args)
            },
            _updateItems: function(layoutData) {
                var items, visibleItems, that = this,
                    userItems = this.option("items"),
                    customizeItem = that.option("customizeItem");
                items = utils.isDefined(userItems) ? userItems : this._generateItemsByData(layoutData);
                if (utils.isDefined(items)) {
                    visibleItems = [];
                    $.each(items, function(index, item) {
                        if (that._isAcceptableItem(item)) {
                            item = that._processItem(item);
                            customizeItem && customizeItem(item);
                            var isItemVisibleDefined = utils.isDefined(item.visible);
                            if (utils.isObject(item) && !isItemVisibleDefined || isItemVisibleDefined && item.visible) {
                                visibleItems.push(item)
                            }
                        }
                    });
                    this._items = visibleItems;
                    this._sortItems()
                }
            },
            _generateItemsByData: function(layoutData) {
                var result = [];
                if (utils.isDefined(layoutData)) {
                    $.each(layoutData, function(dataField, value) {
                        result.push({
                            dataField: dataField
                        })
                    })
                }
                return result
            },
            _isAcceptableItem: function(item) {
                var itemField = item.dataField || item,
                    itemData = this.option("layoutData." + itemField);
                return !(utils.isFunction(itemData) && !isWrapped(itemData))
            },
            _processItem: function(item) {
                if ("string" === typeof item) {
                    item = {
                        dataField: item
                    }
                }
                if ("object" === typeof item && !item.itemType) {
                    item.itemType = "simple"
                }
                if (!utils.isDefined(item.editorType) && utils.isDefined(item.dataField)) {
                    var value = this._getDataByField(item.dataField);
                    item.editorType = utils.isDefined(value) ? this._getEditorTypeByDataType($.type(value)) : FORM_EDITOR_BY_DEFAULT
                }
                return item
            },
            _getEditorTypeByDataType: function(dataType) {
                switch (dataType) {
                    case "number":
                        return "dxNumberBox";
                    case "date":
                        return "dxDateBox";
                    case "boolean":
                        return "dxCheckBox";
                    default:
                        return "dxTextBox"
                }
            },
            _sortItems: function() {
                normalizeIndexes(this._items, "visibleIndex");
                this._sortIndexes()
            },
            _sortIndexes: function() {
                this._items.sort(function(itemA, itemB) {
                    var result, indexA = itemA.visibleIndex,
                        indexB = itemB.visibleIndex;
                    if (indexA > indexB) {
                        result = 1
                    } else {
                        if (indexA < indexB) {
                            result = -1
                        } else {
                            result = 0
                        }
                    }
                    return result
                })
            },
            _render: function() {
                this._clearEditorInstances();
                this.element().addClass(FORM_LAYOUT_MANAGER_CLASS);
                this.callBase()
            },
            _clearEditorInstances: function() {
                this._editorInstancesByField = {}
            },
            _hasBrowserFlex: function() {
                return "flex" === support.styleProp("flex")
            },
            _renderContentImpl: function() {
                this.callBase();
                this._renderResponsiveBox()
            },
            _renderResponsiveBox: function() {
                var layoutItems, that = this,
                    colCount = that._getColCount(),
                    colCountByScreen = this.option("colCountByScreen"),
                    xsColCount = colCountByScreen && colCountByScreen.xs;
                if (that._items && that._items.length) {
                    that._prepareItemsWithMerging(colCount);
                    layoutItems = that._generateLayoutItems();
                    that._responsiveBox = new ResponsiveBox($("<div />").appendTo(that.element()), {
                        _layoutStrategy: that._hasBrowserFlex() ? "flex" : "fallback",
                        onLayoutChanged: function() {
                            var onLayoutChanged = that.option("onLayoutChanged"),
                                isLayoutChanged = that.isLayoutChanged();
                            if (onLayoutChanged) {
                                that.element().toggleClass(LAYOUT_MANAGER_ONE_COLUMN, isLayoutChanged);
                                onLayoutChanged(isLayoutChanged)
                            }
                        },
                        onContentReady: function(e) {
                            if (that.option("onLayoutChanged")) {
                                that.element().toggleClass(LAYOUT_MANAGER_ONE_COLUMN, that.isLayoutChanged(e.component))
                            }
                            that._fireContentReadyAction()
                        },
                        itemTemplate: function(e, itemData, $itemElement) {
                            if (!e.location) {
                                return
                            }
                            var itemRenderedCountInPreviousRows = e.location.row * colCount,
                                item = that._items[e.location.col + itemRenderedCountInPreviousRows],
                                $fieldItem = $("<div/>").addClass(item.cssClass).appendTo($itemElement);
                            if (0 === e.location.row) {
                                $fieldItem.addClass(LAYOUT_MANAGER_FIRST_ROW_CLASS)
                            }
                            if (0 === e.location.col) {
                                $fieldItem.addClass(LAYOUT_MANAGER_FIRST_COL_CLASS)
                            }
                            if (e.location.col === colCount - 1 || e.location.col + e.location.colspan === colCount) {
                                $fieldItem.addClass(LAYOUT_MANAGER_LAST_COL_CLASS)
                            }
                            "empty" === item.itemType ? that._renderEmptyItem($fieldItem) : that._renderFieldItem(item, $fieldItem)
                        },
                        cols: that._generateRatio(colCount),
                        rows: that._generateRatio(that._getRowsCount(), true),
                        dataSource: layoutItems,
                        screenByWidth: this.option("screenByWidth"),
                        singleColumnScreen: xsColCount ? false : "xs"
                    })
                }
            },
            _getColCount: function() {
                var colCount = this.option("colCount"),
                    colCountByScreen = this.option("colCountByScreen");
                if (colCountByScreen) {
                    var currentColCount = colCountByScreen[windowUtils.getCurrentScreenFactor(this.option("screenByWidth"))];
                    colCount = currentColCount || colCount
                }
                if ("auto" === colCount) {
                    if (!!this._cashedColCount) {
                        return this._cashedColCount
                    }
                    var minColWidth = this.option("minColWidth"),
                        width = this.element().width(),
                        itemsCount = this._items.length,
                        maxColCount = Math.floor(width / minColWidth) || 1;
                    this._cashedColCount = colCount = itemsCount < maxColCount ? itemsCount : maxColCount
                }
                return colCount < 1 ? 1 : colCount
            },
            _prepareItemsWithMerging: function(colCount) {
                var item, itemsMergedByCol, j, i, items = this._items.slice(0),
                    result = [];
                for (i = 0; i < items.length; i++) {
                    item = items[i];
                    result.push(item);
                    if (this.option("alignItemLabels") || item.alignItemLabels || item.colSpan) {
                        item.col = this._getColByIndex(result.length - 1, colCount)
                    }
                    if (item.colSpan > 1 && item.col + item.colSpan <= colCount) {
                        itemsMergedByCol = [];
                        for (j = 0; j < item.colSpan - 1; j++) {
                            itemsMergedByCol.push({
                                merged: true
                            })
                        }
                        result = result.concat(itemsMergedByCol)
                    } else {
                        delete item.colSpan
                    }
                }
                this._items = result
            },
            _getColByIndex: function(index, colCount) {
                return index % colCount
            },
            _generateLayoutItems: function() {
                var item, i, items = this._items,
                    colCount = this._getColCount(),
                    result = [];
                for (i = 0; i < items.length; i++) {
                    item = items[i];
                    if (!item.merged) {
                        var generatedItem = {
                            location: {
                                row: parseInt(i / colCount),
                                col: this._getColByIndex(i, colCount)
                            }
                        };
                        if (utils.isDefined(item.colSpan)) {
                            generatedItem.location.colspan = item.colSpan
                        }
                        if (utils.isDefined(item.rowSpan)) {
                            generatedItem.location.rowspan = item.rowSpan
                        }
                        result.push(generatedItem)
                    }
                }
                return result
            },
            _renderEmptyItem: function($container) {
                return $container.addClass(FIELD_EMPTY_ITEM_CLASS).html("&nbsp;")
            },
            _renderFieldItem: function(item, $container) {
                var $label, helpID, name = this._getName(item),
                    id = this.getItemID(name),
                    isRequired = utils.isDefined(item.isRequired) ? item.isRequired : !!this._hasRequiredRuleInSet(item.validationRules),
                    labelOptions = $.extend({
                        showColon: this.option("showColonAfterLabel"),
                        location: this.option("labelLocation"),
                        id: id,
                        visible: true,
                        isRequired: isRequired
                    }, item ? item.label : {}),
                    $editor = $("<div/>");
                $container.addClass(FIELD_ITEM_CLASS).addClass(isRequired ? FIELD_ITEM_REQUIRED_CLASS : FIELD_ITEM_OPTIONAL_CLASS).addClass(this.option("cssItemClass")).addClass(utils.isDefined(item.col) ? "dx-col-" + item.col : "");
                this._prepareLabelOptions(item.dataField, labelOptions);
                if (labelOptions.visible && labelOptions.text) {
                    $label = this._renderLabel(labelOptions);
                    $label.appendTo($container)
                }
                if (item.helpText) {
                    helpID = new Guid
                }
                if ("simple" === item.itemType) {
                    if (this._isLabelNeedBaselineAlign(item) && "top" !== labelOptions.location) {
                        $container.addClass(FIELD_ITEM_LABEL_ALIGN_CLASS)
                    }
                    this._hasBrowserFlex() && $container.addClass(FLEX_LAYOUT_CLASS)
                }
                $editor.data("dx-form-item", item);
                this._appendEditorToField({
                    $fieldItem: $container,
                    $label: $label,
                    $editor: $editor,
                    labelOptions: labelOptions
                });
                this._renderEditor({
                    $container: $editor,
                    dataField: name,
                    editorType: item.editorType,
                    editorOptions: item.editorOptions,
                    template: this._getTemplateByFieldItem(item),
                    isRequired: isRequired,
                    helpID: helpID,
                    id: id,
                    validationBoundary: this.option("validationBoundary")
                });
                var $validationTarget = $editor.children().first();
                if ($validationTarget && $validationTarget.data("dx-validation-target")) {
                    this._renderValidator($validationTarget, item)
                }
                this._renderHelpText(item, $editor, helpID);
                this._attachClickHandler($label, $editor, item.editorType)
            },
            _hasRequiredRuleInSet: function(rules) {
                var hasRequiredRule;
                if (rules && rules.length) {
                    $.each(rules, function(index, rule) {
                        if ("required" === rule.type) {
                            hasRequiredRule = true;
                            return false
                        }
                    })
                }
                return hasRequiredRule
            },
            _getName: function(item) {
                return item.dataField || item.name
            },
            _isLabelNeedBaselineAlign: function(item) {
                var largeEditors = ["dxTextArea", "dxRadioGroup", "dxCalendar"];
                return !!item.helpText && !this._hasBrowserFlex() || $.inArray(item.editorType, largeEditors) !== -1
            },
            _prepareLabelOptions: function(dataField, options) {
                if (!options.text && dataField) {
                    options.text = inflector.captionize(dataField)
                }
                if (options.text) {
                    options.text += options.showColon ? ":" : ""
                }
            },
            _renderLabel: function(options) {
                if (utils.isDefined(options.text) && options.text.length > 0) {
                    var labelClasses = FIELD_ITEM_LABEL_CLASS + " " + FIELD_ITEM_LABEL_LOCATION_CLASS + options.location,
                        $label = $("<label />").addClass(labelClasses).attr("for", options.id),
                        $labelContent = $("<span/>").addClass(FIELD_ITEM_LABEL_CONTENT_CLASS).appendTo($label);
                    $("<span />").addClass(FIELD_ITEM_LABEL_TEXT_CLASS).text(options.text).appendTo($labelContent);
                    if (options.alignment) {
                        $label.css("text-align", options.alignment)
                    }
                    $labelContent.append(this._renderLabelMark(options.isRequired));
                    return $label
                }
            },
            _renderLabelMark: function(isRequired) {
                var $mark, requiredMarksConfig = this._getRequiredMarksConfig(),
                    isRequiredMark = requiredMarksConfig.showRequiredMark && isRequired,
                    isOptionalMark = requiredMarksConfig.showOptionalMark && !isRequired;
                if (isRequiredMark || isOptionalMark) {
                    var markClass = isRequiredMark ? FIELD_ITEM_REQUIRED_MARK_CLASS : FIELD_ITEM_OPTIONAL_MARK_CLASS,
                        markText = isRequiredMark ? requiredMarksConfig.requiredMark : requiredMarksConfig.optionalMark;
                    $mark = $("<span />").addClass(markClass).html("&nbsp" + markText)
                }
                return $mark
            },
            _getRequiredMarksConfig: function() {
                if (!this._cashedRequiredConfig) {
                    this._cashedRequiredConfig = {
                        showRequiredMark: this.option("showRequiredMark"),
                        showOptionalMark: this.option("showOptionalMark"),
                        requiredMark: this.option("requiredMark"),
                        optionalMark: this.option("optionalMark")
                    }
                }
                return this._cashedRequiredConfig
            },
            _renderEditor: function(options) {
                var editorOptions, dataValue = this._getDataByField(options.dataField),
                    defaultEditorOptions = {
                        value: dataValue
                    },
                    isDeepExtend = true;
                if ("dxTagBox" === options.editorType) {
                    defaultEditorOptions.value = defaultEditorOptions.value || []
                }
                editorOptions = $.extend(isDeepExtend, defaultEditorOptions, options.editorOptions, {
                    attr: {
                        id: options.id
                    },
                    validationBoundary: options.validationBoundary
                });
                this._createEditor(options.$container, {
                    editorType: options.editorType,
                    dataField: options.dataField,
                    template: options.template,
                    name: options.name,
                    helpID: options.helpID,
                    isRequired: options.isRequired
                }, editorOptions)
            },
            _renderValidator: function($editor, item) {
                var fieldName = this._getFieldLabelName(item),
                    validationRules = this._prepareValidationRules(item.validationRules, item.isRequired, item.itemType, fieldName);
                if (utils.isArray(validationRules)) {
                    this._createComponent($editor, Validator, {
                        validationRules: validationRules,
                        validationGroup: this.option("form")
                    })
                }
            },
            _getFieldLabelName: function(item) {
                var isItemHaveCustomLabel = item.label && item.label.text,
                    itemName = isItemHaveCustomLabel ? null : this._getName(item);
                return isItemHaveCustomLabel ? item.label.text : itemName && inflector.captionize(itemName)
            },
            _prepareValidationRules: function(userValidationRules, isItemRequired, itemType, itemName) {
                var validationRules, isSimpleItem = "simple" === itemType;
                if (isSimpleItem) {
                    if (userValidationRules) {
                        validationRules = userValidationRules
                    } else {
                        var requiredMessage = stringUtils.format(this.option("requiredMessage"), itemName || "");
                        validationRules = isItemRequired ? [{
                            type: "required",
                            message: requiredMessage
                        }] : null
                    }
                }
                return validationRules
            },
            _createEditor: function($container, renderOptions, editorOptions) {
                var editorInstance, that = this,
                    template = renderOptions.template;
                that._addItemContentClasses($container);
                if (template) {
                    var data = {
                        dataField: renderOptions.dataField,
                        editorOptions: editorOptions,
                        component: template.owner()
                    };
                    template.render({
                        model: data,
                        container: $container
                    })
                } else {
                    var $editor = $("<div/>").appendTo($container);
                    try {
                        editorInstance = that._createComponent($editor, renderOptions.editorType, editorOptions);
                        editorInstance.setAria("describedby", renderOptions.helpID);
                        editorInstance.setAria("required", renderOptions.isRequired);
                        if (renderOptions.dataField) {
                            var componentOwner = that.option("form") || that;
                            editorInstance.on("enterKey", function(args) {
                                componentOwner._createActionByOption("onEditorEnterKey")($.extend(args, {
                                    dataField: renderOptions.dataField
                                }))
                            });
                            that._registerEditorInstance(editorInstance, renderOptions.dataField);
                            that.linkEditorToDataField(editorInstance, renderOptions.dataField, renderOptions.editorType)
                        }
                    } catch (e) {
                        errors.log("E1035", e.message)
                    }
                }
            },
            _addItemContentClasses: function($itemContent) {
                var locationSpecificClass = this._getItemContentLocationSpecificClass();
                $itemContent.addClass([FIELD_ITEM_CONTENT_CLASS, locationSpecificClass].join(" "))
            },
            _getItemContentLocationSpecificClass: function() {
                var labelLocation = this.option("labelLocation"),
                    oppositeClasses = {
                        right: "left",
                        left: "right",
                        top: "bottom"
                    };
                return FIELD_ITEM_CONTENT_LOCATION_CLASS + oppositeClasses[labelLocation]
            },
            _registerEditorInstance: function(instance, dataField) {
                this._editorInstancesByField[dataField] = instance
            },
            _createComponent: function($editor, type, editorOptions) {
                var instance, that = this,
                    readOnlyState = this.option("readOnly");
                instance = that.callBase($editor, type, editorOptions);
                readOnlyState && instance.option("readOnly", readOnlyState);
                that.on("optionChanged", function(args) {
                    if ("readOnly" === args.name) {
                        instance.option(args.name, args.value)
                    }
                });
                return instance
            },
            _getTemplateByFieldItem: function(fieldItem) {
                return fieldItem.template ? this._getTemplate(fieldItem.template) : null
            },
            _appendEditorToField: function(params) {
                if (params.$label) {
                    var location = params.labelOptions.location;
                    if ("top" === location || "left" === location) {
                        params.$fieldItem.append(params.$editor)
                    }
                    if ("right" === location) {
                        params.$fieldItem.prepend(params.$editor)
                    }
                    this._addInnerItemAlignmentClass(params.$fieldItem, location)
                } else {
                    params.$fieldItem.append(params.$editor)
                }
            },
            _addInnerItemAlignmentClass: function($fieldItem, location) {
                if ("top" === location) {
                    $fieldItem.addClass(LABEL_VERTICAL_ALIGNMENT_CLASS)
                } else {
                    $fieldItem.addClass(LABEL_HORIZONTAL_ALIGNMENT_CLASS)
                }
            },
            _renderHelpText: function(fieldItem, $editor, helpID) {
                var helpText = fieldItem.helpText;
                if (helpText) {
                    var $editorWrapper = $("<div>").addClass(FIELD_ITEM_CONTENT_WRAPPER_CLASS);
                    $editor.wrap($editorWrapper);
                    $("<div>").addClass(FIELD_ITEM_HELP_TEXT_CLASS).attr("id", helpID).text(helpText).appendTo($editor.parent())
                }
            },
            _attachClickHandler: function($label, $editor, editorType) {
                var isBooleanEditors = "dxCheckBox" === editorType || "dxSwitch" === editorType;
                if ($label && isBooleanEditors) {
                    $label.on(clickEvent.name, function() {
                        $editor.children().trigger(clickEvent.name)
                    })
                }
            },
            _generateRatio: function(count, isAutoSize) {
                var ratio, i, result = [];
                for (i = 0; i < count; i++) {
                    ratio = {
                        ratio: 1
                    };
                    if (isAutoSize) {
                        ratio.baseSize = "auto"
                    }
                    result.push(ratio)
                }
                return result
            },
            _getRowsCount: function() {
                return Math.ceil(this._items.length / this._getColCount())
            },
            _optionChanged: function(args) {
                if (0 === args.fullName.search("layoutData.")) {
                    return
                }
                switch (args.name) {
                    case "showRequiredMark":
                    case "showOptionalMark":
                    case "requiredMark":
                    case "optionalMark":
                        this._cashedRequiredConfig = null;
                        this._invalidate();
                        break;
                    case "layoutData":
                    case "items":
                        this._syncDataWithItems();
                        this._updateItems(args.value);
                        this._invalidate();
                        break;
                    case "alignItemLabels":
                    case "labelLocation":
                    case "requiredMessage":
                        this._invalidate();
                        break;
                    case "customizeItem":
                        this._updateItems(this.option("layoutData"));
                        this._invalidate();
                        break;
                    case "colCount":
                        this._resetColCount();
                        break;
                    case "minColWidth":
                        if ("auto" === this.option("colCount")) {
                            this._resetColCount()
                        }
                        break;
                    case "readOnly":
                        break;
                    case "width":
                        this.callBase(args);
                        if ("auto" === this.option("colCount")) {
                            this._resetColCount()
                        }
                        break;
                    case "onFieldDataChanged":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _resetColCount: function() {
                this._cashedColCount = null;
                this._invalidate()
            },
            linkEditorToDataField: function(editorInstance, dataField, editorType) {
                var fullFieldName = "layoutData." + dataField,
                    that = this;
                that.on("optionChanged", function(args) {
                    if (args.fullName === fullFieldName) {
                        switch (editorType) {
                            case "dxTagBox":
                            case "dxSelectBox":
                                that._managedUpdateEditorOption(editorInstance, "value", args.value);
                                break;
                            default:
                                editorInstance.option("value", args.value)
                        }
                    }
                });
                editorInstance.on("valueChanged", function(args) {
                    switch (editorType) {
                        case "dxTagBox":
                        case "dxSelectBox":
                            that._managedUpdateFieldValue(dataField, args.value);
                            break;
                        default:
                            that._updateFieldValue(dataField, args.value)
                    }
                })
            },
            _managedUpdateEditorOption: function(editorInstance, optionName, value) {
                if (!this._isValueChangedCalled) {
                    this._isFieldValueChanged = true;
                    editorInstance.option(optionName, value);
                    this._isFieldValueChanged = false
                }
            },
            _managedUpdateFieldValue: function(dataField, value) {
                this._isValueChangedCalled = true;
                if (!this._isFieldValueChanged) {
                    this._updateFieldValue(dataField, value)
                }
                this._isValueChangedCalled = false
            },
            getItemID: function(name) {
                var formInstance = this.option("form"),
                    formID = formInstance && formInstance.option("formID");
                return "dx_" + formID + "_" + (name || new Guid)
            },
            updateData: function(data, value) {
                var that = this;
                if (utils.isObject(data)) {
                    $.each(data, function(dataField, fieldValue) {
                        that._updateFieldValue(dataField, fieldValue)
                    })
                } else {
                    if ("string" === typeof data) {
                        that._updateFieldValue(data, value)
                    }
                }
            },
            getEditor: function(field) {
                return this._editorInstancesByField[field]
            },
            isLayoutChanged: function(component) {
                var responsiveBox = this._responsiveBox || component;
                if (responsiveBox) {
                    return responsiveBox.option("currentScreenFactor") === responsiveBox.option("singleColumnScreen")
                }
            }
        });
        registerComponent("dxLayoutManager", LayoutManager);
        module.exports = LayoutManager;
        module.exports.__internals = {
            FIELD_ITEM_CLASS: FIELD_ITEM_CLASS,
            FIELD_EMPTY_ITEM_CLASS: FIELD_EMPTY_ITEM_CLASS,
            FIELD_ITEM_CONTENT_CLASS: FIELD_ITEM_CONTENT_CLASS,
            FIELD_ITEM_CONTENT_LOCATION_CLASS: FIELD_ITEM_CONTENT_LOCATION_CLASS,
            FIELD_ITEM_LABEL_CLASS: FIELD_ITEM_LABEL_CLASS,
            FIELD_ITEM_LABEL_ALIGN_CLASS: FIELD_ITEM_LABEL_ALIGN_CLASS,
            FIELD_ITEM_LABEL_LOCATION_CLASS: FIELD_ITEM_LABEL_LOCATION_CLASS,
            LABEL_HORIZONTAL_ALIGNMENT_CLASS: LABEL_HORIZONTAL_ALIGNMENT_CLASS,
            LABEL_VERTICAL_ALIGNMENT_CLASS: LABEL_VERTICAL_ALIGNMENT_CLASS,
            FORM_LAYOUT_MANAGER_CLASS: FORM_LAYOUT_MANAGER_CLASS,
            FIELD_ITEM_CONTENT_WRAPPER_CLASS: FIELD_ITEM_CONTENT_WRAPPER_CLASS,
            FIELD_ITEM_HELP_TEXT_CLASS: FIELD_ITEM_HELP_TEXT_CLASS,
            FIELD_ITEM_LABEL_CONTENT_CLASS: FIELD_ITEM_LABEL_CONTENT_CLASS,
            FIELD_ITEM_LABEL_TEXT_CLASS: FIELD_ITEM_LABEL_TEXT_CLASS,
            FIELD_ITEM_REQUIRED_CLASS: FIELD_ITEM_REQUIRED_CLASS,
            FIELD_ITEM_OPTIONAL_CLASS: FIELD_ITEM_OPTIONAL_CLASS,
            FIELD_ITEM_REQUIRED_MARK_CLASS: FIELD_ITEM_REQUIRED_MARK_CLASS,
            FIELD_ITEM_OPTIONAL_MARK_CLASS: FIELD_ITEM_OPTIONAL_MARK_CLASS,
            LAYOUT_MANAGER_ONE_COLUMN: LAYOUT_MANAGER_ONE_COLUMN,
            FLEX_LAYOUT_CLASS: FLEX_LAYOUT_CLASS
        }
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/validator.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ./widget/ui.errors */ 10),
            DOMComponent = __webpack_require__( /*! ../core/dom_component */ 29),
            ValidationMixin = __webpack_require__( /*! ./validation/validation_mixin */ 108),
            ValidationEngine = __webpack_require__( /*! ./validation_engine */ 117),
            DefaultAdapter = __webpack_require__( /*! ./validation/default_adapter */ 280),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43);
        var VALIDATOR_CLASS = "dx-validator";
        var Validator = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    validationRules: []
                })
            },
            _init: function() {
                this.callBase();
                this._initGroupRegistration();
                this.focused = $.Callbacks();
                this._initAdapter()
            },
            _initGroupRegistration: function() {
                var group = this._findGroup();
                if (!this._groupWasInit) {
                    this.on("disposing", function(args) {
                        ValidationEngine.removeRegisteredValidator(args.component._validationGroup, args.component)
                    })
                }
                if (!this._groupWasInit || this._validationGroup !== group) {
                    ValidationEngine.removeRegisteredValidator(this._validationGroup, this);
                    this._groupWasInit = true;
                    this._validationGroup = group;
                    ValidationEngine.registerValidatorInGroup(group, this)
                }
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    validationGroup: true
                })
            },
            _initAdapter: function() {
                var that = this,
                    element = that.element()[0],
                    dxStandardEditor = $.data(element, "dx-validation-target"),
                    adapter = that.option("adapter");
                if (!adapter) {
                    if (dxStandardEditor) {
                        adapter = new DefaultAdapter(dxStandardEditor, this);
                        adapter.validationRequestsCallbacks.add(function() {
                            that.validate()
                        });
                        this.option("adapter", adapter);
                        return
                    }
                    throw errors.Error("E0120")
                }
                if (adapter.validationRequestsCallbacks) {
                    adapter.validationRequestsCallbacks.add(function() {
                        that.validate()
                    })
                }
            },
            _render: function() {
                this.element().addClass(VALIDATOR_CLASS);
                this.callBase()
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._initGroupRegistration()
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "validationGroup":
                        this._initGroupRegistration();
                        return;
                    case "validationRules":
                        void 0 !== this.option("isValid") && this.validate();
                        return;
                    case "adapter":
                        this._initAdapter();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            validate: function() {
                var result, that = this,
                    adapter = that.option("adapter"),
                    name = that.option("name"),
                    bypass = adapter.bypass && adapter.bypass(),
                    value = adapter.getValue(),
                    currentError = adapter.getCurrentValidationError && adapter.getCurrentValidationError(),
                    rules = $.map(that.option("validationRules"), function(rule) {
                        rule.validator = that;
                        return rule
                    });
                if (bypass) {
                    result = {
                        isValid: true
                    }
                } else {
                    if (currentError && currentError.editorSpecific) {
                        currentError.validator = this;
                        result = {
                            isValid: false,
                            brokenRule: currentError
                        }
                    } else {
                        result = ValidationEngine.validate(value, rules, name)
                    }
                }
                this._applyValidationResult(result, adapter);
                return result
            },
            reset: function() {
                var that = this,
                    adapter = that.option("adapter"),
                    result = {
                        isValid: true,
                        brokenRule: null
                    };
                adapter.reset();
                this._applyValidationResult(result, adapter)
            },
            _applyValidationResult: function(result, adapter) {
                var validatedAction = this._createActionByOption("onValidated");
                result.validator = this;
                adapter.applyValidationResults && adapter.applyValidationResults(result);
                this.option({
                    isValid: result.isValid
                });
                validatedAction(result)
            },
            focus: function() {
                var adapter = this.option("adapter");
                adapter.focus()
            }
        }).include(ValidationMixin);
        registerComponent("dxValidator", Validator);
        module.exports = Validator
    },
    /*!**************************************************!*\
      !*** ./Scripts/ui/validation/default_adapter.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20);
        var DefaultAdapter = Class.inherit({
            ctor: function(editor, validator) {
                var that = this;
                that.editor = editor;
                that.validator = validator;
                that.validationRequestsCallbacks = $.Callbacks();
                var handler = function(params) {
                    that.validationRequestsCallbacks.fire()
                };
                editor.validationRequest.add(handler);
                editor.on("disposing", function() {
                    editor.validationRequest.remove(handler)
                })
            },
            getValue: function() {
                return this.editor.option("value")
            },
            getCurrentValidationError: function() {
                return this.editor.option("validationError")
            },
            bypass: function() {
                return this.editor.option("disabled")
            },
            applyValidationResults: function(params) {
                this.editor.option({
                    isValid: params.isValid,
                    validationError: params.brokenRule
                })
            },
            reset: function() {
                this.editor.reset()
            },
            focus: function() {
                this.editor.focus()
            }
        });
        module.exports = DefaultAdapter
    },
    /*!**************************************!*\
      !*** ./Scripts/ui/responsive_box.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ./widget/ui.errors */ 10),
            windowUtils = __webpack_require__( /*! ../core/utils/window */ 30),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Box = __webpack_require__( /*! ./box */ 245),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151);
        var RESPONSIVE_BOX_CLASS = "dx-responsivebox",
            SCREEN_SIZE_CLASS_PREFIX = RESPONSIVE_BOX_CLASS + "-screen-",
            BOX_ITEM_CLASS = "dx-box-item",
            BOX_ITEM_DATA_KEY = "dxBoxItemData";
        var ResponsiveBox = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    rows: [],
                    cols: [],
                    screenByWidth: null,
                    singleColumnScreen: "",
                    height: "100%",
                    width: "100%",
                    activeStateEnabled: false,
                    focusStateEnabled: false,
                    onLayoutChanged: null,
                    currentScreenFactor: void 0,
                    _layoutStrategy: void 0
                })
            },
            _init: function() {
                if (!this.option("screenByWidth")) {
                    this._options.screenByWidth = windowUtils.defaultScreenFactorFunc
                }
                this.callBase();
                this._initLayoutChangedAction()
            },
            _initLayoutChangedAction: function() {
                this._layoutChangedAction = this._createActionByOption("onLayoutChanged", {
                    excludeValidators: ["disabled", "readonly"]
                })
            },
            _itemClass: function() {
                return BOX_ITEM_CLASS
            },
            _itemDataKey: function() {
                return BOX_ITEM_DATA_KEY
            },
            _render: function() {
                this.callBase();
                this.element().addClass(RESPONSIVE_BOX_CLASS);
                this._updateRootBox()
            },
            _updateRootBox: function() {
                clearTimeout(this._updateTimer);
                this._updateTimer = setTimeout($.proxy(function() {
                    if (this._$root) {
                        this._$root.trigger("dxupdate")
                    }
                }, this))
            },
            _renderItems: function() {
                this._setScreenSize();
                this._screenItems = this._itemsByScreen();
                this._prepareGrid();
                this._spreadItems();
                this._layoutItems();
                this._linkNodeToItem()
            },
            _setScreenSize: function() {
                var currentScreen = this._getCurrentScreen();
                this._removeScreenSizeClass();
                this.element().addClass(SCREEN_SIZE_CLASS_PREFIX + currentScreen);
                this.option("currentScreenFactor", currentScreen)
            },
            _removeScreenSizeClass: function() {
                var currentScreenFactor = this.option("currentScreenFactor");
                currentScreenFactor && this.element().removeClass(SCREEN_SIZE_CLASS_PREFIX + currentScreenFactor)
            },
            _prepareGrid: function() {
                var grid = this._grid = [];
                this._prepareRowsAndCols();
                $.each(this._rows, $.proxy(function() {
                    var row = [];
                    grid.push(row);
                    $.each(this._cols, $.proxy(function() {
                        row.push(this._createEmptyCell())
                    }, this))
                }, this))
            },
            _prepareRowsAndCols: function() {
                if (this._isSingleColumnScreen()) {
                    this._prepareSingleColumnScreenItems();
                    this._rows = this._defaultSizeConfig(this._screenItems.length);
                    this._cols = this._defaultSizeConfig(1)
                } else {
                    this._rows = this._sizesByScreen(this.option("rows"));
                    this._cols = this._sizesByScreen(this.option("cols"))
                }
            },
            _isSingleColumnScreen: function() {
                return this._screenRegExp().test(this.option("singleColumnScreen")) || !this.option("rows").length || !this.option("cols").length
            },
            _prepareSingleColumnScreenItems: function() {
                this._screenItems.sort(function(item1, item2) {
                    return item1.location.row - item2.location.row || item1.location.col - item2.location.col
                });
                $.each(this._screenItems, function(index, item) {
                    $.extend(item.location, {
                        row: index,
                        col: 0,
                        rowspan: 1,
                        colspan: 1
                    })
                })
            },
            _sizesByScreen: function(sizeConfigs) {
                return $.map(this._filterByScreen(sizeConfigs), $.proxy(function(sizeConfig) {
                    return $.extend(this._defaultSizeConfig(), sizeConfig)
                }, this))
            },
            _defaultSizeConfig: function(size) {
                var defaultSizeConfig = {
                    ratio: 1,
                    baseSize: 0,
                    minSize: 0,
                    maxSize: 0
                };
                if (!arguments.length) {
                    return defaultSizeConfig
                }
                var result = [];
                for (var i = 0; i < size; i++) {
                    result.push(defaultSizeConfig)
                }
                return result
            },
            _filterByScreen: function(items) {
                var screenRegExp = this._screenRegExp();
                return $.grep(items, function(item) {
                    return !item.screen || screenRegExp.test(item.screen)
                })
            },
            _screenRegExp: function() {
                var screen = this._getCurrentScreen();
                return new RegExp("(^|\\s)" + screen + "($|\\s)", "i")
            },
            _getCurrentScreen: function() {
                var width = this._screenWidth();
                return this.option("screenByWidth")(width)
            },
            _screenWidth: function() {
                return $(window).width()
            },
            _createEmptyCell: function() {
                return {
                    item: {},
                    location: {
                        colspan: 1,
                        rowspan: 1
                    }
                }
            },
            _spreadItems: function() {
                $.each(this._screenItems, $.proxy(function(_, itemInfo) {
                    var location = itemInfo.location || {};
                    var itemCol = location.col;
                    var itemRow = location.row;
                    var row = this._grid[itemRow];
                    var itemCell = row && row[itemCol];
                    this._occupyCells(itemCell, itemInfo)
                }, this))
            },
            _itemsByScreen: function() {
                return $.map(this.option("items"), $.proxy(function(item) {
                    var locations = item.location || {};
                    locations = $.isPlainObject(locations) ? [locations] : locations;
                    return $.map(this._filterByScreen(locations), function(location) {
                        return {
                            item: item,
                            location: $.extend({
                                rowspan: 1,
                                colspan: 1
                            }, location)
                        }
                    })
                }, this))
            },
            _occupyCells: function(itemCell, itemInfo) {
                if (!itemCell || this._isItemCellOccupied(itemCell, itemInfo)) {
                    return
                }
                $.extend(itemCell, itemInfo);
                this._markSpanningCell(itemCell)
            },
            _isItemCellOccupied: function(itemCell, itemInfo) {
                if (!$.isEmptyObject(itemCell.item)) {
                    return true
                }
                var result = false;
                this._loopOverSpanning(itemInfo.location, function(cell) {
                    result = result || !$.isEmptyObject(cell.item)
                });
                return result
            },
            _loopOverSpanning: function(location, callback) {
                var rowEnd = location.row + location.rowspan - 1;
                var colEnd = location.col + location.colspan - 1;
                var boundRowEnd = Math.min(rowEnd, this._rows.length - 1);
                var boundColEnd = Math.min(colEnd, this._cols.length - 1);
                location.rowspan -= rowEnd - boundRowEnd;
                location.colspan -= colEnd - boundColEnd;
                for (var rowIndex = location.row; rowIndex <= boundRowEnd; rowIndex++) {
                    for (var colIndex = location.col; colIndex <= boundColEnd; colIndex++) {
                        if (rowIndex !== location.row || colIndex !== location.col) {
                            callback(this._grid[rowIndex][colIndex])
                        }
                    }
                }
            },
            _markSpanningCell: function(itemCell) {
                this._loopOverSpanning(itemCell.location, function(cell) {
                    $.extend(cell, {
                        item: itemCell.item,
                        spanningCell: itemCell
                    })
                })
            },
            _linkNodeToItem: function() {
                $.each(this._itemElements(), function(_, itemNode) {
                    var $item = $(itemNode),
                        item = $item.data(BOX_ITEM_DATA_KEY);
                    if (!item.box) {
                        item.node = $item.children()
                    }
                })
            },
            _layoutItems: function() {
                var rowsCount = this._grid.length;
                var colsCount = rowsCount && this._grid[0].length;
                if (!rowsCount && !colsCount) {
                    return
                }
                var result = this._layoutBlock({
                    direction: "col",
                    row: {
                        start: 0,
                        end: rowsCount - 1
                    },
                    col: {
                        start: 0,
                        end: colsCount - 1
                    }
                });
                var rootBox = this._prepareBoxConfig(result.box || {
                    direction: "row",
                    items: [$.extend(result, {
                        ratio: 1
                    })]
                });
                $.extend(rootBox, this._rootBoxConfig());
                this._$root = $("<div>").appendTo(this._itemContainer());
                this._createComponent(this._$root, Box, rootBox)
            },
            _rootBoxConfig: function(config) {
                return $.extend({
                    width: "100%",
                    height: "100%",
                    itemTemplate: this.option("itemTemplate"),
                    itemHoldTimeout: this.option("itemHoldTimeout"),
                    onItemHold: this.option("onItemHold"),
                    onItemClick: this.option("onItemClick"),
                    onItemContextMenu: this.option("onItemContextMenu"),
                    onItemRendered: this.option("onItemRendered")
                }, {
                    _layoutStrategy: this.option("_layoutStrategy")
                })
            },
            _prepareBoxConfig: function(config) {
                return $.extend(config || {}, {
                    crossAlign: "stretch"
                })
            },
            _layoutBlock: function(options) {
                if (this._isSingleItem(options)) {
                    return this._itemByCell(options.row.start, options.col.start)
                }
                return this._layoutDirection(options)
            },
            _isSingleItem: function(options) {
                var firstCellLocation = this._grid[options.row.start][options.col.start].location;
                var isItemRowSpanned = options.row.end - options.row.start === firstCellLocation.rowspan - 1;
                var isItemColSpanned = options.col.end - options.col.start === firstCellLocation.colspan - 1;
                return isItemRowSpanned && isItemColSpanned
            },
            _itemByCell: function(rowIndex, colIndex) {
                var itemCell = this._grid[rowIndex][colIndex];
                return itemCell.spanningCell ? null : itemCell.item
            },
            _layoutDirection: function(options) {
                var items = [];
                var direction = options.direction;
                var crossDirection = this._crossDirection(direction);
                var block;
                while (block = this._nextBlock(options)) {
                    if (this._isBlockIndivisible(options.prevBlockOptions, block)) {
                        throw errors.Error("E1025")
                    }
                    var item = this._layoutBlock({
                        direction: crossDirection,
                        row: block.row,
                        col: block.col,
                        prevBlockOptions: options
                    });
                    if (item) {
                        $.extend(item, this._blockSize(block, crossDirection));
                        items.push(item)
                    }
                    options[crossDirection].start = block[crossDirection].end + 1
                }
                return {
                    box: this._prepareBoxConfig({
                        direction: direction,
                        items: items
                    })
                }
            },
            _isBlockIndivisible: function(options, block) {
                return options && options.col.start === block.col.start && options.col.end === block.col.end && options.row.start === block.row.start && options.row.end === block.row.end
            },
            _crossDirection: function(direction) {
                return "col" === direction ? "row" : "col"
            },
            _nextBlock: function(options) {
                var direction = options.direction;
                var crossDirection = this._crossDirection(direction);
                var startIndex = options[direction].start;
                var endIndex = options[direction].end;
                var crossStartIndex = options[crossDirection].start;
                if (crossStartIndex > options[crossDirection].end) {
                    return null
                }
                var crossSpan = 1;
                for (var crossIndex = crossStartIndex; crossIndex < crossStartIndex + crossSpan; crossIndex++) {
                    var lineCrossSpan = 1;
                    for (var index = startIndex; index <= endIndex; index++) {
                        var cell = this._cellByDirection(direction, index, crossIndex);
                        lineCrossSpan = Math.max(lineCrossSpan, cell.location[crossDirection + "span"])
                    }
                    var lineCrossEndIndex = crossIndex + lineCrossSpan;
                    var crossEndIndex = crossStartIndex + crossSpan;
                    if (lineCrossEndIndex > crossEndIndex) {
                        crossSpan += lineCrossEndIndex - crossEndIndex
                    }
                }
                var result = {};
                result[direction] = {
                    start: startIndex,
                    end: endIndex
                };
                result[crossDirection] = {
                    start: crossStartIndex,
                    end: crossStartIndex + crossSpan - 1
                };
                return result
            },
            _cellByDirection: function(direction, index, crossIndex) {
                return "col" === direction ? this._grid[crossIndex][index] : this._grid[index][crossIndex]
            },
            _blockSize: function(block, direction) {
                var sizeConfigs = "row" === direction ? this._rows : this._cols;
                var result = {
                    ratio: 0,
                    baseSize: 0,
                    minSize: 0,
                    maxSize: 0
                };
                for (var index = block[direction].start; index <= block[direction].end; index++) {
                    var sizeConfig = sizeConfigs[index];
                    result.ratio += sizeConfig.ratio;
                    result.baseSize += sizeConfig.baseSize;
                    result.minSize += sizeConfig.minSize;
                    result.maxSize += sizeConfig.maxSize
                }
                result.minSize = result.minSize ? result.minSize : "auto";
                result.maxSize = result.maxSize ? result.maxSize : "auto";
                this._isSingleColumnScreen() && (result.baseSize = "auto");
                return result
            },
            _update: function() {
                var $existingRoot = this._$root;
                this._renderItems();
                $existingRoot && $existingRoot.detach();
                this._saveAssistantRoot($existingRoot);
                this._layoutChangedAction();
                this._updateRootBox()
            },
            _saveAssistantRoot: function($root) {
                this._assistantRoots = this._assistantRoots || [];
                this._assistantRoots.push($root)
            },
            _dispose: function() {
                clearTimeout(this._updateTimer);
                this._cleanUnusedRoots();
                this.callBase.apply(this, arguments)
            },
            _cleanUnusedRoots: function() {
                if (!this._assistantRoots) {
                    return
                }
                $.each(this._assistantRoots, function() {
                    $(this).remove()
                })
            },
            _clearItemNodeTemplates: function() {
                $.each(this.option("items"), function() {
                    delete this.node
                })
            },
            _toggleVisibility: function(visible) {
                this.callBase(visible);
                if (visible) {
                    this._updateRootBox()
                }
            },
            _attachClickEvent: $.noop,
            _optionChanged: function(args) {
                switch (args.name) {
                    case "rows":
                    case "cols":
                    case "screenByWidth":
                    case "_layoutStrategy":
                    case "singleColumnScreen":
                        this._clearItemNodeTemplates();
                        this._invalidate();
                        break;
                    case "width":
                    case "height":
                        this.callBase(args);
                        this._update();
                        break;
                    case "onLayoutChanged":
                        this._initLayoutChangedAction();
                        break;
                    case "itemTemplate":
                        this._clearItemNodeTemplates();
                        this.callBase(args);
                        break;
                    case "currentScreenFactor":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _dimensionChanged: function() {
                if (this._getCurrentScreen() !== this.option("currentScreenFactor")) {
                    this._update()
                }
            },
            repaint: function() {
                this._update()
            }
        });
        registerComponent("dxResponsiveBox", ResponsiveBox);
        module.exports = ResponsiveBox
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/tab_panel.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            support = __webpack_require__( /*! ../core/utils/support */ 48),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            MultiView = __webpack_require__( /*! ./multi_view */ 283),
            Tabs = __webpack_require__( /*! ./tabs */ 284);
        var TABPANEL_CLASS = "dx-tabpanel",
            TABPANEL_TABS_CLASS = "dx-tabpanel-tabs",
            TABPANEL_CONTAINER_CLASS = "dx-tabpanel-container";
        var TabPanel = MultiView.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    itemTitleTemplate: "title",
                    hoverStateEnabled: true,
                    showNavButtons: false,
                    scrollByContent: true,
                    scrollingEnabled: true,
                    onTitleClick: null,
                    onTitleHold: null,
                    onTitleRendered: null
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function(device) {
                        return !support.touch
                    },
                    options: {
                        swipeEnabled: false
                    }
                }, {
                    device: {
                        platform: "generic"
                    },
                    options: {
                        animationEnabled: false
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this.element().addClass(TABPANEL_CLASS);
                this.setAria("role", "tabpanel");
                this._renderLayout()
            },
            _renderContent: function() {
                var that = this;
                this.callBase();
                if (this.option("templatesRenderAsynchronously")) {
                    this._resizeEventTimer = setTimeout(function() {
                        that._updateLayout()
                    }, 0)
                }
            },
            _renderLayout: function() {
                var $element = this.element();
                this._$tabContainer = $("<div>").addClass(TABPANEL_TABS_CLASS).appendTo($element);
                var $tabs = $("<div>").appendTo(this._$tabContainer);
                this._tabs = this._createComponent($tabs, Tabs, this._tabConfig());
                this._$container = $("<div>").addClass(TABPANEL_CONTAINER_CLASS).appendTo($element);
                this._$container.append(this._$wrapper);
                this._updateLayout()
            },
            _updateLayout: function() {
                var tabsHeight = this._$tabContainer.outerHeight();
                this._$container.css({
                    "margin-top": -tabsHeight,
                    "padding-top": tabsHeight
                })
            },
            _refreshActiveDescendant: function() {
                var tabs = this._tabs,
                    tabItems = tabs.itemElements(),
                    $activeTab = $(tabItems[tabs.option("selectedIndex")]),
                    id = this.getFocusedItemId();
                this.setAria("controls", void 0, $(tabItems));
                this.setAria("controls", id, $activeTab)
            },
            _tabConfig: function() {
                return {
                    selectOnFocus: true,
                    focusStateEnabled: this.option("focusStateEnabled"),
                    hoverStateEnabled: this.option("hoverStateEnabled"),
                    tabIndex: this.option("tabIndex"),
                    selectedIndex: this.option("selectedIndex"),
                    onItemClick: this.option("onTitleClick"),
                    onItemHold: this.option("onTitleHold"),
                    itemHoldTimeout: this.option("itemHoldTimeout"),
                    onSelectionChanged: $.proxy(function(e) {
                        this.option("selectedIndex", e.component.option("selectedIndex"));
                        this._refreshActiveDescendant()
                    }, this),
                    onItemRendered: this.option("onTitleRendered"),
                    itemTemplate: this._getTemplateByOption("itemTitleTemplate"),
                    items: this.option("items"),
                    noDataText: null,
                    scrollingEnabled: this.option("scrollingEnabled"),
                    scrollByContent: this.option("scrollByContent"),
                    showNavButtons: this.option("showNavButtons"),
                    itemTemplateProperty: "tabTemplate",
                    loopItemFocus: this.option("loop"),
                    selectionRequired: true,
                    onOptionChanged: $.proxy(function(args) {
                        var name = args.name,
                            value = args.value;
                        if ("focusedElement" === name) {
                            var id = value ? value.index() : value;
                            var newItem = value ? this._itemElements().eq(id) : value;
                            this.option("focusedElement", newItem)
                        }
                    }, this),
                    onFocusIn: $.proxy(function(args) {
                        this._focusInHandler(args.jQueryEvent)
                    }, this),
                    onFocusOut: $.proxy(function(args) {
                        this._focusOutHandler(args.jQueryEvent)
                    }, this)
                }
            },
            _renderFocusTarget: function() {
                this._focusTarget().attr("tabindex", -1);
                this._refreshActiveDescendant()
            },
            _updateFocusState: function(e, isFocused) {
                this.callBase(e, isFocused);
                if (e.target === this._tabs._focusTarget().get(0)) {
                    this._toggleFocusClass(isFocused, this._focusTarget())
                }
            },
            _setTabsOption: function(name, value) {
                if (this._tabs) {
                    this._tabs.option(name, value)
                }
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._tabs._dimensionChanged();
                    this._updateLayout()
                }
            },
            _optionChanged: function(args) {
                var name = args.name,
                    value = args.value;
                switch (name) {
                    case "dataSource":
                        this.callBase(args);
                        break;
                    case "items":
                        this._setTabsOption(name, value);
                        this._updateLayout();
                        this.callBase(args);
                        break;
                    case "selectedIndex":
                    case "selectedItem":
                    case "itemHoldTimeout":
                    case "focusStateEnabled":
                    case "hoverStateEnabled":
                        this._setTabsOption(name, value);
                        this.callBase(args);
                        break;
                    case "scrollingEnabled":
                    case "scrollByContent":
                    case "showNavButtons":
                        this._setTabsOption(name, value);
                        break;
                    case "focusedElement":
                        var id = value ? value.index() : value;
                        var newItem = value ? this._tabs._itemElements().eq(id) : value;
                        this._setTabsOption("focusedElement", newItem);
                        this.callBase(args);
                        this._tabs.focus();
                        break;
                    case "itemTitleTemplate":
                        this._setTabsOption("itemTemplate", this._getTemplateByOption("itemTitleTemplate"));
                        break;
                    case "onTitleClick":
                        this._setTabsOption("onItemClick", value);
                        break;
                    case "onTitleHold":
                        this._setTabsOption("onItemHold", value);
                        break;
                    case "onTitleRendered":
                        this._setTabsOption("onItemRendered", value);
                        break;
                    case "loop":
                        this._setTabsOption("loopItemFocus", value);
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _clean: function() {
                clearTimeout(this._resizeEventTimer);
                this.callBase()
            }
        });
        registerComponent("dxTabPanel", TabPanel);
        module.exports = TabPanel
    },
    /*!**********************************!*\
      !*** ./Scripts/ui/multi_view.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            mathUtils = __webpack_require__( /*! ../core/utils/math */ 79),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151),
            Swipeable = __webpack_require__( /*! ../events/gesture/swipeable */ 248);
        var MULTIVIEW_CLASS = "dx-multiview",
            MULTIVIEW_WRAPPER_CLASS = "dx-multiview-wrapper",
            MULTIVIEW_ITEM_CONTAINER_CLASS = "dx-multiview-item-container",
            MULTIVIEW_ITEM_CLASS = "dx-multiview-item",
            MULTIVIEW_ITEM_HIDDEN_CLASS = "dx-multiview-item-hidden",
            MULTIVIEW_ITEM_DATA_KEY = "dxMultiViewItemData",
            MULTIVIEW_ANIMATION_DURATION = 200;
        var toNumber = function(value) {
            return +value
        };
        var position = function($element) {
            return translator.locate($element).left
        };
        var move = function($element, position) {
            translator.move($element, {
                left: position
            })
        };
        var animation = {
            moveTo: function($element, position, duration, completeAction) {
                fx.animate($element, {
                    type: "slide",
                    to: {
                        left: position
                    },
                    duration: duration,
                    complete: completeAction
                })
            },
            complete: function($element) {
                fx.stop($element, true)
            }
        };
        var MultiView = CollectionWidget.inherit({
            _activeStateUnit: "." + MULTIVIEW_ITEM_CLASS,
            _supportedKeys: function() {
                return $.extend(this.callBase(), {
                    pageUp: $.noop,
                    pageDown: $.noop
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    selectedIndex: 0,
                    swipeEnabled: true,
                    animationEnabled: true,
                    loop: false,
                    deferRendering: true,
                    _itemAttributes: {
                        role: "tabpanel"
                    },
                    loopItemFocus: false,
                    selectOnFocus: true,
                    selectionMode: "single",
                    selectionRequired: true,
                    selectionByClick: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _itemClass: function() {
                return MULTIVIEW_ITEM_CLASS
            },
            _itemDataKey: function() {
                return MULTIVIEW_ITEM_DATA_KEY
            },
            _itemContainer: function() {
                return this._$itemContainer
            },
            _itemElements: function() {
                return this._itemContainer().children(this._itemSelector())
            },
            _itemWidth: function() {
                if (!this._itemWidthValue) {
                    this._itemWidthValue = this._$wrapper.width()
                }
                return this._itemWidthValue
            },
            _clearItemWidthCache: function() {
                delete this._itemWidthValue
            },
            _itemsCount: function() {
                return this.option("items").length
            },
            _normalizeIndex: function(index) {
                var count = this._itemsCount();
                if (index < 0) {
                    index += count
                }
                if (index >= count) {
                    index -= count
                }
                return index
            },
            _getRTLSignCorrection: function() {
                return this.option("rtlEnabled") ? -1 : 1
            },
            _init: function() {
                this.callBase.apply(this, arguments);
                var $element = this.element();
                $element.addClass(MULTIVIEW_CLASS);
                this._$wrapper = $("<div>").addClass(MULTIVIEW_WRAPPER_CLASS);
                this._$wrapper.appendTo($element);
                this._$itemContainer = $("<div>").addClass(MULTIVIEW_ITEM_CONTAINER_CLASS);
                this._$itemContainer.appendTo(this._$wrapper);
                this.option("loopItemFocus", this.option("loop"));
                this._initSwipeable()
            },
            _render: function() {
                this._deferredItems = [];
                this.callBase()
            },
            _renderItemContent: function(args) {
                var renderContentDeferred = $.Deferred();
                var that = this,
                    callBase = this.callBase;
                var deferred = $.Deferred();
                deferred.done(function() {
                    var $itemContent = callBase.call(that, args);
                    renderContentDeferred.resolve($itemContent)
                });
                this._deferredItems.push(deferred);
                this.option("deferRendering") || deferred.resolve();
                return renderContentDeferred.promise()
            },
            _renderSelection: function(addedSelection) {
                this._updateItems(addedSelection[0])
            },
            _updateItems: function(selectedIndex, newIndex) {
                this._updateItemsPosition(selectedIndex, newIndex);
                this._updateItemsVisibility(selectedIndex, newIndex)
            },
            _updateItemsPosition: function(selectedIndex, newIndex) {
                var $itemElements = this._itemElements(),
                    positionSign = -this._animationDirection(newIndex, selectedIndex),
                    $selectedItem = $itemElements.eq(selectedIndex);
                move($selectedItem, 0);
                move($itemElements.eq(newIndex), 100 * positionSign + "%")
            },
            _updateItemsVisibility: function(selectedIndex, newIndex) {
                var $itemElements = this._itemElements();
                $itemElements.each($.proxy(function(itemIndex, item) {
                    var $item = $(item),
                        isHidden = itemIndex !== selectedIndex && itemIndex !== newIndex;
                    if (!isHidden) {
                        this._renderSpecificItem(itemIndex)
                    }
                    $item.toggleClass(MULTIVIEW_ITEM_HIDDEN_CLASS, isHidden);
                    this.setAria("hidden", isHidden || void 0, $item)
                }, this))
            },
            _renderSpecificItem: function(index) {
                var hasItemContent = this._itemElements().eq(index).find(this._itemContentClass()).length > 0;
                if (commonUtils.isDefined(index) && !hasItemContent) {
                    this._deferredItems[index].resolve()
                }
            },
            _setAriaSelected: $.noop,
            _updateSelection: function(addedSelection, removedSelection) {
                var newIndex = addedSelection[0],
                    prevIndex = removedSelection[0];
                animation.complete(this._$itemContainer);
                this._updateItems(prevIndex, newIndex);
                var animationDirection = this._animationDirection(newIndex, prevIndex);
                this._animateItemContainer(animationDirection * this._itemWidth(), $.proxy(function() {
                    move(this._$itemContainer, 0);
                    this._updateItems(newIndex);
                    this._$itemContainer.width()
                }, this))
            },
            _animateItemContainer: function(position, completeCallback) {
                var duration = this.option("animationEnabled") ? MULTIVIEW_ANIMATION_DURATION : 0;
                animation.moveTo(this._$itemContainer, position, duration, completeCallback)
            },
            _animationDirection: function(newIndex, prevIndex) {
                var containerPosition = position(this._$itemContainer),
                    indexDifference = (prevIndex - newIndex) * this._getRTLSignCorrection() * this._getItemFocusLoopSignCorrection(),
                    isSwipePresent = 0 !== containerPosition,
                    directionSignVariable = isSwipePresent ? containerPosition : indexDifference;
                return mathUtils.sign(directionSignVariable)
            },
            _initSwipeable: function() {
                this._createComponent(this.element(), Swipeable, {
                    disabled: !this.option("swipeEnabled"),
                    elastic: false,
                    itemSizeFunc: $.proxy(this._itemWidth, this),
                    onStart: $.proxy(function(args) {
                        this._swipeStartHandler(args.jQueryEvent)
                    }, this),
                    onUpdated: $.proxy(function(args) {
                        this._swipeUpdateHandler(args.jQueryEvent)
                    }, this),
                    onEnd: $.proxy(function(args) {
                        this._swipeEndHandler(args.jQueryEvent)
                    }, this)
                })
            },
            _swipeStartHandler: function(e) {
                animation.complete(this._$itemContainer);
                var selectedIndex = this.option("selectedIndex"),
                    loop = this.option("loop"),
                    lastIndex = this._itemsCount() - 1,
                    rtl = this.option("rtlEnabled");
                e.maxLeftOffset = toNumber(loop || (rtl ? selectedIndex > 0 : selectedIndex < lastIndex));
                e.maxRightOffset = toNumber(loop || (rtl ? selectedIndex < lastIndex : selectedIndex > 0));
                this._swipeDirection = null
            },
            _swipeUpdateHandler: function(e) {
                var offset = e.offset,
                    swipeDirection = mathUtils.sign(offset) * this._getRTLSignCorrection();
                move(this._$itemContainer, offset * this._itemWidth());
                if (swipeDirection !== this._swipeDirection) {
                    this._swipeDirection = swipeDirection;
                    var selectedIndex = this.option("selectedIndex"),
                        newIndex = this._normalizeIndex(selectedIndex - swipeDirection);
                    this._updateItems(selectedIndex, newIndex)
                }
            },
            _swipeEndHandler: function(e) {
                var targetOffset = e.targetOffset * this._getRTLSignCorrection();
                if (targetOffset) {
                    this.option("selectedIndex", this._normalizeIndex(this.option("selectedIndex") - targetOffset));
                    var $selectedElement = this.itemElements().filter(".dx-item-selected");
                    this.option("focusStateEnabled") && this.option("focusedElement", $selectedElement)
                } else {
                    this._animateItemContainer(0, $.noop)
                }
            },
            _getItemFocusLoopSignCorrection: function() {
                return this._itemFocusLooped ? -1 : 1
            },
            _moveFocus: function() {
                this.callBase.apply(this, arguments);
                this._itemFocusLooped = false
            },
            _prevItem: function($items) {
                var $result = this.callBase.apply(this, arguments);
                this._itemFocusLooped = $result.is($items.last());
                return $result
            },
            _nextItem: function($items) {
                var $result = this.callBase.apply(this, arguments);
                this._itemFocusLooped = $result.is($items.first());
                return $result
            },
            _dimensionChanged: function() {
                this._clearItemWidthCache()
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "loop":
                        this.option("loopItemFocus", value);
                        break;
                    case "animationEnabled":
                        break;
                    case "swipeEnabled":
                        Swipeable.getInstance(this.element()).option("disabled", !value);
                        break;
                    case "deferRendering":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxMultiView", MultiView);
        module.exports = MultiView;
        module.exports.animation = animation
    },
    /*!****************************!*\
      !*** ./Scripts/ui/tabs.js ***!
      \****************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Button = __webpack_require__( /*! ./button */ 196),
            inkRipple = __webpack_require__( /*! ./widget/utils.ink_ripple */ 197),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            pointerEvents = __webpack_require__( /*! ../events/pointer */ 65),
            themes = __webpack_require__( /*! ./themes */ 143),
            holdEvent = __webpack_require__( /*! ../events/hold */ 164),
            Scrollable = __webpack_require__( /*! ./scroll_view/ui.scrollable */ 237).default,
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151);
        var TABS_CLASS = "dx-tabs",
            TABS_WRAPPER_CLASS = "dx-tabs-wrapper",
            TABS_EXPANDED_CLASS = "dx-tabs-expanded",
            TABS_SCROLLABLE_CLASS = "dx-tabs-scrollable",
            TABS_NAV_BUTTONS_CLASS = "dx-tabs-nav-buttons",
            TABS_ITEM_CLASS = "dx-tab",
            TABS_ITEM_SELECTED_CLASS = "dx-tab-selected",
            TABS_NAV_BUTTON_CLASS = "dx-tabs-nav-button",
            TABS_LEFT_NAV_BUTTON_CLASS = "dx-tabs-nav-button-left",
            TABS_RIGHT_NAV_BUTTON_CLASS = "dx-tabs-nav-button-right",
            TABS_ITEM_DATA_KEY = "dxTabData",
            FEEDBACK_HIDE_TIMEOUT = 100,
            FEEDBACK_DURATION_INTERVAL = 5,
            FEEDBACK_SCROLL_TIMEOUT = 300,
            TAB_OFFSET = 30;
        var Tabs = CollectionWidget.inherit({
            _activeStateUnit: "." + TABS_ITEM_CLASS,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    showNavButtons: false,
                    scrollByContent: true,
                    scrollingEnabled: true,
                    selectionMode: "single",
                    activeStateEnabled: true,
                    selectionRequired: false,
                    selectOnFocus: true,
                    loopItemFocus: false,
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "generic"
                    },
                    options: {
                        showNavButtons: true,
                        scrollByContent: false
                    }
                }, {
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this.setAria("role", "tablist");
                this.element().addClass(TABS_CLASS);
                this._renderMultiple();
                this._feedbackHideTimeout = FEEDBACK_HIDE_TIMEOUT
            },
            _itemClass: function() {
                return TABS_ITEM_CLASS
            },
            _selectedItemClass: function() {
                return TABS_ITEM_SELECTED_CLASS
            },
            _itemDataKey: function() {
                return TABS_ITEM_DATA_KEY
            },
            _renderContent: function() {
                var that = this;
                this.callBase();
                if (this.option("templatesRenderAsynchronously")) {
                    this._resizeEventTimer = setTimeout(function() {
                        domUtils.triggerResizeEvent(that._$content)
                    }, 0)
                }
            },
            _render: function() {
                this.callBase();
                this._renderWrapper();
                this._renderScrolling();
                this.setAria("role", "tab", this.itemElements());
                this.option("useInkRipple") && this._renderInkRipple()
            },
            _renderScrolling: function() {
                this.element().removeClass(TABS_EXPANDED_CLASS);
                if (this._allowScrolling() && !this._scrollable) {
                    this._renderScrollable();
                    this._renderNavButtons();
                    this._scrollToItem(this.option("selectedItem"))
                }
                if (!this._allowScrolling()) {
                    this._cleanScrolling();
                    this.element().removeClass(TABS_NAV_BUTTONS_CLASS).addClass(TABS_EXPANDED_CLASS)
                }
            },
            _cleanNavButtons: function() {
                if (!this._leftButton || !this._rightButton) {
                    return
                }
                this._leftButton.element().remove();
                this._rightButton.element().remove();
                this._leftButton = null;
                this._rightButton = null
            },
            _cleanScrolling: function() {
                if (!this._scrollable) {
                    return
                }
                this._scrollable.content().children("." + TABS_WRAPPER_CLASS).appendTo(this._itemContainer());
                this._scrollable.element().remove();
                this._scrollable = null;
                this._cleanNavButtons()
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render()
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: $element,
                    jQueryEvent: e
                };
                if (value) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _renderMultiple: function() {
                if ("multiple" === this.option("selectionMode")) {
                    this.option("selectOnFocus", false)
                }
            },
            _renderWrapper: function() {
                this.element().wrapInner($("<div>").addClass(TABS_WRAPPER_CLASS))
            },
            _renderScrollable: function() {
                var $itemContainer = this.element().wrapInner($("<div>").addClass(TABS_SCROLLABLE_CLASS)).children();
                this._scrollable = this._createComponent($itemContainer, Scrollable, {
                    direction: "horizontal",
                    showScrollbar: false,
                    useKeyboard: false,
                    useNative: false,
                    scrollByContent: this.option("scrollByContent"),
                    onScroll: $.proxy(this._updateNavButtonsVisibility, this)
                });
                this.element().append(this._scrollable.element())
            },
            _scrollToItem: function(itemData) {
                if (!this._scrollable) {
                    return
                }
                var $item = this._editStrategy.getItemElement(itemData);
                this._scrollable.scrollToElement($item)
            },
            _allowScrolling: function() {
                if (!this.option("scrollingEnabled")) {
                    return false
                }
                var tabItemsWidth = 0;
                this.itemElements().each(function(_, tabItem) {
                    tabItemsWidth += $(tabItem).outerWidth(true)
                });
                return tabItemsWidth - 1 > this.element().width()
            },
            _renderNavButtons: function() {
                this.element().toggleClass(TABS_NAV_BUTTONS_CLASS, this.option("showNavButtons"));
                if (!this.option("showNavButtons")) {
                    return
                }
                this._leftButton = this._createNavButton(-TAB_OFFSET, "chevronprev");
                var $leftButton = this._leftButton.element();
                $leftButton.addClass(TABS_LEFT_NAV_BUTTON_CLASS);
                this.element().prepend($leftButton);
                this._rightButton = this._createNavButton(TAB_OFFSET, "chevronnext");
                var $rightButton = this._rightButton.element();
                $rightButton.addClass(TABS_RIGHT_NAV_BUTTON_CLASS);
                this.element().append($rightButton);
                this._updateNavButtonsVisibility();
                this._scrollable.update();
                if (this.option("rtlEnabled")) {
                    this._scrollable.scrollTo({
                        left: this._scrollable.scrollWidth() - this._scrollable.clientWidth()
                    })
                }
            },
            _updateNavButtonsVisibility: function() {
                this._leftButton && this._leftButton.option("disabled", this._scrollable.scrollLeft() <= 0);
                this._rightButton && this._rightButton.option("disabled", this._scrollable.scrollLeft() >= this._scrollable.scrollWidth() - this._scrollable.clientWidth())
            },
            _updateScrollPosition: function(offset, duration) {
                this._scrollable.update();
                this._scrollable.scrollBy(offset / duration)
            },
            _createNavButton: function(offset, icon) {
                var that = this;
                var holdAction = that._createAction(function() {
                        that._holdInterval = setInterval(function() {
                            that._updateScrollPosition(offset, FEEDBACK_DURATION_INTERVAL)
                        }, FEEDBACK_DURATION_INTERVAL)
                    }),
                    holdEventName = eventUtils.addNamespace(holdEvent.name, "dxNavButton"),
                    pointerUpEventName = eventUtils.addNamespace(pointerEvents.up, "dxNavButton"),
                    pointerOutEventName = eventUtils.addNamespace(pointerEvents.out, "dxNavButton");
                var navButton = this._createComponent($("<div>").addClass(TABS_NAV_BUTTON_CLASS), Button, {
                    focusStateEnabled: false,
                    icon: icon,
                    onClick: function() {
                        that._updateScrollPosition(offset, 1)
                    },
                    _templates: {}
                });
                navButton.element().on(holdEventName, {
                    timeout: FEEDBACK_SCROLL_TIMEOUT
                }, $.proxy(function(e) {
                    holdAction({
                        jQueryEvent: e
                    })
                }, this)).on(pointerUpEventName, function() {
                    that._clearInterval()
                }).on(pointerOutEventName, function() {
                    that._clearInterval()
                });
                return navButton
            },
            _clearInterval: function() {
                if (this._holdInterval) {
                    clearInterval(this._holdInterval)
                }
            },
            _renderSelection: function(addedSelection) {
                this._scrollable && this._scrollable.scrollToElement(this.itemElements().eq(addedSelection[0]), {
                    left: 1,
                    right: 1
                })
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _dimensionChanged: function() {
                if (this.option("scrollingEnabled")) {
                    this._renderScrolling()
                }
            },
            _itemSelectHandler: function(e) {
                if ("single" === this.option("selectionMode") && this.isItemSelected(e.currentTarget)) {
                    return
                }
                this.callBase(e)
            },
            _clean: function() {
                this._scrollable = null;
                clearTimeout(this._resizeEventTimer);
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "useInkRipple":
                    case "scrollingEnabled":
                    case "showNavButtons":
                        this._invalidate();
                        break;
                    case "scrollByContent":
                        this._scrollable && this._scrollable.option(args.name, args.value);
                        break;
                    case "selectionMode":
                        this._renderMultiple();
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxTabs", Tabs);
        module.exports = Tabs
    },
    /*!******************************************!*\
      !*** ./Scripts/ui/validation_summary.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            ValidationMixin = __webpack_require__( /*! ./validation/validation_mixin */ 108),
            ValidationEngine = __webpack_require__( /*! ./validation_engine */ 117),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151);
        var VALIDATION_SUMMARY_CLASS = "dx-validationsummary",
            ITEM_CLASS = VALIDATION_SUMMARY_CLASS + "-item",
            ITEM_DATA_KEY = VALIDATION_SUMMARY_CLASS + "-item-data";
        var ValidationSummary = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    focusStateEnabled: false,
                    noDataText: null
                })
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    validationGroup: true
                })
            },
            _init: function() {
                this.callBase();
                this._initGroupRegistration()
            },
            _initGroupRegistration: function() {
                var group = this._findGroup(),
                    groupConfig = ValidationEngine.addGroup(group);
                this._unsubscribeGroup();
                this._groupWasInit = true;
                this._validationGroup = group;
                this.groupSubscription = $.proxy(this._groupValidationHandler, this);
                groupConfig.on("validated", this.groupSubscription)
            },
            _unsubscribeGroup: function() {
                var groupConfig = ValidationEngine.getGroupConfig(this._validationGroup);
                groupConfig && groupConfig.off("validated", this.groupSubscription)
            },
            _getOrderedItems: function(validators, items) {
                var orderedItems = [];
                $.each(validators, function(_, validator) {
                    var firstItem = $.grep(items, function(item) {
                        if (item.validator === validator) {
                            return true
                        }
                    })[0];
                    if (firstItem) {
                        orderedItems.push(firstItem)
                    }
                });
                return orderedItems
            },
            _groupValidationHandler: function(params) {
                var that = this,
                    items = that._getOrderedItems(params.validators, $.map(params.brokenRules, function(rule) {
                        return {
                            text: rule.message,
                            validator: rule.validator
                        }
                    }));
                that.validators = params.validators;
                $.each(that.validators, function(_, validator) {
                    if (validator._validationSummary !== this) {
                        var handler = $.proxy(that._itemValidationHandler, that),
                            disposingHandler = function() {
                                validator.off("validated", handler);
                                validator._validationSummary = null;
                                handler = null
                            };
                        validator.on("validated", handler);
                        validator.on("disposing", disposingHandler);
                        validator._validationSummary = this
                    }
                });
                that.option("items", items)
            },
            _itemValidationHandler: function(itemValidationResult) {
                var elementIndex, items = this.option("items"),
                    isValid = itemValidationResult.isValid,
                    replacementFound = false,
                    newMessage = itemValidationResult.brokenRule && itemValidationResult.brokenRule.message,
                    validator = itemValidationResult.validator;
                $.each(items, function(index, item) {
                    if (item.validator === validator) {
                        if (isValid) {
                            elementIndex = index
                        } else {
                            item.text = newMessage
                        }
                        replacementFound = true;
                        return false
                    }
                });
                if (isValid ^ replacementFound) {
                    return
                }
                if (isValid) {
                    items.splice(elementIndex, 1)
                } else {
                    items.push({
                        text: newMessage,
                        validator: validator
                    })
                }
                items = this._getOrderedItems(this.validators, items);
                this.option("items", items)
            },
            _render: function() {
                this.element().addClass(VALIDATION_SUMMARY_CLASS);
                this.callBase()
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "validationGroup":
                        this._initGroupRegistration();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _itemClass: function() {
                return ITEM_CLASS
            },
            _itemDataKey: function() {
                return ITEM_DATA_KEY
            },
            _postprocessRenderItem: function(params) {
                params.itemElement.on("click", function() {
                    params.itemData.validator.focus()
                })
            },
            _dispose: function() {
                this.callBase();
                this._unsubscribeGroup()
            }
        }).include(ValidationMixin);
        registerComponent("dxValidationSummary", ValidationSummary);
        module.exports = ValidationSummary
    },
    /*!****************************************!*\
      !*** ./Scripts/ui/validation_group.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            DOMComponent = __webpack_require__( /*! ../core/dom_component */ 29),
            ValidationSummary = __webpack_require__( /*! ./validation_summary */ 285),
            ValidationEngine = __webpack_require__( /*! ./validation_engine */ 117),
            Validator = __webpack_require__( /*! ./validator */ 279);
        var VALIDATION_ENGINE_CLASS = "dx-validationgroup";
        var ValidationGroup = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return this.callBase()
            },
            _init: function() {
                this.callBase()
            },
            _render: function() {
                var $element = this.element();
                $element.addClass(VALIDATION_ENGINE_CLASS);
                $element.find(".dx-validator").each(function(_, validatorContainer) {
                    Validator.getInstance($(validatorContainer))._initGroupRegistration()
                });
                $element.find(".dx-validationsummary").each(function(_, summaryContainer) {
                    ValidationSummary.getInstance($(summaryContainer))._initGroupRegistration()
                });
                this.callBase()
            },
            validate: function() {
                return ValidationEngine.validateGroup(this)
            },
            reset: function() {
                return ValidationEngine.resetGroup(this)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    default: this.callBase(args)
                }
            },
            _dispose: function() {
                ValidationEngine.removeGroup(this);
                this.element().removeClass(VALIDATION_ENGINE_CLASS);
                this.callBase()
            }
        });
        registerComponent("dxValidationGroup", ValidationGroup);
        module.exports = ValidationGroup
    },
    /*!*******************************!*\
      !*** ./Scripts/ui/gallery.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            Widget = __webpack_require__( /*! ./widget/ui.widget */ 89),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151),
            Swipeable = __webpack_require__( /*! ../events/gesture/swipeable */ 248);
        var GALLERY_CLASS = "dx-gallery",
            GALLERY_WRAPPER_CLASS = GALLERY_CLASS + "-wrapper",
            GALLERY_LOOP_CLASS = "dx-gallery-loop",
            GALLERY_ITEM_CONTAINER_CLASS = GALLERY_CLASS + "-container",
            GALLERY_ACTIVE_CLASS = GALLERY_CLASS + "-active",
            GALLERY_ITEM_CLASS = GALLERY_CLASS + "-item",
            GALLERY_LOOP_ITEM_CLASS = GALLERY_ITEM_CLASS + "-loop",
            GALLERY_ITEM_SELECTOR = "." + GALLERY_ITEM_CLASS,
            GALLERY_ITEM_SELECTED_CLASS = GALLERY_ITEM_CLASS + "-selected",
            GALLERY_INDICATOR_CLASS = GALLERY_CLASS + "-indicator",
            GALLERY_INDICATOR_ITEM_CLASS = GALLERY_INDICATOR_CLASS + "-item",
            GALLERY_INDICATOR_ITEM_SELECTOR = "." + GALLERY_INDICATOR_ITEM_CLASS,
            GALLERY_INDICATOR_ITEM_SELECTED_CLASS = GALLERY_INDICATOR_ITEM_CLASS + "-selected",
            GALLERY_ITEM_DATA_KEY = "dxGalleryItemData",
            MAX_CALC_ERROR = 1;
        var GalleryNavButton = Widget.inherit({
            _supportedKeys: function() {
                return $.extend(this.callBase(), {
                    pageUp: $.noop,
                    pageDown: $.noop
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    direction: "next",
                    onClick: null,
                    hoverStateEnabled: true,
                    activeStateEnabled: true
                })
            },
            _render: function() {
                this.callBase();
                var that = this,
                    $element = this.element(),
                    eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                $element.addClass(GALLERY_CLASS + "-nav-button-" + this.option("direction")).off(eventName).on(eventName, function(e) {
                    that._createActionByOption("onClick")({
                        jQueryEvent: e
                    })
                })
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onClick":
                    case "direction":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        GalleryNavButton.publicName("dxGalleryNavButton");
        var Gallery = CollectionWidget.inherit({
            _activeStateUnit: GALLERY_ITEM_SELECTOR,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    activeStateEnabled: false,
                    animationDuration: 400,
                    animationEnabled: true,
                    loop: false,
                    swipeEnabled: true,
                    indicatorEnabled: true,
                    showIndicator: true,
                    selectedIndex: 0,
                    slideshowDelay: 0,
                    showNavButtons: false,
                    wrapAround: false,
                    initialItemWidth: void 0,
                    stretchImages: false,
                    _itemAttributes: {
                        role: "option"
                    },
                    loopItemFocus: false,
                    selectOnFocus: true,
                    selectionMode: "single",
                    selectionRequired: true,
                    selectionByClick: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this.option("loopItemFocus", this.option("loop"))
            },
            _dataSourceOptions: function() {
                return {
                    paginate: false
                }
            },
            _itemContainer: function() {
                return this._$container
            },
            _itemClass: function() {
                return GALLERY_ITEM_CLASS
            },
            _itemDataKey: function() {
                return GALLERY_ITEM_DATA_KEY
            },
            _actualItemWidth: function() {
                var itemPerPage = this.option("wrapAround") ? this._itemsPerPage() + 1 : this._itemsPerPage();
                if (this.option("stretchImages")) {
                    return 1 / itemPerPage
                }
                if (this.option("wrapAround")) {
                    return this._itemPercentWidth() * this._itemsPerPage() / (this._itemsPerPage() + 1)
                }
                return this._itemPercentWidth()
            },
            _itemPercentWidth: function() {
                var percentWidth, elementWidth = this.element().outerWidth(),
                    initialItemWidth = this.option("initialItemWidth");
                if (initialItemWidth && initialItemWidth <= elementWidth) {
                    percentWidth = this.option("initialItemWidth") / elementWidth
                } else {
                    percentWidth = 1
                }
                return percentWidth
            },
            _itemsPerPage: function() {
                var itemsPerPage = Math.floor(1 / this._itemPercentWidth());
                return Math.min(itemsPerPage, this._itemsCount())
            },
            _pagesCount: function() {
                return Math.ceil(this._itemsCount() / this._itemsPerPage())
            },
            _itemsCount: function() {
                return (this.option("items") || []).length
            },
            _offsetDirection: function() {
                return this.option("rtlEnabled") ? -1 : 1
            },
            _render: function() {
                this.element().addClass(GALLERY_CLASS);
                this.element().toggleClass(GALLERY_LOOP_CLASS, this.option("loop"));
                this._renderDragHandler();
                this._renderWrapper();
                this._renderItemsContainer();
                this.callBase();
                this._renderContainerPosition();
                this._renderItemSizes();
                this._renderItemPositions();
                this._renderNavButtons();
                this._renderIndicator();
                this._renderSelectedItem();
                this._renderUserInteraction();
                this._setupSlideShow();
                this._reviseDimensions();
                this.setAria({
                    role: "listbox",
                    label: "gallery"
                });
                this._fireContentReadyAction()
            },
            _renderContent: function() {
                this._renderContentImpl()
            },
            _dimensionChanged: function() {
                var selectedIndex = this.option("selectedIndex") || 0;
                this._stopItemAnimations();
                this._clearCacheWidth();
                this._renderDuplicateItems();
                this._renderItemSizes();
                this._renderItemPositions();
                this._renderIndicator();
                this._renderContainerPosition(this._calculateIndexOffset(selectedIndex))
            },
            _renderDragHandler: function() {
                var eventName = eventUtils.addNamespace("dragstart", this.NAME);
                this.element().off(eventName).on(eventName, "img", function() {
                    return false
                })
            },
            _renderWrapper: function() {
                if (this._$wrapper) {
                    return
                }
                this._$wrapper = $("<div />").addClass(GALLERY_WRAPPER_CLASS).appendTo(this.element())
            },
            _renderItems: function(items) {
                this.callBase(items);
                this._loadNextPageIfNeeded()
            },
            _renderItemsContainer: function() {
                if (this._$container) {
                    return
                }
                this._$container = $("<div>").addClass(GALLERY_ITEM_CONTAINER_CLASS).appendTo(this._$wrapper)
            },
            _renderDuplicateItems: function() {
                if (!this.option("loop")) {
                    return
                }
                var i, items = this.option("items") || [],
                    itemsCount = items.length,
                    lastItemIndex = itemsCount - 1;
                if (!itemsCount) {
                    return
                }
                this.element().find("." + GALLERY_LOOP_ITEM_CLASS).remove();
                var duplicateCount = Math.min(this._itemsPerPage(), itemsCount);
                for (i = 0; i < duplicateCount; i++) {
                    this._renderItem(0, items[i]).addClass(GALLERY_LOOP_ITEM_CLASS)
                }
                for (i = 0; i < duplicateCount; i++) {
                    this._renderItem(0, items[lastItemIndex - i]).addClass(GALLERY_LOOP_ITEM_CLASS)
                }
            },
            _emptyMessageContainer: function() {
                return this._$wrapper
            },
            _renderItemSizes: function(startIndex) {
                var $items = this._itemElements(),
                    itemWidth = this._actualItemWidth();
                if (void 0 !== startIndex) {
                    $items = $items.slice(startIndex)
                }
                $items.each(function(index) {
                    $($items[index]).outerWidth(100 * itemWidth + "%")
                })
            },
            _renderItemPositions: function() {
                var itemWidth = this._actualItemWidth(),
                    itemsCount = this._itemsCount(),
                    itemsPerPage = this._itemsPerPage(),
                    loopItemsCount = this.element().find("." + GALLERY_LOOP_ITEM_CLASS).length,
                    lastItemDuplicateIndex = itemsCount + loopItemsCount - 1,
                    offsetRatio = this.option("wrapAround") ? .5 : 0,
                    freeSpace = this._itemFreeSpace(),
                    rtlEnabled = this.option("rtlEnabled");
                this._itemElements().each(function(index) {
                    var realIndex = index;
                    if (index > itemsCount + itemsPerPage - 1) {
                        realIndex = lastItemDuplicateIndex - realIndex - itemsPerPage
                    }
                    var itemPosition = itemWidth * (realIndex + offsetRatio) + freeSpace * (realIndex + 1 - offsetRatio);
                    $(this).css(rtlEnabled ? "right" : "left", 100 * itemPosition + "%")
                });
                this._relocateItems(this.option("selectedIndex"), this.option("selectedIndex"), true)
            },
            _itemFreeSpace: function() {
                var itemsPerPage = this._itemsPerPage();
                if (this.option("wrapAround")) {
                    itemsPerPage += 1
                }
                return (1 - this._actualItemWidth() * itemsPerPage) / (itemsPerPage + 1)
            },
            _renderContainerPosition: function(offset, animate) {
                offset = offset || 0;
                var positionReady, that = this,
                    itemWidth = this._actualItemWidth(),
                    targetIndex = offset,
                    targetPosition = this._offsetDirection() * targetIndex * (itemWidth + this._itemFreeSpace());
                if (commonUtils.isDefined(this._animationOverride)) {
                    animate = this._animationOverride;
                    delete this._animationOverride
                }
                if (animate) {
                    that._startSwipe();
                    positionReady = that._animate(targetPosition).done($.proxy(that._endSwipe, that))
                } else {
                    translator.move(this._$container, {
                        left: targetPosition * this._elementWidth(),
                        top: 0
                    });
                    positionReady = $.Deferred().resolveWith(that)
                }
                if (this._deferredAnimate) {
                    positionReady.done(function() {
                        that._deferredAnimate.resolveWith(that)
                    })
                }
                return positionReady.promise()
            },
            _startSwipe: function() {
                this.element().addClass(GALLERY_ACTIVE_CLASS)
            },
            _endSwipe: function() {
                this.element().removeClass(GALLERY_ACTIVE_CLASS)
            },
            _animate: function(targetPosition, extraConfig) {
                var that = this,
                    $container = this._$container,
                    animationComplete = $.Deferred();
                fx.animate(this._$container, $.extend({
                    type: "slide",
                    to: {
                        left: targetPosition * this._elementWidth()
                    },
                    duration: that.option("animationDuration"),
                    complete: function() {
                        if (that._needMoveContainerForward()) {
                            translator.move($container, {
                                left: 0,
                                top: 0
                            })
                        }
                        if (that._needMoveContainerBack()) {
                            translator.move($container, {
                                left: that._maxContainerOffset() * that._elementWidth(),
                                top: 0
                            })
                        }
                        animationComplete.resolveWith(that)
                    }
                }, extraConfig || {}));
                return animationComplete
            },
            _needMoveContainerForward: function() {
                var expectedPosition = this._$container.position().left * this._offsetDirection(),
                    actualPosition = -this._maxItemWidth() * this._elementWidth() * this._itemsCount();
                return expectedPosition <= actualPosition + MAX_CALC_ERROR
            },
            _needMoveContainerBack: function() {
                var expectedPosition = this._$container.position().left * this._offsetDirection(),
                    actualPosition = this._actualItemWidth() * this._elementWidth();
                return expectedPosition >= actualPosition - MAX_CALC_ERROR
            },
            _maxContainerOffset: function() {
                return -this._maxItemWidth() * (this._itemsCount() - this._itemsPerPage()) * this._offsetDirection()
            },
            _maxItemWidth: function() {
                return this._actualItemWidth() + this._itemFreeSpace()
            },
            _reviseDimensions: function() {
                var that = this,
                    $firstItem = that._itemElements().first().find(".dx-item-content");
                if (!$firstItem || $firstItem.is(":hidden")) {
                    return
                }
                if (!that.option("height")) {
                    that.option("height", $firstItem.outerHeight())
                }
                if (!that.option("width")) {
                    that.option("width", $firstItem.outerWidth())
                }
                this._dimensionChanged()
            },
            _renderIndicator: function() {
                this._cleanIndicators();
                if (!this.option("showIndicator")) {
                    return
                }
                var indicator = this._$indicator = $("<div>").addClass(GALLERY_INDICATOR_CLASS).appendTo(this._$wrapper);
                for (var i = 0; i < this._pagesCount(); i++) {
                    $("<div>").addClass(GALLERY_INDICATOR_ITEM_CLASS).appendTo(indicator)
                }
                this._renderSelectedPageIndicator()
            },
            _cleanIndicators: function() {
                if (this._$indicator) {
                    this._$indicator.remove()
                }
            },
            _renderSelectedItem: function() {
                var selectedIndex = this.option("selectedIndex");
                this._itemElements().removeClass(GALLERY_ITEM_SELECTED_CLASS).eq(selectedIndex).addClass(GALLERY_ITEM_SELECTED_CLASS)
            },
            _renderSelectedPageIndicator: function() {
                if (!this._$indicator) {
                    return
                }
                var itemIndex = this.option("selectedIndex"),
                    lastIndex = this._pagesCount() - 1,
                    pageIndex = Math.ceil(itemIndex / this._itemsPerPage());
                pageIndex = Math.min(lastIndex, pageIndex);
                this._$indicator.find(GALLERY_INDICATOR_ITEM_SELECTOR).removeClass(GALLERY_INDICATOR_ITEM_SELECTED_CLASS).eq(pageIndex).addClass(GALLERY_INDICATOR_ITEM_SELECTED_CLASS)
            },
            _renderUserInteraction: function() {
                var rootElement = this.element(),
                    swipeEnabled = this.option("swipeEnabled") && this._itemsCount() > 1;
                this._createComponent(rootElement, Swipeable, {
                    disabled: this.option("disabled") || !swipeEnabled,
                    onStart: $.proxy(this._swipeStartHandler, this),
                    onUpdated: $.proxy(this._swipeUpdateHandler, this),
                    onEnd: $.proxy(this._swipeEndHandler, this),
                    itemSizeFunc: $.proxy(this._elementWidth, this)
                });
                var indicatorSelectAction = this._createAction(this._indicatorSelectHandler);
                rootElement.off(eventUtils.addNamespace(clickEvent.name, this.NAME), GALLERY_INDICATOR_ITEM_SELECTOR).on(eventUtils.addNamespace(clickEvent.name, this.NAME), GALLERY_INDICATOR_ITEM_SELECTOR, function(e) {
                    indicatorSelectAction({
                        jQueryEvent: e
                    })
                })
            },
            _indicatorSelectHandler: function(args) {
                var e = args.jQueryEvent,
                    instance = args.component;
                if (!instance.option("indicatorEnabled")) {
                    return
                }
                var indicatorIndex = $(e.target).index(),
                    itemIndex = instance._fitPaginatedIndex(indicatorIndex * instance._itemsPerPage());
                instance._needLongMove = true;
                instance.option("selectedIndex", itemIndex);
                instance._loadNextPageIfNeeded(itemIndex)
            },
            _renderNavButtons: function() {
                var that = this;
                if (!that.option("showNavButtons")) {
                    that._cleanNavButtons();
                    return
                }
                that._prevNavButton = $("<div>").appendTo(this._$wrapper);
                that._createComponent(that._prevNavButton, GalleryNavButton, {
                    direction: "prev",
                    onClick: function() {
                        that._prevPage()
                    }
                });
                that._nextNavButton = $("<div>").appendTo(this._$wrapper);
                that._createComponent(that._nextNavButton, GalleryNavButton, {
                    direction: "next",
                    onClick: function() {
                        that._nextPage()
                    }
                });
                this._renderNavButtonsVisibility()
            },
            _prevPage: function() {
                var visiblePageSize = this._itemsPerPage(),
                    newSelectedIndex = this.option("selectedIndex") - visiblePageSize;
                if (newSelectedIndex === -visiblePageSize && visiblePageSize === this._itemsCount()) {
                    return this._relocateItems(newSelectedIndex, 0)
                } else {
                    return this.goToItem(this._fitPaginatedIndex(newSelectedIndex))
                }
            },
            _nextPage: function() {
                var visiblePageSize = this._itemsPerPage(),
                    newSelectedIndex = this.option("selectedIndex") + visiblePageSize;
                if (newSelectedIndex === visiblePageSize && visiblePageSize === this._itemsCount()) {
                    return this._relocateItems(newSelectedIndex, 0)
                } else {
                    return this.goToItem(this._fitPaginatedIndex(newSelectedIndex)).done(this._loadNextPageIfNeeded)
                }
            },
            _loadNextPageIfNeeded: function(selectedIndex) {
                selectedIndex = void 0 === selectedIndex ? this.option("selectedIndex") : selectedIndex;
                if (this._dataSource && this._dataSource.paginate() && this._shouldLoadNextPage(selectedIndex) && !this._isDataSourceLoading() && !this._isLastPage()) {
                    this._loadNextPage().done($.proxy(function() {
                        this._renderIndicator();
                        this._renderItemPositions();
                        this._renderNavButtonsVisibility();
                        this._renderItemSizes(selectedIndex)
                    }, this))
                }
            },
            _shouldLoadNextPage: function(selectedIndex) {
                var visiblePageSize = this._itemsPerPage();
                return selectedIndex + 2 * visiblePageSize > this.option("items").length
            },
            _allowDynamicItemsAppend: function() {
                return true
            },
            _fitPaginatedIndex: function(itemIndex) {
                var itemsPerPage = this._itemsPerPage();
                var restItemsCount = itemIndex < 0 ? itemsPerPage + itemIndex : this._itemsCount() - itemIndex;
                if (itemIndex > this._itemsCount() - 1) {
                    itemIndex = 0;
                    this._goToGhostItem = true
                } else {
                    if (restItemsCount < itemsPerPage && restItemsCount > 0) {
                        if (itemIndex > 0) {
                            itemIndex -= itemsPerPage - restItemsCount
                        } else {
                            itemIndex += itemsPerPage - restItemsCount
                        }
                    }
                }
                return itemIndex
            },
            _cleanNavButtons: function() {
                if (this._prevNavButton) {
                    this._prevNavButton.remove();
                    delete this._prevNavButton
                }
                if (this._nextNavButton) {
                    this._nextNavButton.remove();
                    delete this._nextNavButton
                }
            },
            _renderNavButtonsVisibility: function() {
                if (!this.option("showNavButtons") || !this._prevNavButton || !this._nextNavButton) {
                    return
                }
                var selectedIndex = this.option("selectedIndex"),
                    loop = this.option("loop"),
                    itemsCount = this._itemsCount();
                this._prevNavButton.show();
                this._nextNavButton.show();
                if (0 === itemsCount) {
                    this._prevNavButton.hide();
                    this._nextNavButton.hide()
                }
                if (loop) {
                    return
                }
                var nextHidden = selectedIndex === itemsCount - this._itemsPerPage(),
                    prevHidden = itemsCount < 2 || 0 === selectedIndex;
                if (this._dataSource && this._dataSource.paginate()) {
                    nextHidden = nextHidden && this._isLastPage()
                } else {
                    nextHidden = nextHidden || itemsCount < 2
                }
                if (prevHidden) {
                    this._prevNavButton.hide()
                }
                if (nextHidden) {
                    this._nextNavButton.hide()
                }
            },
            _setupSlideShow: function() {
                var that = this,
                    slideshowDelay = that.option("slideshowDelay");
                clearTimeout(that._slideshowTimer);
                if (!slideshowDelay) {
                    return
                }
                that._slideshowTimer = setTimeout(function() {
                    if (that._userInteraction) {
                        that._setupSlideShow();
                        return
                    }
                    that.nextItem(true).done(that._setupSlideShow)
                }, slideshowDelay)
            },
            _elementWidth: function() {
                if (!this._cacheElementWidth) {
                    this._cacheElementWidth = this.element().width()
                }
                return this._cacheElementWidth
            },
            _clearCacheWidth: function() {
                delete this._cacheElementWidth
            },
            _swipeStartHandler: function(e) {
                this._clearCacheWidth();
                this._elementWidth();
                var itemsCount = this._itemsCount();
                if (!itemsCount) {
                    e.jQueryEvent.cancel = true;
                    return
                }
                this._stopItemAnimations();
                this._startSwipe();
                this._userInteraction = true;
                if (!this.option("loop")) {
                    var selectedIndex = this.option("selectedIndex"),
                        startOffset = itemsCount - selectedIndex - this._itemsPerPage(),
                        endOffset = selectedIndex,
                        rtlEnabled = this.option("rtlEnabled");
                    e.jQueryEvent.maxLeftOffset = rtlEnabled ? endOffset : startOffset;
                    e.jQueryEvent.maxRightOffset = rtlEnabled ? startOffset : endOffset
                }
            },
            _stopItemAnimations: function() {
                fx.stop(this._$container, true)
            },
            _swipeUpdateHandler: function(e) {
                var wrapAroundRatio = this.option("wrapAround") ? 1 : 0;
                var offset = this._offsetDirection() * e.jQueryEvent.offset * (this._itemsPerPage() + wrapAroundRatio) - this.option("selectedIndex");
                if (offset < 0) {
                    this._loadNextPageIfNeeded(Math.ceil(Math.abs(offset)))
                }
                this._renderContainerPosition(offset)
            },
            _swipeEndHandler: function(e) {
                var targetOffset = e.jQueryEvent.targetOffset * this._offsetDirection() * this._itemsPerPage(),
                    selectedIndex = this.option("selectedIndex"),
                    newIndex = this._fitIndex(selectedIndex - targetOffset),
                    paginatedIndex = this._fitPaginatedIndex(newIndex);
                if (Math.abs(targetOffset) < this._itemsPerPage()) {
                    this._relocateItems(selectedIndex);
                    return
                }
                if (this._itemsPerPage() === this._itemsCount()) {
                    if (targetOffset > 0) {
                        this._relocateItems(-targetOffset)
                    } else {
                        this._relocateItems(0)
                    }
                    return
                }
                this.option("selectedIndex", paginatedIndex)
            },
            _setFocusOnSelect: function() {
                this._userInteraction = true;
                var selectedItem = this.itemElements().filter("." + GALLERY_ITEM_SELECTED_CLASS);
                this.option("focusedElement", selectedItem);
                this._userInteraction = false
            },
            _flipIndex: function(index) {
                var itemsCount = this._itemsCount();
                index %= itemsCount;
                if (index > (itemsCount + 1) / 2) {
                    index -= itemsCount
                }
                if (index < -(itemsCount - 1) / 2) {
                    index += itemsCount
                }
                return index
            },
            _fitIndex: function(index) {
                if (!this.option("loop")) {
                    return index
                }
                var itemsCount = this._itemsCount();
                if (index >= itemsCount || index < 0) {
                    this._goToGhostItem = true
                }
                if (index >= itemsCount) {
                    index = itemsCount - index
                }
                index %= itemsCount;
                if (index < 0) {
                    index += itemsCount
                }
                return index
            },
            _clean: function() {
                this.callBase();
                this._cleanIndicators();
                this._cleanNavButtons()
            },
            _dispose: function() {
                clearTimeout(this._slideshowTimer);
                this.callBase()
            },
            _updateSelection: function(addedSelection, removedSelection) {
                this._stopItemAnimations();
                this._renderNavButtonsVisibility();
                this._renderSelectedItem();
                this._relocateItems(addedSelection[0], removedSelection[0]);
                this._renderSelectedPageIndicator()
            },
            _relocateItems: function(newIndex, prevIndex, withoutAnimation) {
                if (void 0 === prevIndex) {
                    prevIndex = newIndex
                }
                var indexOffset = this._calculateIndexOffset(newIndex, prevIndex);
                this._renderContainerPosition(indexOffset, this.option("animationEnabled") && !withoutAnimation).done(function() {
                    this._setFocusOnSelect();
                    this._userInteraction = false;
                    this._setupSlideShow()
                })
            },
            _focusInHandler: function(e) {
                if (fx.isAnimating(this._$container) || this._userInteraction) {
                    return
                }
                this.callBase.apply(this, arguments)
            },
            _focusOutHandler: function(e) {
                if (fx.isAnimating(this._$container) || this._userInteraction) {
                    return
                }
                this.callBase.apply(this, arguments)
            },
            _selectFocusedItem: $.noop,
            _moveFocus: function(location) {
                this._stopItemAnimations();
                this.callBase.apply(this, arguments);
                var index = this.itemElements().index(this.option("focusedElement"));
                this.goToItem(index, this.option("animationEnabled"))
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._reviseDimensions()
                }
            },
            _calculateIndexOffset: function(newIndex, lastIndex) {
                if (void 0 === lastIndex) {
                    lastIndex = newIndex
                }
                var indexOffset = lastIndex - newIndex;
                if (this.option("loop") && !this._needLongMove && this._goToGhostItem) {
                    if (this._isItemOnFirstPage(newIndex) && this._isItemOnLastPage(lastIndex)) {
                        indexOffset = -this._itemsPerPage()
                    } else {
                        if (this._isItemOnLastPage(newIndex) && this._isItemOnFirstPage(lastIndex)) {
                            indexOffset = this._itemsPerPage()
                        }
                    }
                    this._goToGhostItem = false
                }
                this._needLongMove = false;
                indexOffset -= lastIndex;
                return indexOffset
            },
            _isItemOnLastPage: function(itemIndex) {
                return itemIndex >= this._itemsCount() - this._itemsPerPage()
            },
            _isItemOnFirstPage: function(itemIndex) {
                return itemIndex <= this._itemsPerPage()
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "width":
                    case "initialItemWidth":
                        this.callBase.apply(this, arguments);
                        this._dimensionChanged();
                        break;
                    case "animationDuration":
                        this._renderNavButtonsVisibility();
                        break;
                    case "animationEnabled":
                        break;
                    case "loop":
                        this.option("loopItemFocus", value);
                        this.element().toggleClass(GALLERY_LOOP_CLASS, value);
                        this._renderDuplicateItems();
                        this._renderItemPositions();
                        this._renderNavButtonsVisibility();
                        return;
                    case "showIndicator":
                        this._renderIndicator();
                        return;
                    case "showNavButtons":
                        this._renderNavButtons();
                        return;
                    case "slideshowDelay":
                        this._setupSlideShow();
                        return;
                    case "wrapAround":
                    case "stretchImages":
                        this._renderItemSizes();
                        this._renderItemPositions();
                        break;
                    case "swipeEnabled":
                    case "indicatorEnabled":
                        this._renderUserInteraction();
                        return;
                    default:
                        this.callBase(args)
                }
            },
            goToItem: function(itemIndex, animation) {
                var selectedIndex = this.option("selectedIndex"),
                    itemsCount = this._itemsCount();
                if (void 0 !== animation) {
                    this._animationOverride = animation
                }
                itemIndex = this._fitIndex(itemIndex);
                this._deferredAnimate = $.Deferred();
                if (itemIndex > itemsCount - 1 || itemIndex < 0 || selectedIndex === itemIndex) {
                    return this._deferredAnimate.resolveWith(this).promise()
                }
                this.option("selectedIndex", itemIndex);
                return this._deferredAnimate.promise()
            },
            prevItem: function(animation) {
                return this.goToItem(this.option("selectedIndex") - 1, animation)
            },
            nextItem: function(animation) {
                return this.goToItem(this.option("selectedIndex") + 1, animation)
            }
        });
        registerComponent("dxGallery", Gallery);
        module.exports = Gallery
    },
    /*!******************************!*\
      !*** ./Scripts/ui/lookup.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            compareVersions = __webpack_require__( /*! ../core/utils/version */ 45).compare,
            support = __webpack_require__( /*! ../core/utils/support */ 48),
            browser = __webpack_require__( /*! ../core/utils/browser */ 18),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            inkRipple = __webpack_require__( /*! ./widget/utils.ink_ripple */ 197),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            DropDownList = __webpack_require__( /*! ./drop_down_editor/ui.drop_down_list */ 204),
            themes = __webpack_require__( /*! ./themes */ 143),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            Popover = __webpack_require__( /*! ./popover */ 202);
        var LOOKUP_CLASS = "dx-lookup",
            LOOKUP_SEARCH_CLASS = "dx-lookup-search",
            LOOKUP_SEARCH_WRAPPER_CLASS = "dx-lookup-search-wrapper",
            LOOKUP_FIELD_CLASS = "dx-lookup-field",
            LOOKUP_ARROW_CLASS = "dx-lookup-arrow",
            LOOKUP_FIELD_WRAPPER_CLASS = "dx-lookup-field-wrapper",
            LOOKUP_POPUP_CLASS = "dx-lookup-popup",
            LOOKUP_POPUP_WRAPPER_CLASS = "dx-lookup-popup-wrapper",
            LOOKUP_POPUP_SEARCH_CLASS = "dx-lookup-popup-search",
            LOOKUP_POPOVER_MODE = "dx-lookup-popover-mode",
            LOOKUP_EMPTY_CLASS = "dx-lookup-empty",
            LOOKUP_POPUP_VALIDATION_MESSAGE = "dx-lookup-validation-message",
            LOOKUP_POPUP_INVALID_CLASS = "dx-lookup-invalid";
        var POPUP_OPTION_MAP = {
            popupWidth: "width",
            popupHeight: "height"
        };
        var Lookup = DropDownList.inherit({
            _supportedKeys: function() {
                return $.extend(this.callBase(), {
                    space: function(e) {
                        e.preventDefault();
                        this._validatedOpening()
                    },
                    enter: function(e) {
                        this._validatedOpening()
                    }
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    showNextButton: {
                        since: "15.1",
                        message: "Use the 'pageLoadMode' option instead"
                    },
                    pagingEnabled: {
                        since: "15.1",
                        message: "Use the 'dataSource.paginate' option instead"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    title: "",
                    titleTemplate: "title",
                    onTitleRendered: null,
                    placeholder: messageLocalization.format("Select"),
                    searchPlaceholder: messageLocalization.format("Search"),
                    searchEnabled: true,
                    cleanSearchOnOpening: true,
                    fullScreen: false,
                    showCancelButton: true,
                    showClearButton: false,
                    clearButtonText: messageLocalization.format("Clear"),
                    applyButtonText: messageLocalization.format("Done"),
                    popupWidth: function() {
                        return .8 * $(window).width()
                    },
                    popupHeight: function() {
                        return .8 * $(window).height()
                    },
                    shading: true,
                    closeOnOutsideClick: false,
                    position: void 0,
                    animation: {},
                    pullRefreshEnabled: false,
                    useNativeScrolling: true,
                    pullingDownText: messageLocalization.format("dxList-pullingDownText"),
                    pulledDownText: messageLocalization.format("dxList-pulledDownText"),
                    refreshingText: messageLocalization.format("dxList-refreshingText"),
                    pageLoadingText: messageLocalization.format("dxList-pageLoadingText"),
                    onScroll: null,
                    onPullRefresh: null,
                    onPageLoading: null,
                    pageLoadMode: "scrollBottom",
                    showNextButton: void 0,
                    nextButtonText: messageLocalization.format("dxList-nextButtonText"),
                    grouped: false,
                    groupTemplate: "group",
                    usePopover: false,
                    showDropButton: false,
                    showPopupTitle: true,
                    focusStateEnabled: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return !support.nativeScrolling
                    },
                    options: {
                        useNativeScrolling: false
                    }
                }, {
                    device: function(device) {
                        return !support.nativeScrolling && !devices.isSimulator() && "generic" === devices.real().platform && "generic" === device.platform
                    },
                    options: {
                        usePopover: true,
                        popupHeight: "auto"
                    }
                }, {
                    device: function(device) {
                        return browser.msie && compareVersions(browser.version, 9) < 0
                    },
                    options: {
                        usePopover: false
                    }
                }, {
                    device: function(device) {
                        return "win" === device.platform && device.phone && device.version && 8 === device.version[0]
                    },
                    options: {
                        showCancelButton: false,
                        fullScreen: true
                    }
                }, {
                    device: function(device) {
                        return "win" === device.platform && !device.phone && device.version && 8 === device.version[0]
                    },
                    options: {
                        popupWidth: function() {
                            return $(window).width()
                        }
                    }
                }, {
                    device: {
                        platform: "ios",
                        phone: true
                    },
                    options: {
                        fullScreen: true
                    }
                }, {
                    device: {
                        platform: "ios",
                        tablet: true
                    },
                    options: {
                        popupWidth: function() {
                            return .4 * Math.min($(window).width(), $(window).height())
                        },
                        popupHeight: "auto",
                        usePopover: true,
                        useInkRipple: false
                    }
                }, {
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _dataSourceOptions: function() {
                this._suppressDeprecatedWarnings();
                var pagingEnabled = commonUtils.ensureDefined(this.option("pagingEnabled"), true);
                pagingEnabled = commonUtils.isDefined(this.option("showNextButton")) ? pagingEnabled || this.option("showNextButton") : pagingEnabled;
                this._resumeDeprecatedWarnings();
                return $.extend(this.callBase(), {
                    paginate: pagingEnabled
                })
            },
            _inputWrapper: function() {
                return this.element().find("." + LOOKUP_FIELD_WRAPPER_CLASS)
            },
            _render: function() {
                this.callBase();
                this.element().addClass(LOOKUP_CLASS).toggleClass(LOOKUP_POPOVER_MODE, this.option("usePopover"))
            },
            _fireContentReadyAction: $.noop,
            _popupWrapperClass: function() {
                return ""
            },
            _renderInput: function() {
                var fieldClickAction = this._createAction($.proxy(function() {
                    this._validatedOpening()
                }, this));
                this._$field = $("<div>").addClass(LOOKUP_FIELD_CLASS).on(eventUtils.addNamespace(clickEvent.name, this.NAME), function(e) {
                    fieldClickAction({
                        jQueryEvent: e
                    })
                });
                var $arrow = $("<div>").addClass(LOOKUP_ARROW_CLASS);
                this._$fieldWrapper = $("<div>").addClass(LOOKUP_FIELD_WRAPPER_CLASS).append(this._$field).append($arrow).appendTo(this.element());
                this.option("useInkRipple") && this._renderInkRipple()
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render()
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: this._inputWrapper(),
                    jQueryEvent: e
                };
                if (value) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _renderField: function() {
                var fieldTemplate = this._getTemplateByOption("fieldTemplate");
                if (fieldTemplate && this.option("fieldTemplate")) {
                    this._renderFieldTemplate(fieldTemplate);
                    return
                }
                this._$field.text(this.option("displayValue") || this.option("placeholder"));
                this.element().toggleClass(LOOKUP_EMPTY_CLASS, !this.option("selectedItem"))
            },
            _renderFieldTemplate: function(template) {
                this._$field.empty();
                var data = this._fieldRenderData();
                template.render({
                    model: data,
                    container: this._$field
                })
            },
            _fieldRenderData: function() {
                return this.option("selectedItem")
            },
            _popupShowingHandler: function() {
                var validationError;
                if (this._$popupValidationMessage) {
                    validationError = this.option("validationError");
                    if (validationError && validationError.message) {
                        this._$popupValidationMessage.text(validationError.message);
                        this._popup.content().addClass(LOOKUP_POPUP_INVALID_CLASS)
                    } else {
                        this._popup.content().removeClass(LOOKUP_POPUP_INVALID_CLASS)
                    }
                }
                this.callBase.apply(this, arguments);
                if (this.option("cleanSearchOnOpening")) {
                    if (this.option("searchEnabled") && this._searchBox.option("value")) {
                        this._searchBox.option("value", "");
                        this._searchCanceled();
                        this._searchDataSource()
                    }
                    this._list && this._list.option("focusedElement", null)
                }
                this._attachSearchChildProcessor()
            },
            _renderPopup: function() {
                if (this.option("usePopover") && !this.option("fullScreen")) {
                    this._renderPopover()
                } else {
                    this.callBase()
                }
                this._$popup.addClass(LOOKUP_POPUP_CLASS);
                this._popup._wrapper().addClass(LOOKUP_POPUP_WRAPPER_CLASS)
            },
            _popupOptionMap: function(optionName) {
                return POPUP_OPTION_MAP[optionName] || optionName
            },
            _renderPopover: function() {
                this._popup = this._createComponent(this._$popup, Popover, $.extend(this._popupConfig(), {
                    target: this.element(),
                    fullScreen: false,
                    shading: false,
                    closeOnTargetScroll: true,
                    closeOnOutsideClick: true,
                    width: this._isInitialOptionValue("popupWidth") ? $.proxy(function() {
                        return this.element().outerWidth()
                    }, this) : this._popupConfig().width
                }));
                this._popup.on({
                    showing: $.proxy(this._popupShowingHandler, this),
                    shown: $.proxy(this._popupShownHandler, this),
                    hiding: $.proxy(this._popupHidingHandler, this),
                    hidden: $.proxy(this._popupHiddenHandler, this)
                });
                this._popup.option("onContentReady", $.proxy(this._contentReadyHandler, this));
                this._contentReadyHandler()
            },
            _popupHidingHandler: function() {
                this.callBase();
                this.option("focusStateEnabled") && this.focus()
            },
            _preventFocusOnPopup: $.noop,
            _popupConfig: function() {
                var result = $.extend(this.callBase(), {
                    showTitle: this.option("showPopupTitle"),
                    title: this.option("title"),
                    titleTemplate: this._getTemplateByOption("titleTemplate"),
                    onTitleRendered: this.option("onTitleRendered"),
                    toolbarItems: this._getPopupToolbarItems(),
                    fullScreen: this.option("fullScreen"),
                    shading: this.option("shading"),
                    closeOnTargetScroll: false,
                    closeOnOutsideClick: this.option("closeOnOutsideClick"),
                    onPositioned: null
                });
                delete result.animation;
                delete result.position;
                result.maxHeight = function() {
                    return $(window).height()
                };
                $.each(["position", "animation", "popupWidth", "popupHeight"], $.proxy(function(_, optionName) {
                    if (void 0 !== this.option(optionName)) {
                        result[this._popupOptionMap(optionName)] = this.option(optionName)
                    }
                }, this));
                return result
            },
            _getPopupToolbarItems: function() {
                var buttonsConfig = "useButtons" === this.option("applyValueMode") ? this._popupToolbarItemsConfig() : [];
                var cancelButton = this._getCancelButtonConfig();
                if (cancelButton) {
                    buttonsConfig.push(cancelButton)
                }
                var clearButton = this._getClearButtonConfig();
                if (clearButton) {
                    buttonsConfig.push(clearButton)
                }
                return this._applyButtonsLocation(buttonsConfig)
            },
            _popupToolbarItemsConfig: function() {
                return [{
                    shortcut: "done",
                    options: {
                        onClick: $.proxy(this._applyButtonHandler, this),
                        text: this.option("applyButtonText")
                    }
                }]
            },
            _getCancelButtonConfig: function() {
                return this.option("showCancelButton") ? {
                    shortcut: "cancel",
                    onClick: $.proxy(this._cancelButtonHandler, this),
                    options: {
                        text: this.option("cancelButtonText")
                    }
                } : null
            },
            _getClearButtonConfig: function() {
                return this.option("showClearButton") ? {
                    shortcut: "clear",
                    onClick: $.proxy(this._resetValue, this),
                    options: {
                        text: this.option("clearButtonText")
                    }
                } : null
            },
            _applyButtonHandler: function() {
                this.option("value", this._valueGetter(this._currentSelectedItem()));
                this.callBase()
            },
            _cancelButtonHandler: function() {
                this._refreshSelected();
                this.callBase()
            },
            _refreshPopupVisibility: $.noop,
            _dimensionChanged: function() {
                if (this.option("usePopover") && !this.option("popupWidth")) {
                    this.option("popupWidth", this.element().width())
                }
            },
            _input: function() {
                return this._$searchBox || this.callBase()
            },
            _renderPopupContent: function() {
                if ("dxPopup" === this._popup.NAME) {
                    this._$popupValidationMessage = $("<div>").addClass(LOOKUP_POPUP_VALIDATION_MESSAGE).appendTo(this._popup.content())
                }
                this.callBase();
                this._renderSearch();
                this._attachSearchChildProcessor()
            },
            _attachSearchChildProcessor: function() {
                if (this.option("searchEnabled") && this._searchBox) {
                    this._listKeyboardProcessor = this._searchBox._keyboardProcessor.attachChildProcessor();
                    this._setListOption("_keyboardProcessor", this._listKeyboardProcessor)
                } else {
                    this._setListOption("_keyboardProcessor", void 0)
                }
            },
            _renderSearch: function() {
                this._$searchWrapper && this._$searchWrapper.remove();
                delete this._$searchWrapper;
                this._$searchBox && this._$searchBox.remove();
                delete this._$searchBox;
                delete this._searchBox;
                if (this.option("searchEnabled")) {
                    var $searchWrapper = this._$searchWrapper = $("<div>").addClass(LOOKUP_SEARCH_WRAPPER_CLASS);
                    var $searchBox = this._$searchBox = $("<div>").addClass(LOOKUP_SEARCH_CLASS).appendTo($searchWrapper);
                    var currentDevice = devices.current(),
                        searchMode = currentDevice.android && currentDevice.version[0] >= 5 ? "text" : "search";
                    this._searchBox = this._createComponent($searchBox, "dxTextBox", {
                        mode: searchMode,
                        showClearButton: true,
                        valueChangeEvent: this.option("valueChangeEvent"),
                        onValueChanged: $.proxy(this._searchHandler, this)
                    });
                    this._registerSearchKeyHandlers();
                    $searchWrapper.insertBefore(this._$list)
                }
                this._renderSearchVisibility();
                this._setSearchPlaceholder()
            },
            _selectListItemHandler: function(e) {
                var $itemElement = this._list.option("focusedElement");
                if (!$itemElement) {
                    return
                }
                e.preventDefault();
                this._selectListItem(e.itemData, $itemElement)
            },
            _registerSearchKeyHandlers: function() {
                this._searchBox.registerKeyHandler("escape", $.proxy(this.close, this));
                this._searchBox.registerKeyHandler("enter", $.proxy(this._selectListItemHandler, this));
                this._searchBox.registerKeyHandler("space", $.proxy(this._selectListItemHandler, this));
                this._searchBox.registerKeyHandler("end", $.noop);
                this._searchBox.registerKeyHandler("home", $.noop)
            },
            _renderSearchVisibility: function() {
                if (this._popup) {
                    this._popup._wrapper().toggleClass(LOOKUP_POPUP_SEARCH_CLASS, this.option("searchEnabled"))
                }
            },
            _setSearchPlaceholder: function() {
                if (!this._$searchBox) {
                    return
                }
                var minSearchLength = this.option("minSearchLength");
                var placeholder = this.option("searchPlaceholder");
                if (minSearchLength && placeholder === messageLocalization.format("Search")) {
                    placeholder = messageLocalization.getFormatter("dxLookup-searchPlaceholder")(minSearchLength)
                }
                this._searchBox.option("placeholder", placeholder)
            },
            _setAriaTargetForList: $.noop,
            _renderList: function() {
                this.callBase();
                this._list.registerKeyHandler("escape", $.proxy(function(e) {
                    this.close()
                }, this))
            },
            _listConfig: function() {
                return $.extend(this.callBase(), {
                    tabIndex: 0,
                    grouped: this.option("grouped"),
                    groupTemplate: this._getTemplateByOption("groupTemplate"),
                    pullRefreshEnabled: this.option("pullRefreshEnabled"),
                    useNativeScrolling: this.option("useNativeScrolling"),
                    pullingDownText: this.option("pullingDownText"),
                    pulledDownText: this.option("pulledDownText"),
                    refreshingText: this.option("refreshingText"),
                    pageLoadingText: this.option("pageLoadingText"),
                    onScroll: this.option("onScroll"),
                    onPullRefresh: this.option("onPullRefresh"),
                    onPageLoading: this.option("onPageLoading"),
                    pageLoadMode: this._getPageLoadMode(),
                    nextButtonText: this.option("nextButtonText"),
                    _keyboardProcessor: this._listKeyboardProcessor,
                    onFocusIn: $.proxy(this._onFocusInHandler, this),
                    onSelectionChanged: this._getSelectionChangedHandler()
                })
            },
            _getSelectionChangedHandler: function() {
                return this.option("showSelectionControls") ? $.proxy(this._selectionChangeHandler, this) : $.noop
            },
            _onFocusInHandler: function() {
                this._setListOption("_keyboardProcessor", void 0)
            },
            _listContentReadyHandler: function() {
                this._popup.repaint();
                this.callBase.apply(this, arguments);
                this._refreshSelected()
            },
            _getPageLoadMode: function() {
                this._suppressDeprecatedWarnings();
                var result = commonUtils.isDefined(this.option("showNextButton")) ? "nextButton" : this.option("pageLoadMode");
                this._resumeDeprecatedWarnings();
                return result
            },
            _setFocusPolicy: function() {
                if (!this.option("focusStateEnabled")) {
                    return
                }
                if (this.option("searchEnabled")) {
                    this._searchBox.focus()
                } else {
                    this._$list.focus()
                }
            },
            _attachChildKeyboardEvents: $.noop,
            _focusTarget: function() {
                return this._$field
            },
            _keyboardEventBindingTarget: function() {
                return this._$field
            },
            _listItemClickHandler: function(e) {
                this._selectListItem(e.itemData, e.jQueryEvent.currentTarget)
            },
            _selectListItem: function(itemData, target) {
                this._list.selectItem(target);
                if ("instantly" === this.option("applyValueMode")) {
                    this._applyButtonHandler()
                }
            },
            _currentSelectedItem: function() {
                return this.option("grouped") ? this._list.option("selectedItems[0]").items[0] : this._list.option("selectedItems[0]")
            },
            _resetValue: function() {
                this.option("value", null);
                this.option("opened", false)
            },
            _searchValue: function() {
                return this.option("searchEnabled") && this._searchBox ? this._searchBox.option("value") : ""
            },
            _renderInputValue: function() {
                return this.callBase().always($.proxy(function() {
                    this._renderField();
                    this._refreshSelected()
                }, this))
            },
            _renderPlaceholder: function() {
                if (0 === this.element().find("input").length) {
                    return
                }
                this.callBase()
            },
            _clean: function() {
                this._$fieldWrapper.remove();
                this._$searchBox = null;
                this.callBase()
            },
            _optionChanged: function(args) {
                var name = args.name;
                var value = args.value;
                switch (name) {
                    case "searchEnabled":
                        this._popup && this._renderSearch();
                        this._attachSearchChildProcessor();
                        break;
                    case "searchPlaceholder":
                        this._setSearchPlaceholder();
                        break;
                    case "minSearchLength":
                        this._setSearchPlaceholder();
                        this.callBase.apply(this, arguments);
                        break;
                    case "title":
                    case "titleTemplate":
                    case "onTitleRendered":
                    case "shading":
                    case "animation":
                    case "position":
                    case "closeOnOutsideClick":
                        this._setPopupOption(name);
                        break;
                    case "fullScreen":
                    case "usePopover":
                    case "placeholder":
                        this._invalidate();
                        break;
                    case "clearButtonText":
                    case "showClearButton":
                    case "showCancelButton":
                        this._setPopupOption("toolbarItems", this._getPopupToolbarItems());
                        break;
                    case "applyValueMode":
                        this.callBase.apply(this, arguments);
                        break;
                    case "popupWidth":
                        this._setPopupOption("popupWidth", "auto" === value ? this.initialOption("popupWidth") : value);
                        break;
                    case "popupHeight":
                        this._setPopupOption("popupHeight", "auto" === value ? this.initialOption("popupHeight") : value);
                        break;
                    case "pullRefreshEnabled":
                    case "useNativeScrolling":
                    case "pullingDownText":
                    case "pulledDownText":
                    case "refreshingText":
                    case "pageLoadingText":
                    case "onScroll":
                    case "onPullRefresh":
                    case "onPageLoading":
                    case "nextButtonText":
                    case "grouped":
                    case "groupTemplate":
                        this._setListOption(name);
                        break;
                    case "showNextButton":
                    case "pageLoadMode":
                        this._setListOption("pageLoadMode", this._getPageLoadMode());
                        break;
                    case "cleanSearchOnOpening":
                        break;
                    default:
                        this.callBase.apply(this, arguments)
                }
            },
            focus: function() {
                this.option("opened") ? this._setFocusPolicy() : this._focusTarget().focus()
            },
            field: function() {
                return this._$field
            }
        });
        registerComponent("dxLookup", Lookup);
        module.exports = Lookup
    },
    /*!***************************!*\
      !*** ./Scripts/ui/map.js ***!
      \***************************/
    function(module, exports, __webpack_require__) {
        var Map = __webpack_require__( /*! ./map/ui.map */ 290),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43);
        registerComponent("dxMap", Map);
        module.exports = Map
    },
    /*!**********************************!*\
      !*** ./Scripts/ui/map/ui.map.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            config = __webpack_require__( /*! ../../core/config */ 15),
            wrapToArray = __webpack_require__( /*! ../../core/utils/array */ 111).wrapToArray;
        var PROVIDERS = {
            googleStatic: __webpack_require__( /*! ./ui.map.provider.google_static */ 291),
            google: __webpack_require__( /*! ./ui.map.provider.dynamic.google */ 293),
            bing: __webpack_require__( /*! ./ui.map.provider.dynamic.bing */ 295)
        };
        var MAP_CLASS = "dx-map",
            MAP_CONTAINER_CLASS = "dx-map-container",
            MAP_SHIELD_CLASS = "dx-map-shield",
            NATIVE_CLICK_CLASS = "dx-native-click";
        var Map = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    bounds: {
                        northEast: null,
                        southWest: null
                    },
                    center: {
                        lat: 0,
                        lng: 0
                    },
                    zoom: 1,
                    width: 300,
                    height: 300,
                    type: "roadmap",
                    provider: "google",
                    autoAdjust: true,
                    markers: [],
                    markerIconSrc: null,
                    onMarkerAdded: null,
                    onMarkerRemoved: null,
                    routes: [],
                    onRouteAdded: null,
                    onRouteRemoved: null,
                    key: {
                        bing: "",
                        google: "",
                        googleStatic: ""
                    },
                    controls: false,
                    onReady: null,
                    onUpdated: null,
                    onClick: null
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this.element().addClass(MAP_CLASS).addClass(NATIVE_CLICK_CLASS);
                this._asyncQueue = [];
                this._checkOption("provider");
                this._checkOption("markers");
                this._checkOption("routes");
                this._initContainer();
                this._grabEvents();
                this._rendered = {}
            },
            _checkOption: function(option) {
                var value = this.option(option);
                if ("provider" === option && support.winJS && "google" === value) {
                    throw errors.Error("E1024")
                }
                if ("markers" === option && !$.isArray(value)) {
                    throw errors.Error("E1022")
                }
                if ("routes" === option && !$.isArray(value)) {
                    throw errors.Error("E1023")
                }
            },
            _initContainer: function() {
                this._$container = $("<div />").addClass(MAP_CONTAINER_CLASS);
                this.element().append(this._$container)
            },
            _grabEvents: function() {
                var eventName = eventUtils.addNamespace(pointerEvents.down, this.NAME);
                this.element().on(eventName, $.proxy(this._cancelEvent, this))
            },
            _cancelEvent: function(e) {
                var cancelByProvider = this._provider.cancelEvents && !this.option("disabled");
                if (!config.designMode && cancelByProvider) {
                    e.stopPropagation()
                }
            },
            _saveRendered: function(option) {
                var value = this.option(option);
                this._rendered[option] = value.slice()
            },
            _render: function() {
                this.callBase();
                this._renderShield();
                this._saveRendered("markers");
                this._saveRendered("routes");
                this._queueAsyncAction("render", this._rendered.markers, this._rendered.routes)
            },
            _renderShield: function() {
                var $shield;
                if (window.DevExpress && DevExpress.designMode || this.option("disabled")) {
                    $shield = $("<div/>").addClass(MAP_SHIELD_CLASS);
                    this.element().append($shield)
                } else {
                    $shield = this.element().find("." + MAP_SHIELD_CLASS);
                    $shield.remove()
                }
            },
            _clean: function() {
                this._cleanFocusState();
                if (!this._provider) {
                    return
                }
                var that = this;
                this._queueAsyncAction("clean").done(function() {
                    that.setOptionSilent("bounds", {
                        northEast: null,
                        southWest: null
                    })
                })
            },
            _dispose: function() {
                this.callBase();
                this._currentAsyncAction && this._currentAsyncAction.reject()
            },
            _optionChanged: function(args) {
                var name = args.name;
                if (this._cancelOptionChange) {
                    return
                }
                var changeBag = this._optionChangeBag;
                this._optionChangeBag = null;
                switch (name) {
                    case "disabled":
                        this._renderShield();
                        this.callBase(args);
                        break;
                    case "width":
                    case "height":
                        this.callBase(args);
                        this._dimensionChanged();
                        break;
                    case "provider":
                        this._invalidate();
                        break;
                    case "key":
                        errors.log("W1001");
                        break;
                    case "bounds":
                        this._queueAsyncAction("updateBounds");
                        break;
                    case "center":
                        this._queueAsyncAction("updateCenter");
                        break;
                    case "zoom":
                        this._queueAsyncAction("updateZoom");
                        break;
                    case "type":
                        this._queueAsyncAction("updateMapType");
                        break;
                    case "controls":
                        this._queueAsyncAction("updateControls", this._rendered.markers, this._rendered.routes);
                        break;
                    case "autoAdjust":
                        this._queueAsyncAction("adjustViewport");
                        break;
                    case "markers":
                    case "routes":
                        this._checkOption(name);
                        var prevValue = this._rendered[name];
                        this._saveRendered(name);
                        this._queueAsyncAction("update" + inflector.titleize(name), changeBag ? changeBag.removed : prevValue, changeBag ? changeBag.added : this._rendered[name]).done(function() {
                            if (changeBag) {
                                var deferred = changeBag.deferred;
                                deferred.resolve.apply(deferred, arguments)
                            }
                        });
                        break;
                    case "markerIconSrc":
                        this._queueAsyncAction("updateMarkers", this._rendered.markers, this._rendered.markers);
                        break;
                    case "onReady":
                    case "onUpdated":
                    case "onMarkerAdded":
                    case "onMarkerRemoved":
                    case "onRouteAdded":
                    case "onRouteRemoved":
                    case "onClick":
                        break;
                    default:
                        this.callBase.apply(this, arguments)
                }
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _dimensionChanged: function() {
                this._queueAsyncAction("updateDimensions")
            },
            _queueAsyncAction: function(name) {
                var deferred = $.Deferred(),
                    emptyQueue = !this._asyncQueue.length;
                this._asyncQueue.push({
                    name: name,
                    options: $.makeArray(arguments).slice(1),
                    deferred: deferred
                });
                if (emptyQueue) {
                    this._enqueueAsyncAction()
                }
                return deferred.promise()
            },
            _enqueueAsyncAction: function() {
                var asyncQueue = this._asyncQueue,
                    emptyQueue = !asyncQueue.length;
                if (emptyQueue) {
                    return
                }
                var that = this;
                this._execAsyncAction(asyncQueue[0]).done(function() {
                    asyncQueue.shift();
                    that._enqueueAsyncAction()
                })
            },
            _execAsyncAction: function(action) {
                var deferred = this._currentAsyncAction = $.Deferred();
                var actionName = action.name,
                    actionOptions = action.options,
                    actionDeferred = action.deferred,
                    provider = this._getProvider(actionName);
                provider[actionName].apply(provider, actionOptions).done($.proxy(function(mapRefreshed) {
                    if ("rejected" === deferred.state()) {
                        return
                    }
                    actionDeferred.resolve.apply(actionDeferred, $.makeArray(arguments).slice(1));
                    if (mapRefreshed) {
                        this._triggerReadyAction()
                    } else {
                        if ("clean" !== actionName) {
                            this._triggerUpdateAction()
                        }
                    }
                    deferred.resolve()
                }, this));
                return deferred.promise()
            },
            _getProvider: function(actionName) {
                var currentProvider = this.option("provider");
                if ("clean" !== actionName && this._usedProvider !== currentProvider) {
                    this._provider = new PROVIDERS[currentProvider](this, this._$container);
                    this._usedProvider = currentProvider
                }
                return this._provider
            },
            _triggerReadyAction: function() {
                this._createActionByOption("onReady")({
                    originalMap: this._provider.map()
                })
            },
            _triggerUpdateAction: function() {
                this._createActionByOption("onUpdated")()
            },
            setOptionSilent: function(name, value) {
                this._cancelOptionChange = true;
                this.option(name, value);
                this._cancelOptionChange = false
            },
            addMarker: function(marker) {
                return this._addFunction("markers", marker)
            },
            removeMarker: function(marker) {
                return this._removeFunction("markers", marker)
            },
            addRoute: function(route) {
                return this._addFunction("routes", route)
            },
            removeRoute: function(route) {
                return this._removeFunction("routes", route)
            },
            _addFunction: function(optionName, addingValue) {
                var optionValue = this.option(optionName),
                    addingValues = wrapToArray(addingValue);
                optionValue.push.apply(optionValue, addingValues);
                return this._partialArrayOptionChange(optionName, optionValue, addingValues, [])
            },
            _removeFunction: function(optionName, removingValue) {
                var optionValue = this.option(optionName),
                    removingValues = wrapToArray(removingValue);
                $.each(removingValues, function(removingIndex, removingValue) {
                    var index = $.isNumeric(removingValue) ? removingValue : $.inArray(removingValue, optionValue);
                    if (index !== -1) {
                        var removing = optionValue.splice(index, 1)[0];
                        removingValues.splice(removingIndex, 1, removing)
                    } else {
                        throw errors.log("E1021", inflector.titleize(optionName.substring(0, optionName.length - 1)), removingValue)
                    }
                });
                return this._partialArrayOptionChange(optionName, optionValue, [], removingValues)
            },
            _partialArrayOptionChange: function(optionName, optionValue, addingValues, removingValues) {
                var deferred = $.Deferred(),
                    that = this,
                    changeDeferred = $.Deferred();
                this._optionChangeBag = {
                    deferred: changeDeferred,
                    added: addingValues,
                    removed: removingValues
                };
                this.option(optionName, optionValue);
                changeDeferred.done(function(result) {
                    deferred.resolveWith(that, result && result.length > 1 ? [result] : result)
                });
                return deferred.promise()
            }
        });
        module.exports = Map
    },
    /*!*********************************************************!*\
      !*** ./Scripts/ui/map/ui.map.provider.google_static.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Provider = __webpack_require__( /*! ./ui.map.provider */ 292),
            Color = __webpack_require__( /*! ../../color */ 26),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        var GOOGLE_STATIC_URL = "https://maps.google.com/maps/api/staticmap?";
        var GoogleStaticProvider = Provider.inherit({
            _locationToString: function(location) {
                var latlng = this._getLatLng(location);
                return latlng ? latlng.lat + "," + latlng.lng : location.toString().replace(/ /g, "+")
            },
            _renderImpl: function() {
                return this._updateMap()
            },
            updateDimensions: function() {
                return this._updateMap()
            },
            updateMapType: function() {
                return this._updateMap()
            },
            updateBounds: function() {
                return $.Deferred().resolve().promise()
            },
            updateCenter: function() {
                return this._updateMap()
            },
            updateZoom: function() {
                return this._updateMap()
            },
            updateControls: function() {
                return $.Deferred().resolve().promise()
            },
            addMarkers: function(options) {
                var that = this;
                return this._updateMap().done(function() {
                    $.each(options, function(_, options) {
                        that._fireMarkerAddedAction({
                            options: options
                        })
                    })
                })
            },
            removeMarkers: function(options) {
                var that = this;
                return this._updateMap().done(function() {
                    $.each(options, function(_, options) {
                        that._fireMarkerRemovedAction({
                            options: options
                        })
                    })
                })
            },
            adjustViewport: function() {
                return $.Deferred().resolve().promise()
            },
            addRoutes: function(options) {
                var that = this;
                return this._updateMap().done(function() {
                    $.each(options, function(_, options) {
                        that._fireRouteAddedAction({
                            options: options
                        })
                    })
                })
            },
            removeRoutes: function(options) {
                var that = this;
                return this._updateMap().done(function() {
                    $.each(options, function(_, options) {
                        that._fireRouteRemovedAction({
                            options: options
                        })
                    })
                })
            },
            clean: function() {
                this._$container.css("background-image", "none");
                this._$container.off(this._addEventNamespace(clickEvent.name));
                return $.Deferred().resolve().promise()
            },
            mapRendered: function() {
                return true
            },
            _updateMap: function() {
                var key = this._keyOption("googleStatic"),
                    $container = this._$container;
                var requestOptions = ["sensor=false", "size=" + $container.width() + "x" + $container.height(), "maptype=" + this._option("type"), "center=" + this._locationToString(this._option("center")), "zoom=" + this._option("zoom"), this._markersSubstring()];
                requestOptions.push.apply(requestOptions, this._routeSubstrings());
                if (key) {
                    requestOptions.push("key=" + key)
                }
                var request = GOOGLE_STATIC_URL + requestOptions.join("&");
                this._$container.css("background", 'url("' + request + '") no-repeat 0 0');
                this._attachClickEvent();
                return $.Deferred().resolve(true).promise()
            },
            _markersSubstring: function() {
                var that = this,
                    markers = [],
                    markerIcon = this._option("markerIconSrc");
                if (markerIcon) {
                    markers.push("icon:" + markerIcon)
                }
                $.each(this._option("markers"), function(_, marker) {
                    markers.push(that._locationToString(marker.location))
                });
                return "markers=" + markers.join("|")
            },
            _routeSubstrings: function() {
                var that = this,
                    routes = [];
                $.each(this._option("routes"), function(_, route) {
                    var color = new Color(route.color || that._defaultRouteColor()).toHex().replace("#", "0x"),
                        opacity = Math.round(255 * (route.opacity || that._defaultRouteOpacity())).toString(16),
                        width = route.weight || that._defaultRouteWeight(),
                        locations = [];
                    $.each(route.locations, function(_, routePoint) {
                        locations.push(that._locationToString(routePoint))
                    });
                    routes.push("path=color:" + color + opacity + "|weight:" + width + "|" + locations.join("|"))
                });
                return routes
            },
            _attachClickEvent: function() {
                var that = this,
                    eventName = this._addEventNamespace(clickEvent.name);
                this._$container.off(eventName).on(eventName, function(e) {
                    that._fireClickAction({
                        jQueryEvent: e
                    })
                })
            }
        });
        GoogleStaticProvider.remapConstant = function(newValue) {
            GOOGLE_STATIC_URL = newValue
        };
        module.exports = GoogleStaticProvider
    },
    /*!*******************************************!*\
      !*** ./Scripts/ui/map/ui.map.provider.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        var abstract = Class.abstract;
        var Provider = Class.inherit({
            _defaultRouteWeight: function() {
                return 5
            },
            _defaultRouteOpacity: function() {
                return .5
            },
            _defaultRouteColor: function() {
                return "#0000FF"
            },
            cancelEvents: false,
            ctor: function(map, $container) {
                this._mapWidget = map;
                this._$container = $container
            },
            render: function(markerOptions, routeOptions) {
                var deferred = $.Deferred();
                this._renderImpl().done($.proxy(function() {
                    var markersPromise = this._applyFunctionIfNeeded("addMarkers", markerOptions);
                    var routesPromise = this._applyFunctionIfNeeded("addRoutes", routeOptions);
                    $.when(markersPromise, routesPromise).done(function() {
                        deferred.resolve(true)
                    })
                }, this));
                return deferred.promise()
            },
            _renderImpl: abstract,
            updateDimensions: abstract,
            updateMapType: abstract,
            updateBounds: abstract,
            updateCenter: abstract,
            updateZoom: abstract,
            updateControls: abstract,
            updateMarkers: function(markerOptionsToRemove, markerOptionsToAdd) {
                var deferred = $.Deferred(),
                    that = this;
                this._applyFunctionIfNeeded("removeMarkers", markerOptionsToRemove).done(function() {
                    that._applyFunctionIfNeeded("addMarkers", markerOptionsToAdd).done(function() {
                        deferred.resolve.apply(deferred, arguments)
                    })
                });
                return deferred.promise()
            },
            addMarkers: abstract,
            removeMarkers: abstract,
            adjustViewport: abstract,
            updateRoutes: function(routeOptionsToRemove, routeOptionsToAdd) {
                var deferred = $.Deferred(),
                    that = this;
                this._applyFunctionIfNeeded("removeRoutes", routeOptionsToRemove).done(function() {
                    that._applyFunctionIfNeeded("addRoutes", routeOptionsToAdd).done(function() {
                        deferred.resolve.apply(deferred, arguments)
                    })
                });
                return deferred.promise()
            },
            addRoutes: abstract,
            removeRoutes: abstract,
            clean: abstract,
            map: function() {
                return this._map
            },
            _option: function(name, value) {
                if (void 0 === value) {
                    return this._mapWidget.option(name)
                }
                this._mapWidget.setOptionSilent(name, value)
            },
            _keyOption: function(providerName) {
                var key = this._option("key");
                return void 0 === key[providerName] ? key : key[providerName]
            },
            _parseTooltipOptions: function(option) {
                return {
                    text: option.text || option,
                    visible: option.isShown || false
                }
            },
            _getLatLng: function(location) {
                if ("string" === typeof location) {
                    var coords = $.map(location.split(","), $.trim),
                        numericRegex = /^[-+]?[0-9]*\.?[0-9]*$/;
                    if (2 === coords.length && coords[0].match(numericRegex) && coords[1].match(numericRegex)) {
                        return {
                            lat: parseFloat(coords[0]),
                            lng: parseFloat(coords[1])
                        }
                    }
                } else {
                    if ($.isArray(location) && 2 === location.length) {
                        return {
                            lat: location[0],
                            lng: location[1]
                        }
                    } else {
                        if ($.isPlainObject(location) && $.isNumeric(location.lat) && $.isNumeric(location.lng)) {
                            return location
                        }
                    }
                }
                return null
            },
            _isBoundsSetted: function() {
                return this._option("bounds.northEast") && this._option("bounds.southWest")
            },
            _addEventNamespace: function(name) {
                return eventUtils.addNamespace(name, this._mapWidget.NAME)
            },
            _applyFunctionIfNeeded: function(fnName, array) {
                if (!array.length) {
                    return $.Deferred().resolve().promise()
                }
                return this[fnName](array)
            },
            _createAction: function() {
                var mapWidget = this._mapWidget;
                return mapWidget._createAction.apply(mapWidget, arguments)
            },
            _fireAction: function(name, actionArguments) {
                var option = this._option(name);
                if (option) {
                    this._createAction(option)(actionArguments)
                }
            },
            _fireClickAction: function(actionArguments) {
                this._fireAction("onClick", actionArguments)
            },
            _fireMarkerAddedAction: function(actionArguments) {
                this._fireAction("onMarkerAdded", actionArguments)
            },
            _fireMarkerRemovedAction: function(actionArguments) {
                this._fireAction("onMarkerRemoved", actionArguments)
            },
            _fireRouteAddedAction: function(actionArguments) {
                this._fireAction("onRouteAdded", actionArguments)
            },
            _fireRouteRemovedAction: function(actionArguments) {
                this._fireAction("onRouteRemoved", actionArguments)
            }
        });
        module.exports = Provider
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/map/ui.map.provider.dynamic.google.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            DynamicProvider = __webpack_require__( /*! ./ui.map.provider.dynamic */ 294),
            Color = __webpack_require__( /*! ../../color */ 26);
        var GOOGLE_MAP_READY = "_googleScriptReady",
            GOOGLE_URL = "https://maps.google.com/maps/api/js?sensor=false&callback=" + GOOGLE_MAP_READY;
        var CustomMarker;
        var initCustomMarkerClass = function() {
            CustomMarker = function(options) {
                this._position = options.position;
                this._offset = options.offset;
                this._$overlayContainer = $("<div>").css({
                    position: "absolute",
                    display: "none",
                    cursor: "pointer"
                }).append(options.html);
                this.setMap(options.map)
            };
            CustomMarker.prototype = new google.maps.OverlayView;
            CustomMarker.prototype.onAdd = function() {
                var $pane = $(this.getPanes().overlayMouseTarget);
                $pane.append(this._$overlayContainer);
                this._clickListener = google.maps.event.addDomListener(this._$overlayContainer.get(0), "click", $.proxy(function(e) {
                    google.maps.event.trigger(this, "click");
                    e.preventDefault()
                }, this));
                this.draw()
            };
            CustomMarker.prototype.onRemove = function() {
                google.maps.event.removeListener(this._clickListener);
                this._$overlayContainer.remove()
            };
            CustomMarker.prototype.draw = function() {
                var position = this.getProjection().fromLatLngToDivPixel(this._position);
                this._$overlayContainer.css({
                    left: position.x + this._offset.left,
                    top: position.y + this._offset.top,
                    display: "block"
                })
            }
        };
        var googleMapsLoaded = function() {
            return window.google && window.google.maps
        };
        var googleMapsLoader;
        var GoogleProvider = DynamicProvider.inherit({
            _mapType: function(type) {
                var mapTypes = {
                    hybrid: google.maps.MapTypeId.HYBRID,
                    roadmap: google.maps.MapTypeId.ROADMAP,
                    satellite: google.maps.MapTypeId.SATELLITE
                };
                return mapTypes[type] || mapTypes.hybrid
            },
            _movementMode: function(type) {
                var movementTypes = {
                    driving: google.maps.TravelMode.DRIVING,
                    walking: google.maps.TravelMode.WALKING
                };
                return movementTypes[type] || movementTypes.driving
            },
            _resolveLocation: function(location) {
                var d = $.Deferred();
                var latLng = this._getLatLng(location);
                if (latLng) {
                    d.resolve(new google.maps.LatLng(latLng.lat, latLng.lng))
                } else {
                    this._geocodeLocation(location).done(function(geocodedLocation) {
                        d.resolve(geocodedLocation)
                    })
                }
                return d.promise()
            },
            _geocodedLocations: {},
            _geocodeLocationImpl: function(location) {
                var d = $.Deferred();
                var geocoder = new google.maps.Geocoder;
                geocoder.geocode({
                    address: location
                }, function(results, status) {
                    if (status === google.maps.GeocoderStatus.OK) {
                        d.resolve(results[0].geometry.location)
                    } else {
                        d.resolve(new google.maps.LatLng(0, 0))
                    }
                });
                return d.promise()
            },
            _normalizeLocation: function(location) {
                return {
                    lat: location.lat(),
                    lng: location.lng()
                }
            },
            _normalizeLocationRect: function(locationRect) {
                return {
                    northEast: this._normalizeLocation(locationRect.getNorthEast()),
                    southWest: this._normalizeLocation(locationRect.getSouthWest())
                }
            },
            _loadImpl: function() {
                this._googleMapsLoader = $.Deferred();
                if (googleMapsLoaded()) {
                    this._mapReady()
                } else {
                    if (!googleMapsLoader || "resolved" === googleMapsLoader.state() && !googleMapsLoaded()) {
                        googleMapsLoader = $.Deferred();
                        var key = this._keyOption("google");
                        window[GOOGLE_MAP_READY] = $.proxy(googleMapsLoader.resolve, googleMapsLoader);
                        $.getScript(GOOGLE_URL + (key ? "&key=" + key : ""))
                    }
                    googleMapsLoader.done($.proxy(this._mapReady, this))
                }
                return this._googleMapsLoader.promise()
            },
            _mapReady: function() {
                try {
                    delete window[GOOGLE_MAP_READY]
                } catch (e) {
                    window[GOOGLE_MAP_READY] = void 0
                }
                initCustomMarkerClass();
                this._googleMapsLoader.resolve()
            },
            _init: function() {
                var deferred = $.Deferred(),
                    initPromise = $.Deferred(),
                    controls = this._option("controls");
                this._map = new google.maps.Map(this._$container[0], {
                    zoom: this._option("zoom"),
                    panControl: controls,
                    zoomControl: controls,
                    mapTypeControl: controls,
                    streetViewControl: controls
                });
                var listener = google.maps.event.addListener(this._map, "idle", $.proxy(initPromise.resolve, initPromise));
                $.when(initPromise).done($.proxy(function() {
                    google.maps.event.removeListener(listener);
                    deferred.resolve()
                }, this));
                return deferred.promise()
            },
            _attachHandlers: function() {
                this._boundsChangeListener = google.maps.event.addListener(this._map, "bounds_changed", $.proxy(this._boundsChangeHandler, this));
                this._clickListener = google.maps.event.addListener(this._map, "click", $.proxy(this._clickActionHandler, this))
            },
            _boundsChangeHandler: function() {
                var bounds = this._map.getBounds();
                this._option("bounds", this._normalizeLocationRect(bounds));
                var center = this._map.getCenter();
                this._option("center", this._normalizeLocation(center));
                if (!this._preventZoomChangeEvent) {
                    this._option("zoom", this._map.getZoom())
                }
            },
            _clickActionHandler: function(e) {
                this._fireClickAction({
                    location: this._normalizeLocation(e.latLng)
                })
            },
            updateDimensions: function() {
                var center = this._option("center");
                google.maps.event.trigger(this._map, "resize");
                this._option("center", center);
                return this.updateCenter()
            },
            updateMapType: function() {
                this._map.setMapTypeId(this._mapType(this._option("type")));
                return $.Deferred().resolve().promise()
            },
            updateBounds: function() {
                var deferred = $.Deferred(),
                    that = this;
                var northEastPromise = this._resolveLocation(this._option("bounds.northEast")),
                    southWestPromise = this._resolveLocation(this._option("bounds.southWest"));
                $.when(northEastPromise, southWestPromise).done(function(northEast, southWest) {
                    var bounds = new google.maps.LatLngBounds;
                    bounds.extend(northEast);
                    bounds.extend(southWest);
                    that._map.fitBounds(bounds);
                    deferred.resolve()
                });
                return deferred.promise()
            },
            updateCenter: function() {
                var deferred = $.Deferred(),
                    that = this;
                this._resolveLocation(this._option("center")).done(function(center) {
                    that._map.setCenter(center);
                    that._option("center", that._normalizeLocation(center));
                    deferred.resolve()
                });
                return deferred.promise()
            },
            updateZoom: function() {
                this._map.setZoom(this._option("zoom"));
                return $.Deferred().resolve().promise()
            },
            updateControls: function() {
                var controls = this._option("controls");
                this._map.setOptions({
                    panControl: controls,
                    zoomControl: controls,
                    mapTypeControl: controls,
                    streetViewControl: controls
                });
                return $.Deferred().resolve().promise()
            },
            _renderMarker: function(options) {
                var d = $.Deferred(),
                    that = this;
                this._resolveLocation(options.location).done(function(location) {
                    var marker;
                    if (options.html) {
                        marker = new CustomMarker({
                            map: that._map,
                            position: location,
                            html: options.html,
                            offset: $.extend({
                                top: 0,
                                left: 0
                            }, options.htmlOffset)
                        })
                    } else {
                        marker = new google.maps.Marker({
                            position: location,
                            map: that._map,
                            icon: options.iconSrc || that._option("markerIconSrc")
                        })
                    }
                    var infoWindow = that._renderTooltip(marker, options.tooltip);
                    var listener;
                    if (options.onClick || options.tooltip) {
                        var markerClickAction = that._createAction(options.onClick || $.noop),
                            markerNormalizedLocation = that._normalizeLocation(location);
                        listener = google.maps.event.addListener(marker, "click", function() {
                            markerClickAction({
                                location: markerNormalizedLocation
                            });
                            if (infoWindow) {
                                infoWindow.open(that._map, marker)
                            }
                        })
                    }
                    d.resolve({
                        location: location,
                        marker: marker,
                        listener: listener
                    })
                });
                return d.promise()
            },
            _renderTooltip: function(marker, options) {
                if (!options) {
                    return
                }
                options = this._parseTooltipOptions(options);
                var infoWindow = new google.maps.InfoWindow({
                    content: options.text
                });
                if (options.visible) {
                    infoWindow.open(this._map, marker)
                }
                return infoWindow
            },
            _destroyMarker: function(marker) {
                marker.marker.setMap(null);
                if (marker.listener) {
                    google.maps.event.removeListener(marker.listener)
                }
            },
            _renderRoute: function(options) {
                var d = $.Deferred(),
                    that = this,
                    directionsService = new google.maps.DirectionsService;
                var points = $.map(options.locations, function(point) {
                    return that._resolveLocation(point)
                });
                $.when.apply($, points).done(function() {
                    var locations = $.makeArray(arguments),
                        origin = locations.shift(),
                        destination = locations.pop(),
                        waypoints = $.map(locations, function(location) {
                            return {
                                location: location,
                                stopover: true
                            }
                        });
                    var request = {
                        origin: origin,
                        destination: destination,
                        waypoints: waypoints,
                        optimizeWaypoints: true,
                        travelMode: that._movementMode(options.mode)
                    };
                    directionsService.route(request, function(response, status) {
                        if (status === google.maps.DirectionsStatus.OK) {
                            var color = new Color(options.color || that._defaultRouteColor()).toHex(),
                                directionOptions = {
                                    directions: response,
                                    map: that._map,
                                    suppressMarkers: true,
                                    preserveViewport: true,
                                    polylineOptions: {
                                        strokeWeight: options.weight || that._defaultRouteWeight(),
                                        strokeOpacity: options.opacity || that._defaultRouteOpacity(),
                                        strokeColor: color
                                    }
                                };
                            var route = new google.maps.DirectionsRenderer(directionOptions),
                                bounds = response.routes[0].bounds;
                            d.resolve({
                                instance: route,
                                northEast: bounds.getNorthEast(),
                                southWest: bounds.getSouthWest()
                            })
                        }
                    })
                });
                return d.promise()
            },
            _destroyRoute: function(routeObject) {
                routeObject.instance.setMap(null)
            },
            _fitBounds: function() {
                this._updateBounds();
                if (this._bounds && this._option("autoAdjust")) {
                    var zoomBeforeFitting = this._map.getZoom();
                    this._preventZoomChangeEvent = true;
                    this._map.fitBounds(this._bounds);
                    this._boundsChangeHandler();
                    var zoomAfterFitting = this._map.getZoom();
                    if (zoomBeforeFitting < zoomAfterFitting) {
                        this._map.setZoom(zoomBeforeFitting)
                    } else {
                        this._option("zoom", zoomAfterFitting)
                    }
                    delete this._preventZoomChangeEvent
                }
                return $.Deferred().resolve().promise()
            },
            _extendBounds: function(location) {
                if (this._bounds) {
                    this._bounds.extend(location)
                } else {
                    this._bounds = new google.maps.LatLngBounds;
                    this._bounds.extend(location)
                }
            },
            clean: function() {
                if (this._map) {
                    google.maps.event.removeListener(this._boundsChangeListener);
                    google.maps.event.removeListener(this._clickListener);
                    this._clearMarkers();
                    this._clearRoutes();
                    delete this._map;
                    this._$container.empty()
                }
                return $.Deferred().resolve().promise()
            }
        });
        GoogleProvider.remapConstant = function(newValue) {
            GOOGLE_URL = newValue
        };
        module.exports = GoogleProvider
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/map/ui.map.provider.dynamic.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Provider = __webpack_require__( /*! ./ui.map.provider */ 292),
            abstract = Provider.abstract;
        var DynamicProvider = Provider.inherit({
            cancelEvents: true,
            _geocodeLocation: function(location) {
                var d = $.Deferred();
                var cache = this._geocodedLocations,
                    cachedLocation = cache[location];
                if (cachedLocation) {
                    d.resolve(cachedLocation)
                } else {
                    this._geocodeLocationImpl(location).done(function(geocodedLocation) {
                        cache[location] = geocodedLocation;
                        d.resolve(geocodedLocation)
                    })
                }
                return d.promise()
            },
            _renderImpl: function(markerOptions, routeOptions) {
                var deferred = $.Deferred();
                this._load().done($.proxy(function() {
                    this._init().done($.proxy(function() {
                        var mapTypePromise = this.updateMapType(),
                            boundsPromise = this._isBoundsSetted() ? this.updateBounds() : this.updateCenter();
                        $.when(mapTypePromise, boundsPromise).done($.proxy(function() {
                            this._attachHandlers();
                            setTimeout(function() {
                                deferred.resolve()
                            })
                        }, this))
                    }, this))
                }, this));
                return deferred.promise()
            },
            _load: function() {
                if (!this._mapsLoader) {
                    this._mapsLoader = $.Deferred();
                    this._loadImpl().done($.proxy(function() {
                        this._mapsLoader.resolve()
                    }, this))
                }
                this._markers = [];
                this._routes = [];
                return this._mapsLoader.promise()
            },
            _loadImpl: abstract,
            _init: abstract,
            _attachHandlers: abstract,
            addMarkers: function(options) {
                var deferred = $.Deferred(),
                    that = this;
                var markerPromises = $.map(options, function(options) {
                    return that._addMarker(options)
                });
                $.when.apply($, markerPromises).done(function() {
                    var instances = $.map($.makeArray(arguments), function(markerObject) {
                        return markerObject.marker
                    });
                    deferred.resolve(false, instances)
                });
                deferred.done(function() {
                    that._fitBounds()
                });
                return deferred.promise()
            },
            _addMarker: function(options) {
                var that = this;
                return this._renderMarker(options).done(function(markerObject) {
                    that._markers.push($.extend({
                        options: options
                    }, markerObject));
                    that._fireMarkerAddedAction({
                        options: options,
                        originalMarker: markerObject.marker
                    })
                })
            },
            _renderMarker: abstract,
            removeMarkers: function(markersOptionsToRemove) {
                var that = this;
                $.each(markersOptionsToRemove, function(_, markerOptionToRemove) {
                    that._removeMarker(markerOptionToRemove)
                });
                return $.Deferred().resolve().promise()
            },
            _removeMarker: function(markersOptionToRemove) {
                var that = this;
                $.each(this._markers, function(markerIndex, markerObject) {
                    if (markerObject.options !== markersOptionToRemove) {
                        return true
                    }
                    that._destroyMarker(markerObject);
                    that._markers.splice(markerIndex, 1);
                    that._fireMarkerRemovedAction({
                        options: markerObject.options
                    });
                    return false
                })
            },
            _destroyMarker: abstract,
            _clearMarkers: function() {
                while (this._markers.length > 0) {
                    this._removeMarker(this._markers[0].options)
                }
            },
            addRoutes: function(options) {
                var deferred = $.Deferred(),
                    that = this;
                var routePromises = $.map(options, function(options) {
                    return that._addRoute(options)
                });
                $.when.apply($, routePromises).done(function() {
                    var instances = $.map($.makeArray(arguments), function(routeObject) {
                        return routeObject.instance
                    });
                    deferred.resolve(false, instances)
                });
                deferred.done(function() {
                    that._fitBounds()
                });
                return deferred.promise()
            },
            _addRoute: function(options) {
                var that = this;
                return this._renderRoute(options).done(function(routeObject) {
                    that._routes.push($.extend({
                        options: options
                    }, routeObject));
                    that._fireRouteAddedAction({
                        options: options,
                        originalRoute: routeObject.instance
                    })
                })
            },
            _renderRoute: abstract,
            removeRoutes: function(options) {
                var that = this;
                $.each(options, function(routeIndex, options) {
                    that._removeRoute(options)
                });
                return $.Deferred().resolve().promise()
            },
            _removeRoute: function(options) {
                var that = this;
                $.each(this._routes, function(routeIndex, routeObject) {
                    if (routeObject.options !== options) {
                        return true
                    }
                    that._destroyRoute(routeObject);
                    that._routes.splice(routeIndex, 1);
                    that._fireRouteRemovedAction({
                        options: options
                    });
                    return false
                })
            },
            _destroyRoute: abstract,
            _clearRoutes: function() {
                while (this._routes.length > 0) {
                    this._removeRoute(this._routes[0].options)
                }
            },
            adjustViewport: function() {
                return this._fitBounds()
            },
            _fitBounds: abstract,
            _updateBounds: function() {
                var that = this;
                this._clearBounds();
                if (!this._option("autoAdjust")) {
                    return
                }
                $.each(this._markers, function(_, markerObject) {
                    that._extendBounds(markerObject.location)
                });
                $.each(this._routes, function(_, routeObject) {
                    that._extendBounds(routeObject.northEast);
                    that._extendBounds(routeObject.southWest)
                })
            },
            _clearBounds: function() {
                this._bounds = null
            },
            _extendBounds: abstract
        });
        module.exports = DynamicProvider
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/map/ui.map.provider.dynamic.bing.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            DynamicProvider = __webpack_require__( /*! ./ui.map.provider.dynamic */ 294),
            Color = __webpack_require__( /*! ../../color */ 26),
            support = __webpack_require__( /*! ../../core/utils/support */ 48);
        var BING_MAP_READY = "_bingScriptReady",
            BING_URL = "https://ecn.dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=7.0&s=1&onScriptLoad=" + BING_MAP_READY,
            BING_LOCAL_FILES1 = "ms-appx:///Bing.Maps.JavaScript/js/veapicore.js",
            BING_LOCAL_FILES2 = "ms-appx:///Bing.Maps.JavaScript/js/veapiModules.js",
            BING_CREDENTIALS = "AhuxC0dQ1DBTNo8L-H9ToVMQStmizZzBJdraTSgCzDSWPsA1Qd8uIvFSflzxdaLH",
            MIN_LOCATION_RECT_LENGTH = 1e-16;
        var msMapsLoaded = function() {
            return window.Microsoft && window.Microsoft.Maps
        };
        var msMapsLoader;
        var BingProvider = DynamicProvider.inherit({
            _mapType: function(type) {
                var mapTypes = {
                    roadmap: Microsoft.Maps.MapTypeId.road,
                    hybrid: Microsoft.Maps.MapTypeId.aerial,
                    satellite: Microsoft.Maps.MapTypeId.aerial
                };
                return mapTypes[type] || mapTypes.road
            },
            _movementMode: function(type) {
                var movementTypes = {
                    driving: Microsoft.Maps.Directions.RouteMode.driving,
                    walking: Microsoft.Maps.Directions.RouteMode.walking
                };
                return movementTypes[type] || movementTypes.driving
            },
            _resolveLocation: function(location) {
                var d = $.Deferred();
                var latLng = this._getLatLng(location);
                if (latLng) {
                    d.resolve(new Microsoft.Maps.Location(latLng.lat, latLng.lng))
                } else {
                    this._geocodeLocation(location).done(function(geocodedLocation) {
                        d.resolve(geocodedLocation)
                    })
                }
                return d.promise()
            },
            _geocodedLocations: {},
            _geocodeLocationImpl: function(location) {
                var d = $.Deferred();
                var searchManager = new Microsoft.Maps.Search.SearchManager(this._map);
                var searchRequest = {
                    where: location,
                    count: 1,
                    callback: function(searchResponse) {
                        var result = searchResponse.results[0];
                        if (result) {
                            var boundsBox = searchResponse.results[0].location;
                            d.resolve(new Microsoft.Maps.Location(boundsBox.latitude, boundsBox.longitude))
                        } else {
                            d.resolve(new Microsoft.Maps.Location(0, 0))
                        }
                    }
                };
                searchManager.geocode(searchRequest);
                return d.promise()
            },
            _normalizeLocation: function(location) {
                return {
                    lat: location.latitude,
                    lng: location.longitude
                }
            },
            _normalizeLocationRect: function(locationRect) {
                var northWest = this._normalizeLocation(locationRect.getNorthwest()),
                    southEast = this._normalizeLocation(locationRect.getSoutheast());
                return {
                    northEast: {
                        lat: northWest.lat,
                        lng: southEast.lng
                    },
                    southWest: {
                        lat: southEast.lat,
                        lng: northWest.lng
                    }
                }
            },
            _loadImpl: function() {
                this._msMapsLoader = $.Deferred();
                if (msMapsLoaded()) {
                    this._mapReady()
                } else {
                    if (!msMapsLoader || "resolved" === msMapsLoader.state() && !msMapsLoaded()) {
                        msMapsLoader = $.Deferred();
                        window[BING_MAP_READY] = $.proxy(msMapsLoader.resolve, msMapsLoader);
                        if (support.winJS) {
                            $.when($.getScript(BING_LOCAL_FILES1), $.getScript(BING_LOCAL_FILES2)).done(function() {
                                Microsoft.Maps.loadModule("Microsoft.Maps.Map", {
                                    callback: window[BING_MAP_READY]
                                })
                            })
                        } else {
                            $.getScript(BING_URL)
                        }
                    }
                    msMapsLoader.done($.proxy(this._mapReady, this))
                }
                return this._msMapsLoader.promise()
            },
            _mapReady: function() {
                try {
                    delete window[BING_MAP_READY]
                } catch (e) {
                    window[BING_MAP_READY] = void 0
                }
                var searchModulePromise = $.Deferred();
                var directionsModulePromise = $.Deferred();
                Microsoft.Maps.loadModule("Microsoft.Maps.Search", {
                    callback: $.proxy(searchModulePromise.resolve, searchModulePromise)
                });
                Microsoft.Maps.loadModule("Microsoft.Maps.Directions", {
                    callback: $.proxy(directionsModulePromise.resolve, directionsModulePromise)
                });
                $.when(searchModulePromise, directionsModulePromise).done($.proxy(function() {
                    this._msMapsLoader.resolve()
                }, this))
            },
            _init: function() {
                var deferred = $.Deferred(),
                    initPromise = $.Deferred(),
                    controls = this._option("controls");
                this._map = new Microsoft.Maps.Map(this._$container[0], {
                    credentials: this._keyOption("bing") || BING_CREDENTIALS,
                    zoom: this._option("zoom"),
                    showDashboard: controls,
                    showMapTypeSelector: controls,
                    showScalebar: controls
                });
                var handler = Microsoft.Maps.Events.addHandler(this._map, "tiledownloadcomplete", $.proxy(initPromise.resolve, initPromise));
                $.when(initPromise).done($.proxy(function() {
                    Microsoft.Maps.Events.removeHandler(handler);
                    deferred.resolve()
                }, this));
                return deferred.promise()
            },
            _attachHandlers: function() {
                this._providerViewChangeHandler = Microsoft.Maps.Events.addHandler(this._map, "viewchange", $.proxy(this._viewChangeHandler, this));
                this._providerClickHandler = Microsoft.Maps.Events.addHandler(this._map, "click", $.proxy(this._clickActionHandler, this))
            },
            _viewChangeHandler: function() {
                var bounds = this._map.getBounds();
                this._option("bounds", this._normalizeLocationRect(bounds));
                var center = this._map.getCenter();
                this._option("center", this._normalizeLocation(center));
                if (!this._preventZoomChangeEvent) {
                    this._option("zoom", this._map.getZoom())
                }
            },
            _clickActionHandler: function(e) {
                if ("map" === e.targetType) {
                    var point = new Microsoft.Maps.Point(e.getX(), e.getY()),
                        location = e.target.tryPixelToLocation(point);
                    this._fireClickAction({
                        location: this._normalizeLocation(location)
                    })
                }
            },
            updateDimensions: function() {
                var $container = this._$container;
                this._map.setOptions({
                    width: $container.width(),
                    height: $container.height()
                });
                return $.Deferred().resolve().promise()
            },
            updateMapType: function() {
                var type = this._option("type"),
                    labelOverlay = Microsoft.Maps.LabelOverlay;
                this._map.setView({
                    animate: false,
                    mapTypeId: this._mapType(type),
                    labelOverlay: "satellite" === type ? labelOverlay.hidden : labelOverlay.visible
                });
                return $.Deferred().resolve().promise()
            },
            updateBounds: function() {
                var deferred = $.Deferred(),
                    that = this;
                var northEastPromise = this._resolveLocation(this._option("bounds.northEast")),
                    southWestPromise = this._resolveLocation(this._option("bounds.southWest"));
                $.when(northEastPromise, southWestPromise).done(function(northEast, southWest) {
                    var bounds = new Microsoft.Maps.LocationRect.fromLocations(northEast, southWest);
                    that._map.setView({
                        animate: false,
                        bounds: bounds
                    });
                    deferred.resolve()
                });
                return deferred.promise()
            },
            updateCenter: function() {
                var deferred = $.Deferred(),
                    that = this;
                this._resolveLocation(this._option("center")).done(function(location) {
                    that._map.setView({
                        animate: false,
                        center: location
                    });
                    deferred.resolve()
                });
                return deferred.promise()
            },
            updateZoom: function() {
                this._map.setView({
                    animate: false,
                    zoom: this._option("zoom")
                });
                return $.Deferred().resolve().promise()
            },
            updateControls: function() {
                this.clean();
                return this.render.apply(this, arguments)
            },
            _renderMarker: function(options) {
                var d = $.Deferred(),
                    that = this;
                this._resolveLocation(options.location).done(function(location) {
                    var pushpinOptions = {
                        icon: options.iconSrc || that._option("markerIconSrc")
                    };
                    if (options.html) {
                        $.extend(pushpinOptions, {
                            htmlContent: options.html,
                            width: null,
                            height: null
                        });
                        var htmlOffset = options.htmlOffset;
                        if (htmlOffset) {
                            pushpinOptions.anchor = new Microsoft.Maps.Point((-htmlOffset.left), (-htmlOffset.top))
                        }
                    }
                    var pushpin = new Microsoft.Maps.Pushpin(location, pushpinOptions);
                    that._map.entities.push(pushpin);
                    var infobox = that._renderTooltip(location, options.tooltip);
                    var handler;
                    if (options.onClick || options.tooltip) {
                        var markerClickAction = that._createAction(options.onClick || $.noop),
                            markerNormalizedLocation = that._normalizeLocation(location);
                        handler = Microsoft.Maps.Events.addHandler(pushpin, "click", function() {
                            markerClickAction({
                                location: markerNormalizedLocation
                            });
                            if (infobox) {
                                infobox.setOptions({
                                    visible: true
                                })
                            }
                        })
                    }
                    d.resolve({
                        location: location,
                        marker: pushpin,
                        infobox: infobox,
                        handler: handler
                    })
                });
                return d.promise()
            },
            _renderTooltip: function(location, options) {
                if (!options) {
                    return
                }
                options = this._parseTooltipOptions(options);
                var infobox = new Microsoft.Maps.Infobox(location, {
                    description: options.text,
                    offset: new Microsoft.Maps.Point(0, 33),
                    visible: options.visible
                });
                this._map.entities.push(infobox, null);
                return infobox
            },
            _destroyMarker: function(marker) {
                this._map.entities.remove(marker.marker);
                if (marker.infobox) {
                    this._map.entities.remove(marker.infobox)
                }
                if (marker.handler) {
                    Microsoft.Maps.Events.removeHandler(marker.handler)
                }
            },
            _renderRoute: function(options) {
                var d = $.Deferred(),
                    that = this;
                var points = $.map(options.locations, function(point) {
                    return that._resolveLocation(point)
                });
                $.when.apply($, points).done(function() {
                    var locations = $.makeArray(arguments),
                        direction = new Microsoft.Maps.Directions.DirectionsManager(that._map),
                        color = new Color(options.color || that._defaultRouteColor()).toHex(),
                        routeColor = new Microsoft.Maps.Color.fromHex(color);
                    routeColor.a = 255 * (options.opacity || that._defaultRouteOpacity());
                    direction.setRenderOptions({
                        autoUpdateMapView: false,
                        displayRouteSelector: false,
                        waypointPushpinOptions: {
                            visible: false
                        },
                        drivingPolylineOptions: {
                            strokeColor: routeColor,
                            strokeThickness: options.weight || that._defaultRouteWeight()
                        },
                        walkingPolylineOptions: {
                            strokeColor: routeColor,
                            strokeThickness: options.weight || that._defaultRouteWeight()
                        }
                    });
                    direction.setRequestOptions({
                        routeMode: that._movementMode(options.mode),
                        routeDraggable: false
                    });
                    $.each(locations, function(_, location) {
                        var waypoint = new Microsoft.Maps.Directions.Waypoint({
                            location: location
                        });
                        direction.addWaypoint(waypoint)
                    });
                    var handler = Microsoft.Maps.Events.addHandler(direction, "directionsUpdated", function(args) {
                        Microsoft.Maps.Events.removeHandler(handler);
                        var routeSummary = args.routeSummary[0];
                        d.resolve({
                            instance: direction,
                            northEast: routeSummary.northEast,
                            southWest: routeSummary.southWest
                        })
                    });
                    direction.calculateDirections()
                });
                return d.promise()
            },
            _destroyRoute: function(routeObject) {
                routeObject.instance.dispose()
            },
            _fitBounds: function() {
                this._updateBounds();
                if (this._bounds && this._option("autoAdjust")) {
                    var zoomBeforeFitting = this._map.getZoom();
                    this._preventZoomChangeEvent = true;
                    var bounds = this._bounds.clone();
                    bounds.height = 1.1 * bounds.height;
                    bounds.width = 1.1 * bounds.width;
                    this._map.setView({
                        animate: false,
                        bounds: bounds,
                        zoom: zoomBeforeFitting
                    });
                    var zoomAfterFitting = this._map.getZoom();
                    if (zoomBeforeFitting < zoomAfterFitting) {
                        this._map.setView({
                            animate: false,
                            zoom: zoomBeforeFitting
                        })
                    } else {
                        this._option("zoom", zoomAfterFitting)
                    }
                    delete this._preventZoomChangeEvent
                }
                return $.Deferred().resolve().promise()
            },
            _extendBounds: function(location) {
                if (this._bounds) {
                    this._bounds = new Microsoft.Maps.LocationRect.fromLocations(this._bounds.getNorthwest(), this._bounds.getSoutheast(), location)
                } else {
                    this._bounds = new Microsoft.Maps.LocationRect(location, MIN_LOCATION_RECT_LENGTH, MIN_LOCATION_RECT_LENGTH)
                }
            },
            clean: function() {
                if (this._map) {
                    Microsoft.Maps.Events.removeHandler(this._providerViewChangeHandler);
                    Microsoft.Maps.Events.removeHandler(this._providerClickHandler);
                    this._clearMarkers();
                    this._clearRoutes();
                    this._map.dispose()
                }
                return $.Deferred().resolve().promise()
            }
        });
        BingProvider.remapConstant = function(newValue) {
            BING_URL = newValue
        };
        module.exports = BingProvider
    },
    /*!*******************************!*\
      !*** ./Scripts/ui/nav_bar.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Tabs = __webpack_require__( /*! ./tabs */ 284);
        var NAVBAR_CLASS = "dx-navbar",
            ITEM_CLASS = "dx-item-content",
            NAVBAR_ITEM_CLASS = "dx-nav-item",
            NAVBAR_ITEM_CONTENT_CLASS = "dx-nav-item-content";
        var NavBar = Tabs.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    scrollingEnabled: false
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass(NAVBAR_CLASS)
            },
            _postprocessRenderItem: function(args) {
                this.callBase(args);
                var $itemElement = args.itemElement,
                    itemData = args.itemData;
                $itemElement.addClass(NAVBAR_ITEM_CLASS);
                $itemElement.find("." + ITEM_CLASS).addClass(NAVBAR_ITEM_CONTENT_CLASS);
                if (!itemData.icon && !itemData.iconSrc) {
                    $itemElement.addClass("dx-navbar-text-item")
                }
            }
        });
        registerComponent("dxNavBar", NavBar);
        module.exports = NavBar
    },
    /*!***********************************!*\
      !*** ./Scripts/ui/radio_group.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./radio_group/radio_group */ 298)
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/radio_group/radio_group.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            inkRipple = __webpack_require__( /*! ../widget/utils.ink_ripple */ 197),
            DataExpressionMixin = __webpack_require__( /*! ../editor/ui.data_expression */ 244),
            themes = __webpack_require__( /*! ../themes */ 143),
            CollectionWidget = __webpack_require__( /*! ../collection/ui.collection_widget.edit */ 151);
        var RADIO_GROUP_CLASS = "dx-radiogroup",
            RADIO_GROUP_VERTICAL_CLASS = "dx-radiogroup-vertical",
            RADIO_GROUP_HORIZONTAL_CLASS = "dx-radiogroup-horizontal",
            RADIO_BUTTON_CLASS = "dx-radiobutton",
            RADIO_BUTTON_ICON_CLASS = "dx-radiobutton-icon",
            RADIO_BUTTON_ICON_DOT_CLASS = "dx-radiobutton-icon-dot",
            RADIO_VALUE_CONTAINER_CLASS = "dx-radio-value-container",
            RADIO_BUTTON_CHECKED_CLASS = "dx-radiobutton-checked",
            ITEM_DATA_KEY = "dxItemData",
            RADIO_FEEDBACK_HIDE_TIMEOUT = 100;
        var RadioCollection = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), DataExpressionMixin._dataExpressionDefaultOptions(), {
                    _itemAttributes: {
                        role: "radio"
                    }
                })
            },
            _supportedKeys: function(e) {
                var parent = this.callBase();
                return $.extend({}, parent, {
                    enter: function(e) {
                        e.preventDefault();
                        return parent.enter.apply(this, arguments)
                    },
                    space: function(e) {
                        e.preventDefault();
                        return parent.space.apply(this, arguments)
                    }
                })
            },
            _focusTarget: function() {
                return this.element().parent()
            },
            _keyboardEventBindingTarget: function() {
                return this._focusTarget()
            }
        });
        RadioCollection.publicName("dxRadioCollection");
        var RadioGroup = Editor.inherit({
            _activeStateUnit: "." + RADIO_BUTTON_CLASS,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), $.extend(DataExpressionMixin._dataExpressionDefaultOptions(), {
                    hoverStateEnabled: true,
                    activeStateEnabled: true,
                    layout: "vertical",
                    useInkRipple: false
                }))
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        tablet: true
                    },
                    options: {
                        layout: "horizontal"
                    }
                }, {
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    value: true
                })
            },
            _dataSourceOptions: function() {
                return {
                    paginate: false
                }
            },
            _init: function() {
                this.callBase();
                this._initDataExpressions();
                this._feedbackHideTimeout = RADIO_FEEDBACK_HIDE_TIMEOUT
            },
            _render: function() {
                this.element().addClass(RADIO_GROUP_CLASS);
                this._renderRadios();
                this.setAria("role", "radiogroup");
                this.callBase();
                this._renderLayout();
                this._updateItemsSize();
                this.option("useInkRipple") && this._renderInkRipple()
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render({
                    waveSizeCoefficient: 3.3,
                    useHoldAnimation: false,
                    isCentered: true
                })
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                if (!this._inkRipple) {
                    return
                }
                if (value) {
                    this._inkRipple.showWave({
                        element: $element.find("." + RADIO_BUTTON_ICON_CLASS),
                        jQueryEvent: e
                    })
                } else {
                    this._inkRipple.hideWave({
                        element: $element.find("." + RADIO_BUTTON_ICON_CLASS),
                        jQueryEvent: e
                    })
                }
            },
            _renderFocusState: $.noop,
            _renderRadios: function() {
                var $radios = $("<div>").appendTo(this.element());
                this._radios = this._createComponent($radios, RadioCollection, {
                    dataSource: this._dataSource,
                    onItemRendered: $.proxy(this._itemRenderedHandler, this),
                    onItemClick: $.proxy(this._itemClickHandler, this),
                    itemTemplate: this._getTemplateByOption("itemTemplate"),
                    scrollingEnabled: false,
                    focusStateEnabled: this.option("focusStateEnabled"),
                    accessKey: this.option("accessKey"),
                    tabIndex: this.option("tabIndex"),
                    noDataText: ""
                });
                this._setCollectionWidgetOption("onContentReady", $.proxy(this._contentReadyHandler, this));
                this._contentReadyHandler()
            },
            _contentReadyHandler: function() {
                this.itemElements().addClass(RADIO_BUTTON_CLASS);
                this._refreshSelected()
            },
            _itemRenderedHandler: function(e) {
                if (e.itemData.html) {
                    return
                }
                var $radio, $radioContainer;
                $radio = $("<div>").addClass(RADIO_BUTTON_ICON_CLASS);
                $("<div>").addClass(RADIO_BUTTON_ICON_DOT_CLASS).appendTo($radio);
                $radioContainer = $("<div>").append($radio).addClass(RADIO_VALUE_CONTAINER_CLASS);
                e.itemElement.prepend($radioContainer)
            },
            _itemClickHandler: function(e) {
                this._saveValueChangeEvent(e.jQueryEvent);
                this.option("value", this._getItemValue(e.itemData))
            },
            _getItemValue: function(item) {
                return !!this._valueGetter ? this._valueGetter(item) : item.text
            },
            itemElements: function() {
                return this._radios.itemElements()
            },
            _renderDimensions: function() {
                this.callBase();
                this._updateItemsSize()
            },
            _renderLayout: function() {
                var layout = this.option("layout");
                this.element().toggleClass(RADIO_GROUP_VERTICAL_CLASS, "vertical" === layout);
                this.element().toggleClass(RADIO_GROUP_HORIZONTAL_CLASS, "horizontal" === layout)
            },
            _refreshSelected: function() {
                var selectedValue = this.option("value");
                this.itemElements().each($.proxy(function(_, item) {
                    var $item = $(item);
                    var itemValue = this._valueGetter($item.data(ITEM_DATA_KEY));
                    $item.toggleClass(RADIO_BUTTON_CHECKED_CLASS, this._isValueEquals(itemValue, selectedValue));
                    this.setAria("checked", this._isValueEquals(itemValue, selectedValue), $item)
                }, this))
            },
            _updateItemsSize: function() {
                if ("horizontal" === this.option("layout")) {
                    this.itemElements().css("height", "auto")
                } else {
                    var itemsCount = this.option("items").length;
                    this.itemElements().css("height", 100 / itemsCount + "%")
                }
            },
            _getAriaTarget: function() {
                return this.element()
            },
            _setCollectionWidgetOption: function() {
                this._setWidgetOption("_radios", arguments)
            },
            focus: function() {
                this._radios && this._radios.focus()
            },
            _optionChanged: function(args) {
                this._dataExpressionOptionChanged(args);
                switch (args.name) {
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    case "focusStateEnabled":
                    case "accessKey":
                    case "tabIndex":
                        this._setCollectionWidgetOption(args.name, args.value);
                        break;
                    case "disabled":
                        this.callBase(args);
                        this._setCollectionWidgetOption(args.name, args.value);
                        break;
                    case "dataSource":
                        this._setCollectionWidgetOption("dataSource");
                        break;
                    case "valueExpr":
                        this._refreshSelected();
                        break;
                    case "value":
                        this._refreshSelected();
                        this.callBase(args);
                        break;
                    case "items":
                    case "itemTemplate":
                    case "displayExpr":
                        break;
                    case "layout":
                        this._renderLayout();
                        this._updateItemsSize();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        }).include(DataExpressionMixin);
        registerComponent("dxRadioGroup", RadioGroup);
        module.exports = RadioGroup
    },
    /*!************************************!*\
      !*** ./Scripts/ui/range_slider.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Slider = __webpack_require__( /*! ./slider */ 300),
            SliderHandle = __webpack_require__( /*! ./slider/ui.slider_handle */ 302),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80);
        var RANGE_SLIDER_CLASS = "dx-rangeslider",
            RANGE_SLIDER_START_HANDLE_CLASS = RANGE_SLIDER_CLASS + "-start-handle",
            RANGE_SLIDER_END_HANDLE_CLASS = RANGE_SLIDER_CLASS + "-end-handle";
        var RangeSlider = Slider.inherit({
            _supportedKeys: function() {
                var isRTL = this.option("rtlEnabled");
                var that = this,
                    _changeHandle = function(e, capturedHandle) {
                        if (that.option("start") === that.option("end")) {
                            that._capturedHandle = capturedHandle;
                            e.target = that._capturedHandle;
                            that._capturedHandle.focus()
                        }
                    },
                    _setHandleValue = function(e, step, sign) {
                        var isStart = $(e.target).hasClass(RANGE_SLIDER_START_HANDLE_CLASS),
                            valueOption = isStart ? "start" : "end",
                            val = that.option(valueOption);
                        step = that._valueStep(step);
                        val += sign * (isRTL ? -step : step);
                        that.option(valueOption, val)
                    },
                    moveHandleRight = function(e, step) {
                        _changeHandle(e, isRTL ? that._$handleStart : that._$handleEnd);
                        _setHandleValue(e, step, 1)
                    },
                    moveHandleLeft = function(e, step) {
                        _changeHandle(e, isRTL ? that._$handleEnd : that._$handleStart);
                        _setHandleValue(e, step, -1)
                    };
                return $.extend(this.callBase(), {
                    leftArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleLeft(e, this.option("step"))
                    },
                    rightArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleRight(e, this.option("step"))
                    },
                    pageUp: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleRight(e, this.option("step") * this.option("keyStep"))
                    },
                    pageDown: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleLeft(e, this.option("step") * this.option("keyStep"))
                    },
                    home: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        var isStart = $(e.target).hasClass(RANGE_SLIDER_START_HANDLE_CLASS),
                            valueOption = isStart ? "start" : "end",
                            startOption = isStart ? "min" : "start",
                            val = this.option(startOption);
                        this.option(valueOption, val)
                    },
                    end: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        var isStart = $(e.target).hasClass(RANGE_SLIDER_START_HANDLE_CLASS),
                            valueOption = isStart ? "start" : "end",
                            endOption = isStart ? "end" : "max",
                            val = this.option(endOption);
                        this.option(valueOption, val)
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    start: 40,
                    end: 60
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass(RANGE_SLIDER_CLASS);
                this._callHandlerMethod("repaint")
            },
            _renderHandle: function() {
                this._$handleStart = this._renderHandleImpl(this.option("start"), this._$handleStart).addClass(RANGE_SLIDER_START_HANDLE_CLASS);
                this._$handleEnd = this._renderHandleImpl(this.option("end"), this._$handleEnd).addClass(RANGE_SLIDER_END_HANDLE_CLASS);
                this._updateHandleAriaLabels()
            },
            _startHandler: function(args) {
                var e = args.jQueryEvent,
                    $range = this._$range,
                    rangeWidth = $range.width(),
                    eventOffsetX = eventUtils.eventData(e).x - this._$bar.offset().left,
                    startHandleX = $range.position().left,
                    endHandleX = $range.position().left + rangeWidth,
                    rtlEnabled = this.option("rtlEnabled"),
                    startHandleIsClosest = (rtlEnabled ? -1 : 1) * ((startHandleX + endHandleX) / 2 - eventOffsetX) > 0;
                this._capturedHandle = startHandleIsClosest ? this._$handleStart : this._$handleEnd;
                this.callBase(args)
            },
            _updateHandleAriaLabels: function() {
                this.setAria("label", messageLocalization.getFormatter("dxRangeSlider-ariaFrom")(this.option("dxRangeSlider-ariaFrom")), this._$handleStart);
                this.setAria("label", messageLocalization.getFormatter("dxRangeSlider-ariaTill")(this.option("dxRangeSlider-ariaTill")), this._$handleEnd)
            },
            _activeHandle: function() {
                return this._capturedHandle
            },
            _updateHandlePosition: function(e) {
                var rtlEnabled = this.option("rtlEnabled"),
                    offsetDirection = rtlEnabled ? -1 : 1,
                    max = this.option("max"),
                    min = this.option("min");
                var newRatio = this._startOffset + offsetDirection * e.jQueryEvent.offset / this._swipePixelRatio();
                newRatio = newRatio.toPrecision(12);
                var newValue = newRatio * (max - min) + min;
                this._updateSelectedRangePosition(newRatio, newRatio);
                SliderHandle.getInstance(this._activeHandle()).fitTooltipPosition;
                this._changeValueOnSwipe(newRatio);
                var $nextHandle, startValue = this.option("start"),
                    endValue = this.option("end");
                if (startValue === endValue) {
                    if (newValue < startValue) {
                        $nextHandle = this._$handleStart
                    } else {
                        $nextHandle = this._$handleEnd
                    }
                    $nextHandle.focus();
                    if ($nextHandle && $nextHandle !== this._capturedHandle) {
                        this._updateSelectedRangePosition((startValue - min) / (max - min), (endValue - min) / (max - min));
                        this._toggleActiveState(this._activeHandle(), false);
                        this._toggleActiveState($nextHandle, true);
                        this._capturedHandle = $nextHandle
                    }
                    this._updateSelectedRangePosition(newRatio, newRatio);
                    this._changeValueOnSwipe(newRatio)
                }
            },
            _updateSelectedRangePosition: function(leftRatio, rightRatio) {
                var rtlEnabled = this.option("rtlEnabled"),
                    moveRight = this._capturedHandle === this._$handleStart && rtlEnabled || this._capturedHandle === this._$handleEnd && !rtlEnabled;
                var prop = moveRight ? "right" : "left";
                if (rtlEnabled ^ moveRight) {
                    this._$range.css(prop, 100 - 100 * rightRatio + "%")
                } else {
                    this._$range.css(prop, 100 * leftRatio + "%")
                }
            },
            _changeValueOnSwipe: function(ratio) {
                this._suppressValueChangeAction();
                this.callBase(ratio);
                this._resumeValueChangeAction();
                var option = this._capturedHandle === this._$handleStart ? "start" : "end",
                    start = this.option("start"),
                    end = this.option("end"),
                    newValue = this.option("value"),
                    max = this.option("max"),
                    min = this.option("min");
                if (start > max) {
                    start = max;
                    this.option("start", max)
                }
                if (start < min) {
                    start = min;
                    this.option("start", min)
                }
                if (end > max) {
                    end = max;
                    this.option("end", max)
                }
                if (newValue > end && "start" === option) {
                    newValue = end
                }
                if (newValue < start && "end" === option) {
                    newValue = start
                }
                this.option(option, newValue)
            },
            _renderValue: function() {
                var valStart = this.option("start"),
                    valEnd = this.option("end"),
                    min = this.option("min"),
                    max = this.option("max"),
                    rtlEnabled = this.option("rtlEnabled");
                valStart = Math.max(min, Math.min(valStart, max));
                valEnd = Math.max(valStart, Math.min(valEnd, max));
                this.option("start", valStart);
                this.option("end", valEnd);
                var ratio1 = max === min ? 0 : (valStart - min) / (max - min),
                    ratio2 = max === min ? 0 : (valEnd - min) / (max - min);
                var startOffset = parseFloat((100 * ratio1).toPrecision(12)) + "%",
                    endOffset = parseFloat((100 * (1 - ratio2)).toPrecision(12)) + "%";
                !this._needPreventAnimation && this._setRangeStyles({
                    right: rtlEnabled ? startOffset : endOffset,
                    left: rtlEnabled ? endOffset : startOffset
                });
                SliderHandle.getInstance(this._$handleStart).option("value", valStart);
                SliderHandle.getInstance(this._$handleEnd).option("value", valEnd)
            },
            _callHandlerMethod: function(name, args) {
                SliderHandle.getInstance(this._$handleStart)[name](args);
                SliderHandle.getInstance(this._$handleEnd)[name](args)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "start":
                    case "end":
                        this._renderValue();
                        this._createActionByOption("onValueChanged", {
                            excludeValidators: ["disabled", "readOnly"]
                        })({
                            start: this.option("start"),
                            end: this.option("end"),
                            jQueryEvent: this._valueChangeEventInstance
                        });
                        this._saveValueChangeEvent(void 0);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxRangeSlider", RangeSlider);
        module.exports = RangeSlider
    },
    /*!******************************!*\
      !*** ./Scripts/ui/slider.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./slider/ui.slider */ 301)
    },
    /*!****************************************!*\
      !*** ./Scripts/ui/slider/ui.slider.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            numberLocalization = __webpack_require__( /*! ../../localization/number */ 22),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            TrackBar = __webpack_require__( /*! ../track_bar */ 275),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            feedbackEvents = __webpack_require__( /*! ../../events/core/emitter.feedback */ 103),
            SliderHandle = __webpack_require__( /*! ./ui.slider_handle */ 302),
            inkRipple = __webpack_require__( /*! ../widget/utils.ink_ripple */ 197),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            Swipeable = __webpack_require__( /*! ../../events/gesture/swipeable */ 248),
            themes = __webpack_require__( /*! ../themes */ 143);
        var SLIDER_CLASS = "dx-slider",
            SLIDER_WRAPPER_CLASS = "dx-slider-wrapper",
            SLIDER_HANDLE_SELECTOR = ".dx-slider-handle",
            SLIDER_BAR_CLASS = "dx-slider-bar",
            SLIDER_RANGE_CLASS = "dx-slider-range",
            SLIDER_RANGE_VISIBLE_CLASS = "dx-slider-range-visible",
            SLIDER_LABEL_CLASS = "dx-slider-label",
            SLIDER_LABEL_POSITION_CLASS_PREFIX = "dx-slider-label-position-",
            SLIDER_TOOLTIP_POSITION_CLASS_PREFIX = "dx-slider-tooltip-position-";
        var Slider = TrackBar.inherit({
            _activeStateUnit: SLIDER_HANDLE_SELECTOR,
            _supportedKeys: function() {
                var isRTL = this.option("rtlEnabled");
                var that = this;
                var roundedValue = function(offset, isLeftDirection) {
                    offset = that._valueStep(offset);
                    var step = that.option("step");
                    var value = that.option("value");
                    var division = (value - that.option("min")) % step;
                    var result = isLeftDirection ? value - offset + (division ? step - division : 0) : value + offset - division;
                    var min = that.option("min"),
                        max = that.option("max");
                    if (result < min) {
                        result = min
                    } else {
                        if (result > max) {
                            result = max
                        }
                    }
                    return result
                };
                var moveHandleRight = function(offset) {
                    that.option("value", roundedValue(offset, isRTL))
                };
                var moveHandleLeft = function(offset) {
                    that.option("value", roundedValue(offset, !isRTL))
                };
                return $.extend(this.callBase(), {
                    leftArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleLeft(this.option("step"))
                    },
                    rightArrow: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleRight(this.option("step"))
                    },
                    pageUp: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleRight(this.option("step") * this.option("keyStep"))
                    },
                    pageDown: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        moveHandleLeft(this.option("step") * this.option("keyStep"))
                    },
                    home: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        var min = this.option("min");
                        this.option("value", min)
                    },
                    end: function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        var max = this.option("max");
                        this.option("value", max)
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    activeStateEnabled: true,
                    step: 1,
                    value: 50,
                    showRange: true,
                    tooltip: {
                        enabled: false,
                        format: function(value) {
                            return value
                        },
                        position: "top",
                        showMode: "onHover"
                    },
                    label: {
                        visible: false,
                        position: "bottom",
                        format: function(value) {
                            return value
                        }
                    },
                    keyStep: 1,
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _render: function() {
                this.element().addClass(SLIDER_CLASS);
                this.callBase();
                this._renderLabels();
                this._renderStartHandler();
                this._renderAriaMinAndMax();
                this._repaintHandle();
                this.option("useInkRipple") && this._renderInkRipple()
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render({
                    waveSizeCoefficient: .7,
                    isCentered: true,
                    wavesNumber: 2,
                    useHoldAnimation: false
                })
            },
            _renderInkWave: function(element, jQueryEvent, doRender, waveIndex) {
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: element,
                    jQueryEvent: jQueryEvent,
                    wave: waveIndex
                };
                if (doRender) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _visibilityChanged: function() {
                this.repaint()
            },
            _renderWrapper: function() {
                this.callBase();
                this._$wrapper.addClass(SLIDER_WRAPPER_CLASS);
                this._createComponent(this._$wrapper, Swipeable, {
                    elastic: false,
                    immediate: true,
                    onStart: $.proxy(this._swipeStartHandler, this),
                    onUpdated: $.proxy(this._swipeUpdateHandler, this),
                    onEnd: $.proxy(this._swipeEndHandler, this),
                    itemSizeFunc: $.proxy(this._itemWidthFunc, this)
                })
            },
            _renderContainer: function() {
                this.callBase();
                this._$bar.addClass(SLIDER_BAR_CLASS)
            },
            _renderRange: function() {
                this.callBase();
                this._$range.addClass(SLIDER_RANGE_CLASS);
                this._renderHandle();
                this._renderRangeVisibility()
            },
            _renderRangeVisibility: function() {
                this._$range.toggleClass(SLIDER_RANGE_VISIBLE_CLASS, Boolean(this.option("showRange")))
            },
            _renderHandle: function() {
                this._$handle = this._renderHandleImpl(this.option("value"), this._$handle)
            },
            _renderHandleImpl: function(value, $element) {
                var $handle = $element || $("<div>").appendTo(this._$range),
                    format = this.option("tooltip.format"),
                    tooltipEnabled = this.option("tooltip.enabled"),
                    tooltipPosition = this.option("tooltip.position");
                this.element().toggleClass(SLIDER_TOOLTIP_POSITION_CLASS_PREFIX + "bottom", tooltipEnabled && "bottom" === tooltipPosition).toggleClass(SLIDER_TOOLTIP_POSITION_CLASS_PREFIX + "top", tooltipEnabled && "top" === tooltipPosition);
                this._createComponent($handle, SliderHandle, {
                    value: value,
                    tooltipEnabled: tooltipEnabled,
                    tooltipPosition: tooltipPosition,
                    tooltipFormat: format,
                    tooltipShowMode: this.option("tooltip.showMode"),
                    tooltipFitIn: this.element()
                });
                return $handle
            },
            _renderAriaMinAndMax: function() {
                this.setAria({
                    valuemin: this.option("min"),
                    valuemax: this.option("max")
                }, this._$handle)
            },
            _hoverStartHandler: function(e) {
                SliderHandle.getInstance($(e.currentTarget)).updateTooltip()
            },
            _toggleActiveState: function($element, value) {
                this.callBase($element, value);
                if (value) {
                    SliderHandle.getInstance($element).updateTooltip()
                }
                this._renderInkWave($element, null, !!value, 1)
            },
            _toggleFocusClass: function(isFocused, $element) {
                this.callBase(isFocused, $element);
                if (this._disposed) {
                    return
                }
                var $focusTarget = $($element || this._focusTarget());
                this._renderInkWave($focusTarget, null, isFocused, 0)
            },
            _renderLabels: function() {
                this.element().removeClass(SLIDER_LABEL_POSITION_CLASS_PREFIX + "bottom").removeClass(SLIDER_LABEL_POSITION_CLASS_PREFIX + "top");
                if (this.option("label.visible")) {
                    var min = this.option("min"),
                        max = this.option("max"),
                        position = this.option("label.position"),
                        labelFormat = this.option("label.format");
                    if (!this._$minLabel) {
                        this._$minLabel = $("<div>").addClass(SLIDER_LABEL_CLASS).appendTo(this._$wrapper)
                    }
                    this._$minLabel.html(numberLocalization.format(min, labelFormat));
                    if (!this._$maxLabel) {
                        this._$maxLabel = $("<div>").addClass(SLIDER_LABEL_CLASS).appendTo(this._$wrapper)
                    }
                    this._$maxLabel.html(numberLocalization.format(max, labelFormat));
                    this.element().addClass(SLIDER_LABEL_POSITION_CLASS_PREFIX + position)
                } else {
                    if (this._$minLabel) {
                        this._$minLabel.remove();
                        delete this._$minLabel
                    }
                    if (this._$maxLabel) {
                        this._$maxLabel.remove();
                        delete this._$maxLabel
                    }
                }
            },
            _renderDimensions: function() {
                this.callBase();
                if (this._$bar) {
                    var barMarginWidth = this._$bar.outerWidth(true) - this._$bar.outerWidth();
                    this._$bar.width(this.option("width") - barMarginWidth)
                }
            },
            _renderStartHandler: function() {
                var pointerDownEventName = eventUtils.addNamespace(pointerEvents.down, this.NAME),
                    clickEventName = eventUtils.addNamespace(clickEvent.name, this.NAME),
                    startAction = this._createAction($.proxy(this._startHandler, this));
                this.element().off(pointerDownEventName).on(pointerDownEventName, function(e) {
                    if (eventUtils.isMouseEvent(e)) {
                        startAction({
                            jQueryEvent: e
                        })
                    }
                }).off(clickEventName).on(clickEventName, $.proxy(function(e) {
                    var handle = this._activeHandle();
                    handle && handle.focusin() && handle.focus();
                    startAction({
                        jQueryEvent: e
                    })
                }, this))
            },
            _itemWidthFunc: function() {
                return this._itemWidthRatio
            },
            _swipeStartHandler: function(e) {
                var startOffset, endOffset, rtlEnabled = this.option("rtlEnabled");
                if (eventUtils.isTouchEvent(e.jQueryEvent)) {
                    this._createAction($.proxy(this._startHandler, this))({
                        jQueryEvent: e.jQueryEvent
                    })
                }
                this._feedbackDeferred = $.Deferred();
                feedbackEvents.lock(this._feedbackDeferred);
                this._toggleActiveState(this._activeHandle(), this.option("activeStateEnabled"));
                this._startOffset = this._currentRatio;
                startOffset = this._startOffset * this._swipePixelRatio();
                endOffset = (1 - this._startOffset) * this._swipePixelRatio();
                e.jQueryEvent.maxLeftOffset = rtlEnabled ? endOffset : startOffset;
                e.jQueryEvent.maxRightOffset = rtlEnabled ? startOffset : endOffset;
                this._itemWidthRatio = this.element().width() / this._swipePixelRatio();
                this._needPreventAnimation = true
            },
            _swipeEndHandler: function(e) {
                this._feedbackDeferred.resolve();
                this._toggleActiveState(this._activeHandle(), false);
                var offsetDirection = this.option("rtlEnabled") ? -1 : 1;
                delete this._needPreventAnimation;
                this._changeValueOnSwipe(this._startOffset + offsetDirection * e.jQueryEvent.targetOffset / this._swipePixelRatio());
                delete this._startOffset;
                this._renderValue()
            },
            _activeHandle: function() {
                return this._$handle
            },
            _swipeUpdateHandler: function(e) {
                this._saveValueChangeEvent(e);
                this._updateHandlePosition(e)
            },
            _updateHandlePosition: function(e) {
                var offsetDirection = this.option("rtlEnabled") ? -1 : 1;
                var newRatio = this._startOffset + offsetDirection * e.jQueryEvent.offset / this._swipePixelRatio();
                this._$range.width(100 * newRatio + "%");
                SliderHandle.getInstance(this._activeHandle()).fitTooltipPosition;
                this._changeValueOnSwipe(newRatio)
            },
            _swipePixelRatio: function() {
                var min = this.option("min"),
                    max = this.option("max"),
                    step = this._valueStep(this.option("step"));
                return (max - min) / step
            },
            _valueStep: function(step) {
                if (!step || isNaN(step)) {
                    step = 1
                }
                step = parseFloat(step.toFixed(5));
                if (0 === step) {
                    step = 1e-5
                }
                return step
            },
            _changeValueOnSwipe: function(ratio) {
                var min = this.option("min"),
                    max = this.option("max"),
                    step = this._valueStep(this.option("step")),
                    newChange = ratio * (max - min),
                    newValue = min + newChange;
                if (step < 0) {
                    return
                }
                if (newValue === max || newValue === min) {
                    this.option("value", newValue)
                } else {
                    var stepExponent = (step + "").split(".")[1];
                    var minExponent = (min + "").split(".")[1];
                    var exponentLength = Math.max(stepExponent && stepExponent.length || 0, minExponent && minExponent.length || 0);
                    var stepCount = Math.round((newValue - min) / step);
                    newValue = Number((stepCount * step + min).toFixed(exponentLength));
                    this.option("value", Math.max(Math.min(newValue, max), min))
                }
            },
            _startHandler: function(args) {
                var e = args.jQueryEvent;
                this._currentRatio = (eventUtils.eventData(e).x - this._$bar.offset().left) / this._$bar.width();
                if (this.option("rtlEnabled")) {
                    this._currentRatio = 1 - this._currentRatio
                }
                this._saveValueChangeEvent(e);
                this._changeValueOnSwipe(this._currentRatio)
            },
            _renderValue: function() {
                this.callBase();
                var value = this.option("value");
                SliderHandle.getInstance(this._activeHandle()).option("value", value)
            },
            _setRangeStyles: function(options) {
                this._$range.css(options)
            },
            _callHandlerMethod: function(name, args) {
                SliderHandle.getInstance(this._$handle)[name](args)
            },
            _repaintHandle: function() {
                this._callHandlerMethod("repaint")
            },
            _fitTooltip: function() {
                this._callHandlerMethod("fitTooltipPosition")
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "visible":
                        this.callBase(args);
                        this._renderHandle();
                        this._repaintHandle();
                        domUtils.triggerShownEvent(this.element());
                        break;
                    case "min":
                    case "max":
                        this._renderLabels();
                        this._renderAriaMinAndMax();
                        this.callBase(args);
                        this._fitTooltip();
                        break;
                    case "step":
                        this._renderValue();
                        break;
                    case "keyStep":
                        break;
                    case "showRange":
                        this._renderRangeVisibility();
                        break;
                    case "tooltip":
                        this._renderHandle();
                        break;
                    case "label":
                        this._renderLabels();
                        break;
                    case "rtlEnabled":
                        this._toggleRTLDirection();
                        this._renderValue();
                        break;
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _refresh: function() {
                this._renderDimensions();
                this._renderValue();
                this._renderHandle();
                this._repaintHandle()
            }
        });
        registerComponent("dxSlider", Slider);
        module.exports = Slider
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/slider/ui.slider_handle.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            Tooltip = __webpack_require__( /*! ../tooltip */ 303),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            positionUtils = __webpack_require__( /*! ../../animation/position */ 61),
            mathUtils = __webpack_require__( /*! ../../core/utils/math */ 79),
            numberLocalization = __webpack_require__( /*! ../../localization/number */ 22);
        var SLIDER_CLASS = "dx-slider",
            SLIDER_HANDLE_CLASS = "dx-slider-handle";
        var POSITION_ALIASES = {
            top: {
                my: "bottom center",
                at: "top center",
                collision: "none"
            },
            bottom: {
                my: "top center",
                at: "bottom center",
                collision: "none"
            },
            right: {
                my: "left center",
                at: "right center",
                collision: "none"
            },
            left: {
                my: "right center",
                at: "left center",
                collision: "none"
            }
        };
        var SliderHandle = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: false,
                    value: 0,
                    tooltipEnabled: false,
                    tooltipFormat: function(v) {
                        return v
                    },
                    tooltipPosition: "top",
                    tooltipShowMode: "onHover",
                    tooltipFitIn: null
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass(SLIDER_HANDLE_CLASS);
                this._renderTooltip();
                this.setAria({
                    role: "slider",
                    valuenow: this.option("value")
                })
            },
            _renderTooltip: function() {
                if (this.option("tooltipEnabled")) {
                    if (!this._$tooltip) {
                        this._$tooltip = $("<div>").appendTo(this.element())
                    }
                    this._$slider = this.element().closest("." + SLIDER_CLASS);
                    this._updateTooltip()
                } else {
                    this._removeTooltip()
                }
            },
            _createTooltip: function() {
                if (this._tooltip) {
                    return false
                }
                this._tooltip = this._createComponent(this._$tooltip, Tooltip, {
                    visible: true,
                    target: this.element(),
                    closeOnOutsideClick: false,
                    container: this.element(),
                    closeOnBackButton: false,
                    closeOnTargetScroll: false,
                    onPositioned: $.proxy(function(args) {
                        this._saveTooltipElements(args.component);
                        this._saveTooltipLocation();
                        this._centeredTooltipPosition()
                    }, this),
                    animation: null,
                    arrowPosition: null,
                    templatesRenderAsynchronously: false
                });
                return true
            },
            _removeTooltip: function() {
                if (!this._$tooltip) {
                    return
                }
                this._$tooltip.remove();
                delete this._$tooltip;
                delete this._tooltip
            },
            _renderTooltipPosition: function() {
                if (!this._tooltip) {
                    return
                }
                var position = this.option("tooltipPosition");
                this._saveTooltipElements();
                this._resetTooltipPosition();
                if ("string" === $.type(position)) {
                    position = $.extend({
                        boundary: this._$slider,
                        boundaryOffset: {
                            h: 1,
                            v: 1
                        }
                    }, POSITION_ALIASES[position])
                }
                this._tooltip.option("position", position);
                this._saveTooltipLocation()
            },
            _saveTooltipElements: function(tooltip) {
                tooltip = this._tooltip || tooltip;
                this._$tooltipContent = tooltip.content().parent();
                this._$tooltipArrow = this._$tooltipContent.find(".dx-popover-arrow")
            },
            _resetTooltipPosition: function() {
                translator.resetPosition(this._$tooltipContent);
                translator.resetPosition(this._$tooltipArrow)
            },
            _saveTooltipLocation: function() {
                this._contentLocate = translator.locate(this._$tooltipContent)
            },
            _centeredTooltipPosition: function() {
                if (!this._tooltip) {
                    return
                }
                this._$tooltipContent.outerWidth("auto");
                var outerWidthWithoutRounding = this._$tooltipContent.get(0).getBoundingClientRect().width;
                var tooltipOuterWidth = Math.ceil(outerWidthWithoutRounding);
                var roundedTooltipOuterWidth = tooltipOuterWidth % 2 + tooltipOuterWidth;
                this._$tooltipContent.outerWidth(roundedTooltipOuterWidth);
                var tooltipCenter = (roundedTooltipOuterWidth - this.element().width()) / 2;
                this._contentLocate.left = -tooltipCenter;
                this._$tooltipArrow.css({
                    marginLeft: -this._$tooltipArrow.outerWidth() / 2,
                    left: "50%"
                });
                this._fitTooltip()
            },
            _fitTooltip: function() {
                if (!this._tooltip) {
                    return
                }
                var position = this.option("tooltipPosition");
                if ("string" === $.type(position)) {
                    position = $.extend({
                        of: this.element(),
                        boundary: this._$slider,
                        boundaryOffset: {
                            h: 2,
                            v: 1
                        }
                    }, POSITION_ALIASES[position], {
                        collision: "fit none"
                    })
                }
                var calculatePosition = positionUtils.calculate(this._$tooltipContent, position);
                var isLeftSide = "left" === calculatePosition.h.collisionSide;
                var arrowLeft = (isLeftSide ? -1 : 1) * calculatePosition.h.oversize,
                    arrowMinLeft = this._contentLocate.left,
                    arrowMaxRight = this._contentLocate.left + this._$tooltipContent.outerWidth() - this._$tooltipArrow.outerWidth();
                translator.move(this._$tooltipContent, {
                    left: this._contentLocate.left + (isLeftSide ? 1 : -1) * calculatePosition.h.oversize
                });
                translator.move(this._$tooltipArrow, {
                    left: mathUtils.fitIntoRange(arrowLeft, arrowMinLeft, arrowMaxRight)
                })
            },
            _renderValue: function() {
                if (!this._tooltip) {
                    return
                }
                var formattedValue = numberLocalization.format(this.option("value"), this.option("tooltipFormat"));
                this._tooltip.content().html(formattedValue);
                this._fitTooltip()
            },
            _updateTooltip: function() {
                var hoverMode = /^onhover$/i.test(this.option("tooltipShowMode"));
                if (!hoverMode) {
                    this._createTooltip()
                }
                this.element().toggleClass("dx-slider-tooltip-on-hover", hoverMode);
                this._renderTooltipPosition();
                this._renderValue();
                this._centeredTooltipPosition()
            },
            _clean: function() {
                this.callBase();
                delete this._$tooltip;
                delete this._tooltip
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "tooltipFormat":
                        this._renderValue();
                        break;
                    case "value":
                        this._renderValue();
                        if (args.value.toString().length !== args.previousValue.toString().length) {
                            this._centeredTooltipPosition()
                        }
                        this.setAria("valuenow", args.value);
                        break;
                    case "tooltipEnabled":
                        this._renderTooltip();
                        break;
                    case "tooltipPosition":
                        this._renderTooltipPosition();
                        this._centeredTooltipPosition();
                        break;
                    case "tooltipShowMode":
                        this._updateTooltip();
                        break;
                    case "tooltipFitIn":
                        this._fitTooltip();
                        break;
                    case "_templates":
                    case "templateProvider":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            fitTooltipPosition: function() {
                this._fitTooltip()
            },
            updateTooltip: function() {
                if (!this._createTooltip()) {
                    return
                }
                this._renderTooltipPosition();
                this._renderValue();
                this._centeredTooltipPosition()
            },
            repaint: function() {
                this._renderTooltipPosition();
                this._centeredTooltipPosition();
                if (this._tooltip) {
                    this._tooltip._visibilityChanged(true)
                }
            }
        });
        module.exports = SliderHandle
    },
    /*!*******************************!*\
      !*** ./Scripts/ui/tooltip.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./tooltip/tooltip */ 304);
        module.exports.show = __webpack_require__( /*! ./tooltip/ui.tooltip */ 305).show;
        module.exports.hide = __webpack_require__( /*! ./tooltip/ui.tooltip */ 305).hide
    },
    /*!***************************************!*\
      !*** ./Scripts/ui/tooltip/tooltip.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Popover = __webpack_require__( /*! ../popover */ 202),
            TOOLTIP_CLASS = "dx-tooltip",
            TOOLTIP_WRAPPER_CLASS = "dx-tooltip-wrapper";
        var Tooltip = Popover.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    toolbarItems: [],
                    showCloseButton: false,
                    showTitle: false,
                    title: null,
                    titleTemplate: null,
                    onTitleRendered: null,
                    bottomTemplate: null,
                    propagateOutsideClick: true
                })
            },
            _render: function() {
                this.element().addClass(TOOLTIP_CLASS);
                this._wrapper().addClass(TOOLTIP_WRAPPER_CLASS);
                this.callBase()
            },
            _renderContent: function() {
                this.callBase();
                this._contentId = new Guid;
                this._$content.attr({
                    id: this._contentId,
                    role: "tooltip"
                });
                this._toggleAriaDescription(true)
            },
            _toggleAriaDescription: function(showing) {
                var $target = $(this.option("target")),
                    label = showing ? this._contentId : void 0;
                this.setAria("describedby", label, $target)
            }
        });
        registerComponent("dxTooltip", Tooltip);
        module.exports = Tooltip
    },
    /*!******************************************!*\
      !*** ./Scripts/ui/tooltip/ui.tooltip.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Tooltip = __webpack_require__( /*! ./tooltip */ 304),
            viewPortUtils = __webpack_require__( /*! ../../core/utils/view_port */ 42);
        var tooltip = null;
        var removeTooltipElement = null;
        var createTooltip = function(options) {
            options = $.extend({
                position: "top"
            }, options);
            var content = options.content;
            delete options.content;
            var $tooltip = $("<div />").html(content).appendTo(viewPortUtils.value());
            removeTooltipElement = function() {
                $tooltip.remove()
            };
            tooltip = new Tooltip($tooltip, options)
        };
        var removeTooltip = function() {
            if (!tooltip) {
                return
            }
            removeTooltipElement();
            tooltip = null
        };
        exports.show = function(options) {
            removeTooltip();
            createTooltip(options);
            return tooltip.show()
        };
        exports.hide = function() {
            if (!tooltip) {
                return $.when()
            }
            return tooltip.hide().done(removeTooltip).promise()
        }
    },
    /*!***********************************!*\
      !*** ./Scripts/ui/scroll_view.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./scroll_view/ui.scroll_view */ 227).ScrollView
    },
    /*!**********************************!*\
      !*** ./Scripts/ui/select_box.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            errors = __webpack_require__( /*! ../core/errors */ 17),
            inkRipple = __webpack_require__( /*! ./widget/utils.ink_ripple */ 197),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            DropDownList = __webpack_require__( /*! ./drop_down_editor/ui.drop_down_list */ 204),
            themes = __webpack_require__( /*! ./themes */ 143),
            clickEvent = __webpack_require__( /*! ../events/click */ 64);
        var DISABLED_STATE_SELECTOR = ".dx-state-disabled",
            SELECTBOX_CLASS = "dx-selectbox",
            SELECTBOX_POPUP_CLASS = "dx-selectbox-popup",
            SELECTBOX_CONTAINER_CLASS = "dx-selectbox-container",
            SELECTBOX_POPUP_WRAPPER_CLASS = "dx-selectbox-popup-wrapper";
        var SelectBox = DropDownList.inherit({
            _supportedKeys: function() {
                var that = this,
                    parent = this.callBase(),
                    clearSelectBox = function(e) {
                        var isEditable = this._isEditable();
                        if (!isEditable) {
                            if (this.option("showClearButton")) {
                                e.preventDefault();
                                this.reset()
                            }
                        } else {
                            if (this._valueSubstituted()) {
                                this._preventFiltering = true
                            }
                        }
                        this._preventSubstitution = true
                    };
                var searchIfNeeded = function() {
                    if (that.option("searchEnabled") && that._valueSubstituted()) {
                        that._searchHandler()
                    }
                };
                return $.extend({}, parent, {
                    tab: function(e) {
                        if (this.option("opened") && "instantly" === this.option("applyValueMode")) {
                            this._cleanInputSelection()
                        }
                        parent.tab.apply(this, arguments)
                    },
                    upArrow: function(e) {
                        if (parent.upArrow.apply(this, arguments)) {
                            if (!this.option("opened")) {
                                this._setNextValue(-1)
                            }
                            return true
                        }
                    },
                    downArrow: function(e) {
                        if (parent.downArrow.apply(this, arguments)) {
                            if (!this.option("opened")) {
                                this._setNextValue(1)
                            }
                            return true
                        }
                    },
                    leftArrow: function() {
                        searchIfNeeded();
                        parent.leftArrow.apply(this, arguments)
                    },
                    rightArrow: function() {
                        searchIfNeeded();
                        parent.rightArrow.apply(this, arguments)
                    },
                    home: function() {
                        searchIfNeeded();
                        parent.home.apply(this, arguments)
                    },
                    end: function() {
                        searchIfNeeded();
                        parent.end.apply(this, arguments)
                    },
                    enter: function(e) {
                        if ("" === this._input().val() && this.option("value")) {
                            this.option({
                                selectedItem: null,
                                value: null
                            });
                            this.close()
                        } else {
                            if (this.option("acceptCustomValue")) {
                                e.preventDefault()
                            }
                            if (parent.enter.apply(this, arguments)) {
                                return this.option("opened")
                            }
                        }
                    },
                    backspace: clearSelectBox,
                    del: clearSelectBox
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    placeholder: messageLocalization.format("Select"),
                    fieldTemplate: null,
                    valueChangeEvent: "change",
                    acceptCustomValue: false,
                    onCustomItemCreating: function(e) {
                        return e.text
                    },
                    showSelectionControls: false,
                    autocompletionEnabled: true,
                    tooltipEnabled: false,
                    openOnFieldClick: true,
                    showDropButton: true,
                    displayCustomValue: false,
                    _isAdaptablePopupPosition: false,
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        return /win8/.test(themes.current())
                    },
                    options: {
                        _isAdaptablePopupPosition: true,
                        popupPosition: {
                            at: "left top",
                            offset: {
                                h: 0,
                                v: 0
                            }
                        }
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        _isAdaptablePopupPosition: true,
                        popupPosition: {
                            offset: {
                                h: -16,
                                v: -8
                            }
                        }
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this._initCustomItemCreatingAction()
            },
            _render: function() {
                this.callBase();
                this.element().addClass(SELECTBOX_CLASS);
                this.option("useInkRipple") && this._renderInkRipple();
                this._renderTooltip();
                this._$container.addClass(SELECTBOX_CONTAINER_CLASS)
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render()
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                if (!this._inkRipple || this._isEditable()) {
                    return
                }
                var config = {
                    element: this._inputWrapper(),
                    jQueryEvent: e
                };
                if (value) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _createPopup: function() {
                this.callBase();
                this._popup.element().addClass(SELECTBOX_POPUP_CLASS)
            },
            _popupWrapperClass: function() {
                return this.callBase() + " " + SELECTBOX_POPUP_WRAPPER_CLASS
            },
            _renderOpenedState: function() {
                this.callBase();
                if (this.option("opened")) {
                    this._updatePopupHeight();
                    this._scrollToSelectedItem();
                    this._focusSelectedElement()
                }
            },
            _focusSelectedElement: function() {
                var searchValue = this._searchValue();
                if (!searchValue) {
                    this._focusListElement(null);
                    return
                }
                var $listItems = this._list._itemElements(),
                    selectedItem = this.option("selectedItem"),
                    index = $.inArray(selectedItem, this.option("items")),
                    isSelectedItemDisplayed = selectedItem && searchValue === this._displayGetter(selectedItem).toString(),
                    focusedElement = index >= 0 && isSelectedItemDisplayed ? $listItems.eq(index) : null;
                this._focusListElement(focusedElement)
            },
            _renderFocusedElement: function() {
                var searchValue = this._searchValue();
                if (!searchValue || this.option("acceptCustomValue")) {
                    this._focusListElement(null);
                    return
                }
                var $listItems = this._list._itemElements(),
                    focusedElement = $listItems.not(DISABLED_STATE_SELECTOR).eq(0);
                this._focusListElement(focusedElement)
            },
            _focusListElement: function(element) {
                if (!this._list) {
                    return
                }
                this._preventInputValueRender = true;
                this._list.option("focusedElement", element);
                delete this._preventInputValueRender
            },
            _scrollToSelectedItem: function() {
                if (this._dataSource.paginate() && this._isEditable()) {
                    this._list.scrollTo(0)
                } else {
                    this._list.scrollToItem(this._list.option("selectedItem"))
                }
            },
            _listContentReadyHandler: function() {
                this.callBase();
                if (this._dataSource.paginate() && this._isEditable()) {
                    return
                }
                this._list.scrollToItem(this._list.option("selectedItem"))
            },
            _renderValue: function() {
                this._renderInputValue()
            },
            _renderInputValue: function() {
                return this.callBase().always($.proxy(function() {
                    this._renderTooltip();
                    this._renderInputValueImpl();
                    this._refreshSelected()
                }, this))
            },
            _renderInputValueImpl: function() {
                this._renderInputAddons()
            },
            _fitIntoRange: function(value, start, end) {
                if (value > end) {
                    return start
                }
                if (value < start) {
                    return end
                }
                return value
            },
            _setNextValue: function(step) {
                var dataSourceIsLoaded = this._dataSource.isLoaded() ? $.Deferred().resolve() : this._dataSource.load();
                dataSourceIsLoaded.done($.proxy(function() {
                    var item = this._calcNextItem(step),
                        value = this._valueGetter(item);
                    this._setValue(value)
                }, this))
            },
            _calcNextItem: function(step) {
                var items = this._items();
                var nextIndex = this._fitIntoRange(this._getSelectedIndex() + step, 0, items.length - 1);
                return items[nextIndex]
            },
            _items: function() {
                return this._list ? this.option("items") : this._dataSource.items()
            },
            _getSelectedIndex: function() {
                var items = this._items();
                var selectedItem = this.option("selectedItem");
                var result = -1;
                $.each(items, $.proxy(function(index, item) {
                    if (this._isValueEquals(item, selectedItem)) {
                        result = index;
                        return false
                    }
                }, this));
                return result
            },
            _setSelectedItem: function(item) {
                var isUnknownItem = !this._isCustomValueAllowed() && void 0 === item;
                this.callBase(isUnknownItem ? null : item)
            },
            _isCustomValueAllowed: function() {
                return this.option("acceptCustomValue") || this.callBase()
            },
            _displayValue: function(item) {
                item = !commonUtils.isDefined(item) && this._isCustomValueAllowed() ? this.option("value") : item;
                return this.callBase(item)
            },
            _listConfig: function() {
                var result = $.extend(this.callBase(), {
                    pageLoadMode: "scrollBottom",
                    onSelectionChanged: this._getSelectionChangeHandler(),
                    onFocusedItemChanged: $.proxy(this._listFocusedItemChangeHandler, this)
                });
                if (this.option("showSelectionControls")) {
                    $.extend(result, {
                        showSelectionControls: true
                    })
                }
                return result
            },
            _listFocusedItemChangeHandler: function(e) {
                if (this._preventInputValueRender) {
                    return
                }
                var list = e.component,
                    focusedElement = list.option("focusedElement"),
                    focusedItem = list._getItemData(focusedElement);
                this._updateField(focusedItem)
            },
            _updateField: function(item) {
                var fieldTemplate = this._getTemplateByOption("fieldTemplate");
                if (!(fieldTemplate && this.option("fieldTemplate"))) {
                    this._renderDisplayText(this._displayGetter(item));
                    return
                }
                this._renderTemplatedField(fieldTemplate, item)
            },
            _getSelectionChangeHandler: function() {
                return this.option("showSelectionControls") ? $.proxy(this._selectionChangeHandler, this) : $.noop
            },
            _selectionChangeHandler: function(e) {
                $.each(e.addedItems || [], $.proxy(function(_, addedItem) {
                    this._setValue(this._valueGetter(addedItem))
                }, this))
            },
            _toggleOpenState: function(isVisible) {
                if (this.option("disabled")) {
                    return
                }
                isVisible = arguments.length ? isVisible : !this.option("opened");
                if (this._wasSearch() && isVisible) {
                    this._wasSearch(false);
                    if (this.option("showDataBeforeSearch") || 0 === this.option("minSearchLength")) {
                        this._filterDataSource(null)
                    } else {
                        this._setListOption("items", []);
                        this._list && this._setListOption("noDataText", this._list.initialOption("noDataText"))
                    }
                }
                this.callBase(isVisible)
            },
            _renderTooltip: function() {
                if (this.option("tooltipEnabled")) {
                    this.element().attr("title", this.option("displayValue"))
                }
            },
            _renderDimensions: function() {
                this.callBase();
                this._setPopupOption("width")
            },
            _focusOutHandler: function(e) {
                this.callBase(e);
                if (!this.option("searchEnabled") || this.option("acceptCustomValue")) {
                    return
                }
                if (!this._searchValue()) {
                    this._clearTextValue();
                    return
                }
                var selectedItem = this.option("selectedItem");
                this._renderInputValue().always($.proxy(function(e) {
                    this._setSelectedItem(selectedItem);
                    this._renderDisplayText(this._displayGetter(this.option("selectedItem")))
                }, this))
            },
            _clearTextValue: function() {
                this.reset()
            },
            _renderValueChangeEvent: function() {
                if (this._isEditable()) {
                    this.callBase()
                }
            },
            _isEditable: function() {
                return this.option("acceptCustomValue") || this.option("searchEnabled")
            },
            _fieldRenderData: function() {
                return this.option("selectedItem")
            },
            _readOnlyPropValue: function() {
                return !this._isEditable() || this.option("readOnly")
            },
            _isSelectedValue: function(value) {
                return this._isValueEquals(value, this.option("value"))
            },
            _listItemClickHandler: function(e) {
                var previousValue = this._getCurrentValue();
                this._saveValueChangeEvent(e.jQueryEvent);
                this._completeSelection(this._valueGetter(e.itemData));
                this.option("opened", false);
                if (this.option("searchEnabled") && previousValue === this._valueGetter(e.itemData)) {
                    this._renderDisplayText(this._displayGetter(e.itemData))
                }
            },
            _completeSelection: function(value) {
                if (this._wasSearch()) {
                    this._clearFilter()
                }
                this._setValue(value)
            },
            _clearValueHandler: function() {
                this.reset()
            },
            _loadItem: function(value) {
                var that = this,
                    deferred = $.Deferred();
                this.callBase(value).done(function(item) {
                    deferred.resolve(item)
                }).fail(function() {
                    if (that.option("acceptCustomValue")) {
                        deferred.resolve(that.option("selectedItem"))
                    } else {
                        deferred.reject()
                    }
                });
                return deferred.promise()
            },
            _valueChangeEventHandler: function(e) {
                if (!this.option("acceptCustomValue")) {
                    return
                }
                this._customItemAddedHandler()
            },
            _initCustomItemCreatingAction: function() {
                this._customItemCreatingAction = this._createActionByOption("onCustomItemCreating")
            },
            _customItemAddedHandler: function() {
                var searchValue = this._searchValue(),
                    item = this._customItemCreatingAction({
                        text: searchValue
                    }),
                    isDeferred = item && item.promise && item.done && item.fail;
                if (void 0 === item) {
                    this._renderValue();
                    throw errors.Error("E0121")
                }
                isDeferred ? item.always($.proxy(this._setCustomItem, this)) : this._setCustomItem(item)
            },
            _setCustomItem: function(item) {
                item = item || null;
                this.option("selectedItem", item);
                this._setValue(this._valueGetter(item));
                this._renderDisplayText(this._displayGetter(item))
            },
            _createClearButton: function() {
                var eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                return this.callBase().on(eventName, function() {
                    return false
                })
            },
            _wasSearch: function(value) {
                if (!arguments.length) {
                    return this._wasSearchValue
                }
                this._wasSearchValue = value
            },
            _searchHandler: function(e) {
                if (e && this._isControlKey(e.which || e.keyCode) || this._preventFiltering) {
                    delete this._preventFiltering;
                    return
                }
                if (this._needPassDataSourceToList()) {
                    this._wasSearch(true)
                }
                this.callBase(e)
            },
            _filterDataSource: function(searchValue) {
                this.callBase(searchValue);
                this._setCollectionWidgetOption("noDataText", searchValue ? "" : this._list && this._list.initialOption("noDataText"))
            },
            _dataSourceFiltered: function(searchValue) {
                this.callBase();
                this._renderInputSubstitution();
                if (null !== searchValue) {
                    this._renderFocusedElement()
                }
            },
            _valueSubstituted: function() {
                var input = this._input().get(0),
                    inputHasSelection = input.selectionStart !== input.selectionEnd;
                return this._wasSearch() && inputHasSelection
            },
            _shouldSubstitutionBeRendered: function() {
                return this.option("autocompletionEnabled") && !this._preventSubstitution && this.option("searchEnabled") && !this.option("acceptCustomValue") && "startswith" === this.option("searchMode")
            },
            _renderInputSubstitution: function() {
                if (!this._shouldSubstitutionBeRendered()) {
                    delete this._preventSubstitution;
                    return
                }
                var item = this._list && this._list.option("items")[0];
                if (!item) {
                    return
                }
                var $input = this._input(),
                    valueLength = $input.val().length;
                if (0 === valueLength) {
                    return
                }
                var inputElement = $input.get(0),
                    displayValue = this._displayGetter(item);
                inputElement.value = displayValue;
                inputElement.selectionStart = valueLength;
                inputElement.selectionEnd = displayValue.length
            },
            _cleanInputSelection: function() {
                var inputElement = this._input().get(0),
                    endPosition = inputElement.value.length;
                inputElement.selectionStart = endPosition;
                inputElement.selectionEnd = endPosition
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "_isAdaptablePopupPosition":
                    case "autocompletionEnabled":
                        break;
                    case "onCustomItemCreating":
                        this._initCustomItemCreatingAction();
                        break;
                    case "tooltipEnabled":
                        this._renderTooltip();
                        break;
                    case "displayCustomValue":
                    case "acceptCustomValue":
                    case "showSelectionControls":
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxSelectBox", SelectBox);
        module.exports = SelectBox
    },
    /*!******************************!*\
      !*** ./Scripts/ui/switch.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            inkRipple = __webpack_require__( /*! ./widget/utils.ink_ripple */ 197),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Editor = __webpack_require__( /*! ./editor/editor */ 107),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            feedbackEvents = __webpack_require__( /*! ../events/core/emitter.feedback */ 103),
            themes = __webpack_require__( /*! ./themes */ 143),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            Swipeable = __webpack_require__( /*! ../events/gesture/swipeable */ 248);
        var SWITCH_CLASS = "dx-switch",
            SWITCH_WRAPPER_CLASS = SWITCH_CLASS + "-wrapper",
            SWITCH_CONTAINER_CLASS = SWITCH_CLASS + "-container",
            SWITCH_INNER_CLASS = SWITCH_CLASS + "-inner",
            SWITCH_HANDLE_CLASS = SWITCH_CLASS + "-handle",
            SWITCH_ON_VALUE_CLASS = SWITCH_CLASS + "-on-value",
            SWITCH_ON_CLASS = SWITCH_CLASS + "-on",
            SWITCH_OFF_CLASS = SWITCH_CLASS + "-off",
            SWITCH_ANIMATION_DURATION = 100;
        var Switch = Editor.inherit({
            _supportedKeys: function() {
                var isRTL = this.option("rtlEnabled");
                var click = function(e) {
                        e.preventDefault();
                        this._clickAction({
                            jQueryEvent: e
                        })
                    },
                    move = function(value, e) {
                        e.preventDefault();
                        e.stopPropagation();
                        this._animateValue(value)
                    };
                return $.extend(this.callBase(), {
                    space: click,
                    enter: click,
                    leftArrow: $.proxy(move, this, isRTL ? true : false),
                    rightArrow: $.proxy(move, this, isRTL ? false : true)
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    activeStateEnabled: true,
                    onText: messageLocalization.format("dxSwitch-onText"),
                    offText: messageLocalization.format("dxSwitch-offText"),
                    value: false,
                    useInkRipple: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _feedbackHideTimeout: 0,
            _animating: false,
            _render: function() {
                var element = this.element();
                this._$switchInner = $("<div>").addClass(SWITCH_INNER_CLASS);
                this._$handle = $("<div>").addClass(SWITCH_HANDLE_CLASS).appendTo(this._$switchInner);
                this.option("useInkRipple") && this._renderInkRipple();
                this._$labelOn = $("<div>").addClass(SWITCH_ON_CLASS).prependTo(this._$switchInner);
                this._$labelOff = $("<div>").addClass(SWITCH_OFF_CLASS).appendTo(this._$switchInner);
                this._$switchContainer = $("<div>").addClass(SWITCH_CONTAINER_CLASS).append(this._$switchInner);
                this._$switchWrapper = $("<div>").addClass(SWITCH_WRAPPER_CLASS).append(this._$switchContainer);
                element.addClass(SWITCH_CLASS).append(this._$switchWrapper);
                this.setAria("role", "button");
                this._createComponent(element, Swipeable, {
                    elastic: false,
                    immediate: true,
                    onStart: $.proxy(this._swipeStartHandler, this),
                    onUpdated: $.proxy(this._swipeUpdateHandler, this),
                    onEnd: $.proxy(this._swipeEndHandler, this),
                    itemSizeFunc: $.proxy(this._getMarginBound, this)
                });
                this._renderLabels();
                this.callBase();
                this._updateMarginBound();
                this._renderValue();
                this._renderClick()
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render({
                    waveSizeCoefficient: 1.7,
                    isCentered: true,
                    useHoldAnimation: false,
                    wavesNumber: 2
                })
            },
            _renderInkWave: function(element, jQueryEvent, doRender, waveIndex) {
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: element,
                    jQueryEvent: jQueryEvent,
                    wave: waveIndex
                };
                if (doRender) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _updateFocusState: function(e, value) {
                this.callBase.apply(this, arguments);
                this._renderInkWave(this._$handle, e, value, 0)
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                this._renderInkWave(this._$handle, e, value, 1)
            },
            _updateMarginBound: function() {
                this._marginBound = this._$switchContainer.outerWidth(true) - this._$handle.outerWidth()
            },
            _getMarginBound: function() {
                return this._marginBound
            },
            _marginDirection: function() {
                return this.option("rtlEnabled") ? "Right" : "Left"
            },
            _offsetDirection: function() {
                return this.option("rtlEnabled") ? -1 : 1
            },
            _renderPosition: function(state, swipeOffset) {
                var stateInt = state ? 1 : 0,
                    marginDirection = this._marginDirection(),
                    resetMarginDirection = "Left" === marginDirection ? "Right" : "Left";
                this._$switchInner.css("margin" + marginDirection, this._getMarginBound() * (stateInt + swipeOffset - 1));
                this._$switchInner.css("margin" + resetMarginDirection, 0)
            },
            _validateValue: function() {
                var check = this.option("value");
                if ("boolean" !== typeof check) {
                    this._options.value = !!check
                }
            },
            _renderClick: function() {
                var eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                this._clickAction = this._createAction($.proxy(this._clickHandler, this));
                this.element().off(eventName).on(eventName, $.proxy(function(e) {
                    this._clickAction({
                        jQueryEvent: e
                    })
                }, this))
            },
            _clickHandler: function(args) {
                this.time = new Date;
                var e = args.jQueryEvent;
                this._saveValueChangeEvent(e);
                if (this._animating || this._swiping) {
                    return
                }
                this._animateValue(!this.option("value"))
            },
            _animateValue: function(value) {
                var startValue = this.option("value"),
                    endValue = value;
                if (startValue === endValue) {
                    return
                }
                this._animating = true;
                var that = this,
                    marginDirection = this._marginDirection(),
                    resetMarginDirection = "Left" === marginDirection ? "Right" : "Left",
                    fromConfig = {},
                    toConfig = {};
                this._$switchInner.css("margin" + resetMarginDirection, 0);
                fromConfig["margin" + marginDirection] = (Number(startValue) - 1) * this._getMarginBound();
                toConfig["margin" + marginDirection] = (Number(endValue) - 1) * this._getMarginBound();
                fx.animate(this._$switchInner, {
                    from: fromConfig,
                    to: toConfig,
                    duration: SWITCH_ANIMATION_DURATION,
                    complete: function() {
                        that._animating = false;
                        that.option("value", endValue)
                    }
                })
            },
            _swipeStartHandler: function(e) {
                var state = this.option("value"),
                    rtlEnabled = this.option("rtlEnabled"),
                    maxOffOffset = rtlEnabled ? 0 : 1,
                    maxOnOffset = rtlEnabled ? 1 : 0;
                e.jQueryEvent.maxLeftOffset = state ? maxOffOffset : maxOnOffset;
                e.jQueryEvent.maxRightOffset = state ? maxOnOffset : maxOffOffset;
                this._swiping = true;
                this._feedbackDeferred = $.Deferred();
                feedbackEvents.lock(this._feedbackDeferred);
                this._toggleActiveState(this.element(), this.option("activeStateEnabled"))
            },
            _swipeUpdateHandler: function(e) {
                this._renderPosition(this.option("value"), this._offsetDirection() * e.jQueryEvent.offset)
            },
            _swipeEndHandler: function(e) {
                var that = this,
                    offsetDirection = this._offsetDirection(),
                    toConfig = {};
                toConfig["margin" + this._marginDirection()] = this._getMarginBound() * (that.option("value") + offsetDirection * e.jQueryEvent.targetOffset - 1);
                fx.animate(this._$switchInner, {
                    to: toConfig,
                    duration: SWITCH_ANIMATION_DURATION,
                    complete: function() {
                        that._swiping = false;
                        var pos = that.option("value") + offsetDirection * e.jQueryEvent.targetOffset;
                        that.option("value", Boolean(pos));
                        that._feedbackDeferred.resolve();
                        that._toggleActiveState(that.element(), false)
                    }
                })
            },
            _renderValue: function() {
                this._validateValue();
                var val = this.option("value");
                this._renderPosition(val, 0);
                this.element().toggleClass(SWITCH_ON_VALUE_CLASS, val);
                this.setAria({
                    pressed: val,
                    label: val ? this.option("onText") : this.option("offText")
                })
            },
            _renderLabels: function() {
                this._$labelOn.text(this.option("onText"));
                this._$labelOff.text(this.option("offText"))
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this.repaint()
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    case "visible":
                    case "width":
                        this._refresh();
                        break;
                    case "onText":
                    case "offText":
                        this._renderLabels();
                        break;
                    case "value":
                        this._renderValue();
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxSwitch", Switch);
        module.exports = Switch
    },
    /*!*******************************!*\
      !*** ./Scripts/ui/tag_box.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            arrayUtils = __webpack_require__( /*! ../core/utils/array */ 111),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            SelectBox = __webpack_require__( /*! ./select_box */ 307),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            caret = __webpack_require__( /*! ./text_box/utils.caret */ 210),
            browser = __webpack_require__( /*! ../core/utils/browser */ 18);
        var TAGBOX_TAG_DATA_KEY = "dxTagData";
        var TAGBOX_CLASS = "dx-tagbox",
            TAGBOX_TAG_CONTAINER_CLASS = "dx-tag-container",
            TAGBOX_TAG_CLASS = "dx-tag",
            TAGBOX_TAG_REMOVE_BUTTON_CLASS = "dx-tag-remove-button",
            TAGBOX_ONLY_SELECT_CLASS = "dx-tagbox-only-select",
            TAGBOX_SINGLE_LINE_CLASS = "dx-tagbox-single-line",
            TAGBOX_POPUP_WRAPPER_CLASS = "dx-tagbox-popup-wrapper",
            LIST_SELECT_ALL_CHECKBOX_CLASS = "dx-list-select-all-checkbox",
            NATIVE_CLICK_CLASS = "dx-native-click";
        var TAGBOX_MOUSE_WHEEL_DELTA_MULTIPLIER = -.3;
        var TagBox = SelectBox.inherit({
            _supportedKeys: function() {
                var parent = this.callBase();
                return $.extend(parent, {
                    backspace: function(e) {
                        if (!this._isCaretAtTheStart()) {
                            return
                        }
                        e.preventDefault();
                        e.stopPropagation();
                        this._isTagRemoved = true;
                        var $tagToDelete = this._$focusedTag || this._tagElements().last();
                        if (this._$focusedTag) {
                            this._moveTagFocus("prev", true)
                        }
                        if (0 === $tagToDelete.length) {
                            return
                        }
                        this._preserveFocusedTag = true;
                        this._removeTagElement($tagToDelete);
                        delete this._preserveFocusedTag
                    },
                    del: function(e) {
                        if (!this._$focusedTag || !this._isCaretAtTheStart()) {
                            return
                        }
                        e.preventDefault();
                        e.stopPropagation();
                        this._isTagRemoved = true;
                        var $tagToDelete = this._$focusedTag;
                        this._moveTagFocus("next", true);
                        this._preserveFocusedTag = true;
                        this._removeTagElement($tagToDelete);
                        delete this._preserveFocusedTag
                    },
                    enter: function(e) {
                        var isListItemFocused = this._list && null !== this._list.option("focusedElement"),
                            isCustomItem = this.option("acceptCustomValue") && !isListItemFocused;
                        if (isCustomItem) {
                            e.preventDefault();
                            "" !== this._searchValue() && this._customItemAddedHandler();
                            return
                        }
                        if (!this.option("opened")) {
                            return
                        }
                        e.preventDefault();
                        this._keyboardProcessor._childProcessors[0].process(e)
                    },
                    leftArrow: function(e) {
                        if (!this._isCaretAtTheStart()) {
                            return
                        }
                        var rtlEnabled = this.option("rtlEnabled");
                        if (this._isEditable() && rtlEnabled && !this._$focusedTag) {
                            return
                        }
                        e.preventDefault();
                        var direction = rtlEnabled ? "next" : "prev";
                        this._moveTagFocus(direction);
                        !this.option("multiline") && this._scrollContainer(direction)
                    },
                    rightArrow: function(e) {
                        if (!this._isCaretAtTheStart()) {
                            return
                        }
                        var rtlEnabled = this.option("rtlEnabled");
                        if (this._isEditable() && !rtlEnabled && !this._$focusedTag) {
                            return
                        }
                        e.preventDefault();
                        var direction = rtlEnabled ? "prev" : "next";
                        this._moveTagFocus(direction);
                        !this.option("multiline") && this._scrollContainer(direction)
                    }
                })
            },
            _isCaretAtTheStart: function() {
                return 0 === caret(this._input()).start
            },
            _moveTagFocus: function(direction, clearOnBoundary) {
                if (!this._$focusedTag) {
                    var tagElements = this._tagElements();
                    this._$focusedTag = "next" === direction ? tagElements.first() : tagElements.last();
                    this._toggleFocusClass(true, this._$focusedTag);
                    return
                }
                var $nextFocusedTag = this._$focusedTag[direction]("." + TAGBOX_TAG_CLASS);
                if ($nextFocusedTag.length > 0) {
                    this._replaceFocusedTag($nextFocusedTag)
                } else {
                    if (clearOnBoundary || "next" === direction && this._isEditable()) {
                        this._clearTagFocus()
                    }
                }
            },
            _replaceFocusedTag: function($nextFocusedTag) {
                this._toggleFocusClass(false, this._$focusedTag);
                this._$focusedTag = $nextFocusedTag;
                this._toggleFocusClass(true, this._$focusedTag)
            },
            _clearTagFocus: function() {
                if (!this._$focusedTag) {
                    return
                }
                this._toggleFocusClass(false, this._$focusedTag);
                delete this._$focusedTag
            },
            _focusClassTarget: function($element) {
                if ($element && $element.length && $element[0] !== this._focusTarget()[0]) {
                    return $element
                }
                return this.callBase()
            },
            _scrollContainer: function(direction) {
                if (this.option("multiline")) {
                    return
                }
                if (!this._$tagsContainer) {
                    return
                }
                var scrollPosition = this._getScrollPosition(direction);
                this._$tagsContainer.scrollLeft(scrollPosition)
            },
            _getScrollPosition: function(direction) {
                if ("start" === direction || "end" === direction) {
                    return this._getBorderPosition(direction)
                }
                return this._$focusedTag ? this._getFocusedTagPosition(direction) : this._getBorderPosition("end")
            },
            _getBorderPosition: function(direction) {
                var rtlEnabled = this.option("rtlEnabled"),
                    isScrollLeft = "end" === direction ^ rtlEnabled,
                    isScrollReverted = rtlEnabled && !browser.webkit,
                    scrollSign = !rtlEnabled || browser.webkit || browser.msie ? 1 : -1;
                return isScrollLeft ^ !isScrollReverted ? 0 : scrollSign * (this._$tagsContainer.get(0).scrollWidth - this._$tagsContainer.outerWidth())
            },
            _getFocusedTagPosition: function(direction) {
                var rtlEnabled = this.option("rtlEnabled"),
                    isScrollLeft = "next" === direction ^ rtlEnabled,
                    scrollOffset = Math.floor(this._$focusedTag.position().left),
                    scrollLeft = this._$tagsContainer.scrollLeft();
                if (isScrollLeft) {
                    scrollOffset += this._$focusedTag.outerWidth(true) - this._$tagsContainer.outerWidth()
                }
                if (isScrollLeft ^ scrollOffset < 0) {
                    var scrollCorrection = rtlEnabled && browser.msie ? -1 : 1;
                    scrollLeft += scrollOffset * scrollCorrection
                }
                return scrollLeft
            },
            _setNextValue: $.noop,
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    values: {
                        since: "16.1",
                        alias: "value"
                    }
                })
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: [],
                    showDropButton: false,
                    tagTemplate: "tag",
                    selectAllText: messageLocalization.format("dxList-selectAll"),
                    hideSelectedItems: false,
                    selectedItems: [],
                    onSelectAllValueChanged: null,
                    multiline: true
                })
            },
            _init: function() {
                this.callBase();
                this._setListDataSourceFilter();
                this._selectedItems = [];
                this._initSelectAllValueChangedAction()
            },
            _render: function() {
                this.element().addClass(TAGBOX_CLASS).toggleClass(TAGBOX_ONLY_SELECT_CLASS, !(this.option("searchEnabled") || this.option("acceptCustomValue"))).toggleClass(TAGBOX_SINGLE_LINE_CLASS, !this.option("multiline"));
                this._toggleRTLDirection(this.option("rtlEnabled"));
                this._initTagTemplate();
                this.callBase();
                this._renderTagRemoveAction();
                this._renderSingleLineScroll();
                this._scrollContainer("start")
            },
            _initTagTemplate: function() {
                this._tagTemplate = this._getTemplateByOption("tagTemplate")
            },
            _renderTagRemoveAction: function() {
                var tagRemoveAction = this._createAction($.proxy(this._removeTagHandler, this));
                var eventName = eventUtils.addNamespace(clickEvent.name, "dxTagBoxTagRemove");
                this.element().find(".dx-texteditor-container").off(eventName).on(eventName, "." + TAGBOX_TAG_REMOVE_BUTTON_CLASS, function(e) {
                    tagRemoveAction({
                        jQueryEvent: e
                    })
                });
                this._renderTypingEvent()
            },
            _renderSingleLineScroll: function() {
                var mouseWheelEvent = eventUtils.addNamespace("dxmousewheel", this.NAME),
                    $element = this.element(),
                    isMultiline = this.option("multiline");
                $element.off(mouseWheelEvent);
                if ("desktop" !== devices.real().deviceType) {
                    this._$tagsContainer && this._$tagsContainer.css("overflow-x", isMultiline ? "" : "auto");
                    return
                }
                if (isMultiline) {
                    return
                }
                $element.on(mouseWheelEvent, $.proxy(this._tagContainerMouseWheelHandler, this))
            },
            _tagContainerMouseWheelHandler: function(e) {
                var scrollLeft = this._$tagsContainer.scrollLeft();
                this._$tagsContainer.scrollLeft(scrollLeft + e.delta * TAGBOX_MOUSE_WHEEL_DELTA_MULTIPLIER);
                return false
            },
            _renderTypingEvent: function() {
                this._input().on(eventUtils.addNamespace("keydown", this.NAME), $.proxy(function(e) {
                    var keyCode = e.which || e.keyCode;
                    if (!this._isControlKey(keyCode) && this._isEditable()) {
                        this._clearTagFocus()
                    }
                }, this))
            },
            _popupWrapperClass: function() {
                return this.callBase() + " " + TAGBOX_POPUP_WRAPPER_CLASS
            },
            _renderInputValueImpl: function() {
                this._renderMultiSelect()
            },
            _clearTextValue: function() {
                this._input().val("")
            },
            _focusInHandler: function(e) {
                this.callBase(e);
                this._scrollContainer("end")
            },
            _focusOutHandler: function(e) {
                if (this.option("opened") && "useButtons" === this.option("applyValueMode")) {
                    return
                }
                this.callBase(e);
                this._clearTextValue();
                this._clearTagFocus();
                this._scrollContainer("start")
            },
            _getFirstPopupElement: function() {
                return this.option("showSelectionControls") ? this._popup._wrapper().find("." + LIST_SELECT_ALL_CHECKBOX_CLASS) : this.callBase()
            },
            _suppressingSelectionChanged: function(callback) {
                this._setListOption("onSelectionChanged", $.noop);
                callback.call(this);
                this._setListOption("onSelectionChanged", this._getSelectionChangeHandler())
            },
            _initSelectAllValueChangedAction: function() {
                this._selectAllValueChangeAction = this._createActionByOption("onSelectAllValueChanged")
            },
            _renderList: function() {
                this.callBase();
                if (!this.option("showSelectionControls")) {
                    return
                }
                var $selectAllCheckBox = this._list.element().find("." + LIST_SELECT_ALL_CHECKBOX_CLASS),
                    selectAllCheckbox = $selectAllCheckBox.dxCheckBox("instance");
                selectAllCheckbox.registerKeyHandler("tab", $.proxy(this._popupElementTabHandler, this));
                selectAllCheckbox.registerKeyHandler("escape", $.proxy(this._popupElementEscHandler, this))
            },
            _listConfig: function() {
                var that = this,
                    selectionMode = this.option("showSelectionControls") ? "all" : "multiple";
                return $.extend(this.callBase(), {
                    selectionMode: selectionMode,
                    selectAllText: this.option("selectAllText"),
                    onSelectAllValueChanged: function(e) {
                        that._selectAllValueChangeAction({
                            value: e.value
                        })
                    },
                    selectedItems: this._selectedItems,
                    onFocusedItemChanged: null
                })
            },
            _renderMultiSelect: function() {
                this._$tagsContainer = this.element().find(".dx-texteditor-container").addClass(TAGBOX_TAG_CONTAINER_CLASS).addClass(NATIVE_CLICK_CLASS);
                this._renderInputSize();
                this._clearFilter();
                this._renderTags();
                this._popup && this._popup.repaint()
            },
            _listItemClickHandler: function(e) {
                this._clearTextValue();
                if ("useButtons" === this.option("applyValueMode")) {
                    return
                }
                this.callBase(e)
            },
            _renderInputSize: function() {
                var $input = this._input();
                $input.prop("size", $input.val() ? $input.val().length + 2 : 1)
            },
            _renderInputSubstitution: function() {
                this.callBase();
                this._renderInputSize()
            },
            _getValue: function() {
                return this.option("value") || []
            },
            _renderTags: function() {
                this._cleanTags();
                var $input = this._input();
                var itemLoadDeferreds = $.map(this._getValue(), $.proxy(function(value) {
                    return this._renderTag(value, $input)
                }, this));
                $.when.apply($, itemLoadDeferreds).done($.proxy(function() {
                    this._renderInputAddons();
                    this._scrollContainer("end")
                }, this));
                this._renderEmptyState();
                if (!this._preserveFocusedTag) {
                    this._clearTagFocus()
                }
                this.option("selectedItems", this._selectedItems.slice())
            },
            _renderEmptyState: function() {
                var isEmpty = !(this._getValue().length || this._selectedItems.length || this._searchValue());
                this._toggleEmptiness(isEmpty);
                this._renderDisplayText()
            },
            _renderDisplayText: function() {
                this._renderInputSize()
            },
            _cleanTags: function() {
                var $tags = this._tagElements(),
                    values = this._getValue();
                $.each($tags, function(_, tag) {
                    var $tag = $(tag),
                        index = $.inArray($tag.data(TAGBOX_TAG_DATA_KEY), values);
                    if (index < 0) {
                        $tag.remove()
                    }
                });
                this._cleanSelectedItems()
            },
            _cleanSelectedItems: function() {
                if (this.option("fieldTemplate")) {
                    this._selectedItems = [];
                    return
                }
                var values = this._getValue(),
                    selectedItemsCount = this._selectedItems.length;
                for (var index = 0; index < selectedItemsCount; index++) {
                    var selectedItem = this._selectedItems[index],
                        value = this._valueGetter(selectedItem);
                    if ($.inArray(value, values) < 0) {
                        this._selectedItems.splice(index, 1);
                        index--;
                        selectedItemsCount--
                    }
                }
            },
            _tagElements: function() {
                return this.element().find("." + TAGBOX_TAG_CLASS)
            },
            _getDefaultTagTemplate: function() {
                if (!this._defaultTagTemplate) {
                    this._defaultTagTemplate = this.option("templateProvider").getTemplates(this).tag
                }
                return this._defaultTagTemplate
            },
            _renderTag: function(value, $input) {
                if (this._isTagRendered(value)) {
                    return $.Deferred().resolve()
                }
                var $tag = $("<div>").addClass(TAGBOX_TAG_CLASS).data(TAGBOX_TAG_DATA_KEY, value).insertBefore($input);
                return this._loadItem(value).always($.proxy(function(item) {
                    item = commonUtils.isDefined(item) ? item : value;
                    this._selectedItems.push(item);
                    if (this._displayGetterExpr() && this._tagTemplate === this._getDefaultTagTemplate()) {
                        item = this._displayGetter(item)
                    }
                    this._tagTemplate.render({
                        model: item,
                        container: $tag
                    })
                }, this))
            },
            _isTagRendered: function(value) {
                var $tags = this._tagElements();
                var result = false;
                $.each($tags, function(_, tag) {
                    var $tag = $(tag);
                    if (value === $tag.data(TAGBOX_TAG_DATA_KEY)) {
                        result = true;
                        return false
                    }
                });
                return result
            },
            _toggleEmptinessEventHandler: function() {
                this._toggleEmptiness(!this._getValue().length && !this._searchValue().length)
            },
            _customItemAddedHandler: function(e) {
                this.callBase(e);
                this._input().val("")
            },
            _removeTagHandler: function(args) {
                var e = args.jQueryEvent;
                e.stopPropagation();
                var $tag = $(e.target).closest("." + TAGBOX_TAG_CLASS);
                this._removeTagElement($tag)
            },
            _removeTagElement: function($tag) {
                var itemValue = $tag.data(TAGBOX_TAG_DATA_KEY);
                this._removeTagWithUpdate(itemValue)
            },
            _removeTagWithUpdate: function(itemValue) {
                var value = this._getValue().slice();
                this._removeTag(value, itemValue);
                this.option("value", value);
                if (0 === value.length) {
                    this._clearTagFocus()
                }
            },
            _getCurrentValue: function() {
                return this._lastValue()
            },
            _selectionChangeHandler: function(e) {
                if ("useButtons" === this.option("applyValueMode")) {
                    return
                }
                var value = this._getValue().slice();
                $.each(e.removedItems || [], $.proxy(function(_, removedItem) {
                    this._removeTag(value, this._valueGetter(removedItem))
                }, this));
                $.each(e.addedItems || [], $.proxy(function(_, addedItem) {
                    this._addTag(value, this._valueGetter(addedItem))
                }, this));
                this._updateWidgetHeight();
                this.option("value", value)
            },
            _removeTag: function(value, item) {
                var index = this._valueIndex(item, value);
                if (index >= 0) {
                    value.splice(index, 1)
                }
            },
            _addTag: function(value, item) {
                var index = this._valueIndex(item);
                if (index < 0) {
                    value.push(item)
                }
            },
            _fieldRenderData: function() {
                return this._selectedItems.slice()
            },
            _setValue: function(value) {
                if (null === value) {
                    return
                }
                var valueIndex = this._valueIndex(value),
                    values = this._getValue().slice();
                if (valueIndex >= 0) {
                    values.splice(valueIndex, 1)
                } else {
                    values.push(value)
                }
                this.option("value", values)
            },
            _isSelectedValue: function(value) {
                return this._valueIndex(value) > -1
            },
            _valueIndex: function(value, values) {
                values = values || this._getValue();
                var result = -1;
                $.each(values, $.proxy(function(index, selectedValue) {
                    if (this._isValueEquals(value, selectedValue)) {
                        result = index;
                        return false
                    }
                }, this));
                return result
            },
            _lastValue: function() {
                return this._getValue().slice(-1).pop() || null
            },
            _valueChangeEventHandler: $.noop,
            _shouldRenderSearchEvent: function() {
                return this.option("searchEnabled") || this.option("acceptCustomValue")
            },
            _searchHandler: function(e) {
                if (this.option("searchEnabled") && !!e && !this._isTagRemoved) {
                    this.callBase(e)
                }
                this._updateWidgetHeight();
                delete this._isTagRemoved
            },
            _updateWidgetHeight: function() {
                var element = this.element(),
                    originalHeight = element.height();
                this._renderInputSize();
                var currentHeight = element.height();
                if (this._popup && this.option("opened") && this._isEditable() && currentHeight !== originalHeight) {
                    this._popup.repaint()
                }
            },
            _refreshSelected: function() {
                this._list && this._suppressingSelectionChanged(function() {
                    this._setListOption("selectedItems", this._selectedItems.slice());
                    this.callBase()
                })
            },
            _resetListDataSourceFilter: function() {
                var dataSource = this._getDataSource();
                if (!dataSource) {
                    return
                }
                dataSource.filter(null);
                dataSource.reload()
            },
            _setListDataSourceFilter: function() {
                if (!this.option("hideSelectedItems") || !this._list) {
                    return
                }
                var dataSource = this._getDataSource();
                if (!dataSource) {
                    return
                }
                dataSource.filter($.proxy(this._dataSourceFilter, this));
                dataSource.reload()
            },
            _dataSourceFilter: function(itemData) {
                var itemValue = this._valueGetter(itemData),
                    result = true;
                $.each(this._getValue(), $.proxy(function(index, value) {
                    if (this._isValueEquals(value, itemValue)) {
                        result = false;
                        return false
                    }
                }, this));
                return result
            },
            _applyButtonHandler: function() {
                this.option("value", this._getListValues());
                this._clearTextValue();
                this.callBase()
            },
            _getListValues: function() {
                if (!this._list) {
                    return []
                }
                var that = this,
                    selectedItems = this._list.option("selectedItems"),
                    result = [];
                $.each(selectedItems, function(index, item) {
                    result[index] = that._valueGetter(item)
                });
                return result
            },
            _renderOpenedState: function() {
                this.callBase();
                if (this.option(false)) {
                    this._refreshSelected()
                }
            },
            _clean: function() {
                this.callBase();
                delete this._defaultTagTemplate;
                delete this._tagTemplate
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "onSelectAllValueChanged":
                        this._initSelectAllValueChangedAction();
                        break;
                    case "hideSelectedItems":
                        if (args.value) {
                            this._setListDataSourceFilter()
                        } else {
                            this._resetListDataSourceFilter()
                        }
                        break;
                    case "displayExpr":
                        this.callBase(args);
                        this._invalidate();
                        break;
                    case "tagTemplate":
                        this._initTagTemplate();
                        this._invalidate();
                        break;
                    case "selectAllText":
                        this._setListOption("selectAllText", this.option("selectAllText"));
                        break;
                    case "value":
                        this.callBase(args);
                        this._setListDataSourceFilter();
                        break;
                    case "selectedItem":
                        break;
                    case "selectedItems":
                        var addedItems = arrayUtils.removeDuplicates(args.value, args.previousValue),
                            removedItems = arrayUtils.removeDuplicates(args.previousValue, args.value);
                        this._selectionChangedAction({
                            addedItems: addedItems,
                            removedItems: removedItems
                        });
                        break;
                    case "multiline":
                        this.element().toggleClass(TAGBOX_SINGLE_LINE_CLASS, !args.value);
                        this._renderSingleLineScroll();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            reset: function() {
                this.option("value", []);
                this._clearFilter();
                this._clearSelectedItem()
            }
        });
        registerComponent("dxTagBox", TagBox);
        module.exports = TagBox
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/text_area.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../events/pointer */ 65),
            TextBox = __webpack_require__( /*! ./text_box */ 206);
        var TEXTAREA_CLASS = "dx-textarea",
            TEXTEDITOR_INPUT_CLASS = "dx-texteditor-input";
        var TextArea = TextBox.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    spellcheck: true,
                    minHeight: void 0,
                    maxHeight: void 0,
                    autoResizeEnabled: false
                })
            },
            _render: function() {
                this.callBase();
                this.element().addClass(TEXTAREA_CLASS);
                this.setAria("multiline", "true");
                this._updateInputHeight()
            },
            _renderInput: function() {
                this.callBase();
                this._renderScrollHandler()
            },
            _createInput: function() {
                return $("<textarea>").addClass(TEXTEDITOR_INPUT_CLASS).attr(this.option("attr"))
            },
            _renderScrollHandler: function() {
                var $input = this._input(),
                    eventY = 0;
                $input.on(eventUtils.addNamespace(pointerEvents.down, this.NAME), function(e) {
                    eventY = eventUtils.eventData(e).y
                });
                $input.on(eventUtils.addNamespace(pointerEvents.move, this.NAME), function(e) {
                    var scrollTopPos = $input.scrollTop(),
                        scrollBottomPos = $input.prop("scrollHeight") - $input.prop("clientHeight") - scrollTopPos;
                    if (0 === scrollTopPos && 0 === scrollBottomPos) {
                        return
                    }
                    var currentEventY = eventUtils.eventData(e).y;
                    var isScrollFromTop = 0 === scrollTopPos && eventY >= currentEventY,
                        isScrollFromBottom = 0 === scrollBottomPos && eventY <= currentEventY,
                        isScrollFromMiddle = scrollTopPos > 0 && scrollBottomPos > 0;
                    if (isScrollFromTop || isScrollFromBottom || isScrollFromMiddle) {
                        e.isScrollingEvent = true;
                        e.stopPropagation()
                    }
                    eventY = currentEventY
                })
            },
            _renderDimensions: function() {
                var width = this.option("width"),
                    height = this.option("height"),
                    minHeight = this.option("minHeight"),
                    maxHeight = this.option("maxHeight"),
                    $element = this.element();
                $element.css({
                    "min-height": void 0 !== minHeight ? minHeight : "",
                    "max-height": void 0 !== maxHeight ? maxHeight : ""
                });
                $element.outerWidth(width);
                $element.outerHeight(height)
            },
            _resetDimensions: function() {
                this.element().css({
                    height: "",
                    "min-height": "",
                    "max-height": ""
                })
            },
            _renderEvents: function() {
                if (this.option("autoResizeEnabled")) {
                    this._input().on(eventUtils.addNamespace("input paste", this.NAME), $.proxy(this._updateInputHeight, this))
                }
                this.callBase()
            },
            _refreshEvents: function() {
                this._input().off(eventUtils.addNamespace("input paste", this.NAME));
                this.callBase()
            },
            _updateInputHeight: function() {
                var $input = this._input();
                if (!this.option("autoResizeEnabled") || void 0 !== this.option("height")) {
                    $input.css("height", "");
                    return
                }
                this._resetDimensions();
                $input.css("height", 0);
                var heightDifference = this._$element.outerHeight() - $input.outerHeight();
                this._renderDimensions();
                var minHeight = this.option("minHeight"),
                    maxHeight = this.option("maxHeight"),
                    inputHeight = $input[0].scrollHeight;
                if (void 0 !== minHeight) {
                    inputHeight = Math.max(inputHeight, minHeight - heightDifference)
                }
                if (void 0 !== maxHeight) {
                    inputHeight = Math.min(inputHeight, maxHeight - heightDifference)
                }
                $input.css("height", inputHeight)
            },
            _renderInputType: $.noop,
            _visibilityChanged: function(visible) {
                if (visible) {
                    this.repaint()
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "autoResizeEnabled":
                        this._refreshEvents();
                        this._updateInputHeight();
                        break;
                    case "value":
                    case "height":
                        this.callBase(args);
                        this._updateInputHeight();
                        break;
                    case "minHeight":
                    case "maxHeight":
                        this._renderDimensions();
                        this._updateInputHeight();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxTextArea", TextArea);
        module.exports = TextArea
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/tile_view.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            inflector = __webpack_require__( /*! ../core/utils/inflector */ 49),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            ScrollModule = __webpack_require__( /*! ./scroll_view/ui.scroll_view */ 227),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151);
        var TILEVIEW_CLASS = "dx-tileview",
            TILEVIEW_CONTAINER_CLASS = "dx-tileview-wrapper",
            TILEVIEW_ITEM_CLASS = "dx-tile",
            TILEVIEW_ITEM_SELECTOR = "." + TILEVIEW_ITEM_CLASS,
            TILEVIEW_ITEM_DATA_KEY = "dxTileData";
        var CONFIGS = {
            horizontal: {
                itemMainRatio: "widthRatio",
                itemCrossRatio: "heightRatio",
                baseItemMainDimension: "baseItemWidth",
                baseItemCrossDimension: "baseItemHeight",
                mainDimension: "width",
                crossDimension: "height",
                mainPosition: "left",
                crossPosition: "top"
            },
            vertical: {
                itemMainRatio: "heightRatio",
                itemCrossRatio: "widthRatio",
                baseItemMainDimension: "baseItemHeight",
                baseItemCrossDimension: "baseItemWidth",
                mainDimension: "height",
                crossDimension: "width",
                mainPosition: "top",
                crossPosition: "left"
            }
        };
        var TileView = CollectionWidget.inherit({
            _activeStateUnit: TILEVIEW_ITEM_SELECTOR,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    items: null,
                    direction: "horizontal",
                    hoverStateEnabled: true,
                    showScrollbar: false,
                    height: 500,
                    baseItemWidth: 100,
                    baseItemHeight: 100,
                    itemMargin: 20,
                    activeStateEnabled: true,
                    indicateLoading: true
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _itemClass: function() {
                return TILEVIEW_ITEM_CLASS
            },
            _itemDataKey: function() {
                return TILEVIEW_ITEM_DATA_KEY
            },
            _itemContainer: function() {
                return this._$container
            },
            _init: function() {
                this.callBase();
                this.element().addClass(TILEVIEW_CLASS);
                this._initScrollView()
            },
            _dataSourceLoadingChangedHandler: function(isLoading) {
                var scrollView = this._scrollView;
                if (!scrollView) {
                    return
                }
                if (isLoading && this.option("indicateLoading")) {
                    scrollView.startLoading()
                } else {
                    scrollView.finishLoading()
                }
            },
            _hideLoadingIfLoadIndicationOff: function() {
                if (!this.option("indicateLoading")) {
                    this._dataSourceLoadingChangedHandler(false)
                }
            },
            _initScrollView: function() {
                this._scrollView = this._createComponent(this.element(), ScrollModule.ScrollView, {
                    direction: this.option("direction"),
                    scrollByContent: true,
                    useKeyboard: false,
                    showScrollbar: this.option("showScrollbar")
                });
                this._$container = this._scrollView.content();
                this._$container.addClass(TILEVIEW_CONTAINER_CLASS);
                this._scrollView.option("onUpdated", $.proxy(this._renderGeometry, this))
            },
            _render: function() {
                this.callBase();
                this._cellsPerDimension = 1;
                this._renderGeometry();
                this._updateScrollView();
                this._fireContentReadyAction()
            },
            _renderContent: function() {
                this._renderContentImpl()
            },
            _updateScrollView: function() {
                this._scrollView.option("direction", this.option("direction"));
                this._scrollView.update();
                this._indicateLoadingIfAlreadyStarted()
            },
            _indicateLoadingIfAlreadyStarted: function() {
                if (this._isDataSourceLoading()) {
                    this._dataSourceLoadingChangedHandler(true)
                }
            },
            _renderGeometry: function() {
                this._config = CONFIGS[this.option("direction")];
                var items = this.option("items") || [],
                    config = this._config,
                    itemMargin = this.option("itemMargin"),
                    maxItemCrossRatio = Math.max.apply(Math, $.map(items || [], function(item) {
                        return Math.round(item[config.itemCrossRatio] || 1)
                    }));
                this._cellsPerDimension = Math.floor(this.element()[config.crossDimension]() / (this.option(config.baseItemCrossDimension) + itemMargin));
                this._cellsPerDimension = Math.max(this._cellsPerDimension, maxItemCrossRatio);
                this._cells = [];
                this._cells.push(new Array(this._cellsPerDimension));
                this._arrangeItems(items);
                this._$container[config.mainDimension](this._cells.length * this.option(config.baseItemMainDimension) + (this._cells.length + 1) * itemMargin)
            },
            _arrangeItems: function(items) {
                var config = this._config,
                    itemMainRatio = config.itemMainRatio,
                    itemCrossRatio = config.itemCrossRatio,
                    mainPosition = config.mainPosition;
                this._itemsPositions = [];
                $.each(items, $.proxy(function(index, item) {
                    var currentItem = {};
                    currentItem[itemMainRatio] = item[itemMainRatio] || 1;
                    currentItem[itemCrossRatio] = item[itemCrossRatio] || 1;
                    currentItem.index = index;
                    currentItem[itemMainRatio] = currentItem[itemMainRatio] <= 0 ? 0 : Math.round(currentItem[config.itemMainRatio]);
                    currentItem[itemCrossRatio] = currentItem[itemCrossRatio] <= 0 ? 0 : Math.round(currentItem[config.itemCrossRatio]);
                    var itemPosition = this._getItemPosition(currentItem);
                    if (itemPosition[mainPosition] === -1) {
                        itemPosition[mainPosition] = this._cells.push(new Array(this._cellsPerDimension)) - 1
                    }
                    this._occupyCells(currentItem, itemPosition);
                    this._arrangeItem(currentItem, itemPosition);
                    this._itemsPositions.push(itemPosition)
                }, this))
            },
            _getItemPosition: function(item) {
                var config = this._config,
                    mainPosition = config.mainPosition,
                    crossPosition = config.crossPosition;
                var position = {};
                position[mainPosition] = -1;
                position[crossPosition] = 0;
                for (var main = 0; main < this._cells.length; main++) {
                    for (var cross = 0; cross < this._cellsPerDimension; cross++) {
                        if (this._itemFit(main, cross, item)) {
                            position[mainPosition] = main;
                            position[crossPosition] = cross;
                            break
                        }
                    }
                    if (position[mainPosition] > -1) {
                        break
                    }
                }
                return position
            },
            _itemFit: function(mainPosition, crossPosition, item) {
                var result = true,
                    config = this._config,
                    itemRatioMain = item[config.itemMainRatio],
                    itemRatioCross = item[config.itemCrossRatio];
                if (crossPosition + itemRatioCross > this._cellsPerDimension) {
                    return false
                }
                for (var main = mainPosition; main < mainPosition + itemRatioMain; main++) {
                    for (var cross = crossPosition; cross < crossPosition + itemRatioCross; cross++) {
                        if (this._cells.length - 1 < main) {
                            this._cells.push(new Array(this._cellsPerDimension))
                        } else {
                            if (void 0 !== this._cells[main][cross]) {
                                result = false;
                                break
                            }
                        }
                    }
                }
                return result
            },
            _occupyCells: function(item, itemPosition) {
                var config = this._config,
                    itemPositionMain = itemPosition[config.mainPosition],
                    itemPositionCross = itemPosition[config.crossPosition],
                    itemRatioMain = item[config.itemMainRatio],
                    itemRatioCross = item[config.itemCrossRatio];
                for (var main = itemPositionMain; main < itemPositionMain + itemRatioMain; main++) {
                    for (var cross = itemPositionCross; cross < itemPositionCross + itemRatioCross; cross++) {
                        this._cells[main][cross] = item.index
                    }
                }
            },
            _arrangeItem: function(item, itemPosition) {
                var config = this._config,
                    itemPositionMain = itemPosition[config.mainPosition],
                    itemPositionCross = itemPosition[config.crossPosition],
                    itemRatioMain = item[config.itemMainRatio],
                    itemRatioCross = item[config.itemCrossRatio],
                    baseItemCross = this.option(config.baseItemCrossDimension),
                    baseItemMain = this.option(config.baseItemMainDimension),
                    itemMargin = this.option("itemMargin");
                var cssProps = {
                    display: itemRatioMain <= 0 || itemRatioCross <= 0 ? "none" : ""
                };
                cssProps[config.mainDimension] = itemRatioMain * baseItemMain + (itemRatioMain - 1) * itemMargin;
                cssProps[config.crossDimension] = itemRatioCross * baseItemCross + (itemRatioCross - 1) * itemMargin;
                cssProps[config.mainPosition] = itemPositionMain * baseItemMain + (itemPositionMain + 1) * itemMargin;
                cssProps[config.crossPosition] = itemPositionCross * baseItemCross + (itemPositionCross + 1) * itemMargin;
                if (this.option("rtlEnabled")) {
                    var offsetCorrection = this._$container.width(),
                        baseItemWidth = this.option("baseItemWidth"),
                        itemPositionX = itemPosition.left,
                        offsetPosition = itemPositionX * baseItemWidth,
                        itemBaseOffset = baseItemWidth + itemMargin,
                        itemWidth = itemBaseOffset * item.widthRatio,
                        subitemMargins = itemPositionX * itemMargin;
                    cssProps.left = offsetCorrection - (offsetPosition + itemWidth + subitemMargins)
                }
                this._itemElements().eq(item.index).css(cssProps)
            },
            _moveFocus: function(location) {
                var FOCUS_UP = "up",
                    FOCUS_DOWN = "down",
                    FOCUS_LEFT = this.option("rtlEnabled") ? "right" : "left",
                    FOCUS_RIGHT = this.option("rtlEnabled") ? "left" : "right",
                    FOCUS_PAGE_UP = "pageup",
                    FOCUS_PAGE_DOWN = "pagedown";
                var horizontalDirection = "horizontal" === this.option("direction"),
                    cells = this._cells,
                    index = this.option("focusedElement").index(),
                    targetCol = this._itemsPositions[index].left,
                    targetRow = this._itemsPositions[index].top;
                var colCount = (horizontalDirection ? cells : cells[0]).length;
                var rowCount = (horizontalDirection ? cells[0] : cells).length;
                var getCell = function(col, row) {
                    if (horizontalDirection) {
                        return cells[col][row]
                    }
                    return cells[row][col]
                };
                switch (location) {
                    case FOCUS_PAGE_UP:
                    case FOCUS_UP:
                        while (targetRow > 0 && index === getCell(targetCol, targetRow)) {
                            targetRow--
                        }
                        if (targetRow < 0) {
                            targetRow = 0
                        }
                        break;
                    case FOCUS_PAGE_DOWN:
                    case FOCUS_DOWN:
                        while (targetRow < rowCount && index === getCell(targetCol, targetRow)) {
                            targetRow++
                        }
                        if (targetRow === rowCount) {
                            targetRow = rowCount - 1
                        }
                        break;
                    case FOCUS_RIGHT:
                        while (targetCol < colCount && index === getCell(targetCol, targetRow)) {
                            targetCol++
                        }
                        if (targetCol === colCount) {
                            targetCol = colCount - 1
                        }
                        break;
                    case FOCUS_LEFT:
                        while (targetCol >= 0 && index === getCell(targetCol, targetRow)) {
                            targetCol--
                        }
                        if (targetCol < 0) {
                            targetCol = 0
                        }
                        break;
                    default:
                        this.callBase.apply(this, arguments);
                        return
                }
                var newTargetIndex = getCell(targetCol, targetRow);
                if (!commonUtils.isDefined(newTargetIndex)) {
                    return
                }
                var $newTarget = this._itemElements().eq(newTargetIndex);
                this.option("focusedElement", $newTarget);
                this._scrollToItem($newTarget)
            },
            _scrollToItem: function($itemElement) {
                if (!$itemElement.length) {
                    return
                }
                var config = this._config,
                    outerMainProp = "outer" + inflector.captionize(config.mainDimension),
                    itemMargin = this.option("itemMargin"),
                    itemPosition = $itemElement.position()[config.mainPosition],
                    itemDimension = $itemElement[outerMainProp](),
                    itemTail = itemPosition + itemDimension,
                    scrollPosition = this.scrollPosition(),
                    clientWidth = this.element()[outerMainProp]();
                if (scrollPosition <= itemPosition && itemTail <= scrollPosition + clientWidth) {
                    return
                }
                if (scrollPosition > itemPosition) {
                    this._scrollView.scrollTo(itemPosition - itemMargin)
                } else {
                    this._scrollView.scrollTo(itemPosition + itemDimension - clientWidth + itemMargin)
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "showScrollbar":
                        this._initScrollView();
                        break;
                    case "disabled":
                        this._scrollView.option("disabled", args.value);
                        this.callBase(args);
                        break;
                    case "baseItemWidth":
                    case "baseItemHeight":
                    case "itemMargin":
                        this._renderGeometry();
                        break;
                    case "width":
                    case "height":
                        this.callBase(args);
                        this._renderGeometry();
                        this._updateScrollView();
                        break;
                    case "direction":
                        this._renderGeometry();
                        this._updateScrollView();
                        break;
                    case "indicateLoading":
                        this._hideLoadingIfLoadIndicationOff();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            scrollPosition: function() {
                return this._scrollView.scrollOffset()[this._config.mainPosition]
            }
        });
        registerComponent("dxTileView", TileView);
        module.exports = TileView
    },
    /*!*******************************!*\
      !*** ./Scripts/ui/toolbar.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            themes = __webpack_require__( /*! ./themes */ 143),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            ActionSheetStrategy = __webpack_require__( /*! ./toolbar/ui.toolbar.strategy.action_sheet */ 313),
            DropDownMenuStrategy = __webpack_require__( /*! ./toolbar/ui.toolbar.strategy.drop_down_menu */ 315),
            ListBottomStrategy = __webpack_require__( /*! ./toolbar/ui.toolbar.strategy.list_bottom */ 317),
            ListTopStrategy = __webpack_require__( /*! ./toolbar/ui.toolbar.strategy.list_top */ 319),
            ToolbarBase = __webpack_require__( /*! ./toolbar/ui.toolbar.base */ 198);
        var STRATEGIES = {
            actionSheet: ActionSheetStrategy,
            dropDownMenu: DropDownMenuStrategy,
            listBottom: ListBottomStrategy,
            listTop: ListTopStrategy
        };
        var TOOLBAR_AUTO_HIDE_ITEM_CLASS = "dx-toolbar-item-auto-hide",
            TOOLBAR_AUTO_HIDE_TEXT_CLASS = "dx-toolbar-text-auto-hide",
            TOOLBAR_HIDDEN_ITEM = "dx-toolbar-item-invisible";
        var Toolbar = ToolbarBase.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    menuItemTemplate: "menuItem",
                    submenuType: "dropDownMenu"
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        return /ios7.*/.test(themes.current())
                    },
                    options: {
                        submenuType: "actionSheet"
                    }
                }, {
                    device: function() {
                        return /android5.*/.test(themes.current())
                    },
                    options: {
                        submenuType: "dropDownMenu"
                    }
                }, {
                    device: function() {
                        return /win8.*/.test(themes.current())
                    },
                    options: {
                        submenuType: "listBottom"
                    }
                }, {
                    device: function() {
                        return /win10.*/.test(themes.current())
                    },
                    options: {
                        submenuType: "listTop"
                    }
                }])
            },
            _dimensionChanged: function() {
                this._menuStrategy.toggleMenuVisibility(false, true);
                this.callBase();
                this._menuStrategy.renderMenuItems()
            },
            _render: function() {
                this.callBase();
                this._menuStrategy.renderMenuItems()
            },
            _renderContentImpl: function() {
                this.callBase();
                this._hideOverflowItems();
                this._renderMenu()
            },
            _renderItem: function(index, item, itemContainer, $after) {
                var itemElement = this.callBase(index, item, itemContainer, $after);
                if ("auto" === item.locateInMenu) {
                    itemElement.addClass(TOOLBAR_AUTO_HIDE_ITEM_CLASS)
                }
                if ("dxButton" === item.widget && "inMenu" === item.showText) {
                    itemElement.toggleClass(TOOLBAR_AUTO_HIDE_TEXT_CLASS)
                }
                return itemElement
            },
            _hideOverflowItems: function(elementWidth) {
                var overflowItems = this.element().find("." + TOOLBAR_AUTO_HIDE_ITEM_CLASS);
                if (!overflowItems.length) {
                    return
                }
                elementWidth = elementWidth || this.element().width();
                $(overflowItems).removeClass(TOOLBAR_HIDDEN_ITEM);
                var beforeWidth = this._$beforeSection.outerWidth(),
                    centerWidth = this._$centerSection.outerWidth(),
                    afterWidth = this._$afterSection.outerWidth(),
                    itemsWidth = beforeWidth + centerWidth + afterWidth;
                while (overflowItems.length && elementWidth < itemsWidth) {
                    var $item = overflowItems.eq(-1);
                    itemsWidth -= $item.outerWidth();
                    $item.addClass(TOOLBAR_HIDDEN_ITEM);
                    overflowItems.splice(-1, 1)
                }
            },
            _getMenuItems: function() {
                var that = this;
                var menuItems = $.grep(this.option("items") || [], function(item) {
                    return that._isMenuItem(item)
                });
                var $hiddenItems = this._itemContainer().children("." + TOOLBAR_AUTO_HIDE_ITEM_CLASS + "." + TOOLBAR_HIDDEN_ITEM).not(".dx-state-invisible");
                this._restoreItems = this._restoreItems || [];
                var overflowItems = $.map($hiddenItems, function(item) {
                    var itemData = that._getItemData(item),
                        $itemContainer = $(item).children(),
                        $itemMarkup = $itemContainer.children();
                    return $.extend({
                        menuItemTemplate: function() {
                            that._restoreItems.push({
                                container: $itemContainer,
                                item: $itemMarkup
                            });
                            var $container = $("<div>").addClass(TOOLBAR_AUTO_HIDE_ITEM_CLASS);
                            return $container.append($itemMarkup)
                        }
                    }, itemData)
                });
                return $.merge(overflowItems, menuItems)
            },
            _getToolbarItems: function() {
                var that = this;
                return $.grep(this.option("items") || [], function(item) {
                    return !that._isMenuItem(item)
                })
            },
            _renderMenu: function() {
                this._renderMenuStrategy();
                this._menuStrategy.render()
            },
            _renderMenuStrategy: function() {
                var strategyName = this.option("submenuType");
                if (this._requireDropDownStrategy()) {
                    strategyName = "dropDownMenu"
                }
                var strategy = STRATEGIES[strategyName];
                if (!(this._menuStrategy && this._menuStrategy.NAME === strategyName)) {
                    this._menuStrategy = new strategy(this)
                }
            },
            _requireDropDownStrategy: function() {
                var strategyName = this.option("submenuType");
                if (("listBottom" === strategyName || "listTop" === strategyName) && "topToolbar" === this.option("renderAs")) {
                    return true
                }
                var items = this.option("items") || [],
                    result = false;
                $.each(items, function(index, item) {
                    if ("auto" === item.locateInMenu) {
                        result = true
                    } else {
                        if ("always" === item.locateInMenu && item.widget) {
                            result = true
                        }
                    }
                });
                return result
            },
            _arrangeItems: function() {
                if (this.element().is(":hidden")) {
                    return
                }
                this._$centerSection.css({
                    margin: "0 auto",
                    "float": "none"
                });
                $.each(this._restoreItems || [], function(_, obj) {
                    $(obj.container).append(obj.item)
                });
                this._restoreItems = [];
                var elementWidth = this.element().width();
                this._hideOverflowItems(elementWidth);
                this.callBase(elementWidth)
            },
            _itemOptionChanged: function(item, property, value) {
                if (this._isMenuItem(item)) {
                    this._menuStrategy.renderMenuItems()
                } else {
                    if (this._isToolbarItem(item)) {
                        this.callBase(item, property, value)
                    } else {
                        this.callBase(item, property, value);
                        this._menuStrategy.renderMenuItems()
                    }
                }
            },
            _isMenuItem: function(itemData) {
                return "menu" === itemData.location || "always" === itemData.locateInMenu
            },
            _isToolbarItem: function(itemData) {
                return void 0 === itemData.location || "never" === itemData.locateInMenu
            },
            _optionChanged: function(args) {
                var name = args.name;
                var value = args.value;
                switch (name) {
                    case "submenuType":
                        this._invalidate();
                        break;
                    case "visible":
                        this.callBase.apply(this, arguments);
                        this._menuStrategy.handleToolbarVisibilityChange(value);
                        break;
                    case "menuItemTemplate":
                        this._changeMenuOption("itemTemplate", this._getTemplate(value));
                        break;
                    case "onItemClick":
                        this._changeMenuOption(name, value);
                        this.callBase.apply(this, arguments);
                        break;
                    default:
                        this.callBase.apply(this, arguments)
                }
            },
            _changeMenuOption: function(name, value) {
                this._menuStrategy.widgetOption(name, value)
            }
        });
        registerComponent("dxToolbar", Toolbar);
        module.exports = Toolbar
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.strategy.action_sheet.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ToolbarStrategy = __webpack_require__( /*! ./ui.toolbar.strategy */ 314),
            ActionSheet = __webpack_require__( /*! ../action_sheet */ 201);
        var ActionSheetStrategy = ToolbarStrategy.inherit({
            NAME: "actionSheet",
            _getMenuItemTemplate: function() {
                return this._toolbar._getTemplate("actionSheetItem")
            },
            render: function() {
                if (!this._hasVisibleMenuItems()) {
                    return
                }
                this.callBase()
            },
            _menuWidgetClass: function() {
                return ActionSheet
            },
            _menuContainer: function() {
                return this._toolbar.element()
            },
            _widgetOptions: function() {
                return $.extend({}, this.callBase(), {
                    target: this._$button,
                    showTitle: false
                })
            },
            _menuButtonOptions: function() {
                return $.extend({}, this.callBase(), {
                    icon: "overflow"
                })
            },
            _toggleMenu: function(visible, animate) {
                this.callBase.apply(this, arguments);
                this._menu.toggle(this._menuShown);
                this._menuShown = false
            }
        });
        module.exports = ActionSheetStrategy
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.strategy.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../../core/errors */ 17),
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            Class = __webpack_require__( /*! ../../core/class */ 20),
            Button = __webpack_require__( /*! ../button */ 196),
            abstract = Class.abstract;
        var TOOLBAR_MENU_CONTAINER_CLASS = "dx-toolbar-menu-container",
            TOOLBAR_MENU_BUTTON_CLASS = "dx-toolbar-menu-button";
        var ToolbarStrategy = Class.inherit({
            ctor: function(toolbar) {
                this._toolbar = toolbar
            },
            render: function() {
                this._renderMenuButton();
                this._renderWidget()
            },
            _widgetOptions: function() {
                var itemClickAction = this._toolbar._createActionByOption("onItemClick");
                return {
                    itemTemplate: $.proxy(this._getMenuItemTemplate, this),
                    onItemClick: $.proxy(function(e) {
                        this._toggleMenu(false, true);
                        itemClickAction(e)
                    }, this)
                }
            },
            _getMenuItemTemplate: function() {
                return this._toolbar._getTemplateByOption("menuItemTemplate")
            },
            _renderWidget: function() {
                var $menu = $("<div>").appendTo(this._menuContainer());
                this._menu = this._toolbar._createComponent($menu, this._menuWidgetClass(), this._widgetOptions());
                this.renderMenuItems()
            },
            _menuContainer: abstract,
            _menuWidgetClass: abstract,
            _hasVisibleMenuItems: function() {
                var menuItems = this._toolbar.option("items"),
                    result = false;
                var optionGetter = compileGetter("visible"),
                    overflowGetter = compileGetter("locateInMenu");
                var menuLocation = false;
                $.each(menuItems, function(index, item) {
                    var itemVisible = optionGetter(item, {
                            functionsAsIs: true
                        }),
                        itemOverflow = overflowGetter(item, {
                            functionsAsIs: true
                        });
                    if ("menu" === item.location) {
                        menuLocation = true
                    }
                    if (false !== itemVisible && ("auto" === itemOverflow || "always" === itemOverflow || "menu" === item.location)) {
                        result = true
                    }
                });
                if (menuLocation) {
                    errors.log("W0001", "dxToolbar - 'location' item field", "menu", "16.1", "Use 'locateInMenu' item field instead.")
                }
                return result
            },
            _getMenuItems: function() {
                return this._toolbar._getMenuItems()
            },
            _renderMenuButton: function() {
                var buttonOptions = this._menuButtonOptions();
                this._renderMenuButtonContainer();
                this._$button = $("<div>").appendTo(this._$menuButtonContainer).addClass(TOOLBAR_MENU_BUTTON_CLASS);
                this._toolbar._createComponent(this._$button, Button, buttonOptions)
            },
            _menuButtonOptions: function() {
                return {
                    onClick: $.proxy(this._menuButtonClickHandler, this)
                }
            },
            _menuButtonClickHandler: function() {
                this._toggleMenu(!this._menuShown, true)
            },
            _renderMenuButtonContainer: function() {
                var $afterSection = this._toolbar._$afterSection;
                this._$menuButtonContainer = $("<div>").appendTo($afterSection).addClass(this._toolbar._buttonClass()).addClass(TOOLBAR_MENU_CONTAINER_CLASS)
            },
            renderMenuItems: function() {
                this._menu && this._menu.option("items", this._getMenuItems())
            },
            toggleMenuVisibility: function(visible, animate) {
                this._menu && this._toggleMenu(visible, animate)
            },
            _toggleMenu: function(visible, animate) {
                this._menuShown = visible
            },
            getMenuWidget: function() {
                return this._menu
            },
            widgetOption: function(name, value) {
                this._menu && this._menu.option(name, value)
            },
            handleToolbarVisibilityChange: $.noop
        });
        module.exports = ToolbarStrategy
    },
    /*!******************************************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.strategy.drop_down_menu.js ***!
      \******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ToolbarStrategy = __webpack_require__( /*! ./ui.toolbar.strategy */ 314),
            ToolbarMenu = __webpack_require__( /*! ./ui.toolbar.menu */ 316),
            DropDownMenu = __webpack_require__( /*! ../drop_down_menu */ 272);
        var DropDownMenuStrategy = ToolbarStrategy.inherit({
            NAME: "dropDownMenu",
            render: function() {
                if (!this._hasVisibleMenuItems()) {
                    return
                }
                this._renderMenuButtonContainer();
                this._renderWidget()
            },
            renderMenuItems: function() {
                this.callBase();
                if (this._menu && !this._menu.option("items").length) {
                    this._menu.close()
                }
            },
            _menuWidgetClass: function() {
                return DropDownMenu
            },
            _widgetOptions: function() {
                return $.extend(this.callBase(), {
                    deferRendering: true,
                    menuWidget: ToolbarMenu,
                    popupPosition: {
                        at: "bottom right",
                        my: "top right"
                    }
                })
            },
            _getMenuItems: function() {
                var menuItems = this.callBase();
                this._toggleMenuVisibility(menuItems.length);
                return menuItems
            },
            _toggleMenuVisibility: function(value) {
                if (!this._menuContainer()) {
                    return
                }
                this._menuContainer().toggleClass("dx-state-invisible", !value)
            },
            _menuContainer: function() {
                return this._$menuButtonContainer
            }
        });
        module.exports = DropDownMenuStrategy
    },
    /*!***********************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.menu.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            List = __webpack_require__( /*! ../list/ui.list.base */ 226);
        var TOOLBAR_MENU_ACTION_CLASS = "dx-toolbar-menu-action",
            TOOLBAR_HIDDEN_BUTTON_CLASS = "dx-toolbar-hidden-button",
            TOOLBAR_MENU_SECTION_CLASS = "dx-toolbar-menu-section",
            TOOLBAR_MENU_LAST_SECTION_CLASS = "dx-toolbar-menu-last-section";
        var ToolbarMenu = List.inherit({
            _activeStateUnit: "." + TOOLBAR_MENU_ACTION_CLASS,
            _render: function() {
                this._renderSections();
                this.callBase()
            },
            _getSections: function() {
                return this._itemContainer().children()
            },
            _itemElements: function() {
                return this._getSections().children(this._itemSelector())
            },
            _renderSections: function() {
                var that = this,
                    $container = this._itemContainer();
                $.each(["before", "center", "after", "menu"], function() {
                    var sectionName = "_$" + this + "Section",
                        $section = that[sectionName];
                    if (!$section) {
                        that[sectionName] = $section = $("<div>").addClass(TOOLBAR_MENU_SECTION_CLASS)
                    }
                    $section.appendTo($container)
                })
            },
            _renderItems: function() {
                this.callBase.apply(this, arguments);
                this._updateSections()
            },
            _updateSections: function() {
                var $sections = this.element().find("." + TOOLBAR_MENU_SECTION_CLASS);
                $sections.removeClass(TOOLBAR_MENU_LAST_SECTION_CLASS);
                $sections.not(":empty").eq(-1).addClass(TOOLBAR_MENU_LAST_SECTION_CLASS)
            },
            _renderItem: function(index, item, itemContainer, $after) {
                var itemElement, location = item.location || "menu",
                    $container = this["_$" + location + "Section"];
                itemElement = this.callBase(index, item, $container, $after);
                if (this._getItemTemplateName({
                        itemData: item
                    })) {
                    itemElement.addClass("dx-toolbar-menu-custom")
                }
                if ("menu" === location || "dxButton" === item.widget) {
                    itemElement.addClass(TOOLBAR_MENU_ACTION_CLASS)
                }
                if ("dxButton" === item.widget) {
                    itemElement.addClass(TOOLBAR_HIDDEN_BUTTON_CLASS)
                }
                return itemElement
            },
            _getItemTemplateName: function(args) {
                var template = this.callBase(args);
                var data = args.itemData,
                    menuTemplate = data && data.menuItemTemplate;
                return menuTemplate || template
            },
            _itemClickHandler: function(e, args, config) {
                if ($(e.target).closest("." + TOOLBAR_MENU_ACTION_CLASS).length) {
                    this.callBase(e, args, config)
                }
            },
            _clean: function() {
                this._getSections().empty();
                this.callBase()
            }
        });
        registerComponent("dxToolbarMenu", ToolbarMenu);
        module.exports = ToolbarMenu
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.strategy.list_bottom.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ListStrategy = __webpack_require__( /*! ./ui.toolbar.strategy.list_base */ 318),
            Swipeable = __webpack_require__( /*! ../../events/gesture/swipeable */ 248);
        var ListBottomStrategy = ListStrategy.inherit({
            NAME: "listBottom",
            _renderWidget: function() {
                this._renderContainerSwipe();
                this.callBase();
                this._toolbar._$toolbarItemsContainer.prependTo(this._listOverlay.content())
            },
            _renderContainerSwipe: function() {
                this._toolbar._createComponent(this._toolbar._$toolbarItemsContainer, Swipeable, {
                    elastic: false,
                    onStart: $.proxy(this._swipeStartHandler, this),
                    onUpdated: $.proxy(this._swipeUpdateHandler, this),
                    onEnd: $.proxy(this._swipeEndHandler, this),
                    itemSizeFunc: $.proxy(this._getListHeight, this),
                    direction: "vertical"
                })
            },
            _swipeStartHandler: function(e) {
                e.jQueryEvent.maxTopOffset = this._menuShown ? 0 : 1;
                e.jQueryEvent.maxBottomOffset = this._menuShown ? 1 : 0
            },
            _swipeUpdateHandler: function(e) {
                var offset = this._menuShown ? e.jQueryEvent.offset : 1 + e.jQueryEvent.offset;
                this._renderMenuPosition(offset, false)
            },
            _swipeEndHandler: function(e) {
                var targetOffset = e.jQueryEvent.targetOffset;
                targetOffset -= this._menuShown - 1;
                this._toggleMenu(0 === targetOffset, true)
            }
        });
        module.exports = ListBottomStrategy
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.strategy.list_base.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ToolbarStrategy = __webpack_require__( /*! ./ui.toolbar.strategy */ 314),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            hideTopOverlayCallback = __webpack_require__( /*! ../../mobile/hide_top_overlay */ 54).hideCallback,
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            Overlay = __webpack_require__( /*! ../overlay */ 109),
            List = __webpack_require__( /*! ../list/ui.list.base */ 226);
        var TOOLBAR_LIST_VISIBLE_CLASS = "dx-toolbar-list-visible",
            SUBMENU_ANIMATION_EASING = "easeOutCubic",
            SUBMENU_HIDE_DURATION = 200,
            SUBMENU_SHOW_DURATION = 400;
        var ListStrategy = ToolbarStrategy.inherit({
            render: function() {
                this._renderListOverlay();
                this.callBase();
                this._changeListVisible(this._toolbar.option("visible"))
            },
            _renderWidget: function() {
                if (!this._hasVisibleMenuItems()) {
                    return
                }
                this.callBase()
            },
            _menuWidgetClass: function() {
                return List
            },
            _menuContainer: function() {
                return this._listOverlay.content()
            },
            _menuButtonOptions: function() {
                return $.extend({}, this.callBase(), {
                    activeStateEnabled: false,
                    text: "..."
                })
            },
            _widgetOptions: function() {
                return $.extend({}, this.callBase(), {
                    width: "100%",
                    indicateLoading: false
                })
            },
            _renderListOverlay: function() {
                var $listOverlay = $("<div>").appendTo(this._toolbar.element());
                this._listOverlay = this._toolbar._createComponent($listOverlay, Overlay, this._listOverlayConfig())
            },
            _listOverlayConfig: function() {
                return {
                    container: false,
                    deferRendering: false,
                    shading: false,
                    height: "auto",
                    width: "100%",
                    showTitle: false,
                    closeOnOutsideClick: $.proxy(this._listOutsideClickHandler, this),
                    position: null,
                    animation: null,
                    closeOnBackButton: false
                }
            },
            _listOutsideClickHandler: function(e) {
                if (!$(e.target).closest(this._listOverlay.content()).length) {
                    this._toggleMenu(false, true)
                }
            },
            _getListHeight: function() {
                var listHeight = this._listOverlay.content().find(".dx-list").height(),
                    semiHiddenHeight = this._toolbar._$toolbarItemsContainer.height() - this._toolbar.element().height();
                return listHeight + semiHiddenHeight
            },
            _hideTopOverlayHandler: function() {
                this._toggleMenu(false, true)
            },
            _toggleHideTopOverlayCallback: function() {
                if (this._closeCallback) {
                    hideTopOverlayCallback.remove(this._closeCallback)
                }
                if (this._menuShown) {
                    this._closeCallback = $.proxy(this._hideTopOverlayHandler, this);
                    hideTopOverlayCallback.add(this._closeCallback)
                }
            },
            _calculatePixelOffset: function(offset) {
                offset = (offset || 0) - 1;
                var maxOffset = this._getListHeight();
                return offset * maxOffset
            },
            _renderMenuPosition: function(offset, animate) {
                var pos = this._calculatePixelOffset(offset),
                    element = this._listOverlay.content();
                if (animate) {
                    return this._animateMenuToggling(element, pos, this._menuShown)
                }
                translator.move(element, {
                    top: pos
                });
                return $.Deferred().resolve().promise()
            },
            _animateMenuToggling: function($element, position, isShowAnimation) {
                var duration = isShowAnimation ? SUBMENU_SHOW_DURATION : SUBMENU_HIDE_DURATION;
                return fx.animate($element, {
                    type: "slide",
                    to: {
                        top: position
                    },
                    easing: SUBMENU_ANIMATION_EASING,
                    duration: duration
                })
            },
            _toggleMenu: function(visible, animate) {
                this.callBase.apply(this, arguments);
                this._toggleHideTopOverlayCallback();
                this._renderMenuPosition(this._menuShown ? 0 : 1, animate).done($.proxy(function() {
                    this._toolbar.element().toggleClass(TOOLBAR_LIST_VISIBLE_CLASS, visible)
                }, this))
            },
            _changeListVisible: function(value) {
                if (this._listOverlay) {
                    this._listOverlay.option("visible", value);
                    this._toggleMenu(false, false)
                }
            },
            handleToolbarVisibilityChange: function(value) {
                this._changeListVisible(value)
            }
        });
        module.exports = ListStrategy
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/toolbar/ui.toolbar.strategy.list_top.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ListStrategy = __webpack_require__( /*! ./ui.toolbar.strategy.list_base */ 318),
            translator = __webpack_require__( /*! ../../animation/translator */ 60);
        var ListTopStrategy = ListStrategy.inherit({
            NAME: "listTop",
            _listOverlayConfig: function() {
                var config = this.callBase();
                return $.extend({}, config, {
                    onContentReady: $.proxy(this._setItemsContainerZIndex, this)
                })
            },
            _setItemsContainerZIndex: function(e) {
                var overlayZIndex = e.component.content().css("z-index");
                this._toolbar._$toolbarItemsContainer.css("z-index", overlayZIndex + 1)
            },
            _renderMenuPosition: function(offset, animate) {
                var $element = this._toolbar._$toolbarItemsContainer;
                var pos = this._calculateItemsContainerOffset(offset);
                if (animate) {
                    this._animateMenuToggling($element, pos, this._menuShown)
                } else {
                    translator.move($element, {
                        top: pos
                    })
                }
                return this.callBase(offset, animate)
            },
            _calculateItemsContainerOffset: function(offset) {
                offset = (offset || 0) - 1;
                var maxOffset = this._getItemsContainerHeight();
                return offset * maxOffset
            },
            _getItemsContainerHeight: function() {
                var semiHiddenHeight = this._toolbar._$toolbarItemsContainer.height() - this._toolbar.element().height();
                return semiHiddenHeight
            },
            _listOutsideClickHandler: function(e) {
                var $target = $(e.target);
                var isOverlayClick = $target.closest(this._listOverlay.content()).length > 0;
                var isItemsContainerClick = $target.closest(this._toolbar._$toolbarItemsContainer).length > 0;
                if (!isOverlayClick && !isItemsContainerClick) {
                    this._toggleMenu(false, true)
                }
            }
        });
        module.exports = ListTopStrategy
    },
    /*!********************************!*\
      !*** ./Scripts/ui/panorama.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            Class = __webpack_require__( /*! ../core/class */ 20),
            abstract = abstract,
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            swipeEvents = __webpack_require__( /*! ../events/swipe */ 178),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            config = __webpack_require__( /*! ../core/config */ 15),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151);
        var PANORAMA_CLASS = "dx-panorama",
            PANORAMA_WRAPPER_CLASS = "dx-panorama-wrapper",
            PANORAMA_TITLE_CLASS = "dx-panorama-title",
            PANORAMA_GHOST_TITLE_CLASS = "dx-panorama-ghosttitle",
            PANORAMA_ITEMS_CONTAINER_CLASS = "dx-panorama-itemscontainer",
            PANORAMA_ITEM_CLASS = "dx-panorama-item",
            PANORAMA_GHOST_ITEM_CLASS = "dx-panorama-ghostitem",
            PANORAMA_ITEM_DATA_KEY = "dxPanoramaItemData",
            PANORAMA_ITEM_MARGIN_SCALE = .02,
            PANORAMA_TITLE_MARGIN_SCALE = .02,
            PANORAMA_BACKGROUND_MOVE_DURATION = 300,
            PANORAMA_BACKGROUND_MOVE_EASING = "cubic-bezier(.40, .80, .60, 1)",
            PANORAMA_TITLE_MOVE_DURATION = 300,
            PANORAMA_TITLE_MOVE_EASING = "cubic-bezier(.40, .80, .60, 1)",
            PANORAMA_ITEM_MOVE_DURATION = 300,
            PANORAMA_ITEM_MOVE_EASING = "cubic-bezier(.40, .80, .60, 1)";
        var moveBackground = function($element, position) {
            $element.css("background-position", position + "px 0%")
        };
        var position = function($element) {
            return translator.locate($element).left
        };
        var move = function($element, position) {
            translator.move($element, {
                left: position
            });
            $element.css("visibility", "")
        };
        var animation = {
            backgroundMove: function($element, position, completeAction) {
                return fx.animate($element, {
                    to: {
                        "background-position": position + "px 0%"
                    },
                    duration: PANORAMA_BACKGROUND_MOVE_DURATION,
                    easing: PANORAMA_BACKGROUND_MOVE_EASING,
                    complete: completeAction
                })
            },
            titleMove: function($title, position, completeAction) {
                return fx.animate($title, {
                    type: "slide",
                    to: {
                        left: position
                    },
                    duration: PANORAMA_TITLE_MOVE_DURATION,
                    easing: PANORAMA_TITLE_MOVE_EASING,
                    complete: completeAction
                })
            },
            itemMove: function($item, itemPosition, completeAction) {
                return fx.animate($item, {
                    type: "slide",
                    to: {
                        left: itemPosition
                    },
                    duration: PANORAMA_ITEM_MOVE_DURATION,
                    easing: PANORAMA_ITEM_MOVE_EASING,
                    complete: function() {
                        completeAction && completeAction.apply(this, arguments);
                        $item.css("visibility", position($item) > 0 ? "" : "hidden")
                    }
                })
            }
        };
        var endAnimation = function(elements) {
            if (!elements) {
                return
            }
            $.each(elements, function(_, element) {
                fx.stop(element, true)
            })
        };
        var PanoramaItemsRenderStrategy = Class.inherit({
            ctor: function(panorama) {
                this._panorama = panorama
            },
            init: $.noop,
            render: $.noop,
            allItemElements: function() {
                return this._panorama._itemElements()
            },
            updatePositions: abstract,
            animateRollback: abstract,
            detectBoundsTransition: abstract,
            animateComplete: abstract,
            _getRTLSignCorrection: function() {
                return this._panorama._getRTLSignCorrection()
            },
            _isRTLEnabled: function() {
                return this._panorama.option("rtlEnabled")
            },
            _itemMargin: function() {
                return this._containerWidth() * PANORAMA_ITEM_MARGIN_SCALE
            },
            _containerWidth: function() {
                return this._panorama._elementWidth()
            },
            _itemWidth: function() {
                return this._panorama._itemWidth()
            },
            _indexBoundary: function() {
                return this._panorama._indexBoundary()
            },
            _normalizeIndex: function(index) {
                return this._panorama._normalizeIndex(index)
            },
            _startNextPosition: function() {
                if (this._isRTLEnabled()) {
                    return this._containerWidth() - (this._itemMargin() + this._itemWidth())
                } else {
                    return this._itemMargin()
                }
            },
            _startPrevPosition: function() {
                if (this._isRTLEnabled()) {
                    return this._containerWidth()
                } else {
                    return -this._itemWidth()
                }
            }
        });
        var PanoramaOneAndLessItemsRenderStrategy = PanoramaItemsRenderStrategy.inherit({
            updatePositions: function() {
                var $items = this._panorama._itemElements(),
                    startPosition = this._startNextPosition();
                $items.each(function() {
                    move($(this), startPosition)
                })
            },
            animateRollback: $.noop,
            detectBoundsTransition: $.noop,
            animateComplete: $.noop
        });
        var PanoramaTwoItemsRenderStrategy = PanoramaItemsRenderStrategy.inherit({
            init: function() {
                this._initGhostItem()
            },
            render: function() {
                this._renderGhostItem()
            },
            _initGhostItem: function() {
                this._$ghostItem = $("<div>").addClass(PANORAMA_GHOST_ITEM_CLASS)
            },
            _renderGhostItem: function() {
                this._panorama._itemContainer().append(this._$ghostItem);
                this._toggleGhostItem(false)
            },
            _toggleGhostItem: function(visible) {
                var $ghostItem = this._$ghostItem;
                if (visible) {
                    $ghostItem.css("opacity", 1)
                } else {
                    $ghostItem.css("opacity", 0)
                }
            },
            _updateGhostItemContent: function(index) {
                if (false !== index && index !== this._prevGhostIndex) {
                    this._$ghostItem.html(this._panorama._itemElements().eq(index).html());
                    this._prevGhostIndex = index
                }
            },
            _isGhostItemVisible: function() {
                return "1" === this._$ghostItem.css("opacity")
            },
            _swapGhostWithItem: function($item) {
                var $ghostItem = this._$ghostItem,
                    lastItemPosition = position($item);
                move($item, position($ghostItem));
                move($ghostItem, lastItemPosition)
            },
            allItemElements: function() {
                return this._panorama._itemContainer().find("." + PANORAMA_ITEM_CLASS + ", ." + PANORAMA_GHOST_ITEM_CLASS)
            },
            updatePositions: function(offset) {
                var $items = this.allItemElements(),
                    selectedIndex = this._panorama.option("selectedIndex"),
                    adjustedOffset = offset * this._getRTLSignCorrection(),
                    isGhostReplaceLast = adjustedOffset > 0 && 0 === selectedIndex || adjustedOffset < 0 && 1 === selectedIndex,
                    isGhostReplaceFirst = adjustedOffset < 0 && 0 === selectedIndex || adjustedOffset > 0 && 1 === selectedIndex,
                    ghostPosition = isGhostReplaceLast && "replaceLast" || isGhostReplaceFirst && "replaceFirst",
                    ghostContentIndex = isGhostReplaceLast && 1 || isGhostReplaceFirst && 0,
                    positions = this._calculateItemPositions(selectedIndex, ghostPosition);
                this._updateGhostItemContent(ghostContentIndex);
                this._toggleGhostItem(isGhostReplaceLast || isGhostReplaceFirst);
                $items.each(function(index) {
                    move($(this), positions[index] + offset)
                })
            },
            animateRollback: function(currentIndex) {
                var that = this,
                    $items = this._panorama._itemElements(),
                    startPosition = this._startNextPosition(),
                    signCorrection = this._getRTLSignCorrection(),
                    offset = (position($items.eq(currentIndex)) - startPosition) * signCorrection,
                    ghostOffset = (position(this._$ghostItem) - startPosition) * signCorrection,
                    positions = this._calculateItemPositions(currentIndex, ghostOffset > 0 ? "prepend" : "append"),
                    isLastReplacedByGhost = 0 === currentIndex && offset > 0 && ghostOffset > 0 || 1 === currentIndex && ghostOffset < 0;
                if (isLastReplacedByGhost) {
                    this._swapGhostWithItem($items.eq(1))
                } else {
                    this._swapGhostWithItem($items.eq(0))
                }
                $items.each(function(index) {
                    animation.itemMove($(this), positions[index])
                });
                animation.itemMove(this._$ghostItem, positions[2], function() {
                    that._toggleGhostItem(false)
                })
            },
            detectBoundsTransition: function(newIndex, currentIndex) {
                var ghostLocation = position(this._$ghostItem),
                    startPosition = this._startNextPosition(),
                    rtl = this._isRTLEnabled();
                if (0 === newIndex && rtl ^ ghostLocation < startPosition) {
                    return "left"
                }
                if (0 === currentIndex && rtl ^ ghostLocation > startPosition) {
                    return "right"
                }
            },
            animateComplete: function(boundCross, newIndex, currentIndex) {
                var that = this,
                    ghostPosition = !boundCross ^ 0 !== currentIndex ? "prepend" : "append",
                    $items = this._panorama._itemElements(),
                    positions = this._calculateItemPositions(newIndex, ghostPosition),
                    animations = [];
                $items.each(function(index) {
                    animations.push(animation.itemMove($(this), positions[index]))
                });
                animations.push(animation.itemMove(this._$ghostItem, positions[2], function() {
                    that._toggleGhostItem(false)
                }));
                return $.when.apply($, animations)
            },
            _calculateItemPositions: function(atIndex, ghostPosition) {
                var positions = [],
                    itemMargin = this._itemMargin(),
                    itemWidth = this._itemWidth(),
                    itemPositionOffset = (itemWidth + itemMargin) * this._getRTLSignCorrection(),
                    normalFlow = 0 === atIndex,
                    prevPosition = this._startPrevPosition(),
                    nextPosition = this._startNextPosition();
                positions.push(nextPosition);
                nextPosition += itemPositionOffset;
                if (normalFlow) {
                    positions.push(nextPosition)
                } else {
                    positions.splice(0, 0, nextPosition)
                }
                nextPosition += itemPositionOffset;
                switch (ghostPosition) {
                    case "replaceFirst":
                        positions.push(positions[0]);
                        if (normalFlow) {
                            positions[0] = nextPosition
                        } else {
                            positions[0] = prevPosition
                        }
                        break;
                    case "replaceLast":
                        if (normalFlow) {
                            positions.splice(1, 0, prevPosition)
                        } else {
                            positions.splice(1, 0, nextPosition)
                        }
                        break;
                    case "prepend":
                        positions.push(prevPosition);
                        break;
                    case "append":
                        positions.push(nextPosition)
                }
                return positions
            }
        });
        var PanoramaThreeAndMoreItemsRenderStrategy = PanoramaItemsRenderStrategy.inherit({
            updatePositions: function(offset) {
                var $items = this._panorama._itemElements(),
                    movingBack = offset * this._getRTLSignCorrection() < 0,
                    positions = this._calculateItemPositions(this._panorama.option("selectedIndex"), movingBack);
                $items.each(function(index) {
                    move($(this), positions[index] + offset)
                })
            },
            animateRollback: function(selectedIndex) {
                var $items = this._panorama._itemElements(),
                    positions = this._calculateItemPositions(selectedIndex),
                    animatingItems = [selectedIndex, this._normalizeIndex(selectedIndex + 1)];
                if (this._isRTLEnabled() ^ position($items.eq(selectedIndex)) > this._startNextPosition()) {
                    animatingItems.push(this._normalizeIndex(selectedIndex - 1))
                }
                $items.each(function(index) {
                    var $item = $(this);
                    if ($.inArray(index, animatingItems) !== -1) {
                        animation.itemMove($item, positions[index])
                    } else {
                        move($item, positions[index])
                    }
                })
            },
            detectBoundsTransition: function(newIndex, currentIndex) {
                var lastIndex = this._indexBoundary() - 1;
                if (currentIndex === lastIndex && 0 === newIndex) {
                    return "left"
                }
                if (0 === currentIndex && newIndex === lastIndex) {
                    return "right"
                }
            },
            animateComplete: function(boundCross, newIndex, currentIndex) {
                var animations = [],
                    $items = this._panorama._itemElements(),
                    positions = this._calculateItemPositions(newIndex);
                var transitionBack = this._normalizeIndex(currentIndex - 1) === newIndex,
                    cyclingItemIndex = 3 === $items.length && transitionBack ? this._normalizeIndex(currentIndex + 1) : null,
                    cyclingItemPosition = positions[this._indexBoundary()];
                var animatingItems = [newIndex, currentIndex],
                    backAnimatedItemIndex = transitionBack ? currentIndex : newIndex;
                if (!transitionBack) {
                    animatingItems.push(this._normalizeIndex(backAnimatedItemIndex + 1))
                }
                $items.each(function(index) {
                    var $item = $(this);
                    if ($.inArray(index, animatingItems) === -1) {
                        move($item, positions[index]);
                        return
                    }
                    animations.push(index !== cyclingItemIndex ? animation.itemMove($item, positions[index]) : animation.itemMove($item, cyclingItemPosition, function() {
                        move($item, positions[index])
                    }))
                });
                return $.when.apply($, animations)
            },
            _calculateItemPositions: function(atIndex, movingBack) {
                var previousIndex = this._normalizeIndex(atIndex - 1),
                    itemMargin = this._itemMargin(),
                    itemWidth = this._itemWidth(),
                    itemPositionOffset = (itemWidth + itemMargin) * this._getRTLSignCorrection(),
                    positions = [],
                    prevPosition = this._startPrevPosition(),
                    nextPosition = this._startNextPosition();
                for (var i = atIndex; i !== previousIndex; i = this._normalizeIndex(i + 1)) {
                    positions[i] = nextPosition;
                    nextPosition += itemPositionOffset
                }
                if (movingBack) {
                    positions[previousIndex] = nextPosition;
                    nextPosition += itemPositionOffset
                } else {
                    positions[previousIndex] = prevPosition
                }
                positions.push(nextPosition);
                return positions
            }
        });
        var Panorama = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    selectedIndex: 0,
                    title: "panorama",
                    backgroundImage: {
                        url: null,
                        width: 0,
                        height: 0
                    },
                    focusStateEnabled: false,
                    selectionMode: "single",
                    selectionRequired: true,
                    selectionByClick: false
                })
            },
            _itemClass: function() {
                return PANORAMA_ITEM_CLASS
            },
            _itemDataKey: function() {
                return PANORAMA_ITEM_DATA_KEY
            },
            _itemContainer: function() {
                return this._$itemsContainer
            },
            _itemWidth: function() {
                if (!this._itemWidthCache) {
                    this._itemWidthCache = this._itemElements().eq(0).outerWidth()
                }
                return this._itemWidthCache
            },
            _clearItemWidthCache: function() {
                delete this._itemWidthCache
            },
            _elementWidth: function() {
                if (!this._elementWidthCache) {
                    this._elementWidthCache = this.element().width()
                }
                return this._elementWidthCache
            },
            _clearElementWidthCache: function() {
                delete this._elementWidthCache
            },
            _titleWidth: function() {
                if (!this._titleWidthCache) {
                    this._titleWidthCache = this._$title.outerWidth()
                }
                return this._titleWidthCache
            },
            _clearTitleWidthCache: function() {
                delete this._titleWidthCache
            },
            _init: function() {
                this.callBase();
                this._initItemsRenderStrategy();
                this._initWrapper();
                this._initTitle();
                this._initItemsContainer();
                this._initSwipeHandlers()
            },
            _dimensionChanged: function() {
                this._clearItemWidthCache();
                this._clearElementWidthCache();
                this._clearTitleWidthCache();
                this._updatePositions()
            },
            _initWrapper: function() {
                this._$wrapper = $("<div>").addClass(PANORAMA_WRAPPER_CLASS).appendTo(this.element())
            },
            _initItemsRenderStrategy: function() {
                var itemsRenderStrategy;
                switch (this.option("items").length) {
                    case 0:
                    case 1:
                        itemsRenderStrategy = PanoramaOneAndLessItemsRenderStrategy;
                        break;
                    case 2:
                        itemsRenderStrategy = PanoramaTwoItemsRenderStrategy;
                        break;
                    default:
                        itemsRenderStrategy = PanoramaThreeAndMoreItemsRenderStrategy
                }
                this._itemsRenderStrategy = new itemsRenderStrategy(this);
                this._itemsRenderStrategy.init()
            },
            _initBackgroundImage: function() {
                var bgUrl = this.option("backgroundImage.url");
                if (bgUrl) {
                    this.element().css("background-image", "url(" + bgUrl + ")")
                }
            },
            _initTitle: function() {
                this._$title = $("<div>").addClass(PANORAMA_TITLE_CLASS);
                this._$ghostTitle = $("<div>").addClass(PANORAMA_GHOST_TITLE_CLASS);
                this._$wrapper.append(this._$title);
                this._$wrapper.append(this._$ghostTitle);
                this._updateTitle()
            },
            _updateTitle: function() {
                var title = this.option("title");
                this._$title.text(title);
                this._$ghostTitle.text(title);
                this._toggleGhostTitle(false)
            },
            _toggleGhostTitle: function(visible) {
                var $ghostTitle = this._$ghostTitle;
                if (visible) {
                    $ghostTitle.css("opacity", 1)
                } else {
                    $ghostTitle.css("opacity", 0)
                }
            },
            _getRTLSignCorrection: function() {
                return this.option("rtlEnabled") ? -1 : 1
            },
            _initItemsContainer: function() {
                this._$itemsContainer = $("<div>").addClass(PANORAMA_ITEMS_CONTAINER_CLASS);
                this._$wrapper.append(this._$itemsContainer)
            },
            _render: function() {
                this.element().addClass(PANORAMA_CLASS);
                this.callBase();
                this._initBackgroundImage();
                this._itemsRenderStrategy.render()
            },
            _updatePositions: function(offset) {
                offset = offset || 0;
                this._updateBackgroundPosition(offset * this._calculateBackgroundStep());
                this._updateTitlePosition(offset * this._calculateTitleStep());
                this._itemsRenderStrategy.updatePositions(offset * this._elementWidth())
            },
            _updateBackgroundPosition: function(offset) {
                moveBackground(this.element(), this._calculateBackgroundPosition(this.option("selectedIndex")) + offset)
            },
            _updateTitlePosition: function(offset) {
                move(this._$title, this._calculateTitlePosition(this.option("selectedIndex")) + offset)
            },
            _animateRollback: function(currentIndex) {
                this._animateBackgroundMove(currentIndex);
                this._animateTitleMove(currentIndex);
                this._itemsRenderStrategy.animateRollback(currentIndex)
            },
            _animateBackgroundMove: function(toIndex) {
                return animation.backgroundMove(this.element(), this._calculateBackgroundPosition(toIndex))
            },
            _animateTitleMove: function(toIndex) {
                return animation.titleMove(this._$title, this._calculateTitlePosition(toIndex))
            },
            _animateComplete: function(newIndex, currentIndex) {
                var that = this,
                    boundCross = this._itemsRenderStrategy.detectBoundsTransition(newIndex, currentIndex);
                var backgroundAnimation = this._performBackgroundAnimation(boundCross, newIndex);
                var titleAnimation = this._performTitleAnimation(boundCross, newIndex);
                var itemsAnimation = this._itemsRenderStrategy.animateComplete(boundCross, newIndex, currentIndex);
                $.when(backgroundAnimation, titleAnimation, itemsAnimation).done(function() {
                    that._indexChangeOnAnimation = true;
                    that.option("selectedIndex", newIndex);
                    that._indexChangeOnAnimation = false
                })
            },
            _performBackgroundAnimation: function(boundCross, newIndex) {
                if (boundCross) {
                    return this._animateBackgroundBoundsTransition(boundCross, newIndex)
                }
                return this._animateBackgroundMove(newIndex)
            },
            _animateBackgroundBoundsTransition: function(bound, newIndex) {
                var that = this,
                    isLeft = "left" === bound,
                    afterAnimationPosition = this._calculateBackgroundPosition(newIndex),
                    animationEndPositionShift = isLeft ^ this.option("rtlEnabled") ? -this._calculateBackgroundScaledWidth() : this._calculateBackgroundScaledWidth(),
                    animationEndPosition = afterAnimationPosition + animationEndPositionShift;
                return animation.backgroundMove(this.element(), animationEndPosition, function() {
                    moveBackground(that.element(), afterAnimationPosition)
                })
            },
            _performTitleAnimation: function(boundCross, newIndex) {
                if (boundCross) {
                    return this._animateTitleBoundsTransition(boundCross, newIndex)
                }
                return this._animateTitleMove(newIndex)
            },
            _animateTitleBoundsTransition: function(bound, newIndex) {
                var that = this,
                    $ghostTitle = this._$ghostTitle,
                    ghostWidth = this._titleWidth(),
                    panoramaWidth = this._elementWidth(),
                    isLeft = "left" === bound,
                    rtl = this.option("rtlEnabled"),
                    ghostTitleStartPosition = isLeft ^ rtl ? panoramaWidth : -ghostWidth,
                    ghostTitleEndPosition = isLeft ^ rtl ? -(panoramaWidth + ghostWidth) : panoramaWidth;
                move($ghostTitle, ghostTitleStartPosition);
                this._toggleGhostTitle(true);
                this._swapGhostWithTitle();
                var ghostAnimation = animation.titleMove($ghostTitle, ghostTitleEndPosition, function() {
                    that._toggleGhostTitle(false)
                });
                var titleAnimation = animation.titleMove(this._$title, this._calculateTitlePosition(newIndex));
                return $.when(ghostAnimation, titleAnimation)
            },
            _swapGhostWithTitle: function() {
                var $ghostTitle = this._$ghostTitle,
                    $title = this._$title,
                    lastTitlePosition = position($title);
                move($title, position($ghostTitle));
                move($ghostTitle, lastTitlePosition)
            },
            _calculateTitlePosition: function(atIndex) {
                var panoramaWidth = this._elementWidth(),
                    titleWidth = this._titleWidth(),
                    titleMargin = panoramaWidth * PANORAMA_TITLE_MARGIN_SCALE,
                    titleStartPosition = this.option("rtlEnabled") ? panoramaWidth - titleMargin - titleWidth : titleMargin,
                    titleStep = atIndex * this._calculateTitleStep() * this._getRTLSignCorrection();
                return titleStartPosition - titleStep
            },
            _calculateTitleStep: function() {
                var panoramaWidth = this._elementWidth(),
                    titleWidth = this._titleWidth(),
                    indexBoundary = this._indexBoundary() || 1;
                return Math.max((titleWidth - panoramaWidth) / indexBoundary, titleWidth / indexBoundary)
            },
            _calculateBackgroundPosition: function(atIndex) {
                var panoramaWidth = this._elementWidth(),
                    backgroundScaledWidth = this._calculateBackgroundScaledWidth(),
                    backgroundStartPosition = this.option("rtlEnabled") ? panoramaWidth - backgroundScaledWidth : 0,
                    backgroundOffset = atIndex * this._calculateBackgroundStep() * this._getRTLSignCorrection();
                return backgroundStartPosition - backgroundOffset
            },
            _calculateBackgroundStep: function() {
                var itemWidth = this._itemWidth(),
                    backgroundScaledWidth = this._calculateBackgroundScaledWidth();
                return Math.max((backgroundScaledWidth - itemWidth) / (this._indexBoundary() || 1), 0)
            },
            _calculateBackgroundScaledWidth: function() {
                return this.element().height() * this.option("backgroundImage.width") / (this.option("backgroundImage.height") || 1)
            },
            _initSwipeHandlers: function() {
                this.element().on(eventUtils.addNamespace(swipeEvents.start, this.NAME), {
                    itemSizeFunc: $.proxy(this._elementWidth, this)
                }, $.proxy(this._swipeStartHandler, this)).on(eventUtils.addNamespace(swipeEvents.swipe, this.NAME), $.proxy(this._swipeUpdateHandler, this)).on(eventUtils.addNamespace(swipeEvents.end, this.NAME), $.proxy(this._swipeEndHandler, this))
            },
            _swipeStartHandler: function(e) {
                this._stopAnimations();
                e.maxLeftOffset = 1;
                e.maxRightOffset = 1;
                if (config().designMode || this.option("disabled") || this._indexBoundary() <= 1) {
                    e.cancel = true
                }
            },
            _stopAnimations: function() {
                endAnimation([this.element(), this._$ghostTitle, this._$title]);
                endAnimation(this._itemsRenderStrategy.allItemElements())
            },
            _swipeUpdateHandler: function(e) {
                this._updatePositions(e.offset)
            },
            _swipeEndHandler: function(e) {
                var currentIndex = this.option("selectedIndex"),
                    targetOffset = e.targetOffset * this._getRTLSignCorrection();
                if (0 === targetOffset) {
                    this._animateRollback(currentIndex)
                } else {
                    this._animateComplete(this._normalizeIndex(currentIndex - targetOffset), currentIndex)
                }
            },
            _renderSelection: function(current, previous) {
                if (!this._indexChangeOnAnimation) {
                    this._updatePositions()
                }
            },
            _normalizeIndex: function(index) {
                var boundary = this._indexBoundary();
                if (index < 0) {
                    index = boundary + index
                }
                if (index >= boundary) {
                    index -= boundary
                }
                return index
            },
            _indexBoundary: function() {
                return this.option("items").length
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "width":
                        this.callBase(args);
                        this._dimensionChanged();
                        break;
                    case "backgroundImage":
                        this._invalidate();
                        break;
                    case "title":
                        this._updateTitle();
                        break;
                    case "items":
                        this._initItemsRenderStrategy();
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxPanorama", Panorama);
        module.exports = Panorama;
        module.exports.animation = animation
    },
    /*!*****************************!*\
      !*** ./Scripts/ui/pivot.js ***!
      \*****************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            swipeEvents = __webpack_require__( /*! ../events/swipe */ 178),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            domUtils = __webpack_require__( /*! ../core/utils/dom */ 50),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            config = __webpack_require__( /*! ../core/config */ 15),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151),
            PivotTabsModule = __webpack_require__( /*! ./pivot/ui.pivot_tabs */ 322);
        var PIVOT_CLASS = "dx-pivot",
            PIVOT_AUTOHEIGHT_CLASS = "dx-pivot-autoheight",
            PIVOT_WRAPPER_CLASS = "dx-pivot-wrapper",
            PIVOT_TABS_CONTAINER_CLASS = "dx-pivottabs-container",
            PIVOT_ITEM_CONTAINER_CLASS = "dx-pivot-itemcontainer",
            PIVOT_ITEM_WRAPPER_CLASS = "dx-pivot-itemwrapper",
            PIVOT_ITEM_CLASS = "dx-pivot-item",
            PIVOT_ITEM_HIDDEN_CLASS = "dx-pivot-item-hidden",
            PIVOT_ITEM_DATA_KEY = "dxPivotItemData",
            PIVOT_RETURN_BACK_DURATION = 200,
            PIVOT_SLIDE_AWAY_DURATION = 50,
            PIVOT_SLIDE_BACK_DURATION = 250,
            PIVOT_SLIDE_BACK_EASING = "cubic-bezier(.10, 1, 0, 1)";
        var animation = {
            returnBack: function($element) {
                fx.animate($element, {
                    type: "slide",
                    to: {
                        left: 0
                    },
                    duration: PIVOT_RETURN_BACK_DURATION
                })
            },
            slideAway: function($element, position, complete) {
                fx.animate($element, {
                    type: "slide",
                    to: {
                        left: position
                    },
                    duration: PIVOT_SLIDE_AWAY_DURATION,
                    complete: complete
                })
            },
            slideBack: function($element) {
                fx.animate($element, {
                    type: "slide",
                    to: {
                        left: 0
                    },
                    easing: PIVOT_SLIDE_BACK_EASING,
                    duration: PIVOT_SLIDE_BACK_DURATION
                })
            },
            complete: function($element) {
                fx.stop($element, true)
            }
        };
        var Pivot = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    selectedIndex: 0,
                    swipeEnabled: true,
                    itemTitleTemplate: "title",
                    contentTemplate: "content",
                    focusStateEnabled: false,
                    selectionMode: "single",
                    selectionRequired: true,
                    selectionByClick: false
                })
            },
            _itemClass: function() {
                return PIVOT_ITEM_CLASS
            },
            _itemDataKey: function() {
                return PIVOT_ITEM_DATA_KEY
            },
            _itemContainer: function() {
                return this._$itemWrapper
            },
            _elementWidth: function() {
                if (!this._elementWidthCache) {
                    this._elementWidthCache = this.element().width()
                }
                return this._elementWidthCache
            },
            _clearElementWidthCache: function() {
                delete this._elementWidthCache
            },
            _init: function() {
                this.callBase();
                this.element().addClass(PIVOT_CLASS);
                this._initWrapper();
                this._initTabs();
                this._initItemContainer();
                this._clearItemsCache();
                this._initSwipeHandlers()
            },
            _dimensionChanged: function() {
                this._clearElementWidthCache()
            },
            _initWrapper: function() {
                this._$wrapper = $("<div>").addClass(PIVOT_WRAPPER_CLASS).appendTo(this.element())
            },
            _initItemContainer: function() {
                var $itemContainer = $("<div>").addClass(PIVOT_ITEM_CONTAINER_CLASS);
                this._$wrapper.append($itemContainer);
                this._$itemWrapper = $("<div>").addClass(PIVOT_ITEM_WRAPPER_CLASS);
                $itemContainer.append(this._$itemWrapper)
            },
            _clearItemsCache: function() {
                this._itemsCache = []
            },
            _initTabs: function() {
                var that = this,
                    $tabsContainer = $("<div>").addClass(PIVOT_TABS_CONTAINER_CLASS);
                this._$wrapper.append($tabsContainer);
                this._tabs = this._createComponent($tabsContainer, PivotTabsModule.default, {
                    itemTemplateProperty: "titleTemplate",
                    itemTemplate: this._getTemplateByOption("itemTitleTemplate"),
                    items: this.option("items"),
                    selectedIndex: this.option("selectedIndex"),
                    onPrepare: function() {
                        that._prepareAnimation()
                    },
                    onUpdatePosition: function(args) {
                        that._updateContentPosition(args.offset)
                    },
                    onRollback: function() {
                        that._animateRollback()
                    },
                    onSelectionChanged: function(args) {
                        that.option("selectedItem", args.addedItems[0])
                    },
                    swipeEnabled: this.option("swipeEnabled")
                })
            },
            _render: function() {
                this._renderContentTemplate();
                this.callBase();
                var selectedIndex = this.option("selectedIndex");
                this._renderCurrentContent(selectedIndex, selectedIndex)
            },
            _renderContentTemplate: function() {
                if (commonUtils.isDefined(this._singleContent)) {
                    return
                }
                this._getTemplateByOption("contentTemplate").render({
                    container: this._$itemWrapper
                });
                this._singleContent = !this._$itemWrapper.is(":empty")
            },
            _renderDimensions: function() {
                this.callBase();
                this.element().toggleClass(PIVOT_AUTOHEIGHT_CLASS, "auto" === this.option("height"))
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._tabs._dimensionChanged()
                }
            },
            _renderCurrentContent: function(currentIndex, previousIndex) {
                var itemsCache = this._itemsCache;
                itemsCache[previousIndex] = this._selectedItemElement();
                var $hidingItem = itemsCache[previousIndex],
                    $showingItem = itemsCache[currentIndex];
                domUtils.triggerHidingEvent($hidingItem);
                $hidingItem.addClass(PIVOT_ITEM_HIDDEN_CLASS);
                if ($showingItem) {
                    $showingItem.removeClass(PIVOT_ITEM_HIDDEN_CLASS);
                    domUtils.triggerShownEvent($showingItem)
                } else {
                    this._renderContent()
                }
                this._selectionChangePromise && this._selectionChangePromise.resolve();
                this._selectionChangePromise = $.Deferred()
            },
            _updateContentPosition: function(offset) {
                translator.move(this._$itemWrapper, {
                    left: this._calculatePixelOffset(offset)
                })
            },
            _animateRollback: function() {
                animation.returnBack(this._$itemWrapper)
            },
            _animateComplete: function(newIndex, currentIndex) {
                var $itemWrapper = this._$itemWrapper,
                    rtlSignCorrection = this._getRTLSignCorrection(),
                    intermediatePosition = this._elementWidth() * (this._isPrevSwipeHandled() ? 1 : -1) * rtlSignCorrection;
                animation.slideAway($itemWrapper, intermediatePosition, $.proxy(function() {
                    translator.move($itemWrapper, {
                        left: -intermediatePosition
                    });
                    this._renderCurrentContent(newIndex, currentIndex)
                }, this));
                animation.slideBack($itemWrapper)
            },
            _calculatePixelOffset: function(offset) {
                offset = offset || 0;
                return offset * this._elementWidth()
            },
            _isPrevSwipeHandled: function() {
                var wrapperOffset = translator.locate(this._$itemWrapper).left,
                    rtl = this.option("rtlEnabled");
                return rtl ^ wrapperOffset > 0 && 0 !== wrapperOffset
            },
            _initSwipeHandlers: function() {
                this.element().on(eventUtils.addNamespace(swipeEvents.start, this.NAME), {
                    itemSizeFunc: $.proxy(this._elementWidth, this)
                }, $.proxy(this._swipeStartHandler, this)).on(eventUtils.addNamespace(swipeEvents.swipe, this.NAME), $.proxy(this._swipeUpdateHandler, this)).on(eventUtils.addNamespace(swipeEvents.end, this.NAME), $.proxy(this._swipeEndHandler, this))
            },
            _swipeStartHandler: function(e) {
                this._prepareAnimation();
                this._tabs.prepare();
                if (config().designMode || this.option("disabled") || !this.option("swipeEnabled") || this._indexBoundary() <= 1) {
                    e.cancel = true
                } else {
                    this._swipeGestureRunning = true
                }
                e.maxLeftOffset = 1;
                e.maxRightOffset = 1
            },
            _prepareAnimation: function() {
                this._stopAnimation()
            },
            _stopAnimation: function() {
                animation.complete(this._$itemWrapper)
            },
            _swipeUpdateHandler: function(e) {
                var offset = e.offset;
                this._updateContentPosition(offset);
                this._tabs.updatePosition(offset)
            },
            _swipeEndHandler: function(e) {
                var targetOffset = e.targetOffset * this._getRTLSignCorrection();
                if (0 === targetOffset) {
                    this._animateRollback();
                    this._tabs.rollback()
                } else {
                    var newIndex = this._normalizeIndex(this.option("selectedIndex") - targetOffset);
                    this.option("selectedIndex", newIndex)
                }
                this._swipeGestureRunning = false
            },
            _normalizeIndex: function(index) {
                var boundary = this._indexBoundary();
                if (index < 0) {
                    index = boundary + index
                }
                if (index >= boundary) {
                    index -= boundary
                }
                return index
            },
            _indexBoundary: function() {
                return this.option("items").length
            },
            _renderContentImpl: function() {
                if (this._singleContent) {
                    return
                }
                var items = this.option("items"),
                    selectedIndex = this.option("selectedIndex");
                if (items.length) {
                    this._renderItems([items[selectedIndex]])
                }
            },
            _selectedItemElement: function() {
                return this._$itemWrapper.children("." + PIVOT_ITEM_CLASS + ":not(." + PIVOT_ITEM_HIDDEN_CLASS + ")")
            },
            _getRTLSignCorrection: function() {
                return this.option("rtlEnabled") ? -1 : 1
            },
            _clean: function() {
                animation.complete(this._$itemWrapper);
                this.callBase()
            },
            _cleanItemContainer: function() {
                if (this._singleContent) {
                    return
                }
                this.callBase()
            },
            _refresh: function() {
                this._tabs._refresh();
                this.callBase()
            },
            _updateSelection: function(addedItems, removedItems) {
                var newIndex = addedItems[0],
                    oldIndex = removedItems[0];
                if (!this._swipeGestureRunning) {
                    this._prepareAnimation()
                }
                this._animateComplete(newIndex, oldIndex);
                this._tabs.option("selectedIndex", newIndex)
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "disabled":
                        this._tabs.option("disabled", value);
                        this.callBase(args);
                        break;
                    case "items":
                        this._tabs.option("items", value);
                        this._clearItemsCache();
                        this.callBase(args);
                        break;
                    case "rtlEnabled":
                        this._tabs.option("rtlEnabled", value);
                        this._clearItemsCache();
                        this.callBase(args);
                        break;
                    case "itemTitleTemplate":
                        this._tabs.option("itemTemplate", this._getTemplate(value));
                        break;
                    case "swipeEnabled":
                        this._tabs.option("swipeEnabled", value);
                        break;
                    case "contentTemplate":
                        this._singleContent = null;
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        registerComponent("dxPivot", Pivot);
        module.exports = Pivot;
        module.exports.animation = animation
    },
    /*!*******************************************!*\
      !*** ./Scripts/ui/pivot/ui.pivot_tabs.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            swipeEvents = __webpack_require__( /*! ../../events/swipe */ 178),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            config = __webpack_require__( /*! ../../core/config */ 15),
            CollectionWidget = __webpack_require__( /*! ../collection/ui.collection_widget.edit */ 151);
        var PIVOT_TABS_CLASS = "dx-pivottabs",
            PIVOT_TAB_CLASS = "dx-pivottabs-tab",
            PIVOT_TAB_SELECTED_CLASS = "dx-pivottabs-tab-selected",
            PIVOT_GHOST_TAB_CLASS = "dx-pivottabs-ghosttab",
            PIVOT_TAB_DATA_KEY = "dxPivotTabData",
            PIVOT_TAB_MOVE_DURATION = 200,
            PIVOT_TAB_MOVE_EASING = "cubic-bezier(.40, .80, .60, 1)";
        var animation = {
            moveTo: function($tab, position, completeAction) {
                return fx.animate($tab, {
                    type: "slide",
                    to: {
                        left: position
                    },
                    duration: PIVOT_TAB_MOVE_DURATION,
                    easing: PIVOT_TAB_MOVE_EASING,
                    complete: completeAction
                })
            },
            slideAppear: function($tab, position) {
                return fx.animate($tab, {
                    type: "slide",
                    to: {
                        left: position,
                        opacity: 1
                    },
                    duration: PIVOT_TAB_MOVE_DURATION,
                    easing: PIVOT_TAB_MOVE_EASING
                })
            },
            slideDisappear: function($tab, position) {
                return fx.animate($tab, {
                    type: "slide",
                    to: {
                        left: position,
                        opacity: 0
                    },
                    duration: PIVOT_TAB_MOVE_DURATION,
                    easing: PIVOT_TAB_MOVE_EASING
                })
            },
            complete: function(elements) {
                if (!elements) {
                    return
                }
                $.each(elements, function(_, $element) {
                    fx.stop($element, true)
                })
            },
            stop: function(elements) {
                if (!elements) {
                    return
                }
                $.each(elements, function(_, $element) {
                    fx.stop($element)
                })
            }
        };
        var PivotTabs = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    selectedIndex: 0,
                    onPrepare: null,
                    onUpdatePosition: null,
                    onRollback: null,
                    focusStateEnabled: false,
                    selectionMode: "single",
                    selectionRequired: true,
                    swipeEnabled: true
                })
            },
            _itemClass: function() {
                return PIVOT_TAB_CLASS
            },
            _itemDataKey: function() {
                return PIVOT_TAB_DATA_KEY
            },
            _itemContainer: function() {
                return this.element()
            },
            _elementWidth: function() {
                if (!this._elementWidthCache) {
                    this._elementWidthCache = this.element().width()
                }
                return this._elementWidthCache
            },
            _clearElementWidthCache: function() {
                delete this._elementWidthCache
            },
            _itemWidths: function() {
                if (!this._itemWidthsCache) {
                    var $tabs = this._itemElements(),
                        widths = [];
                    $tabs.each(function() {
                        widths.push($(this).outerWidth())
                    });
                    this._itemWidthsCache = widths
                }
                return this._itemWidthsCache
            },
            _init: function() {
                this.callBase();
                this._initGhostTab();
                this._initSwipeHandlers();
                this._initActions()
            },
            _dimensionChanged: function() {
                this._clearElementWidthCache();
                this._cleanPositionCache();
                this._updateTabsPositions()
            },
            _initGhostTab: function() {
                this._$ghostTab = $("<div>").addClass(PIVOT_GHOST_TAB_CLASS)
            },
            _initActions: function() {
                this._updatePositionAction = this._createActionByOption("onUpdatePosition");
                this._rollbackAction = this._createActionByOption("onRollback");
                this._prepareAction = this._createActionByOption("onPrepare")
            },
            _render: function() {
                this.element().addClass(PIVOT_TABS_CLASS);
                this.callBase();
                this._renderGhostTab()
            },
            _renderGhostTab: function() {
                this._itemContainer().append(this._$ghostTab);
                this._toggleGhostTab(false)
            },
            _toggleGhostTab: function(visible) {
                var $ghostTab = this._$ghostTab;
                if (visible) {
                    this._updateGhostTabContent();
                    $ghostTab.css("opacity", 1)
                } else {
                    $ghostTab.css("opacity", 0)
                }
            },
            _isGhostTabVisible: function() {
                return "1" === this._$ghostTab.css("opacity")
            },
            _updateGhostTabContent: function(prevIndex) {
                prevIndex = void 0 === prevIndex ? this._previousIndex() : prevIndex;
                var $ghostTab = this._$ghostTab,
                    $items = this._itemElements();
                $ghostTab.html($items.eq(prevIndex).html())
            },
            _updateTabsPositions: function(offset) {
                offset = this._applyOffsetBoundaries(offset);
                var isPrevSwipeHandled = this.option("rtlEnabled") ^ offset > 0 && 0 !== offset,
                    tabPositions = this._calculateTabPositions(isPrevSwipeHandled ? "replace" : "append");
                this._moveTabs(tabPositions, offset);
                this._toggleGhostTab(isPrevSwipeHandled)
            },
            _moveTabs: function(positions, offset) {
                offset = offset || 0;
                var $tabs = this._allTabElements();
                $tabs.each(function(index) {
                    translator.move($(this), {
                        left: positions[index] + offset
                    })
                })
            },
            _applyOffsetBoundaries: function(offset) {
                offset = offset || 0;
                var maxOffset = offset > 0 ? this._maxRightOffset : this._maxLeftOffset;
                return offset * maxOffset
            },
            _animateRollback: function() {
                var that = this,
                    $tabs = this._itemElements(),
                    positions = this._calculateTabPositions("prepend");
                if (this._isGhostTabVisible()) {
                    this._swapGhostWithTab($tabs.eq(this._previousIndex()));
                    animation.moveTo(this._$ghostTab, positions[this._indexBoundary()], function() {
                        that._toggleGhostTab(false)
                    })
                }
                $tabs.each(function(index) {
                    animation.moveTo($(this), positions[index])
                })
            },
            _animateComplete: function(newIndex, currentIndex) {
                var $tabs = this._itemElements(),
                    isPrevSwipeHandled = this._isGhostTabVisible();
                $tabs.eq(currentIndex).removeClass(PIVOT_TAB_SELECTED_CLASS);
                if (isPrevSwipeHandled) {
                    this._animateIndexDecreasing(newIndex)
                } else {
                    this._animateIndexIncreasing(newIndex)
                }
                $tabs.eq(newIndex).addClass(PIVOT_TAB_SELECTED_CLASS)
            },
            _animateIndexDecreasing: function(newIndex) {
                var $tabs = this._itemElements(),
                    positions = this._calculateTabPositions("append", newIndex),
                    animations = [];
                $tabs.each(function(index) {
                    animations.push(animation.moveTo($(this), positions[index]))
                });
                animations.push(animation.slideDisappear(this._$ghostTab, positions[this._indexBoundary()]));
                return $.when.apply($, animations)
            },
            _animateIndexIncreasing: function(newIndex) {
                var that = this,
                    $tabs = this._itemElements(),
                    positions = this._calculateTabPositions("prepend", newIndex),
                    previousIndex = this._previousIndex(newIndex),
                    $prevTab = $tabs.eq(previousIndex),
                    prevTabPosition = translator.locate($prevTab).left,
                    rtl = this.option("rtlEnabled"),
                    bound = rtl ? this._elementWidth() - this._itemWidths()[previousIndex] : 0,
                    isNextSwipeHandled = (prevTabPosition - bound) * this._getRTLSignCorrection() < 0,
                    animations = [];
                if (!isNextSwipeHandled) {
                    this._moveTabs(this._calculateTabPositions("append", previousIndex))
                }
                this._updateGhostTabContent(previousIndex);
                this._swapGhostWithTab($tabs.eq(previousIndex));
                $tabs.each(function(index) {
                    var $tab = $(this),
                        newPosition = positions[index];
                    animations.push(index === previousIndex ? animation.slideAppear($tab, newPosition) : animation.moveTo($tab, newPosition))
                });
                animations.push(animation.moveTo(this._$ghostTab, positions[this._indexBoundary()], function() {
                    that._toggleGhostTab(false)
                }));
                return $.when.apply($, animations)
            },
            _swapGhostWithTab: function($tab) {
                var $ghostTab = this._$ghostTab,
                    lastTabPosition = translator.locate($tab).left,
                    lastTabOpacity = $tab.css("opacity");
                translator.move($tab, {
                    left: translator.locate($ghostTab).left
                });
                $tab.css("opacity", $ghostTab.css("opacity"));
                translator.move($ghostTab, {
                    left: lastTabPosition
                });
                $ghostTab.css("opacity", lastTabOpacity)
            },
            _calculateTabPositions: function(ghostPosition, index) {
                index = void 0 === index ? this.option("selectedIndex") : index;
                var mark = index + ghostPosition;
                if (this._calculatedPositionsMark !== mark) {
                    this._calculatedPositions = this._calculateTabPositionsImpl(index, ghostPosition);
                    this._calculatedPositionsMark = mark
                }
                return this._calculatedPositions
            },
            _calculateTabPositionsImpl: function(currentIndex, ghostPosition) {
                var prevIndex = this._normalizeIndex(currentIndex - 1),
                    widths = this._itemWidths();
                var rtl = this.option("rtlEnabled"),
                    signCorrection = this._getRTLSignCorrection(),
                    tabsContainerWidth = this._elementWidth(),
                    nextPosition = rtl ? tabsContainerWidth : 0,
                    positions = [];
                var calculateTabPosition = function(currentIndex, width) {
                    var rtlOffset = rtl * width;
                    positions.splice(currentIndex, 0, nextPosition - rtlOffset);
                    nextPosition += width * signCorrection
                };
                $.each(widths.slice(currentIndex), calculateTabPosition);
                $.each(widths.slice(0, currentIndex), calculateTabPosition);
                switch (ghostPosition) {
                    case "replace":
                        var lastTabPosition = positions[prevIndex];
                        positions.splice(prevIndex, 1, rtl ? tabsContainerWidth : -widths[prevIndex]);
                        positions.push(lastTabPosition);
                        break;
                    case "prepend":
                        positions.push(rtl ? tabsContainerWidth : -widths[prevIndex]);
                        break;
                    case "append":
                        positions.push(nextPosition - widths[currentIndex] * rtl)
                }
                return positions
            },
            _allTabElements: function() {
                return this._itemContainer().find("." + PIVOT_TAB_CLASS + ", ." + PIVOT_GHOST_TAB_CLASS)
            },
            _initSwipeHandlers: function() {
                this.element().on(eventUtils.addNamespace(swipeEvents.start, this.NAME), {
                    itemSizeFunc: $.proxy(this._elementWidth, this)
                }, $.proxy(this._swipeStartHandler, this)).on(eventUtils.addNamespace(swipeEvents.swipe, this.NAME), $.proxy(this._swipeUpdateHandler, this)).on(eventUtils.addNamespace(swipeEvents.end, this.NAME), $.proxy(this._swipeEndHandler, this))
            },
            _swipeStartHandler: function(e) {
                this._prepareAnimation();
                this._prepareAction();
                e.maxLeftOffset = 1;
                e.maxRightOffset = 1;
                if (config().designMode || this.option("disabled") || !this.option("swipeEnabled") || this._indexBoundary() <= 1) {
                    e.cancel = true
                } else {
                    this._swipeGestureRunning = true
                }
            },
            _prepareAnimation: function() {
                this._stopAnimation()
            },
            _stopAnimation: function() {
                animation.complete(this._allTabElements())
            },
            _swipeUpdateHandler: function(e) {
                var offset = e.offset;
                this._updateTabsPositions(offset);
                this._updatePositionAction({
                    offset: offset
                })
            },
            _swipeEndHandler: function(e) {
                var targetOffset = e.targetOffset * this._getRTLSignCorrection();
                if (0 === targetOffset) {
                    this._animateRollback();
                    this._rollbackAction()
                } else {
                    var newIndex = this._normalizeIndex(this.option("selectedIndex") - targetOffset);
                    this.option("selectedIndex", newIndex)
                }
                this._swipeGestureRunning = false
            },
            _previousIndex: function(atIndex) {
                atIndex = void 0 === atIndex ? this.option("selectedIndex") : atIndex;
                return this._normalizeIndex(atIndex - 1)
            },
            _normalizeIndex: function(index) {
                var boundary = this._indexBoundary();
                if (index < 0) {
                    index = boundary + index
                }
                if (index >= boundary) {
                    index -= boundary
                }
                return index
            },
            _indexBoundary: function() {
                return this.option("items").length
            },
            _renderSelection: function(current) {
                this._calculateMaxOffsets(current);
                this._updateTabsPositions();
                this._itemElements().eq(current).addClass(PIVOT_TAB_SELECTED_CLASS)
            },
            _updateSelection: function(addedItems, removedItems) {
                var newIndex = addedItems[0],
                    oldIndex = removedItems[0];
                this._calculateMaxOffsets(newIndex);
                if (!this._swipeGestureRunning) {
                    this._prepareAnimation()
                }
                if (this._itemElements().length) {
                    this._animateComplete(newIndex, oldIndex)
                }
            },
            _calculateMaxOffsets: function(index) {
                var currentTabWidth = this._itemWidths()[index],
                    prevTabWidth = this._itemWidths()[this._previousIndex(index)],
                    rtl = this.option("rtlEnabled");
                this._maxLeftOffset = rtl ? prevTabWidth : currentTabWidth;
                this._maxRightOffset = rtl ? currentTabWidth : prevTabWidth
            },
            _getRTLSignCorrection: function() {
                return this.option("rtlEnabled") ? -1 : 1
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _clean: function() {
                animation.stop(this._allTabElements());
                this._clearElementWidthCache();
                this._cleanPositionCache();
                this.callBase()
            },
            _cleanPositionCache: function() {
                delete this._itemWidthsCache;
                delete this._calculatedPositionsMark
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "items":
                    case "rtlEnabled":
                        this._cleanPositionCache();
                        this.callBase(args);
                        break;
                    case "onPrepare":
                    case "swipeEnabled":
                        break;
                    case "onUpdatePosition":
                    case "onRollback":
                        this._initActions();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            prepare: function() {
                this._prepareAnimation()
            },
            updatePosition: function(offset) {
                this._updateTabsPositions(offset)
            },
            rollback: function() {
                this._animateRollback()
            }
        });
        PivotTabs.publicName("dxPivotTabs");
        exports.default = PivotTabs;
        exports.animation = animation
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/slide_out.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            PlainEditStrategy = __webpack_require__( /*! ./collection/ui.collection_widget.edit.strategy.plain */ 166),
            SlideOutView = __webpack_require__( /*! ./slide_out_view */ 324),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151),
            List = __webpack_require__( /*! ./list */ 213);
        var SLIDEOUT_CLASS = "dx-slideout",
            SLIDEOUT_ITEM_CONTAINER_CLASS = "dx-slideout-item-container",
            SLIDEOUT_MENU = "dx-slideout-menu",
            SLIDEOUT_ITEM_CLASS = "dx-slideout-item",
            SLIDEOUT_ITEM_DATA_KEY = "dxSlideoutItemData";
        var SlideOut = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    activeStateEnabled: false,
                    menuItemTemplate: "menuItem",
                    swipeEnabled: true,
                    menuVisible: false,
                    menuPosition: "normal",
                    menuGrouped: false,
                    menuGroupTemplate: "menuGroup",
                    onMenuItemRendered: null,
                    onMenuGroupRendered: null,
                    contentTemplate: "content",
                    selectionMode: "single",
                    selectionRequired: true
                })
            },
            _itemClass: function() {
                return SLIDEOUT_ITEM_CLASS
            },
            _itemDataKey: function() {
                return SLIDEOUT_ITEM_DATA_KEY
            },
            _itemContainer: function() {
                return this._slideOutView.content()
            },
            _init: function() {
                this.callBase();
                this.element().addClass(SLIDEOUT_CLASS);
                this._initSlideOutView()
            },
            _initEditStrategy: function() {
                if (this.option("menuGrouped")) {
                    var strategy = PlainEditStrategy.inherit({
                        _getPlainItems: function() {
                            return $.map(this.callBase(), function(group) {
                                return group.items
                            })
                        }
                    });
                    this._editStrategy = new strategy(this)
                } else {
                    this.callBase()
                }
            },
            _initSlideOutView: function() {
                this._slideOutView = this._createComponent(this.element(), SlideOutView, {
                    _templates: [],
                    menuVisible: this.option("menuVisible"),
                    swipeEnabled: this.option("swipeEnabled"),
                    menuPosition: this.option("menuPosition"),
                    onOptionChanged: $.proxy(this._slideOutViewOptionChanged, this)
                });
                this._itemContainer().addClass(SLIDEOUT_ITEM_CONTAINER_CLASS)
            },
            _slideOutViewOptionChanged: function(args) {
                if ("menuVisible" === args.name) {
                    this.option(args.name, args.value)
                }
            },
            _render: function() {
                this._slideOutView._renderShield();
                this._renderList();
                this._renderContentTemplate();
                this.callBase()
            },
            _renderList: function() {
                this._$list = this._$list || $("<div>").addClass(SLIDEOUT_MENU).appendTo(this._slideOutView.menuContent());
                this._renderItemClickAction();
                this._createComponent(this._$list, List, {
                    itemTemplateProperty: "menuTemplate",
                    indicateLoading: false,
                    onItemClick: $.proxy(this._listItemClickHandler, this),
                    items: this.option("items"),
                    dataSource: this.option("dataSource"),
                    itemTemplate: this._getTemplateByOption("menuItemTemplate"),
                    grouped: this.option("menuGrouped"),
                    groupTemplate: this.option("menuGroupTemplate"),
                    onItemRendered: this.option("onMenuItemRendered"),
                    onGroupRendered: this.option("onMenuGroupRendered"),
                    onContentReady: $.proxy(this._updateSlideOutView, this)
                })
            },
            _updateSlideOutView: function() {
                this._slideOutView._dimensionChanged()
            },
            _renderItemClickAction: function() {
                this._itemClickAction = this._createActionByOption("onItemClick")
            },
            _listItemClickHandler: function(e) {
                var selectedIndex = this._$list.find(".dx-list-item").index(e.itemElement);
                this.option("selectedIndex", selectedIndex);
                this._itemClickAction(e)
            },
            _renderContentTemplate: function() {
                if (commonUtils.isDefined(this._singleContent)) {
                    return
                }
                var itemsLength = this._itemContainer().html().length;
                this._getTemplateByOption("contentTemplate").render({
                    container: this._itemContainer()
                });
                this._singleContent = this._itemContainer().html().length !== itemsLength
            },
            _itemClickHandler: $.noop,
            _renderContentImpl: function(template) {
                if (this._singleContent) {
                    return
                }
                var items = this.option("items"),
                    selectedIndex = this.option("selectedIndex");
                if (items.length && selectedIndex > -1) {
                    var selectedItem = this._$list.dxList("instance").getItemByIndex(selectedIndex);
                    this._renderItems([selectedItem])
                }
            },
            _renderItem: function(index, item, container) {
                this._itemContainer().find("." + SLIDEOUT_ITEM_CLASS).remove();
                this.callBase(index, item)
            },
            _selectedItemElement: function(index) {
                return this._itemElements().eq(0)
            },
            _renderSelection: function() {
                this._renderContent()
            },
            _getListWidth: function() {
                return this._slideOutView._getMenuWidth()
            },
            _changeMenuOption: function(name, value) {
                this._$list.dxList("instance").option(name, value);
                this._updateSlideOutView()
            },
            _cleanItemContainer: function() {
                if (this._singleContent) {
                    return
                }
                this.callBase()
            },
            beginUpdate: function() {
                this.callBase();
                this._$list && this._$list.dxList("beginUpdate")
            },
            endUpdate: function() {
                this._$list && this._$list.dxList("endUpdate");
                this.callBase()
            },
            _optionChanged: function(args) {
                var name = args.name;
                var value = args.value;
                switch (name) {
                    case "menuVisible":
                    case "swipeEnabled":
                    case "rtlEnabled":
                    case "menuPosition":
                        this._slideOutView.option(name, value);
                        break;
                    case "width":
                        this.callBase(args);
                        this._updateSlideOutView();
                        break;
                    case "menuItemTemplate":
                        this._changeMenuOption("itemTemplate", this._getTemplate(value));
                        break;
                    case "items":
                        this._changeMenuOption("items", this.option("items"));
                        break;
                    case "dataSource":
                        this._changeMenuOption(name, value);
                        this.callBase(args);
                        break;
                    case "menuGrouped":
                        this._initEditStrategy();
                        this._changeMenuOption("grouped", value);
                        break;
                    case "menuGroupTemplate":
                        this._changeMenuOption("groupTemplate", this._getTemplate(value));
                        break;
                    case "onMenuItemRendered":
                        this._changeMenuOption("onItemRendered", value);
                        break;
                    case "onMenuGroupRendered":
                        this._changeMenuOption("onGroupRendered", value);
                        break;
                    case "onItemClick":
                        this._renderItemClickAction();
                        break;
                    case "contentTemplate":
                        this._singleContent = null;
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            showMenu: function() {
                return this._slideOutView.toggleMenuVisibility(true)
            },
            hideMenu: function() {
                return this._slideOutView.toggleMenuVisibility(false)
            },
            toggleMenuVisibility: function(showing) {
                return this._slideOutView.toggleMenuVisibility(showing)
            }
        });
        registerComponent("dxSlideOut", SlideOut);
        module.exports = SlideOut
    },
    /*!**************************************!*\
      !*** ./Scripts/ui/slide_out_view.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            translator = __webpack_require__( /*! ../animation/translator */ 60),
            hideTopOverlayCallback = __webpack_require__( /*! ../mobile/hide_top_overlay */ 54).hideCallback,
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            Widget = __webpack_require__( /*! ./widget/ui.widget */ 89),
            Swipeable = __webpack_require__( /*! ../events/gesture/swipeable */ 248);
        var SLIDEOUTVIEW_CLASS = "dx-slideoutview",
            SLIDEOUTVIEW_WRAPPER_CLASS = "dx-slideoutview-wrapper",
            SLIDEOUTVIEW_MENU_CONTENT_CLASS = "dx-slideoutview-menu-content",
            SLIDEOUTVIEW_CONTENT_CLASS = "dx-slideoutview-content",
            SLIDEOUTVIEW_SHIELD_CLASS = "dx-slideoutview-shield",
            INVISIBLE_STATE_CLASS = "dx-state-invisible",
            ANONYMOUS_TEMPLATE_NAME = "content",
            ANIMATION_DURATION = 400;
        var animation = {
            moveTo: function($element, position, completeAction) {
                fx.animate($element, {
                    type: "slide",
                    to: {
                        left: position
                    },
                    duration: ANIMATION_DURATION,
                    complete: completeAction
                })
            },
            complete: function($element) {
                fx.stop($element, true)
            }
        };
        var SlideOutView = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    menuPosition: "normal",
                    menuVisible: false,
                    swipeEnabled: true,
                    menuTemplate: "menu",
                    contentTemplate: "content",
                    contentOffset: 45
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        android: true
                    },
                    options: {
                        contentOffset: 54
                    }
                }, {
                    device: function(device) {
                        return "generic" === device.platform && "desktop" !== device.deviceType
                    },
                    options: {
                        contentOffset: 56
                    }
                }, {
                    device: {
                        win: true,
                        phone: false
                    },
                    options: {
                        contentOffset: 76
                    }
                }])
            },
            _getAnonymousTemplateName: function() {
                return ANONYMOUS_TEMPLATE_NAME
            },
            _init: function() {
                this.callBase();
                this.element().addClass(SLIDEOUTVIEW_CLASS);
                this._deferredAnimate = void 0;
                this._initHideTopOverlayHandler()
            },
            _initHideTopOverlayHandler: function() {
                this._hideMenuHandler = $.proxy(this.hideMenu, this)
            },
            _render: function() {
                this.callBase();
                this._renderShield();
                this._toggleMenuPositionClass();
                this._initSwipeHandlers();
                this._dimensionChanged()
            },
            _renderContentImpl: function() {
                this._renderMarkup();
                var menuTemplate = this._getTemplate(this.option("menuTemplate")),
                    contentTemplate = this._getTemplate(this.option("contentTemplate"));
                menuTemplate && menuTemplate.render({
                    container: this.menuContent()
                });
                contentTemplate && contentTemplate.render({
                    container: this.content(),
                    noModel: true
                })
            },
            _renderMarkup: function() {
                var $wrapper = $("<div>").addClass(SLIDEOUTVIEW_WRAPPER_CLASS);
                this._$menu = $("<div>").addClass(SLIDEOUTVIEW_MENU_CONTENT_CLASS);
                this._$container = $("<div>").addClass(SLIDEOUTVIEW_CONTENT_CLASS);
                $wrapper.append(this._$menu);
                $wrapper.append(this._$container);
                this.element().append($wrapper);
                this._$container.on("MSPointerDown", $.noop)
            },
            _renderShield: function() {
                this._$shield = this._$shield || $("<div>").addClass(SLIDEOUTVIEW_SHIELD_CLASS);
                this._$shield.appendTo(this.content());
                this._$shield.off(clickEvent.name).on(clickEvent.name, $.proxy(this.hideMenu, this));
                this._toggleShieldVisibility(this.option("menuVisible"))
            },
            _initSwipeHandlers: function() {
                this._createComponent(this.content(), Swipeable, {
                    disabled: !this.option("swipeEnabled"),
                    elastic: false,
                    itemSizeFunc: $.proxy(this._getMenuWidth, this),
                    onStart: $.proxy(this._swipeStartHandler, this),
                    onUpdated: $.proxy(this._swipeUpdateHandler, this),
                    onEnd: $.proxy(this._swipeEndHandler, this)
                })
            },
            _isRightMenuPosition: function() {
                var invertedPosition = "inverted" === this.option("menuPosition"),
                    rtl = this.option("rtlEnabled");
                return rtl && !invertedPosition || !rtl && invertedPosition
            },
            _swipeStartHandler: function(e) {
                animation.complete(this.content());
                var event = e.jQueryEvent,
                    menuVisible = this.option("menuVisible"),
                    rtl = this._isRightMenuPosition();
                event.maxLeftOffset = +(rtl ? !menuVisible : menuVisible);
                event.maxRightOffset = +(rtl ? menuVisible : !menuVisible);
                this._toggleShieldVisibility(true)
            },
            _swipeUpdateHandler: function(e) {
                var event = e.jQueryEvent,
                    offset = this.option("menuVisible") ? event.offset + 1 * this._getRTLSignCorrection() : event.offset;
                offset *= this._getRTLSignCorrection();
                this._renderPosition(offset, false)
            },
            _swipeEndHandler: function(e) {
                var targetOffset = e.jQueryEvent.targetOffset * this._getRTLSignCorrection() + this.option("menuVisible"),
                    menuVisible = 0 !== targetOffset;
                if (this.option("menuVisible") === menuVisible) {
                    this._renderPosition(this.option("menuVisible"), true)
                } else {
                    this.option("menuVisible", menuVisible)
                }
            },
            _toggleMenuPositionClass: function() {
                var left = SLIDEOUTVIEW_CLASS + "-left",
                    right = SLIDEOUTVIEW_CLASS + "-right",
                    menuPosition = this._isRightMenuPosition() ? "right" : "left";
                this._$menu.removeClass(left + " " + right);
                this._$menu.addClass(SLIDEOUTVIEW_CLASS + "-" + menuPosition)
            },
            _renderPosition: function(offset, animate) {
                var pos = this._calculatePixelOffset(offset) * this._getRTLSignCorrection();
                this._toggleHideMenuCallback(offset);
                if (animate) {
                    this._toggleShieldVisibility(true);
                    animation.moveTo(this.content(), pos, $.proxy(this._animationCompleteHandler, this))
                } else {
                    translator.move(this.content(), {
                        left: pos
                    })
                }
            },
            _calculatePixelOffset: function(offset) {
                offset = offset || 0;
                return offset * this._getMenuWidth()
            },
            _getMenuWidth: function() {
                if (!this._menuWidth) {
                    var maxMenuWidth = this.element().width() - this.option("contentOffset");
                    this.menuContent().css("max-width", maxMenuWidth);
                    var currentMenuWidth = this.menuContent().width();
                    this._menuWidth = Math.min(currentMenuWidth, maxMenuWidth)
                }
                return this._menuWidth
            },
            _animationCompleteHandler: function() {
                this._toggleShieldVisibility(this.option("menuVisible"));
                if (this._deferredAnimate) {
                    this._deferredAnimate.resolveWith(this)
                }
            },
            _toggleHideMenuCallback: function(subscribe) {
                if (subscribe) {
                    hideTopOverlayCallback.add(this._hideMenuHandler)
                } else {
                    hideTopOverlayCallback.remove(this._hideMenuHandler)
                }
            },
            _getRTLSignCorrection: function() {
                return this._isRightMenuPosition() ? -1 : 1
            },
            _dispose: function() {
                animation.complete(this.content());
                this._toggleHideMenuCallback(false);
                this.callBase()
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _dimensionChanged: function() {
                delete this._menuWidth;
                this._renderPosition(this.option("menuVisible"), false)
            },
            _toggleShieldVisibility: function(visible) {
                this._$shield.toggleClass(INVISIBLE_STATE_CLASS, !visible)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "width":
                        this.callBase(args);
                        this._dimensionChanged();
                        break;
                    case "contentOffset":
                        this._dimensionChanged();
                        break;
                    case "menuVisible":
                        this._renderPosition(args.value, true);
                        break;
                    case "menuPosition":
                        this._renderPosition(this.option("menuVisible"), true);
                        this._toggleMenuPositionClass();
                        break;
                    case "swipeEnabled":
                        this._initSwipeHandlers();
                        break;
                    case "contentTemplate":
                    case "menuTemplate":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            menuContent: function() {
                return this._$menu
            },
            content: function() {
                return this._$container
            },
            showMenu: function() {
                return this.toggleMenuVisibility(true)
            },
            hideMenu: function() {
                return this.toggleMenuVisibility(false)
            },
            toggleMenuVisibility: function(showing) {
                showing = void 0 === showing ? !this.option("menuVisible") : showing;
                this._deferredAnimate = $.Deferred();
                this.option("menuVisible", showing);
                return this._deferredAnimate.promise()
            }
        });
        registerComponent("dxSlideOutView", SlideOutView);
        module.exports = SlideOutView;
        module.exports.animation = animation
    },
    /*!******************************************************!*\
      !*** ./Scripts/bundles/modules/parts/widgets-web.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var data = __webpack_require__( /*! ./data */ 180);
        var ui = __webpack_require__( /*! ./widgets-base */ 4);
        ui.dxAccordion = __webpack_require__( /*! ../../../ui/accordion */ 326);
        ui.dxContextMenu = __webpack_require__( /*! ../../../ui/context_menu */ 327);
        ui.dxDataGrid = __webpack_require__( /*! ../../../ui/data_grid */ 334);
        ui.dxMenu = __webpack_require__( /*! ../../../ui/menu */ 368);
        ui.dxPivotGrid = __webpack_require__( /*! ../../../ui/pivot_grid */ 383);
        ui.dxPivotGridFieldChooser = __webpack_require__( /*! ../../../ui/pivot_grid_field_chooser */ 400);
        data.PivotGridDataSource = __webpack_require__( /*! ../../../ui/pivot_grid/data_source */ 387);
        data.XmlaStore = __webpack_require__( /*! ../../../ui/pivot_grid/xmla_store */ 401);
        ui.dxScheduler = __webpack_require__( /*! ../../../ui/scheduler */ 402);
        ui.dxTreeView = __webpack_require__( /*! ../../../ui/tree_view */ 356)
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/accordion.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            devices = __webpack_require__( /*! ../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            CollectionWidget = __webpack_require__( /*! ./collection/ui.collection_widget.edit */ 151);
        var ACCORDION_CLASS = "dx-accordion",
            ACCORDION_WRAPPER_CLASS = "dx-accordion-wrapper",
            ACCORDION_ITEM_CLASS = "dx-accordion-item",
            ACCORDION_ITEM_OPENED_CLASS = "dx-accordion-item-opened",
            ACCORDION_ITEM_CLOSED_CLASS = "dx-accordion-item-closed",
            ACCORDION_ITEM_TITLE_CLASS = "dx-accordion-item-title",
            ACCORDION_ITEM_BODY_CLASS = "dx-accordion-item-body",
            ACCORDION_ITEM_DATA_KEY = "dxAccordionItemData";
        var Accordion = CollectionWidget.inherit({
            _activeStateUnit: "." + ACCORDION_ITEM_CLASS,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    hoverStateEnabled: true,
                    height: void 0,
                    itemTitleTemplate: "title",
                    onItemTitleClick: null,
                    selectedIndex: 0,
                    collapsible: false,
                    multiple: false,
                    animationDuration: 300,
                    deferRendering: true,
                    selectionByClick: true,
                    activeStateEnabled: true,
                    _itemAttributes: {
                        role: "tab"
                    }
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _itemElements: function() {
                return this._itemContainer().children(this._itemSelector())
            },
            _init: function() {
                this.callBase();
                this.option("selectionRequired", !this.option("collapsible"));
                this.option("selectionMode", this.option("multiple") ? "multiple" : "single");
                var $element = this.element();
                $element.addClass(ACCORDION_CLASS);
                this._$container = $("<div>").addClass(ACCORDION_WRAPPER_CLASS);
                $element.append(this._$container)
            },
            _render: function() {
                this._deferredItems = [];
                this.callBase();
                this._fireContentReadyAction();
                this.setAria({
                    role: "tablist",
                    multiselectable: this.option("multiple")
                });
                this._attachItemTitleClickAction()
            },
            _renderContent: function() {
                this._renderContentImpl()
            },
            _itemDataKey: function() {
                return ACCORDION_ITEM_DATA_KEY
            },
            _itemClass: function() {
                return ACCORDION_ITEM_CLASS
            },
            _itemContainer: function() {
                return this._$container
            },
            _itemTitles: function() {
                return this._itemElements().find("." + ACCORDION_ITEM_TITLE_CLASS)
            },
            _itemContents: function() {
                return this._itemElements().find("." + ACCORDION_ITEM_BODY_CLASS)
            },
            _getItemData: function(target) {
                return $(target).parent().data(this._itemDataKey()) || this.callBase.apply(this, arguments)
            },
            _executeItemRenderAction: function(itemData, itemElement) {
                if (itemData.type) {
                    return
                }
                this.callBase.apply(this, arguments)
            },
            _itemSelectHandler: function(e) {
                if ($(e.target).closest(this._itemContents()).length) {
                    return
                }
                this.callBase.apply(this, arguments)
            },
            _renderItemContent: function(args) {
                var $itemTitle = this.callBase($.extend({}, args, {
                    contentClass: ACCORDION_ITEM_TITLE_CLASS,
                    templateProperty: "titleTemplate",
                    defaultTemplateName: this.option("itemTitleTemplate")
                }));
                var deferred = $.Deferred();
                this._deferredItems.push(deferred);
                if (!this.option("deferRendering")) {
                    deferred.resolve()
                }
                deferred.done($.proxy(this.callBase, this, $.extend({}, args, {
                    contentClass: ACCORDION_ITEM_BODY_CLASS,
                    container: $("<div>").appendTo($itemTitle.parent())
                })))
            },
            _attachItemTitleClickAction: function() {
                var itemSelector = "." + ACCORDION_ITEM_TITLE_CLASS,
                    eventName = eventUtils.addNamespace(clickEvent.name, this.NAME);
                this._itemContainer().off(eventName, itemSelector).on(eventName, itemSelector, $.proxy(this._itemTitleClickHandler, this))
            },
            _itemTitleClickHandler: function(e) {
                this._itemJQueryEventHandler(e, "onItemTitleClick")
            },
            _renderSelection: function(addedSelection, removedSelection) {
                this._itemElements().addClass(ACCORDION_ITEM_CLOSED_CLASS);
                this.setAria("hidden", true, this._itemContents());
                this._updateItems(addedSelection, removedSelection, true)
            },
            _updateSelection: function(addedSelection, removedSelection) {
                this._updateItems(addedSelection, removedSelection, false)
            },
            _updateItems: function(addedSelection, removedSelection, skipAnimation) {
                var $items = this._itemElements(),
                    that = this;
                $.each(addedSelection, function(_, index) {
                    that._deferredItems[index].resolve();
                    var $item = $items.eq(index).addClass(ACCORDION_ITEM_OPENED_CLASS).removeClass(ACCORDION_ITEM_CLOSED_CLASS);
                    that.setAria("hidden", false, $item.find("." + ACCORDION_ITEM_BODY_CLASS))
                });
                $.each(removedSelection, function(_, index) {
                    var $item = $items.eq(index).removeClass(ACCORDION_ITEM_OPENED_CLASS);
                    that.setAria("hidden", true, $item.find("." + ACCORDION_ITEM_BODY_CLASS))
                });
                this._updateItemHeights(skipAnimation)
            },
            _updateItemHeights: function(skipAnimation) {
                var that = this,
                    deferredAnimate = that._deferredAnimate,
                    itemHeight = this._splitFreeSpace(this._calculateFreeSpace());
                return $.when.apply($, $.map(this._itemElements(), function(item) {
                    return that._updateItemHeight($(item), itemHeight, skipAnimation)
                })).done(function() {
                    if (deferredAnimate) {
                        deferredAnimate.resolveWith(that)
                    }
                })
            },
            _updateItemHeight: function($item, itemHeight, skipAnimation) {
                var $title = $item.children("." + ACCORDION_ITEM_TITLE_CLASS);
                if (fx.isAnimating($item)) {
                    fx.stop($item)
                }
                var startItemHeight = $item.outerHeight(),
                    finalItemHeight = $item.hasClass(ACCORDION_ITEM_OPENED_CLASS) ? itemHeight + $title.outerHeight() || $item.height("auto").outerHeight() : $title.outerHeight();
                return this._animateItem($item, startItemHeight, finalItemHeight, skipAnimation, !!itemHeight)
            },
            _animateItem: function($element, startHeight, endHeight, skipAnimation, fixedHeight) {
                var d;
                if (skipAnimation || startHeight === endHeight) {
                    $element.css("height", endHeight);
                    d = $.Deferred().resolve()
                } else {
                    d = fx.animate($element, {
                        type: "custom",
                        from: {
                            height: startHeight
                        },
                        to: {
                            height: endHeight
                        },
                        duration: this.option("animationDuration")
                    })
                }
                return d.done(function() {
                    if ($element.hasClass(ACCORDION_ITEM_OPENED_CLASS) && !fixedHeight) {
                        $element.css("height", "")
                    }
                    $element.not("." + ACCORDION_ITEM_OPENED_CLASS).addClass(ACCORDION_ITEM_CLOSED_CLASS)
                })
            },
            _splitFreeSpace: function(freeSpace) {
                if (!freeSpace) {
                    return freeSpace
                }
                return freeSpace / this.option("selectedItems").length
            },
            _calculateFreeSpace: function() {
                var height = this.option("height");
                if (void 0 === height || "auto" === height) {
                    return
                }
                var $titles = this._itemTitles(),
                    itemsHeight = 0;
                $.each($titles, function(_, title) {
                    itemsHeight += $(title).outerHeight()
                });
                return this.element().height() - itemsHeight
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _dimensionChanged: function() {
                this._updateItemHeights(true)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "animationDuration":
                    case "onItemTitleClick":
                        break;
                    case "collapsible":
                        this.option("selectionRequired", !this.option("collapsible"));
                        break;
                    case "itemTitleTemplate":
                    case "height":
                    case "deferRendering":
                        this._invalidate();
                        break;
                    case "multiple":
                        this.option("selectionMode", args.value ? "multiple" : "single");
                        break;
                    default:
                        this.callBase(args)
                }
            },
            expandItem: function(index) {
                this._deferredAnimate = $.Deferred();
                this.selectItem(index);
                return this._deferredAnimate.promise()
            },
            collapseItem: function(index) {
                this._deferredAnimate = $.Deferred();
                this.unselectItem(index);
                return this._deferredAnimate.promise()
            },
            updateDimensions: function() {
                return this._updateItemHeights(false)
            }
        });
        registerComponent("dxAccordion", Accordion);
        module.exports = Accordion
    },
    /*!************************************!*\
      !*** ./Scripts/ui/context_menu.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./context_menu/ui.context_menu */ 328)
    },
    /*!****************************************************!*\
      !*** ./Scripts/ui/context_menu/ui.context_menu.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            fx = __webpack_require__( /*! ../../animation/fx */ 59),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            positionUtils = __webpack_require__( /*! ../../animation/position */ 61),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            contextmenuEvent = __webpack_require__( /*! ../../events/contextmenu */ 165),
            Overlay = __webpack_require__( /*! ../overlay */ 109),
            MenuBase = __webpack_require__( /*! ./ui.menu_base */ 329);
        var DX_MENU_CLASS = "dx-menu",
            DX_MENU_ITEM_CLASS = DX_MENU_CLASS + "-item",
            DX_MENU_ITEM_EXPANDED_CLASS = DX_MENU_ITEM_CLASS + "-expanded",
            DX_MENU_PHONE_CLASS = "dx-menu-phone-overlay",
            DX_MENU_ITEMS_CONTAINER_CLASS = DX_MENU_CLASS + "-items-container",
            DX_MENU_ITEM_WRAPPER_CLASS = DX_MENU_ITEM_CLASS + "-wrapper",
            DX_SUBMENU_CLASS = "dx-submenu",
            DX_CONTEXT_MENU_CLASS = "dx-context-menu",
            DX_HAS_CONTEXT_MENU_CLASS = "dx-has-context-menu",
            DX_STATE_DISABLED_CLASS = "dx-state-disabled",
            FOCUS_UP = "up",
            FOCUS_DOWN = "down",
            FOCUS_LEFT = "left",
            FOCUS_RIGHT = "right",
            FOCUS_FIRST = "first",
            FOCUS_LAST = "last",
            ACTIONS = ["onShowing", "onShown", "onHiding", "onHidden", "onPositioning", "onLeftFirstItem", "onLeftLastItem", "onCloseRootSubmenu", "onExpandLastSubmenu"],
            LOCAL_SUBMENU_DIRECTIONS = [FOCUS_UP, FOCUS_DOWN, FOCUS_FIRST, FOCUS_LAST];
        var ContextMenu = MenuBase.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    alternativeInvocationMode: {
                        enabled: false,
                        invokingElement: null
                    },
                    position: {
                        at: "top left",
                        my: "top left"
                    },
                    onShowing: null,
                    onShown: null,
                    onHiding: null,
                    onHidden: null,
                    onPositioning: null,
                    submenuDirection: "auto",
                    visible: false,
                    target: window,
                    onLeftFirstItem: null,
                    onLeftLastItem: null,
                    onCloseRootSubmenu: null,
                    onExpandLastSubmenu: null
                })
            },
            _initActions: function() {
                this._actions = {};
                $.each(ACTIONS, $.proxy(function(index, action) {
                    this._actions[action] = this._createActionByOption(action) || $.noop
                }, this))
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    animation: true,
                    selectedItem: true
                })
            },
            _focusInHandler: $.noop,
            _itemContainer: function() {
                return this._overlay ? this._overlay.content() : $()
            },
            _eventBindingTarget: function() {
                return this._itemContainer()
            },
            itemsContainer: function() {
                return this._overlay ? this._overlay.content() : void 0
            },
            _supportedKeys: function() {
                var selectItem = function(e) {
                    var $item = this.option("focusedElement");
                    this.hide();
                    if (!$item || !this._isSelectionEnabled()) {
                        return
                    }
                    this.selectItem($item[0])
                };
                return $.extend(this.callBase(), {
                    space: selectItem,
                    esc: this.hide
                })
            },
            _moveFocus: function(location) {
                var $newTarget, $items = this._getItemsByLocation(location),
                    $oldTarget = this._getActiveItem(true),
                    $focusedItem = this.option("focusedElement");
                switch (location) {
                    case FOCUS_UP:
                        $newTarget = $focusedItem ? this._prevItem($items) : $items.last();
                        if ($oldTarget.is($items.first())) {
                            this._actions.onLeftFirstItem($oldTarget)
                        }
                        break;
                    case FOCUS_DOWN:
                        $newTarget = $focusedItem ? this._nextItem($items) : $items.first();
                        if ($oldTarget.is($items.last())) {
                            this._actions.onLeftLastItem($oldTarget)
                        }
                        break;
                    case FOCUS_RIGHT:
                        $newTarget = this.option("rtlEnabled") ? this._hideSubmenuHandler($items) : this._expandSubmenuHandler($items, location);
                        break;
                    case FOCUS_LEFT:
                        $newTarget = this.option("rtlEnabled") ? this._expandSubmenuHandler($items, location) : this._hideSubmenuHandler($items);
                        break;
                    case FOCUS_FIRST:
                        $newTarget = $items.first();
                        break;
                    case FOCUS_LAST:
                        $newTarget = $items.last();
                        break;
                    default:
                        return this.callBase(location)
                }
                if (0 !== $newTarget.length) {
                    this.option("focusedElement", $newTarget)
                }
            },
            _getItemsByLocation: function(location) {
                var $items, $activeItem = this._getActiveItem(true),
                    expandedLocation = this.option("rtlEnabled") ? FOCUS_LEFT : FOCUS_RIGHT;
                if ($.inArray(location, LOCAL_SUBMENU_DIRECTIONS) >= 0) {
                    $items = $activeItem.closest("." + DX_MENU_ITEMS_CONTAINER_CLASS).children().children()
                } else {
                    $items = this._itemElements();
                    if (location !== expandedLocation) {
                        $items = $items.filter(":visible")
                    }
                }
                return $items
            },
            _getAriaTarget: function() {
                return this.element()
            },
            _refreshActiveDescendant: function() {
                if (!this._overlay) {
                    return
                }
                var id = this.getFocusedItemId();
                this.setAria("activedescendant", "", this._overlay.content());
                this.setAria("activedescendant", id, this._overlay.content())
            },
            _hideSubmenuHandler: function($items) {
                var $curItem = this._getActiveItem(true),
                    $parentItem = $curItem.parents("." + DX_MENU_ITEM_EXPANDED_CLASS).first();
                if ($parentItem.length) {
                    this._hideSubmenusOnSameLevel($parentItem);
                    this._hideSubmenu($curItem.closest("." + DX_SUBMENU_CLASS));
                    return $parentItem
                }
                this._actions.onCloseRootSubmenu($curItem);
                return $curItem
            },
            _expandSubmenuHandler: function($items, location) {
                var $curItem = this._getActiveItem(true),
                    node = this._dataAdapter.getNodeByItem(this._getItemData($curItem)),
                    isItemHasSubmenu = this._hasSubmenu(node),
                    $submenu = $curItem.children("." + DX_SUBMENU_CLASS);
                if (isItemHasSubmenu && !$curItem.hasClass(DX_STATE_DISABLED_CLASS)) {
                    if (!$submenu.length || "hidden" === $submenu.css("visibility")) {
                        this._showSubmenu($curItem)
                    }
                    return this._nextItem(this._getItemsByLocation(location))
                }
                this._actions.onExpandLastSubmenu($curItem);
                return $curItem
            },
            _clean: function() {
                if (this._overlay) {
                    this._overlay.element().remove();
                    this._overlay = null
                }
                this._detachShowContextMenuEvents($(this.option("target")));
                this.option("templatesRenderAsynchronously") && clearTimeout(this._drawSubmenuTimeout);
                this.callBase()
            },
            _render: function() {
                this.element().addClass(DX_HAS_CONTEXT_MENU_CLASS);
                this.callBase();
                this.setAria("role", "menu")
            },
            _renderContentImpl: function() {
                this._detachShowContextMenuEvents(this.option("target"));
                this._attachShowContextMenuEvents();
                this._attachInvokeContextMenuEvents()
            },
            _renderContextMenuOverlay: function() {
                if (this._overlay) {
                    return
                }
                var $overlayContent, overlayOptions = this._getOverlayOptions(),
                    $overlayElement = $("<div>");
                this._overlay = this._createComponent($overlayElement.appendTo(this._$element), Overlay, overlayOptions);
                $overlayContent = this._overlay.content();
                $overlayContent.addClass(DX_CONTEXT_MENU_CLASS);
                this._addCustomCssClass($overlayContent);
                this._addPlatformDependentClass($overlayContent);
                this._attachContextMenuEvent()
            },
            _itemContextMenuHandler: function(e) {
                this.callBase(e);
                e.stopPropagation()
            },
            _addPlatformDependentClass: function($element) {
                if (devices.current().phone) {
                    $element.addClass(DX_MENU_PHONE_CLASS)
                }
            },
            _detachShowContextMenuEvents: function(target) {
                var eventName = eventUtils.addNamespace(contextmenuEvent.name, this.NAME);
                if (this._showContextMenuEventHandler) {
                    $(document).off(eventName, this._getTargetSelector(target), this._showContextMenuEventHandler)
                } else {
                    $(target).off(eventName)
                }
            },
            _attachShowContextMenuEvents: function() {
                var that = this,
                    target = this.option("target"),
                    eventName = eventUtils.addNamespace(contextmenuEvent.name, this.NAME),
                    contextMenuAction = this._createAction($.proxy(function(e) {
                        if (!that.option("alternativeInvocationMode").enabled) {
                            that._show(e.jQueryEvent)
                        }
                    }, this), {
                        validatingTargetName: "target"
                    }),
                    handler = function(e) {
                        contextMenuAction({
                            jQueryEvent: e,
                            target: $(e.currentTarget)
                        })
                    };
                contextMenuAction = this._createAction(contextMenuAction);
                if (target instanceof $) {
                    this._showContextMenuEventHandler = void 0;
                    target.on(eventName, handler)
                } else {
                    this._showContextMenuEventHandler = handler;
                    $(document).on(eventName, target, this._showContextMenuEventHandler)
                }
            },
            _getTargetSelector: function(target) {
                return target instanceof $ ? target.selector : target
            },
            _attachInvokeContextMenuEvents: function() {
                var that = this,
                    eventName = eventUtils.addNamespace(clickEvent.name, this.NAME),
                    contextMenuAction = this._createAction($.proxy(function() {
                        that.toggle()
                    }, this), {
                        validatingTargetName: "target"
                    });
                if (this.option("alternativeInvocationMode").enabled && this._getInvokeTarget()) {
                    $(this._getInvokeTarget()).off(eventName).on(eventName, $.proxy(function(e) {
                        contextMenuAction({
                            jQueryEvent: e,
                            target: $(e.target)
                        })
                    }, this))
                }
            },
            _getInvokeTarget: function() {
                return this.option("alternativeInvocationMode").invokingElement
            },
            _hoverEndHandler: function(e) {
                e.stopPropagation()
            },
            _renderDimensions: $.noop,
            _renderContainer: function($wrapper, submenuContainer) {
                var $itemsContainer, $holder = submenuContainer || this._itemContainer();
                $wrapper = $("<div>");
                $wrapper.appendTo($holder).addClass(DX_SUBMENU_CLASS).css("visibility", submenuContainer ? "hidden" : "visible");
                $itemsContainer = this.callBase($wrapper);
                if (submenuContainer) {
                    return $itemsContainer
                }
                if (this.option("width")) {
                    return $itemsContainer.css("min-width", this.option("width"))
                }
                if (this.option("height")) {
                    return $itemsContainer.css("min-height", this.option("height"))
                }
                return $itemsContainer
            },
            _renderSubmenuItems: function(node, $itemFrame) {
                this._renderItems(this._getChildNodes(node), $itemFrame)
            },
            _getOverlayOptions: function() {
                var position = this.option("position"),
                    overlayAnimation = this.option("animation"),
                    overlayOptions = {
                        focusStateEnabled: this.option("focusStateEnabled"),
                        animation: overlayAnimation,
                        closeOnOutsideClick: $.proxy(this._closeOnOutsideClickHandler, this),
                        closeOnTargetScroll: true,
                        deferRendering: false,
                        position: {
                            at: position.at,
                            my: position.my,
                            of: this.option("target"),
                            collision: "fit"
                        },
                        shading: false,
                        showTitle: false,
                        height: "auto",
                        width: "auto",
                        visible: this.option("visible"),
                        onShown: $.proxy(this._overlayShownActionHandler, this),
                        onHiding: $.proxy(this._overlayHidingActionHandler, this),
                        onHidden: $.proxy(this._overlayHiddenActionHandler, this),
                        onPositioned: $.proxy(this._overlayPositionedActionHandler, this)
                    };
                return overlayOptions
            },
            _overlayShownActionHandler: function(arg) {
                this._actions.onShown(arg)
            },
            _overlayHidingActionHandler: function(arg) {
                this._actions.onHiding(arg);
                if (!arg.cancel) {
                    this._hideAllShownSubmenus();
                    this._setOptionSilent("visible", false)
                }
            },
            _overlayHiddenActionHandler: function(arg) {
                this._actions.onHidden(arg)
            },
            _overlayPositionedActionHandler: $.noop,
            _closeOnOutsideClickHandler: function(e) {
                var $clickedItem, $activeItemContainer, $itemContainers, $rootItem, isRootItemClicked, isInnerOverlayClicked, isInvokeTarget = $(e.target).closest(this._getInvokeTarget());
                if (e.target === document) {
                    return true
                }
                if (isInvokeTarget && isInvokeTarget.length) {
                    return false
                }
                $activeItemContainer = this._getActiveItemsContainer(e.target);
                $itemContainers = this._getItemsContainers();
                $clickedItem = this._searchActiveItem(e.target);
                $rootItem = this.element().parents("." + DX_MENU_ITEM_CLASS);
                isRootItemClicked = $clickedItem[0] === $rootItem[0] && $clickedItem.length && $rootItem.length;
                isInnerOverlayClicked = this._isIncludeOverlay($activeItemContainer, $itemContainers) && $clickedItem.length;
                if (isInnerOverlayClicked || isRootItemClicked) {
                    if ("onClick" === this._getShowSubmenuMode()) {
                        this._hideAllShownChildSubmenus($clickedItem)
                    }
                    return false
                }
                return true
            },
            _getActiveItemsContainer: function(target) {
                return $(target).closest("." + DX_MENU_ITEMS_CONTAINER_CLASS)
            },
            _getItemsContainers: function() {
                return this._overlay._$content.find("." + DX_MENU_ITEMS_CONTAINER_CLASS)
            },
            _searchActiveItem: function(target) {
                return $(target).closest("." + DX_MENU_ITEM_CLASS).eq(0)
            },
            _isIncludeOverlay: function($activeOverlay, $allOverlays) {
                var isSame = false;
                $.each($allOverlays, function(index, $overlay) {
                    if ($activeOverlay.is($overlay) && !isSame) {
                        isSame = true
                    }
                });
                return isSame
            },
            _hideAllShownChildSubmenus: function($clickedItem) {
                var $context, that = this,
                    $submenuElements = $clickedItem.find("." + DX_SUBMENU_CLASS),
                    shownSubmenus = $.extend([], this._shownSubmenus);
                if ($submenuElements.length > 0) {
                    $.each(shownSubmenus, function(index, $submenu) {
                        $context = that._searchActiveItem($submenu.context).parent();
                        if ($context.parent().is($clickedItem.parent().parent()) && !$context.is($clickedItem.parent())) {
                            that._hideSubmenu($submenu)
                        }
                    })
                }
            },
            _showSubmenu: function($item) {
                var isSubmenuVisible, node = this._dataAdapter.getNodeByItem(this._getItemData($item)),
                    isItemHasSubmenu = this._hasSubmenu(node);
                this._hideSubmenusOnSameLevel($item);
                if (isItemHasSubmenu) {
                    this.callBase($item);
                    if (!$item.children("." + DX_SUBMENU_CLASS).length) {
                        this._renderSubmenuItems(node, $item, 2)
                    }
                    isSubmenuVisible = this._isSubmenuVisible($item.children("." + DX_SUBMENU_CLASS));
                    if (!isSubmenuVisible) {
                        $item.addClass(DX_MENU_ITEM_EXPANDED_CLASS);
                        this._drawSubmenu($item)
                    }
                }
            },
            _hideSubmenusOnSameLevel: function($item) {
                var $expandedItems = $item.parent("." + DX_MENU_ITEM_WRAPPER_CLASS).siblings().find("." + DX_MENU_ITEM_EXPANDED_CLASS);
                if ($expandedItems.length) {
                    $expandedItems.removeClass(DX_MENU_ITEM_EXPANDED_CLASS);
                    this._hideSubmenu($expandedItems.find("." + DX_SUBMENU_CLASS))
                }
            },
            _hideSubmenuGroup: function($submenu) {
                if (this._isSubmenuVisible($submenu)) {
                    this._hideSubmenuCore($submenu)
                }
            },
            _isSubmenuVisible: function($submenu) {
                return "visible" === $submenu.css("visibility")
            },
            _drawSubmenu: function($itemElement) {
                var animation = this.option("animation") ? this.option("animation").show : {},
                    $submenu = $itemElement.children("." + DX_SUBMENU_CLASS),
                    submenuPosition = this._getSubmenuPosition($itemElement);
                if (this._overlay && this._overlay.option("visible")) {
                    if (!commonUtils.isDefined(this._shownSubmenus)) {
                        this._shownSubmenus = []
                    }
                    if ($.inArray($submenu, this._shownSubmenus)) {
                        this._shownSubmenus.push($submenu)
                    }
                    if (this.option("templatesRenderAsynchronously")) {
                        this._drawSubmenuTimeout = setTimeout(function() {
                            positionUtils.setup($submenu, submenuPosition)
                        })
                    } else {
                        positionUtils.setup($submenu, submenuPosition)
                    }
                    if (animation) {
                        if ($.isPlainObject(animation.to)) {
                            animation.to.position = submenuPosition
                        }
                        this._animate($submenu, animation)
                    }
                    $submenu.css("visibility", "visible")
                }
            },
            _animate: function($container, options) {
                fx.animate($container, options)
            },
            _getSubmenuPosition: function($rootItem) {
                var submenuDirection = this.option("submenuDirection").toLowerCase(),
                    $rootItemWrapper = $rootItem.parent("." + DX_MENU_ITEM_WRAPPER_CLASS),
                    position = {
                        collision: "flip",
                        of: $rootItemWrapper,
                        offset: {
                            h: 0,
                            v: -1
                        }
                    };
                switch (submenuDirection) {
                    case "left":
                        position.at = "left top";
                        position.my = "right top";
                        break;
                    case "right":
                        position.at = "right top";
                        position.my = "left top";
                        break;
                    default:
                        if (this.option("rtlEnabled")) {
                            position.at = "left top";
                            position.my = "right top"
                        } else {
                            position.at = "right top";
                            position.my = "left top"
                        }
                }
                return position
            },
            _updateSubmenuVisibilityOnClick: function(actionArgs) {
                var $itemElement, itemData, node, renderSubmenu, $submenuElement, notCloseMenuOnItemClick;
                if (!actionArgs.args.length) {
                    return
                }
                actionArgs.args[0].jQueryEvent.stopPropagation();
                $itemElement = actionArgs.args[0].itemElement;
                itemData = actionArgs.args[0].itemData;
                node = this._dataAdapter.getNodeByItem(itemData);
                if (!node) {
                    return
                }
                renderSubmenu = node.internalFields.childrenKeys.length && !$itemElement.find("." + DX_SUBMENU_CLASS).length;
                renderSubmenu && this._renderSubmenuItems(node, $itemElement, 2);
                notCloseMenuOnItemClick = itemData && false === itemData.closeMenuOnClick;
                $submenuElement = $itemElement.children("." + DX_SUBMENU_CLASS);
                if ($itemElement.context === $submenuElement.context && "visible" === $submenuElement.css("visibility")) {
                    return
                }
                if (!itemData || itemData.disabled || notCloseMenuOnItemClick) {
                    return
                }
                this._updateSelectedItemOnClick(actionArgs);
                if (0 === $submenuElement.length) {
                    var $prevSubmenu = $($itemElement.parents("." + DX_SUBMENU_CLASS)[0]);
                    this._hideSubmenu($prevSubmenu);
                    if (!actionArgs.canceled && this._overlay && this._overlay.option("visible")) {
                        this.option("visible", false)
                    }
                } else {
                    if (this._shownSubmenus && this._shownSubmenus.length > 0) {
                        if (this._shownSubmenus[0].is($submenuElement) || 1 === this._shownSubmenus[0].has($submenuElement).length) {
                            this._hideSubmenu($submenuElement)
                        } else {
                            this._hideAllShownSubmenus()
                        }
                    }
                    this._showSubmenu($itemElement)
                }
            },
            _hideSubmenu: function($curSubmenu) {
                var that = this,
                    shownSubmenus = $.extend([], that._shownSubmenus);
                $.each(shownSubmenus, function(index, $submenu) {
                    if ($curSubmenu.is($submenu) || $curSubmenu.has($submenu).length) {
                        $submenu.parent().removeClass(DX_MENU_ITEM_EXPANDED_CLASS);
                        that._hideSubmenuCore($submenu)
                    }
                })
            },
            _hideSubmenuCore: function($submenu) {
                var index = $.inArray($submenu, this._shownSubmenus),
                    animation = this.option("animation") ? this.option("animation").hide : null;
                if (index >= 0) {
                    this._shownSubmenus.splice(index, 1)
                }
                this._stopAnimate($submenu);
                animation && this._animate($submenu, animation);
                $submenu.css("visibility", "hidden")
            },
            _stopAnimate: function($container) {
                fx.stop($container, true)
            },
            _hideAllShownSubmenus: function() {
                var that = this,
                    shownSubmenus = $.extend([], that._shownSubmenus),
                    $expandedItems = this._overlay.content().find("." + DX_MENU_ITEM_EXPANDED_CLASS);
                $expandedItems.removeClass(DX_MENU_ITEM_EXPANDED_CLASS);
                $.each(shownSubmenus, function(_, $submenu) {
                    that._hideSubmenuCore($submenu)
                })
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._detachShowContextMenuEvents(this.option("target"));
                    this._attachShowContextMenuEvents();
                    this._attachInvokeContextMenuEvents()
                }
            },
            _optionChanged: function(args) {
                if (this._cancelOptionChange === args.name) {
                    return
                }
                if ($.inArray(args.name, ACTIONS) > -1) {
                    this._initActions();
                    return
                }
                switch (args.name) {
                    case "visible":
                        this._toggleVisibility(args.value);
                        break;
                    case "alternativeInvocationMode":
                    case "position":
                    case "submenuDirection":
                        this._invalidate();
                        break;
                    case "target":
                        args.previousValue && this._detachShowContextMenuEvents(args.previousValue);
                        this.option("position").of = null;
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _toggleVisibility: function(showing) {
                showing ? this._show() : this._hide()
            },
            _show: function(jQEvent, position) {
                var args = {
                    jQEvent: jQEvent
                };
                !position && this._actions.onShowing(args);
                if (args.cancel) {
                    return $.Deferred().reject().promise()
                }
                var promise, id = new Guid;
                position = position || this._positionContextMenu(jQEvent);
                if (position) {
                    if (this._overlay) {
                        this._setOptionSilent("visible", true);
                        this._overlay.option("position", position);
                        promise = this._overlay.show();
                        this._overlay.content().attr({
                            id: id,
                            role: "menu"
                        });
                        this.setAria("owns", id)
                    } else {
                        this._renderContextMenuOverlay();
                        this._overlay.content().addClass(this._widgetClass());
                        this._renderFocusState();
                        this._attachHoverEvents();
                        this._attachClickEvent();
                        this._renderItems(this._dataAdapter.getRootNodes());
                        this._show(jQEvent, position)
                    }
                }
                return promise || $.Deferred().reject().promise()
            },
            _positionContextMenu: function(jQEvent) {
                var actionArgs, position = this.option("position"),
                    positioningAction = this._createActionByOption("onPositioning", actionArgs);
                if (jQEvent && jQEvent.preventDefault) {
                    position = {
                        at: "top left",
                        my: "top left",
                        of: jQEvent
                    }
                }
                if (!position.of) {
                    position.of = this.option("target")
                }
                actionArgs = {
                    position: position,
                    jQueryEvent: jQEvent
                };
                positioningAction(actionArgs);
                if (actionArgs.cancel) {
                    position = null
                } else {
                    if (actionArgs.jQueryEvent) {
                        actionArgs.jQueryEvent.cancel = true;
                        jQEvent.preventDefault()
                    }
                }
                return position
            },
            _hide: function() {
                var promise;
                if (this._overlay) {
                    this._overlay.content().removeAttr("id");
                    promise = this._overlay.hide();
                    this._setOptionSilent("visible", false)
                }
                this.setAria("owns", void 0);
                return promise || $.Deferred().reject().promise()
            },
            toggle: function(showing) {
                var visible = this.option("visible");
                showing = void 0 === showing ? !visible : showing;
                return showing ? this._show() : this._hide()
            },
            show: function() {
                return this.toggle(true)
            },
            hide: function() {
                return this.toggle(false)
            }
        });
        registerComponent("dxContextMenu", ContextMenu);
        module.exports = ContextMenu
    },
    /*!*************************************************!*\
      !*** ./Scripts/ui/context_menu/ui.menu_base.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            inkRipple = __webpack_require__( /*! ../widget/utils.ink_ripple */ 197),
            HierarchicalCollectionWidget = __webpack_require__( /*! ../hierarchical_collection/ui.hierarchical_collection_widget */ 330),
            MenuBaseEditStrategy = __webpack_require__( /*! ./ui.menu_base.edit.strategy */ 333),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            themes = __webpack_require__( /*! ../themes */ 143);
        var DX_MENU_CLASS = "dx-menu",
            DX_MENU_NO_ICONS_CLASS = DX_MENU_CLASS + "-no-icons",
            DX_MENU_BASE_CLASS = "dx-menu-base",
            ITEM_CLASS = DX_MENU_CLASS + "-item",
            DX_MENU_SELECTED_ITEM_CLASS = ITEM_CLASS + "-selected",
            DX_MENU_ITEM_WRAPPER_CLASS = ITEM_CLASS + "-wrapper",
            DX_MENU_ITEMS_CONTAINER_CLASS = DX_MENU_CLASS + "-items-container",
            DX_MENU_ITEM_EXPANDED_CLASS = ITEM_CLASS + "-expanded",
            DX_MENU_SEPARATOR_CLASS = DX_MENU_CLASS + "-separator",
            DX_MENU_ITEM_LAST_GROUP_ITEM = DX_MENU_CLASS + "-last-group-item",
            DX_ITEM_HAS_TEXT = ITEM_CLASS + "-has-text",
            DX_ITEM_HAS_ICON = ITEM_CLASS + "-has-icon",
            DX_ITEM_HAS_SUBMENU = ITEM_CLASS + "-has-submenu",
            DX_MENU_ITEM_POPOUT_CLASS = ITEM_CLASS + "-popout",
            DX_MENU_ITEM_POPOUT_CONTAINER_CLASS = DX_MENU_ITEM_POPOUT_CLASS + "-container",
            DX_MENU_ITEM_CAPTION_CLASS = ITEM_CLASS + "-text",
            SINGLE_SELECTION_MODE = "single",
            DEFAULT_DELAY = {
                show: 50,
                hide: 300
            };
        var MenuBase = HierarchicalCollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    items: [],
                    cssClass: "",
                    activeStateEnabled: true,
                    showSubmenuMode: {
                        name: "onHover",
                        delay: {
                            show: 50,
                            hide: 300
                        }
                    },
                    animation: {
                        show: {
                            type: "fade",
                            from: 0,
                            to: 1,
                            duration: 100
                        },
                        hide: {
                            type: "fade",
                            from: 1,
                            to: 0,
                            duration: 100
                        }
                    },
                    selectByClick: false,
                    focusOnSelectedItem: false,
                    _itemAttributes: {
                        role: "menuitem"
                    },
                    useInkRipple: false
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    selectionByClick: {
                        since: "16.1",
                        alias: "selectByClick"
                    }
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function() {
                        return /android5/.test(themes.current())
                    },
                    options: {
                        useInkRipple: true
                    }
                }])
            },
            _activeStateUnit: "." + ITEM_CLASS,
            _itemDataKey: function() {
                return "dxMenuItemDataKey"
            },
            _itemClass: function() {
                return ITEM_CLASS
            },
            _setAriaSelected: $.noop,
            _selectedItemClass: function() {
                return DX_MENU_SELECTED_ITEM_CLASS
            },
            _widgetClass: function() {
                return DX_MENU_BASE_CLASS
            },
            _focusTarget: function() {
                return this._itemContainer()
            },
            _supportedKeys: function() {
                var selectItem = function(e) {
                    var $item = this.option("focusedElement");
                    if (!$item || !this._isSelectionEnabled()) {
                        return
                    }
                    this.selectItem($item[0])
                };
                return $.extend(this.callBase(), {
                    space: selectItem,
                    pageUp: $.noop,
                    pageDown: $.noop
                })
            },
            _isSelectionEnabled: function() {
                return this.option("selectionMode") === SINGLE_SELECTION_MODE
            },
            _init: function() {
                this.callBase();
                this._renderSelectedItem();
                this._initActions()
            },
            _useCustomExpressions: function() {
                return this.callBase() || "items" !== this.option("itemsExpr")
            },
            _getTextContainer: function(itemData) {
                var itemText = this._displayGetter(itemData),
                    $itemContainer = $("<span>").addClass(DX_MENU_ITEM_CAPTION_CLASS),
                    itemContent = $.isPlainObject(itemData) ? itemText : String(itemData);
                return itemText && $itemContainer.html(itemContent)
            },
            _getPopoutContainer: function(itemData) {
                var $popOutContainer, items = this._itemsGetter(itemData);
                if (items && items.length) {
                    var $popOutImage = $("<div>").addClass(DX_MENU_ITEM_POPOUT_CLASS);
                    $popOutContainer = $("<span>").addClass(DX_MENU_ITEM_POPOUT_CONTAINER_CLASS).append($popOutImage)
                }
                return $popOutContainer
            },
            _getDataAdapterOptions: function() {
                return {
                    rootValue: 0,
                    multipleSelection: false,
                    recursiveSelection: false,
                    recursiveExpansion: false,
                    searchValue: ""
                }
            },
            _selectByItem: function(selectedItem) {
                if (!selectedItem) {
                    return
                }
                var nodeToSelect = this._dataAdapter.getNodeByItem(selectedItem);
                this._dataAdapter.toggleSelection(nodeToSelect.internalFields.key, true)
            },
            _renderSelectedItem: function() {
                var selectedKeys = this._dataAdapter.getSelectedNodesKeys(),
                    selectedKey = selectedKeys.length && selectedKeys[0],
                    selectedItem = this.option("selectedItem");
                if (!selectedKey) {
                    this._selectByItem(selectedItem);
                    return
                }
                var node = this._dataAdapter.getNodeByKey(selectedKey);
                if (false === node.selectable) {
                    return
                }
                if (!selectedItem) {
                    this.option("selectedItem", node.internalFields.item);
                    return
                }
                if (selectedItem !== node.internalFields.item) {
                    this._dataAdapter.toggleSelection(selectedKey, false);
                    this._selectByItem(selectedItem)
                }
            },
            _initActions: $.noop,
            _render: function() {
                this.callBase();
                this._addCustomCssClass(this.element());
                this.option("useInkRipple") && this._renderInkRipple()
            },
            _renderInkRipple: function() {
                this._inkRipple = inkRipple.render()
            },
            _toggleActiveState: function($element, value, e) {
                this.callBase.apply(this, arguments);
                if (!this._inkRipple) {
                    return
                }
                var config = {
                    element: $element,
                    jQueryEvent: e
                };
                if (value) {
                    this._inkRipple.showWave(config)
                } else {
                    this._inkRipple.hideWave(config)
                }
            },
            _getShowSubmenuMode: function() {
                var defaultValue = "onClick",
                    optionValue = this.option("showSubmenuMode");
                optionValue = commonUtils.isObject(optionValue) ? optionValue.name : optionValue;
                return this._isDesktopDevice() ? optionValue : defaultValue
            },
            _initSelectedItems: $.noop,
            _isDesktopDevice: function() {
                return "desktop" === devices.real().deviceType
            },
            _initEditStrategy: function() {
                var Strategy = MenuBaseEditStrategy;
                this._editStrategy = new Strategy(this)
            },
            _addCustomCssClass: function($element) {
                $element.addClass(this.option("cssClass"))
            },
            _itemWrapperSelector: function() {
                return "." + DX_MENU_ITEM_WRAPPER_CLASS
            },
            _hoverStartHandler: function(e) {
                var that = this,
                    $itemElement = that._getItemElementByEventArgs(e);
                if (!$itemElement || that._isItemDisabled($itemElement)) {
                    return
                }
                e.stopPropagation();
                that.option("focusedElement", $itemElement);
                if ("onHover" === that._getShowSubmenuMode()) {
                    this._showSubmenusTimeout = setTimeout($.proxy(that._showSubmenu, that, $itemElement), that._getSubmenuDelay("show"))
                }
            },
            _isItemDisabled: function($item) {
                return this._disabledGetter($item.data(this._itemDataKey()))
            },
            _showSubmenu: function($itemElement) {
                clearTimeout(this._showSubmenusTimeout);
                if (this._hasFocusClass($itemElement)) {
                    this._addExpandedClass($itemElement)
                }
            },
            _addExpandedClass: function($itemElement) {
                $itemElement.addClass(DX_MENU_ITEM_EXPANDED_CLASS)
            },
            _getSubmenuDelay: function(action) {
                var delay = this.option("showSubmenuMode").delay;
                if (!commonUtils.isDefined(delay)) {
                    return DEFAULT_DELAY[action]
                }
                return commonUtils.isObject(delay) ? delay[action] : delay
            },
            _getItemElementByEventArgs: function(eventArgs) {
                var $target = $(eventArgs.target);
                if ($target.hasClass(this._itemClass()) || $target.get(0) === eventArgs.currentTarget) {
                    return $target
                }
                while (!$target.hasClass(this._itemClass())) {
                    $target = $target.parent();
                    if ($target.hasClass("dx-submenu")) {
                        return null
                    }
                }
                return $target
            },
            _hoverEndHandler: $.noop,
            _hasSubmenu: function(node) {
                return node.internalFields.childrenKeys.length
            },
            _renderContentImpl: function() {
                this._renderItems(this._dataAdapter.getRootNodes())
            },
            _renderItems: function(nodes, submenuContainer) {
                var $nodeContainer, that = this;
                if (nodes.length) {
                    this.hasIcons = false;
                    $nodeContainer = this._renderContainer(this.element(), submenuContainer);
                    $.each(nodes, function(index, node) {
                        that._renderItem(index, node, $nodeContainer)
                    });
                    if (!this.hasIcons) {
                        $nodeContainer.addClass(DX_MENU_NO_ICONS_CLASS)
                    }
                }
            },
            _renderContainer: function($wrapper) {
                return $("<ul>").appendTo($wrapper).addClass(DX_MENU_ITEMS_CONTAINER_CLASS)
            },
            _createDOMElement: function($nodeContainer) {
                var $node = $("<li>").appendTo($nodeContainer).addClass(DX_MENU_ITEM_WRAPPER_CLASS);
                return $node
            },
            _renderItem: function(index, node, $nodeContainer) {
                var $itemFrame, items = this.option("items");
                this._renderSeparator(node, index, $nodeContainer);
                if (false === node.internalFields.item.visible) {
                    return
                }
                var $node = this._createDOMElement($nodeContainer);
                if (items[index + 1] && items[index + 1].beginGroup) {
                    $node.addClass(DX_MENU_ITEM_LAST_GROUP_ITEM)
                }
                $itemFrame = this.callBase(index, node.internalFields.item, $node);
                if (node.internalFields.item === this.option("selectedItem")) {
                    $itemFrame.addClass(DX_MENU_SELECTED_ITEM_CLASS)
                }
                this._addContentClasses(node, $itemFrame);
                if (this._hasSubmenu(node)) {
                    this.setAria("haspopup", "true", $itemFrame)
                }
            },
            _addContentClasses: function(node, $itemFrame) {
                if (this._displayGetter(node)) {
                    $itemFrame.addClass(DX_ITEM_HAS_TEXT)
                }
                if (node.icon || node.iconSrc) {
                    $itemFrame.addClass(DX_ITEM_HAS_ICON);
                    this.hasIcons = true
                }
                if (this._hasSubmenu(node)) {
                    $itemFrame.addClass(DX_ITEM_HAS_SUBMENU)
                }
            },
            _postprocessRenderItem: function(args) {
                var node, $itemElement = $(args.itemElement),
                    selectedIndex = this._dataAdapter.getSelectedNodesKeys();
                if (!selectedIndex.length || !this._selectedGetter(args.itemData) || !this._isItemSelectable(args.itemData)) {
                    this._setAriaSelected($itemElement, "false");
                    return
                }
                node = this._dataAdapter.getNodeByItem(args.itemData);
                if (node.internalFields.key === selectedIndex[0]) {
                    $itemElement.addClass(this._selectedItemClass());
                    this._setAriaSelected($itemElement, "true")
                } else {
                    this._setAriaSelected($itemElement, "false")
                }
            },
            _isItemSelectable: function(item) {
                return false !== item.selectable
            },
            _renderSeparator: function(node, index, $itemsContainer) {
                if (node.beginGroup && index > 0) {
                    this._needSeparate = true
                }
                if (false !== node.visible && this._needSeparate) {
                    $("<li>").appendTo($itemsContainer).addClass(DX_MENU_SEPARATOR_CLASS);
                    this._needSeparate = false
                }
            },
            _itemClickHandler: function(e) {
                var itemClickActionHandler = this._createAction($.proxy(this._updateSubmenuVisibilityOnClick, this));
                this._itemJQueryEventHandler(e, "onItemClick", {}, {
                    afterExecute: $.proxy(itemClickActionHandler, this)
                })
            },
            _updateSubmenuVisibilityOnClick: function(actionArgs) {
                this._updateSelectedItemOnClick(actionArgs);
                if ("onClick" === this._getShowSubmenuMode()) {
                    this._addExpandedClass(actionArgs.args[0].itemElement)
                }
            },
            _updateSelectedItemOnClick: function(actionArgs) {
                var selectedItemKey, args = actionArgs.args ? actionArgs.args[0] : actionArgs;
                if (!this._isItemSelectionAllowed(args.itemData)) {
                    return
                }
                selectedItemKey = this._dataAdapter.getSelectedNodesKeys();
                var selectedNode = selectedItemKey.length && this._dataAdapter.getNodeByKey(selectedItemKey[0]);
                if (selectedNode) {
                    this._toggleItemSelection(selectedNode, false)
                }
                if (!selectedNode || selectedNode.internalFields.item !== args.itemData) {
                    this.selectItem(args.itemData)
                } else {
                    this._fireSelectionChangeEvent(null, this.option("selectedItem"));
                    this._setOptionSilent("selectedItem", null)
                }
            },
            _isItemSelectionAllowed: function(item) {
                var isSelectionByClickEnabled = this._isSelectionEnabled() && this.option("selectByClick");
                return !this._isContainerEmpty() && isSelectionByClickEnabled && this._isItemSelectable(item) && !this._itemsGetter(item)
            },
            _isContainerEmpty: function() {
                return this._itemContainer().is(":empty")
            },
            _syncSelectionOptions: $.noop,
            _optionChanged: function(args) {
                if (this._cancelOptionChange === args.name) {
                    return
                }
                switch (args.name) {
                    case "showSubmenuMode":
                        break;
                    case "selectedItem":
                        var itemData = args.value,
                            node = this._dataAdapter.getNodeByItem(itemData),
                            selectedKey = this._dataAdapter.getSelectedNodesKeys()[0];
                        if (node && node.internalFields.key !== selectedKey) {
                            if (false === node.selectable) {
                                break
                            }
                            if (selectedKey) {
                                this._toggleItemSelection(this._dataAdapter.getNodeByKey(selectedKey), false)
                            }
                            this._toggleItemSelection(node, true);
                            this._updateSelectedItems()
                        }
                        break;
                    case "cssClass":
                    case "position":
                    case "selectByClick":
                    case "animation":
                    case "useInkRipple":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _toggleItemSelection: function(node, value) {
                var itemElement = this._getElementByItem(node.internalFields.item);
                itemElement && $(itemElement).toggleClass(DX_MENU_SELECTED_ITEM_CLASS);
                this._dataAdapter.toggleSelection(node.internalFields.key, value)
            },
            _getElementByItem: function(itemData) {
                var result, that = this;
                $.each(this._itemContainer().find("." + ITEM_CLASS), function(_, itemElement) {
                    if ($(itemElement).data(that._itemDataKey()) !== itemData) {
                        return true
                    }
                    result = itemElement;
                    return false
                });
                return result
            },
            _updateSelectedItems: function(oldSelection, newSelection) {
                if (oldSelection || newSelection) {
                    this._updateSelection(newSelection, oldSelection);
                    this._fireSelectionChangeEvent(newSelection, oldSelection)
                }
            },
            _fireSelectionChangeEvent: function(addedSelection, removedSelection) {
                this._createActionByOption("onSelectionChanged", {
                    excludeValidators: ["disabled", "readOnly"]
                })({
                    addedItems: [addedSelection],
                    removedItems: [removedSelection]
                })
            },
            selectItem: function(itemElement) {
                var itemData = itemElement.nodeType ? this._getItemData(itemElement) : itemElement,
                    node = this._dataAdapter.getNodeByItem(itemData),
                    selectedKey = this._dataAdapter.getSelectedNodesKeys()[0],
                    selectedItem = this.option("selectedItem");
                if (node.internalFields.key !== selectedKey) {
                    if (selectedKey) {
                        this._toggleItemSelection(this._dataAdapter.getNodeByKey(selectedKey), false)
                    }
                    this._toggleItemSelection(node, true);
                    this._updateSelectedItems(selectedItem, itemData);
                    this._setOptionSilent("selectedItem", itemData)
                }
            },
            unselectItem: function(itemElement) {
                var itemData = itemElement.nodeType ? this._getItemData(itemElement) : itemElement,
                    node = this._dataAdapter.getNodeByItem(itemData),
                    selectedItem = this.option("selectedItem");
                if (node.internalFields.selected) {
                    this._toggleItemSelection(node, false);
                    this._updateSelectedItems(selectedItem, null);
                    this._setOptionSilent("selectedItem", null)
                }
            }
        });
        MenuBase.publicName("dxMenuBase");
        module.exports = MenuBase
    },
    /*!*********************************************************************************!*\
      !*** ./Scripts/ui/hierarchical_collection/ui.hierarchical_collection_widget.js ***!
      \*********************************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dataCoreUtils = __webpack_require__( /*! ../../core/utils/data */ 36),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            FunctionTemplate = __webpack_require__( /*! ../widget/ui.template.function */ 97),
            iconUtils = __webpack_require__( /*! ../../core/utils/icon */ 99),
            HierarchicalDataAdapter = __webpack_require__( /*! ./ui.data_adapter */ 331),
            CollectionWidget = __webpack_require__( /*! ../collection/ui.collection_widget.edit */ 151);
        var DISABLED_STATE_CLASS = "dx-state-disabled";
        var HierarchicalCollectionWidget = CollectionWidget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    keyExpr: "id",
                    displayExpr: "text",
                    selectedExpr: "selected",
                    disabledExpr: "disabled",
                    itemsExpr: "items",
                    hoverStateEnabled: true,
                    parentIdExpr: "parentId",
                    expandedExpr: "expanded"
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }])
            },
            _init: function() {
                this.callBase();
                this._initAccessors();
                this._initDataAdapter();
                this._initDynamicTemplates()
            },
            _initDataSource: function() {
                this.callBase();
                this._dataSource && this._dataSource.paginate(false)
            },
            _initDataAdapter: function() {
                var accessors = this._createDataAdapterAccessors();
                this._dataAdapter = new HierarchicalDataAdapter($.extend({
                    dataAccessors: {
                        getters: accessors.getters,
                        setters: accessors.setters
                    },
                    items: this.option("items")
                }, this._getDataAdapterOptions()))
            },
            _getDataAdapterOptions: $.noop,
            _initDynamicTemplates: function() {
                if (!this._useCustomExpressions()) {
                    delete this._dynamicTemplates.item;
                    return
                }
                this._dynamicTemplates.item = new FunctionTemplate($.proxy(function(itemData) {
                    return $("<div>").append(this._getIconContainer(itemData)).append(this._getTextContainer(itemData)).append(this._getPopoutContainer(itemData))
                }, this))
            },
            _useCustomExpressions: function() {
                return "text" !== this.option("displayExpr") && "html" !== this.option("displayExpr")
            },
            _getIconContainer: function(itemData) {
                var icon = itemData.icon || itemData.iconSrc;
                return icon ? iconUtils.getImageContainer(icon) : void 0
            },
            _getTextContainer: function(itemData) {
                return $("<span>").text(this._displayGetter(itemData))
            },
            _getPopoutContainer: $.noop,
            _initAccessors: function() {
                var that = this;
                $.each(this._getAccessors(), function(_, accessor) {
                    that._compileAccessor(accessor)
                })
            },
            _getAccessors: function() {
                return ["key", "display", "selected", "items", "disabled", "parentId", "expanded"]
            },
            _getChildNodes: function(node) {
                var that = this,
                    arr = [];
                $.each(node.internalFields.childrenKeys, function(_, key) {
                    var childNode = that._dataAdapter.getNodeByKey(key);
                    arr.push(childNode)
                });
                return arr
            },
            _hasChildren: function(node) {
                return node && node.internalFields.childrenKeys.length
            },
            _compileAccessor: function(optionName) {
                var getter = "_" + optionName + "Getter",
                    setter = "_" + optionName + "Setter",
                    optionExpr = this.option(optionName + "Expr");
                if ($.isFunction(optionExpr)) {
                    this[setter] = function(obj, value) {
                        obj[optionExpr()] = value
                    };
                    this[getter] = function(obj) {
                        return obj[optionExpr()]
                    };
                    return
                }
                this[getter] = dataCoreUtils.compileGetter(optionExpr);
                this[setter] = dataCoreUtils.compileSetter(optionExpr)
            },
            _createDataAdapterAccessors: function() {
                var that = this,
                    accessors = {
                        getters: {},
                        setters: {}
                    };
                $.each(this._getAccessors(), function(_, accessor) {
                    var getterName = "_" + accessor + "Getter",
                        setterName = "_" + accessor + "Setter",
                        newAccessor = "parentId" === accessor ? "parentKey" : accessor;
                    accessors.getters[newAccessor] = that[getterName];
                    accessors.setters[newAccessor] = that[setterName]
                });
                return accessors
            },
            _render: function() {
                this.callBase();
                this._focusTarget().addClass(this._widgetClass())
            },
            _widgetClass: $.noop,
            _renderItemFrame: function(index, itemData) {
                var $itemFrame = this.callBase.apply(this, arguments);
                $itemFrame.toggleClass(DISABLED_STATE_CLASS, !!this._disabledGetter(itemData));
                return $itemFrame
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "displayExpr":
                    case "keyExpr":
                        if (!this._dynamicTemplates.item) {
                            this._initDynamicTemplates()
                        }
                        this._initAccessors();
                        this.repaint();
                        break;
                    case "itemsExpr":
                    case "selectedExpr":
                    case "disabledExpr":
                    case "expandedExpr":
                    case "parentIdExpr":
                        this._initAccessors();
                        this._initDataAdapter();
                        this.repaint();
                        break;
                    case "items":
                        this._initDataAdapter();
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        });
        module.exports = HierarchicalCollectionWidget
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/hierarchical_collection/ui.data_adapter.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            query = __webpack_require__( /*! ../../data/query */ 158),
            HierarchicalDataConverter = __webpack_require__( /*! ./ui.data_converter */ 332);
        var EXPANDED = "expanded",
            SELECTED = "selected",
            DISABLED = "disabled";
        var DataAdapter = Class.inherit({
            ctor: function(options) {
                this.options = {};
                $.extend(this.options, this._defaultOptions(), options);
                this.options.dataConverter.setDataAccessors(this.options.dataAccessors);
                this._selectedNodesKeys = [];
                this._expandedNodesKeys = [];
                this._dataStructure = [];
                this._createInternalDataStructure();
                this.getTreeNodes()
            },
            _defaultOptions: function() {
                return {
                    dataAccessors: void 0,
                    items: [],
                    multipleSelection: true,
                    recursiveSelection: false,
                    recursiveExpansion: false,
                    rootValue: 0,
                    searchValue: "",
                    dataType: "tree",
                    dataConverter: new HierarchicalDataConverter,
                    onNodeChanged: $.noop
                }
            },
            _createInternalDataStructure: function() {
                this._initialDataStructure = this.options.dataConverter.createPlainStructure(this.options.items, this.options.rootValue, this.options.dataType);
                this._dataStructure = this.options.searchValue.length ? this.search(this.options.searchValue) : this._initialDataStructure;
                this.options.dataConverter._dataStructure = this._dataStructure;
                this._updateSelection();
                this._updateExpansion()
            },
            _updateSelection: function() {
                if (this.options.recursiveSelection) {
                    this._setChildrenSelection();
                    this._setParentSelection()
                }
                this._selectedNodesKeys = this._updateNodesKeysArray(SELECTED)
            },
            _updateExpansion: function(key) {
                if (this.options.recursiveExpansion) {
                    key ? this._updateOneBranch(key) : this._setParentExpansion()
                }
                this._expandedNodesKeys = this._updateNodesKeysArray(EXPANDED)
            },
            _updateNodesKeysArray: function(property) {
                var that = this,
                    array = [];
                $.each(this._dataStructure, function(_, node) {
                    if (!that._isNodeVisible(node)) {
                        return
                    }
                    if (!!node.internalFields[property]) {
                        if (property === EXPANDED || that.options.multipleSelection) {
                            array.push(node.internalFields.key)
                        } else {
                            array.length && that.toggleSelection(array[0], false, true);
                            array = [node.internalFields.key]
                        }
                    }
                });
                return array
            },
            _isNodeVisible: function(node) {
                return false !== node.internalFields.item.visible
            },
            _getByKey: function(data, key) {
                return data === this._dataStructure ? this.options.dataConverter._getByKey(key) : this.options.dataConverter.getByKey(data, key)
            },
            _setChildrenSelection: function() {
                var that = this;
                $.each(this._dataStructure, function(_, node) {
                    if (!node.internalFields.childrenKeys.length) {
                        return
                    }
                    var isSelected = node.internalFields.selected;
                    true === isSelected && that._toggleChildrenSelection(node, isSelected)
                })
            },
            _setParentSelection: function() {
                var length = this._dataStructure.length;
                for (var i = length - 1; i >= 0; i--) {
                    var node = this._dataStructure[i],
                        parent = this.options.dataConverter._getByKey(node.internalFields.parentKey);
                    if (parent && node.internalFields.parentKey !== this.options.rootValue) {
                        var newParentState = this._calculateSelectedState(parent);
                        this._setFieldState(parent, SELECTED, newParentState)
                    }
                }
            },
            _setParentExpansion: function(key) {
                var that = this;
                $.each(this._dataStructure, function(_, node) {
                    if (!node.internalFields.expanded) {
                        return
                    }
                    that._updateOneBranch(node.internalFields.key)
                })
            },
            _updateOneBranch: function(key) {
                var that = this,
                    node = this.getNodeByKey(key);
                that._iterateParents(node, function(parent) {
                    that._setFieldState(parent, EXPANDED, true)
                })
            },
            _iterateChildren: function(node, recursive, callback) {
                var that = this;
                $.each(node.internalFields.childrenKeys, function(_, key) {
                    var child = that.options.dataConverter._getByKey(key);
                    $.isFunction(callback) && callback(child);
                    if (child.internalFields.childrenKeys.length && recursive) {
                        that._iterateChildren(child, recursive, callback)
                    }
                })
            },
            _iterateParents: function(node, callback) {
                if (node.internalFields.parentKey === this.options.rootValue) {
                    return
                }
                var parent = this.options.dataConverter._getByKey(node.internalFields.parentKey);
                if (parent) {
                    $.isFunction(callback) && callback(parent);
                    if (parent.internalFields.parentKey !== this.options.rootValue) {
                        this._iterateParents(parent, callback)
                    }
                }
            },
            _calculateSelectedState: function(node) {
                var itemsCount = node.internalFields.childrenKeys.length,
                    selectedItemsCount = 0,
                    invisibleItemsCount = 0,
                    result = false;
                for (var i = 0; i <= itemsCount - 1; i++) {
                    var childNode = this.options.dataConverter._getByKey(node.internalFields.childrenKeys[i]),
                        isChildInvisible = false === childNode.internalFields.item.visible,
                        childState = childNode.internalFields.selected;
                    if (isChildInvisible) {
                        invisibleItemsCount++;
                        continue
                    }
                    if (childState) {
                        selectedItemsCount++
                    } else {
                        if (void 0 === childState) {
                            selectedItemsCount += .5
                        }
                    }
                }
                if (selectedItemsCount) {
                    result = selectedItemsCount === itemsCount - invisibleItemsCount ? true : void 0
                }
                return result
            },
            _toggleChildrenSelection: function(node, state) {
                var that = this;
                this._iterateChildren(node, true, function(child) {
                    if (that._isNodeVisible(child)) {
                        that._setFieldState(child, SELECTED, state)
                    }
                })
            },
            _setFieldState: function(node, field, state) {
                if (node.internalFields[field] === state) {
                    return
                }
                node.internalFields[field] = state;
                if (node.internalFields.publicNode) {
                    node.internalFields.publicNode[field] = state
                }
                this.options.dataAccessors.setters[field](node.internalFields.item, state);
                this.options.onNodeChanged(node)
            },
            _markChildren: function(keys) {
                var that = this;
                $.each(keys, function(_, key) {
                    var index = that.getIndexByKey(key),
                        node = that.getNodeByKey(key);
                    that._dataStructure[index] = 0;
                    node.internalFields.childrenKeys.length && that._markChildren(node.internalFields.childrenKeys)
                })
            },
            _removeNode: function(key) {
                var node = this.getNodeByKey(key);
                this._dataStructure[this.getIndexByKey(key)] = 0;
                this._markChildren(node.internalFields.childrenKeys);
                var that = this,
                    counter = 0,
                    items = $.extend([], this._dataStructure);
                $.each(items, function(index, item) {
                    if (!item) {
                        that._dataStructure.splice(index - counter, 1);
                        counter++
                    }
                })
            },
            _addNode: function(item) {
                var dataConverter = this.options.dataConverter,
                    node = dataConverter._convertItemToNode(item, this.options.dataAccessors.getters.parentKey(item));
                this._dataStructure = this._dataStructure.concat(node);
                this._initialDataStructure = this._initialDataStructure.concat(node);
                dataConverter._dataStructure = dataConverter._dataStructure.concat(node)
            },
            _updateFields: function() {
                this.options.dataConverter.updateChildrenKeys();
                this._updateSelection();
                this._updateExpansion()
            },
            getSelectedNodesKeys: function() {
                return this._selectedNodesKeys
            },
            getExpandedNodesKeys: function() {
                return this._expandedNodesKeys
            },
            getData: function() {
                return this._dataStructure
            },
            getFullData: function() {
                return this._initialDataStructure
            },
            getNodeByItem: function(item) {
                var result = null;
                $.each(this._dataStructure, function(_, node) {
                    if (node.internalFields.item === item) {
                        result = node;
                        return false
                    }
                });
                return result
            },
            getNodeByKey: function(key) {
                return this._getByKey(this._dataStructure, key)
            },
            getTreeNodes: function() {
                return this.options.dataConverter.convertToPublicNodes(this.getRootNodes())
            },
            getItemsCount: function() {
                return this.options.dataConverter.getItemsCount()
            },
            getVisibleItemsCount: function() {
                return this.options.dataConverter.getVisibleItemsCount()
            },
            getPublicNode: function(node) {
                return node.internalFields.publicNode
            },
            getRootNodes: function() {
                return this.getChildrenNodes(this.options.rootValue)
            },
            getChildrenNodes: function(parentKey) {
                return query(this._dataStructure).filter(["internalFields.parentKey", parentKey]).toArray()
            },
            getIndexByKey: function(key) {
                return this.options.dataConverter.getIndexByKey(key)
            },
            addItem: function(item) {
                this._addNode(item);
                this._updateFields()
            },
            removeItem: function(key) {
                this._removeNode(key);
                this._updateFields()
            },
            toggleSelection: function(key, state, selectRecursive) {
                var node = !selectRecursive ? this._getByKey(this._dataStructure, key) : this._getByKey(this._initialDataStructure, key);
                this._setFieldState(node, SELECTED, state);
                if (this.options.recursiveSelection && !selectRecursive) {
                    state ? this._setChildrenSelection() : this._toggleChildrenSelection(node, state);
                    this._setParentSelection()
                }
                this._selectedNodesKeys = this._updateNodesKeysArray(SELECTED)
            },
            toggleNodeDisabledState: function(key, state) {
                var node = this._getByKey(this._dataStructure, key);
                this._setFieldState(node, DISABLED, state)
            },
            toggleSelectAll: function(state) {
                if (!commonUtils.isDefined(state)) {
                    return
                }
                var that = this;
                $.each(this._dataStructure, function(_, node) {
                    if (!that._isNodeVisible(node)) {
                        return
                    }
                    that._setFieldState(node, SELECTED, state);
                    that._selectedNodesKeys = that._updateNodesKeysArray(SELECTED)
                })
            },
            isAllSelected: function() {
                if (this.getSelectedNodesKeys().length) {
                    return this.getSelectedNodesKeys().length === this.getVisibleItemsCount() ? true : void 0
                } else {
                    return false
                }
            },
            toggleExpansion: function(key, state) {
                var node = this._getByKey(this._dataStructure, key);
                this._setFieldState(node, EXPANDED, state);
                if (state) {
                    this._updateExpansion(key)
                }
                this._expandedNodesKeys = this._updateNodesKeysArray(EXPANDED)
            },
            _filterDataStructure: function(substring) {
                var text, matches = [],
                    dataStructure = this._initialDataStructure,
                    reg = new RegExp(substring, "i");
                for (var i = 0, size = dataStructure.length; i < size; i++) {
                    text = this.options.dataAccessors.getters.display(dataStructure[i]);
                    reg.test(text) && matches.push(dataStructure[i])
                }
                return matches
            },
            search: function(substring) {
                var that = this,
                    matches = this._filterDataStructure(substring),
                    dataConverter = this.options.dataConverter;

                function lookForParents(matches, index) {
                    var length = matches.length;
                    while (index < length) {
                        var parent, parentKey = matches[index].internalFields.parentKey;
                        if (parentKey === that.options.rootValue) {
                            index++;
                            continue
                        }
                        parent = dataConverter._getByKey(parentKey);
                        if (!parent.internalFields.expanded) {
                            that._setFieldState(parent, EXPANDED, true)
                        }
                        if ($.inArray(parent, matches) > -1) {
                            index++;
                            continue
                        }
                        matches.splice(index, 0, parent);
                        lookForParents(matches, index)
                    }
                }
                lookForParents(matches, 0);
                dataConverter._indexByKey = {};
                $.each(matches, function(index, node) {
                    node.internalFields.childrenKeys = [];
                    dataConverter._indexByKey[node.internalFields.key] = index
                });
                dataConverter._dataStructure = matches;
                dataConverter.setChildrenKeys();
                return dataConverter._dataStructure
            }
        });
        module.exports = DataAdapter
    },
    /*!*****************************************************************!*\
      !*** ./Scripts/ui/hierarchical_collection/ui.data_converter.js ***!
      \*****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            errors = __webpack_require__( /*! ../../ui/widget/ui.errors */ 10),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        var DataConverter = Class.inherit({
            ctor: function() {
                this._dataStructure = [];
                this._itemsCount = 0;
                this._visibleItemsCount = 0
            },
            _indexByKey: {},
            _convertItemsToNodes: function(items, parentKey) {
                var that = this;
                $.each(items, function(_, item) {
                    var parentId = commonUtils.isDefined(parentKey) ? parentKey : that._getParentId(item),
                        node = that._convertItemToNode(item, parentId);
                    that._dataStructure.push(node);
                    that._checkForDuplicateId(node.internalFields.key);
                    that._indexByKey[node.internalFields.key] = that._dataStructure.length - 1;
                    if (that._itemHasChildren(item)) {
                        that._convertItemsToNodes(that._dataAccessors.getters.items(item), node.internalFields.key)
                    }
                })
            },
            _checkForDuplicateId: function(key) {
                if (commonUtils.isDefined(this._indexByKey[key])) {
                    throw errors.Error("E1040")
                }
            },
            _getParentId: function(item) {
                return "plain" === this._dataType ? this._dataAccessors.getters.parentKey(item) : void 0
            },
            _itemHasChildren: function(item) {
                var items = this._dataAccessors.getters.items(item);
                return items && items.length
            },
            _convertItemToNode: function(item, parentKey) {
                this._itemsCount++;
                false !== item.visible && this._visibleItemsCount++;
                var that = this,
                    node = {
                        internalFields: {
                            disabled: that._dataAccessors.getters.disabled(item) || false,
                            expanded: that._dataAccessors.getters.expanded(item) || false,
                            selected: that._dataAccessors.getters.selected(item) || false,
                            key: commonUtils.isDefined(that._dataAccessors.getters.key(item)) ? that._dataAccessors.getters.key(item) : that.getItemsCount(),
                            parentKey: commonUtils.isDefined(parentKey) ? parentKey : that._rootValue,
                            item: that._makeObjectFromPrimitive(item),
                            childrenKeys: []
                        }
                    };
                $.extend(true, node, item);
                delete node.items;
                return node
            },
            setChildrenKeys: function() {
                var that = this;
                $.each(this._dataStructure, function(_, node) {
                    if (node.internalFields.parentKey === that._rootValue) {
                        return
                    }
                    var parent = that._getByKey(node.internalFields.parentKey);
                    parent && parent.internalFields.childrenKeys.push(node.internalFields.key)
                })
            },
            _makeObjectFromPrimitive: function(item) {
                if (commonUtils.isPrimitive(item)) {
                    var key = item;
                    item = {};
                    this._dataAccessors.setters.key(item, key)
                }
                return item
            },
            _convertToPublicNode: function(node, parent) {
                if (!node) {
                    return null
                }
                var publicNode = {
                    text: this._dataAccessors.getters.display(node),
                    key: node.internalFields.key,
                    selected: node.internalFields.selected,
                    expanded: node.internalFields.expanded,
                    disabled: node.internalFields.disabled,
                    parent: parent || null,
                    itemData: node.internalFields.item,
                    children: [],
                    items: []
                };
                if (publicNode.parent) {
                    publicNode.parent.children.push(publicNode);
                    publicNode.parent.items.push(publicNode)
                }
                return publicNode
            },
            convertToPublicNodes: function(data, parent) {
                if (!data.length) {
                    return []
                }
                var that = this,
                    publicNodes = [];
                $.each(data, function(_, node) {
                    node = commonUtils.isPrimitive(node) ? that._getByKey(node) : node;
                    var publicNode = that._convertToPublicNode(node, parent);
                    publicNode.children = that.convertToPublicNodes(node.internalFields.childrenKeys, publicNode);
                    publicNodes.push(publicNode);
                    node.internalFields.publicNode = publicNode
                });
                return publicNodes
            },
            setDataAccessors: function(accessors) {
                this._dataAccessors = accessors
            },
            _getByKey: function(key) {
                return this._dataStructure[this.getIndexByKey(key)] || null
            },
            getByKey: function(data, key) {
                var result = null,
                    that = this;
                var getByKey = function(data, key) {
                    $.each(data, function(_, element) {
                        var currentElementKey = element.internalFields && element.internalFields.key || that._dataAccessors.getters.key(element),
                            items = that._dataAccessors.getters.items(element);
                        if (currentElementKey === key) {
                            result = element;
                            return false
                        }
                        if (items) {
                            getByKey(items, key)
                        }
                    });
                    return result
                };
                return getByKey(data, key)
            },
            getItemsCount: function() {
                return this._itemsCount
            },
            getVisibleItemsCount: function() {
                return this._visibleItemsCount
            },
            updateIndexByKey: function() {
                var that = this;
                this._indexByKey = {};
                $.each(this._dataStructure, function(index, node) {
                    that._checkForDuplicateId(node.internalFields.key);
                    that._indexByKey[node.internalFields.key] = index
                })
            },
            updateChildrenKeys: function() {
                this._indexByKey = {};
                this.removeChildrenKeys();
                this.updateIndexByKey();
                this.setChildrenKeys()
            },
            removeChildrenKeys: function() {
                this._indexByKey = {};
                $.each(this._dataStructure, function(index, node) {
                    node.internalFields.childrenKeys = []
                })
            },
            getIndexByKey: function(key) {
                return this._indexByKey[key]
            },
            createPlainStructure: function(items, rootValue, dataType) {
                this._itemsCount = 0;
                this._visibleItemsCount = 0;
                this._rootValue = rootValue;
                this._dataType = dataType;
                this._indexByKey = {};
                this._convertItemsToNodes(items);
                this.setChildrenKeys();
                return this._dataStructure
            }
        });
        module.exports = DataConverter
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/context_menu/ui.menu_base.edit.strategy.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            PlainEditStrategy = __webpack_require__( /*! ../collection/ui.collection_widget.edit.strategy.plain */ 166);
        var MenuBaseEditStrategy = PlainEditStrategy.inherit({
            _getPlainItems: function() {
                return $.map(this._collectionWidget.option("items"), function getMenuItems(item) {
                    return item.items ? [item].concat($.map(item.items, getMenuItems)) : item
                })
            },
            _stringifyItem: function(item) {
                var that = this;
                return JSON.stringify(item, function(key, value) {
                    if ("template" === key) {
                        return that._getTemplateString(value)
                    }
                    return value
                })
            },
            _getTemplateString: function(template) {
                var result;
                if ("object" === typeof template) {
                    result = $(template).text()
                } else {
                    result = template.toString()
                }
                return result
            },
            selectedItemIndices: function() {
                var selectedIndices = [],
                    dataAdapter = this._collectionWidget._dataAdapter,
                    items = dataAdapter.getData(),
                    selectedItem = dataAdapter.getNodeByKey(dataAdapter.getSelectedNodesKeys()[0]);
                if (selectedItem) {
                    var index = $.inArray(selectedItem, items);
                    if (index !== -1) {
                        selectedIndices.push(index)
                    } else {
                        errors.log("W1002", selectedItem)
                    }
                }
                return selectedIndices
            },
            fetchSelectedItems: function(indices) {
                indices = indices || this._collectionWidget._selectedItemIndices;
                var items = this._getPlainItems(),
                    selectedItems = [];
                $.each(indices, function(_, index) {
                    selectedItems.push(items[index])
                });
                return selectedItems
            }
        });
        module.exports = MenuBaseEditStrategy
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/data_grid.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./data_grid/ui.data_grid */ 335)
    },
    /*!**********************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var DataGrid = __webpack_require__( /*! ./ui.data_grid.base */ 336);
        module.exports = DataGrid;
        __webpack_require__( /*! ./ui.data_grid.state_storing */ 352);
        __webpack_require__( /*! ./ui.data_grid.selection */ 354);
        __webpack_require__( /*! ./ui.data_grid.column_chooser_module */ 355);
        __webpack_require__( /*! ./ui.data_grid.grouping_module */ 357);
        __webpack_require__( /*! ./ui.data_grid.master_detail_module */ 361);
        __webpack_require__( /*! ./ui.data_grid.editing */ 362);
        __webpack_require__( /*! ./ui.data_grid.validation_module */ 364);
        __webpack_require__( /*! ./ui.data_grid.virtual_scrolling_module */ 365);
        __webpack_require__( /*! ./ui.data_grid.filter_row */ 367);
        __webpack_require__( /*! ./ui.data_grid.header_filter */ 371);
        __webpack_require__( /*! ./ui.data_grid.search */ 373);
        __webpack_require__( /*! ./ui.data_grid.pager */ 374);
        __webpack_require__( /*! ./ui.data_grid.columns_resizing_reordering_module */ 376);
        __webpack_require__( /*! ./ui.data_grid.keyboard_navigation */ 377);
        __webpack_require__( /*! ./ui.data_grid.summary_module */ 378);
        __webpack_require__( /*! ./ui.data_grid.fixed_columns */ 380);
        __webpack_require__( /*! ./ui.data_grid.adaptivity */ 381);
        __webpack_require__( /*! ./ui.data_grid.export_controller */ 382)
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.base.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            logger = __webpack_require__( /*! ../../core/utils/console */ 12).logger,
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            callModuleItemsMethod = gridCore.callModuleItemsMethod;
        var DATAGRID_ROW_SELECTOR = ".dx-row",
            DATAGRID_DEPRECATED_TEMPLATE_WARNING = "Specifying grid templates with the name of a jQuery selector is now deprecated. Instead, use the jQuery object that references this selector.";
        __webpack_require__( /*! ./ui.data_grid.column_headers_view */ 339);
        __webpack_require__( /*! ./ui.data_grid.columns_controller */ 342);
        __webpack_require__( /*! ./ui.data_grid.data_controller */ 343);
        __webpack_require__( /*! ./ui.data_grid.sorting_module */ 345);
        __webpack_require__( /*! ./ui.data_grid.rows_view */ 347);
        __webpack_require__( /*! ./ui.data_grid.context_menu_view */ 348);
        __webpack_require__( /*! ./ui.data_grid.error_handling */ 349);
        __webpack_require__( /*! ./ui.data_grid.grid_view */ 350);
        __webpack_require__( /*! ./ui.data_grid.header_panel */ 351);
        gridCore.registerModulesOrder(["stateStoring", "columns", "selection", "editorFactory", "columnChooser", "grouping", "masterDetail", "editing", "validating", "adaptivity", "data", "virtualScrolling", "columnHeaders", "filterRow", "headerPanel", "headerFilter", "sorting", "search", "rows", "pager", "columnsResizingReordering", "contextMenu", "keyboardNavigation", "errorHandling", "summary", "fixedColumns", "export", "gridView"]);
        var DataGrid = Widget.inherit({
            _activeStateUnit: DATAGRID_ROW_SELECTOR,
            _getDefaultOptions: function() {
                var that = this,
                    result = that.callBase();
                $.each(gridCore.modules, function() {
                    if ($.isFunction(this.defaultOptions)) {
                        $.extend(true, result, this.defaultOptions())
                    }
                });
                return result
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    "editing.editMode": {
                        since: "15.2",
                        alias: "editing.mode"
                    },
                    "editing.editEnabled": {
                        since: "15.2",
                        alias: "editing.allowUpdating"
                    },
                    "editing.insertEnabled": {
                        since: "15.2",
                        alias: "editing.allowAdding"
                    },
                    "editing.removeEnabled": {
                        since: "15.2",
                        alias: "editing.allowDeleting"
                    },
                    "grouping.groupContinuedMessage": {
                        since: "16.1",
                        alias: "grouping.texts.groupContinuedMessage"
                    },
                    "grouping.groupContinuesMessage": {
                        since: "16.1",
                        alias: "grouping.texts.groupContinuesMessage"
                    },
                    "export.texts.excelFormat": {
                        since: "16.1",
                        alias: "export.texts.exportAll"
                    },
                    "export.texts.exportToExcel": {
                        since: "16.1",
                        alias: "export.texts.exportAll"
                    },
                    "export.texts.selectedRows": {
                        since: "16.1",
                        alias: "export.texts.exportSelectedRows"
                    }
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: {
                        platform: "ios"
                    },
                    options: {
                        showRowLines: true
                    }
                }, {
                    device: function() {
                        return browser.webkit
                    },
                    options: {
                        loadingTimeout: 30,
                        loadPanel: {
                            animation: {
                                show: {
                                    easing: "cubic-bezier(1, 0, 1, 0)",
                                    duration: 500,
                                    from: {
                                        opacity: 0
                                    },
                                    to: {
                                        opacity: 1
                                    }
                                }
                            }
                        }
                    }
                }, {
                    device: function(device) {
                        return "desktop" !== device.deviceType
                    },
                    options: {
                        grouping: {
                            expandMode: "rowClick"
                        }
                    }
                }])
            },
            _init: function() {
                var that = this;
                that.callBase();
                gridCore.processModules(that, gridCore);
                callModuleItemsMethod(that, "init")
            },
            _clean: $.noop,
            _optionChanged: function(args) {
                var that = this;
                callModuleItemsMethod(that, "optionChanged", [args]);
                if (!args.handled) {
                    that.callBase(args)
                }
            },
            _dimensionChanged: function() {
                this.updateDimensions(true)
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this.updateDimensions()
                }
            },
            _renderContentImpl: function() {
                this.getView("gridView").render(this.element())
            },
            _renderContent: function() {
                var that = this;
                commonUtils.deferRender(function() {
                    that._renderContentImpl()
                })
            },
            _getTemplate: function(templateName) {
                var template = templateName;
                if (commonUtils.isString(template) && "#" === template[0]) {
                    template = $(templateName);
                    logger.warn(DATAGRID_DEPRECATED_TEMPLATE_WARNING)
                }
                return this.callBase(template)
            },
            _dispose: function() {
                var that = this;
                that.callBase();
                callModuleItemsMethod(that, "dispose")
            },
            isReady: function() {
                return this.getController("data").isReady()
            },
            beginUpdate: function() {
                var that = this;
                that.callBase();
                callModuleItemsMethod(that, "beginUpdate")
            },
            endUpdate: function() {
                var that = this;
                callModuleItemsMethod(that, "endUpdate");
                that.callBase()
            },
            getController: function(name) {
                return this._controllers[name]
            },
            getView: function(name) {
                return this._views[name]
            },
            focus: function(element) {
                this.callBase();
                if (commonUtils.isDefined(element)) {
                    this.getController("keyboardNavigation").focus(element)
                }
            }
        });
        DataGrid.registerModule = gridCore.registerModule.bind(gridCore);
        registerComponent("dxDataGrid", DataGrid);
        module.exports = DataGrid
    },
    /*!***************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.core.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            toComparable = __webpack_require__( /*! ../../core/utils/data */ 36).toComparable,
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            modules = __webpack_require__( /*! ../grid_core/ui.grid_core.modules */ 338),
            dataUtils = __webpack_require__( /*! ../../data/utils */ 137),
            formatHelper = __webpack_require__( /*! ../../format_helper */ 55);
        var DATE_INTERVAL_SELECTORS = {
                year: function(value) {
                    return value && value.getFullYear()
                },
                month: function(value) {
                    return value && value.getMonth() + 1
                },
                day: function(value) {
                    return value && value.getDate()
                },
                quarter: function(value) {
                    return value && Math.floor(value.getMonth() / 3) + 1
                },
                hour: function(value) {
                    return value && value.getHours()
                },
                minute: function(value) {
                    return value && value.getMinutes()
                },
                second: function(value) {
                    return value && value.getSeconds()
                }
            },
            DEFAULT_DATE_INTERVAL = ["year", "month", "day"];
        $.extend(exports, modules, function() {
            var getIntervalSelector = function() {
                var groupInterval, nameIntervalSelector, data = arguments[1],
                    value = this.calculateCellValue(data);
                if (!commonUtils.isDefined(value)) {
                    return null
                } else {
                    if ("date" === this.dataType) {
                        nameIntervalSelector = arguments[0];
                        return DATE_INTERVAL_SELECTORS[nameIntervalSelector](value)
                    } else {
                        if ("number" === this.dataType) {
                            groupInterval = arguments[0];
                            return Math.floor(Number(value) / groupInterval) * groupInterval
                        }
                    }
                }
            };
            var getDateValues = function(dateValue) {
                if (commonUtils.isDate(dateValue)) {
                    return [dateValue.getFullYear(), dateValue.getMonth(), dateValue.getDate(), dateValue.getHours(), dateValue.getMinutes(), dateValue.getSeconds()]
                }
                return $.map(("" + dateValue).split("/"), function(value, index) {
                    return 1 === index ? Number(value) - 1 : Number(value)
                })
            };
            var getFilterExpressionForDate = function(filterValue, selectedFilterOperation, target) {
                var dateStart, dateEnd, column = this,
                    selector = getFilterSelector(column, target),
                    values = getDateValues(filterValue),
                    dateInterval = exports.getGroupInterval(column)[values.length - 1];
                switch (dateInterval) {
                    case "year":
                        dateStart = new Date(values[0], 0, 1), dateEnd = new Date(values[0] + 1, 0, 1);
                        break;
                    case "month":
                        dateStart = new Date(values[0], values[1], 1), dateEnd = new Date(values[0], values[1] + 1, 1);
                        break;
                    case "quarter":
                        dateStart = new Date(values[0], 3 * values[1], 1), dateEnd = new Date(values[0], 3 * values[1] + 3, 1);
                        break;
                    case "hour":
                        dateStart = new Date(values[0], values[1], values[2], values[3]), dateEnd = new Date(values[0], values[1], values[2], values[3] + 1);
                        break;
                    case "minute":
                        dateStart = new Date(values[0], values[1], values[2], values[3], values[4]), dateEnd = new Date(values[0], values[1], values[2], values[3], values[4] + 1);
                        break;
                    case "second":
                        dateStart = new Date(values[0], values[1], values[2], values[3], values[4], values[5]), dateEnd = new Date(values[0], values[1], values[2], values[3], values[4], values[5] + 1);
                        break;
                    default:
                        dateStart = new Date(values[0], values[1], values[2]), dateEnd = new Date(values[0], values[1], values[2] + 1)
                }
                switch (selectedFilterOperation) {
                    case "<":
                        return [selector, "<", dateStart];
                    case "<=":
                        return [selector, "<", dateEnd];
                    case ">":
                        return [selector, ">=", dateEnd];
                    case ">=":
                        return [selector, ">=", dateStart];
                    case "<>":
                        return [
                            [selector, "<", dateStart], "or", [selector, ">=", dateEnd]
                        ];
                    default:
                        return [
                            [selector, ">=", dateStart], "and", [selector, "<", dateEnd]
                        ]
                }
            };
            var getFilterExpressionForNumber = function(filterValue, selectedFilterOperation, target) {
                var interval, startFilterValue, endFilterValue, column = this,
                    selector = getFilterSelector(column, target),
                    values = ("" + filterValue).split("/"),
                    value = Number(values[values.length - 1]),
                    isExclude = "exclude" === column.filterType,
                    groupInterval = exports.getGroupInterval(column);
                if ("headerFilter" === target && groupInterval && commonUtils.isDefined(filterValue)) {
                    interval = groupInterval[values.length - 1];
                    startFilterValue = [selector, isExclude ? "<" : ">=", value];
                    endFilterValue = [selector, isExclude ? ">=" : "<", value + interval];
                    return [startFilterValue, isExclude ? "or" : "and", endFilterValue]
                }
                return [selector, selectedFilterOperation || "=", filterValue]
            };
            var getFilterSelector = function(column, target) {
                var selector = column.dataField || column.selector;
                if ("search" === target) {
                    selector = column.displayField || column.calculateDisplayValue || selector
                }
                return selector
            };
            var getFilterExpressionByRange = function(filterValue, selectedFilterOperation, target) {
                var column = this,
                    dataField = column.dataField;
                if (commonUtils.isArray(filterValue) && commonUtils.isDefined(filterValue[0]) && commonUtils.isDefined(filterValue[1])) {
                    return [
                        [dataField, ">=", filterValue[0]], "and", [dataField, "<=", filterValue[1]]
                    ]
                }
            };
            return {
                formatValue: function(value, options) {
                    var valueText = formatHelper.format(value, options.format, options.precision) || value && value.toString() || "",
                        formatObject = {
                            value: value,
                            valueText: options.getDisplayFormat ? options.getDisplayFormat(valueText) : valueText,
                            target: options.target || "row",
                            groupInterval: options.groupInterval
                        };
                    return options.customizeText ? options.customizeText.call(options, formatObject) : formatObject.valueText
                },
                getDisplayValue: function(column, value, data, rowType) {
                    if (column.displayValueMap && void 0 !== column.displayValueMap[value]) {
                        return column.displayValueMap[value]
                    } else {
                        if (column.calculateDisplayValue && data && "group" !== rowType) {
                            return column.calculateDisplayValue(data)
                        } else {
                            if (column.lookup && !("group" === rowType && column.calculateGroupValue)) {
                                return column.lookup.calculateCellValue(value)
                            }
                        }
                    }
                    return value
                },
                getGroupRowSummaryText: function(summaryItems, summaryTexts) {
                    var i, summaryItem, result = "(";
                    for (i = 0; i < summaryItems.length; i++) {
                        summaryItem = summaryItems[i];
                        result += (i > 0 ? ", " : "") + exports.getSummaryText(summaryItem, summaryTexts)
                    }
                    return result += ")"
                },
                getSummaryText: function(summaryItem, summaryTexts) {
                    var displayFormat = summaryItem.displayFormat || summaryItem.columnCaption && summaryTexts[summaryItem.summaryType + "OtherColumn"] || summaryTexts[summaryItem.summaryType];
                    return this.formatValue(summaryItem.value, {
                        format: summaryItem.valueFormat,
                        precision: summaryItem.precision,
                        getDisplayFormat: function(valueText) {
                            return displayFormat ? stringUtils.format(displayFormat, valueText, summaryItem.columnCaption) : valueText
                        },
                        customizeText: summaryItem.customizeText
                    })
                },
                getKeyHash: function(key) {
                    if (commonUtils.isObject(key) || commonUtils.isArray(key)) {
                        try {
                            var keyHash = JSON.stringify(key);
                            return "{}" === keyHash ? key : keyHash
                        } catch (e) {
                            return key
                        }
                    }
                    return key
                },
                normalizeSortingInfo: function(sort) {
                    sort = sort || [];
                    var result, i;
                    result = dataUtils.normalizeSortingInfo(sort);
                    for (i = 0; i < sort.length; i++) {
                        if (sort && sort[i] && void 0 !== sort[i].isExpanded) {
                            result[i].isExpanded = sort[i].isExpanded
                        }
                        if (sort && sort[i] && void 0 !== sort[i].groupInterval) {
                            result[i].groupInterval = sort[i].groupInterval
                        }
                    }
                    return result
                },
                getFormatByDataType: function(dataType) {
                    switch (dataType) {
                        case "date":
                            return "shortDate"
                    }
                },
                defaultCalculateFilterExpression: function(filterValue, selectedFilterOperation, target) {
                    var column = this,
                        selector = getFilterSelector(column, target),
                        isSearchByDisplayValue = column.calculateDisplayValue && "search" === target,
                        dataType = isSearchByDisplayValue && column.lookup && column.lookup.dataType || column.dataType,
                        filter = null;
                    if ("headerFilter" === target && null === filterValue) {
                        filter = [selector, selectedFilterOperation || "=", null];
                        if ("string" === dataType) {
                            filter = [filter, "=" === selectedFilterOperation ? "or" : "and", [selector, selectedFilterOperation || "=", ""]]
                        }
                    } else {
                        if ("string" === dataType && (!column.lookup || isSearchByDisplayValue)) {
                            filter = [selector, selectedFilterOperation || "contains", filterValue]
                        } else {
                            if ("between" === selectedFilterOperation) {
                                return getFilterExpressionByRange.apply(column, arguments)
                            } else {
                                if ("date" === dataType && commonUtils.isDefined(filterValue)) {
                                    return getFilterExpressionForDate.apply(column, arguments)
                                } else {
                                    if ("number" === dataType) {
                                        return getFilterExpressionForNumber.apply(column, arguments)
                                    } else {
                                        if ("object" !== dataType) {
                                            filter = [selector, selectedFilterOperation || "=", filterValue]
                                        }
                                    }
                                }
                            }
                        }
                    }
                    return filter
                },
                getHeaderFilterGroupParameters: function(column, remoteGrouping) {
                    var result = [],
                        dataField = column.dataField || column.name,
                        groupInterval = this.getGroupInterval(column);
                    if (column.calculateGroupValue) {
                        return remoteGrouping ? [{
                            selector: column.calculateGroupValue,
                            isExpanded: false
                        }] : $.proxy(column.calculateGroupValue, column)
                    }
                    if (groupInterval) {
                        $.each(groupInterval, function(index, interval) {
                            result.push(remoteGrouping ? {
                                selector: dataField,
                                groupInterval: interval,
                                isExpanded: false
                            } : $.proxy(getIntervalSelector, column, interval))
                        });
                        return result
                    }
                    return remoteGrouping ? [{
                        selector: dataField,
                        isExpanded: false
                    }] : function(data) {
                        var result = column.calculateCellValue(data);
                        if (void 0 === result || "" === result) {
                            result = null
                        }
                        return result
                    }
                },
                getGroupInterval: function(column) {
                    var index, result = [],
                        dateIntervals = ["year", "month", "day", "hour", "minute", "second"],
                        groupInterval = column.headerFilter && column.headerFilter.groupInterval,
                        interval = "quarter" === groupInterval ? "month" : groupInterval;
                    if ("date" === column.dataType) {
                        result = DEFAULT_DATE_INTERVAL;
                        index = $.inArray(interval, dateIntervals);
                        if (index >= 0) {
                            result = dateIntervals.slice(0, index);
                            result.push(groupInterval);
                            return result
                        }
                        return result
                    } else {
                        if (commonUtils.isDefined(groupInterval)) {
                            return commonUtils.isArray(groupInterval) ? groupInterval : [groupInterval]
                        }
                    }
                },
                checkChanges: function(changes, changeNames) {
                    var i, changesWithChangeNamesCount = 0;
                    for (i = 0; i < changeNames.length; i++) {
                        if (changes[changeNames[i]]) {
                            changesWithChangeNamesCount++
                        }
                    }
                    return changes.length && changes.length === changesWithChangeNamesCount
                },
                equalSortParameters: function(sortParameters1, sortParameters2, ignoreIsExpanded) {
                    var i;
                    sortParameters1 = exports.normalizeSortingInfo(sortParameters1);
                    sortParameters2 = exports.normalizeSortingInfo(sortParameters2);
                    if ($.isArray(sortParameters1) && $.isArray(sortParameters2)) {
                        if (sortParameters1.length !== sortParameters2.length) {
                            return false
                        } else {
                            for (i = 0; i < sortParameters1.length; i++) {
                                if (sortParameters1[i].selector !== sortParameters2[i].selector || sortParameters1[i].desc !== sortParameters2[i].desc || sortParameters1[i].groupInterval !== sortParameters2[i].groupInterval || !ignoreIsExpanded && Boolean(sortParameters1[i].isExpanded) !== Boolean(sortParameters2[i].isExpanded)) {
                                    return false
                                }
                            }
                        }
                        return true
                    } else {
                        return (!sortParameters1 || !sortParameters1.length) === (!sortParameters2 || !sortParameters2.length)
                    }
                },
                equalFilterParameters: function(filter1, filter2) {
                    var i;
                    if ($.isArray(filter1) && $.isArray(filter2)) {
                        if (filter1.length !== filter2.length) {
                            return false
                        } else {
                            for (i = 0; i < filter1.length; i++) {
                                if (!exports.equalFilterParameters(filter1[i], filter2[i])) {
                                    return false
                                }
                            }
                        }
                        return true
                    } else {
                        if ($.isFunction(filter1) && filter1.columnIndex >= 0 && $.isFunction(filter2) && filter2.columnIndex >= 0) {
                            return filter1.columnIndex === filter2.columnIndex
                        } else {
                            return toComparable(filter1) == toComparable(filter2)
                        }
                    }
                },
                proxyMethod: function(instance, methodName, defaultResult) {
                    if (!instance[methodName]) {
                        instance[methodName] = function() {
                            var dataSource = this._dataSource;
                            return dataSource ? dataSource[methodName].apply(dataSource, arguments) : defaultResult
                        }
                    }
                },
                combineFilters: function(filters, operation) {
                    var i, resultFilter = [];
                    operation = operation || "and";
                    for (i = 0; i < filters.length; i++) {
                        if (!filters[i]) {
                            continue
                        }
                        if (resultFilter.length) {
                            resultFilter.push(operation)
                        }
                        resultFilter.push(filters[i])
                    }
                    if (1 === resultFilter.length) {
                        resultFilter = resultFilter[0]
                    }
                    if (resultFilter.length) {
                        return resultFilter
                    }
                },
                getPointsByColumns: function(items, pointCreated, isVertical, startColumnIndex) {
                    var point, i, item, offset, prevItemOffset, rtlEnabled, cellsLength = items.length,
                        notCreatePoint = false,
                        columnIndex = startColumnIndex || 0,
                        result = [];
                    for (i = 0; i <= cellsLength; i++) {
                        if (i < cellsLength) {
                            item = items.eq(i);
                            offset = item.offset();
                            rtlEnabled = "rtl" === item.css("direction")
                        }
                        point = {
                            index: columnIndex,
                            x: offset ? offset.left + (!isVertical && rtlEnabled ^ i === cellsLength ? item.outerWidth() : 0) : 0,
                            y: offset ? offset.top + (isVertical && i === cellsLength ? item.outerHeight() : 0) : 0,
                            columnIndex: columnIndex
                        };
                        if (!isVertical && i > 0) {
                            prevItemOffset = items.eq(i - 1).offset();
                            if (prevItemOffset.top < point.y) {
                                point.y = prevItemOffset.top
                            }
                        }
                        if (pointCreated) {
                            notCreatePoint = pointCreated(point)
                        }
                        if (!notCreatePoint) {
                            result.push(point)
                        }
                        columnIndex++
                    }
                    return result
                }
            }
        }())
    },
    /*!******************************************************!*\
      !*** ./Scripts/ui/grid_core/ui.grid_core.modules.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var CallBacks = function(options) {
            options = options || {};
            var firing, firingIndex, list = [],
                fireCore = function(context, args) {
                    firing = true;
                    for (firingIndex = 0; firingIndex < list.length; firingIndex++) {
                        if (list[firingIndex] && false === list[firingIndex].apply(context, args) && options.stopOnFalse) {
                            break
                        }
                    }
                    firing = false
                },
                that = {
                    add: function(fn) {
                        if ("function" === typeof fn && !that.has(fn)) {
                            list.push(fn)
                        }
                        return this
                    },
                    has: function(fn) {
                        return fn ? $.inArray(fn, list) > -1 : !!list.length
                    },
                    remove: function(fn) {
                        var index = $.inArray(fn, list);
                        if (index > -1) {
                            list.splice(index, 1);
                            if (firing && index <= firingIndex) {
                                firingIndex--
                            }
                        }
                        return this
                    },
                    fireWith: function(context, args) {
                        args = args || [];
                        fireCore(context, args.slice ? args.slice() : args)
                    },
                    fire: function() {
                        that.fireWith(this, arguments);
                        return this
                    },
                    empty: function() {
                        list = [];
                        return this
                    }
                };
            return that
        };
        var ModuleItem = Class.inherit({
            _endUpdateCore: function() {},
            ctor: function(component) {
                var that = this;
                that._updateLockCount = 0;
                that.component = component;
                that._actions = {};
                that._actionConfigs = {};
                $.each(this.callbackNames() || [], function(index, name) {
                    var flags = that.callbackFlags(name);
                    that[this] = CallBacks(flags)
                })
            },
            init: function() {},
            callbackNames: function() {},
            callbackFlags: function(name) {},
            publicMethods: function() {},
            beginUpdate: function() {
                this._updateLockCount++
            },
            endUpdate: function() {
                if (this._updateLockCount > 0) {
                    this._updateLockCount--;
                    if (!this._updateLockCount) {
                        this._endUpdateCore()
                    }
                }
            },
            option: function(name) {
                var component = this.component,
                    optionCache = component._optionCache;
                if (1 === arguments.length && optionCache) {
                    if (!(name in optionCache)) {
                        optionCache[name] = component.option(name)
                    }
                    return optionCache[name]
                }
                return component.option.apply(component, arguments)
            },
            localize: function(name) {
                var optionCache = this.component._optionCache;
                if (optionCache) {
                    if (!(name in optionCache)) {
                        optionCache[name] = messageLocalization.format(name)
                    }
                    return optionCache[name]
                }
                return messageLocalization.format(name)
            },
            on: function() {
                return this.component.on.apply(this.component, arguments)
            },
            off: function() {
                return this.component.off.apply(this.component, arguments)
            },
            optionChanged: function(args) {
                if (args.name in this._actions) {
                    this.createAction(args.name, this._actionConfigs[args.name]);
                    args.handled = true
                }
            },
            getAction: function(actionName) {
                return this._actions[actionName]
            },
            setAria: function(name, value, $target) {
                var target = $target.get(0),
                    prefix = "role" !== name && "id" !== name ? "aria-" : "";
                if (target.setAttribute) {
                    target.setAttribute(prefix + name, value)
                } else {
                    $target.attr(prefix + name, value)
                }
            },
            _createComponent: function() {
                return this.component._createComponent.apply(this.component, arguments)
            },
            getController: function(name) {
                return this.component._controllers[name]
            },
            createAction: function(actionName, config) {
                var action;
                if (commonUtils.isFunction(actionName)) {
                    action = this.component._createAction($.proxy(actionName, this), config);
                    return function(e) {
                        action({
                            jQueryEvent: e
                        })
                    }
                } else {
                    this._actions[actionName] = this.component._createActionByOption(actionName, config);
                    this._actionConfigs[actionName] = config
                }
            },
            executeAction: function(actionName, options) {
                var action = this._actions[actionName];
                return action && action(options)
            },
            dispose: function() {
                var that = this;
                $.each(that.callbackNames() || [], function() {
                    that[this].empty()
                })
            }
        });
        var Controller = ModuleItem;
        var ViewController = Controller.inherit({
            getView: function(name) {
                return this.component._views[name]
            },
            getViews: function() {
                return this.component._views
            }
        });
        var View = ModuleItem.inherit({
            _isReady: function() {
                return this.component.isReady()
            },
            _endUpdateCore: function() {
                this.callBase();
                if (!this._isReady() && this._requireReady) {
                    this._requireRender = false;
                    this.component._requireResize = false
                }
                if (this._requireRender) {
                    this._requireRender = false;
                    this.render(this._$parent)
                }
            },
            _invalidate: function(requireResize, requireReady) {
                this._requireRender = true;
                this.component._requireResize = this.component._requireResize || requireResize;
                this._requireReady = this._requireReady || requireReady
            },
            _renderCore: function(options) {},
            _resizeCore: function() {},
            _afterRender: function($root) {},
            _parentElement: function() {
                return this._$parent
            },
            ctor: function(component) {
                this.callBase(component);
                this.renderCompleted = $.Callbacks();
                this.resizeCompleted = $.Callbacks()
            },
            element: function() {
                return this._$element
            },
            isVisible: function() {
                return true
            },
            getTemplate: function(name) {
                return this.component._getTemplate(name)
            },
            render: function($parent, options) {
                var $element = this._$element,
                    isVisible = this.isVisible();
                this._requireReady = false;
                if (!$element) {
                    $element = this._$element = $("<div />").appendTo($parent);
                    this._$parent = $parent
                }
                $element.toggleClass("dx-hidden", !isVisible);
                if (isVisible) {
                    this.component._optionCache = {};
                    this._renderCore(options);
                    this.component._optionCache = void 0;
                    this._afterRender($parent);
                    this.renderCompleted.fire()
                }
            },
            resize: function() {
                this.isResizing = true;
                this._resizeCore();
                this.resizeCompleted.fire();
                this.isResizing = false
            },
            focus: function() {
                this.element().focus()
            }
        });
        var MODULES_ORDER_MAX_INDEX = 1e6;
        var processModules = function(that, componentClass) {
            var modules = componentClass.modules,
                modulesOrder = componentClass.modulesOrder,
                controllerTypes = componentClass.controllerTypes || {},
                viewTypes = componentClass.viewTypes || {};
            if (!componentClass.controllerTypes) {
                if (modulesOrder) {
                    modules.sort(function(module1, module2) {
                        var orderIndex1 = $.inArray(module1.name, modulesOrder);
                        var orderIndex2 = $.inArray(module2.name, modulesOrder);
                        if (orderIndex1 < 0) {
                            orderIndex1 = MODULES_ORDER_MAX_INDEX
                        }
                        if (orderIndex2 < 0) {
                            orderIndex2 = MODULES_ORDER_MAX_INDEX
                        }
                        return orderIndex1 - orderIndex2
                    })
                }
                $.each(modules, function() {
                    var controllers = this.controllers,
                        moduleName = this.name,
                        views = this.views;
                    controllers && $.each(controllers, function(name, type) {
                        if (controllerTypes[name]) {
                            throw errors.Error("E1001", moduleName, name)
                        } else {
                            if (!(type && type.subclassOf && type.subclassOf(Controller))) {
                                type.subclassOf(Controller);
                                throw errors.Error("E1002", moduleName, name)
                            }
                        }
                        controllerTypes[name] = type
                    });
                    views && $.each(views, function(name, type) {
                        if (viewTypes[name]) {
                            throw errors.Error("E1003", moduleName, name)
                        } else {
                            if (!(type && type.subclassOf && type.subclassOf(View))) {
                                throw errors.Error("E1004", moduleName, name)
                            }
                        }
                        viewTypes[name] = type
                    })
                });
                $.each(modules, function() {
                    var extenders = this.extenders;
                    if (extenders) {
                        extenders.controllers && $.each(extenders.controllers, function(name, extender) {
                            if (controllerTypes[name]) {
                                controllerTypes[name] = controllerTypes[name].inherit(extender)
                            }
                        });
                        extenders.views && $.each(extenders.views, function(name, extender) {
                            if (viewTypes[name]) {
                                viewTypes[name] = viewTypes[name].inherit(extender)
                            }
                        })
                    }
                });
                componentClass.controllerTypes = controllerTypes;
                componentClass.viewTypes = viewTypes
            }
            var registerPublicMethods = function(that, name, moduleItem) {
                var publicMethods = moduleItem.publicMethods();
                if (publicMethods) {
                    $.each(publicMethods, function(index, methodName) {
                        if (moduleItem[methodName]) {
                            if (!that[methodName]) {
                                that[methodName] = function() {
                                    return moduleItem[methodName].apply(moduleItem, arguments)
                                }
                            } else {
                                throw errors.Error("E1005", methodName)
                            }
                        } else {
                            throw errors.Error("E1006", name, methodName)
                        }
                    })
                }
            };
            var createModuleItems = function(moduleTypes) {
                var moduleItems = {};
                $.each(moduleTypes, function(name, moduleType) {
                    var moduleItem = new moduleType(that);
                    moduleItem.name = name;
                    registerPublicMethods(that, name, moduleItem);
                    moduleItems[name] = moduleItem
                });
                return moduleItems
            };
            that._controllers = createModuleItems(controllerTypes);
            that._views = createModuleItems(viewTypes)
        };
        var callModuleItemsMethod = function(that, methodName, args) {
            args = args || [];
            if (that._controllers) {
                $.each(that._controllers, function() {
                    this[methodName] && this[methodName].apply(this, args)
                })
            }
            if (that._views) {
                $.each(that._views, function() {
                    this[methodName] && this[methodName].apply(this, args)
                })
            }
        };
        $.extend(exports, function() {
            return {
                modules: [],
                View: View,
                ViewController: ViewController,
                Controller: Controller,
                registerModule: function(name, module) {
                    var i, modules = this.modules;
                    for (i = 0; i < modules.length; i++) {
                        if (modules[i].name === name) {
                            return
                        }
                    }
                    module.name = name;
                    modules.push(module);
                    delete this.controllerTypes, delete this.viewTypes
                },
                registerModulesOrder: function(moduleNames) {
                    this.modulesOrder = moduleNames
                },
                unregisterModule: function(name) {
                    this.modules = $.grep(this.modules, function(module) {
                        return module.name !== name
                    });
                    delete this.controllerTypes, delete this.viewTypes
                },
                processModules: processModules,
                callModuleItemsMethod: callModuleItemsMethod
            }
        }());
        exports.CallBacks = CallBacks
    },
    /*!******************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.column_headers_view.js ***!
      \******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            columnsView = __webpack_require__( /*! ./ui.data_grid.columns_view */ 340),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var DATAGRID_CELL_CONTENT_CLASS = "dx-datagrid-text-content",
            DATAGRID_HEADERS_CLASS = "dx-datagrid-headers",
            DATAGRID_HEADER_ROW_CLASS = "dx-header-row",
            DATAGRID_NOWRAP_CLASS = "dx-datagrid-nowrap",
            DATAGRID_COLUMN_LINES_CLASS = "dx-column-lines",
            DATAGRID_CONTEXT_MENU_SORT_ASC_ICON = "context-menu-sort-asc",
            DATAGRID_CONTEXT_MENU_SORT_DESC_ICON = "context-menu-sort-desc",
            DATAGRID_CONTEXT_MENU_SORT_NONE_ICON = "context-menu-sort-none",
            DATAGRID_CELL_FOCUS_DISABLED_CLASS = "dx-cell-focus-disabled",
            DATAGRID_COLUMN_INDICATORS_CLASS = "dx-column-indicators";
        var createCellContent = function($cell, showColumnLines) {
            return $("<div />").addClass(DATAGRID_CELL_CONTENT_CLASS).appendTo($cell)
        };
        exports.ColumnHeadersView = columnsView.ColumnsView.inherit({
            _getDefaultTemplate: function(column) {
                var template, that = this,
                    showColumnLines = that.option("showColumnLines");
                if (column.command) {
                    template = function($container, options) {
                        var column = options.column;
                        $container.html("&nbsp;");
                        $container.addClass(column.cssClass)
                    }
                } else {
                    template = function($container, options) {
                        var $content = createCellContent($container, showColumnLines);
                        $content.text(column.caption)
                    }
                }
                return template
            },
            _getHeaderTemplate: function(column) {
                return !column.command && column.headerCellTemplate || {
                    allowRenderToDetachedContainer: true,
                    render: this._getDefaultTemplate(column)
                }
            },
            _processTemplate: function(template, options) {
                var resultTemplate, that = this,
                    column = options.column,
                    renderingTemplate = this.callBase(template);
                if (renderingTemplate && column.headerCellTemplate) {
                    resultTemplate = {
                        render: function(options) {
                            var $content = createCellContent(options.container, that.option("showColumnLines"));
                            renderingTemplate.render($.extend({}, options, {
                                container: $content
                            }))
                        }
                    }
                } else {
                    resultTemplate = renderingTemplate
                }
                return resultTemplate
            },
            _handleDataChanged: function(e) {
                if (this._isGroupingChanged || this._requireReady) {
                    this._isGroupingChanged = false;
                    this.render()
                }
            },
            _renderCell: function($row, options) {
                var $cell = this.callBase($row, options);
                if ("header" === options.row.rowType) {
                    $cell.addClass(DATAGRID_CELL_FOCUS_DISABLED_CLASS);
                    if (!commonUtils.isDefined(options.column.command)) {
                        this.setAria("role", "columnheader", $cell);
                        this.setAria("label", options.column.caption + " " + messageLocalization.format("dxDataGrid-ariaColumn"), $cell)
                    }
                }
                return $cell
            },
            _createRow: function(row) {
                var $row = this.callBase(row).toggleClass(DATAGRID_COLUMN_LINES_CLASS, this.option("showColumnLines"));
                if ("header" === row.rowType) {
                    $row.addClass(DATAGRID_HEADER_ROW_CLASS)
                }
                return $row
            },
            _renderCore: function() {
                var that = this,
                    $container = that.element();
                if (that._tableElement && !that._dataController.isLoaded()) {
                    return
                }
                $container.addClass(DATAGRID_HEADERS_CLASS).toggleClass(DATAGRID_NOWRAP_CLASS, !that.option("wordWrapEnabled")).empty();
                that._updateContent(that._renderTable());
                that.callBase.apply(that, arguments)
            },
            _renderRows: function() {
                var that = this;
                if (that._dataController.isLoaded()) {
                    that.callBase.apply(that, arguments)
                }
            },
            _getRowVisibleColumns: function(rowIndex) {
                return this._columnsController.getVisibleColumns(rowIndex)
            },
            _renderRow: function($table, options) {
                options.columns = this._getRowVisibleColumns(options.row.rowIndex);
                this.callBase($table, options)
            },
            _createCell: function(options) {
                var column = options.column,
                    $cellElement = this.callBase.apply(this, arguments);
                column.rowspan > 1 && $cellElement.attr("rowspan", column.rowspan);
                return $cellElement
            },
            _getRows: function() {
                var i, result = [],
                    rowCount = this.getRowCount();
                if (this.option("showColumnHeaders")) {
                    for (i = 0; i < rowCount; i++) {
                        result.push({
                            rowType: "header",
                            rowIndex: i
                        })
                    }
                }
                return result
            },
            _getCellTemplate: function(options) {
                if ("header" === options.rowType) {
                    return this._getHeaderTemplate(options.column)
                }
            },
            _columnOptionChanged: function(e) {
                var changeTypes = e.changeTypes,
                    optionNames = e.optionNames,
                    showColumnLines = this.option("showColumnLines");
                if (changeTypes.grouping) {
                    this._isGroupingChanged = true;
                    return
                }
                this.callBase(e);
                if (optionNames.width || optionNames.visibleWidth) {
                    !showColumnLines && this._updateColumnTextWidths();
                    this.resizeCompleted.fire()
                }
            },
            _updateColumnTextWidths: function() {
                var indicatorWidth, $indicatorContainer, that = this,
                    widths = [],
                    columns = that.getColumns(),
                    $cells = that.getColumnElements();
                if (!$cells) {
                    return
                }
                $.each(columns, function(index, column) {
                    indicatorWidth = 0;
                    $indicatorContainer = that._getIndicatorContainer($($cells[index]));
                    if ($indicatorContainer.length) {
                        indicatorWidth = $indicatorContainer.outerWidth()
                    }
                    widths[index] = $($cells[index]).width() - ("center" === column.alignment ? 2 * indicatorWidth : indicatorWidth)
                });
                $.each($cells, function(index, cell) {
                    if (widths.length && widths[index] > 0) {
                        $(cell).find("." + DATAGRID_CELL_CONTENT_CLASS).css("max-width", widths[index])
                    }
                })
            },
            _isElementVisible: function(elementOptions) {
                return elementOptions && elementOptions.visible
            },
            getHeadersRowHeight: function() {
                var $tableElement = this._getTableElement(),
                    $headerRows = $tableElement && $tableElement.find("." + DATAGRID_HEADER_ROW_CLASS);
                if ($headerRows && $headerRows.length) {
                    return $headerRows.first().height() * $headerRows.length
                }
                return 0
            },
            getHeaderElement: function(index) {
                var columnElements = this.getColumnElements();
                return columnElements && columnElements.eq(index)
            },
            getColumnElements: function(index, bandColumnIndex) {
                var rowIndex, result, $cellElement, visibleColumns, that = this,
                    columnsController = that._columnsController,
                    rowCount = that.getRowCount();
                if (that.option("showColumnHeaders")) {
                    if (rowCount > 1 && (!commonUtils.isDefined(index) || commonUtils.isDefined(bandColumnIndex))) {
                        result = $();
                        visibleColumns = commonUtils.isDefined(bandColumnIndex) ? columnsController.getChildrenByBandColumn(bandColumnIndex, index) : columnsController.getVisibleColumns();
                        $.each(visibleColumns, function(_, column) {
                            rowIndex = commonUtils.isDefined(index) ? index : columnsController.getRowIndex(column.index);
                            $cellElement = that.getCellElement(rowIndex, columnsController.getVisibleIndex(column.index, rowIndex));
                            $cellElement && result.push($cellElement.get(0))
                        });
                        return result
                    } else {
                        if (!index || index < rowCount) {
                            return that.getCellElements(index || 0)
                        }
                    }
                }
            },
            getColumnWidths: function() {
                var indicatorWidth, $indicatorElements, that = this,
                    resultWidths = [],
                    columns = that.getColumns(),
                    $columnElements = that.getColumnElements();
                if ($columnElements && $columnElements.length) {
                    resultWidths = that._getWidths($columnElements);
                    if (that.option("showColumnLines")) {
                        $.each($columnElements, function(index, columnElement) {
                            $indicatorElements = $(columnElement).find("." + DATAGRID_COLUMN_INDICATORS_CLASS);
                            if ($indicatorElements.length) {
                                $.each($indicatorElements.children(), function(_, indicator) {
                                    if ("none" !== $(indicator).css("display")) {
                                        indicatorWidth = $indicatorElements.outerWidth(true);
                                        resultWidths[index] += "center" === columns[index].alignment ? 2 * indicatorWidth : indicatorWidth;
                                        return false
                                    }
                                })
                            }
                        })
                    }
                    return resultWidths
                }
                return this.callBase.apply(that, arguments)
            },
            allowDragging: function(column, sourceLocation, draggingPanels) {
                var i, draggingPanel, rowIndex = column && this._columnsController.getRowIndex(column.index),
                    columns = this.getColumns(0 === rowIndex ? 0 : null),
                    draggableColumnCount = 0,
                    allowDrag = function(column) {
                        return column.allowReordering || column.allowGrouping || column.allowHiding
                    };
                for (i = 0; i < columns.length; i++) {
                    if (allowDrag(columns[i])) {
                        draggableColumnCount++
                    }
                }
                if (draggableColumnCount <= 1) {
                    return false
                } else {
                    if (!draggingPanels) {
                        return (this.option("allowColumnReordering") || this._columnsController.isColumnOptionUsed("allowReordering")) && column && column.allowReordering
                    }
                }
                for (i = 0; i < draggingPanels.length; i++) {
                    draggingPanel = draggingPanels[i];
                    if (draggingPanel && draggingPanel.allowDragging(column, sourceLocation)) {
                        return true
                    }
                }
                return false
            },
            getBoundingRect: function() {
                var offset, that = this,
                    $columnElements = that.getColumnElements();
                if ($columnElements && $columnElements.length) {
                    offset = that._getTableElement().offset();
                    return {
                        top: offset.top
                    }
                }
                return null
            },
            getName: function() {
                return "headers"
            },
            getColumnCount: function() {
                var $columnElements = this.getColumnElements();
                return $columnElements ? $columnElements.length : 0
            },
            isVisible: function() {
                return this.option("showColumnHeaders")
            },
            optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "showColumnHeaders":
                    case "wordWrapEnabled":
                    case "showColumnLines":
                        that._invalidate(true, true);
                        args.handled = true;
                        break;
                    default:
                        that.callBase(args)
                }
            },
            getHeight: function() {
                var $element = this.element();
                return $element ? $element.outerHeight(true) : 0
            },
            getContextMenuItems: function(options) {
                var onItemClick, sortingOptions, that = this,
                    column = options.column;
                if (options.row && "header" === options.row.rowType) {
                    sortingOptions = that.option("sorting");
                    if (sortingOptions && "none" !== sortingOptions.mode && column && column.allowSorting) {
                        onItemClick = function(params) {
                            setTimeout(function() {
                                that._columnsController.changeSortOrder(column.index, params.itemData.value)
                            })
                        };
                        return [{
                            text: sortingOptions.ascendingText,
                            value: "asc",
                            disabled: "asc" === column.sortOrder,
                            icon: DATAGRID_CONTEXT_MENU_SORT_ASC_ICON,
                            onItemClick: onItemClick
                        }, {
                            text: sortingOptions.descendingText,
                            value: "desc",
                            disabled: "desc" === column.sortOrder,
                            icon: DATAGRID_CONTEXT_MENU_SORT_DESC_ICON,
                            onItemClick: onItemClick
                        }, {
                            text: sortingOptions.clearText,
                            value: "none",
                            disabled: !column.sortOrder,
                            icon: DATAGRID_CONTEXT_MENU_SORT_NONE_ICON,
                            onItemClick: onItemClick
                        }]
                    }
                }
            },
            getRowCount: function() {
                return this._columnsController && this._columnsController.getRowCount()
            },
            setRowsOpacity: function(columnIndex, value, rowIndex) {
                var i, columnElements, that = this,
                    rowCount = that.getRowCount(),
                    columns = that._columnsController.getColumns(),
                    column = columns && columns[columnIndex],
                    columnID = column && column.isBand && column.index,
                    setColumnOpacity = function(index, column) {
                        if (column.ownerBand === columnID) {
                            columnElements.eq(index).css({
                                opacity: value
                            });
                            if (column.isBand) {
                                that.setRowsOpacity(column.index, value, i + 1)
                            }
                        }
                    };
                if (commonUtils.isDefined(columnID)) {
                    rowIndex = rowIndex || 0;
                    for (i = rowIndex; i < rowCount; i++) {
                        columnElements = that.getCellElements(i);
                        $.each(that.getColumns(i), setColumnOpacity)
                    }
                }
            }
        });
        gridCore.registerModule("columnHeaders", {
            defaultOptions: function() {
                return {
                    showColumnHeaders: true,
                    cellHintEnabled: true
                }
            },
            views: {
                columnHeadersView: exports.ColumnHeadersView
            }
        })
    },
    /*!***********************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.columns_view.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341);
        var DATAGRID_SCROLL_CONTAINER_CLASS = "dx-datagrid-scroll-container",
            DATAGRID_ROW_CLASS = "dx-row",
            DATAGRID_GROUP_SPACE_CLASS = "dx-datagrid-group-space",
            DATAGRID_GROUP_ROW_CLASS = "dx-group-row",
            DATAGRID_DETAIL_ROW_CLASS = "dx-master-detail-row",
            DATAGRID_CONTENT_CLASS = "dx-datagrid-content",
            DATAGRID_TABLE_CLASS = "dx-datagrid-table",
            DATAGRID_TABLE_FIXED_CLASS = "dx-datagrid-table-fixed",
            DATAGRID_CONTENT_FIXED_CLASS = "dx-datagrid-content-fixed",
            DATAGRID_HIDDEN_COLUMNS_WIDTH = "0.0001px",
            DATAGRID_CELL_HINT_VISIBLE = "dxCellHintVisible";
        var appendElementTemplate = {
            render: function(options) {
                options.container.append(options.content)
            }
        };
        exports.ColumnsView = gridCore.View.inherit(gridCoreUtils.columnStateMixin).inherit({
            _createScrollableOptions: function() {
                var that = this,
                    scrollingOptions = that.option("scrolling"),
                    useNativeScrolling = that.option("scrolling.useNative");
                var options = $.extend({}, scrollingOptions, {
                    direction: "both",
                    bounceEnabled: false,
                    useKeyboard: false
                });
                if (void 0 === useNativeScrolling) {
                    useNativeScrolling = true
                }
                if ("auto" === useNativeScrolling) {
                    delete options.useNative;
                    delete options.useSimulatedScrollbar
                } else {
                    options.useNative = !!useNativeScrolling;
                    options.useSimulatedScrollbar = !useNativeScrolling
                }
                return options
            },
            _updateCell: function($cell, parameters) {
                if (parameters.rowType) {
                    this._cellPrepared($cell, parameters)
                }
            },
            _createCell: function(options) {
                var column = options.column,
                    alignment = column.alignment || commonUtils.getDefaultAlignment(this.option("rtlEnabled"));
                var cell = window.document.createElement("td");
                cell.style.textAlign = alignment;
                var $cell = $(cell);
                this.setAria("role", "gridcell", $cell);
                if (!commonUtils.isDefined(column.groupIndex) && column.cssClass) {
                    $cell.addClass(column.cssClass)
                }
                if ("expand" === column.command) {
                    $cell.addClass(DATAGRID_GROUP_SPACE_CLASS)
                }
                column.colspan > 1 && $cell.attr("colspan", column.colspan);
                return $cell
            },
            _createRow: function(row) {
                return $("<tr />").addClass(DATAGRID_ROW_CLASS).attr("role", "row")
            },
            _createTable: function(columns) {
                var that = this,
                    $table = $("<table />").addClass(DATAGRID_TABLE_CLASS).addClass(DATAGRID_TABLE_FIXED_CLASS).attr("role", "grid");
                if (columns) {
                    $table.append(that._createColGroup(columns));
                    if (devices.real().ios) {
                        $table.append("<thead><tr></tr></thead>")
                    }
                }
                if (browser.mozilla) {
                    $table.on("mousedown", "td", function(e) {
                        if (e.ctrlKey) {
                            e.preventDefault()
                        }
                    })
                }
                if (that.option("cellHintEnabled")) {
                    $table.on("mousemove", ".dx-row > td", this.createAction(function(args) {
                        var e = args.jQueryEvent,
                            $element = $(e.target),
                            $cell = $(e.currentTarget),
                            $row = $cell.parent(),
                            isDataRow = $row.hasClass("dx-data-row"),
                            isHeaderRow = $row.hasClass("dx-header-row"),
                            isGroupRow = $row.hasClass("dx-group-row"),
                            visibleColumns = that._columnsController.getVisibleColumns(),
                            rowOptions = $row.data("options"),
                            columnIndex = $cell.index(),
                            cellOptions = rowOptions && rowOptions.cells && rowOptions.cells[columnIndex],
                            column = cellOptions ? cellOptions.column : visibleColumns[columnIndex];
                        if ((!isDataRow || isDataRow && column && !column.cellTemplate) && (!isHeaderRow || isHeaderRow && column && !column.headerCellTemplate) && (!isGroupRow || isGroupRow && column && (void 0 === column.groupIndex || !column.groupCellTemplate))) {
                            if ($element.data(DATAGRID_CELL_HINT_VISIBLE)) {
                                $element.removeAttr("title");
                                $element.data(DATAGRID_CELL_HINT_VISIBLE, false)
                            }
                            if ($element[0].scrollWidth > $element[0].clientWidth && !commonUtils.isDefined($element.attr("title"))) {
                                $element.attr("title", $element.text());
                                $element.data(DATAGRID_CELL_HINT_VISIBLE, true)
                            }
                        }
                    }))
                }
                var getOptions = function(event) {
                    var cellElement = $(event.currentTarget),
                        rowOptions = cellElement.parent().data("options"),
                        options = rowOptions && rowOptions.cells && rowOptions.cells[cellElement.index()];
                    return $.extend({}, options, {
                        cellElement: cellElement,
                        jQueryEvent: event,
                        eventType: event.type
                    })
                };
                if (that.option("onCellHoverChanged")) {
                    $table.on("mouseover", ".dx-row > td", function(e) {
                        that.executeAction("onCellHoverChanged", getOptions(e))
                    });
                    $table.on("mouseout", ".dx-row > td", function(e) {
                        that.executeAction("onCellHoverChanged", getOptions(e))
                    })
                }
                if (that.option("onCellClick")) {
                    $table.on(clickEvent.name, ".dx-row > td", function(e) {
                        that.executeAction("onCellClick", getOptions(e))
                    })
                }
                $table.on(clickEvent.name, ".dx-row", {
                    useNative: that._isNativeClick()
                }, that.createAction(function(e) {
                    var jQueryEvent = e.jQueryEvent;
                    if (!$(jQueryEvent.target).closest("a").length) {
                        e.rowIndex = that.getRowIndex(jQueryEvent.currentTarget);
                        if (e.rowIndex >= 0) {
                            e.rowElement = $(jQueryEvent.currentTarget);
                            e.columns = that.getColumns();
                            that._rowClick(e)
                        }
                    }
                }));
                return $table
            },
            _isNativeClick: $.noop,
            _rowClick: $.noop,
            _createColGroup: function(columns) {
                var i, j, colspan, colgroupElement = $("<colgroup />");
                for (i = 0; i < columns.length; i++) {
                    colspan = columns[i].colspan || 1;
                    for (j = 0; j < colspan; j++) {
                        colgroupElement.append(this._createCol(columns[i]))
                    }
                }
                return colgroupElement
            },
            _createCol: function(column) {
                var width = column.visibleWidth || column.width;
                if ("adaptiveHidden" === width) {
                    width = DATAGRID_HIDDEN_COLUMNS_WIDTH
                }
                return $("<col />").width(width)
            },
            renderDelayedTemplates: function() {
                var templateParameters, delayedTemplates = this._delayedTemplates;
                while (delayedTemplates.length) {
                    templateParameters = delayedTemplates.shift();
                    templateParameters.template.render(templateParameters.options);
                    if (templateParameters.options.model && templateParameters.options.model.column) {
                        this._updateCell(templateParameters.options.container, templateParameters.options.model)
                    }
                }
            },
            _processTemplate: function(template) {
                var templateID, renderingTemplate, that = this;
                if (template && template.render) {
                    renderingTemplate = {
                        allowRenderToDetachedContainer: template.allowRenderToDetachedContainer,
                        render: function(options) {
                            template.render(options.container, options.model)
                        }
                    }
                } else {
                    if ($.isFunction(template)) {
                        renderingTemplate = {
                            render: function(options) {
                                template(options.container, options.model)
                            }
                        }
                    } else {
                        templateID = commonUtils.isString(template) ? template : $(template).attr("id");
                        if (!templateID) {
                            renderingTemplate = that.getTemplate(template)
                        } else {
                            if (!that._templatesCache[templateID]) {
                                that._templatesCache[templateID] = that.getTemplate(template)
                            }
                            renderingTemplate = that._templatesCache[templateID]
                        }
                    }
                }
                return renderingTemplate
            },
            renderTemplate: function(container, template, options) {
                var that = this,
                    renderingTemplate = that._processTemplate(template, options);
                if (renderingTemplate) {
                    if (renderingTemplate.allowRenderToDetachedContainer) {
                        renderingTemplate.render({
                            container: container,
                            model: options
                        });
                        return true
                    } else {
                        that._delayedTemplates.push({
                            template: renderingTemplate,
                            options: {
                                container: container,
                                model: options
                            }
                        })
                    }
                }
                return false
            },
            _appendRow: function($table, $row, appendTemplate) {
                var that = this;
                if (that.option("rowTemplate") && that._delayedTemplates.length && $row) {
                    that._delayedTemplates.push({
                        options: {
                            container: $table,
                            content: $row
                        },
                        template: appendTemplate || appendElementTemplate
                    })
                } else {
                    $table.append($row)
                }
            },
            _resizeCore: function() {
                var that = this,
                    scrollLeft = that._scrollLeft;
                that._scrollLeft = 0;
                that.scrollTo({
                    left: scrollLeft
                })
            },
            _renderCore: function(change) {
                var $root = this.element().parent();
                if (!$root || $root.parent().length) {
                    this.renderDelayedTemplates()
                }
            },
            _renderTable: function(options) {
                options = options || {};
                var $table, that = this;
                options.columns = that._columnsController.getVisibleColumns();
                $table = that._createTable(options.columns);
                that._renderRows($table, options);
                return $table
            },
            _renderRows: function($table, options) {
                var i, that = this,
                    rows = that._getRows(options.change);
                for (i = 0; i < rows.length; i++) {
                    that._renderRow($table, $.extend({
                        row: rows[i]
                    }, options))
                }
            },
            _renderRow: function($table, options) {
                var $row, that = this;
                options.row.cells = [];
                $row = that._createRow(options.row);
                that._renderCells($row, options);
                that._appendRow($table, $row);
                that._rowPrepared($row, $.extend({
                    columns: options.columns
                }, options.row))
            },
            _renderCells: function($row, options) {
                var i, that = this,
                    columnIndex = 0,
                    row = options.row,
                    columns = options.columns;
                for (i = 0; i < columns.length; i++) {
                    that._renderCell($row, $.extend({
                        column: columns[i],
                        columnIndex: columnIndex,
                        value: row.values && row.values[columnIndex]
                    }, options));
                    if (columns[i].colspan > 1) {
                        columnIndex += columns[i].colspan
                    } else {
                        columnIndex++
                    }
                }
            },
            _renderCell: function($row, options) {
                var $cell, that = this,
                    cellOptions = that._getCellOptions(options),
                    column = options.column;
                options.row.cells.push(cellOptions);
                $cell = that._createCell(cellOptions);
                if (!column.command) {
                    that.setAria("label", that.localize("dxDataGrid-ariaColumn") + " " + column.caption + ", " + that.localize("dxDataGrid-ariaValue") + " " + cellOptions.text, $cell)
                }
                that._renderCellContent($cell, cellOptions);
                $row.get(0).appendChild($cell.get(0));
                return $cell
            },
            _renderCellContent: function($cell, options) {
                var template = this._getCellTemplate(options);
                if (!template || this.renderTemplate($cell, template, options)) {
                    this._updateCell($cell, options)
                }
            },
            _getCellTemplate: function(options) {},
            _getRows: function() {
                return []
            },
            _getCellOptions: function(options) {
                return {
                    column: options.column,
                    columnIndex: options.columnIndex,
                    rowType: options.row.rowType
                }
            },
            _cellPrepared: function($cell, options) {
                options.cellElement = $cell;
                this.executeAction("onCellPrepared", options)
            },
            _rowPrepared: function($row, options) {
                $.data($row.get(0), "options", options);
                options.rowElement = $row;
                this.executeAction("onRowPrepared", options)
            },
            _columnOptionChanged: function(e) {
                var optionNames = e.optionNames;
                if (gridCore.checkChanges(optionNames, ["width", "visibleWidth"])) {
                    var visibleColumns = this._columnsController.getVisibleColumns();
                    var widths = $.map(visibleColumns, function(column) {
                        return column.visibleWidth || column.width || "auto"
                    });
                    this.setColumnWidths(widths);
                    return
                }
                if (!this._requireReady) {
                    this.render()
                }
            },
            getTableElements: function() {
                return this._tableElement || $()
            },
            _getTableElement: function() {
                return this._tableElement
            },
            _setTableElement: function(tableElement) {
                this._tableElement = tableElement
            },
            optionChanged: function(args) {
                this.callBase(args);
                switch (args.name) {
                    case "cellHintEnabled":
                    case "onCellPrepared":
                    case "onRowPrepared":
                    case "onCellHoverChanged":
                        this._invalidate(true, true);
                        args.handled = true
                }
            },
            init: function() {
                var that = this;
                that._scrollLeft = 0;
                that._columnsController = that.getController("columns");
                that._dataController = that.getController("data");
                that._delayedTemplates = [];
                that._templatesCache = {};
                that.createAction("onCellClick");
                that.createAction("onRowClick");
                that.createAction("onCellHoverChanged", {
                    excludeValidators: ["disabled", "readOnly"]
                });
                that.createAction("onCellPrepared", {
                    excludeValidators: ["designMode", "disabled", "readOnly"],
                    category: "rendering"
                });
                that.createAction("onRowPrepared", {
                    excludeValidators: ["designMode", "disabled", "readOnly"],
                    category: "rendering",
                    afterExecute: function(e) {
                        that._afterRowPrepared(e)
                    }
                });
                that._columnsController.columnsChanged.add($.proxy(that._columnOptionChanged, that));
                that._dataController && that._dataController.changed.add($.proxy(that._handleDataChanged, that))
            },
            _afterRowPrepared: $.noop,
            _handleDataChanged: function(e) {},
            callbackNames: function() {
                return ["scrollChanged"]
            },
            scrollTo: function(pos) {
                var that = this,
                    $element = that.element(),
                    $scrollContainer = $element && $element.children("." + DATAGRID_SCROLL_CONTAINER_CLASS).not("." + DATAGRID_CONTENT_FIXED_CLASS);
                that._skipScrollChanged = false;
                if (commonUtils.isDefined(pos) && commonUtils.isDefined(pos.left) && that._scrollLeft !== pos.left) {
                    that._scrollLeft = pos.left;
                    $scrollContainer && $scrollContainer.scrollLeft(Math.round(pos.left));
                    that._skipScrollChanged = true
                }
            },
            _wrapTableInScrollContainer: function($table) {
                var $scrollContainer, that = this;
                $scrollContainer = $("<div/>").on("scroll", function() {
                    !that._skipScrollChanged && that.scrollChanged.fire({
                        left: $scrollContainer.scrollLeft()
                    }, that.name);
                    that._skipScrollChanged = false
                }).addClass(DATAGRID_CONTENT_CLASS).addClass(DATAGRID_SCROLL_CONTAINER_CLASS).append($table).appendTo(that.element());
                return $scrollContainer
            },
            _updateContent: function($newTableElement) {
                this._setTableElement($newTableElement);
                this._wrapTableInScrollContainer($newTableElement)
            },
            _findContentElement: $.noop,
            _getWidths: function($cellElements) {
                var width, clientRect, result = [];
                if ($cellElements) {
                    $.each($cellElements, function(index, item) {
                        width = item.offsetWidth;
                        if (item.getBoundingClientRect) {
                            clientRect = item.getBoundingClientRect();
                            if (clientRect.width > width) {
                                width = Math.ceil(clientRect.width)
                            }
                        }
                        result.push(width)
                    })
                }
                return result
            },
            getColumnWidths: function($tableElement) {
                var $cells, that = this,
                    result = [];
                $tableElement = $tableElement || that._getTableElement();
                if ($tableElement) {
                    $cells = $tableElement.children("tbody").children(":not(." + DATAGRID_GROUP_ROW_CLASS + ", ." + DATAGRID_DETAIL_ROW_CLASS + ")").first().children("td");
                    result = that._getWidths($cells)
                }
                return result
            },
            setColumnWidths: function(widths) {
                var $cols, i, j, columnIndex, columns, width, tableElements = this.getTableElements(true);
                if (tableElements.length && widths) {
                    for (i = 0; i < tableElements.length; i++) {
                        columnIndex = 0;
                        $cols = $(tableElements[i]).find("col");
                        columns = this.getColumns(null, $(tableElements[i]));
                        for (j = 0; j < columns.length; j++) {
                            if (columns[j].colspan) {
                                columnIndex += columns[j].colspan;
                                continue
                            }
                            width = widths[columnIndex];
                            if ("adaptiveHidden" === width) {
                                width = DATAGRID_HIDDEN_COLUMNS_WIDTH
                            }
                            $cols.eq(columnIndex).css("width", width || "auto");
                            columnIndex++
                        }
                    }
                }
            },
            getCellElements: function(rowIndex) {
                var $row = this._getRowElements().eq(rowIndex);
                return $row.children()
            },
            getCellElement: function(rowIndex, columnIdentificator) {
                var $cell, columnIndex, that = this,
                    $cells = that.getCellElements(rowIndex),
                    columnsController = that._columnsController,
                    columnVisibleIndex = columnIdentificator;
                if (commonUtils.isString(columnIdentificator)) {
                    columnIndex = columnsController.columnOption(columnIdentificator, "index");
                    columnVisibleIndex = columnsController.getVisibleIndex(columnIndex)
                }
                if ($cells.length && columnVisibleIndex >= 0) {
                    $cell = $cells.eq(columnVisibleIndex)
                }
                if ($cell && $cell.length) {
                    return $cell
                }
            },
            getColumnElements: function() {},
            getColumns: function(rowIndex) {
                return this._columnsController.getVisibleColumns(rowIndex)
            },
            getCell: function(cellPosition, rows) {
                var $cells, $rows = rows || this._getRowElements();
                if ($rows.length > 0 && cellPosition.rowIndex >= 0) {
                    cellPosition.rowIndex = cellPosition.rowIndex < $rows.length ? cellPosition.rowIndex : $rows.length - 1;
                    $cells = this.getCellElements(cellPosition.rowIndex);
                    if ($cells && $cells.length > 0) {
                        return $cells.eq($cells.length > cellPosition.columnIndex ? cellPosition.columnIndex : $cells.length - 1)
                    }
                }
            },
            getRowsCount: function() {
                var tableElement = this._getTableElement();
                if (tableElement && 1 === tableElement.length) {
                    return tableElement[0].rows.length
                }
                return 0
            },
            _getRowElements: function(tableElement) {
                tableElement = tableElement || this._getTableElement();
                return tableElement && tableElement.children("tbody").children("." + DATAGRID_ROW_CLASS) || $()
            },
            getRowIndex: function($row) {
                return this._getRowElements().index($row)
            },
            getBoundingRect: function() {},
            getName: function() {},
            setScrollerSpacing: function(width) {
                var that = this,
                    $element = that.element(),
                    rtlEnabled = that.option("rtlEnabled");
                $element && $element.css(rtlEnabled ? {
                    paddingLeft: width
                } : {
                    paddingRight: width
                })
            }
        })
    },
    /*!****************************************************!*\
      !*** ./Scripts/ui/grid_core/ui.grid_core.utils.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            LoadPanel = __webpack_require__( /*! ../load_panel */ 239);
        var DATAGRID_NODATA_TEXT_CLASS = "dx-datagrid-nodata",
            DATAGRID_INDICATOR_ALIGNMENT_CLASS = "dx-indicator-alignment-",
            DATAGRID_COLUMN_INDICATORS_CLASS = "dx-column-indicators",
            DATAGRID_GROUP_PANEL_ITEM_CLASS = "dx-group-panel-item";
        exports.renderNoDataText = function($element) {
            var that = this;
            $element = $element || this.element();
            var noDataElement = $element.find("." + DATAGRID_NODATA_TEXT_CLASS),
                isVisible = this._dataController.isEmpty(),
                isLoading = this._dataController.isLoading(),
                rtlEnabled = this.option("rtlEnabled");
            if (!noDataElement.length) {
                noDataElement = $("<span>").addClass(DATAGRID_NODATA_TEXT_CLASS).appendTo($element)
            }
            if (isVisible && !isLoading) {
                noDataElement.removeClass("dx-hidden").text(that._getNoDataText());
                commonUtils.deferUpdate(function() {
                    var noDataHeight = noDataElement.height(),
                        noDataWidth = noDataElement.width();
                    commonUtils.deferRender(function() {
                        noDataElement.css({
                            marginTop: -Math.floor(noDataHeight / 2),
                            marginRight: rtlEnabled ? -Math.floor(noDataWidth / 2) : 0,
                            marginLeft: rtlEnabled ? 0 : -Math.floor(noDataWidth / 2)
                        })
                    })
                })
            } else {
                noDataElement.addClass("dx-hidden")
            }
        };
        exports.renderLoadPanel = function($element, $container, isLocalStore) {
            var loadPanelOptions, that = this;
            that._loadPanel && that._loadPanel.element().remove();
            loadPanelOptions = that.option("loadPanel");
            if (loadPanelOptions && ("auto" === loadPanelOptions.enabled ? !isLocalStore : loadPanelOptions.enabled)) {
                loadPanelOptions = $.extend({
                    shading: false,
                    message: loadPanelOptions.text,
                    position: {
                        of: $element
                    },
                    container: $element
                }, loadPanelOptions);
                that._loadPanel = that._createComponent($("<div>").appendTo($container), LoadPanel, loadPanelOptions)
            } else {
                that._loadPanel = null
            }
        };
        exports.columnStateMixin = {
            _applyColumnState: function(options) {
                var that = this,
                    rtlEnabled = this.option("rtlEnabled"),
                    columnAlignment = that._getColumnAlignment(options.column.alignment, rtlEnabled),
                    parameters = $.extend(true, {
                        columnAlignment: columnAlignment
                    }, options),
                    isGroupPanelItem = parameters.rootElement.hasClass(DATAGRID_GROUP_PANEL_ITEM_CLASS),
                    $indicatorsContainer = that._createIndicatorContainer(parameters, isGroupPanelItem),
                    $span = $("<span>").addClass(that._getIndicatorClassName(options.name)),
                    getIndicatorAlignment = function() {
                        if (rtlEnabled) {
                            return "left" === columnAlignment ? "right" : "left"
                        }
                        return columnAlignment
                    };
                parameters.container = $indicatorsContainer;
                parameters.indicator = $span;
                that._renderIndicator(parameters);
                $indicatorsContainer[(isGroupPanelItem || !options.showColumnLines) && "left" === getIndicatorAlignment() ? "appendTo" : "prependTo"](options.rootElement).addClass(DATAGRID_INDICATOR_ALIGNMENT_CLASS + columnAlignment);
                return $span
            },
            _getIndicatorClassName: $.noop,
            _getColumnAlignment: function(alignment, rtlEnabled) {
                rtlEnabled = rtlEnabled || this.option("rtlEnabled");
                return "center" !== alignment ? alignment : commonUtils.getDefaultAlignment(rtlEnabled)
            },
            _createIndicatorContainer: function(options, ignoreIndicatorAlignment) {
                var $indicatorsContainer = options.rootElement.find("." + DATAGRID_COLUMN_INDICATORS_CLASS),
                    indicatorAlignment = "left" === options.columnAlignment ? "right" : "left";
                if (!$indicatorsContainer.length) {
                    $indicatorsContainer = $("<div>").addClass(DATAGRID_COLUMN_INDICATORS_CLASS)
                }
                return $indicatorsContainer.css("float", options.showColumnLines && !ignoreIndicatorAlignment ? indicatorAlignment : null)
            },
            _getIndicatorContainer: function($cell) {
                return $cell && $cell.find("." + DATAGRID_COLUMN_INDICATORS_CLASS)
            },
            _renderIndicator: function(options) {
                var $container = options.container,
                    $indicator = options.indicator;
                $container && $indicator && $container.append($indicator)
            },
            _updateIndicators: function(indicatorName) {
                var $cell, i, that = this,
                    columns = that.getColumns(),
                    $cells = that.getColumnElements();
                for (i = 0; i < columns.length; i++) {
                    $cell = $cells.eq(i);
                    that._updateIndicator($cell, columns[i], indicatorName)
                }
            },
            _updateIndicator: function($cell, column, indicatorName) {
                if (!column.command) {
                    return this._applyColumnState({
                        name: indicatorName,
                        rootElement: $cell,
                        column: column,
                        showColumnLines: this.option("showColumnLines")
                    })
                }
            }
        };
        var MAX_EQUAL_KEYS_LEVEL = 3;
        exports.equalKeys = function(key1, key2, level) {
            var propertyName, i;
            level = level || 0;
            if (level < MAX_EQUAL_KEYS_LEVEL) {
                if (commonUtils.isObject(key1) && commonUtils.isObject(key2)) {
                    for (propertyName in key1) {
                        if (key1.hasOwnProperty(propertyName) && !exports.equalKeys(key1[propertyName], key2[propertyName], level + 1)) {
                            return false
                        }
                    }
                    for (propertyName in key2) {
                        if (!(propertyName in key1)) {
                            return false
                        }
                    }
                    return true
                } else {
                    if (commonUtils.isArray(key1) && commonUtils.isArray(key2)) {
                        if (key1.length !== key2.length) {
                            return false
                        }
                        for (i = 0; i < key1.length; i++) {
                            if (!exports.equalKeys(key1[i], key2[i], level + 1)) {
                                return false
                            }
                        }
                        return true
                    } else {
                        if (commonUtils.isDate(key1) && commonUtils.isDate(key2)) {
                            return key1.getTime() === key2.getTime()
                        } else {
                            return key1 === key2
                        }
                    }
                }
            }
            return true
        };
        exports.getIndexByKey = function(key, items, keyName) {
            var item, index = -1;
            if (commonUtils.isArray(items)) {
                keyName = arguments.length <= 2 ? "key" : keyName;
                for (var i = 0; i < items.length; i++) {
                    item = commonUtils.isDefined(keyName) ? items[i][keyName] : items[i];
                    if (exports.equalKeys(key, item)) {
                        index = i;
                        break
                    }
                }
            }
            return index
        };
        exports.exportMixin = {
            _getEmptyCell: function() {
                return {
                    text: "",
                    value: void 0,
                    colspan: 1,
                    rowspan: 1
                }
            },
            _defaultSetter: function(value) {
                value = parseInt(value, 10);
                return !value ? 1 : value
            },
            _makeRowOffset: function(resultItems) {
                var offset = 0,
                    rowIndex = resultItems.length - 1,
                    row = resultItems[rowIndex],
                    cellIndex = row.length;
                $.each(resultItems, function(rowIndex) {
                    if (this[cellIndex] && this[cellIndex].rowspan + rowIndex > resultItems.length - 1) {
                        offset = Math.max.apply(this, [this[cellIndex].colspan, offset])
                    }
                });
                for (var i = 0; i < offset; i++) {
                    row.push(this._cloneItem(resultItems[resultItems.length - 2][cellIndex && cellIndex - 1 || 0]))
                }
                if (offset > 0) {
                    this._makeRowOffset(resultItems)
                }
            },
            _cloneItem: function(item) {
                return $.extend({}, item, this._getEmptyCell())
            },
            _prepareItems: function(cols, items) {
                var i, row, cellIndex, rowIndex, that = this,
                    resultItems = [];
                for (rowIndex = 0; rowIndex < items.length; rowIndex++) {
                    row = [];
                    resultItems.push(row);
                    do {
                        that._makeRowOffset(resultItems);
                        cellIndex = row.length;
                        row.push(items[rowIndex].shift());
                        if (row[row.length - 1]) {
                            row[row.length - 1].colspan = that._defaultSetter(row[row.length - 1].colspan);
                            row[row.length - 1].rowspan = that._defaultSetter(row[row.length - 1].rowspan)
                        } else {
                            row[row.length - 1] = $({}, that._getEmptyCell())
                        }
                        for (i = 1; i < row[cellIndex].colspan; i++) {
                            row.push(that._cloneItem(row[row.length - 1]))
                        }
                    } while (items[rowIndex].length);
                    while (row.length < cols) {
                        row.push(that._cloneItem(row[row.length - 1]))
                    }
                }
                return resultItems
            }
        }
    },
    /*!*****************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.columns_controller.js ***!
      \*****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            isWrapped = __webpack_require__( /*! ../../core/utils/variable_wrapper */ 38).isWrapped,
            dataCoreUtils = __webpack_require__( /*! ../../core/utils/data */ 36),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isDefined = commonUtils.isDefined,
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            normalizeSortingInfo = gridCore.normalizeSortingInfo,
            equalSortParameters = gridCore.equalSortParameters,
            normalizeIndexes = __webpack_require__( /*! ../../core/utils/array */ 111).normalizeIndexes,
            inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            numberLocalization = __webpack_require__( /*! ../../localization/number */ 22),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            DataSourceModule = __webpack_require__( /*! ../../data/data_source/data_source */ 155),
            normalizeDataSourceOptions = DataSourceModule.normalizeDataSourceOptions;
        var USER_STATE_FIELD_NAMES_15_1 = ["filterValues", "filterType", "fixed", "fixedPosition"],
            USER_STATE_FIELD_NAMES = ["visibleIndex", "dataField", "name", "dataType", "width", "visible", "sortOrder", "sortIndex", "groupIndex", "filterValue", "selectedFilterOperation", "added"].concat(USER_STATE_FIELD_NAMES_15_1),
            DATAGRID_COMMAND_EXPAND_CLASS = "dx-command-expand";
        var ColumnsController = gridCore.Controller.inherit(function() {
            var DEFAULT_COLUMN_OPTIONS = {
                    visible: true,
                    showInColumnChooser: true
                },
                DATATYPE_OPERATIONS = {
                    number: ["=", "<>", "<", ">", "<=", ">=", "between"],
                    string: ["contains", "notcontains", "startswith", "endswith", "=", "<>"],
                    date: ["=", "<>", "<", ">", "<=", ">=", "between"]
                },
                COLUMN_INDEX_OPTIONS = {
                    visibleIndex: true,
                    groupIndex: true,
                    grouped: true,
                    sortIndex: true,
                    sortOrder: true
                },
                GROUP_LOCATION = "group",
                COLUMN_CHOOSER_LOCATION = "columnChooser";
            var createColumn = function(that, columnOptions, userStateColumnOptions, bandColumn) {
                var calculatedColumnOptions, commonColumnOptions = {};
                if (columnOptions) {
                    if (commonUtils.isString(columnOptions)) {
                        columnOptions = {
                            dataField: columnOptions
                        }
                    }
                    if (columnOptions.command) {
                        return $.extend(true, {}, columnOptions)
                    } else {
                        commonColumnOptions = that.getCommonSettings();
                        if (userStateColumnOptions && userStateColumnOptions.name && userStateColumnOptions.dataField) {
                            columnOptions = $.extend({}, columnOptions, {
                                dataField: userStateColumnOptions.dataField
                            })
                        }
                        calculatedColumnOptions = that._createCalculatedColumnOptions(columnOptions, bandColumn);
                        return $.extend(true, {}, DEFAULT_COLUMN_OPTIONS, commonColumnOptions, calculatedColumnOptions, columnOptions, {
                            selector: null
                        })
                    }
                }
            };
            var createColumnsFromOptions = function(that, columnsOptions, bandColumn) {
                var result = [];
                if (columnsOptions) {
                    $.each(columnsOptions, function(index, columnOptions) {
                        var userStateColumnOptions = that._columnsUserState && checkUserStateColumn(columnOptions, that._columnsUserState[index]) && that._columnsUserState[index],
                            column = createColumn(that, columnOptions, userStateColumnOptions, bandColumn);
                        if (column) {
                            if (bandColumn) {
                                column.ownerBand = bandColumn
                            }
                            result.push(column)
                        }
                        if (column.isBand) {
                            result = result.concat(createColumnsFromOptions(that, column.columns, column));
                            delete column.columns
                        }
                    })
                }
                return result
            };
            var getParentBandColumns = function(columnIndex, columns) {
                var result = [],
                    columnID = columns[columnIndex].ownerBand;
                if (isDefined(columnID)) {
                    $.each(columns, function(index, column) {
                        if (column.index === columnID) {
                            result.unshift(column);
                            if (isDefined(column.ownerBand)) {
                                result = getParentBandColumns(index, columns).concat(result)
                            } else {
                                return false
                            }
                        }
                    })
                }
                return result
            };
            var calculateColspan = function(that, columnID, columns) {
                var colspan = 0;
                columns = columns || that.getChildrenByBandColumn(columnID);
                $.each(columns, function(_, column) {
                    if (column.visible && column.ownerBand === columnID) {
                        if (column.isBand) {
                            colspan += calculateColspan(that, column.index, columns)
                        } else {
                            colspan += 1
                        }
                    }
                });
                return colspan
            };
            var processBandColumns = function(that, columns) {
                var i, column, rowspan, colspan, rowCount = that.getRowCount();
                for (i = 0; i < columns.length; i++) {
                    column = columns[i];
                    if (column.visible || column.command) {
                        if (column.isBand) {
                            colspan = calculateColspan(that, column.index);
                            column.colspan = colspan
                        }
                        if (!column.isBand || !column.colspan) {
                            rowspan = rowCount - (!column.command && !isDefined(column.groupIndex) ? getParentBandColumns(i, columns).length : 0);
                            if (rowspan > 1) {
                                column.rowspan = rowspan
                            }
                        }
                    }
                }
            };
            var getValueDataType = function(value) {
                var dataType = $.type(value);
                if ("string" !== dataType && "boolean" !== dataType && "number" !== dataType && "date" !== dataType && "object" !== dataType) {
                    dataType = void 0
                }
                return dataType
            };
            var getSerializationFormat = function(dataType, value) {
                switch (dataType) {
                    case "date":
                        return dateUtils.getDateSerializationFormat(value);
                    case "number":
                        if (commonUtils.isString(value)) {
                            return "string"
                        }
                }
            };
            var updateSerializers = function(options, dataType) {
                if (!options.deserializeValue) {
                    if ("date" === dataType) {
                        options.deserializeValue = function(value) {
                            return dateUtils.deserializeDate(value, this.serializationFormat, $.proxy(dateLocalization.parse, dateLocalization))
                        };
                        options.serializeValue = function(value) {
                            return dateUtils.serializeDate(value, this.serializationFormat, $.proxy(dateLocalization.format, dateLocalization))
                        }
                    }
                    if ("number" === dataType) {
                        options.deserializeValue = function(value) {
                            return isDefined(value) ? Number(value) : value
                        };
                        options.serializeValue = function(value) {
                            return isDefined(value) && "string" === this.serializationFormat ? value.toString() : value
                        }
                    }
                }
            };
            var getAlignmentByDataType = function(dataType, isRTL) {
                switch (dataType) {
                    case "number":
                        return "right";
                    case "boolean":
                        return "center";
                    default:
                        return commonUtils.getDefaultAlignment(isRTL)
                }
            };
            var getCustomizeTextByDataType = function(dataType) {
                if ("boolean" === dataType) {
                    return function(e) {
                        if (true === e.value) {
                            return this.trueText || "true"
                        } else {
                            if (false === e.value) {
                                return this.falseText || "false"
                            } else {
                                return e.valueText || ""
                            }
                        }
                    }
                }
            };
            var createColumnsFromDataSource = function(that, dataSource) {
                var fieldName, i, firstItems = getFirstItems(dataSource),
                    processedFields = {},
                    result = [];
                for (i = 0; i < firstItems.length; i++) {
                    if (firstItems[i]) {
                        for (fieldName in firstItems[i]) {
                            processedFields[fieldName] = true
                        }
                    }
                }
                for (fieldName in processedFields) {
                    if (0 !== fieldName.indexOf("__")) {
                        var column = createColumn(that, fieldName);
                        result.push(column)
                    }
                }
                return result
            };
            var getFirstItems = function(dataSource) {
                var groupsCount, items = [];
                var getFirstItemsCore = function(items, groupsCount) {
                    var i, childItems;
                    if (!items || !groupsCount) {
                        return items
                    }
                    for (i = 0; i < items.length; i++) {
                        childItems = getFirstItemsCore(items[i].items || items[i].collapsedItems, groupsCount - 1);
                        if (childItems && childItems.length) {
                            return childItems
                        }
                    }
                };
                if (dataSource && dataSource.items().length > 0) {
                    groupsCount = normalizeSortingInfo(dataSource.group()).length;
                    items = getFirstItemsCore(dataSource.items(), groupsCount) || []
                }
                return items
            };
            var updateColumnIndexes = function(that) {
                $.each(that._columns, function(index, column) {
                    column.index = index
                });
                $.each(that._columns, function(index, column) {
                    if (commonUtils.isObject(column.ownerBand)) {
                        column.ownerBand = column.ownerBand.index
                    }
                });
                $.each(that._commandColumns, function(index, column) {
                    column.index = -(index + 1)
                })
            };
            var updateColumnGroupIndexes = function(that, currentColumn) {
                normalizeIndexes(that._columns, "groupIndex", currentColumn, function(column) {
                    var grouped = column.grouped;
                    delete column.grouped;
                    return grouped
                })
            };
            var updateColumnSortIndexes = function(that, currentColumn) {
                $.each(that._columns, function(index, column) {
                    if (isDefined(column.sortIndex) && !isSortOrderValid(column.sortOrder)) {
                        delete column.sortIndex
                    }
                });
                normalizeIndexes(that._columns, "sortIndex", currentColumn, function(column) {
                    return !isDefined(column.groupIndex) && isSortOrderValid(column.sortOrder)
                })
            };
            var updateColumnVisibleIndexes = function(that, currentColumn) {
                var i, key, column, bandColumnIndex, parentBandColumns, bandColumns = {},
                    columns = [];
                for (i = 0; i < that._columns.length; i++) {
                    column = that._columns[i];
                    parentBandColumns = getParentBandColumns(i, that._columns);
                    if (parentBandColumns.length) {
                        bandColumnIndex = parentBandColumns[parentBandColumns.length - 1].index;
                        bandColumns[bandColumnIndex] = bandColumns[bandColumnIndex] || [];
                        bandColumns[bandColumnIndex].push(column)
                    } else {
                        columns.push(column)
                    }
                }
                for (key in bandColumns) {
                    normalizeIndexes(bandColumns[key], "visibleIndex", currentColumn)
                }
                normalizeIndexes(columns, "visibleIndex", currentColumn)
            };
            var getColumnIndexByVisibleIndex = function(that, visibleIndex, location) {
                var column, rowIndex = commonUtils.isObject(visibleIndex) ? visibleIndex.rowIndex : null,
                    columns = location === GROUP_LOCATION ? that.getGroupColumns() : location === COLUMN_CHOOSER_LOCATION ? that.getChooserColumns() : that.getVisibleColumns(rowIndex);
                visibleIndex = commonUtils.isObject(visibleIndex) ? visibleIndex.columnIndex : visibleIndex;
                column = columns[visibleIndex];
                return column && isDefined(column.index) ? column.index : -1
            };
            var moveColumnToGroup = function(that, column, groupIndex) {
                var i, groupColumns = that.getGroupColumns();
                if (groupIndex >= 0) {
                    for (i = 0; i < groupColumns.length; i++) {
                        if (groupColumns[i].groupIndex >= groupIndex) {
                            groupColumns[i].groupIndex++
                        }
                    }
                } else {
                    groupIndex = 0;
                    for (i = 0; i < groupColumns.length; i++) {
                        groupIndex = Math.max(groupIndex, groupColumns[i].groupIndex + 1)
                    }
                }
                column.groupIndex = groupIndex
            };
            var checkUserStateColumn = function(column, userStateColumn) {
                return column && userStateColumn && userStateColumn.name === column.name && (userStateColumn.dataField === column.dataField || column.name)
            };
            var applyUserState = function(that) {
                var column, columnUserState, userStateColumnIndex, i, columnsUserState = that._columnsUserState,
                    ignoreColumnOptionNames = that._ignoreColumnOptionNames || [],
                    columns = that._columns,
                    columnCountById = {},
                    resultColumns = [],
                    allColumnsHaveState = true,
                    userStateColumnIndexes = [];

                function applyFieldsState(column, userStateColumn) {
                    var fieldName;
                    if (!userStateColumn) {
                        return
                    }
                    for (var index = 0; index < USER_STATE_FIELD_NAMES.length; index++) {
                        fieldName = USER_STATE_FIELD_NAMES[index];
                        if ($.inArray(fieldName, ignoreColumnOptionNames) >= 0) {
                            continue
                        }
                        if ("dataType" === fieldName) {
                            column[fieldName] = column[fieldName] || userStateColumn[fieldName]
                        } else {
                            if ($.inArray(fieldName, USER_STATE_FIELD_NAMES_15_1) >= 0) {
                                if (fieldName in userStateColumn) {
                                    column[fieldName] = userStateColumn[fieldName]
                                }
                            } else {
                                column[fieldName] = userStateColumn[fieldName]
                            }
                        }
                    }
                }

                function findUserStateColumn(columnsUserState, column) {
                    var id = column.name || column.dataField,
                        count = columnCountById[id] || 0;
                    for (var j = 0; j < columnsUserState.length; j++) {
                        if (checkUserStateColumn(column, columnsUserState[j])) {
                            if (count) {
                                count--
                            } else {
                                columnCountById[id] = columnCountById[id] || 0;
                                columnCountById[id]++;
                                return j
                            }
                        }
                    }
                    return -1
                }
                if (columnsUserState) {
                    for (i = 0; i < columns.length; i++) {
                        userStateColumnIndex = findUserStateColumn(columnsUserState, columns[i]);
                        allColumnsHaveState = allColumnsHaveState && userStateColumnIndex >= 0;
                        userStateColumnIndexes.push(userStateColumnIndex)
                    }
                    for (i = 0; i < columns.length; i++) {
                        column = columns[i];
                        userStateColumnIndex = userStateColumnIndexes[i];
                        if (that._hasUserState || allColumnsHaveState) {
                            applyFieldsState(column, columnsUserState[userStateColumnIndex])
                        }
                        if (userStateColumnIndex >= 0 && isDefined(columnsUserState[userStateColumnIndex].initialIndex)) {
                            resultColumns[userStateColumnIndex] = column
                        } else {
                            resultColumns.push(column)
                        }
                    }
                    for (i = 0; i < columnsUserState.length; i++) {
                        columnUserState = columnsUserState[i];
                        if (columnUserState.added && findUserStateColumn(columns, columnUserState) < 0) {
                            column = createColumn(that, columnUserState.added);
                            applyFieldsState(column, columnUserState);
                            resultColumns.push(column)
                        }
                    }
                    assignColumns(that, resultColumns)
                }
            };
            var updateIndexes = function(that, column) {
                updateColumnIndexes(that);
                updateColumnGroupIndexes(that, column);
                updateColumnSortIndexes(that, column);
                updateColumnVisibleIndexes(that, column)
            };
            var assignColumns = function(that, columns) {
                that._columns = columns;
                that._visibleColumns = void 0;
                that._fixedColumns = void 0;
                that._rowCount = void 0;
                that.updateColumnDataTypes()
            };
            var updateColumnChanges = function(that, changeType, optionName, columnIndex) {
                var columnChanges = that._columnChanges || {
                    optionNames: {
                        length: 0
                    },
                    changeTypes: {
                        length: 0
                    },
                    columnIndex: columnIndex
                };
                optionName = optionName || "all";
                var changeTypes = columnChanges.changeTypes;
                if (changeType && !changeTypes[changeType]) {
                    changeTypes[changeType] = true;
                    changeTypes.length++
                }
                var optionNames = columnChanges.optionNames;
                if (optionName && !optionNames[optionName]) {
                    optionNames[optionName] = true;
                    optionNames.length++
                }
                if (void 0 === columnIndex || columnIndex !== columnChanges.columnIndex) {
                    delete columnChanges.columnIndex
                }
                that._columnChanges = columnChanges;
                that._visibleColumns = void 0;
                that._fixedColumns = void 0;
                that._rowCount = void 0
            };
            var fireColumnsChanged = function(that) {
                var onColumnsChanging = that.option("onColumnsChanging"),
                    columnChanges = that._columnChanges;
                if (that.isInitialized() && !that._updateLockCount && columnChanges) {
                    if (onColumnsChanging) {
                        that._updateLockCount++;
                        onColumnsChanging($.extend({
                            component: that.component
                        }, columnChanges));
                        that._updateLockCount--
                    }
                    that._columnChanges = void 0;
                    if (columnChanges.optionNames && (columnChanges.optionNames.dataField || columnChanges.optionNames.lookup)) {
                        that.reinit()
                    } else {
                        that.columnsChanged.fire(columnChanges)
                    }
                }
            };
            var columnOptionCore = function(that, column, optionName, value, notFireEvent) {
                var prevValue, optionSetter, columns, changeType, optionGetter = dataCoreUtils.compileGetter(optionName),
                    columnIndex = column.index;
                if (3 === arguments.length) {
                    return optionGetter(column, {
                        functionsAsIs: true
                    })
                }
                prevValue = optionGetter(column, {
                    functionsAsIs: true
                });
                if (prevValue !== value) {
                    if ("groupIndex" === optionName) {
                        changeType = "grouping"
                    } else {
                        if ("sortIndex" === optionName || "sortOrder" === optionName) {
                            changeType = "sorting"
                        } else {
                            changeType = "columns"
                        }
                    }
                    optionSetter = dataCoreUtils.compileSetter(optionName);
                    optionSetter(column, value, {
                        functionsAsIs: true
                    });
                    if (!isDefined(prevValue) && !isDefined(value)) {
                        notFireEvent = true
                    }
                    if (!notFireEvent) {
                        if ($.inArray(optionName, USER_STATE_FIELD_NAMES) < 0 && "visibleWidth" !== optionName) {
                            columns = that.option("columns");
                            column = columns && columns[columnIndex];
                            if (commonUtils.isString(column)) {
                                column = columns[columnIndex] = {
                                    dataField: column
                                }
                            }
                            if (column) {
                                optionSetter(column, value, {
                                    functionsAsIs: true
                                })
                            }
                        }
                        updateColumnChanges(that, changeType, optionName, columnIndex)
                    }
                }
            };
            var isSortOrderValid = function(sortOrder) {
                return "asc" === sortOrder || "desc" === sortOrder
            };
            var addExpandColumn = function(that) {
                that.addCommandColumn({
                    command: "expand",
                    width: "auto",
                    cssClass: DATAGRID_COMMAND_EXPAND_CLASS,
                    allowEditing: false,
                    allowGrouping: false,
                    allowSorting: false,
                    allowResizing: false,
                    allowReordering: false,
                    allowHiding: false
                })
            };
            var defaultSetCellValue = function(data, value) {
                var name, i, path = this.dataField.split("."),
                    dotCount = path.length - 1;
                if (this.serializeValue) {
                    value = this.serializeValue(value)
                }
                for (i = 0; i < dotCount; i++) {
                    name = path[i];
                    data = data[name] = data[name] || {}
                }
                data[path[dotCount]] = value
            };
            var getDataColumns = function(columns, rowIndex, bandColumnID) {
                var result = [];
                rowIndex = rowIndex || 0;
                columns[rowIndex] && $.each(columns[rowIndex], function(_, column) {
                    if (column.ownerBand === bandColumnID || isDefined(column.groupIndex)) {
                        if (!column.isBand || !column.colspan) {
                            if (!column.command || rowIndex < 1) {
                                result.push(column)
                            }
                        } else {
                            result.push.apply(result, getDataColumns(columns, rowIndex + 1, column.index))
                        }
                    }
                });
                return result
            };
            var isChildrenColumnVisibleInHeaders = function(that, columnID) {
                var result;
                $.each(that.getChildrenByBandColumn(columnID), function(_, column) {
                    if (column.visible) {
                        if (column.isBand) {
                            result = isChildrenColumnVisibleInHeaders(that, column.index)
                        } else {
                            if (column.ownerBand === columnID) {
                                result = true
                            }
                        }
                    }
                    return !result
                });
                return result
            };
            var getRowCount = function(that, level, bandColumnIndex) {
                var rowCount, visibleInHeaders;
                level = level || 1;
                rowCount = level;
                $.each(that._columns, function(_, column) {
                    if (column.isBand && column.visible && column.ownerBand === bandColumnIndex) {
                        visibleInHeaders = isChildrenColumnVisibleInHeaders(that, column.index);
                        if (visibleInHeaders) {
                            rowCount = Math.max(rowCount, getRowCount(that, level + 1, column.index))
                        }
                    }
                });
                return rowCount
            };
            var getFixedPosition = function(column) {
                return !column.fixedPosition ? "left" : column.fixedPosition
            };
            var processExpandColumns = function(columns, expandColumns, columnIndex) {
                var rowspan = columns[columnIndex] && columns[columnIndex].rowspan,
                    expandColumnsByRow = expandColumns.slice(0);
                if (rowspan > 1) {
                    expandColumnsByRow = $.map(expandColumnsByRow, function(expandColumn) {
                        return $.extend({}, expandColumn, {
                            rowspan: rowspan
                        })
                    })
                }
                expandColumnsByRow.unshift(columnIndex, 0);
                columns.splice.apply(columns, expandColumnsByRow);
                return rowspan || 1
            };
            var digitsCount = function(number) {
                var i;
                for (i = 0; number > 1; i++) {
                    number /= 10
                }
                return i
            };
            var numberToString = function(number, digitsCount) {
                var str = number ? number.toString() : "0";
                while (str.length < digitsCount) {
                    str = "0" + str
                }
                return str
            };
            return {
                _endUpdateCore: function() {
                    fireColumnsChanged(this)
                },
                init: function() {
                    var that = this,
                        columns = that.option("columns");
                    that._commandColumns = that._commandColumns || [];
                    that._columns = that._columns || [];
                    addExpandColumn(that);
                    that._isColumnsFromOptions = !!columns;
                    if (that._isColumnsFromOptions) {
                        assignColumns(that, columns ? createColumnsFromOptions(that, columns) : []);
                        applyUserState(that)
                    } else {
                        assignColumns(that, that._columnsUserState ? createColumnsFromOptions(that, that._columnsUserState) : that._columns)
                    }
                    if (that._dataSourceApplied) {
                        that.applyDataSource(that._dataSource, true)
                    } else {
                        updateIndexes(that)
                    }
                },
                callbackNames: function() {
                    return ["columnsChanged"]
                },
                optionChanged: function(args) {
                    switch (args.name) {
                        case "adaptColumnWidthByRatio":
                            args.handled = true;
                            break;
                        case "columns":
                            args.handled = true;
                            this._columnsUserState = null;
                            this._ignoreColumnOptionNames = null;
                            this.init();
                            break;
                        case "commonColumnSettings":
                        case "columnAutoWidth":
                        case "allowColumnResizing":
                        case "allowColumnReordering":
                        case "columnFixing":
                        case "grouping":
                        case "groupPanel":
                        case "regenerateColumnsByVisibleItems":
                        case "customizeColumns":
                        case "editing":
                        case "columnHidingEnabled":
                            args.handled = true;
                            this.reinit();
                            break;
                        case "rtlEnabled":
                            this.reinit();
                            break;
                        default:
                            this.callBase(args)
                    }
                },
                publicMethods: function() {
                    return ["addColumn", "deleteColumn", "columnOption", "columnCount", "clearSorting", "clearGrouping"]
                },
                applyDataSource: function(dataSource, forceApplying) {
                    var that = this,
                        isDataSourceLoaded = dataSource && dataSource.isLoaded();
                    that._dataSource = dataSource;
                    if (!that._dataSourceApplied || 0 === that._dataSourceColumnsCount || forceApplying || that.option("regenerateColumnsByVisibleItems")) {
                        if (isDataSourceLoaded) {
                            if (!that._isColumnsFromOptions) {
                                assignColumns(that, createColumnsFromDataSource(that, dataSource));
                                that._dataSourceColumnsCount = that._columns.length;
                                applyUserState(that)
                            }
                            return that.updateColumns(dataSource, forceApplying)
                        } else {
                            that._dataSourceApplied = false
                        }
                    }
                },
                reset: function() {
                    this._dataSourceApplied = false;
                    this._dataSourceColumnsCount = void 0;
                    this.reinit()
                },
                reinit: function() {
                    this._columnsUserState = this.getUserState();
                    this._ignoreColumnOptionNames = null;
                    this.init()
                },
                isInitialized: function() {
                    return !!this._columns.length || !!this.option("columns")
                },
                isDataSourceApplied: function() {
                    return this._dataSourceApplied
                },
                getCommonSettings: function() {
                    var commonColumnSettings = this.option("commonColumnSettings") || {},
                        groupingOptions = this.option("grouping") || {},
                        groupPanelOptions = this.option("groupPanel") || {};
                    return $.extend({
                        allowFixing: this.option("columnFixing.enabled"),
                        allowResizing: this.option("allowColumnResizing"),
                        allowReordering: this.option("allowColumnReordering"),
                        autoExpandGroup: groupingOptions.autoExpandAll,
                        allowCollapsing: groupingOptions.allowCollapsing,
                        allowGrouping: groupPanelOptions.allowColumnDragging && groupPanelOptions.visible || groupingOptions.contextMenuEnabled
                    }, commonColumnSettings)
                },
                isColumnOptionUsed: function(optionName) {
                    for (var i = 0; i < this._columns.length; i++) {
                        if (this._columns[i][optionName]) {
                            return true
                        }
                    }
                },
                isAllDataTypesDefined: function() {
                    var i, columns = this._columns;
                    if (!columns.length) {
                        return false
                    }
                    for (i = 0; i < columns.length; i++) {
                        if (!columns[i].dataType) {
                            return false
                        }
                    }
                    return true
                },
                getColumns: function() {
                    return this._columns
                },
                getGroupColumns: function() {
                    var result = [];
                    $.each(this._columns, function() {
                        var column = this;
                        if (isDefined(column.groupIndex)) {
                            result[column.groupIndex] = column
                        }
                    });
                    return result
                },
                getVisibleColumns: function(rowIndex) {
                    this._visibleColumns = this._visibleColumns || this._getVisibleColumnsCore();
                    rowIndex = isDefined(rowIndex) ? rowIndex : this._visibleColumns.length - 1;
                    return this._visibleColumns[rowIndex] || []
                },
                getFixedColumns: function(rowIndex) {
                    this._fixedColumns = this._fixedColumns || this._getFixedColumnsCore();
                    rowIndex = isDefined(rowIndex) ? rowIndex : this._fixedColumns.length - 1;
                    return this._fixedColumns[rowIndex] || []
                },
                _getFixedColumnsCore: function() {
                    var i, j, column, prevColumn, notFixedColumnCount, transparentColumnIndex, lastFixedPosition, visibleColumns, that = this,
                        result = [],
                        rowCount = that.getRowCount(),
                        isColumnFixing = that._isColumnFixing(),
                        transparentColumn = {
                            command: "transparent"
                        },
                        transparentColspan = 0;
                    if (isColumnFixing) {
                        for (i = 0; i <= rowCount; i++) {
                            notFixedColumnCount = 0;
                            lastFixedPosition = null;
                            transparentColumnIndex = null;
                            visibleColumns = that.getVisibleColumns(i);
                            for (j = 0; j < visibleColumns.length; j++) {
                                prevColumn = visibleColumns[j - 1];
                                column = visibleColumns[j];
                                if (!column.command) {
                                    if (!column.fixed) {
                                        if (0 === i) {
                                            if (column.isBand && column.colspan) {
                                                transparentColspan += column.colspan
                                            } else {
                                                transparentColspan++
                                            }
                                        }
                                        notFixedColumnCount++;
                                        if (!isDefined(transparentColumnIndex)) {
                                            transparentColumnIndex = j
                                        }
                                    } else {
                                        if (prevColumn && prevColumn.fixed && getFixedPosition(prevColumn) !== getFixedPosition(column)) {
                                            if (!isDefined(transparentColumnIndex)) {
                                                transparentColumnIndex = j
                                            }
                                        } else {
                                            lastFixedPosition = column.fixedPosition
                                        }
                                    }
                                }
                            }
                            if (0 === i && (0 === notFixedColumnCount || notFixedColumnCount >= visibleColumns.length)) {
                                return []
                            }
                            if (!isDefined(transparentColumnIndex)) {
                                transparentColumnIndex = "right" === lastFixedPosition ? 0 : visibleColumns.length
                            }
                            result[i] = visibleColumns.slice(0);
                            if (!transparentColumn.colspan) {
                                transparentColumn.colspan = transparentColspan
                            }
                            result[i].splice(transparentColumnIndex, notFixedColumnCount, transparentColumn)
                        }
                    }
                    return result
                },
                _isColumnFixing: function() {
                    var isColumnFixing = this.option("columnFixing.enabled");
                    !isColumnFixing && $.each(this._columns, function(_, column) {
                        if (column.fixed) {
                            isColumnFixing = true;
                            return false
                        }
                    });
                    return isColumnFixing
                },
                _getExpandColumnsCore: function() {
                    return this.getGroupColumns()
                },
                getExpandColumns: function() {
                    var expandColumn, expandColumns = this._getExpandColumnsCore();
                    if (expandColumns.length) {
                        expandColumn = this.columnOption("command:expand")
                    }
                    expandColumns = $.map(expandColumns, function(column) {
                        return $.extend({}, column, {
                            visibleWidth: "auto"
                        }, expandColumn, {
                            index: column.index
                        })
                    });
                    return expandColumns
                },
                _getVisibleColumnsCore: function() {
                    var i, firstPositiveIndexColumn, isFixedToEnd, that = this,
                        result = [],
                        rowspanExpandColumns = 0,
                        expandColumns = that.getExpandColumns(),
                        rowCount = that.getRowCount(),
                        positiveIndexedColumns = [],
                        negativeIndexedColumns = [],
                        notGroupedColumnsCount = 0,
                        rtlEnabled = that.option("rtlEnabled"),
                        columns = $.extend(true, [], that._columns.length ? that._commandColumns.concat(that._columns) : []),
                        columnDigitsCount = digitsCount(columns.length);
                    processBandColumns(that, columns);
                    for (i = 0; i < rowCount; i++) {
                        result[i] = [];
                        negativeIndexedColumns[i] = [{}];
                        positiveIndexedColumns[i] = [{}, {}, {}]
                    }
                    $.each(columns, function(index) {
                        var rowIndex, indexedColumns, column = this,
                            visibleIndex = column.visibleIndex,
                            parentBandColumns = getParentBandColumns(index, columns),
                            visible = column.visible && that.isParentColumnVisible(column.index);
                        if (visible && (!isDefined(column.groupIndex) || column.showWhenGrouped)) {
                            rowIndex = parentBandColumns.length;
                            if (visibleIndex < 0) {
                                visibleIndex = -visibleIndex;
                                indexedColumns = negativeIndexedColumns[rowIndex]
                            } else {
                                column.fixed = parentBandColumns.length ? parentBandColumns[0].fixed : column.fixed;
                                column.fixedPosition = parentBandColumns.length ? parentBandColumns[0].fixedPosition : column.fixedPosition;
                                if (column.fixed || column.command) {
                                    isFixedToEnd = "right" === column.fixedPosition;
                                    if (rtlEnabled) {
                                        isFixedToEnd = !isFixedToEnd
                                    }
                                    if (isFixedToEnd || column.command) {
                                        indexedColumns = positiveIndexedColumns[rowIndex][2]
                                    } else {
                                        indexedColumns = positiveIndexedColumns[rowIndex][0]
                                    }
                                } else {
                                    indexedColumns = positiveIndexedColumns[rowIndex][1]
                                }
                            }
                            if (parentBandColumns.length) {
                                visibleIndex = numberToString(visibleIndex, columnDigitsCount);
                                for (i = parentBandColumns.length - 1; i >= 0; i--) {
                                    visibleIndex = numberToString(parentBandColumns[i].visibleIndex, columnDigitsCount) + visibleIndex
                                }
                            }
                            indexedColumns[visibleIndex] = indexedColumns[visibleIndex] || [];
                            indexedColumns[visibleIndex].push(column);
                            notGroupedColumnsCount++
                        }
                    });
                    $.each(result, function(rowIndex) {
                        objectUtils.orderEach(negativeIndexedColumns[rowIndex], function(_, columns) {
                            result[rowIndex].unshift.apply(result[rowIndex], columns)
                        });
                        firstPositiveIndexColumn = result[rowIndex].length;
                        $.each(positiveIndexedColumns[rowIndex], function(index, columnsByFixing) {
                            objectUtils.orderEach(columnsByFixing, function(_, columnsByVisibleIndex) {
                                result[rowIndex].push.apply(result[rowIndex], columnsByVisibleIndex)
                            })
                        });
                        if (rowspanExpandColumns < rowIndex + 1) {
                            rowspanExpandColumns += processExpandColumns(result[rowIndex], expandColumns, firstPositiveIndexColumn)
                        }
                    });
                    result.push(getDataColumns(result));
                    if (!notGroupedColumnsCount && that._columns.length) {
                        result[rowCount].push({
                            command: "empty"
                        })
                    }
                    return result
                },
                getInvisibleColumns: function(columns, bandColumnIndex) {
                    var hiddenColumnsByBand, that = this,
                        result = [];
                    columns = columns || that._columns;
                    $.each(columns, function(_, column) {
                        if (column.ownerBand !== bandColumnIndex) {
                            return
                        }
                        if (column.isBand) {
                            if (!column.visible) {
                                hiddenColumnsByBand = that.getChildrenByBandColumn(column.index)
                            } else {
                                hiddenColumnsByBand = that.getInvisibleColumns(that.getChildrenByBandColumn(column.index), column.index)
                            }
                            if (hiddenColumnsByBand.length) {
                                result.push(column);
                                result = result.concat(hiddenColumnsByBand)
                            }
                            return
                        }
                        if (!column.visible) {
                            result.push(column)
                        }
                    });
                    return result
                },
                getChooserColumns: function(getAllColumns) {
                    var columns = getAllColumns ? this.getColumns() : this.getInvisibleColumns();
                    return $.grep(columns, function(column) {
                        return column.showInColumnChooser
                    })
                },
                allowMoveColumn: function(fromVisibleIndex, toVisibleIndex, sourceLocation, targetLocation) {
                    var that = this,
                        columnIndex = getColumnIndexByVisibleIndex(that, fromVisibleIndex, sourceLocation),
                        sourceColumn = that._columns[columnIndex];
                    if (sourceColumn && (sourceColumn.allowReordering || sourceColumn.allowGrouping || sourceColumn.allowHiding)) {
                        if (sourceLocation === targetLocation) {
                            if (sourceLocation === COLUMN_CHOOSER_LOCATION) {
                                return false
                            }
                            fromVisibleIndex = commonUtils.isObject(fromVisibleIndex) ? fromVisibleIndex.columnIndex : fromVisibleIndex;
                            toVisibleIndex = commonUtils.isObject(toVisibleIndex) ? toVisibleIndex.columnIndex : toVisibleIndex;
                            return fromVisibleIndex !== toVisibleIndex && fromVisibleIndex + 1 !== toVisibleIndex
                        } else {
                            if (sourceLocation === GROUP_LOCATION && targetLocation !== COLUMN_CHOOSER_LOCATION || targetLocation === GROUP_LOCATION) {
                                return sourceColumn && sourceColumn.allowGrouping
                            } else {
                                if (sourceLocation === COLUMN_CHOOSER_LOCATION || targetLocation === COLUMN_CHOOSER_LOCATION) {
                                    return sourceColumn && sourceColumn.allowHiding
                                }
                            }
                        }
                        return true
                    }
                    return false
                },
                moveColumn: function(fromVisibleIndex, toVisibleIndex, sourceLocation, targetLocation) {
                    var targetGroupIndex, column, that = this,
                        fromIndex = getColumnIndexByVisibleIndex(that, fromVisibleIndex, sourceLocation),
                        toIndex = getColumnIndexByVisibleIndex(that, toVisibleIndex, targetLocation),
                        isGroupMoving = sourceLocation === GROUP_LOCATION || targetLocation === GROUP_LOCATION;
                    if (fromIndex >= 0) {
                        column = that._columns[fromIndex];
                        toVisibleIndex = commonUtils.isObject(toVisibleIndex) ? toVisibleIndex.columnIndex : toVisibleIndex;
                        targetGroupIndex = toIndex >= 0 ? that._columns[toIndex].groupIndex : -1;
                        if (isDefined(column.groupIndex) && sourceLocation === GROUP_LOCATION) {
                            if (targetGroupIndex > column.groupIndex) {
                                targetGroupIndex--
                            }
                            delete column.groupIndex;
                            delete column.sortOrder;
                            updateColumnGroupIndexes(that)
                        }
                        if (targetLocation === GROUP_LOCATION) {
                            moveColumnToGroup(that, column, targetGroupIndex);
                            updateColumnGroupIndexes(that)
                        } else {
                            if (toVisibleIndex >= 0) {
                                var targetColumn = that._columns[toIndex];
                                if (!targetColumn || column.ownerBand !== targetColumn.ownerBand) {
                                    column.visibleIndex = void 0
                                } else {
                                    if (column.fixed ^ targetColumn.fixed) {
                                        column.visibleIndex = void 0
                                    } else {
                                        column.visibleIndex = targetColumn.visibleIndex
                                    }
                                }
                                updateColumnVisibleIndexes(that, column)
                            }
                        }
                        column.visible = targetLocation !== COLUMN_CHOOSER_LOCATION;
                        updateColumnChanges(that, isGroupMoving ? "grouping" : "columns");
                        fireColumnsChanged(that)
                    }
                },
                changeSortOrder: function(columnIndex, sortOrder) {
                    var that = this,
                        sortingOptions = that.option("sorting"),
                        sortingMode = sortingOptions && sortingOptions.mode,
                        needResetSorting = "single" === sortingMode || !sortOrder,
                        allowSorting = "single" === sortingMode || "multiple" === sortingMode,
                        column = that._columns[columnIndex],
                        nextSortOrder = function(column) {
                            if ("ctrl" === sortOrder) {
                                if (!("sortOrder" in column && "sortIndex" in column)) {
                                    return false
                                }
                                delete column.sortOrder;
                                delete column.sortIndex
                            } else {
                                if (isDefined(column.groupIndex) || isDefined(column.sortIndex)) {
                                    column.sortOrder = "desc" === column.sortOrder ? "asc" : "desc"
                                } else {
                                    column.sortOrder = "asc"
                                }
                            }
                            return true
                        },
                        isSortingChanged = false;
                    if (allowSorting && column && column.allowSorting) {
                        if (needResetSorting && !isDefined(column.groupIndex)) {
                            $.each(that._columns, function(index) {
                                if (index !== columnIndex && this.sortOrder && !isDefined(this.groupIndex)) {
                                    delete this.sortOrder;
                                    delete this.sortIndex;
                                    isSortingChanged = true
                                }
                            })
                        }
                        if (isSortOrderValid(sortOrder)) {
                            if (column.sortOrder !== sortOrder) {
                                column.sortOrder = sortOrder;
                                isSortingChanged = true
                            }
                        } else {
                            if ("none" === sortOrder) {
                                if (column.sortOrder) {
                                    delete column.sortIndex;
                                    delete column.sortOrder;
                                    isSortingChanged = true
                                }
                            } else {
                                isSortingChanged = nextSortOrder(column)
                            }
                        }
                    }
                    if (isSortingChanged) {
                        updateColumnSortIndexes(that);
                        updateColumnChanges(that, "sorting");
                        fireColumnsChanged(that)
                    }
                },
                getSortDataSourceParameters: function(useLocalSelector) {
                    var that = this,
                        sortColumns = [],
                        sort = [];
                    $.each(that._columns, function() {
                        if ((this.dataField || this.selector || this.calculateCellValue) && isDefined(this.sortIndex) && !isDefined(this.groupIndex)) {
                            sortColumns[this.sortIndex] = this
                        }
                    });
                    $.each(sortColumns, function() {
                        var sortOrder = this && this.sortOrder;
                        if (isSortOrderValid(sortOrder)) {
                            sort.push({
                                selector: this.calculateSortValue || this.displayField || this.calculateDisplayValue || useLocalSelector && this.selector || this.dataField || this.calculateCellValue,
                                desc: "desc" === this.sortOrder
                            })
                        }
                    });
                    return sort.length > 0 ? sort : null
                },
                getGroupDataSourceParameters: function(useLocalSelector) {
                    var group = [];
                    $.each(this.getGroupColumns(), function() {
                        var selector = this.calculateGroupValue || this.displayField || this.calculateDisplayValue || useLocalSelector && this.selector || this.dataField || this.calculateCellValue;
                        if (selector) {
                            group.push({
                                selector: selector,
                                desc: "desc" === this.sortOrder,
                                isExpanded: !!this.autoExpandGroup
                            })
                        }
                    });
                    return group.length > 0 ? group : null
                },
                refresh: function(updateNewLookupsOnly) {
                    var deferreds = [];
                    $.each(this._columns, function() {
                        var lookup = this.lookup;
                        if (lookup && !this.calculateDisplayValue) {
                            if (updateNewLookupsOnly && lookup.valueMap) {
                                return
                            }
                            if (lookup.update) {
                                deferreds.push(lookup.update())
                            }
                        }
                    });
                    return $.when.apply($, deferreds)
                },
                updateColumnDataTypes: function(dataSource) {
                    var firstItems = getFirstItems(dataSource),
                        rtlEnabled = this.option("rtlEnabled");
                    $.each(this._columns, function(index, column) {
                        var i, value, dataType, lookupDataType, valueDataType, lookup = column.lookup;
                        if (column.calculateCellValue && firstItems.length) {
                            if (!column.dataType || lookup && !lookup.dataType) {
                                for (i = 0; i < firstItems.length; i++) {
                                    value = column.calculateCellValue(firstItems[i]);
                                    valueDataType = column.dataType || getValueDataType(value);
                                    dataType = dataType || valueDataType;
                                    if (dataType && valueDataType && dataType !== valueDataType) {
                                        dataType = "string"
                                    }
                                    if (lookup) {
                                        valueDataType = lookup.dataType || getValueDataType(gridCore.getDisplayValue(column, value, firstItems[i]));
                                        lookupDataType = lookupDataType || valueDataType;
                                        if (lookupDataType && valueDataType && lookupDataType !== valueDataType) {
                                            lookupDataType = "string"
                                        }
                                    }
                                }
                                column.dataType = dataType;
                                if (lookup) {
                                    lookup.dataType = lookupDataType
                                }
                            }
                            if (!column.serializationFormat || lookup && !lookup.serializationFormat) {
                                for (i = 0; i < firstItems.length; i++) {
                                    value = column.calculateCellValue(firstItems[i], true);
                                    column.serializationFormat = column.serializationFormat || getSerializationFormat(column.dataType, value);
                                    if (lookup) {
                                        lookup.serializationFormat = lookup.serializationFormat || getSerializationFormat(lookup.dataType, lookup.calculateCellValue(value, true))
                                    }
                                }
                            }
                        }
                        column.selector = column.selector || function(data) {
                            return column.calculateCellValue(data)
                        };
                        $.each(["calculateSortValue", "calculateGroupValue", "calculateDisplayValue"], function(_, calculateCallbackName) {
                            var calculateCallback = column[calculateCallbackName];
                            if (commonUtils.isFunction(calculateCallback) && !calculateCallback.isProxy) {
                                column[calculateCallbackName] = function(data) {
                                    return calculateCallback.call(column, data)
                                };
                                column[calculateCallbackName].isProxy = true
                            }
                        });
                        if (commonUtils.isString(column.calculateDisplayValue)) {
                            column.displayField = column.calculateDisplayValue;
                            column.calculateDisplayValue = dataCoreUtils.compileGetter(column.displayField)
                        }
                        if (column.calculateDisplayValue) {
                            column.displayValueMap = column.displayValueMap || {}
                        }
                        updateSerializers(column, column.dataType);
                        if (lookup) {
                            updateSerializers(lookup, lookup.dataType)
                        }
                        dataType = lookup ? lookup.dataType : column.dataType;
                        if (dataType) {
                            column.alignment = column.alignment || getAlignmentByDataType(dataType, rtlEnabled);
                            column.format = column.format || gridCore.getFormatByDataType(dataType);
                            column.customizeText = column.customizeText || getCustomizeTextByDataType(dataType);
                            if (!isDefined(column.filterOperations)) {
                                column.filterOperations = !lookup && DATATYPE_OPERATIONS[dataType] || []
                            }
                            column.defaultFilterOperation = column.filterOperations && column.filterOperations[0] || "=";
                            column.showEditorAlways = isDefined(column.showEditorAlways) ? column.showEditorAlways : "boolean" === dataType && !column.cellTemplate
                        }
                    })
                },
                _customizeColumns: function(columns) {
                    var that = this,
                        customizeColumns = that.option("customizeColumns");
                    if (customizeColumns) {
                        customizeColumns(columns);
                        assignColumns(that, createColumnsFromOptions(that, columns))
                    }
                },
                updateColumns: function(dataSource, forceApplying) {
                    var sortParameters, groupParameters, that = this;
                    if (!forceApplying) {
                        that.updateSortingGrouping(dataSource)
                    }
                    if (!dataSource || dataSource.isLoaded()) {
                        sortParameters = dataSource ? dataSource.sort() || [] : that.getSortDataSourceParameters();
                        groupParameters = dataSource ? dataSource.group() || [] : that.getGroupDataSourceParameters();
                        that._customizeColumns(that._columns);
                        updateIndexes(that);
                        return $.when(that.refresh(true)).always(function() {
                            that._updateChanges(dataSource, {
                                sorting: sortParameters,
                                grouping: groupParameters
                            });
                            fireColumnsChanged(that)
                        })
                    }
                },
                _updateChanges: function(dataSource, parameters) {
                    var that = this;
                    if (dataSource) {
                        that.updateColumnDataTypes(dataSource);
                        that._dataSourceApplied = true
                    }
                    if (!equalSortParameters(parameters.sorting, that.getSortDataSourceParameters())) {
                        updateColumnChanges(that, "sorting")
                    }
                    if (!equalSortParameters(parameters.grouping, that.getGroupDataSourceParameters())) {
                        updateColumnChanges(that, "grouping")
                    }
                    updateColumnChanges(that, "columns")
                },
                updateSortingGrouping: function(dataSource, fromDataSource) {
                    var sortParameters, groupParameters, columnsGroupParameters, columnsSortParameters, isColumnsChanged, that = this,
                        updateSortGroupParameterIndexes = function(columns, sortParameters, indexParameterName) {
                            var i, selector, isExpanded;
                            $.each(columns, function(index, column) {
                                delete column[indexParameterName];
                                if (sortParameters) {
                                    for (i = 0; i < sortParameters.length; i++) {
                                        selector = sortParameters[i].selector;
                                        isExpanded = sortParameters[i].isExpanded;
                                        if (selector === column.dataField || selector === column.name || selector === column.selector || selector === column.calculateCellValue || selector === column.calculateGroupValue) {
                                            column.sortOrder = column.sortOrder || (sortParameters[i].desc ? "desc" : "asc");
                                            if (void 0 !== isExpanded) {
                                                column.autoExpandGroup = isExpanded
                                            }
                                            column[indexParameterName] = i;
                                            break
                                        }
                                    }
                                }
                            })
                        };
                    if (dataSource) {
                        sortParameters = normalizeSortingInfo(dataSource.sort());
                        groupParameters = normalizeSortingInfo(dataSource.group());
                        columnsGroupParameters = that.getGroupDataSourceParameters();
                        columnsSortParameters = that.getSortDataSourceParameters();
                        if (!that._columns.length) {
                            $.each(groupParameters, function(index, group) {
                                that._columns.push(group.selector)
                            });
                            $.each(sortParameters, function(index, sort) {
                                that._columns.push(sort.selector)
                            });
                            assignColumns(that, createColumnsFromOptions(that, that._columns))
                        }
                        if ((fromDataSource || !columnsGroupParameters && !that._hasUserState) && !equalSortParameters(groupParameters, columnsGroupParameters)) {
                            that.__groupingUpdated = true;
                            updateSortGroupParameterIndexes(that._columns, groupParameters, "groupIndex");
                            if (fromDataSource) {
                                updateColumnChanges(that, "grouping");
                                isColumnsChanged = true
                            }
                        }
                        if ((fromDataSource || !columnsSortParameters && !that._hasUserState) && !equalSortParameters(sortParameters, columnsSortParameters)) {
                            that.__sortingUpdated = true;
                            updateSortGroupParameterIndexes(that._columns, sortParameters, "sortIndex");
                            if (fromDataSource) {
                                updateColumnChanges(that, "sorting");
                                isColumnsChanged = true
                            }
                        }
                        if (isColumnsChanged) {
                            fireColumnsChanged(that)
                        }
                    }
                },
                updateFilter: function(filter, localFiltering, columnIndex) {
                    var that = this;
                    if (!commonUtils.isArray(filter)) {
                        return filter
                    }
                    var column, i;
                    filter = $.extend([], filter);
                    columnIndex = filter.columnIndex || columnIndex;
                    if (localFiltering && commonUtils.isString(filter[0])) {
                        column = that.columnOption(filter[0]);
                        if (column && column.selector) {
                            filter[0] = column.selector;
                            filter[0].columnIndex = column.index
                        }
                    } else {
                        if (commonUtils.isFunction(filter[0])) {
                            filter[0].columnIndex = columnIndex
                        }
                    }
                    for (i = 0; i < filter.length; i++) {
                        filter[i] = that.updateFilter(filter[i], localFiltering, columnIndex)
                    }
                    return filter
                },
                columnCount: function() {
                    return this._columns.length
                },
                columnOption: function(identificator, option, value, notFireEvent) {
                    var i, needUpdateIndexes, column, that = this,
                        identificatorOptionName = commonUtils.isString(identificator) && identificator.substr(0, identificator.indexOf(":")),
                        columns = identificator < 0 || "command" === identificatorOptionName ? that._commandColumns : that._columns;
                    if (void 0 === identificator) {
                        return
                    }
                    if (identificatorOptionName) {
                        identificator = identificator.substr(identificatorOptionName.length + 1)
                    }
                    for (i = 0; i < columns.length; i++) {
                        if (identificatorOptionName) {
                            if ("" + columns[i][identificatorOptionName] === identificator) {
                                column = columns[i];
                                break
                            }
                        } else {
                            if (columns[i].index === identificator || columns[i].name === identificator || columns[i].dataField === identificator || columns[i].caption === identificator) {
                                column = columns[i];
                                break
                            }
                        }
                    }
                    if (column) {
                        if (1 === arguments.length) {
                            return $.extend({}, column)
                        }
                        if (commonUtils.isString(option)) {
                            if (2 === arguments.length) {
                                return columnOptionCore(that, column, option)
                            } else {
                                needUpdateIndexes = needUpdateIndexes || COLUMN_INDEX_OPTIONS[option];
                                columnOptionCore(that, column, option, value, notFireEvent)
                            }
                        } else {
                            if (commonUtils.isObject(option)) {
                                $.each(option, function(optionName, value) {
                                    needUpdateIndexes = needUpdateIndexes || COLUMN_INDEX_OPTIONS[optionName];
                                    columnOptionCore(that, column, optionName, value, notFireEvent)
                                })
                            }
                        }
                        if (needUpdateIndexes) {
                            updateIndexes(that, column)
                        }
                        fireColumnsChanged(that)
                    }
                },
                clearSorting: function() {
                    var i, that = this,
                        columnCount = this.columnCount();
                    that.beginUpdate();
                    for (i = 0; i < columnCount; i++) {
                        that.columnOption(i, "sortOrder", void 0)
                    }
                    that.endUpdate()
                },
                clearGrouping: function() {
                    var i, that = this,
                        columnCount = this.columnCount();
                    that.beginUpdate();
                    for (i = 0; i < columnCount; i++) {
                        that.columnOption(i, "groupIndex", void 0)
                    }
                    that.endUpdate()
                },
                getVisibleIndex: function(index, rowIndex) {
                    var i, columns = this.getVisibleColumns(rowIndex);
                    for (i = 0; i < columns.length; i++) {
                        if (columns[i].index === index) {
                            return i
                        }
                    }
                    return -1
                },
                addColumn: function(options) {
                    var that = this,
                        column = createColumn(that, options);
                    column.added = options;
                    that._columns.push(column);
                    updateIndexes(that, column);
                    that.updateColumns(that._dataSource)
                },
                deleteColumn: function(id) {
                    var that = this,
                        columnIndex = that.columnOption(id, "index");
                    if (columnIndex >= 0) {
                        that._columns.splice(columnIndex, 1);
                        updateIndexes(that);
                        that.updateColumns(that._dataSource)
                    }
                },
                addCommandColumn: function(options) {
                    var i, commandColumns = this._commandColumns;
                    for (i = 0; i < commandColumns.length; i++) {
                        if (commandColumns[i].command === options.command) {
                            return
                        }
                    }
                    commandColumns.push(options)
                },
                getUserState: function() {
                    var i, columns = this._columns,
                        result = [];

                    function handleStateField(index, value) {
                        if (void 0 !== columns[i][value]) {
                            result[i][value] = columns[i][value]
                        }
                    }
                    for (i = 0; i < columns.length; i++) {
                        result[i] = {};
                        $.each(USER_STATE_FIELD_NAMES, handleStateField)
                    }
                    return result
                },
                setUserState: function(state) {
                    var commonColumnSettings, that = this,
                        ignoreColumnOptionNames = that.option("stateStoring.ignoreColumnOptionNames");
                    if (!ignoreColumnOptionNames) {
                        ignoreColumnOptionNames = [];
                        commonColumnSettings = that.getCommonSettings();
                        if (!that.option("columnChooser.enabled")) {
                            ignoreColumnOptionNames.push("visible")
                        }
                        if ("none" === that.option("sorting.mode")) {
                            ignoreColumnOptionNames.push("sortIndex", "sortOrder")
                        }
                        if (!commonColumnSettings.allowGrouping) {
                            ignoreColumnOptionNames.push("groupIndex")
                        }
                        if (!commonColumnSettings.allowFixing) {
                            ignoreColumnOptionNames.push("fixed", "fixedPosition")
                        }
                        if (!commonColumnSettings.allowResizing) {
                            ignoreColumnOptionNames.push("width", "visibleWidth")
                        }
                        if (!that.option("filterRow.visible")) {
                            ignoreColumnOptionNames.push("filterValue", "selectedFilterOperation")
                        }
                        if (!that.option("headerFilter.visible")) {
                            ignoreColumnOptionNames.push("filterValues", "filterType")
                        }
                    }
                    that._columnsUserState = state;
                    that._ignoreColumnOptionNames = ignoreColumnOptionNames;
                    that._hasUserState = !!state;
                    that.init()
                },
                _createCalculatedColumnOptions: function(columnOptions, bandColumn) {
                    var getter, calculatedColumnOptions = {},
                        dataField = columnOptions.dataField;
                    if (commonUtils.isArray(columnOptions.columns) && columnOptions.columns.length || columnOptions.isBand) {
                        calculatedColumnOptions.isBand = true;
                        dataField = null
                    }
                    if (dataField) {
                        if (commonUtils.isString(dataField)) {
                            getter = dataCoreUtils.compileGetter(dataField);
                            calculatedColumnOptions = {
                                caption: inflector.captionize(dataField),
                                calculateCellValue: function(data, skipDeserialization) {
                                    var value = getter(data);
                                    return this.deserializeValue && !skipDeserialization ? this.deserializeValue(value) : value
                                },
                                setCellValue: defaultSetCellValue,
                                parseValue: function(text) {
                                    var result, parsedValue, column = this;
                                    if ("number" === column.dataType) {
                                        if (commonUtils.isString(text)) {
                                            parsedValue = numberLocalization.parse(text);
                                            if (commonUtils.isNumber(parsedValue)) {
                                                result = parsedValue
                                            }
                                        } else {
                                            if (isDefined(text)) {
                                                result = Number(text)
                                            }
                                        }
                                    } else {
                                        if ("boolean" === column.dataType) {
                                            if (text === column.trueText) {
                                                result = true
                                            } else {
                                                if (text === column.falseText) {
                                                    result = false
                                                }
                                            }
                                        } else {
                                            if ("date" === column.dataType) {
                                                parsedValue = dateLocalization.parse(text, column.format);
                                                if (parsedValue) {
                                                    result = parsedValue
                                                }
                                            } else {
                                                result = text
                                            }
                                        }
                                    }
                                    return result
                                }
                            }
                        }
                        calculatedColumnOptions.allowFiltering = true
                    } else {
                        calculatedColumnOptions.allowFiltering = !!columnOptions.calculateFilterExpression
                    }
                    calculatedColumnOptions.calculateFilterExpression = function() {
                        return gridCore.defaultCalculateFilterExpression.apply(this, arguments)
                    };
                    calculatedColumnOptions.createFilterExpression = function() {
                        var result;
                        if (this.calculateFilterExpression) {
                            result = this.calculateFilterExpression.apply(this, arguments)
                        }
                        if (result) {
                            result.columnIndex = this.index
                        }
                        return result
                    };
                    if (!dataField || !commonUtils.isString(dataField)) {
                        $.extend(true, calculatedColumnOptions, {
                            allowSorting: false,
                            allowGrouping: false,
                            calculateCellValue: function() {
                                return null
                            }
                        })
                    }
                    if (bandColumn) {
                        calculatedColumnOptions.allowFixing = false
                    }
                    if (columnOptions.dataType) {
                        calculatedColumnOptions.userDataType = columnOptions.dataType
                    }
                    if (columnOptions.selectedFilterOperation) {
                        calculatedColumnOptions.defaultSelectedFilterOperation = columnOptions.selectedFilterOperation
                    }
                    if (columnOptions.lookup) {
                        calculatedColumnOptions.lookup = {
                            calculateCellValue: function(value, skipDeserialization) {
                                if (this.valueExpr) {
                                    value = this.valueMap && this.valueMap[value]
                                }
                                return this.deserializeValue && !skipDeserialization ? this.deserializeValue(value) : value
                            },
                            updateValueMap: function() {
                                var calculateValue, calculateDisplayValue, item, i;
                                this.valueMap = {};
                                if (this.items) {
                                    calculateValue = dataCoreUtils.compileGetter(this.valueExpr);
                                    calculateDisplayValue = dataCoreUtils.compileGetter(this.displayExpr);
                                    for (i = 0; i < this.items.length; i++) {
                                        item = this.items[i];
                                        this.valueMap[calculateValue(item)] = calculateDisplayValue(item)
                                    }
                                }
                            },
                            update: function() {
                                var dataSourceOptions, that = this,
                                    dataSource = that.dataSource;
                                if (dataSource) {
                                    if (commonUtils.isFunction(dataSource) && !isWrapped(dataSource)) {
                                        dataSource = dataSource({})
                                    }
                                    if (commonUtils.isObject(dataSource) || commonUtils.isArray(dataSource)) {
                                        if (that.valueExpr) {
                                            dataSourceOptions = normalizeDataSourceOptions(dataSource);
                                            dataSourceOptions.paginate = false;
                                            dataSource = new DataSourceModule.DataSource(dataSourceOptions);
                                            return dataSource.load().done(function(data) {
                                                that.items = data;
                                                that.updateValueMap && that.updateValueMap()
                                            })
                                        }
                                    } else {
                                        errors.log("E1016")
                                    }
                                } else {
                                    that.updateValueMap && that.updateValueMap()
                                }
                            }
                        }
                    }
                    calculatedColumnOptions.resizedCallbacks = $.Callbacks();
                    if (columnOptions.resized) {
                        calculatedColumnOptions.resizedCallbacks.add($.proxy(columnOptions.resized, columnOptions))
                    }
                    $.each(calculatedColumnOptions, function(optionName) {
                        var defaultOptionName;
                        if (commonUtils.isFunction(calculatedColumnOptions[optionName]) && 0 !== optionName.indexOf("default")) {
                            defaultOptionName = "default" + optionName.charAt(0).toUpperCase() + optionName.substr(1);
                            calculatedColumnOptions[defaultOptionName] = calculatedColumnOptions[optionName]
                        }
                    });
                    return calculatedColumnOptions
                },
                getRowCount: function(rowCount, bandColumnIndex) {
                    this._rowCount = this._rowCount || getRowCount(this);
                    return this._rowCount
                },
                getRowIndex: function(columnIndex, alwaysGetRowIndex) {
                    var column = this._columns[columnIndex];
                    return column && (alwaysGetRowIndex || column.visible && !(column.command || isDefined(column.groupIndex))) ? getParentBandColumns(columnIndex, this._columns).length : 0
                },
                getChildrenByBandColumn: function(bandColumnIndex, rowIndex) {
                    var that = this,
                        result = [];
                    if (isDefined(rowIndex)) {
                        result = $.grep(that.getVisibleColumns(rowIndex), function(column) {
                            return column.ownerBand === bandColumnIndex && !column.command
                        })
                    } else {
                        $.each(that._columns, function(_, column) {
                            if ((!isDefined(column.groupIndex) || column.showWhenGrouped) && that.isParentBandColumn(column.index, bandColumnIndex)) {
                                result.push(column)
                            }
                        })
                    }
                    return result
                },
                isParentBandColumn: function(columnIndex, bandColumnIndex) {
                    var result = false,
                        column = this._columns[columnIndex],
                        parentBandColumns = column && getParentBandColumns(columnIndex, this._columns);
                    if (parentBandColumns) {
                        $.each(parentBandColumns, function(_, bandColumn) {
                            if (bandColumn.index === bandColumnIndex) {
                                result = true;
                                return false
                            }
                        })
                    }
                    return result
                },
                isParentColumnVisible: function(columnIndex) {
                    var result = true,
                        bandColumns = columnIndex >= 0 && getParentBandColumns(columnIndex, this._columns);
                    bandColumns && $.each(bandColumns, function(_, bandColumn) {
                        result = result && bandColumn.visible;
                        return result
                    });
                    return result
                }
            }
        }());
        exports.ColumnsController = ColumnsController;
        gridCore.registerModule("columns", {
            defaultOptions: function() {
                return {
                    commonColumnSettings: {
                        allowFiltering: true,
                        allowHiding: true,
                        allowSorting: true,
                        allowEditing: true,
                        encodeHtml: true,
                        trueText: messageLocalization.format("dxDataGrid-trueText"),
                        falseText: messageLocalization.format("dxDataGrid-falseText")
                    },
                    allowColumnReordering: false,
                    allowColumnResizing: false,
                    adaptColumnWidthByRatio: true,
                    columns: void 0,
                    regenerateColumnsByVisibleItems: false,
                    customizeColumns: null
                }
            },
            controllers: {
                columns: ColumnsController
            }
        })
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.data_controller.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            dataSourceAdapterProvider = __webpack_require__( /*! ./ui.data_grid.data_source_adapter */ 344),
            ArrayStore = __webpack_require__( /*! ../../data/array_store */ 162),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            DataHelperMixin = __webpack_require__( /*! ../collection/ui.data_helper */ 154);
        exports.DataController = gridCore.Controller.inherit({}).include(DataHelperMixin).inherit(function() {
            var members = {
                init: function() {
                    var that = this;
                    that._items = [];
                    that._columnsController = that.getController("columns");
                    that._columnsChangedHandler = $.proxy(that._handleColumnsChanged, that);
                    that._dataChangedHandler = $.proxy(that._handleDataChanged, that);
                    that._loadingChangedHandler = $.proxy(that._handleLoadingChanged, that);
                    that._loadErrorHandler = $.proxy(that._handleLoadError, that);
                    that._customizeStoreLoadOptionsHandler = $.proxy(that._handleCustomizeStoreLoadOptions, that);
                    that._columnsController.columnsChanged.add(that._columnsChangedHandler);
                    that._isLoading = false;
                    that._isCustomLoading = false;
                    that.createAction("onDataErrorOccurred");
                    that.dataErrorOccurred.add(function(error) {
                        return that.executeAction("onDataErrorOccurred", {
                            error: error
                        })
                    });
                    that._refreshDataSource()
                },
                callbackNames: function() {
                    return ["changed", "loadingChanged", "dataErrorOccurred", "pageChanged", "dataSourceChanged"]
                },
                callbackFlags: function(name) {
                    if ("dataErrorOccurred" === name) {
                        return {
                            stopOnFalse: true
                        }
                    }
                },
                publicMethods: function() {
                    return ["beginCustomLoading", "endCustomLoading", "refresh", "filter", "clearFilter", "getCombinedFilter", "keyOf", "byKey", "getDataByKeys", "pageIndex", "pageSize", "pageCount", "totalCount", "_disposeDataSource", "getKeyByRowIndex", "getRowIndexByKey"]
                },
                optionChanged: function(args) {
                    var that = this;

                    function handled() {
                        args.handled = true
                    }

                    function reload() {
                        that._columnsController.reset();
                        that._refreshDataSource()
                    }
                    if ("dataSource" === args.name && args.name === args.fullName && args.value === args.previousValue) {
                        handled();
                        that.refresh();
                        return
                    }
                    switch (args.name) {
                        case "cacheEnabled":
                        case "loadingTimeout":
                        case "remoteOperations":
                            handled();
                            break;
                        case "dataSource":
                        case "scrolling":
                        case "paging":
                            handled();
                            reload();
                            break;
                        case "rtlEnabled":
                            reload();
                            break;
                        default:
                            that.callBase(args)
                    }
                },
                isReady: function() {
                    return !this._isLoading
                },
                getCombinedFilter: function() {
                    return this.combinedFilter()
                },
                combinedFilter: function(filter) {
                    var additionalFilter, that = this,
                        dataSource = that._dataSource,
                        columnsController = that._columnsController;
                    if (dataSource) {
                        if (void 0 === filter) {
                            filter = dataSource.filter()
                        }
                        additionalFilter = that._calculateAdditionalFilter();
                        if (additionalFilter) {
                            if (columnsController.isDataSourceApplied() || columnsController.isAllDataTypesDefined()) {
                                filter = gridCore.combineFilters([additionalFilter, filter])
                            }
                        }
                        filter = columnsController.updateFilter(filter, !dataSource.remoteOperations().filtering)
                    }
                    return filter
                },
                _handleCustomizeStoreLoadOptions: function(e) {
                    var columnsController = this._columnsController,
                        dataSource = this._dataSource,
                        storeLoadOptions = e.storeLoadOptions;
                    if (e.isCustomLoading && !storeLoadOptions.isLoadingAll) {
                        return
                    }
                    storeLoadOptions.filter = this.combinedFilter(storeLoadOptions.filter);
                    if (!columnsController.isDataSourceApplied()) {
                        columnsController.updateColumnDataTypes(dataSource)
                    }
                    this._columnsUpdating = true;
                    columnsController.updateSortingGrouping(dataSource, !this._isFirstLoading);
                    this._columnsUpdating = false;
                    storeLoadOptions.sort = columnsController.getSortDataSourceParameters();
                    storeLoadOptions.group = columnsController.getGroupDataSourceParameters();
                    dataSource.sort(storeLoadOptions.sort);
                    dataSource.group(storeLoadOptions.group);
                    storeLoadOptions.sort = columnsController.getSortDataSourceParameters(!dataSource.remoteOperations().sorting);
                    e.group = columnsController.getGroupDataSourceParameters(true);
                    this._isFirstLoading = false
                },
                _handleColumnsChanged: function(e) {
                    var filterValue, filterValues, that = this,
                        changeTypes = e.changeTypes,
                        optionNames = e.optionNames;
                    var updateItemsHandler = function() {
                        that._columnsController.columnsChanged.remove(updateItemsHandler);
                        that.updateItems()
                    };
                    if (changeTypes.sorting || changeTypes.grouping) {
                        if (that._dataSource && !that._columnsUpdating) {
                            that._dataSource.group(that._columnsController.getGroupDataSourceParameters());
                            that._dataSource.sort(that._columnsController.getSortDataSourceParameters());
                            that.reload()
                        }
                        that.pageChanged.fire()
                    } else {
                        if (changeTypes.columns) {
                            if (optionNames.filterValues || optionNames.filterValue || optionNames.selectedFilterOperation) {
                                filterValue = that._columnsController.columnOption(e.columnIndex, "filterValue");
                                filterValues = that._columnsController.columnOption(e.columnIndex, "filterValues");
                                if (commonUtils.isArray(filterValues) || void 0 === e.columnIndex || commonUtils.isDefined(filterValue) || !optionNames.selectedFilterOperation || optionNames.filterValue) {
                                    that._applyFilter()
                                }
                            }
                            if (!that._needApplyFilter && !gridCore.checkChanges(optionNames, ["width", "visibleWidth", "filterValue", "selectedFilterOperation", "filterValues", "filterType"])) {
                                that._columnsController.columnsChanged.add(updateItemsHandler)
                            }
                        }
                    }
                },
                _handleDataChanged: function(e) {
                    var that = this,
                        dataSource = that._dataSource,
                        columnsController = that._columnsController,
                        isAllDataTypesDefined = columnsController.isAllDataTypesDefined();
                    if (dataSource && !that._isDataSourceApplying) {
                        that._isDataSourceApplying = true;
                        $.when(that._columnsController.applyDataSource(dataSource)).done(function() {
                            if (that._isLoading) {
                                that._handleLoadingChanged(false)
                            }
                            that._isDataSourceApplying = false;
                            var additionalFilter = that._calculateAdditionalFilter(),
                                needApplyFilter = that._needApplyFilter;
                            that._needApplyFilter = false;
                            if (needApplyFilter && additionalFilter && additionalFilter.length && !isAllDataTypesDefined) {
                                errors.log("W1005", that.component.NAME);
                                that._applyFilter()
                            } else {
                                that.updateItems(e)
                            }
                        });
                        if (that._isDataSourceApplying) {
                            that._handleLoadingChanged(true)
                        }
                        that._needApplyFilter = !that._columnsController.isDataSourceApplied()
                    }
                },
                _handleLoadingChanged: function(isLoading) {
                    this._isLoading = isLoading;
                    this._fireLoadingChanged()
                },
                _handleLoadError: function(e) {
                    this.dataErrorOccurred.fire(e)
                },
                _initDataSource: function() {
                    var that = this,
                        dataSource = this.option("dataSource"),
                        pageIndex = this.option("paging.pageIndex"),
                        pageSize = this.option("paging.pageSize"),
                        scrollingMode = that.option("scrolling.mode"),
                        pagingEnabled = this.option("paging.enabled"),
                        appendMode = "infinite" === scrollingMode,
                        virtualMode = "virtual" === scrollingMode,
                        oldDataSource = this._dataSource;
                    that.callBase();
                    dataSource = that._dataSource;
                    that._isFirstLoading = true;
                    if (dataSource) {
                        dataSource.requireTotalCount(!appendMode);
                        if (void 0 !== pagingEnabled) {
                            dataSource.paginate(pagingEnabled || virtualMode || appendMode)
                        }
                        if (void 0 !== pageSize) {
                            dataSource.pageSize(pageSize)
                        }
                        if (void 0 !== pageIndex) {
                            dataSource.pageIndex(pageIndex)
                        }
                        that.setDataSource(dataSource)
                    } else {
                        if (oldDataSource) {
                            that.updateItems()
                        }
                    }
                },
                _loadDataSource: function() {
                    var dataSource = this._dataSource;
                    dataSource && dataSource.load()
                },
                _processItems: function(items) {
                    var that = this,
                        visibleColumns = that._columnsController.getVisibleColumns(),
                        options = {
                            visibleColumns: visibleColumns,
                            dataIndex: 0
                        },
                        result = [];
                    $.each(items, function(index, item) {
                        if (commonUtils.isDefined(item)) {
                            item = that._processItem(item, options);
                            result.push(item)
                        }
                    });
                    return result
                },
                _processItem: function(item, options) {
                    item = this._generateDataItem(item);
                    item = this._processDataItem(item, options);
                    item.dataIndex = options.dataIndex++;
                    return item
                },
                _generateDataItem: function(data) {
                    return {
                        rowType: "data",
                        data: data,
                        key: this.keyOf(data)
                    }
                },
                _processDataItem: function(dataItem, options) {
                    dataItem.values = this.generateDataValues(dataItem.data, options.visibleColumns);
                    return dataItem
                },
                generateDataValues: function(data, columns) {
                    var column, value, values = [];
                    for (var i = 0; i < columns.length; i++) {
                        column = columns[i];
                        value = null;
                        if (column.command) {
                            value = null
                        } else {
                            if (column.calculateCellValue) {
                                value = column.calculateCellValue(data)
                            } else {
                                if (column.dataField) {
                                    value = data[column.dataField]
                                }
                            }
                        }
                        values.push(value)
                    }
                    return values
                },
                _updateItemsCore: function(change) {
                    var items, that = this,
                        dataSource = that._dataSource,
                        changeType = change.changeType || "refresh";
                    change.changeType = changeType;
                    if (dataSource) {
                        items = change.items || dataSource.items();
                        items = that._processItems(items.slice(0), changeType);
                        change.items = items;
                        switch (changeType) {
                            case "prepend":
                                that._items.unshift.apply(that._items, items);
                                break;
                            case "append":
                                that._items.push.apply(that._items, items);
                                break;
                            case "update":
                                var prevIndex = -1,
                                    rowIndices = change.rowIndices.slice(0),
                                    rowIndexCorrection = 0;
                                rowIndices.sort(function(a, b) {
                                    return a - b
                                });
                                for (var i = 0; i < rowIndices.length; i++) {
                                    if (rowIndices[i] < 0) {
                                        rowIndices.splice(i, 1);
                                        i--
                                    }
                                }
                                change.items = [];
                                change.rowIndices = [];
                                change.changeTypes = [];
                                var equalItems = function(item1, item2, strict) {
                                    return item1 && item2 && gridCoreUtils.equalKeys(item1.key, item2.key) && (!strict || item1.rowType === item2.rowType)
                                };
                                $.each(rowIndices, function(index, rowIndex) {
                                    var oldItem, newItem, oldNextItem, newNextItem, strict;
                                    rowIndex += rowIndexCorrection;
                                    if (prevIndex === rowIndex) {
                                        return
                                    }
                                    change.rowIndices.push(rowIndex);
                                    prevIndex = rowIndex;
                                    oldItem = that._items[rowIndex];
                                    oldNextItem = that._items[rowIndex + 1];
                                    newItem = items[rowIndex];
                                    newNextItem = items[rowIndex + 1];
                                    strict = equalItems(oldItem, oldNextItem) || equalItems(newItem, newNextItem);
                                    if (newItem) {
                                        change.items.push(newItem)
                                    }
                                    if (oldItem && newItem && equalItems(oldItem, newItem, strict)) {
                                        changeType = "update";
                                        that._items[rowIndex] = newItem;
                                        if (oldItem.visible !== newItem.visible) {
                                            change.items.splice(-1, 1, {
                                                visible: newItem.visible
                                            })
                                        }
                                    } else {
                                        if (newItem && !oldItem || newNextItem && equalItems(oldItem, newNextItem, strict)) {
                                            changeType = "insert";
                                            that._items.splice(rowIndex, 0, newItem);
                                            rowIndexCorrection++
                                        } else {
                                            if (oldItem && !newItem || oldNextItem && equalItems(newItem, oldNextItem, strict)) {
                                                changeType = "remove";
                                                that._items.splice(rowIndex, 1);
                                                rowIndexCorrection--;
                                                prevIndex = -1
                                            }
                                        }
                                    }
                                    change.changeTypes.push(changeType)
                                });
                                break;
                            default:
                                that._items = items.slice(0)
                        }
                        $.each(that._items, function(index, item) {
                            item.rowIndex = index
                        })
                    } else {
                        that._items = []
                    }
                },
                updateItems: function(change) {
                    change = change || {};
                    var that = this;
                    that._updateItemsCore(change);
                    commonUtils.deferRender(function() {
                        that.changed.fire(change)
                    })
                },
                isLoading: function() {
                    return this._isLoading || this._isCustomLoading
                },
                _fireLoadingChanged: function(messageText) {
                    this.loadingChanged.fire(this.isLoading(), messageText)
                },
                _calculateAdditionalFilter: function() {
                    return null
                },
                _applyFilter: function() {
                    var that = this,
                        dataSource = that._dataSource;
                    if (dataSource) {
                        dataSource.pageIndex(0);
                        return that.reload().done($.proxy(that.pageChanged, "fire"))
                    }
                },
                filter: function(filterExpr) {
                    var dataSource = this._dataSource,
                        filter = dataSource.filter();
                    if (0 === arguments.length) {
                        return dataSource ? dataSource.filter() : void 0
                    }
                    filterExpr = arguments.length > 1 ? Array.prototype.slice.call(arguments, 0) : filterExpr;
                    if (gridCore.equalFilterParameters(filter, filterExpr)) {
                        return
                    }
                    if (dataSource) {
                        dataSource.filter(filterExpr)
                    }
                    this._applyFilter()
                },
                clearFilter: function(filterName) {
                    var that = this,
                        columnsController = that._columnsController,
                        clearColumnOption = function(optionName) {
                            var index, columnCount = columnsController.columnCount();
                            for (index = 0; index < columnCount; index++) {
                                columnsController.columnOption(index, optionName, void 0)
                            }
                        };
                    that.component.beginUpdate();
                    if (arguments.length > 0) {
                        switch (filterName) {
                            case "dataSource":
                                that.filter(null);
                                break;
                            case "search":
                                that.searchByText("");
                                break;
                            case "header":
                                clearColumnOption("filterValues");
                                break;
                            case "row":
                                clearColumnOption("filterValue")
                        }
                    } else {
                        that.filter(null);
                        that.searchByText("");
                        clearColumnOption("filterValue");
                        clearColumnOption("filterValues")
                    }
                    that.component.endUpdate()
                },
                _fireDataSourceChanged: function() {
                    var that = this;
                    var changedHandler = function() {
                        that.changed.remove(changedHandler);
                        that.dataSourceChanged.fire()
                    };
                    that.changed.add(changedHandler)
                },
                _createDataSourceAdapterCore: function(dataSource, remoteOperations) {
                    var dataSourceAdapter = dataSourceAdapterProvider.create(this.component);
                    dataSourceAdapter.init(dataSource, remoteOperations);
                    return dataSourceAdapter
                },
                isLocalStore: function(store) {
                    store = store || this.store();
                    return store instanceof ArrayStore
                },
                _createDataSourceAdapter: function(dataSource) {
                    var remoteOperations = this.option("remoteOperations");
                    if ("auto" === remoteOperations) {
                        remoteOperations = this.isLocalStore(dataSource.store()) ? {} : {
                            filtering: true,
                            sorting: true,
                            paging: true
                        }
                    }
                    if (true === remoteOperations) {
                        remoteOperations = {
                            filtering: true,
                            sorting: true,
                            paging: true,
                            grouping: true,
                            summary: true
                        }
                    }
                    return this._createDataSourceAdapterCore(dataSource, remoteOperations)
                },
                setDataSource: function(dataSource) {
                    var that = this,
                        oldDataSource = that._dataSource;
                    if (!dataSource && oldDataSource) {
                        oldDataSource.changed.remove(that._dataChangedHandler);
                        oldDataSource.loadingChanged.remove(that._loadingChangedHandler);
                        oldDataSource.loadError.remove(that._loadErrorHandler);
                        oldDataSource.customizeStoreLoadOptions.remove(that._customizeStoreLoadOptionsHandler);
                        oldDataSource.dispose(that._isSharedDataSource)
                    }
                    if (dataSource) {
                        dataSource = that._createDataSourceAdapter(dataSource)
                    }
                    that._dataSource = dataSource;
                    if (dataSource) {
                        that._fireDataSourceChanged();
                        that._isLoading = !dataSource.isLoaded();
                        that._needApplyFilter = true;
                        dataSource.changed.add(that._dataChangedHandler);
                        dataSource.loadingChanged.add(that._loadingChangedHandler);
                        dataSource.loadError.add(that._loadErrorHandler);
                        dataSource.customizeStoreLoadOptions.add(that._customizeStoreLoadOptionsHandler)
                    }
                },
                items: function() {
                    return this._items
                },
                isEmpty: function() {
                    return !this.items().length
                },
                pageCount: function() {
                    return this._dataSource ? this._dataSource.pageCount() : 1
                },
                dataSource: function() {
                    return this._dataSource
                },
                store: function() {
                    var dataSource = this._dataSource;
                    return dataSource && dataSource.store()
                },
                loadAll: function(data) {
                    var that = this,
                        d = $.Deferred(),
                        dataSource = that._dataSource;
                    if (dataSource) {
                        if (data) {
                            var options = {
                                data: data,
                                isCustomLoading: true,
                                storeLoadOptions: {},
                                loadOptions: {
                                    group: dataSource.group(),
                                    sort: dataSource.sort()
                                }
                            };
                            dataSource._handleDataLoaded(options);
                            d.resolve(that._processItems(options.data, "loadingAll"), options.extra && options.extra.summary)
                        } else {
                            if (!that.isLoading()) {
                                var loadOptions = $.extend({
                                    isLoadingAll: true
                                }, dataSource.loadOptions());
                                loadOptions.requireTotalCount = false;
                                dataSource.load(loadOptions).done(function(items, extra) {
                                    items = that._processItems(items.slice(0), "loadingAll");
                                    d.resolve(items, extra && extra.summary)
                                }).fail(d.reject)
                            } else {
                                d.reject()
                            }
                        }
                    } else {
                        d.resolve([])
                    }
                    return d
                },
                getKeyByRowIndex: function(rowIndex) {
                    var item = this.items()[rowIndex];
                    if (item) {
                        return item.key
                    }
                },
                getRowIndexByKey: function(key) {
                    return gridCoreUtils.getIndexByKey(key, this.items())
                },
                keyOf: function(data) {
                    var store = this.store();
                    if (store) {
                        return store.keyOf(data)
                    }
                },
                byKey: function(key) {
                    var result, store = this.store(),
                        rowIndex = this.getRowIndexByKey(key);
                    if (!store) {
                        return
                    }
                    if (rowIndex >= 0) {
                        result = $.Deferred().resolve(this.items()[rowIndex].data)
                    }
                    return result || store.byKey(key)
                },
                getDataByKeys: function(rowKeys) {
                    var that = this,
                        result = $.Deferred(),
                        deferreds = [],
                        data = [];
                    $.each(rowKeys, function(index, key) {
                        deferreds.push(that.byKey(key).done(function(keyData) {
                            data[index] = keyData
                        }))
                    });
                    $.when.apply($, deferreds).always(function() {
                        result.resolve(data)
                    });
                    return result
                },
                pageIndex: function(value) {
                    var that = this,
                        pagingOptions = that.option("paging"),
                        dataSource = that._dataSource;
                    if (dataSource) {
                        if (void 0 !== value) {
                            if (dataSource.pageIndex() !== value) {
                                dataSource.pageIndex(value);
                                if (pagingOptions) {
                                    pagingOptions.pageIndex = value
                                }
                                return dataSource.load().done($.proxy(that.pageChanged, "fire"))
                            }
                        }
                        return dataSource.pageIndex()
                    }
                    return 0
                },
                pageSize: function(value) {
                    var that = this,
                        pagingOptions = that.option("paging"),
                        dataSource = that._dataSource;
                    if (void 0 === value) {
                        return dataSource ? dataSource.pageSize() : 0
                    }
                    if (dataSource) {
                        if (dataSource.pageSize() !== value) {
                            dataSource.pageIndex(0);
                            dataSource.pageSize(value);
                            if (pagingOptions) {
                                pagingOptions.pageSize = value
                            }
                            return dataSource.reload().done($.proxy(that.pageChanged, "fire"))
                        }
                    }
                },
                beginCustomLoading: function(messageText) {
                    this._isCustomLoading = true;
                    this._fireLoadingChanged(messageText || "")
                },
                endCustomLoading: function() {
                    this._isCustomLoading = false;
                    this._fireLoadingChanged()
                },
                refresh: function() {
                    var that = this,
                        d = $.Deferred();
                    $.when(this._columnsController.refresh()).always(function() {
                        $.when(that.reload(true)).done(d.resolve).fail(d.reject)
                    });
                    return d
                },
                _disposeDataSource: function() {
                    this.setDataSource(null)
                }
            };
            gridCore.proxyMethod(members, "load");
            gridCore.proxyMethod(members, "reload");
            gridCore.proxyMethod(members, "itemsCount", 0);
            gridCore.proxyMethod(members, "totalItemsCount", 0);
            gridCore.proxyMethod(members, "hasKnownLastPage", true);
            gridCore.proxyMethod(members, "isLoaded", true);
            gridCore.proxyMethod(members, "totalCount", 0);
            return members
        }());
        gridCore.registerModule("data", {
            defaultOptions: function() {
                return {
                    loadingTimeout: 0,
                    dataSource: null,
                    cacheEnabled: true,
                    onDataErrorOccurred: null,
                    remoteOperations: "auto",
                    paging: {
                        enabled: true,
                        pageSize: void 0,
                        pageIndex: void 0
                    }
                }
            },
            controllers: {
                data: exports.DataController
            }
        })
    },
    /*!******************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.data_source_adapter.js ***!
      \******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            ArrayStore = __webpack_require__( /*! ../../data/array_store */ 162);

        function cloneItems(items, groupCount) {
            if (items) {
                items = items.slice(0);
                if (groupCount) {
                    for (var i = 0; i < items.length; i++) {
                        items[i] = $.extend({
                            key: items[i].key
                        }, items[i]);
                        items[i].items = cloneItems(items[i].items, groupCount - 1)
                    }
                }
            }
            return items
        }
        var DataSourceAdapter = gridCore.Controller.inherit(function() {
            function calculateOperationTypes(loadOptions, lastLoadOptions) {
                var operationTypes = {};
                if (lastLoadOptions) {
                    operationTypes = {
                        sorting: !gridCore.equalSortParameters(loadOptions.sort, lastLoadOptions.sort),
                        grouping: !gridCore.equalSortParameters(loadOptions.group, lastLoadOptions.group, true),
                        filtering: !gridCore.equalFilterParameters(loadOptions.filter, lastLoadOptions.filter),
                        skip: loadOptions.skip !== lastLoadOptions.skip,
                        take: loadOptions.take !== lastLoadOptions.take
                    };
                    operationTypes.reload = operationTypes.sorting || operationTypes.grouping || operationTypes.filtering;
                    operationTypes.paging = operationTypes.skip || operationTypes.take
                }
                return operationTypes
            }

            function executeTask(action, timeout) {
                if (commonUtils.isDefined(timeout)) {
                    commonUtils.executeAsync(action, timeout)
                } else {
                    action()
                }
            }
            return {
                init: function(dataSource, remoteOperations) {
                    var that = this;
                    that._dataSource = dataSource;
                    that._remoteOperations = remoteOperations || {};
                    that._isLastPage = !dataSource.isLastPage();
                    that._hasLastPage = false;
                    that._currentTotalCount = 0;
                    that.changed = $.Callbacks();
                    that.loadingChanged = $.Callbacks();
                    that.loadError = $.Callbacks();
                    that.customizeStoreLoadOptions = $.Callbacks();
                    that._dataChangedHandler = $.proxy(that._handleDataChanged, that);
                    that._dataLoadingHandler = $.proxy(that._handleDataLoading, that);
                    that._dataLoadedHandler = $.proxy(that._handleDataLoaded, that);
                    that._loadingChangedHandler = $.proxy(that._handleLoadingChanged, that);
                    that._loadErrorHandler = $.proxy(that._handleLoadError, that);
                    dataSource.on("changed", that._dataChangedHandler);
                    dataSource.on("customizeStoreLoadOptions", that._dataLoadingHandler);
                    dataSource.on("customizeLoadResult", that._dataLoadedHandler);
                    dataSource.on("loadingChanged", that._loadingChangedHandler);
                    dataSource.on("loadError", that._loadErrorHandler);
                    $.each(dataSource, function(memberName, member) {
                        if (!that[memberName] && $.isFunction(member)) {
                            that[memberName] = function() {
                                return this._dataSource[memberName].apply(this._dataSource, arguments)
                            }
                        }
                    })
                },
                remoteOperations: function() {
                    return this._remoteOperations
                },
                dispose: function(isSharedDataSource) {
                    var that = this,
                        dataSource = that._dataSource;
                    dataSource.off("changed", that._dataChangedHandler);
                    dataSource.off("customizeStoreLoadOptions", that._dataLoadingHandler);
                    dataSource.off("customizeLoadResult", that._dataLoadedHandler);
                    dataSource.off("loadingChanged", that._loadingChangedHandler);
                    dataSource.off("loadError", that._loadErrorHandler);
                    if (!isSharedDataSource) {
                        dataSource.dispose()
                    }
                },
                refresh: function(options, isReload, operationTypes) {
                    var that = this,
                        dataSource = that._dataSource;
                    if (isReload || operationTypes.reload) {
                        that._currentTotalCount = 0;
                        that._isLastPage = !dataSource.paginate();
                        that._hasLastPage = that._isLastPage
                    }
                },
                _customizeRemoteOperations: function() {},
                _handleDataLoading: function(options) {
                    var loadOptions, operationTypes, that = this,
                        dataSource = that._dataSource,
                        lastLoadOptions = that._lastLoadOptions;
                    that.customizeStoreLoadOptions.fire(options);
                    options.delay = this.option("loadingTimeout");
                    options.originalStoreLoadOptions = options.storeLoadOptions;
                    options.remoteOperations = $.extend({}, this.remoteOperations());
                    var isReload = !that.isLoaded() && !that._isRefreshing;
                    loadOptions = $.extend({}, options.storeLoadOptions);
                    operationTypes = calculateOperationTypes(loadOptions, lastLoadOptions);
                    that._customizeRemoteOperations(options, isReload, operationTypes);
                    if (options.isCustomLoading) {
                        return
                    } else {
                        that._lastLoadOptions = loadOptions
                    }
                    that._isRefreshing = true;
                    $.when(that.refresh(options, isReload, operationTypes)).always(function() {
                        if (that._lastOperationId === options.operationId) {
                            that.load()
                        }
                        that._isRefreshing = false
                    });
                    dataSource.cancel(that._lastOperationId);
                    that._lastOperationId = options.operationId;
                    if (that._isRefreshing) {
                        dataSource.cancel(that._lastOperationId)
                    }
                },
                _handleDataLoaded: function(options) {
                    options.storeLoadOptions = options.originalStoreLoadOptions
                },
                _handleLoadingChanged: function(isLoading) {
                    this.loadingChanged.fire(isLoading)
                },
                _handleLoadError: function(error) {
                    this.changed.fire({
                        changeType: "loadError",
                        error: error
                    });
                    this.loadError.fire(error)
                },
                _handleDataChanged: function(args) {
                    var currentTotalCount, that = this,
                        dataSource = that._dataSource,
                        isLoading = false,
                        itemsCount = that.itemsCount();
                    that._isLastPage = !itemsCount || !that.pageSize() || itemsCount < that.pageSize();
                    if (that._isLastPage) {
                        that._hasLastPage = true
                    }
                    if (dataSource.totalCount() >= 0) {
                        if (dataSource.pageIndex() >= that.pageCount()) {
                            dataSource.pageIndex(that.pageCount() - 1);
                            dataSource.load();
                            isLoading = true
                        }
                    } else {
                        currentTotalCount = dataSource.pageIndex() * that.pageSize() + itemsCount;
                        that._currentTotalCount = Math.max(that._currentTotalCount, currentTotalCount);
                        if (0 === itemsCount && dataSource.pageIndex() >= that.pageCount()) {
                            dataSource.pageIndex(that.pageCount() - 1);
                            dataSource.load();
                            isLoading = true
                        }
                    }
                    if (!isLoading) {
                        this.component._optionCache = {};
                        this.changed.fire(args);
                        this.component._optionCache = void 0
                    }
                },
                isLastPage: function() {
                    return this._isLastPage
                },
                totalCount: function() {
                    return parseInt(this._currentTotalCount || this._dataSource.totalCount())
                },
                itemsCount: function() {
                    return this._dataSource.items().length
                },
                totalItemsCount: function() {
                    return this.totalCount()
                },
                pageSize: function() {
                    var dataSource = this._dataSource;
                    if (!arguments.length && !dataSource.paginate()) {
                        return 0
                    }
                    return dataSource.pageSize.apply(dataSource, arguments)
                },
                pageCount: function() {
                    var that = this,
                        count = that.totalItemsCount(),
                        pageSize = that.pageSize();
                    if (pageSize && count > 0) {
                        return Math.max(1, Math.ceil(count / pageSize))
                    }
                    return 1
                },
                hasKnownLastPage: function() {
                    return this._hasLastPage || this._dataSource.totalCount() >= 0
                },
                load: function(options) {
                    var store, loadResult, dataSourceLoadOptions, that = this,
                        dataSource = that._dataSource,
                        d = $.Deferred();
                    if (options) {
                        store = dataSource.store();
                        dataSourceLoadOptions = dataSource.loadOptions();
                        loadResult = {
                            storeLoadOptions: options,
                            isCustomLoading: true
                        };
                        $.each(store._customLoadOptions() || [], function(_, optionName) {
                            if (!(optionName in loadResult.storeLoadOptions)) {
                                loadResult.storeLoadOptions[optionName] = dataSourceLoadOptions[optionName]
                            }
                        });
                        dataSource._scheduleLoadCallbacks(d);
                        that._handleDataLoading(loadResult);
                        executeTask(function() {
                            $.when(loadResult.data || store.load(loadResult.storeLoadOptions)).done(function(data, extra) {
                                loadResult.data = data;
                                loadResult.extra = extra || {};
                                that._handleDataLoaded(loadResult);
                                if (options.requireTotalCount && void 0 === loadResult.extra.totalCount) {
                                    loadResult.extra.totalCount = store.totalCount(loadResult.storeLoadOptions)
                                }
                                $.when(loadResult.data, loadResult.extra.totalCount).done(function(data, totalCount) {
                                    loadResult.extra.totalCount = totalCount;
                                    d.resolve(data, loadResult.extra)
                                }).fail(d.reject)
                            }).fail(d.reject)
                        }, that.option("loadingTimeout"));
                        return d.fail(function() {
                            that.fireEvent("loadError", arguments)
                        }).promise()
                    } else {
                        return dataSource.load()
                    }
                }
            }
        }());
        DataSourceAdapter = DataSourceAdapter.inherit({
            reload: function(full) {
                return full ? this._dataSource.reload() : this._dataSource.load()
            },
            _customizeRemoteOperations: function(options, isReload, operationTypes) {
                var that = this,
                    cachedStoreData = that._cachedStoreData,
                    cachedPagingData = that._cachedPagingData;
                that.callBase.apply(that, arguments);
                if (isReload) {
                    cachedStoreData = void 0;
                    cachedPagingData = void 0
                } else {
                    if (operationTypes.reload) {
                        cachedPagingData = void 0
                    }
                    $.each(operationTypes, function(operationType, value) {
                        if (value && options.remoteOperations[operationType]) {
                            cachedStoreData = void 0;
                            cachedPagingData = void 0
                        }
                    })
                }
                if (cachedPagingData) {
                    options.remoteOperations.paging = false
                }
                options.cachedStoreData = cachedStoreData;
                options.cachedPagingData = cachedPagingData;
                if (!options.isCustomLoading) {
                    that._cachedStoreData = cachedStoreData;
                    that._cachedPagingData = cachedPagingData
                }
            },
            _handleDataLoading: function(options) {
                this.callBase(options);
                this._handleDataLoadingCore(options)
            },
            _handleDataLoadingCore: function(options) {
                var remoteOperations = options.remoteOperations;
                options.loadOptions = {};
                var localLoadOptionNames = {
                    filter: !remoteOperations.filtering,
                    sort: !remoteOperations.sorting,
                    group: !remoteOperations.grouping,
                    summary: !remoteOperations.summary,
                    skip: !remoteOperations.paging,
                    take: !remoteOperations.paging,
                    requireTotalCount: !remoteOperations.paging
                };
                $.each(options.storeLoadOptions, function(optionName, optionValue) {
                    if (localLoadOptionNames[optionName]) {
                        options.loadOptions[optionName] = optionValue;
                        delete options.storeLoadOptions[optionName]
                    }
                });
                options.data = options.cachedStoreData
            },
            _handleDataLoaded: function(options) {
                var callBase = this.callBase,
                    loadOptions = options.loadOptions,
                    localPaging = options.remoteOperations && !options.remoteOperations.paging,
                    isCaching = false !== this.option("cacheEnabled") && localPaging && options.storeLoadOptions,
                    needStoreCache = isCaching && !options.isCustomLoading;
                if (!loadOptions) {
                    this._dataSource.cancel(options.operationId);
                    return
                }
                if (localPaging) {
                    options.skip = loadOptions.skip;
                    options.take = loadOptions.take;
                    delete loadOptions.skip;
                    delete loadOptions.take
                }
                if (loadOptions.group) {
                    loadOptions.group = options.group || loadOptions.group
                }
                var groupCount = gridCore.normalizeSortingInfo(options.storeLoadOptions.group || loadOptions.group).length;
                if (isCaching && options.cachedPagingData) {
                    options.data = cloneItems(options.cachedPagingData, groupCount)
                } else {
                    if (needStoreCache && !this._cachedStoreData) {
                        this._cachedStoreData = cloneItems(options.data, gridCore.normalizeSortingInfo(options.storeLoadOptions.group).length)
                    }
                    new ArrayStore(options.data).load(loadOptions).done(function(data) {
                        options.data = data
                    });
                    if (needStoreCache) {
                        this._cachedPagingData = cloneItems(options.data, groupCount)
                    }
                }
                if (loadOptions.requireTotalCount && localPaging) {
                    options.extra = $.isPlainObject(options.extra) ? options.extra : {};
                    options.extra.totalCount = options.data.length
                }
                this._handleDataLoadedCore(options);
                callBase.apply(this, arguments)
            },
            _handleDataLoadedCore: function(options) {
                if (options.remoteOperations && !options.remoteOperations.paging) {
                    if (void 0 !== options.skip) {
                        options.data = options.data.slice(options.skip)
                    }
                    if (void 0 !== options.take) {
                        options.data = options.data.slice(0, options.take)
                    }
                }
            }
        });
        module.exports = {
            extend: function(extender) {
                DataSourceAdapter = DataSourceAdapter.inherit(extender)
            },
            create: function(component) {
                return new DataSourceAdapter(component)
            }
        }
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.sorting_module.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            sortingMixin = __webpack_require__( /*! ../grid_core/ui.grid_core.sorting */ 346).sortingMixin,
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        var COLUMN_HEADERS_VIEW_NAMESPACE = "dxDataGridColumnHeadersView";
        var ColumnHeadersViewSortingExtender = $.extend({}, sortingMixin, {
            _createRow: function(row) {
                var that = this,
                    $row = that.callBase(row);
                if ("header" === row.rowType) {
                    $row.on(eventUtils.addNamespace(clickEvent.name, COLUMN_HEADERS_VIEW_NAMESPACE), "> td", that.createAction(function(e) {
                        var keyName = null,
                            event = e.jQueryEvent,
                            $cellElement = $(event.currentTarget),
                            rowIndex = $cellElement.parent().index(),
                            columnIndex = $.map(that.getCellElements(rowIndex), function($tdElement, index) {
                                if ($tdElement === $cellElement.get(0)) {
                                    return index
                                }
                            })[0],
                            visibleColumns = that._columnsController.getVisibleColumns(rowIndex),
                            column = visibleColumns[columnIndex];
                        if (column && !commonUtils.isDefined(column.groupIndex) && !column.command) {
                            if (event.shiftKey) {
                                keyName = "shift"
                            } else {
                                if (event.ctrlKey) {
                                    keyName = "ctrl"
                                }
                            }
                            setTimeout(function() {
                                that._columnsController.changeSortOrder(column.index, keyName)
                            })
                        }
                    }))
                }
                return $row
            },
            _renderCellContent: function($cell, options) {
                var that = this,
                    column = options.column;
                that.callBase($cell, options);
                if (!column.command && "header" === options.rowType) {
                    that._applyColumnState({
                        name: "sort",
                        rootElement: $cell,
                        column: column,
                        showColumnLines: that.option("showColumnLines")
                    })
                }
            },
            _columnOptionChanged: function(e) {
                var changeTypes = e.changeTypes;
                if (1 === changeTypes.length && changeTypes.sorting) {
                    this._updateIndicators("sort");
                    return
                }
                this.callBase(e)
            },
            optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "sorting":
                        that._invalidate();
                        args.handled = true;
                        break;
                    default:
                        that.callBase(args)
                }
            }
        });
        var HeaderPanelSortingExtender = $.extend({}, sortingMixin, {
            _createGroupPanelItem: function($rootElement, groupColumn) {
                var that = this,
                    $item = that.callBase.apply(that, arguments);
                $item.on(eventUtils.addNamespace(clickEvent.name, "dxDataGridHeaderPanel"), that.createAction(function(e) {
                    setTimeout(function() {
                        that.getController("columns").changeSortOrder(groupColumn.index)
                    })
                }));
                that._applyColumnState({
                    name: "sort",
                    rootElement: $item,
                    column: {
                        alignment: that.option("rtlEnabled") ? "right" : "left",
                        allowSorting: groupColumn.allowSorting,
                        sortOrder: "desc" === groupColumn.sortOrder ? "desc" : "asc"
                    },
                    showColumnLines: true
                });
                return $item
            },
            optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "sorting":
                        that._invalidate();
                        args.handled = true;
                        break;
                    default:
                        that.callBase(args)
                }
            }
        });
        gridCore.registerModule("sorting", {
            defaultOptions: function() {
                return {
                    sorting: {
                        mode: "single",
                        ascendingText: messageLocalization.format("dxDataGrid-sortingAscendingText"),
                        descendingText: messageLocalization.format("dxDataGrid-sortingDescendingText"),
                        clearText: messageLocalization.format("dxDataGrid-sortingClearText")
                    }
                }
            },
            extenders: {
                views: {
                    columnHeadersView: ColumnHeadersViewSortingExtender,
                    headerPanel: HeaderPanelSortingExtender
                }
            }
        })
    },
    /*!******************************************************!*\
      !*** ./Scripts/ui/grid_core/ui.grid_core.sorting.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        var DATAGRID_SORT_CLASS = "dx-sort",
            DATAGRID_SORT_NONE_CLASS = "dx-sort-none",
            DATAGRID_SORTUP_CLASS = "dx-sort-up",
            DATAGRID_SORTDOWN_CLASS = "dx-sort-down",
            DATAGRID_HEADERS_ACTION_CLASS = "dx-datagrid-action",
            DATAGRID_COLUMN_INDICATORS_CLASS = "dx-column-indicators",
            DATAGRID_CELL_CONTENT_CLASS = "dx-datagrid-text-content";
        exports.sortingMixin = {
            _applyColumnState: function(options) {
                var side, ariaSortState, $sortIndicator, that = this,
                    sortingMode = that.option("sorting.mode"),
                    rootElement = options.rootElement,
                    column = options.column,
                    $indicatorsContainer = rootElement.find("." + DATAGRID_COLUMN_INDICATORS_CLASS);
                if ("sort" === options.name) {
                    side = that.option("rtlEnabled") ? "right" : "left", rootElement.find("." + DATAGRID_SORT_CLASS).remove();
                    !$indicatorsContainer.children().length && $indicatorsContainer.remove();
                    rootElement.children("." + DATAGRID_CELL_CONTENT_CLASS).css("margin-" + side, "");
                    if (("single" === sortingMode || "multiple" === sortingMode) && column.allowSorting || commonUtils.isDefined(column.sortOrder)) {
                        ariaSortState = "asc" === column.sortOrder ? "ascending" : "descending", $sortIndicator = that.callBase(options).toggleClass(DATAGRID_SORTUP_CLASS, "asc" === column.sortOrder).toggleClass(DATAGRID_SORTDOWN_CLASS, "desc" === column.sortOrder);
                        options.rootElement.addClass(DATAGRID_HEADERS_ACTION_CLASS);
                        if ("center" === column.alignment && !$sortIndicator.hasClass(DATAGRID_SORT_NONE_CLASS)) {
                            rootElement.children("." + DATAGRID_CELL_CONTENT_CLASS).css("margin-" + side, $sortIndicator.outerWidth(true))
                        }
                    }
                    if (!commonUtils.isDefined(column.sortOrder)) {
                        that.setAria("sort", "none", rootElement)
                    } else {
                        that.setAria("sort", ariaSortState, rootElement)
                    }
                    return $sortIndicator
                } else {
                    return that.callBase(options)
                }
            },
            _getIndicatorClassName: function(name) {
                if ("sort" === name) {
                    return DATAGRID_SORT_CLASS
                }
                return this.callBase(name)
            },
            _renderIndicator: function(options) {
                var rtlEnabled, column = options.column,
                    $container = options.container,
                    $indicator = options.indicator;
                if ("sort" === options.name) {
                    rtlEnabled = this.option("rtlEnabled");
                    if (!commonUtils.isDefined(column.sortOrder)) {
                        $indicator && $indicator.addClass(DATAGRID_SORT_NONE_CLASS)
                    }
                    if ($container.children().length && (!rtlEnabled && "left" === options.columnAlignment || rtlEnabled && "right" === options.columnAlignment)) {
                        $container.prepend($indicator);
                        return
                    }
                }
                this.callBase(options)
            },
            _updateIndicator: function($cell, column, indicatorName) {
                if ("sort" === indicatorName && commonUtils.isDefined(column.groupIndex)) {
                    return
                }
                this.callBase.apply(this, arguments)
            }
        }
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.rows_view.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            columnsView = __webpack_require__( /*! ./ui.data_grid.columns_view */ 340),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            Scrollable = __webpack_require__( /*! ../scroll_view/ui.scrollable */ 237).default,
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            isDefined = commonUtils.isDefined;
        var DATAGRID_GROUP_ROW_CLASS = "dx-group-row",
            DATAGRID_GROUP_CELL_CLASS = "dx-group-cell",
            DATAGRID_ROWS_VIEW_CLASS = "dx-datagrid-rowsview",
            DATAGRID_DATA_ROW_CLASS = "dx-data-row",
            DATAGRID_FREESPACE_CLASS = "dx-freespace-row",
            DATAGRID_CONTENT_CLASS = "dx-datagrid-content",
            DATAGRID_NOWRAP_CLASS = "dx-datagrid-nowrap",
            DATAGRID_ROW_LINES_CLASS = "dx-row-lines",
            DATAGRID_COLUMN_LINES_CLASS = "dx-column-lines",
            DATAGRID_ROW_ALTERNATION_CLASS = "dx-row-alt",
            DATAGRID_LAST_ROW_BORDER = "dx-last-row-border",
            DATAGRID_LOADPANEL_HIDE_TIMEOUT = 200,
            appendFreeSpaceRowTemplate = {
                render: function(options) {
                    var $tbody = options.container.find("tbody");
                    if ($tbody.length) {
                        $tbody.last().append(options.content)
                    } else {
                        options.container.append(options.content)
                    }
                }
            };
        exports.RowsView = columnsView.ColumnsView.inherit({
            _getDefaultTemplate: function(column) {
                switch (column.command) {
                    case "empty":
                        return function(container) {
                            container.html("&nbsp;")
                        };
                    default:
                        return function($container, options) {
                            var isDataTextEmpty = stringUtils.isEmpty(options.text) && "data" === options.rowType,
                                text = isDataTextEmpty ? "&nbsp;" : options.text,
                                container = $container.get(0);
                            if (column.encodeHtml && !isDataTextEmpty) {
                                container.textContent = text
                            } else {
                                container.innerHTML = text
                            }
                        }
                }
            },
            _getDefaultGroupTemplate: function() {
                var that = this,
                    summaryTexts = that.option("summary.texts");
                return function(container, options) {
                    var data = options.data,
                        text = options.column.caption + ": " + options.text;
                    if (options.summaryItems && options.summaryItems.length) {
                        text += " " + gridCore.getGroupRowSummaryText(options.summaryItems, summaryTexts)
                    }
                    if (data) {
                        if (options.groupContinuedMessage && options.groupContinuesMessage) {
                            text += " (" + options.groupContinuedMessage + ". " + options.groupContinuesMessage + ")"
                        } else {
                            if (options.groupContinuesMessage) {
                                text += " (" + options.groupContinuesMessage + ")"
                            } else {
                                if (options.groupContinuedMessage) {
                                    text += " (" + options.groupContinuedMessage + ")"
                                }
                            }
                        }
                    }
                    container.addClass(DATAGRID_GROUP_CELL_CLASS);
                    container.text(text)
                }
            },
            _update: function(change) {},
            _getCellTemplate: function(options) {
                var template, that = this,
                    column = options.column;
                if ("group" === options.rowType && isDefined(column.groupIndex) && !column.showWhenGrouped) {
                    template = column.groupCellTemplate || {
                        allowRenderToDetachedContainer: true,
                        render: that._getDefaultGroupTemplate()
                    }
                } else {
                    template = column.cellTemplate || {
                        allowRenderToDetachedContainer: true,
                        render: that._getDefaultTemplate(column)
                    }
                }
                return template
            },
            _createRow: function(row) {
                var isGroup, isDataRow, isRowExpanded, $row = this.callBase(row);
                if (row) {
                    isGroup = "group" === row.rowType;
                    isDataRow = "data" === row.rowType;
                    isDataRow && $row.addClass(DATAGRID_DATA_ROW_CLASS);
                    isDataRow && row.dataIndex % 2 === 1 && this.option("rowAlternationEnabled") && $row.addClass(DATAGRID_ROW_ALTERNATION_CLASS);
                    isDataRow && this.option("showRowLines") && $row.addClass(DATAGRID_ROW_LINES_CLASS);
                    this.option("showColumnLines") && $row.addClass(DATAGRID_COLUMN_LINES_CLASS);
                    if (isGroup) {
                        $row.addClass(DATAGRID_GROUP_ROW_CLASS);
                        isRowExpanded = row.isExpanded;
                        this.setAria("role", "rowgroup", $row);
                        this.setAria("expanded", isDefined(isRowExpanded) && isRowExpanded.toString(), $row)
                    }
                }
                return $row
            },
            _afterRowPrepared: function(e) {
                var arg = e.args[0],
                    dataController = this._dataController,
                    watch = this.option("watchMethod");
                if (!arg.data || "data" !== arg.rowType || arg.inserted || !this.option("twoWayBindingEnabled") || !watch) {
                    return
                }
                watch(function() {
                    return dataController.generateDataValues(arg.data, arg.columns)
                }, function() {
                    dataController.updateItems({
                        changeType: "update",
                        rowIndices: [arg.rowIndex]
                    })
                }, arg.rowElement.get(0))
            },
            _renderScrollable: function(force) {
                var that = this,
                    $element = that.element();
                if (!$element.children().length) {
                    $element.append("<div />")
                }
                if (force || !that._loadPanel) {
                    that._renderLoadPanel($element, $element.parent(), that._dataController.isLocalStore())
                }
                if ((force || !that.getScrollable()) && that._dataController.isLoaded()) {
                    var columns = that.getColumns(),
                        allColumnsHasWidth = true;
                    for (var i = 0; i < columns.length; i++) {
                        if (!columns[i].width) {
                            allColumnsHasWidth = false;
                            break
                        }
                    }
                    if (that.option("columnAutoWidth") || that._hasHeight || allColumnsHasWidth || that._columnsController._isColumnFixing()) {
                        that._renderScrollableCore($element)
                    }
                }
            },
            _handleScroll: function(e) {
                var that = this;
                that._scrollTop = e.scrollOffset.top;
                that._scrollLeft = e.scrollOffset.left;
                that.scrollChanged.fire(e.scrollOffset, that.name)
            },
            _renderScrollableCore: function($element) {
                var that = this,
                    dxScrollableOptions = that._createScrollableOptions(),
                    scrollHandler = $.proxy(that._handleScroll, that);
                dxScrollableOptions.onScroll = scrollHandler;
                dxScrollableOptions.onStop = scrollHandler;
                that._scrollable = that._createComponent($element, Scrollable, dxScrollableOptions);
                that._scrollableContainer = that._scrollable && that._scrollable._$container
            },
            _renderLoadPanel: gridCoreUtils.renderLoadPanel,
            _renderContent: function(contentElement, tableElement) {
                contentElement.replaceWith($("<div>").addClass(DATAGRID_CONTENT_CLASS).append(tableElement));
                return this._findContentElement()
            },
            _updateContent: function(newTableElement, change) {
                var that = this,
                    tableElement = that._getTableElement(),
                    contentElement = that._findContentElement(),
                    changeType = change && change.changeType,
                    executors = [];
                switch (changeType) {
                    case "update":
                        $.each(change.rowIndices, function(index, rowIndex) {
                            var $newRowElement = that._getRowElements(newTableElement).eq(index),
                                changeType = change.changeTypes[index],
                                item = change.items && change.items[index];
                            executors.push(function() {
                                var $rowsElement = that._getRowElements(),
                                    $rowElement = $rowsElement.eq(rowIndex);
                                switch (changeType) {
                                    case "update":
                                        if (item) {
                                            if (isDefined(item.visible) && item.visible !== $rowElement.is(":visible")) {
                                                $rowElement.toggle(item.visible)
                                            } else {
                                                $rowElement.replaceWith($newRowElement)
                                            }
                                        }
                                        break;
                                    case "insert":
                                        if (!$rowsElement.length) {
                                            $newRowElement.prependTo(tableElement)
                                        } else {
                                            if ($rowElement.length) {
                                                $newRowElement.insertBefore($rowElement)
                                            } else {
                                                $newRowElement.insertAfter($rowsElement.last())
                                            }
                                        }
                                        break;
                                    case "remove":
                                        $rowElement.remove()
                                }
                            })
                        });
                        $.each(executors, function() {
                            this()
                        });
                        newTableElement.remove();
                        break;
                    default:
                        that._setTableElement(newTableElement);
                        contentElement.addClass(DATAGRID_CONTENT_CLASS);
                        that._renderContent(contentElement, newTableElement)
                }
            },
            _renderFreeSpaceRow: function(tableElement) {
                var i, that = this,
                    freeSpaceRowElement = that._createRow(),
                    columns = this.getColumns();
                freeSpaceRowElement.addClass(DATAGRID_FREESPACE_CLASS).toggleClass(DATAGRID_COLUMN_LINES_CLASS, that.option("showColumnLines"));
                for (i = 0; i < columns.length; i++) {
                    freeSpaceRowElement.append(that._createCell({
                        column: columns[i],
                        rowType: "freeSpace"
                    }))
                }
                that._appendRow(tableElement, freeSpaceRowElement, appendFreeSpaceRowTemplate)
            },
            _needUpdateRowHeight: function(itemsCount) {
                return itemsCount > 0 && !this._rowHeight
            },
            _updateRowHeight: function() {
                var tableHeight, freeSpaceRowHeight, $freeSpaceRowElement, that = this,
                    tableElement = that._getTableElement(),
                    itemsCount = that._dataController.items().length;
                if (tableElement && that._needUpdateRowHeight(itemsCount)) {
                    tableHeight = tableElement.outerHeight();
                    $freeSpaceRowElement = that._getFreeSpaceRowElements().first();
                    if ($freeSpaceRowElement && $freeSpaceRowElement.is(":visible")) {
                        freeSpaceRowHeight = parseFloat($freeSpaceRowElement[0].style.height) || 0;
                        tableHeight -= freeSpaceRowHeight
                    }
                    that._rowHeight = tableHeight / itemsCount
                }
            },
            _findContentElement: function() {
                var $scrollableContent, $element = this.element();
                if ($element) {
                    $scrollableContent = $element.find("> .dx-scrollable-container > .dx-scrollable-content");
                    if (!$scrollableContent.length) {
                        $scrollableContent = $element
                    }
                    return $scrollableContent.children().first()
                }
            },
            _getRowElements: function(tableElement) {
                var $rows = this.callBase(tableElement);
                return $rows && $rows.not("." + DATAGRID_FREESPACE_CLASS)
            },
            _getFreeSpaceRowElements: function($table) {
                var tableElements = $table || this.getTableElements();
                return tableElements && tableElements.children("tbody").children("." + DATAGRID_FREESPACE_CLASS)
            },
            _getNoDataText: function() {
                return this.option("noDataText")
            },
            _renderNoDataText: gridCoreUtils.renderNoDataText,
            _rowClick: function(e) {
                var item = this._dataController.items()[e.rowIndex] || {};
                this.executeAction("onRowClick", $.extend({
                    evaluate: function(expr) {
                        var getter = compileGetter(expr);
                        return getter(item.data)
                    }
                }, e, item))
            },
            _getGroupCellOptions: function(options) {
                var columnIndex = (options.row.groupIndex || 0) + options.columnsCountBeforeGroups;
                return {
                    columnIndex: columnIndex,
                    colspan: options.columns.length - columnIndex - 1
                }
            },
            _renderCells: function($row, options) {
                if ("group" === options.row.rowType) {
                    this._renderGroupedCells($row, options)
                } else {
                    if (options.row.values) {
                        this.callBase($row, options)
                    }
                }
            },
            _renderGroupedCells: function($row, options) {
                var $groupCell, i, isExpanded, groupColumn, groupColumnAlignment, row = options.row,
                    columns = options.columns,
                    rowIndex = row.rowIndex,
                    groupCellOptions = this._getGroupCellOptions(options);
                for (i = 0; i <= groupCellOptions.columnIndex; i++) {
                    if (i === groupCellOptions.columnIndex && columns[i].allowCollapsing && "infinite" !== options.scrollingMode) {
                        isExpanded = !!row.isExpanded
                    } else {
                        isExpanded = null
                    }
                    this._renderCell($row, {
                        value: isExpanded,
                        row: row,
                        rowIndex: rowIndex,
                        column: {
                            command: "expand",
                            cssClass: columns[i].cssClass
                        },
                        columnIndex: i
                    })
                }
                groupColumnAlignment = commonUtils.getDefaultAlignment(this.option("rtlEnabled"));
                groupColumn = $.extend({}, columns[groupCellOptions.columnIndex], {
                    command: null,
                    cssClass: null,
                    showWhenGrouped: false,
                    alignment: groupColumnAlignment
                });
                if (groupCellOptions.colspan > 1) {
                    groupColumn.colspan = groupCellOptions.colspan
                }
                $groupCell = this._renderCell($row, {
                    value: row.values[row.groupIndex],
                    row: row,
                    rowIndex: rowIndex,
                    column: groupColumn,
                    columnIndex: groupCellOptions.columnIndex
                })
            },
            _renderRows: function($table, options) {
                var i, that = this,
                    columns = options.columns,
                    columnsCountBeforeGroups = 0,
                    scrollingMode = that.option("scrolling.mode");
                for (i = 0; i < columns.length; i++) {
                    if ("expand" === columns[i].command) {
                        columnsCountBeforeGroups = i;
                        break
                    }
                }
                that.callBase($table, $.extend({
                    scrollingMode: scrollingMode,
                    columnsCountBeforeGroups: columnsCountBeforeGroups
                }, options));
                that._renderFreeSpaceRow($table);
                if (!that._hasHeight) {
                    that.updateFreeSpaceRowHeight($table)
                }
            },
            _renderRow: function($table, options) {
                var that = this,
                    row = options.row,
                    rowTemplate = that.option("rowTemplate");
                if (("data" === row.rowType || "group" === row.rowType) && !isDefined(row.groupIndex) && rowTemplate) {
                    that.renderTemplate($table, rowTemplate, $.extend({
                        columns: options.columns
                    }, row))
                } else {
                    that.callBase($table, options)
                }
            },
            _renderTable: function(options) {
                var that = this,
                    $table = that.callBase(options),
                    triggerShownEvent = function() {
                        if (that.element().closest(document).length) {
                            that.resizeCompleted.remove(triggerShownEvent);
                            that.element().triggerHandler("dxshown")
                        }
                    };
                if (!isDefined(that._getTableElement())) {
                    that._setTableElement($table);
                    that._renderScrollable(true);
                    that.resizeCompleted.add(triggerShownEvent)
                } else {
                    that._renderScrollable()
                }
                return $table
            },
            _renderCore: function(change) {
                var $table, that = this,
                    $element = that.element();
                $element.addClass(DATAGRID_ROWS_VIEW_CLASS).toggleClass(DATAGRID_NOWRAP_CLASS, !that.option("wordWrapEnabled"));
                $table = that._renderTable({
                    change: change
                });
                that._updateContent($table, change);
                that.callBase(change);
                that._lastColumnWidths = null
            },
            _getRows: function(change) {
                return change && change.items || this._dataController.items()
            },
            _getCellOptions: function(options) {
                var parameters, groupingTextsOptions, scrollingMode, that = this,
                    column = options.column,
                    row = options.row,
                    data = row.data,
                    summaryCells = row && row.summaryCells,
                    value = options.value,
                    displayValue = gridCore.getDisplayValue(column, value, data, row.rowType);
                parameters = this.callBase(options);
                parameters.value = value;
                parameters.displayValue = displayValue;
                parameters.row = row;
                parameters.key = row.key;
                parameters.data = data;
                parameters.rowType = row.rowType;
                parameters.values = row.values;
                parameters.text = !column.command ? gridCore.formatValue(displayValue, column) : "";
                parameters.rowIndex = row.rowIndex;
                parameters.summaryItems = summaryCells && summaryCells[options.columnIndex];
                parameters.resized = column.resizedCallbacks;
                if (isDefined(column.groupIndex)) {
                    groupingTextsOptions = that.option("grouping.texts");
                    scrollingMode = that.option("scrolling.mode");
                    if ("virtual" !== scrollingMode && "infinite" !== scrollingMode) {
                        parameters.groupContinuesMessage = data && data.isContinuationOnNextPage && groupingTextsOptions && groupingTextsOptions.groupContinuesMessage;
                        parameters.groupContinuedMessage = data && data.isContinuation && groupingTextsOptions && groupingTextsOptions.groupContinuedMessage
                    }
                }
                return parameters
            },
            getCellOptions: function(rowIndex, columnIdentificator) {
                var cellOptions, column, rowOptions = this._dataController.items()[rowIndex];
                if (rowOptions) {
                    column = this._columnsController.columnOption(columnIdentificator);
                    if (column) {
                        cellOptions = this._getCellOptions({
                            value: column.calculateCellValue(rowOptions.data),
                            rowIndex: rowOptions.rowIndex,
                            row: rowOptions,
                            column: column
                        })
                    }
                }
                return cellOptions
            },
            getRow: function(index) {
                var rows = this._getRowElements();
                if (rows.length > index) {
                    return $(rows[index])
                }
            },
            getCellIndex: function($cell) {
                var cellIndex = $cell.length ? $cell[0].cellIndex : -1;
                return cellIndex
            },
            updateFreeSpaceRowHeight: function($table) {
                var elementHeight, freespaceRowCount, scrollingMode, resultHeight, that = this,
                    contentElement = that._findContentElement(),
                    freeSpaceRowElements = that._getFreeSpaceRowElements($table),
                    contentHeight = 0;
                if (freeSpaceRowElements && contentElement) {
                    var isFreespaceRowVisible = false;
                    if (that._dataController.items().length > 0) {
                        if (!that._hasHeight) {
                            freespaceRowCount = that._dataController.pageSize() - that._dataController.items().length;
                            scrollingMode = that.option("scrolling.mode");
                            if (freespaceRowCount > 0 && that._dataController.pageCount() > 1 && "virtual" !== scrollingMode && "infinite" !== scrollingMode) {
                                freeSpaceRowElements.height(freespaceRowCount * that._rowHeight);
                                isFreespaceRowVisible = true
                            }
                            if (!isFreespaceRowVisible && $table) {
                                freeSpaceRowElements.height(0)
                            } else {
                                freeSpaceRowElements.css("display", isFreespaceRowVisible ? "" : "none")
                            }
                            that._updateLastRowBorder(isFreespaceRowVisible)
                        } else {
                            freeSpaceRowElements.css("display", "none");
                            commonUtils.deferUpdate(function() {
                                elementHeight = that.element().height();
                                contentHeight = contentElement.outerHeight();
                                resultHeight = elementHeight - contentHeight - that.getScrollbarWidth(true);
                                if (resultHeight > 0) {
                                    commonUtils.deferRender(function() {
                                        freeSpaceRowElements.height(resultHeight);
                                        isFreespaceRowVisible = true;
                                        freeSpaceRowElements.css("display", "")
                                    })
                                }
                                commonUtils.deferRender(function() {
                                    that._updateLastRowBorder(isFreespaceRowVisible)
                                })
                            })
                        }
                    } else {
                        freeSpaceRowElements.height(0);
                        freeSpaceRowElements.css("display", "");
                        that._updateLastRowBorder(true)
                    }
                }
            },
            _columnOptionChanged: function(e) {
                var optionNames = e.optionNames;
                if (e.changeTypes.grouping) {
                    return
                }
                if (optionNames.width || optionNames.visibleWidth) {
                    this.callBase(e);
                    this._fireColumnResizedCallbacks()
                }
            },
            getScrollable: function() {
                return this._scrollable
            },
            init: function() {
                var that = this,
                    dataController = that.getController("data");
                that.callBase();
                that._editorFactoryController = that.getController("editorFactory");
                that._rowHeight = 0;
                that._scrollTop = 0;
                that._scrollLeft = 0;
                that._hasHeight = false;
                dataController.loadingChanged.add(function(isLoading, messageText) {
                    that.setLoading(isLoading, messageText)
                });
                dataController.dataSourceChanged.add(function() {
                    that._handleScroll({
                        scrollOffset: {
                            top: that._scrollTop,
                            left: that._scrollLeft
                        }
                    })
                })
            },
            _handleDataChanged: function(change) {
                var that = this;
                switch (change.changeType) {
                    case "refresh":
                    case "prepend":
                    case "append":
                    case "update":
                        that.render(null, change);
                        break;
                    default:
                        that._update(change)
                }
            },
            publicMethods: function() {
                return ["isScrollbarVisible", "getTopVisibleRowData", "getScrollbarWidth", "getCellElement"]
            },
            contentWidth: function() {
                return this.element().width() - this.getScrollbarWidth()
            },
            getScrollbarWidth: function(isHorizontal) {
                var scrollableContainer = this._scrollableContainer && this._scrollableContainer.get(0),
                    scrollbarWidth = 0;
                if (scrollableContainer) {
                    if (!isHorizontal) {
                        scrollbarWidth = scrollableContainer.clientWidth ? scrollableContainer.offsetWidth - scrollableContainer.clientWidth : 0
                    } else {
                        scrollbarWidth = scrollableContainer.clientHeight ? scrollableContainer.offsetHeight - scrollableContainer.clientHeight : 0
                    }
                }
                return scrollbarWidth > 0 ? scrollbarWidth : 0
            },
            _fireColumnResizedCallbacks: function() {
                var i, that = this,
                    lastColumnWidths = that._lastColumnWidths || [],
                    columnWidths = [],
                    columns = that.getColumns();
                for (i = 0; i < columns.length; i++) {
                    columnWidths[i] = columns[i].visibleWidth;
                    if (columns[i].resizedCallbacks && !isDefined(columns[i].groupIndex) && lastColumnWidths[i] !== columnWidths[i]) {
                        columns[i].resizedCallbacks.fire(columnWidths[i])
                    }
                }
                that._lastColumnWidths = columnWidths
            },
            _updateLastRowBorder: function(isFreespaceRowVisible) {
                if (this.option("showBorders") && this.option("showRowLines") && !isFreespaceRowVisible) {
                    this.element().addClass(DATAGRID_LAST_ROW_BORDER)
                } else {
                    this.element().removeClass(DATAGRID_LAST_ROW_BORDER)
                }
            },
            _updateScrollable: function() {
                var dxScrollable = Scrollable.getInstance(this.element());
                if (dxScrollable) {
                    dxScrollable.update();
                    this._updateHorizontalScrollPosition()
                }
            },
            _updateHorizontalScrollPosition: function() {
                var scrollable = this.getScrollable(),
                    scrollLeft = scrollable && scrollable.scrollOffset().left;
                if (0 === scrollLeft && scrollLeft !== this._scrollLeft) {
                    scrollable.scrollTo({
                        x: this._scrollLeft
                    })
                }
            },
            _resizeCore: function() {
                var that = this;
                that._fireColumnResizedCallbacks();
                that._updateRowHeight();
                commonUtils.deferRender(function() {
                    that._renderScrollable();
                    that._renderNoDataText();
                    that.updateFreeSpaceRowHeight()
                });
                that._updateScrollable();
                that.setLoading(that._dataController.isLoading())
            },
            scrollTo: function(location) {
                var $element = this.element(),
                    dxScrollable = $element && Scrollable.getInstance($element);
                if (dxScrollable) {
                    dxScrollable.scrollTo(location)
                }
            },
            height: function(height, hasHeight) {
                var that = this,
                    $element = this.element();
                if (isDefined(height)) {
                    that._hasHeight = void 0 === hasHeight ? "auto" !== height : hasHeight;
                    if ($element) {
                        $element.css("height", height)
                    }
                } else {
                    return $element ? $element.outerHeight(true) : 0
                }
            },
            setLoading: function(isLoading, messageText) {
                var visibilityOptions, that = this,
                    loadPanel = that._loadPanel,
                    dataController = that._dataController,
                    loadPanelOptions = that.option("loadPanel") || {},
                    animation = dataController.isLoaded() ? loadPanelOptions.animation : null,
                    $element = that.element();
                if (!loadPanel && void 0 !== messageText && dataController.isLocalStore() && "auto" === loadPanelOptions.enabled && $element) {
                    that._renderLoadPanel($element, $element.parent());
                    loadPanel = that._loadPanel
                }
                if (loadPanel) {
                    visibilityOptions = {
                        message: messageText || loadPanelOptions.text,
                        animation: animation,
                        visible: isLoading
                    };
                    clearTimeout(that._hideLoadingTimeoutID);
                    if (loadPanel.option("visible") && !isLoading) {
                        that._hideLoadingTimeoutID = setTimeout(function() {
                            loadPanel.option(visibilityOptions)
                        }, DATAGRID_LOADPANEL_HIDE_TIMEOUT)
                    } else {
                        loadPanel.option(visibilityOptions)
                    }
                }
            },
            isScrollbarVisible: function() {
                var $element = this.element();
                return $element ? this._findContentElement().outerHeight() - $element.height() > 0 : false
            },
            setRowsOpacity: function(columnIndex, value) {
                var i, that = this,
                    columnsController = that._columnsController,
                    visibleColumns = that.getColumns(),
                    columns = columnsController.getColumns(),
                    column = columns && columns[columnIndex],
                    columnID = column && column.isBand && column.index,
                    $rows = that._getRowElements().not("." + DATAGRID_GROUP_ROW_CLASS) || [];
                $.each($rows, function(rowIndex, row) {
                    if (!$(row).hasClass(DATAGRID_GROUP_ROW_CLASS)) {
                        for (i = 0; i < visibleColumns.length; i++) {
                            if (commonUtils.isNumber(columnID) && columnsController.isParentBandColumn(visibleColumns[i].index, columnID) || visibleColumns[i].index === columnIndex) {
                                that.getCellElements(rowIndex).eq(i).css({
                                    opacity: value
                                });
                                if (!commonUtils.isNumber(columnID)) {
                                    break
                                }
                            }
                        }
                    }
                })
            },
            getCellElements: function(rowIndex) {
                var groupCellIndex, $cells = this.callBase(rowIndex);
                if ($cells) {
                    groupCellIndex = $cells.filter("." + DATAGRID_GROUP_CELL_CLASS).index();
                    if (groupCellIndex >= 0 && $cells.length > groupCellIndex + 1) {
                        $cells.length = groupCellIndex + 1
                    }
                }
                return $cells
            },
            getTopVisibleItemIndex: function() {
                var rowElements, rowElement, that = this,
                    itemIndex = 0,
                    prevOffsetTop = 0,
                    offsetTop = 0,
                    scrollPosition = that._scrollTop,
                    contentElementOffsetTop = that._findContentElement().offset().top,
                    items = that._dataController.items(),
                    tableElement = that._getTableElement();
                if (items.length && tableElement) {
                    rowElements = tableElement.children("tbody").children(".dx-row:visible, .dx-error-row").not("." + DATAGRID_FREESPACE_CLASS);
                    for (itemIndex = 0; itemIndex < items.length; itemIndex++) {
                        prevOffsetTop = offsetTop;
                        rowElement = rowElements.eq(itemIndex);
                        if (rowElement.length) {
                            offsetTop = rowElement.offset().top - contentElementOffsetTop;
                            if (offsetTop > scrollPosition) {
                                if (2 * scrollPosition < offsetTop + prevOffsetTop && itemIndex) {
                                    itemIndex--
                                }
                                break
                            }
                        }
                    }
                    if (itemIndex && itemIndex === items.length) {
                        itemIndex--
                    }
                }
                return itemIndex
            },
            getTopVisibleRowData: function() {
                var itemIndex = this.getTopVisibleItemIndex(),
                    items = this._dataController.items();
                if (items[itemIndex]) {
                    return items[itemIndex].data
                }
            },
            optionChanged: function(args) {
                var that = this;
                that.callBase(args);
                switch (args.name) {
                    case "wordWrapEnabled":
                    case "showColumnLines":
                    case "showRowLines":
                    case "rowAlternationEnabled":
                    case "rowTemplate":
                    case "twoWayBindingEnabled":
                        that._invalidate(true, true);
                        args.handled = true;
                        break;
                    case "scrolling":
                        that._rowHeight = null;
                        that._tableElement = null;
                        args.handled = true;
                        break;
                    case "rtlEnabled":
                        that._rowHeight = null;
                        that._tableElement = null;
                        break;
                    case "loadPanel":
                        that._tableElement = null;
                        that._invalidate(true, true);
                        args.handled = true;
                        break;
                    case "noDataText":
                        that._renderNoDataText();
                        args.handled = true
                }
            },
            dispose: function() {
                clearTimeout(this._hideLoadingTimeoutID)
            },
            setScrollerSpacing: function() {}
        });
        gridCore.registerModule("rows", {
            defaultOptions: function() {
                return {
                    hoverStateEnabled: false,
                    loadPanel: {
                        enabled: "auto",
                        text: messageLocalization.format("Loading"),
                        width: 200,
                        height: 90,
                        showIndicator: true,
                        indicatorSrc: "",
                        showPane: true
                    },
                    rowTemplate: null,
                    columnAutoWidth: false,
                    noDataText: messageLocalization.format("dxDataGrid-noDataText"),
                    wordWrapEnabled: false,
                    showColumnLines: true,
                    showRowLines: false,
                    rowAlternationEnabled: false,
                    activeStateEnabled: false,
                    twoWayBindingEnabled: true
                }
            },
            views: {
                rowsView: exports.RowsView
            }
        })
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.context_menu_view.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            ContextMenu = __webpack_require__( /*! ../context_menu */ 327);
        var DATAGRID_CLASS = "dx-datagrid",
            DATAGRID_CONTEXT_MENU = "dx-context-menu",
            viewName = {
                columnHeadersView: "header",
                rowsView: "content",
                footerView: "footer",
                headerPanel: "headerPanel"
            },
            VIEW_NAMES = ["columnHeadersView", "rowsView", "footerView", "headerPanel"];
        exports.ContextMenuController = gridCore.ViewController.inherit({
            init: function() {
                this.createAction("onContextMenuPreparing")
            },
            getContextMenuItems: function(jQueryEvent) {
                if (!jQueryEvent) {
                    return false
                }
                var view, options, rowIndex, columnIndex, rowOptions, $element, $targetRowElement, $targetCellElement, menuItems, that = this,
                    $targetElement = $(jQueryEvent.target);
                $.each(VIEW_NAMES, function() {
                    view = that.getView(this);
                    $element = view && view.element();
                    if ($element && ($element.is($targetElement) || $element.find($targetElement).length)) {
                        $targetCellElement = $targetElement.closest("td");
                        $targetRowElement = $targetCellElement.closest(".dx-row");
                        rowIndex = view.getRowIndex($targetRowElement);
                        columnIndex = $targetCellElement[0] && $targetCellElement[0].cellIndex;
                        rowOptions = $targetRowElement.data("options");
                        options = {
                            jQueryEvent: jQueryEvent,
                            targetElement: $targetElement,
                            target: viewName[this],
                            rowIndex: rowIndex,
                            row: view._getRows()[rowIndex],
                            columnIndex: columnIndex,
                            column: rowOptions && rowOptions.cells[columnIndex].column
                        };
                        options.items = view.getContextMenuItems && view.getContextMenuItems(options);
                        that.executeAction("onContextMenuPreparing", options);
                        that._contextMenuPrepared(options);
                        menuItems = options.items;
                        if (menuItems) {
                            return false
                        }
                    }
                });
                return menuItems
            },
            _contextMenuPrepared: $.noop
        });
        exports.ContextMenuView = gridCore.View.inherit({
            _renderCore: function() {
                var that = this;
                this._createComponent(that.element().addClass(DATAGRID_CONTEXT_MENU), ContextMenu, {
                    onPositioning: function(actionArgs) {
                        var event = actionArgs.jQueryEvent,
                            contextMenuInstance = actionArgs.component,
                            items = that.getController("contextMenu").getContextMenuItems(event);
                        if (items) {
                            contextMenuInstance.option("items", items);
                            event.stopPropagation()
                        } else {
                            actionArgs.cancel = true
                        }
                    },
                    onItemClick: function(params) {
                        params.itemData.onItemClick && params.itemData.onItemClick(params)
                    },
                    cssClass: DATAGRID_CLASS,
                    target: that.component.element()
                })
            }
        });
        gridCore.registerModule("contextMenu", {
            defaultOptions: function() {
                return {
                    onContextMenuPreparing: null
                }
            },
            controllers: {
                contextMenu: exports.ContextMenuController
            },
            views: {
                contextMenuView: exports.ContextMenuView
            }
        })
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.error_handling.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337);
        var DATAGRID_ERROR_ROW_CLASS = "dx-error-row",
            DATAGRID_ERROR_MESSAGE_CLASS = "dx-error-message",
            DATAGRID_ERROR_CLOSEBUTTON_CLASS = "dx-closebutton",
            DATAGRID_ACTION_CLASS = "dx-datagrid-action";
        exports.ErrorHandlingController = gridCore.ViewController.inherit({
            init: function() {
                var that = this;
                that._columnHeadersView = that.getView("columnHeadersView");
                that._rowsView = that.getView("rowsView")
            },
            _createErrorRow: function(message, $tableElements) {
                var that = this,
                    $errorRow = $("<tr />").addClass(DATAGRID_ERROR_ROW_CLASS),
                    $errorMessage = $("<div/>").addClass(DATAGRID_ERROR_MESSAGE_CLASS).text(message),
                    $closeButton = $("<div/>").addClass(DATAGRID_ERROR_CLOSEBUTTON_CLASS).addClass(DATAGRID_ACTION_CLASS);
                $closeButton.on(clickEvent.name, that.createAction(function(args) {
                    var $errorRow, e = args.jQueryEvent,
                        errorRowIndex = $(e.currentTarget).closest("." + DATAGRID_ERROR_ROW_CLASS).index();
                    e.stopPropagation();
                    $.each($tableElements, function(_, tableElement) {
                        $errorRow = $(tableElement).find("tbody > tr").eq(errorRowIndex);
                        that.removeErrorRow($errorRow)
                    })
                }));
                $("<td/>").attr({
                    colspan: that.getController("columns").getVisibleColumns().length,
                    role: "presentation"
                }).prepend($closeButton).append($errorMessage).appendTo($errorRow);
                return $errorRow
            },
            renderErrorRow: function(message, rowIndex) {
                var $row, $errorRow, rowElements, that = this,
                    viewElement = rowIndex >= 0 ? that._rowsView : that._columnHeadersView,
                    $tableElements = viewElement.getTableElements();
                $.each($tableElements, function(_, tableElement) {
                    $errorRow = that._createErrorRow(message, $tableElements);
                    rowElements = $(tableElement).find("tr");
                    if (rowIndex >= 0) {
                        $row = viewElement._getRowElements($(tableElement)).eq(rowIndex);
                        that.removeErrorRow(rowElements.eq($row.index() + 1));
                        $errorRow.insertAfter($row)
                    } else {
                        that.removeErrorRow(rowElements.last());
                        $(tableElement).append($errorRow)
                    }
                })
            },
            removeErrorRow: function($row) {
                var $columnHeaders = this._columnHeadersView && this._columnHeadersView.element();
                $row = $row || $columnHeaders && $columnHeaders.find("." + DATAGRID_ERROR_ROW_CLASS);
                $row && $row.hasClass(DATAGRID_ERROR_ROW_CLASS) && $row.remove()
            },
            optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "errorRowEnabled":
                        args.handled = true;
                        break;
                    default:
                        that.callBase(args)
                }
            }
        });
        gridCore.registerModule("errorHandling", {
            defaultOptions: function() {
                return {
                    errorRowEnabled: true
                }
            },
            controllers: {
                errorHandling: exports.ErrorHandlingController
            },
            extenders: {
                controllers: {
                    data: {
                        init: function() {
                            var that = this,
                                errorHandlingController = that.getController("errorHandling");
                            that.callBase();
                            that.dataErrorOccurred.add(function(error) {
                                var message = error && error.message || error;
                                if (that.option("errorRowEnabled")) {
                                    errorHandlingController.renderErrorRow(message)
                                }
                            });
                            that.changed.add(function() {
                                var errorHandlingController = that.getController("errorHandling"),
                                    editingController = that.getController("editing");
                                if (editingController && !editingController.hasChanges()) {
                                    errorHandlingController && errorHandlingController.removeErrorRow()
                                }
                            })
                        }
                    }
                }
            }
        })
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.grid_view.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var DATAGRID_CLASS = "dx-datagrid",
            DATAGRID_HIDDEN_CLASS = "dx-hidden",
            DATAGRID_TABLE_CLASS = "dx-datagrid-table",
            DATAGRID_BORDERS_CLASS = "dx-datagrid-borders",
            DATAGRID_TABLE_FIXED_CLASS = "dx-datagrid-table-fixed",
            DATAGRID_IMPORTANT_MARGIN_CLASS = "dx-datagrid-important-margin",
            DATAGRID_HIDDEN_COLUMNS_WIDTH = "adaptiveHidden",
            EMPTY_GRID_ROWS_HEIGHT = 100,
            LOADPANEL_MARGIN = 50,
            VIEW_NAMES = ["columnsSeparatorView", "blockSeparatorView", "trackerView", "headerPanel", "columnHeadersView", "rowsView", "footerView", "columnChooserView", "pagerView", "draggingHeaderView", "contextMenuView", "errorView", "headerFilterView"];
        var isPercentWidth = function(width) {
            return commonUtils.isString(width) && "%" === width.slice(-1)
        };
        var mergeArraysByMaxValue = function(values1, values2) {
            var i, result = [];
            if (values1 && values2 && values1.length && values1.length === values2.length) {
                for (i = 0; i < values1.length; i++) {
                    result.push(values1[i] > values2[i] ? values1[i] : values2[i])
                }
            } else {
                if (values1 && values1.length) {
                    result = values1
                } else {
                    if (values2) {
                        result = values2
                    }
                }
            }
            return result
        };
        exports.ResizingController = gridCore.ViewController.inherit({
            _initPostRenderHandlers: function() {
                var that = this;
                if (!that._refreshSizesHandler) {
                    that._refreshSizesHandler = function(e) {
                        that._dataController.changed.remove(that._refreshSizesHandler);
                        var resizeDeferred, changeType = e && e.changeType;
                        if (!e || "refresh" === changeType || "prepend" === changeType || "append" === changeType) {
                            resizeDeferred = that.resize()
                        } else {
                            if ("update" === changeType) {
                                if (that._dataController.items().length > 1 || "insert" !== e.changeTypes[0]) {
                                    that._rowsView.resize()
                                } else {
                                    resizeDeferred = that.resize()
                                }
                            }
                        }
                        if (changeType && "updateSelection" !== changeType) {
                            $.when(resizeDeferred).done(function() {
                                that.component._fireContentReadyAction()
                            })
                        }
                    };
                    that._dataController.changed.add(function() {
                        that._dataController.changed.add(that._refreshSizesHandler)
                    })
                }
            },
            _getBestFitWidths: function() {
                var rowsColumnWidths, headerColumnWidths, footerColumnWidths, resultWidths, that = this;
                rowsColumnWidths = that._rowsView.getColumnWidths();
                headerColumnWidths = that._columnHeadersView && that._columnHeadersView.getColumnWidths();
                footerColumnWidths = that._footerView && that._footerView.getColumnWidths();
                resultWidths = mergeArraysByMaxValue(rowsColumnWidths, headerColumnWidths);
                resultWidths = mergeArraysByMaxValue(resultWidths, footerColumnWidths);
                return resultWidths
            },
            _setVisibleWidths: function(visibleColumns, widths) {
                var columnsController = this._columnsController;
                columnsController.beginUpdate();
                $.each(visibleColumns, function(index, column) {
                    var columnId = column.command ? "command:" + column.command : column.index;
                    columnsController.columnOption(columnId, "visibleWidth", widths[index])
                });
                columnsController.endUpdate()
            },
            _toggleBestFitMode: function(isBestFit) {
                var $element = this.component.element();
                $element.find("." + DATAGRID_TABLE_CLASS).toggleClass(DATAGRID_TABLE_FIXED_CLASS, !isBestFit);
                $element.find("input").toggleClass(DATAGRID_HIDDEN_CLASS, isBestFit);
                $element.find(".dx-group-cell").toggleClass(DATAGRID_HIDDEN_CLASS, isBestFit);
                $element.find(".dx-header-row .dx-datagrid-text-content").css("max-width", "")
            },
            _synchronizeColumns: function() {
                var resetBestFitMode, that = this,
                    columnsController = that._columnsController,
                    visibleColumns = columnsController.getVisibleColumns(),
                    columnAutoWidth = that.option("columnAutoWidth"),
                    needBestFit = columnAutoWidth,
                    isLastWidthReset = false,
                    resultWidths = [],
                    normalizeWidthsByExpandColumns = function() {
                        var expandColumnWidth;
                        $.each(visibleColumns, function(index, column) {
                            if ("expand" === column.command) {
                                expandColumnWidth = resultWidths[index]
                            }
                        });
                        $.each(visibleColumns, function(index, column) {
                            if ("expand" === column.command && expandColumnWidth) {
                                resultWidths[index] = expandColumnWidth
                            }
                        })
                    };
                !needBestFit && $.each(visibleColumns, function(index, column) {
                    if ("auto" === column.width) {
                        needBestFit = true;
                        return false
                    }
                });
                that._setVisibleWidths(visibleColumns, []);
                if (that._isNeedToCalcBestFitWidths(needBestFit)) {
                    that._toggleBestFitMode(true);
                    resetBestFitMode = true
                }
                commonUtils.deferUpdate(function() {
                    if (that._isNeedToCalcBestFitWidths(needBestFit)) {
                        resultWidths = that._getBestFitWidths();
                        $.each(visibleColumns, function(index, column) {
                            var columnId = column.command ? "command:" + column.command : column.index;
                            columnsController.columnOption(columnId, "bestFitWidth", resultWidths[index], true)
                        })
                    }
                    $.each(visibleColumns, function(index) {
                        if ("auto" !== this.width) {
                            if (this.width) {
                                resultWidths[index] = this.width
                            } else {
                                if (!columnAutoWidth) {
                                    resultWidths[index] = void 0
                                }
                            }
                        }
                    });
                    isLastWidthReset = that._correctColumnWidths(resultWidths, visibleColumns);
                    if (columnAutoWidth) {
                        normalizeWidthsByExpandColumns();
                        that._processStretch(resultWidths, visibleColumns)
                    }
                    commonUtils.deferRender(function() {
                        if (resetBestFitMode) {
                            that._toggleBestFitMode(false);
                            resetBestFitMode = false
                        }
                        if (needBestFit || isLastWidthReset) {
                            that._setVisibleWidths(visibleColumns, resultWidths)
                        }
                    })
                })
            },
            _isNeedToCalcBestFitWidths: function(needBestFit) {
                return needBestFit
            },
            _correctColumnWidths: function(resultWidths, visibleColumns) {
                var lastColumnIndex, that = this,
                    hasPercentWidth = false,
                    hasAutoWidth = false,
                    isLastWidthReset = false,
                    $element = that.component.element(),
                    hasWidth = that._hasWidth;
                $.each(visibleColumns, function(index) {
                    if ("auto" !== this.width) {
                        if (this.width) {
                            if (resultWidths[index] !== DATAGRID_HIDDEN_COLUMNS_WIDTH) {
                                resultWidths[index] = this.width
                            }
                        } else {
                            hasAutoWidth = true
                        }
                    }
                    if (isPercentWidth(this.width)) {
                        hasPercentWidth = true
                    }
                });
                if ($element && that._maxWidth) {
                    delete that._maxWidth;
                    $element.css("max-width", "")
                }
                if (!hasAutoWidth && resultWidths.length) {
                    var contentWidth = that._rowsView.contentWidth(),
                        totalWidth = that._getTotalWidth(resultWidths, contentWidth);
                    if (totalWidth <= contentWidth) {
                        lastColumnIndex = resultWidths.length - 1;
                        while (lastColumnIndex >= 0 && visibleColumns[lastColumnIndex] && (visibleColumns[lastColumnIndex].command || resultWidths[lastColumnIndex] === DATAGRID_HIDDEN_COLUMNS_WIDTH)) {
                            lastColumnIndex--
                        }
                        if (lastColumnIndex >= 0) {
                            resultWidths[lastColumnIndex] = "auto";
                            isLastWidthReset = true;
                            if (!hasWidth && !hasPercentWidth) {
                                that._maxWidth = that.option("showBorders") ? totalWidth + 2 : totalWidth;
                                $element.css("max-width", that._maxWidth)
                            }
                        }
                    }
                }
                return isLastWidthReset
            },
            _processStretch: function(resultSizes, visibleColumns) {
                var diff, diffElement, onePixelElementsCount, i, groupSize = this._rowsView.contentWidth(),
                    tableSize = this._getTotalWidth(resultSizes, groupSize),
                    unusedIndexes = {
                        length: 0
                    };
                if (!resultSizes.length) {
                    return
                }
                $.each(visibleColumns, function(index) {
                    if (this.width || resultSizes[index] === DATAGRID_HIDDEN_COLUMNS_WIDTH) {
                        unusedIndexes[index] = true;
                        unusedIndexes.length++
                    }
                });
                diff = groupSize - tableSize;
                diffElement = Math.floor(diff / (resultSizes.length - unusedIndexes.length));
                onePixelElementsCount = diff - diffElement * (resultSizes.length - unusedIndexes.length);
                if (diff >= 0) {
                    for (i = 0; i < resultSizes.length; i++) {
                        if (unusedIndexes[i]) {
                            continue
                        }
                        resultSizes[i] += diffElement;
                        if (onePixelElementsCount) {
                            resultSizes[i]++;
                            onePixelElementsCount--
                        }
                    }
                }
            },
            _getTotalWidth: function(widths, groupWidth) {
                var width, i, result = 0;
                for (i = 0; i < widths.length; i++) {
                    width = widths[i];
                    if (width && width !== DATAGRID_HIDDEN_COLUMNS_WIDTH) {
                        result += isPercentWidth(width) ? parseInt(width) * groupWidth / 100 : parseInt(width)
                    }
                }
                return Math.round(result)
            },
            updateSize: function($rootElement) {
                var $groupElement, width, that = this;
                if (void 0 === that._hasHeight && $rootElement && $rootElement.is(":visible")) {
                    $groupElement = $rootElement.children("." + DATAGRID_CLASS);
                    if ($groupElement.length) {
                        $groupElement.detach()
                    }
                    that._hasHeight = !!$rootElement.height();
                    width = $rootElement.width();
                    $rootElement.addClass(DATAGRID_IMPORTANT_MARGIN_CLASS);
                    that._hasWidth = $rootElement.width() === width;
                    $rootElement.removeClass(DATAGRID_IMPORTANT_MARGIN_CLASS);
                    if ($groupElement.length) {
                        $groupElement.appendTo($rootElement)
                    }
                }
            },
            publicMethods: function() {
                return ["resize", "updateDimensions"]
            },
            resize: function() {
                return !this.component._requireResize && this.updateDimensions()
            },
            updateDimensions: function(checkSize) {
                var that = this;
                that._initPostRenderHandlers();
                if (!that._checkSize(checkSize)) {
                    return
                }
                return commonUtils.deferRender(function() {
                    if (that._dataController.isLoaded()) {
                        that._synchronizeColumns();
                        that._rowsView.height("auto")
                    }
                    commonUtils.deferUpdate(function() {
                        that._updateDimensionsCore()
                    })
                })
            },
            _checkSize: function(checkSize) {
                var $rootElement = this.component.element();
                if (checkSize && (this._lastWidth === $rootElement.width() && this._lastHeight === $rootElement.height() || !$rootElement.is(":visible"))) {
                    return false
                }
                return true
            },
            _updateDimensionsCore: function() {
                var rowsViewHeight, $testDiv, that = this,
                    dataController = that._dataController,
                    rowsView = that._rowsView,
                    columnHeadersView = that._columnHeadersView,
                    footerView = that._footerView,
                    $rootElement = that.component.element(),
                    rootElementHeight = $rootElement && ($rootElement.get(0).clientHeight || $rootElement.height()),
                    maxHeight = parseFloat($rootElement.css("maxHeight")),
                    maxHeightHappened = maxHeight && rootElementHeight >= maxHeight,
                    loadPanelOptions = that.option("loadPanel"),
                    height = that.option("height") || $rootElement.get(0).style.height,
                    editorFactory = that.getController("editorFactory");
                that.updateSize($rootElement);
                if (height && that._hasHeight ^ "auto" !== height) {
                    $testDiv = $("<div>").height(height).appendTo($rootElement);
                    that._hasHeight = !!$testDiv.height();
                    $testDiv.remove()
                }
                if (that.option("scrolling") && (that._hasHeight && rootElementHeight > 0 || maxHeightHappened)) {
                    rowsViewHeight = rootElementHeight;
                    $.each(that.getViews(), function() {
                        if (this.isVisible() && this.getHeight) {
                            rowsViewHeight -= this.getHeight()
                        }
                    })
                } else {
                    if (!that._hasHeight && 0 === dataController.items().length) {
                        rowsViewHeight = loadPanelOptions && loadPanelOptions.enabled ? loadPanelOptions.height + LOADPANEL_MARGIN : EMPTY_GRID_ROWS_HEIGHT
                    } else {
                        rowsViewHeight = "auto"
                    }
                }
                commonUtils.deferRender(function() {
                    rowsView.height(rowsViewHeight, that._hasHeight);
                    if (!dataController.isLoaded()) {
                        rowsView.setLoading(true);
                        return
                    }
                    commonUtils.deferUpdate(function() {
                        that._updateLastSizes($rootElement);
                        var vScrollbarWidth = rowsView.getScrollbarWidth();
                        var hScrollbarWidth = rowsView.getScrollbarWidth(true);
                        commonUtils.deferRender(function() {
                            columnHeadersView && columnHeadersView.setScrollerSpacing(vScrollbarWidth);
                            footerView && footerView.setScrollerSpacing(vScrollbarWidth);
                            rowsView.setScrollerSpacing(vScrollbarWidth, hScrollbarWidth)
                        });
                        $.each(VIEW_NAMES, function(index, viewName) {
                            var view = that.getView(viewName);
                            if (view) {
                                view.resize()
                            }
                        });
                        editorFactory && editorFactory.resize()
                    })
                })
            },
            _updateLastSizes: function($rootElement) {
                this._lastWidth = $rootElement.width();
                this._lastHeight = $rootElement.height()
            },
            optionChanged: function(args) {
                switch (args.name) {
                    case "width":
                    case "height":
                        this.component._renderDimensions();
                        this.resize();
                    default:
                        this.callBase(args)
                }
            },
            init: function() {
                var that = this;
                that._dataController = that.getController("data");
                that._columnsController = that.getController("columns");
                that._columnHeadersView = that.getView("columnHeadersView");
                that._footerView = that.getView("footerView");
                that._rowsView = that.getView("rowsView")
            }
        });
        exports.SynchronizeScrollingController = gridCore.ViewController.inherit({
            _scrollChangedHandler: function(views, pos, viewName) {
                for (var j = 0; j < views.length; j++) {
                    if (views[j].name !== viewName) {
                        views[j].scrollTo({
                            left: pos.left,
                            top: pos.top
                        })
                    }
                }
            },
            init: function() {
                var view, i, views = [this.getView("columnHeadersView"), this.getView("footerView"), this.getView("rowsView")];
                for (i = 0; i < views.length; i++) {
                    view = views[i];
                    if (view) {
                        view.scrollChanged.add($.proxy(this._scrollChangedHandler, this, views))
                    }
                }
            }
        });
        exports.GridView = gridCore.View.inherit({
            _endUpdateCore: function() {
                if (this.component._requireResize) {
                    this.component._requireResize = false;
                    this._resizingController.resize()
                }
            },
            init: function() {
                var that = this;
                that._resizingController = this.getController("resizing");
                that._dataController = that.getController("data")
            },
            getView: function(name) {
                return this.component._views[name]
            },
            element: function() {
                return this._groupElement
            },
            optionChanged: function(args) {
                var that = this;
                if (commonUtils.isDefined(that._groupElement) && "showBorders" === args.name) {
                    that._groupElement.toggleClass(DATAGRID_BORDERS_CLASS, !!args.value);
                    args.handled = true
                } else {
                    that.callBase(args)
                }
            },
            render: function($rootElement) {
                var that = this,
                    groupElement = that._groupElement || $("<div />").addClass(DATAGRID_CLASS).toggleClass(DATAGRID_BORDERS_CLASS, !!that.option("showBorders"));
                that.component.setAria({
                    role: "application",
                    label: messageLocalization.format("dxDataGrid-ariaDataGrid")
                }, $rootElement);
                that._rootElement = $rootElement || that._rootElement;
                that._groupElement = groupElement;
                $.each(VIEW_NAMES, function(index, viewName) {
                    var view = that.getView(viewName);
                    if (view) {
                        view.render(groupElement)
                    }
                });
                that.update()
            },
            update: function() {
                var that = this,
                    $rootElement = that._rootElement,
                    $groupElement = that._groupElement,
                    columnHeadersView = that.getView("columnHeadersView"),
                    resizingController = that.getController("resizing");
                if ($rootElement && $groupElement) {
                    if (!$groupElement.parent().length) {
                        resizingController.updateSize($rootElement);
                        $groupElement.appendTo($rootElement);
                        columnHeadersView && columnHeadersView.renderDelayedTemplates();
                        that.getView("rowsView").renderDelayedTemplates()
                    }
                    resizingController.resize();
                    if (that._dataController.isLoaded()) {
                        that.component._fireContentReadyAction()
                    }
                }
            }
        });
        gridCore.registerModule("gridView", {
            defaultOptions: function() {
                return {
                    showBorders: false
                }
            },
            controllers: {
                resizing: exports.ResizingController,
                synchronizeScrolling: exports.SynchronizeScrollingController
            },
            views: {
                gridView: exports.GridView
            }
        })
    },
    /*!***********************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.header_panel.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            Toolbar = __webpack_require__( /*! ../toolbar */ 312),
            columnsView = __webpack_require__( /*! ./ui.data_grid.columns_view */ 340),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        __webpack_require__( /*! ../drop_down_menu */ 272);
        var DATAGRID_HEADER_PANEL_CLASS = "dx-datagrid-header-panel",
            DATAGRID_TOOLBAR_BUTTON_CLASS = "dx-datagrid-toolbar-button";
        exports.HeaderPanel = columnsView.ColumnsView.inherit({
            _resizeCore: $.noop,
            _invalidateToolbarItems: function() {
                var toolbarItems = this._getToolbarItems(),
                    toolbarInstance = this._toolbar;
                if (toolbarInstance) {
                    toolbarInstance.option("items", toolbarItems)
                }
            },
            _renderCore: function() {
                var toolbarInstance = this._toolbar;
                if (!toolbarInstance) {
                    var toolbarItems = this._getToolbarItems();
                    this.element().addClass(DATAGRID_HEADER_PANEL_CLASS);
                    this._toolbar = this._createComponent($("<div />").appendTo(this.element()), Toolbar, {
                        items: toolbarItems
                    })
                }
            },
            updateToolbarItemOption: function(name, optionName, optionValue) {
                var toolbarInstance = this._toolbar;
                if (toolbarInstance) {
                    var items = toolbarInstance.option("items");
                    if (items && items.length) {
                        var itemIndex;
                        $.each(items, function(index, item) {
                            if (item.name === name) {
                                itemIndex = index;
                                return false
                            }
                        });
                        if (void 0 !== itemIndex) {
                            if (commonUtils.isObject(optionName)) {
                                toolbarInstance.option("items[" + itemIndex + "]", optionName)
                            } else {
                                toolbarInstance.option("items[" + itemIndex + "]." + optionName, optionValue);
                                if ("disabled" === optionName) {
                                    var widgetOptions = toolbarInstance.option("items[" + itemIndex + "].options") || {};
                                    widgetOptions.disabled = optionValue;
                                    toolbarInstance.option("items[" + itemIndex + "].options", widgetOptions)
                                }
                            }
                        }
                    }
                }
            },
            getToolbarItemOption: function(name, optionName) {
                var toolbarInstance = this._toolbar;
                if (toolbarInstance) {
                    var items = toolbarInstance.option("items");
                    if (items && items.length) {
                        var optionValue;
                        $.each(items, function(index, item) {
                            if (item.name === name) {
                                optionValue = item[optionName];
                                return false
                            }
                        });
                        return optionValue
                    }
                }
            },
            _getToolbarItems: function() {
                return []
            },
            _getButtonContainer: function() {
                return $("<div />").addClass(DATAGRID_TOOLBAR_BUTTON_CLASS)
            },
            _getToolbarButtonClass: function(specificClass) {
                var secondClass = specificClass ? " " + specificClass : "";
                return DATAGRID_TOOLBAR_BUTTON_CLASS + secondClass
            },
            getHeaderPanel: function() {
                return this.element()
            },
            getHeight: function() {
                var $element = this.element();
                return $element ? $element.outerHeight(true) : 0
            },
            isVisible: function() {
                return false
            }
        });
        gridCore.registerModule("headerPanel", {
            defaultOptions: function() {
                return {}
            },
            views: {
                headerPanel: exports.HeaderPanel
            }
        })
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.state_storing.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            stateStoringCore = __webpack_require__( /*! ../grid_core/ui.grid_core.state_storing */ 353),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341);
        var processLoadState = function(that) {
            var columnsController = that.getController("columns"),
                selectionController = that.getController("selection"),
                exportController = that.getController("export"),
                dataController = that.getController("data"),
                pagerView = that.getView("pagerView");
            if (columnsController) {
                columnsController.columnsChanged.add(function() {
                    var columnsState = columnsController.getUserState(),
                        columnsStateHash = gridCore.getKeyHash(columnsState),
                        currentColumnsStateHash = gridCore.getKeyHash(that._state.columns);
                    if (!gridCoreUtils.equalKeys(currentColumnsStateHash, columnsStateHash)) {
                        $.extend(that._state, {
                            columns: columnsState
                        });
                        that.isEnabled() && that.save()
                    }
                })
            }
            if (selectionController) {
                selectionController.selectionChanged.add(function(keys) {
                    $.extend(that._state, {
                        selectedRowKeys: keys
                    });
                    that.isEnabled() && that.save()
                })
            }
            if (dataController) {
                that._initialPageSize = that.option("paging.pageSize");
                dataController.changed.add(function() {
                    $.extend(that._state, {
                        searchText: that.option("searchPanel.text"),
                        pageIndex: dataController.pageIndex(),
                        pageSize: dataController.pageSize(),
                        allowedPageSizes: pagerView ? pagerView.getPageSizes() : void 0
                    });
                    that.isEnabled() && that.save()
                })
            }
            if (exportController) {
                exportController.selectionOnlyChanged.add(function() {
                    $.extend(that._state, {
                        exportSelectionOnly: exportController.selectionOnly()
                    });
                    that.isEnabled() && that.save()
                })
            }
        };
        var applyState = function(that, state) {
            var allowedPageSizes = state.allowedPageSizes,
                searchText = state.searchText,
                selectedRowKeys = state.selectedRowKeys,
                exportController = that.getController("export"),
                columnsController = that.getController("columns"),
                scrollingMode = that.option("scrolling.mode");
            that.component.beginUpdate();
            if (columnsController) {
                columnsController.setUserState(state.columns)
            }
            if (exportController) {
                exportController.selectionOnly(state.exportSelectionOnly)
            }
            that.option("selectedRowKeys", selectedRowKeys || []);
            if (allowedPageSizes && "auto" === that.option("pager.allowedPageSizes")) {
                that.option("pager").allowedPageSizes = allowedPageSizes
            }
            that.option("searchPanel.text", searchText || "");
            that.option("paging.pageSize", "virtual" !== scrollingMode && "infinite" !== scrollingMode && state.pageSize ? state.pageSize : that._initialPageSize);
            that.option("paging.pageIndex", state.pageIndex || 0);
            that.component.endUpdate()
        };
        gridCore.registerModule("stateStoring", {
            defaultOptions: function() {
                return {
                    stateStoring: {
                        enabled: false,
                        storageKey: null,
                        type: "localStorage",
                        customLoad: null,
                        customSave: null,
                        savingTimeout: 2e3
                    }
                }
            },
            controllers: {
                stateStoring: stateStoringCore.StateStoringController
            },
            extenders: {
                controllers: {
                    stateStoring: {
                        init: function() {
                            this.callBase.apply(this, arguments);
                            processLoadState(this)
                        },
                        state: function(state) {
                            var result = this.callBase.apply(this, arguments);
                            if (void 0 !== state) {
                                applyState(this, $.extend({}, state))
                            }
                            return result
                        }
                    },
                    columns: {
                        getVisibleColumns: function() {
                            var visibleColumns = this.callBase.apply(this, arguments),
                                stateStoringController = this.getController("stateStoring");
                            return stateStoringController.isEnabled() && !stateStoringController.isLoaded() ? [] : visibleColumns
                        }
                    },
                    data: {
                        _refreshDataSource: function() {
                            var that = this,
                                callBase = that.callBase,
                                stateStoringController = that.getController("stateStoring");
                            if (stateStoringController.isEnabled() && !stateStoringController.isLoaded()) {
                                clearTimeout(that._restoreStateTimeoutID);
                                that._restoreStateTimeoutID = setTimeout(function() {
                                    stateStoringController.load().always(function() {
                                        that._restoreStateTimeoutID = null;
                                        callBase.call(that)
                                    })
                                })
                            } else {
                                if (!that._restoreStateTimeoutID) {
                                    callBase.call(that)
                                }
                            }
                        },
                        isLoading: function() {
                            var that = this,
                                stateStoringController = that.getController("stateStoring");
                            return this.callBase() || stateStoringController.isLoading()
                        },
                        isLoaded: function() {
                            return this.callBase() && !this._restoreStateTimeoutID
                        },
                        dispose: function() {
                            clearTimeout(this._restoreStateTimeoutID);
                            this.callBase()
                        }
                    }
                }
            }
        })
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/grid_core/ui.grid_core.state_storing.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            modules = __webpack_require__( /*! ./ui.grid_core.modules */ 338),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            sessionStorage = __webpack_require__( /*! ../../core/utils/storage */ 41).sessionStorage,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        var DATE_REGEX = /^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}(?:\.\d*)?)Z$/;
        var parseDates = function(state) {
            if (!state) {
                return
            }
            $.each(state, function(key, value) {
                var date;
                if ($.isPlainObject(value) || $.isArray(value)) {
                    parseDates(value)
                } else {
                    if ("string" === typeof value) {
                        date = DATE_REGEX.exec(value);
                        if (date) {
                            state[key] = new Date(Date.UTC(+date[1], +date[2] - 1, +date[3], +date[4], +date[5], +date[6]))
                        }
                    }
                }
            })
        };
        exports.StateStoringController = modules.ViewController.inherit(function() {
            var getStorage = function(options) {
                var storage = "sessionStorage" === options.type ? sessionStorage() : localStorage;
                if (!storage) {
                    if ("file:" === window.location.protocol && browser.msie) {
                        throw new Error("E1038")
                    } else {
                        throw new Error("E1007")
                    }
                }
                return storage
            };
            var getUniqueStorageKey = function(options) {
                return commonUtils.isDefined(options.storageKey) ? options.storageKey : "storage"
            };
            return {
                _loadState: function() {
                    var options = this.option("stateStoring");
                    if ("custom" === options.type) {
                        return options.customLoad && options.customLoad()
                    }
                    try {
                        return JSON.parse(getStorage(options).getItem(getUniqueStorageKey(options)))
                    } catch (e) {
                        errors.log(e.message)
                    }
                },
                _saveState: function(state) {
                    var options = this.option("stateStoring");
                    if ("custom" === options.type) {
                        options.customSave && options.customSave(state);
                        return
                    }
                    try {
                        getStorage(options).setItem(getUniqueStorageKey(options), JSON.stringify(state))
                    } catch (e) {}
                },
                publicMethods: function() {
                    return ["state"]
                },
                isEnabled: function() {
                    return this.option("stateStoring.enabled")
                },
                init: function() {
                    var that = this;
                    that._state = {};
                    that._isLoaded = false;
                    that._isLoading = false;
                    that._windowUnloadHandler = function() {
                        if (void 0 !== that._savingTimeoutID) {
                            that._saveState(that.state())
                        }
                    }, $(window).on("unload", that._windowUnloadHandler);
                    return that
                },
                isLoaded: function() {
                    return this._isLoaded
                },
                isLoading: function() {
                    return this._isLoading
                },
                load: function() {
                    var loadResult, that = this;
                    that._isLoading = true;
                    loadResult = that._loadState();
                    if (!loadResult || !$.isFunction(loadResult.done)) {
                        loadResult = $.Deferred().resolve(loadResult)
                    }
                    loadResult.done(function(state) {
                        that._isLoaded = true;
                        that._isLoading = false;
                        that.state(state)
                    });
                    return loadResult
                },
                state: function(state) {
                    var that = this;
                    if (!arguments.length) {
                        return $.extend(true, {}, that._state)
                    } else {
                        that._state = $.extend({}, state);
                        parseDates(that._state)
                    }
                },
                save: function() {
                    var that = this;
                    clearTimeout(that._savingTimeoutID);
                    that._savingTimeoutID = setTimeout(function() {
                        that._saveState(that.state());
                        that._savingTimeoutID = void 0
                    }, that.option("stateStoring.savingTimeout"))
                },
                optionChanged: function(args) {
                    var that = this;
                    switch (args.name) {
                        case "stateStoring":
                            if (that.isEnabled() && that.isLoaded()) {
                                that.load()
                            }
                            args.handled = true;
                            break;
                        default:
                            that.callBase(args)
                    }
                },
                dispose: function() {
                    clearTimeout(this._savingTimeoutID);
                    $(window).off("unload", this._windowUnloadHandler)
                }
            }
        }())
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.selection.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            equalKeys = gridCoreUtils.equalKeys,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            holdEvent = __webpack_require__( /*! ../../events/hold */ 164),
            dataQuery = __webpack_require__( /*! ../../data/query */ 158),
            ArrayStore = __webpack_require__( /*! ../../data/array_store */ 162),
            getKeyHash = gridCore.getKeyHash;
        var DATAGRID_EDITOR_CELL_CLASS = "dx-editor-cell",
            DATAGRID_ROW_CLASS = "dx-row",
            DATAGRID_ROW_SELECTION_CLASS = "dx-selection",
            DATAGRID_SELECT_CHECKBOX_CLASS = "dx-select-checkbox",
            DATAGRID_CHECKBOXES_HIDDEN_CLASS = "dx-select-checkboxes-hidden",
            DATAGRID_COMMAND_SELECT_CLASS = "dx-command-select",
            DATAGRID_SELECTION_DISABLED_CLASS = "dx-selection-disabled",
            DATAGRID_DATA_ROW_CLASS = "dx-data-row";
        var SHOW_CHECKBOXES_MODE = "selection.showCheckBoxesMode",
            SELECTION_MODE = "selection.mode";
        var isSelectable = function(selectionMode) {
            return "single" === selectionMode || "multiple" === selectionMode
        };
        var processLongTap = function(that, jQueryEvent) {
            var selectionController = that.getController("selection"),
                rowsView = that.getView("rowsView"),
                $row = $(jQueryEvent.target).closest("." + DATAGRID_DATA_ROW_CLASS),
                rowIndex = rowsView.getRowIndex($row);
            if (rowIndex < 0) {
                return
            }
            if ("onLongTap" === that.option(SHOW_CHECKBOXES_MODE)) {
                if (selectionController.isSelectionWithCheckboxes()) {
                    selectionController.stopSelectionWithCheckboxes()
                } else {
                    selectionController.startSelectionWithCheckboxes()
                }
            } else {
                if ("onClick" === that.option(SHOW_CHECKBOXES_MODE)) {
                    selectionController.startSelectionWithCheckboxes()
                }
                selectionController.changeItemSelection(rowIndex, {
                    control: true
                })
            }
        };
        exports.SelectionController = gridCore.Controller.inherit(function() {
            var indexOfSelectedItemKey = function(that, key, isSelectAll) {
                var index, indices, selectedItemKeys = isSelectAll ? that._unselectedItemKeys : that._selectedItemKeys;
                if (commonUtils.isObject(key)) {
                    for (index = 0; index < selectedItemKeys.length; index++) {
                        if (equalKeys(selectedItemKeys[index], key)) {
                            return index
                        }
                    }
                    return -1
                } else {
                    indices = that._selectedItemKeyHashIndices[key];
                    return indices && indices[0] >= 0 ? indices[0] : -1
                }
            };
            var addSelectedItem = function(that, itemData) {
                var key = that.getController("data").keyOf(itemData),
                    keyHash = getKeyHash(key);
                if (indexOfSelectedItemKey(that, keyHash) === -1) {
                    if (!commonUtils.isObject(keyHash)) {
                        that._selectedItemKeyHashIndices[keyHash] = [that._selectedItemKeys.length]
                    }
                    that._selectedItemKeys.push(key);
                    that._addedItemKeys.push(key);
                    that._selectedItems.push(itemData)
                }
            };
            var removeSelectedItem = function(that, key) {
                var currentKeyIndex, currentKeyIndices, keyIndices, i, keyHash = getKeyHash(key),
                    keyIndex = indexOfSelectedItemKey(that, keyHash);
                if (keyIndex >= 0) {
                    that._selectedItemKeys.splice(keyIndex, 1);
                    that._removedItemKeys.push(key);
                    that._selectedItems.splice(keyIndex, 1);
                    if (!commonUtils.isObject(keyHash)) {
                        keyIndices = that._selectedItemKeyHashIndices[keyHash];
                        if (keyIndices) {
                            keyIndices.shift();
                            if (!keyIndices.length) {
                                delete that._selectedItemKeyHashIndices[keyHash]
                            }
                            for (currentKeyIndex = keyIndex; currentKeyIndex < that._selectedItemKeys.length; currentKeyIndex++) {
                                currentKeyIndices = that._selectedItemKeyHashIndices[getKeyHash(that._selectedItemKeys[currentKeyIndex])];
                                if (currentKeyIndices) {
                                    for (i = 0; i < currentKeyIndices.length; i++) {
                                        if (currentKeyIndices[i] > keyIndex) {
                                            currentKeyIndices[i]--
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            };
            var clearSelectedItems = function(that) {
                setSelectedItems(that, [], [])
            };
            var setSelectedItems = function(that, keys, items) {
                var i, keyHash, keyIndices, oldSelectedItemKeys = that._selectedItemKeys;
                that._selectedItemKeys = keys;
                that._selectedItemKeyHashIndices = {};
                that._selectedItems = items;
                that._unselectedItemKeys = [];
                for (i = 0; i < oldSelectedItemKeys.length; i++) {
                    if ($.inArray(oldSelectedItemKeys[i], keys) === -1) {
                        that._removedItemKeys.push(oldSelectedItemKeys[i])
                    }
                }
                for (i = 0; i < keys.length; i++) {
                    keyHash = getKeyHash(keys[i]);
                    if (!commonUtils.isObject(keyHash)) {
                        keyIndices = that._selectedItemKeyHashIndices[keyHash] = that._selectedItemKeyHashIndices[keyHash] || [];
                        keyIndices.push(i)
                    }
                    if ($.inArray(keys[i], oldSelectedItemKeys) === -1) {
                        that._addedItemKeys.push(keys[i])
                    }
                }
            };
            var resetItemSelectionWhenShiftKeyPressed = function(that) {
                delete that._shiftFocusedItemIndex
            };
            var isDataItem = function(row) {
                return row && "data" === row.rowType && !row.inserted
            };
            var changeItemSelectionWhenShiftKeyPressed = function(that, itemIndex, items) {
                var itemIndexStep, index, isSelectedItemsChanged = false,
                    dataController = that.getController("data"),
                    isFocusedItemSelected = items[that._focusedItemIndex] && that.isRowSelected(dataController.keyOf(items[that._focusedItemIndex].data));
                var addRemoveSelectedItem = function(that, data, isRemove) {
                    if (isRemove) {
                        removeSelectedItem(that, dataController.keyOf(data))
                    } else {
                        addSelectedItem(that, data)
                    }
                };
                if (!commonUtils.isDefined(that._shiftFocusedItemIndex)) {
                    that._shiftFocusedItemIndex = that._focusedItemIndex
                }
                if (that._shiftFocusedItemIndex !== that._focusedItemIndex) {
                    itemIndexStep = that._focusedItemIndex < that._shiftFocusedItemIndex ? 1 : -1;
                    for (index = that._focusedItemIndex; index !== that._shiftFocusedItemIndex; index += itemIndexStep) {
                        if (isDataItem(items[index])) {
                            addRemoveSelectedItem(that, items[index].data, true);
                            isSelectedItemsChanged = true
                        }
                    }
                }
                if (itemIndex !== that._shiftFocusedItemIndex) {
                    itemIndexStep = itemIndex < that._shiftFocusedItemIndex ? 1 : -1;
                    for (index = itemIndex; index !== that._shiftFocusedItemIndex; index += itemIndexStep) {
                        if (isDataItem(items[index])) {
                            addRemoveSelectedItem(that, items[index].data, false);
                            isSelectedItemsChanged = true
                        }
                    }
                }
                if (isDataItem(items[that._focusedItemIndex]) && !isFocusedItemSelected) {
                    addRemoveSelectedItem(that, items[that._focusedItemIndex].data, false);
                    isSelectedItemsChanged = true
                }
                return isSelectedItemsChanged
            };
            var createSelectedItemsFilterCriteria = function(dataSource, selectedItemKeys, isSelectAll) {
                var keyCriteria, i, key = dataSource && dataSource.key(),
                    criteria = [];
                if (dataSource) {
                    if (key) {
                        $.each(selectedItemKeys, function(index, keyValue) {
                            if (criteria.length > 0) {
                                criteria.push(isSelectAll ? "and" : "or")
                            }
                            if ($.isArray(key)) {
                                keyCriteria = [];
                                for (i = 0; i < key.length; i++) {
                                    if (i > 0) {
                                        keyCriteria.push(isSelectAll ? "or" : "and")
                                    }
                                    keyCriteria.push([key[i], isSelectAll ? "<>" : "=", keyValue[key[i]]])
                                }
                                criteria.push(keyCriteria)
                            } else {
                                criteria.push([key, isSelectAll ? "<>" : "=", keyValue])
                            }
                        })
                    } else {
                        criteria = function(item) {
                            var i;
                            for (i = 0; i < selectedItemKeys.length; i++) {
                                if (equalKeys(selectedItemKeys[i], item)) {
                                    return !isSelectAll
                                }
                            }
                            return isSelectAll
                        }
                    }
                }
                if (criteria.length > 0 || $.isFunction(criteria)) {
                    return criteria
                }
            };
            var updateSelectedItems = function(that) {
                var addedItemKeys, removedItemKeys, changedItemIndexes = [],
                    dataController = that.getController("data"),
                    isSelectionWithCheckboxes = that.isSelectionWithCheckboxes();
                if (dataController) {
                    $.each(dataController.items(), function(index, row) {
                        if (isDataItem(row) && row.isSelected !== that.isRowSelected(row.key)) {
                            changedItemIndexes.push(index)
                        }
                    });
                    if ("onClick" === that.option(SHOW_CHECKBOXES_MODE)) {
                        if (that._selectedItemKeys.length > 1) {
                            that.startSelectionWithCheckboxes()
                        } else {
                            if (0 === that._selectedItemKeys.length && that._removedItemKeys.length) {
                                that.stopSelectionWithCheckboxes()
                            }
                        }
                    }
                    if (changedItemIndexes.length || isSelectionWithCheckboxes !== that.isSelectionWithCheckboxes()) {
                        dataController.updateItems({
                            changeType: "updateSelection",
                            itemIndexes: changedItemIndexes
                        })
                    }
                    addedItemKeys = that._addedItemKeys;
                    removedItemKeys = that._removedItemKeys;
                    if (addedItemKeys.length || removedItemKeys.length) {
                        that._selectedItemsInternalChange = true;
                        that.option("selectedRowKeys", that._selectedItemKeys.slice(0));
                        that._selectedItemsInternalChange = false;
                        that.selectionChanged.fire(that._selectedItemKeys);
                        that._addedItemKeys = [];
                        that._removedItemKeys = [];
                        that.executeAction("onSelectionChanged", {
                            selectedRowsData: that._selectedItems,
                            selectedRowKeys: that._selectedItemKeys,
                            currentSelectedRowKeys: addedItemKeys,
                            currentDeselectedRowKeys: removedItemKeys
                        })
                    }
                }
            };
            var updateSelectColumn = function(that) {
                var columnsController = that.getController("columns"),
                    isSelectColumnVisible = that.isSelectColumnVisible();
                columnsController.addCommandColumn({
                    command: "select",
                    visible: isSelectColumnVisible,
                    visibleIndex: -1,
                    dataType: "boolean",
                    alignment: "center",
                    cssClass: DATAGRID_COMMAND_SELECT_CLASS,
                    width: "auto"
                });
                columnsController.columnOption("command:select", "visible", isSelectColumnVisible)
            };
            return {
                init: function() {
                    var that = this;
                    that._isSelectionWithCheckboxes = false;
                    that._focusedItemIndex = -1;
                    that._selectedItemKeys = [];
                    that._selectedItemKeyHashIndices = {};
                    that._unselectedItemKeys = [];
                    that._selectedItems = [];
                    that._addedItemKeys = [];
                    that._removedItemKeys = [];
                    updateSelectColumn(that);
                    that.createAction("onSelectionChanged", {
                        excludeValidators: ["disabled", "readOnly"]
                    })
                },
                callbackNames: function() {
                    return ["selectionChanged"]
                },
                optionChanged: function(args) {
                    var that = this;
                    that.callBase(args);
                    switch (args.name) {
                        case "selection":
                            that.init();
                            that.getController("columns").updateColumns();
                            args.handled = true;
                            break;
                        case "selectedRowKeys":
                            if (commonUtils.isArray(args.value) && !that._selectedItemsInternalChange) {
                                that.selectRows(args.value)
                            }
                            args.handled = true
                    }
                },
                publicMethods: function() {
                    return ["selectRows", "deselectRows", "selectRowsByIndexes", "getSelectedRowKeys", "getSelectedRowsData", "clearSelection", "selectAll", "deselectAll", "startSelectionWithCheckboxes", "stopSelectionWithCheckboxes", "isRowSelected"]
                },
                isRowSelected: function(key) {
                    var keyHash = getKeyHash(key),
                        index = indexOfSelectedItemKey(this, keyHash);
                    return index !== -1
                },
                isSelectColumnVisible: function() {
                    var showCheckBoxesMode = this.option(SHOW_CHECKBOXES_MODE);
                    return "multiple" === this.option(SELECTION_MODE) && ("always" === showCheckBoxesMode || "onClick" === showCheckBoxesMode || this._isSelectionWithCheckboxes)
                },
                isSelectAll: function() {
                    var i, dataController = this.getController("data"),
                        items = dataController.items(),
                        combinedFilter = dataController.getCombinedFilter(),
                        selectedItems = this.getSelectedRowsData();
                    if (combinedFilter) {
                        dataQuery(selectedItems).filter(combinedFilter).enumerate().done(function(items) {
                            selectedItems = items
                        })
                    }
                    if (!selectedItems.length) {
                        for (i = 0; i < items.length; i++) {
                            if (items[i].selected) {
                                return
                            }
                        }
                        return false
                    } else {
                        if (selectedItems.length >= dataController.totalCount()) {
                            return true
                        }
                    }
                },
                selectAll: function() {
                    if ("onClick" === this.option(SHOW_CHECKBOXES_MODE)) {
                        this.startSelectionWithCheckboxes()
                    }
                    return this.selectedItemKeys([], true, false, true)
                },
                deselectAll: function() {
                    return this.selectedItemKeys([], true, true, true)
                },
                clearSelection: function() {
                    return this.selectedItemKeys([])
                },
                refresh: function() {
                    return this.selectedItemKeys(this.option("selectedRowKeys") || [])
                },
                selectedItemKeys: function(value, preserve, isDeselect, isSelectAll) {
                    var keys, criteria, isFunctionCriteria, deferred, dataSourceFilter, filter, loadOptions, that = this,
                        dataController = that.getController("data"),
                        dataSource = dataController.dataSource(),
                        store = dataSource && dataSource.store(),
                        deselectItems = [];
                    if (commonUtils.isDefined(value)) {
                        if (store) {
                            keys = $.isArray(value) ? $.extend([], value) : [value];
                            if (keys.length || isSelectAll) {
                                criteria = createSelectedItemsFilterCriteria(dataSource, keys, isSelectAll);
                                isFunctionCriteria = $.isFunction(criteria);
                                if (isSelectAll) {
                                    dataSourceFilter = dataController.getCombinedFilter();
                                    if (isDeselect && !dataSourceFilter) {
                                        return that.clearSelection()
                                    }
                                }
                                if (criteria || isSelectAll) {
                                    if (criteria && !isFunctionCriteria && dataSourceFilter) {
                                        filter = [];
                                        filter.push(criteria);
                                        filter.push(dataSourceFilter)
                                    } else {
                                        if (dataSourceFilter) {
                                            filter = dataSourceFilter
                                        } else {
                                            if (criteria && !isFunctionCriteria) {
                                                filter = criteria
                                            }
                                        }
                                    }
                                    deferred = $.Deferred();
                                    if (isDeselect) {
                                        new ArrayStore(that._selectedItems).load({
                                            filter: filter
                                        }).done(function(items) {
                                            deselectItems = items
                                        })
                                    }
                                    loadOptions = {
                                        filter: filter,
                                        select: dataSource.select()
                                    };
                                    new ArrayStore(deselectItems.length ? deselectItems : dataSource.items()).load({
                                        filter: criteria
                                    }).done(function(items) {
                                        if (!isSelectAll && (deselectItems.length || items.length === keys.length)) {
                                            deferred.resolve(items)
                                        } else {
                                            dataSource.load(loadOptions).done(function(items) {
                                                new ArrayStore(items).load({
                                                    filter: criteria
                                                }).done(deferred.resolve)
                                            }).fail($.proxy(deferred.reject, deferred))
                                        }
                                    })
                                }
                            }
                        }
                        deferred = deferred || $.Deferred().resolve([]);
                        deferred.done(function(items) {
                            var i, key, item, keys = [];
                            if (store && items.length > 0) {
                                for (i = 0; i < items.length; i++) {
                                    item = items[i];
                                    key = store.keyOf(item);
                                    if (preserve) {
                                        if (isDeselect) {
                                            removeSelectedItem(that, key)
                                        } else {
                                            addSelectedItem(that, item)
                                        }
                                    } else {
                                        keys.push(key)
                                    }
                                }
                            }
                            if (!preserve) {
                                setSelectedItems(that, keys, items)
                            }
                            updateSelectedItems(that)
                        });
                        return deferred
                    } else {
                        return that._selectedItemKeys
                    }
                },
                getSelectedRowKeys: function() {
                    return this.selectedItemKeys()
                },
                selectRows: function(keys, preserve) {
                    return this.selectedItemKeys(keys, preserve)
                },
                deselectRows: function(keys) {
                    return this.selectedItemKeys(keys, true, true)
                },
                selectRowsByIndexes: function(indexes) {
                    var items = this.getController("data").items(),
                        keys = [];
                    if (!commonUtils.isArray(indexes)) {
                        indexes = Array.prototype.slice.call(arguments, 0)
                    }
                    $.each(indexes, function() {
                        var item = items[this];
                        if (item && "data" === item.rowType) {
                            keys.push(item.key)
                        }
                    });
                    return this.selectRows(keys)
                },
                getSelectedRowsData: function() {
                    return this._selectedItems
                },
                changeItemSelection: function(itemIndex, keys) {
                    var isSelectedItemsChanged, isSelected, itemKey, that = this,
                        dataController = that.getController("data"),
                        items = dataController.items(),
                        item = items[itemIndex],
                        itemData = item && (item.oldData || item.data),
                        selectionMode = that.option(SELECTION_MODE);
                    if (isSelectable(selectionMode) && isDataItem(item)) {
                        itemKey = dataController.keyOf(itemData);
                        keys = keys || {};
                        if (that.isSelectionWithCheckboxes()) {
                            keys.control = true
                        }
                        if (keys.shift && "multiple" === selectionMode && that._focusedItemIndex >= 0) {
                            isSelectedItemsChanged = changeItemSelectionWhenShiftKeyPressed(that, itemIndex, items)
                        } else {
                            if (keys.control) {
                                resetItemSelectionWhenShiftKeyPressed(that);
                                isSelected = that.isRowSelected(itemKey);
                                if ("single" === selectionMode) {
                                    clearSelectedItems(that)
                                }
                                if (isSelected) {
                                    removeSelectedItem(that, itemKey)
                                } else {
                                    addSelectedItem(that, itemData)
                                }
                                isSelectedItemsChanged = true
                            } else {
                                resetItemSelectionWhenShiftKeyPressed(that);
                                if (1 !== that._selectedItemKeys.length || !equalKeys(that._selectedItemKeys[0], itemKey)) {
                                    setSelectedItems(that, [itemKey], [itemData]);
                                    isSelectedItemsChanged = true
                                }
                            }
                        }
                        if (isSelectedItemsChanged) {
                            that._focusedItemIndex = itemIndex;
                            updateSelectedItems(that);
                            return true
                        }
                    }
                    return false
                },
                focusedItemIndex: function(itemIndex) {
                    var that = this;
                    if (commonUtils.isDefined(itemIndex)) {
                        that._focusedItemIndex = itemIndex
                    } else {
                        return that._focusedItemIndex
                    }
                },
                isSelectionWithCheckboxes: function() {
                    var selectionMode = this.option(SELECTION_MODE),
                        showCheckBoxesMode = this.option(SHOW_CHECKBOXES_MODE);
                    return "multiple" === selectionMode && ("always" === showCheckBoxesMode || this._isSelectionWithCheckboxes)
                },
                startSelectionWithCheckboxes: function() {
                    var that = this,
                        isSelectColumnVisible = that.isSelectColumnVisible();
                    if ("multiple" === that.option(SELECTION_MODE) && !that.isSelectionWithCheckboxes()) {
                        that._isSelectionWithCheckboxes = true;
                        updateSelectColumn(that);
                        if (isSelectColumnVisible === that.isSelectColumnVisible() && "onClick" === that.option(SHOW_CHECKBOXES_MODE)) {
                            updateSelectedItems(that)
                        }
                        return true
                    }
                    return false
                },
                stopSelectionWithCheckboxes: function() {
                    var that = this;
                    if (that._isSelectionWithCheckboxes) {
                        that._isSelectionWithCheckboxes = false;
                        updateSelectColumn(that);
                        return true
                    }
                    return false
                }
            }
        }());
        gridCore.registerModule("selection", {
            defaultOptions: function() {
                return {
                    selection: {
                        mode: "none",
                        showCheckBoxesMode: "onClick",
                        allowSelectAll: true
                    },
                    selectedRowKeys: []
                }
            },
            controllers: {
                selection: exports.SelectionController
            },
            extenders: {
                controllers: {
                    data: {
                        setDataSource: function(dataSource) {
                            this.callBase(dataSource);
                            if (dataSource) {
                                this.getController("selection").refresh()
                            }
                        },
                        pageIndex: function(value) {
                            var that = this,
                                dataSource = that._dataSource;
                            if (dataSource && value && dataSource.pageIndex() !== value) {
                                that.getController("selection").focusedItemIndex(-1)
                            }
                            return that.callBase(value)
                        },
                        _processDataItem: function(item, options) {
                            var that = this,
                                selectionController = that.getController("selection"),
                                hasSelectColumn = selectionController.isSelectColumnVisible(),
                                dataItem = this.callBase.apply(this, arguments);
                            dataItem.isSelected = selectionController.isRowSelected(dataItem.key);
                            if (hasSelectColumn && dataItem.values) {
                                for (var i = 0; i < options.visibleColumns.length; i++) {
                                    if ("select" === options.visibleColumns[i].command) {
                                        dataItem.values[i] = dataItem.isSelected;
                                        break
                                    }
                                }
                            }
                            return dataItem
                        },
                        refresh: function() {
                            var that = this,
                                d = $.Deferred();
                            this.callBase.apply(this, arguments).done(function() {
                                that.getController("selection").refresh().done(d.resolve).fail(d.reject)
                            }).fail(d.reject);
                            return d.promise()
                        }
                    },
                    contextMenu: {
                        _contextMenuPrepared: function(options) {
                            var jQueryEvent = options.jQueryEvent;
                            if (jQueryEvent.originalEvent && "dxhold" !== jQueryEvent.originalEvent.type || options.items && options.items.length > 0) {
                                return
                            }
                            processLongTap(this, jQueryEvent)
                        }
                    }
                },
                views: {
                    columnHeadersView: {
                        init: function() {
                            var that = this;
                            that.callBase();
                            that.getController("selection").selectionChanged.add($.proxy(that._updateSelectAllValue, that))
                        },
                        _updateSelectAllValue: function() {
                            var that = this,
                                $element = that.element(),
                                $editor = $element && $element.find("." + DATAGRID_SELECT_CHECKBOX_CLASS);
                            if ($element && $editor.length && "multiple" === that.option("selection.mode")) {
                                $editor.dxCheckBox("instance").option("value", that.getController("selection").isSelectAll())
                            }
                        },
                        _handleDataChanged: function(e) {
                            this.callBase(e);
                            if (!e || "refresh" === e.changeType) {
                                this._updateSelectAllValue()
                            }
                        },
                        _getDefaultTemplate: function(column) {
                            var groupElement, that = this,
                                selectionController = that.getController("selection");
                            if ("select" === column.command) {
                                return function($cell, options) {
                                    var column = options.column;
                                    if ("select" === column.command) {
                                        $cell.addClass(DATAGRID_EDITOR_CELL_CLASS);
                                        groupElement = $("<div />").appendTo($cell).addClass(DATAGRID_SELECT_CHECKBOX_CLASS);
                                        that.setAria("label", messageLocalization.format("dxDataGrid-ariaSelectAll"), $cell);
                                        that.getController("editorFactory").createEditor(groupElement, $.extend({}, column, {
                                            parentType: "headerRow",
                                            value: selectionController.isSelectAll(),
                                            editorOptions: {
                                                visible: that.option("selection.allowSelectAll") || false !== selectionController.isSelectAll()
                                            },
                                            tabIndex: -1,
                                            setValue: function(value, e) {
                                                var allowSelectAll = that.option("selection.allowSelectAll");
                                                if (e.jQueryEvent && selectionController.isSelectAll() !== value) {
                                                    if (void 0 === e.previousValue || e.previousValue) {
                                                        selectionController.deselectAll();
                                                        e.component.option("value", false)
                                                    }
                                                    if (false === e.previousValue) {
                                                        if (allowSelectAll) {
                                                            selectionController.selectAll()
                                                        } else {
                                                            e.component.option("value", false)
                                                        }
                                                    }
                                                    e.jQueryEvent.preventDefault()
                                                }
                                                e.component.option("visible", allowSelectAll || false !== e.component.option("value"))
                                            }
                                        }));
                                        $cell.on(clickEvent.name, that.createAction(function(e) {
                                            var event = e.jQueryEvent;
                                            if (!$(event.target).closest("." + DATAGRID_SELECT_CHECKBOX_CLASS).length) {
                                                $(event.currentTarget).children().trigger(clickEvent.name)
                                            }
                                            event.preventDefault()
                                        }))
                                    }
                                }
                            } else {
                                return that.callBase(column)
                            }
                        }
                    },
                    rowsView: {
                        _getDefaultTemplate: function(column) {
                            var groupElement, that = this;
                            if ("select" === column.command) {
                                return function(container, options) {
                                    if ("data" === options.rowType && !options.row.inserted) {
                                        container.addClass(DATAGRID_EDITOR_CELL_CLASS);
                                        container.on(clickEvent.name, that.createAction(function(e) {
                                            var selectionController = that.getController("selection"),
                                                event = e.jQueryEvent,
                                                rowIndex = that.getRowIndex($(event.currentTarget).closest("." + DATAGRID_ROW_CLASS));
                                            if (rowIndex >= 0) {
                                                selectionController.startSelectionWithCheckboxes();
                                                selectionController.changeItemSelection(rowIndex, {
                                                    shift: event.shiftKey
                                                })
                                            }
                                        }));
                                        that.setAria("label", messageLocalization.format("dxDataGrid-ariaSelectRow"), container);
                                        groupElement = $("<div />").addClass(DATAGRID_SELECT_CHECKBOX_CLASS).appendTo(container);
                                        that.getController("editorFactory").createEditor(groupElement, $.extend({}, column, {
                                            parentType: "dataRow",
                                            value: options.value,
                                            tabIndex: -1,
                                            setValue: function(value, e) {
                                                if (e && e.jQueryEvent && "keydown" === e.jQueryEvent.type) {
                                                    container.trigger(clickEvent.name, e)
                                                }
                                            }
                                        }))
                                    }
                                }
                            } else {
                                return that.callBase(column)
                            }
                        },
                        _update: function(change) {
                            var that = this,
                                tableElements = that.getTableElements();
                            if ("updateSelection" === change.changeType) {
                                if (tableElements.length > 0) {
                                    $.each(tableElements, function(_, tableElement) {
                                        $.each(change.itemIndexes || [], function(_, index) {
                                            var $row, isSelected;
                                            if (change.items[index]) {
                                                $row = that._getRowElements($(tableElement)).eq(index);
                                                isSelected = !!change.items[index].isSelected;
                                                $row.toggleClass(DATAGRID_ROW_SELECTION_CLASS, isSelected).find("." + DATAGRID_SELECT_CHECKBOX_CLASS).dxCheckBox("option", "value", isSelected);
                                                that.setAria("selected", isSelected, $row)
                                            }
                                        })
                                    });
                                    that._updateCheckboxesClass()
                                }
                            } else {
                                that.callBase(change)
                            }
                        },
                        _createTable: function() {
                            var that = this,
                                selectionMode = that.option("selection.mode"),
                                $table = that.callBase.apply(that, arguments);
                            if ("none" !== selectionMode) {
                                if ("onLongTap" === that.option(SHOW_CHECKBOXES_MODE) || !support.touch) {
                                    $table.on(eventUtils.addNamespace(holdEvent.name, "dxDataGridRowsView"), "." + DATAGRID_DATA_ROW_CLASS, that.createAction(function(e) {
                                        processLongTap(that.component, e.jQueryEvent);
                                        e.jQueryEvent.stopPropagation()
                                    }))
                                }
                                $table.on("mousedown selectstart", that.createAction(function(e) {
                                    var event = e.jQueryEvent;
                                    if (event.shiftKey) {
                                        event.preventDefault()
                                    }
                                }))
                            }
                            return $table
                        },
                        _createRow: function(row) {
                            var isSelected, $row = this.callBase(row);
                            if (row) {
                                isSelected = !!row.isSelected;
                                if (isSelected) {
                                    $row.addClass(DATAGRID_ROW_SELECTION_CLASS)
                                }
                                this.setAria("selected", isSelected, $row)
                            }
                            return $row
                        },
                        _rowClick: function(e) {
                            var that = this,
                                jQueryEvent = e.jQueryEvent,
                                isSelectionDisabled = $(jQueryEvent.target).closest("." + DATAGRID_SELECTION_DISABLED_CLASS).length;
                            if (!that.isClickableElement($(jQueryEvent.target))) {
                                if (!isSelectionDisabled && ("multiple" !== that.option(SELECTION_MODE) || "always" !== that.option(SHOW_CHECKBOXES_MODE))) {
                                    if (that.getController("selection").changeItemSelection(e.rowIndex, {
                                            control: jQueryEvent.ctrlKey,
                                            shift: jQueryEvent.shiftKey
                                        })) {
                                        jQueryEvent.preventDefault();
                                        e.handled = true
                                    }
                                }
                                that.callBase(e)
                            }
                        },
                        isClickableElement: function($target) {
                            var isCommandSelect = $target.closest("." + DATAGRID_COMMAND_SELECT_CLASS).length;
                            return !!isCommandSelect
                        },
                        _renderCore: function(change) {
                            this.callBase(change);
                            this._updateCheckboxesClass()
                        },
                        _updateCheckboxesClass: function() {
                            var tableElements = this.getTableElements(),
                                selectionController = this.getController("selection"),
                                isCheckBoxesHidden = selectionController.isSelectColumnVisible() && !selectionController.isSelectionWithCheckboxes();
                            $.each(tableElements, function(_, tableElement) {
                                $(tableElement).toggleClass(DATAGRID_CHECKBOXES_HIDDEN_CLASS, isCheckBoxesHidden)
                            })
                        }
                    }
                }
            }
        })
    },
    /*!********************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.column_chooser_module.js ***!
      \********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            columnsView = __webpack_require__( /*! ./ui.data_grid.columns_view */ 340),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            themes = __webpack_require__( /*! ../themes */ 143),
            Button = __webpack_require__( /*! ../button */ 196),
            TreeView = __webpack_require__( /*! ../tree_view */ 356),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            Popup = __webpack_require__( /*! ../popup */ 195);
        var DATAGRID_COLUMN_CHOOSER_CLASS = "dx-datagrid-column-chooser",
            DATAGRID_COLUMN_CHOOSER_BUTTON_CLASS = "dx-datagrid-column-chooser-button",
            DATAGRID_COLUMN_CHOOSER_ICON_NAME = "column-chooser",
            DATAGRID_COLUMN_CHOOSER_ITEM_CLASS = "dx-column-chooser-item",
            DATAGRID_NOTOUCH_ACTION_CLASS = "dx-datagrid-notouch-action",
            DATAGRID_COLUMN_CHOOSER_LIST_CLASS = "dx-datagrid-column-chooser-list",
            DATAGRID_COLUMN_CHOOSER_DRAG_CLASS = "dx-datagrid-column-chooser-mode-drag",
            DATAGRID_COLUMN_CHOOSER_SELECT_CLASS = "dx-datagrid-column-chooser-mode-select",
            DATAGRID_CLICK_TIMEOUT = 300,
            processItems = function(that, chooserColumns) {
                var item, items = [],
                    isSelectMode = "select" === that.option("columnChooser.mode");
                if (chooserColumns.length) {
                    $.each(chooserColumns, function(index, column) {
                        item = {
                            text: column.caption,
                            cssClass: column.cssClass,
                            allowHiding: column.allowHiding,
                            expanded: true,
                            id: column.index,
                            parentId: commonUtils.isDefined(column.ownerBand) ? column.ownerBand : null
                        };
                        if (isSelectMode) {
                            item.selected = column.visible
                        }
                        items.push(item)
                    })
                }
                return items
            };
        exports.ColumnChooserController = gridCore.ViewController.inherit({
            renderShowColumnChooserButton: function($element) {
                var $columnChooserButton, that = this,
                    columnChooserEnabled = that.option("columnChooser.enabled"),
                    $showColumnChooserButton = $element.find("." + DATAGRID_COLUMN_CHOOSER_BUTTON_CLASS);
                if (columnChooserEnabled) {
                    if (!$showColumnChooserButton.length) {
                        $columnChooserButton = $("<div />").addClass(DATAGRID_COLUMN_CHOOSER_BUTTON_CLASS).appendTo($element);
                        that._createComponent($columnChooserButton, Button, {
                            icon: DATAGRID_COLUMN_CHOOSER_ICON_NAME,
                            onClick: function() {
                                that.getView("columnChooserView").showColumnChooser()
                            },
                            hint: that.option("columnChooser.title"),
                            _templates: {}
                        })
                    } else {
                        $showColumnChooserButton.show()
                    }
                } else {
                    $showColumnChooserButton.hide()
                }
            },
            getPosition: function() {
                var rowsView = this.getView("rowsView");
                return {
                    my: "right bottom",
                    at: "right bottom",
                    of: rowsView && rowsView.element(),
                    collision: "fit",
                    offset: "-2 -2",
                    boundaryOffset: "2 2"
                }
            }
        });
        exports.ColumnChooserView = columnsView.ColumnsView.inherit({
            _resizeCore: $.noop,
            _isWinDevice: function() {
                return !!devices.real().win
            },
            _updateList: function(allowUpdate) {
                var items, $popupContent = this._popupContainer.content(),
                    isSelectMode = "select" === this.option("columnChooser.mode"),
                    chooserColumns = this._columnsController.getChooserColumns(isSelectMode);
                if (!isSelectMode || !this._columnChooserList || allowUpdate) {
                    this._popupContainer._wrapper().toggleClass(DATAGRID_COLUMN_CHOOSER_DRAG_CLASS, !isSelectMode).toggleClass(DATAGRID_COLUMN_CHOOSER_SELECT_CLASS, isSelectMode);
                    items = processItems(this, chooserColumns);
                    this._renderColumnChooserList($popupContent, items)
                }
            },
            _initializePopupContainer: function() {
                var that = this,
                    $element = that.element().addClass(DATAGRID_COLUMN_CHOOSER_CLASS),
                    columnChooserOptions = that.option("columnChooser"),
                    theme = themes.current(),
                    isGenericTheme = theme && theme.indexOf("generic") > -1,
                    isAndroid5Theme = theme && theme.indexOf("android5") > -1,
                    dxPopupOptions = {
                        visible: false,
                        shading: false,
                        showCloseButton: false,
                        dragEnabled: true,
                        resizeEnabled: true,
                        toolbarItems: [{
                            text: columnChooserOptions.title,
                            toolbar: "top",
                            location: isGenericTheme || isAndroid5Theme ? "before" : "center"
                        }],
                        position: that.getController("columnChooser").getPosition(),
                        width: columnChooserOptions.width,
                        height: columnChooserOptions.height,
                        rtlEnabled: that.option("rtlEnabled"),
                        onHidden: function() {
                            if (that._isWinDevice()) {
                                $(document.body).removeClass(DATAGRID_NOTOUCH_ACTION_CLASS)
                            }
                        },
                        container: columnChooserOptions.container
                    };
                if (isGenericTheme) {
                    $.extend(dxPopupOptions, {
                        showCloseButton: true
                    })
                } else {
                    dxPopupOptions.toolbarItems[dxPopupOptions.toolbarItems.length] = {
                        shortcut: "cancel"
                    }
                }
                if (!commonUtils.isDefined(this._popupContainer)) {
                    that._popupContainer = that._createComponent($element, Popup, dxPopupOptions);
                    that._popupContainer.on("optionChanged", function(args) {
                        if ("visible" === args.name) {
                            that.renderCompleted.fire()
                        }
                    })
                } else {
                    this._popupContainer.option(dxPopupOptions)
                }
            },
            _renderCore: function(allowUpdate) {
                if (this._popupContainer) {
                    this._updateList(allowUpdate)
                }
            },
            _renderColumnChooserList: function($container, items) {
                var isSelectMode = "select" === this.option("columnChooser.mode"),
                    listConfig = {
                        items: items,
                        dataStructure: "plain",
                        activeStateEnabled: true,
                        focusStateEnabled: true,
                        hoverStateEnabled: true,
                        rootValue: null
                    };
                if (this._isWinDevice()) {
                    listConfig.useNativeScrolling = false
                }
                $.extend(listConfig, isSelectMode ? this._prepareSelectModeConfig() : this._prepareDragModeConfig());
                if (this._columnChooserList) {
                    this._columnChooserList.option(listConfig)
                } else {
                    this._columnChooserList = this._createComponent($container, TreeView, listConfig);
                    $container.addClass(DATAGRID_COLUMN_CHOOSER_LIST_CLASS)
                }
            },
            _prepareDragModeConfig: function() {
                var columnChooserOptions = this.option("columnChooser");
                return {
                    noDataText: columnChooserOptions.emptyPanelText,
                    activeStateEnabled: false,
                    focusStateEnabled: false,
                    hoverStateEnabled: false,
                    itemTemplate: function(data, index, $item) {
                        $item.text(data.text).parent().addClass(data.cssClass).addClass(DATAGRID_COLUMN_CHOOSER_ITEM_CLASS)
                    }
                }
            },
            _prepareSelectModeConfig: function() {
                var that = this,
                    selectionChangedHandler = function(e) {
                        var visibleColumns = that._columnsController.getVisibleColumns().filter(function(item) {
                                return !item.command
                            }),
                            isLastColumnUnselected = 1 === visibleColumns.length && !e.itemData.selected;
                        if (isLastColumnUnselected) {
                            e.component.selectItem(e.itemElement)
                        } else {
                            setTimeout(function() {
                                that._columnsController.columnOption(e.itemData.id, "visible", e.itemData.selected)
                            }, DATAGRID_CLICK_TIMEOUT)
                        }
                    };
                return {
                    selectNodesRecursive: false,
                    showCheckBoxesMode: "normal",
                    activeStateEnabled: true,
                    focusStateEnabled: true,
                    itemTemplate: "item",
                    onItemSelectionChanged: selectionChangedHandler
                }
            },
            _columnOptionChanged: function(e) {
                var optionNames = e.optionNames,
                    isSelectMode = "select" === this.option("columnChooser.mode");
                this.callBase(e);
                if (isSelectMode && optionNames.showInColumnChooser) {
                    this.render(null, true)
                }
            },
            optionChanged: function(args) {
                switch (args.name) {
                    case "columnChooser":
                        this.render(null, true);
                        break;
                    default:
                        this.callBase(args)
                }
            },
            getColumnElements: function() {
                var $content = this._popupContainer && this._popupContainer.content();
                return $content && $content.find("." + DATAGRID_COLUMN_CHOOSER_ITEM_CLASS)
            },
            getName: function() {
                return "columnChooser"
            },
            getColumns: function() {
                return this._columnsController.getChooserColumns()
            },
            allowDragging: function(column, sourceLocation) {
                var columnVisible = column && column.allowHiding && ("columnChooser" !== sourceLocation || !column.visible && this._columnsController.isParentColumnVisible(column.index));
                return this.isColumnChooserVisible() && columnVisible
            },
            getBoundingRect: function() {
                var offset, that = this,
                    container = that._popupContainer && that._popupContainer._container();
                if (container && container.is(":visible")) {
                    offset = container.offset();
                    return {
                        left: offset.left,
                        top: offset.top,
                        right: offset.left + container.outerWidth(),
                        bottom: offset.top + container.outerHeight()
                    }
                }
                return null
            },
            showColumnChooser: function() {
                this._isPopupContainerShown = true;
                if (!this._popupContainer) {
                    this._initializePopupContainer();
                    this.render()
                }
                this._popupContainer.show();
                if (this._isWinDevice()) {
                    $(document.body).addClass(DATAGRID_NOTOUCH_ACTION_CLASS)
                }
            },
            hideColumnChooser: function() {
                if (this._popupContainer) {
                    this._popupContainer.hide();
                    this._isPopupContainerShown = false
                }
            },
            isColumnChooserVisible: function() {
                var popupContainer = this._popupContainer;
                return popupContainer && popupContainer.option("visible")
            },
            publicMethods: function() {
                return ["showColumnChooser", "hideColumnChooser"]
            }
        });
        gridCore.registerModule("columnChooser", {
            defaultOptions: function() {
                return {
                    columnChooser: {
                        enabled: false,
                        mode: "dragAndDrop",
                        width: 250,
                        height: 260,
                        title: messageLocalization.format("dxDataGrid-columnChooserTitle"),
                        emptyPanelText: messageLocalization.format("dxDataGrid-columnChooserEmptyText"),
                        container: void 0
                    }
                }
            },
            controllers: {
                columnChooser: exports.ColumnChooserController
            },
            views: {
                columnChooserView: exports.ColumnChooserView
            },
            extenders: {
                views: {
                    headerPanel: {
                        _getToolbarItems: function() {
                            var items = this.callBase();
                            return this._appendColumnChooserItem(items)
                        },
                        _appendColumnChooserItem: function(items) {
                            var that = this,
                                columnChooserEnabled = that.option("columnChooser.enabled");
                            if (columnChooserEnabled) {
                                var onClickHandler = function() {
                                        that.component.getView("columnChooserView").showColumnChooser()
                                    },
                                    onInitialized = function(e) {
                                        e.element.addClass(that._getToolbarButtonClass(DATAGRID_COLUMN_CHOOSER_BUTTON_CLASS))
                                    },
                                    hintText = that.option("columnChooser.title"),
                                    toolbarItem = {
                                        widget: "dxButton",
                                        options: {
                                            icon: DATAGRID_COLUMN_CHOOSER_ICON_NAME,
                                            onClick: onClickHandler,
                                            hint: hintText,
                                            text: hintText,
                                            onInitialized: onInitialized
                                        },
                                        showText: "inMenu",
                                        location: "after",
                                        name: "columnChooser",
                                        locateInMenu: "auto"
                                    };
                                items.push(toolbarItem)
                            }
                            return items
                        },
                        optionChanged: function(args) {
                            switch (args.name) {
                                case "columnChooser":
                                    this._invalidateToolbarItems();
                                    args.handled = true;
                                    break;
                                default:
                                    this.callBase(args)
                            }
                        },
                        isVisible: function() {
                            var that = this,
                                columnChooserEnabled = that.option("columnChooser.enabled");
                            return that.callBase() || columnChooserEnabled
                        }
                    }
                },
                controllers: {
                    columns: {
                        allowMoveColumn: function(fromVisibleIndex, toVisibleIndex, sourceLocation, targetLocation) {
                            var columnChooserMode = this.option("columnChooser.mode"),
                                isMoveColumnDisallowed = "select" === columnChooserMode && "columnChooser" === targetLocation;
                            return isMoveColumnDisallowed ? false : this.callBase(fromVisibleIndex, toVisibleIndex, sourceLocation, targetLocation)
                        }
                    }
                }
            }
        })
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/tree_view.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            messageLocalization = __webpack_require__( /*! ../localization/message */ 80),
            clickEvent = __webpack_require__( /*! ../events/click */ 64),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            CheckBox = __webpack_require__( /*! ./check_box */ 241),
            HierarchicalCollectionWidget = __webpack_require__( /*! ./hierarchical_collection/ui.hierarchical_collection_widget */ 330),
            eventUtils = __webpack_require__( /*! ../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../events/pointer */ 65),
            dblclickEvent = __webpack_require__( /*! ../events/dblclick */ 177),
            fx = __webpack_require__( /*! ../animation/fx */ 59),
            Scrollable = __webpack_require__( /*! ./scroll_view/ui.scrollable */ 237).default,
            LoadIndicator = __webpack_require__( /*! ./load_indicator */ 231);
        var WIDGET_CLASS = "dx-treeview",
            NODE_CONTAINER_CLASS = "dx-treeview-node-container",
            OPENED_NODE_CONTAINER_CLASS = "dx-treeview-node-container-opened",
            NODE_CLASS = "dx-treeview-node",
            ITEM_CLASS = "dx-treeview-item",
            ITEM_WITH_CHECKBOX_CLASS = "dx-treeview-item-with-checkbox",
            ITEM_DATA_KEY = "dx-treeview-item-data",
            IS_LEAF = "dx-treeview-node-is-leaf",
            TOGGLE_ITEM_VISIBILITY_CLASS = "dx-treeview-toggle-item-visibility",
            TOGGLE_ITEM_VISIBILITY_OPENED_CLASS = "dx-treeview-toggle-item-visibility-opened",
            SELECT_ALL_ITEM_CLASS = "dx-treeview-select-all-item",
            DISABLED_STATE_CLASS = "dx-state-disabled",
            SELECTED_ITEM_CLASS = "dx-state-selected",
            DATA_ITEM_ID = "data-item-id";
        var TreeView = HierarchicalCollectionWidget.inherit({
            _supportedKeys: function(e) {
                var click = function(e) {
                    var $itemElement = this.option("focusedElement");
                    if (!$itemElement) {
                        return
                    }
                    e.target = $itemElement;
                    e.currentTarget = $itemElement;
                    this._itemClickHandler(e, $itemElement.find(">." + ITEM_CLASS))
                };
                var select = function(e) {
                    e.preventDefault();
                    this._changeCheckBoxState(this.option("focusedElement"))
                };
                var toggleExpandedNestedItems = function(state, e) {
                    if (!this.option("expandAllEnabled")) {
                        return
                    }
                    e.preventDefault();
                    var $rootElement = this.option("focusedElement");
                    if (!$rootElement) {
                        return
                    }
                    var rootItem = this._getItemData($rootElement.find("." + ITEM_CLASS));
                    this._toggleExpandedNestedItems([rootItem], state)
                };
                return $.extend(this.callBase(), {
                    enter: this._showCheckboxes() ? select : click,
                    space: this._showCheckboxes() ? select : click,
                    asterisk: $.proxy(toggleExpandedNestedItems, this, true),
                    minus: $.proxy(toggleExpandedNestedItems, this, false)
                })
            },
            _changeCheckBoxState: function($element) {
                var checkboxInstance = this._getCheckBoxInstance($element),
                    currentState = checkboxInstance.option("value");
                if (!checkboxInstance.option("disabled")) {
                    this._updateItemSelection(!currentState, $element.find("." + ITEM_CLASS).get(0), true, $element)
                }
            },
            _toggleExpandedNestedItems: function(items, state) {
                if (!items) {
                    return
                }
                for (var i = 0, len = items.length; i < len; i++) {
                    var item = items[i],
                        node = this._dataAdapter.getNodeByItem(item);
                    this._toggleExpandedState(node, state);
                    this._toggleExpandedNestedItems(item.items, state)
                }
            },
            _getNodeElement: function(node) {
                return this.element().find("[" + DATA_ITEM_ID + "='" + commonUtils.normalizeKey(node.internalFields.key) + "']")
            },
            _activeStateUnit: "." + ITEM_CLASS,
            _widgetClass: function() {
                return WIDGET_CLASS
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    animationEnabled: true,
                    dataStructure: "tree",
                    expandAllEnabled: false,
                    hasItemsExpr: "hasItems",
                    selectNodesRecursive: true,
                    expandNodesRecursive: true,
                    showCheckBoxesMode: "none",
                    selectAllText: messageLocalization.format("dxList-selectAll"),
                    onItemSelectionChanged: null,
                    onItemExpanded: null,
                    onItemCollapsed: null,
                    scrollDirection: "vertical",
                    virtualModeEnabled: false,
                    rootValue: 0,
                    searchValue: "",
                    focusStateEnabled: false,
                    selectionMode: "multiple",
                    expandEvent: "dblclick",
                    selectByClick: false
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    showCheckBoxes: {
                        since: "15.2",
                        message: "use 'showCheckBoxesMode' option instead"
                    },
                    selectAllEnabled: {
                        since: "15.2",
                        message: "use 'showCheckBoxesMode' option instead"
                    },
                    onItemSelected: {
                        since: "16.1",
                        alias: "onItemSelectionChanged"
                    }
                })
            },
            _initSelectedItems: $.noop,
            _syncSelectionOptions: $.noop,
            _fireSelectionChanged: function() {
                var selectionChangePromise = this._selectionChangePromise;
                $.when(selectionChangePromise).done($.proxy(function() {
                    this._createActionByOption("onSelectionChanged", {
                        excludeValidators: ["disabled", "readOnly"]
                    })()
                }, this))
            },
            _checkBoxModeChange: function(value, previousValue) {
                if ("none" === previousValue || "none" === value) {
                    this.repaint();
                    return
                }
                var selectAllExists = this._$selectAllItem && this._$selectAllItem.length;
                switch (value) {
                    case "selectAll":
                        !selectAllExists && this._renderSelectAllItem();
                        break;
                    case "normal":
                        if (selectAllExists) {
                            this._$selectAllItem.remove();
                            delete this._$selectAllItem
                        }
                }
            },
            _removeSelection: function() {
                var that = this;
                $.each(this._dataAdapter.getFullData(), function(_, node) {
                    if (!that._hasChildren(node)) {
                        return
                    }
                    that._dataAdapter.toggleSelection(node.internalFields.key, false, true)
                })
            },
            _optionChanged: function(args) {
                var name = args.name,
                    value = args.value,
                    previousValue = args.previousValue;
                switch (name) {
                    case "showCheckBoxes":
                        this.option("showCheckBoxesMode", value ? "normal" : "none");
                        break;
                    case "selectAllEnabled":
                        this.option("showCheckBoxesMode", value ? "selectAll" : "normal");
                        break;
                    case "selectAllText":
                        if (this._$selectAllItem) {
                            this._$selectAllItem.dxCheckBox("instance").option("text", value)
                        }
                        break;
                    case "showCheckBoxesMode":
                        this._checkBoxModeChange(value, previousValue);
                        break;
                    case "scrollDirection":
                        this._scrollableContainer.option("direction", value);
                        break;
                    case "items":
                        delete this._$selectAllItem;
                        this.callBase(args);
                        break;
                    case "dataSource":
                        this.callBase(args);
                        this._initDataAdapter();
                        this._filter = {};
                        break;
                    case "hasItemsExpr":
                        this._initAccessors();
                        this.repaint();
                        break;
                    case "expandEvent":
                        this._toggleExpandEvent(args.previousValue, args.value);
                        break;
                    case "dataStructure":
                    case "rootValue":
                    case "searchValue":
                        if ((!value.length || value < previousValue) && "none" !== this.option("showCheckBoxesMode")) {
                            this._removeSelection()
                        }
                        this._initDataAdapter();
                        this.repaint();
                        break;
                    case "selectNodesRecursive":
                    case "expandNodesRecursive":
                    case "onItemSelectionChanged":
                    case "onItemExpanded":
                    case "onItemCollapsed":
                    case "expandAllEnabled":
                    case "animationEnabled":
                    case "virtualModeEnabled":
                    case "selectByClick":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _initDataSource: function() {
                var that = this,
                    filter = this._filter;
                this.callBase();
                if (this._isVirtualMode()) {
                    if (!filter.custom) {
                        filter.custom = this._dataSource.filter()
                    }
                    if (!filter.internal) {
                        filter.internal = [this.option("parentIdExpr"), this.option("rootValue")]
                    }
                    var resultFilter = this._combineFilter();
                    this._dataSource.filter(resultFilter);
                    this._dataSource.on("loadingChanged", function(isLoading) {
                        if (isLoading && !this.isLoaded()) {
                            that.option("items", []);
                            that._dataSource.filter() !== resultFilter && that._dataSource.filter([])
                        }
                    })
                }
            },
            _combineFilter: function() {
                if (!this._filter.custom || !this._filter.custom.length) {
                    return this._filter.internal
                }
                return [this._filter.custom, this._filter.internal]
            },
            _dataSourceLoadErrorHandler: function() {
                this._renderEmptyMessage()
            },
            _init: function() {
                this._filter = {};
                this.callBase();
                this._initStoreChangeHandlers();
                this._initCheckBoxesMode()
            },
            _dataSourceChangedHandler: function(newItems) {
                var isInArray = $.inArray(newItems[0], this.option("items")) + 1;
                if (!this._initialized || !this._isVirtualMode() || !this.option("items").length) {
                    this.option("items", newItems);
                    return
                }
                if (!isInArray) {
                    this.option().items = this.option("items").concat(newItems);
                    this._initDataAdapter()
                }!this._contentAlreadyRendered && this._renderContent()
            },
            _initStoreChangeHandlers: function() {
                if ("plain" !== this.option("dataStructure")) {
                    return
                }
                var that = this;
                this._dataSource && this._dataSource.store().on("inserted", function(newItem) {
                    that.option().items = that.option("items").concat(newItem);
                    that._dataAdapter.addItem(newItem);
                    if (!that._isFiltered(newItem)) {
                        return
                    }
                    that._updateLevel(that._parentIdGetter(newItem))
                }).on("removed", function(removedKey) {
                    var node = that._dataAdapter.getNodeByKey(removedKey);
                    that.option("items")[that._dataAdapter.getIndexByKey(node.internalFields.key)] = 0;
                    that._markChildrenItemsToRemove(node);
                    that._removeItems();
                    that._dataAdapter.removeItem(removedKey);
                    that._updateLevel(that._parentIdGetter(node))
                })
            },
            _markChildrenItemsToRemove: function(node) {
                var that = this,
                    keys = node.internalFields.childrenKeys;
                $.each(keys, function(_, key) {
                    that.option("items")[that._dataAdapter.getIndexByKey(key)] = 0;
                    that._markChildrenItemsToRemove(that._dataAdapter.getNodeByKey(key))
                })
            },
            _removeItems: function() {
                var that = this,
                    counter = 0,
                    items = $.extend(true, [], this.option("items"));
                $.each(items, function(index, item) {
                    if (!item) {
                        that.option("items").splice(index - counter, 1);
                        counter++
                    }
                })
            },
            _isFiltered: function(item) {
                var value = this.option("searchValue"),
                    reg = new RegExp(value, "i");
                return reg.test(this._displayGetter(item))
            },
            _updateLevel: function(parentId) {
                var $container = this._getContainerByParentKey(parentId);
                this._renderItems($container, this._dataAdapter.getChildrenNodes(parentId))
            },
            _getOldContainer: function($itemElement) {
                if ($itemElement.length) {
                    return $itemElement.find(" > ." + NODE_CONTAINER_CLASS)
                }
                if (this._scrollableContainer) {
                    return this._scrollableContainer.content().children()
                }
                return $()
            },
            _getContainerByParentKey: function(parentId) {
                var $container, node = this._dataAdapter.getNodeByKey(parentId),
                    $itemElement = node ? this._getNodeElement(node) : [];
                this._getOldContainer($itemElement).remove();
                $container = this._renderNodeContainer($itemElement);
                if (this._isRootLevel(parentId)) {
                    if (!this._scrollableContainer) {
                        this._renderScrollableContainer()
                    }
                    this._scrollableContainer.content().append($container)
                }
                return $container
            },
            _isRootLevel: function(parentId) {
                return parentId === this.option("rootValue")
            },
            _getAccessors: function() {
                return ["key", "display", "selected", "expanded", "items", "parentId", "disabled", "hasItems"]
            },
            _getDataAdapterOptions: function() {
                return {
                    rootValue: this.option("rootValue"),
                    multipleSelection: !this._isSingleSelection(),
                    recursiveSelection: this.option("selectNodesRecursive"),
                    recursiveExpansion: this.option("expandNodesRecursive"),
                    searchValue: this.option("searchValue"),
                    dataType: this.option("dataStructure")
                }
            },
            _render: function() {
                this._attachPointerEventHandler();
                this.callBase();
                this.setAria("role", "tree")
            },
            _attachPointerEventHandler: function() {
                var that = this,
                    event = pointerEvents.down;
                this.element().off(event).on(event, function(e) {
                    var $target = $(e.target).closest(that._activeStateUnit);
                    if (!$target.length) {
                        e.preventDefault()
                    }
                })
            },
            _renderContentImpl: function() {
                if (!this.option("items").length) {
                    return
                }
                var $nodeContainer = this._renderNodeContainer();
                this._renderScrollableContainer();
                this._scrollableContainer.content().append($nodeContainer);
                this._renderItems($nodeContainer, this._dataAdapter.getRootNodes());
                this._toggleExpandEvent(null, this.option("expandEvent"));
                if (this._selectAllEnabled()) {
                    this._renderSelectAllItem($nodeContainer)
                }
            },
            _isVirtualMode: function() {
                return this.option("virtualModeEnabled") && this._isDataStructurePlain() && this.option("dataSource")
            },
            _isDataStructurePlain: function() {
                return "plain" === this.option("dataStructure")
            },
            _fireContentReadyAction: function() {
                this.callBase();
                if (this._scrollableContainer) {
                    this._scrollableContainer.update()
                }
            },
            _renderScrollableContainer: function() {
                this._scrollableContainer = this._createComponent($("<div>").appendTo(this.element()), Scrollable, {
                    direction: this.option("scrollDirection"),
                    useKeyboard: false
                })
            },
            _renderNodeContainer: function($parent) {
                var $container = $("<ul>").addClass(NODE_CONTAINER_CLASS);
                this.setAria("role", "group", $container);
                if ($parent && $parent.length) {
                    var itemData = this._getItemData($parent.find("> ." + ITEM_CLASS));
                    if (this._expandedGetter(itemData)) {
                        $container.addClass(OPENED_NODE_CONTAINER_CLASS)
                    }
                    $container.appendTo($parent)
                }
                return $container
            },
            _createDOMElement: function($nodeContainer, node) {
                var $node = $("<li>").addClass(NODE_CLASS).attr(DATA_ITEM_ID, commonUtils.normalizeKey(node.internalFields.key)).prependTo($nodeContainer);
                this.setAria({
                    role: "treeitem",
                    label: this._displayGetter(node.internalFields.item) || "",
                    expanded: node.internalFields.expanded || false,
                    level: this._getLevel($nodeContainer)
                }, $node);
                return $node
            },
            _getLevel: function($nodeContainer) {
                var parent = $nodeContainer.parent();
                return parent.hasClass("dx-scrollable-content") ? 1 : parseInt(parent.attr("aria-level")) + 1
            },
            _showCheckboxes: function() {
                return "none" !== this.option("showCheckBoxesMode")
            },
            _selectAllEnabled: function() {
                return "selectAll" === this.option("showCheckBoxesMode")
            },
            _initCheckBoxesMode: function() {
                if (this._showCheckboxes()) {
                    return
                }
                this._suppressDeprecatedWarnings();
                var showCheckboxes = this.option("showCheckBoxes"),
                    selectAllEnabled = this.option("selectAllEnabled");
                this._resumeDeprecatedWarnings();
                this.option("showCheckBoxesMode", showCheckboxes ? selectAllEnabled ? "selectAll" : "normal" : "none")
            },
            _renderItems: function($nodeContainer, nodes) {
                var length = nodes.length - 1;
                for (var i = length; i >= 0; i--) {
                    this._renderItem(nodes[i], $nodeContainer)
                }
                this._renderFocusTarget()
            },
            _renderItem: function(node, $nodeContainer) {
                var $node = this._createDOMElement($nodeContainer, node),
                    nodeData = node.internalFields;
                this._showCheckboxes() && this._renderCheckBox($node, node);
                this.setAria("selected", nodeData.selected, $node);
                this._toggleSelectedClass($node, nodeData.selected);
                this.callBase(nodeData.key, nodeData.item, $node);
                if (false !== nodeData.item.visible) {
                    this._renderChildren($node, node)
                }
            },
            _renderChildren: function($node, node) {
                if (!this._hasChildren(node)) {
                    this._addLeafClass($node);
                    return
                }
                this._renderToggleItemVisibilityIcon($node, node);
                this._renderSublevel($node, node)
            },
            _hasChildren: function(node) {
                if (this._isVirtualMode()) {
                    return false !== this._hasItemsGetter(node.internalFields.item)
                }
                return this.callBase(node)
            },
            _renderSublevel: function($node, node) {
                var $nestedNodeContainer = this._renderNodeContainer($node, node);
                if (!node.internalFields.expanded) {
                    return
                }
                var childrenNodes = this._getChildNodes(node);
                if (childrenNodes.length) {
                    this._renderItems($nestedNodeContainer, childrenNodes)
                } else {
                    this._renderNestedItems($nestedNodeContainer)
                }
                $nestedNodeContainer.addClass(OPENED_NODE_CONTAINER_CLASS)
            },
            _executeItemRenderAction: function(index, itemData, itemElement) {
                var node = this._dataAdapter.getNodeByItem(itemData);
                this._getItemRenderAction()({
                    itemElement: itemElement,
                    itemIndex: index,
                    itemData: itemData,
                    node: node
                })
            },
            _addLeafClass: function($node) {
                $node.addClass(IS_LEAF)
            },
            _toggleExpandEvent: function(detached, attached) {
                var that = this,
                    detachedEventName = this._getEventNameByOption(detached) + "_expand",
                    attachedEventName = this._getEventNameByOption(attached) + "_expand",
                    $itemsContainer = this._itemContainer(),
                    itemSelector = this._itemSelector();
                detachedEventName && $itemsContainer.off(detachedEventName, itemSelector);
                attachedEventName && $itemsContainer.on(attachedEventName, itemSelector, function(e) {
                    that._toggleExpandedState(e.currentTarget, void 0, e)
                })
            },
            _getEventNameByOption: function(name) {
                switch (name) {
                    case "click":
                        return eventUtils.addNamespace(clickEvent.name, this.NAME);
                    case "dblclick":
                        return eventUtils.addNamespace(dblclickEvent.name, this.NAME);
                    default:
                        return false
                }
            },
            _getNodeByItemElement: function(itemElement) {
                if (commonUtils.isPrimitive(itemElement)) {
                    return this._dataAdapter.getNodeByKey(itemElement)
                }
                itemElement = $(itemElement).get(0);
                if (!itemElement) {
                    return null
                }
                if (itemElement.nodeType) {
                    return this._dataAdapter.getNodeByItem(this._getItemData(itemElement))
                }
                if (itemElement.internalFields) {
                    return itemElement
                }
                return this._dataAdapter.getNodeByItem(itemElement)
            },
            _toggleExpandedState: function(itemElement, state, e) {
                var node = this._getNodeByItemElement(itemElement),
                    currentState = node.internalFields.expanded;
                if (node.internalFields.disabled || currentState === state) {
                    return
                }
                if (this._isVirtualMode()) {
                    var $node = this._getNodeElement(node);
                    this._hasChildren(node) && this._createLoadIndicator($node)
                }
                if (!commonUtils.isDefined(state)) {
                    state = !currentState
                }
                this._dataAdapter.toggleExpansion(node.internalFields.key, state);
                node.internalFields.expanded = state;
                if (this._isVirtualMode() && !this._hasChildren(node)) {
                    return
                }
                this._updateExpandedItemsUI(node, state, e)
            },
            _createLoadIndicator: function($node) {
                var $icon = $node.find(">." + TOGGLE_ITEM_VISIBILITY_CLASS),
                    $nodeContainer = $node.find(" > ." + NODE_CONTAINER_CLASS);
                if ($icon.hasClass(TOGGLE_ITEM_VISIBILITY_OPENED_CLASS) || $nodeContainer.not(":empty").length) {
                    return
                }
                this._createComponent("<div>", LoadIndicator, {}).element().appendTo($node);
                $icon.hide()
            },
            _renderToggleItemVisibilityIcon: function($node, node) {
                var $icon = $("<div>").addClass(TOGGLE_ITEM_VISIBILITY_CLASS).appendTo($node);
                if (node.internalFields.expanded) {
                    $icon.addClass(TOGGLE_ITEM_VISIBILITY_OPENED_CLASS);
                    $node.parent().addClass(OPENED_NODE_CONTAINER_CLASS)
                }
                if (node.internalFields.disabled) {
                    $icon.addClass(DISABLED_STATE_CLASS)
                }
                this._renderToggleItemVisibilityIconClick($icon, node)
            },
            _renderToggleItemVisibilityIconClick: function($icon, node) {
                var eventName = eventUtils.addNamespace(clickEvent.name, this.NAME),
                    that = this;
                $icon.off(eventName).on(eventName, function(e) {
                    that._toggleExpandedState(node, void 0, e)
                })
            },
            _updateExpandedItemsUI: function(node, state, e) {
                var $nodeContainer, that = this,
                    $node = that._getNodeElement(node),
                    $icon = $node.find(">." + TOGGLE_ITEM_VISIBILITY_CLASS);
                $icon.toggleClass(TOGGLE_ITEM_VISIBILITY_OPENED_CLASS, state);
                if (!state) {
                    that._updateExpandedItem(node, state, e);
                    return
                }
                $nodeContainer = $node.find(" > ." + NODE_CONTAINER_CLASS);
                that._renderNestedItems($nodeContainer).done(function(itemsLoaded) {
                    if (itemsLoaded.wereLoaded) {
                        itemsLoaded.newLoaded && that._fireContentReadyAction();
                        that._updateExpandedItem(node, state, e)
                    }
                })
            },
            _updateExpandedItem: function(node, state, e) {
                var $node = this._getNodeElement(node),
                    $nodeContainer = $node.find(" > ." + NODE_CONTAINER_CLASS);
                this._animateNodeContainer($nodeContainer, state);
                this.setAria("expanded", state, $node);
                this._fireExpandedStateUpdatedEvt(state, node, e)
            },
            _animateNodeContainer: function($nodeContainer, state) {
                var nodeHeight = $nodeContainer.height();
                fx.stop($nodeContainer, true);
                fx.animate($nodeContainer, {
                    type: "custom",
                    duration: this.option("animationEnabled") ? 400 : 0,
                    from: {
                        "max-height": state ? 0 : nodeHeight
                    },
                    to: {
                        "max-height": state ? nodeHeight : 0
                    },
                    start: function() {
                        $nodeContainer.addClass(OPENED_NODE_CONTAINER_CLASS)
                    },
                    complete: $.proxy(function() {
                        $nodeContainer.css("max-height", "none");
                        $nodeContainer.toggleClass(OPENED_NODE_CONTAINER_CLASS, state);
                        this._scrollableContainer.update()
                    }, this)
                })
            },
            _fireExpandedStateUpdatedEvt: function(isExpanded, node, e) {
                var target, optionName = isExpanded ? "onItemExpanded" : "onItemCollapsed";
                if (!this.option(optionName) || !this._hasChildren(node)) {
                    return
                }
                if (commonUtils.isDefined(e)) {
                    this._itemJQueryEventHandler(e, optionName, {
                        node: this._dataAdapter.getPublicNode(node)
                    })
                } else {
                    target = this._getNodeElement(node);
                    this._itemEventHandler(target, optionName, {
                        jQueryEvent: e,
                        node: this._dataAdapter.getPublicNode(node)
                    })
                }
            },
            _renderNestedItems: function($container) {
                var deferred = $.Deferred();
                if (!$container.is(":empty")) {
                    return deferred.resolve({
                        wereLoaded: true
                    }).promise()
                }
                if (this._isVirtualMode()) {
                    this._renderVirtualNodes($container).done(function(items) {
                        deferred.resolve({
                            wereLoaded: items && items.length,
                            newLoaded: true
                        })
                    })
                } else {
                    var itemElement = $container.parent().find(">." + ITEM_CLASS),
                        node = this._getNodeByItemElement(itemElement),
                        nestedItems = this._getChildNodes(node);
                    this._renderItems($container, nestedItems);
                    deferred.resolve({
                        wereLoaded: true,
                        newLoaded: true
                    })
                }
                return deferred.promise()
            },
            _renderVirtualNodes: function($container) {
                var $node = $container.parent(),
                    node = this._getNodeByItemElement($node.find(">." + ITEM_CLASS)),
                    that = this;
                this._filter.internal = [this.option("parentIdExpr"), node.internalFields.key];
                this._dataSource.filter(this._combineFilter());
                return this._dataSource.load().done(function(data) {
                    var virtualNodes = that._getVirtualNodes(data);
                    that._renderItems($container, virtualNodes);
                    if (virtualNodes.length && !node.internalFields.selected) {
                        var $firstChild = that._getNodeElement(virtualNodes[0]);
                        that._updateParentsState(virtualNodes[0], $firstChild)
                    }
                    that._normalizeIconState($node, virtualNodes.length)
                })
            },
            _getVirtualNodes: function(items) {
                var that = this,
                    virtualNodes = [];
                $.each(items, function(_, item) {
                    var virtualNode = that._dataAdapter.getNodeByItem(item);
                    virtualNode && virtualNodes.push(virtualNode)
                });
                return virtualNodes
            },
            _normalizeIconState: function($node, hasNewItems) {
                var $icon, $loadIndicator = $node.find(".dx-loadindicator");
                $loadIndicator.length && LoadIndicator.getInstance($loadIndicator).option("visible", false);
                if (hasNewItems) {
                    $icon = $node.find("." + TOGGLE_ITEM_VISIBILITY_CLASS);
                    $icon.show();
                    return
                }
                $node.find("." + TOGGLE_ITEM_VISIBILITY_CLASS).removeClass(TOGGLE_ITEM_VISIBILITY_CLASS);
                $node.addClass(IS_LEAF)
            },
            _renderContent: function() {
                this._renderEmptyMessage();
                var items = this.option("items");
                if (!items || !items.length) {
                    return
                }
                if (items.length) {
                    this._contentAlreadyRendered = true
                }
                this.callBase()
            },
            _renderSelectAllItem: function($container) {
                $container = $container || this.element().find("." + NODE_CONTAINER_CLASS).first();
                this._$selectAllItem = $("<div>").addClass(SELECT_ALL_ITEM_CLASS);
                var value = this._dataAdapter.isAllSelected();
                this._createComponent(this._$selectAllItem, CheckBox, {
                    value: value,
                    text: this.option("selectAllText"),
                    onValueChanged: $.proxy(this._toggleSelectAll, this)
                });
                this._toggleSelectedClass(this._$selectAllItem, value);
                $container.before(this._$selectAllItem)
            },
            _toggleSelectAll: function(args) {
                this._dataAdapter.toggleSelectAll(args.value);
                this._updateItemsUI();
                this._fireSelectionChanged()
            },
            _renderCheckBox: function($node, node) {
                $node.addClass(ITEM_WITH_CHECKBOX_CLASS);
                var $checkbox = $("<div>").appendTo($node);
                this._createComponent($checkbox, CheckBox, {
                    value: node.internalFields.selected,
                    onValueChanged: $.proxy(this._changeCheckboxValue, this),
                    focusStateEnabled: false,
                    disabled: this._disabledGetter(node)
                })
            },
            _toggleSelectedClass: function($node, value) {
                $node.toggleClass(SELECTED_ITEM_CLASS, !!value)
            },
            _toggleNodeDisabledState: function(node, state) {
                var $node = this._getNodeElement(node),
                    $item = $node.find("." + ITEM_CLASS).eq(0);
                this._dataAdapter.toggleNodeDisabledState(node.internalFields.key, state);
                $item.toggleClass(DISABLED_STATE_CLASS, !!state);
                if (this._showCheckboxes()) {
                    var checkbox = this._getCheckBoxInstance($node);
                    checkbox.option("disabled", !!state)
                }
            },
            _itemOptionChanged: function(item, property, value) {
                var node = this._dataAdapter.getNodeByItem(item);
                switch (property) {
                    case this.option("disabledExpr"):
                        this._toggleNodeDisabledState(node, value)
                }
            },
            _changeCheckboxValue: function(e) {
                var $node = e.element.parent("." + NODE_CLASS),
                    item = this._getItemData($node.find("> ." + ITEM_CLASS)),
                    node = this._dataAdapter.getNodeByItem(item),
                    value = e.value;
                if (node.internalFields.selected === value) {
                    return
                }
                this._updateItemSelection(value, item, e.jQueryEvent)
            },
            _isSingleSelection: function() {
                return "single" === this.option("selectionMode")
            },
            _updateItemSelection: function(value, itemElement, jQueryEvent) {
                var node = this._getNodeByItemElement(itemElement);
                if (!node || node.internalFields.selected === value) {
                    return
                }
                if (this._isSingleSelection()) {
                    this._toggleSelectAll({
                        value: false
                    })
                }
                this._dataAdapter.toggleSelection(node.internalFields.key, value);
                this._updateItemsUI();
                if (jQueryEvent) {
                    this._itemJQueryEventHandler(jQueryEvent, "onItemSelectionChanged", {
                        node: this._dataAdapter.getPublicNode(node)
                    })
                } else {
                    this._fireOnSelectedEvent(node)
                }
                this._fireSelectionChanged()
            },
            _fireOnSelectedEvent: function(node) {
                var handler = this.option("onItemSelectionChanged");
                if (handler) {
                    handler.call(this, {
                        itemData: node.internalFields.item,
                        node: this._dataAdapter.getPublicNode(node)
                    })
                }
            },
            _getCheckBoxInstance: function($node) {
                return $node.find("> .dx-checkbox").dxCheckBox("instance")
            },
            _updateItemsUI: function() {
                var that = this;
                $.each(this._dataAdapter.getData(), function(_, node) {
                    var $node = that._getNodeElement(node),
                        nodeSelection = node.internalFields.selected;
                    if (!$node.length) {
                        return
                    }
                    that._toggleSelectedClass($node, nodeSelection);
                    that.setAria("selected", nodeSelection, $node);
                    if (that._showCheckboxes()) {
                        var checkbox = that._getCheckBoxInstance($node);
                        checkbox.option("value", nodeSelection)
                    }
                });
                if (this._selectAllEnabled()) {
                    this._$selectAllItem.dxCheckBox("instance").option("value", this._dataAdapter.isAllSelected())
                }
            },
            _updateParentsState: function(node, $node) {
                var parentValue, $parentNode, parentNode = this._dataAdapter.getNodeByKey(node.internalFields.parentKey);
                if ($node && this._showCheckboxes()) {
                    parentValue = parentNode.internalFields.selected;
                    $parentNode = $($node.parents("." + NODE_CLASS)[0]);
                    this._getCheckBoxInstance($parentNode).option("value", parentValue);
                    this._toggleSelectedClass($parentNode, parentValue)
                }
                if (parentNode.internalFields.parentKey !== this.option("rootValue")) {
                    this._updateParentsState(parentNode, $parentNode)
                }
            },
            _itemEventHandlerImpl: function(initiator, action, actionArgs) {
                var $itemElement = $(initiator).closest("." + NODE_CLASS).find("> ." + ITEM_CLASS);
                return action($.extend(this._extendActionArgs($itemElement), actionArgs))
            },
            _itemContextMenuHandler: function(e) {
                this._createEventHandler("onItemContextMenu", e)
            },
            _itemHoldHandler: function(e) {
                this._createEventHandler("onItemHold", e)
            },
            _createEventHandler: function(eventName, e) {
                var itemData = this._getItemData(e.currentTarget),
                    node = this._dataAdapter.getNodeByItem(itemData);
                this._itemJQueryEventHandler(e, eventName, {
                    node: this._dataAdapter.getPublicNode(node)
                })
            },
            _itemClass: function() {
                return ITEM_CLASS
            },
            _itemDataKey: function() {
                return ITEM_DATA_KEY
            },
            _selectionEnabled: function() {
                return true
            },
            _attachClickEvent: function() {
                var that = this,
                    itemSelector = that._itemSelector(),
                    eventName = eventUtils.addNamespace(clickEvent.name, that.NAME),
                    pointerDownEvent = eventUtils.addNamespace(pointerEvents.down, this.NAME);
                that._itemContainer().off(eventName, itemSelector).off(pointerDownEvent, itemSelector).on(eventName, itemSelector, function(e) {
                    that._itemClickHandler(e, $(this))
                }).on(pointerDownEvent, itemSelector, function(e) {
                    that._itemPointerDownHandler(e)
                })
            },
            _itemClickHandler: function(e, $item) {
                var itemData = this._getItemData($item),
                    node = this._dataAdapter.getNodeByItem(itemData);
                this._itemJQueryEventHandler(e, "onItemClick", {
                    node: this._dataAdapter.getPublicNode(node)
                });
                if (this.option("selectByClick")) {
                    this._updateItemSelection(!node.internalFields.selected, itemData)
                }
            },
            _updateSelectionToFirstItem: function($items, startIndex) {
                var itemIndex = startIndex;
                while (itemIndex >= 0) {
                    var $item = $($items[itemIndex]);
                    this._updateItemSelection(true, $item.find("." + ITEM_CLASS).get(0), true, $item);
                    itemIndex--
                }
            },
            _updateSelectionToLastItem: function($items, startIndex) {
                var itemIndex = startIndex,
                    length = $items.length;
                while (itemIndex < length) {
                    var $item = $($items[itemIndex]);
                    this._updateItemSelection(true, $item.find("." + ITEM_CLASS).get(0), true, $item);
                    itemIndex++
                }
            },
            _focusInHandler: function(e) {
                var currentTarget = e.currentTarget,
                    focusTargets = this._focusTarget();
                if ($.inArray(currentTarget, focusTargets) !== -1) {
                    this._toggleFocusClass(true, currentTarget)
                }
                if (this.option("focusedElement")) {
                    this._setFocusedItem(this.option("focusedElement"));
                    return
                }
                var $activeItem = this._getActiveItem();
                this.option("focusedElement", $activeItem.closest("." + NODE_CLASS))
            },
            _setFocusedItem: function($target) {
                if (!$target || !$target.length) {
                    return
                }
                if (!$target.children().hasClass(DISABLED_STATE_CLASS)) {
                    this.callBase($target)
                }
                this._scrollableContainer.scrollToElement($target.find("." + ITEM_CLASS).first())
            },
            _itemPointerDownHandler: function(e) {
                if (!this.option("focusStateEnabled")) {
                    return
                }
                var $target = $(e.target).closest("." + NODE_CLASS);
                if (!$target.hasClass(NODE_CLASS)) {
                    return
                }
                var itemElement = $target.hasClass(DISABLED_STATE_CLASS) ? null : $target;
                this.option("focusedElement", itemElement)
            },
            _findNonDisabledNodes: function($nodes) {
                return $nodes.not(function() {
                    return $(this).find(">." + ITEM_CLASS).hasClass(DISABLED_STATE_CLASS)
                })
            },
            _moveFocus: function(location, e) {
                var FOCUS_UP = "up",
                    FOCUS_DOWN = "down",
                    FOCUS_FIRST = "first",
                    FOCUS_LAST = "last",
                    FOCUS_LEFT = this.option("rtlEnabled") ? "right" : "left",
                    FOCUS_RIGHT = this.option("rtlEnabled") ? "left" : "right";
                this.element().find("." + NODE_CONTAINER_CLASS).each(function() {
                    fx.stop(this, true)
                });
                var $items = this._findNonDisabledNodes(this._nodeElements());
                if (!$items || !$items.length) {
                    return
                }
                switch (location) {
                    case FOCUS_UP:
                        var $prevItem = this._prevItem($items);
                        this.option("focusedElement", $prevItem);
                        if (e.shiftKey && this._showCheckboxes()) {
                            this._updateItemSelection(true, $prevItem.find("." + ITEM_CLASS).get(0), true, $prevItem)
                        }
                        break;
                    case FOCUS_DOWN:
                        var $nextItem = this._nextItem($items);
                        this.option("focusedElement", $nextItem);
                        if (e.shiftKey && this._showCheckboxes()) {
                            this._updateItemSelection(true, $nextItem.find("." + ITEM_CLASS).get(0), true, $nextItem)
                        }
                        break;
                    case FOCUS_FIRST:
                        var $firstItem = $items.first();
                        if (e.shiftKey && this._showCheckboxes()) {
                            this._updateSelectionToFirstItem($items, $items.index(this._prevItem($items)))
                        }
                        this.option("focusedElement", $firstItem);
                        break;
                    case FOCUS_LAST:
                        var $lastItem = $items.last();
                        if (e.shiftKey && this._showCheckboxes()) {
                            this._updateSelectionToLastItem($items, $items.index(this._nextItem($items)))
                        }
                        this.option("focusedElement", $lastItem);
                        break;
                    case FOCUS_RIGHT:
                        this._expandFocusedContainer();
                        break;
                    case FOCUS_LEFT:
                        this._collapseFocusedContainer();
                        break;
                    default:
                        this.callBase.apply(this, arguments);
                        return
                }
            },
            _nodeElements: function() {
                return this.element().find("." + NODE_CLASS).not(":hidden")
            },
            _expandFocusedContainer: function() {
                var $focusedItem = this.option("focusedElement");
                if (!$focusedItem || $focusedItem.hasClass(IS_LEAF)) {
                    return
                }
                var $node = $focusedItem.find("." + NODE_CONTAINER_CLASS).eq(0);
                if ($node.hasClass(OPENED_NODE_CONTAINER_CLASS)) {
                    this.option("focusedElement", this._nextItem(this._findNonDisabledNodes(this._nodeElements())));
                    return
                }
                var node = this._getNodeByItemElement($focusedItem.find(">." + ITEM_CLASS));
                this._toggleExpandedState(node, true)
            },
            _getClosestNonDisabledNode: function($node) {
                do {
                    $node = $node.parent().closest("." + NODE_CLASS)
                } while ($node.children(".dx-treeview-item.dx-state-disabled").length);
                return $node
            },
            _collapseFocusedContainer: function() {
                var $focusedItem = this.option("focusedElement");
                if (!$focusedItem) {
                    return
                }
                var nodeElement = $focusedItem.find("." + NODE_CONTAINER_CLASS).eq(0);
                if (!$focusedItem.hasClass(IS_LEAF) && nodeElement.hasClass(OPENED_NODE_CONTAINER_CLASS)) {
                    var node = this._getNodeByItemElement($focusedItem.find(">." + ITEM_CLASS));
                    this._toggleExpandedState(node, false)
                } else {
                    var collapsedNode = this._getClosestNonDisabledNode($focusedItem);
                    collapsedNode.length && this.option("focusedElement", collapsedNode)
                }
            },
            updateDimensions: function() {
                var that = this,
                    deferred = $.Deferred();
                if (that._scrollableContainer) {
                    that._scrollableContainer.update().done(function() {
                        deferred.resolveWith(that)
                    })
                } else {
                    deferred.resolveWith(that)
                }
                return deferred.promise()
            },
            selectItem: function(itemElement) {
                this._updateItemSelection(true, itemElement)
            },
            unselectItem: function(itemElement) {
                this._updateItemSelection(false, itemElement)
            },
            expandItem: function(itemElement) {
                this._toggleExpandedState(itemElement, true)
            },
            collapseItem: function(itemElement) {
                this._toggleExpandedState(itemElement, false)
            },
            getNodes: function() {
                return this._dataAdapter.getTreeNodes()
            },
            selectAll: function() {
                if (this._selectAllEnabled()) {
                    this._$selectAllItem.dxCheckBox("instance").option("value", true)
                } else {
                    this._toggleSelectAll({
                        value: true
                    })
                }
            },
            unselectAll: function() {
                if (this._selectAllEnabled()) {
                    this._$selectAllItem.dxCheckBox("instance").option("value", false)
                } else {
                    this._toggleSelectAll({
                        value: false
                    })
                }
            },
            collapseAll: function() {
                var that = this;
                $.each(this._dataAdapter.getExpandedNodesKeys(), function(_, key) {
                    that._toggleExpandedState(key, false)
                })
            }
        });
        registerComponent("dxTreeView", TreeView);
        module.exports = TreeView
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.grouping_module.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            ExpandedGroupingHelper = __webpack_require__( /*! ./ui.data_grid.grouping.server */ 358).GroupingHelper,
            CollapsedGroupingHelper = __webpack_require__( /*! ./ui.data_grid.grouping.client */ 360).GroupingHelper,
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dataSourceAdapter = __webpack_require__( /*! ./ui.data_grid.data_source_adapter */ 344),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../../core/devices */ 40);
        var DATAGRID_GROUP_PANEL_CLASS = "dx-datagrid-group-panel",
            DATAGRID_GROUP_PANEL_MESSAGE_CLASS = "dx-group-panel-message",
            DATAGRID_GROUP_PANEL_ITEM_CLASS = "dx-group-panel-item",
            DATAGRID_GROUP_OPENED_CLASS = "dx-datagrid-group-opened",
            DATAGRID_GROUP_CLOSED_CLASS = "dx-datagrid-group-closed",
            DATAGRID_EXPAND_CLASS = "dx-datagrid-expand",
            DATAGRID_SELECTION_DISABLED_CLASS = "dx-selection-disabled",
            DATAGRID_GROUP_ROW_CLASS = "dx-group-row";
        var GroupingDataSourceAdapterExtender = function() {
            return {
                init: function() {
                    this.callBase.apply(this, arguments);
                    this._initGroupingHelper()
                },
                _initGroupingHelper: function(options) {
                    var grouping = this._grouping,
                        remoteOperations = options ? options.remoteOperations : this.remoteOperations();
                    if (remoteOperations.filtering && remoteOperations.sorting && remoteOperations.paging && !remoteOperations.grouping) {
                        if (!grouping || grouping instanceof CollapsedGroupingHelper) {
                            this._grouping = new ExpandedGroupingHelper(this)
                        }
                    } else {
                        if (!grouping || grouping instanceof ExpandedGroupingHelper) {
                            this._grouping = new CollapsedGroupingHelper(this)
                        }
                    }
                },
                totalItemsCount: function() {
                    var that = this,
                        totalCount = that.callBase();
                    return totalCount > 0 && that._dataSource.group() && that._dataSource.requireTotalCount() ? totalCount + that._grouping.totalCountCorrection() : totalCount
                },
                itemsCount: function() {
                    return this._dataSource.group() ? this._grouping.itemsCount() || 0 : this.callBase()
                },
                allowCollapseAll: function() {
                    return this._grouping.allowCollapseAll()
                },
                isRowExpanded: function(key) {
                    var groupInfo = this._grouping.findGroupInfo(key);
                    return groupInfo ? groupInfo.isExpanded : !this._grouping.allowCollapseAll()
                },
                collapseAll: function(groupIndex) {
                    return this._collapseExpandAll(groupIndex, false)
                },
                expandAll: function(groupIndex) {
                    return this._collapseExpandAll(groupIndex, true)
                },
                _collapseExpandAll: function(groupIndex, isExpand) {
                    var i, that = this,
                        dataSource = that._dataSource,
                        group = dataSource.group(),
                        groups = gridCore.normalizeSortingInfo(group || []);
                    if (groups.length) {
                        for (i = 0; i < groups.length; i++) {
                            if (void 0 === groupIndex || groupIndex === i) {
                                groups[i].isExpanded = isExpand
                            } else {
                                if (group && group[i]) {
                                    groups[i].isExpanded = group[i].isExpanded
                                }
                            }
                        }
                        dataSource.group(groups);
                        that._grouping.foreachGroups(function(groupInfo, parents) {
                            if (void 0 === groupIndex || groupIndex === parents.length - 1) {
                                groupInfo.isExpanded = isExpand
                            }
                        }, false, true)
                    }
                    return true
                },
                refresh: function() {
                    this.callBase.apply(this, arguments);
                    return this._grouping.refresh.apply(this._grouping, arguments)
                },
                changeRowExpand: function(path) {
                    var that = this,
                        dataSource = that._dataSource;
                    if (dataSource.group()) {
                        dataSource._changeLoadingCount(1);
                        return that._changeRowExpandCore(path).always(function() {
                            dataSource._changeLoadingCount(-1)
                        })
                    }
                },
                _changeRowExpandCore: function(path) {
                    return this._grouping.changeRowExpand(path)
                },
                getGroupsInfo: function() {
                    return this._grouping._groupsInfo
                },
                _hasCollapsedGroupLevels: function(group) {
                    if (group && $.isArray(group)) {
                        for (var i = 0; i < group.length; i++) {
                            if (false === group[i].isExpanded) {
                                return true
                            }
                        }
                    }
                },
                _customizeRemoteOperations: function(options) {
                    var remoteOperations = options.remoteOperations;
                    if (options.storeLoadOptions.group) {
                        if (remoteOperations.grouping && !options.isCustomLoading) {
                            remoteOperations.paging = false
                        }
                        if (!remoteOperations.grouping && (!remoteOperations.sorting || !remoteOperations.filtering || options.isCustomLoading || this._hasCollapsedGroupLevels(options.storeLoadOptions.group))) {
                            remoteOperations.paging = false
                        }
                    }
                    this.callBase.apply(this, arguments)
                },
                _handleDataLoading: function(options) {
                    this.callBase(options);
                    this._initGroupingHelper(options);
                    return this._grouping.handleDataLoading(options)
                },
                _handleDataLoaded: function(options) {
                    return this._grouping.handleDataLoaded(options, $.proxy(this.callBase, this))
                },
                _handleDataLoadedCore: function(options) {
                    return this._grouping.handleDataLoadedCore(options, $.proxy(this.callBase, this))
                }
            }
        }();
        dataSourceAdapter.extend(GroupingDataSourceAdapterExtender);
        var GroupingDataControllerExtender = function() {
            return {
                init: function() {
                    var that = this;
                    that.callBase();
                    that.createAction("onRowExpanding");
                    that.createAction("onRowExpanded");
                    that.createAction("onRowCollapsing");
                    that.createAction("onRowCollapsed")
                },
                _processItems: function(items, changeType) {
                    var groupColumns = this._columnsController.getGroupColumns();
                    if (items.length && groupColumns.length) {
                        items = this._processGroupItems(items, groupColumns.length)
                    }
                    return this.callBase(items, changeType)
                },
                _processItem: function(item, options) {
                    if (commonUtils.isDefined(item.groupIndex) && commonUtils.isString(item.rowType) && 0 === item.rowType.indexOf("group")) {
                        item = this._processGroupItem(item, options);
                        options.dataIndex = 0
                    } else {
                        item = this.callBase.apply(this, arguments)
                    }
                    return item
                },
                _processGroupItem: function(item, options) {
                    return item
                },
                _processGroupItems: function(items, groupsCount, options) {
                    var scrollingMode, i, item, resultItems, that = this,
                        groupedColumns = that._columnsController.getGroupColumns(),
                        column = groupedColumns[groupedColumns.length - groupsCount];
                    if (!options) {
                        scrollingMode = that.option("scrolling.mode");
                        options = {
                            collectContinuationItems: "virtual" !== scrollingMode && "infinite" !== scrollingMode,
                            resultItems: [],
                            path: [],
                            values: []
                        }
                    }
                    resultItems = options.resultItems;
                    if (options.data) {
                        if (options.collectContinuationItems || !options.data.isContinuation) {
                            resultItems.push({
                                rowType: "group",
                                data: options.data,
                                groupIndex: options.path.length - 1,
                                isExpanded: !!options.data.items,
                                key: options.path.slice(0),
                                values: options.values.slice(0)
                            })
                        }
                    }
                    if (items) {
                        if (0 === groupsCount) {
                            resultItems.push.apply(resultItems, items)
                        } else {
                            for (i = 0; i < items.length; i++) {
                                item = items[i];
                                if (item && "items" in item) {
                                    options.data = item;
                                    options.path.push(item.key);
                                    options.values.push(column && column.deserializeValue ? column.deserializeValue(item.key) : item.key);
                                    that._processGroupItems(item.items, groupsCount - 1, options);
                                    options.data = void 0;
                                    options.path.pop();
                                    options.values.pop()
                                } else {
                                    resultItems.push(item)
                                }
                            }
                        }
                    }
                    return resultItems
                },
                publicMethods: function() {
                    return this.callBase().concat(["collapseAll", "expandAll", "isRowExpanded", "expandRow", "collapseRow"])
                },
                collapseAll: function(groupIndex) {
                    var dataSource = this._dataSource;
                    if (dataSource && dataSource.collapseAll(groupIndex)) {
                        dataSource.pageIndex(0);
                        dataSource.reload()
                    }
                },
                expandAll: function(groupIndex) {
                    var dataSource = this._dataSource;
                    if (dataSource && dataSource.expandAll(groupIndex)) {
                        dataSource.pageIndex(0);
                        dataSource.reload()
                    }
                },
                changeRowExpand: function(key) {
                    var that = this,
                        expanded = that.isRowExpanded(key),
                        args = {
                            key: key,
                            expanded: expanded
                        };
                    that.executeAction(expanded ? "onRowCollapsing" : "onRowExpanding", args);
                    if (!args.cancel) {
                        return $.when(that._changeRowExpandCore(key)).done(function() {
                            args.expanded = !expanded;
                            that.executeAction(expanded ? "onRowCollapsed" : "onRowExpanded", args)
                        })
                    }
                },
                _changeRowExpandCore: function(key) {
                    var d, that = this,
                        dataSource = this._dataSource;
                    if (!dataSource) {
                        return
                    }
                    d = $.Deferred();
                    $.when(dataSource.changeRowExpand(key)).done(function() {
                        that.load().done(d.resolve).fail(d.reject)
                    }).fail(d.reject);
                    return d
                },
                isRowExpanded: function(key) {
                    var dataSource = this._dataSource;
                    return dataSource && dataSource.isRowExpanded(key)
                },
                expandRow: function(key) {
                    if (!this.isRowExpanded(key)) {
                        return this.changeRowExpand(key)
                    }
                    return $.Deferred().resolve()
                },
                collapseRow: function(key) {
                    if (this.isRowExpanded(key)) {
                        return this.changeRowExpand(key)
                    }
                    return $.Deferred().resolve()
                },
                optionChanged: function(args) {
                    if ("grouping" === args.name) {
                        args.name = "dataSource"
                    }
                    this.callBase(args)
                }
            }
        }();
        var onGroupingMenuItemClick = function(column, params) {
            var columnsController = this._columnsController;
            switch (params.itemData.value) {
                case "group":
                    var groups = columnsController._dataSource.group() || [];
                    columnsController.columnOption(column.dataField, "groupIndex", groups.length);
                    break;
                case "ungroup":
                    columnsController.columnOption(column.dataField, "groupIndex", -1);
                    break;
                case "ungroupAll":
                    this.component.clearGrouping()
            }
        };
        var GroupingHeaderPanelExtender = function() {
            return {
                _getToolbarItems: function() {
                    var items = this.callBase();
                    return this._appendGroupingItem(items)
                },
                _appendGroupingItem: function(items) {
                    var that = this;
                    if (that._isGroupPanelVisible()) {
                        var toolbarItem = {
                            template: function(data, index, $container) {
                                var $groupPanel = $("<div />").addClass(DATAGRID_GROUP_PANEL_CLASS).appendTo($container);
                                that._updateGroupPanelContent($groupPanel)
                            },
                            name: "groupPanel",
                            location: "before",
                            locateInMenu: "never"
                        };
                        items.push(toolbarItem)
                    }
                    return items
                },
                _updateGroupPanelContent: function($groupPanel) {
                    var that = this,
                        groupColumns = that.getController("columns").getGroupColumns(),
                        groupPanelOptions = that.option("groupPanel");
                    that._renderGroupPanelItems($groupPanel, groupColumns);
                    if (groupPanelOptions.allowColumnDragging && !groupColumns.length) {
                        $("<div />").addClass(DATAGRID_GROUP_PANEL_MESSAGE_CLASS).text(groupPanelOptions.emptyPanelText).appendTo($groupPanel)
                    }
                },
                _isGroupPanelVisible: function() {
                    var isVisible, groupPanelOptions = this.option("groupPanel");
                    if (groupPanelOptions) {
                        isVisible = groupPanelOptions.visible;
                        if ("auto" === isVisible) {
                            isVisible = "desktop" === devices.current().deviceType ? true : false
                        }
                    }
                    return isVisible
                },
                _renderGroupPanelItems: function($groupPanel, groupColumns) {
                    var that = this;
                    $groupPanel.empty();
                    $.each(groupColumns, function(index, groupColumn) {
                        that._createGroupPanelItem($groupPanel, groupColumn)
                    })
                },
                _createGroupPanelItem: function($rootElement, groupColumn) {
                    return $("<div />").addClass(groupColumn.cssClass).addClass(DATAGRID_GROUP_PANEL_ITEM_CLASS).data("columnData", groupColumn).appendTo($rootElement).text(groupColumn.caption)
                },
                _renderCore: function() {
                    if (this._toolbar) {
                        var $groupPanel = this.element().find("." + DATAGRID_GROUP_PANEL_CLASS);
                        if ($groupPanel.length) {
                            this._updateGroupPanelContent($groupPanel)
                        }
                    }
                    this.callBase()
                },
                allowDragging: function(column) {
                    var groupPanelOptions = this.option("groupPanel");
                    return this._isGroupPanelVisible() && groupPanelOptions.allowColumnDragging && column && column.allowGrouping
                },
                getColumnElements: function() {
                    var $element = this.element();
                    return $element && $element.find("." + DATAGRID_GROUP_PANEL_ITEM_CLASS)
                },
                getColumns: function() {
                    return this.getController("columns").getGroupColumns()
                },
                getBoundingRect: function() {
                    var offset, that = this,
                        $element = that.element();
                    if ($element && $element.find("." + DATAGRID_GROUP_PANEL_CLASS).length) {
                        offset = $element.offset();
                        return {
                            top: offset.top,
                            bottom: offset.top + $element.height()
                        }
                    }
                    return null
                },
                getName: function() {
                    return "group"
                },
                getContextMenuItems: function(options) {
                    var items, that = this,
                        contextMenuEnabled = that.option("grouping.contextMenuEnabled"),
                        $groupedColumnElement = options.targetElement.closest("." + DATAGRID_GROUP_PANEL_ITEM_CLASS);
                    if ($groupedColumnElement.length) {
                        options.column = $groupedColumnElement.data("columnData")
                    }
                    if (contextMenuEnabled && options.column) {
                        var column = options.column,
                            isGroupingAllowed = commonUtils.isDefined(column.allowGrouping) ? column.allowGrouping : true;
                        if (isGroupingAllowed) {
                            var isColumnGrouped = commonUtils.isDefined(column.groupIndex) && column.groupIndex > -1,
                                groupingTexts = that.option("grouping.texts"),
                                onItemClick = $.proxy(onGroupingMenuItemClick, that, column);
                            items = [{
                                text: groupingTexts.ungroup,
                                value: "ungroup",
                                disabled: !isColumnGrouped,
                                onItemClick: onItemClick
                            }, {
                                text: groupingTexts.ungroupAll,
                                value: "ungroupAll",
                                onItemClick: onItemClick
                            }]
                        }
                    }
                    return items
                },
                isVisible: function() {
                    return this.callBase() || this._isGroupPanelVisible()
                },
                optionChanged: function(args) {
                    if ("groupPanel" === args.name) {
                        this._invalidateToolbarItems();
                        args.handled = true
                    } else {
                        this.callBase(args)
                    }
                }
            }
        }();
        exports.GroupingHeaderPanelExtender = GroupingHeaderPanelExtender;
        var GroupingRowsViewExtender = function() {
            return {
                getContextMenuItems: function(options) {
                    var items, that = this,
                        contextMenuEnabled = that.option("grouping.contextMenuEnabled");
                    if (contextMenuEnabled && options.row && "group" === options.row.rowType) {
                        var columnsController = that._columnsController,
                            column = columnsController.columnOption("groupIndex:" + options.row.groupIndex);
                        if (column && column.allowGrouping) {
                            var groupingTexts = that.option("grouping.texts"),
                                onItemClick = $.proxy(onGroupingMenuItemClick, that, column);
                            items = [];
                            items.push({
                                text: groupingTexts.ungroup,
                                value: "ungroup",
                                onItemClick: onItemClick
                            }, {
                                text: groupingTexts.ungroupAll,
                                value: "ungroupAll",
                                onItemClick: onItemClick
                            })
                        }
                    }
                    return items
                },
                _rowClick: function(e) {
                    var that = this,
                        expandMode = that.option("grouping.expandMode"),
                        isGroupRowStateChanged = "rowClick" === expandMode && $(e.jQueryEvent.target).closest("." + DATAGRID_GROUP_ROW_CLASS).length,
                        isExpandButtonClicked = $(e.jQueryEvent.target).closest("." + DATAGRID_EXPAND_CLASS).length;
                    if (isGroupRowStateChanged || isExpandButtonClicked) {
                        that._changeGroupRowState(e)
                    }
                    that.callBase(e)
                },
                _changeGroupRowState: function(e) {
                    var dataController = this.getController("data"),
                        row = dataController.items()[e.rowIndex];
                    if ("detail" !== row.rowType) {
                        dataController.changeRowExpand(row.key);
                        e.jQueryEvent.preventDefault();
                        e.handled = true
                    }
                },
                _getCellTemplate: function(options) {
                    var that = this;
                    if ("expand" === options.column.command) {
                        return {
                            allowRenderToDetachedContainer: true,
                            render: function(container, options) {
                                if (commonUtils.isDefined(options.value) && !(options.data && options.data.isContinuation) && !options.row.inserted) {
                                    container.addClass(DATAGRID_EXPAND_CLASS).addClass(DATAGRID_SELECTION_DISABLED_CLASS);
                                    $("<div>").addClass(options.value ? DATAGRID_GROUP_OPENED_CLASS : DATAGRID_GROUP_CLOSED_CLASS).appendTo(container);
                                    that.setAria("label", options.value ? that.localize("dxDataGrid-ariaCollapse") : that.localize("dxDataGrid-ariaExpand"), container)
                                }
                            }
                        }
                    }
                    return that.callBase(options)
                }
            }
        }();
        var columnHeadersViewExtender = function() {
            return {
                getContextMenuItems: function(options) {
                    var that = this,
                        contextMenuEnabled = that.option("grouping.contextMenuEnabled"),
                        items = that.callBase(options);
                    if (contextMenuEnabled && options.row && "header" === options.row.rowType) {
                        var column = options.column;
                        if (!column.command && (!commonUtils.isDefined(column.allowGrouping) || column.allowGrouping)) {
                            var groupingTexts = that.option("grouping.texts"),
                                isColumnGrouped = commonUtils.isDefined(column.groupIndex) && column.groupIndex > -1,
                                onItemClick = $.proxy(onGroupingMenuItemClick, that, column);
                            items = items || [];
                            items.push({
                                text: groupingTexts.groupByThisColumn,
                                value: "group",
                                beginGroup: true,
                                disabled: isColumnGrouped,
                                onItemClick: onItemClick
                            });
                            if (column.showWhenGrouped) {
                                items.push({
                                    text: groupingTexts.ungroup,
                                    value: "ungroup",
                                    disabled: !isColumnGrouped,
                                    onItemClick: onItemClick
                                })
                            }
                            items.push({
                                text: groupingTexts.ungroupAll,
                                value: "ungroupAll",
                                onItemClick: onItemClick
                            })
                        }
                    }
                    return items
                }
            }
        }();
        gridCore.registerModule("grouping", {
            defaultOptions: function() {
                return {
                    grouping: {
                        autoExpandAll: true,
                        allowCollapsing: true,
                        contextMenuEnabled: false,
                        expandMode: "buttonClick",
                        texts: {
                            groupContinuesMessage: messageLocalization.format("dxDataGrid-groupContinuesMessage"),
                            groupContinuedMessage: messageLocalization.format("dxDataGrid-groupContinuedMessage"),
                            groupByThisColumn: messageLocalization.format("dxDataGrid-groupHeaderText"),
                            ungroup: messageLocalization.format("dxDataGrid-ungroupHeaderText"),
                            ungroupAll: messageLocalization.format("dxDataGrid-ungroupAllText")
                        }
                    },
                    groupPanel: {
                        visible: false,
                        emptyPanelText: messageLocalization.format("dxDataGrid-groupPanelEmptyText"),
                        allowColumnDragging: true
                    }
                }
            },
            extenders: {
                controllers: {
                    data: GroupingDataControllerExtender
                },
                views: {
                    headerPanel: GroupingHeaderPanelExtender,
                    rowsView: GroupingRowsViewExtender,
                    columnHeadersView: columnHeadersViewExtender
                }
            }
        })
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.grouping.server.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            toComparable = __webpack_require__( /*! ../../core/utils/data */ 36).toComparable,
            dataUtils = __webpack_require__( /*! ../../data/utils */ 137),
            Store = __webpack_require__( /*! ../../data/abstract_store */ 156),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            normalizeSortingInfo = gridCore.normalizeSortingInfo,
            groupingCore = __webpack_require__( /*! ./ui.data_grid.grouping.core */ 359),
            createGroupFilter = groupingCore.createGroupFilter,
            dataQuery = __webpack_require__( /*! ../../data/query */ 158);
        var loadTotalCount = function(dataSource, options) {
            var d = $.Deferred(),
                loadOptions = $.extend({
                    skip: 0,
                    take: 1,
                    requireTotalCount: true
                }, options);
            dataSource.load(loadOptions).done(function(data, extra) {
                d.resolve(extra && extra.totalCount)
            }).fail($.proxy(d.reject, d));
            return d
        };
        exports.loadTotalCount = loadTotalCount;
        exports.GroupingHelper = groupingCore.GroupingHelper.inherit(function() {
            var foreachCollapsedGroups = function(that, callback, updateOffsets) {
                return that.foreachGroups(function(groupInfo) {
                    if (!groupInfo.isExpanded) {
                        return callback(groupInfo)
                    }
                }, false, false, updateOffsets, true)
            };
            var correctSkipLoadOption = function(that, skip) {
                var skipCorrection = 0,
                    resultSkip = skip || 0;
                if (skip) {
                    foreachCollapsedGroups(that, function(groupInfo) {
                        if (groupInfo.offset - skipCorrection >= skip) {
                            return false
                        }
                        skipCorrection += groupInfo.count - 1
                    });
                    resultSkip += skipCorrection
                }
                return resultSkip
            };
            var processGroupItems = function(that, items, path, offset, skipFirstItem, take) {
                var i, item, offsetInfo, removeLastItemsCount = 0,
                    needRemoveFirstItem = false;
                for (i = 0; i < items.length; i++) {
                    item = items[i];
                    if (void 0 !== item.items) {
                        path.push(item.key);
                        var groupInfo = that.findGroupInfo(path);
                        if (groupInfo && !groupInfo.isExpanded) {
                            item.collapsedItems = item.items;
                            item.items = null;
                            offset += groupInfo.count;
                            take--;
                            if (take < 0) {
                                removeLastItemsCount++
                            }
                            if (skipFirstItem) {
                                needRemoveFirstItem = true
                            }
                        } else {
                            if (item.items) {
                                offsetInfo = processGroupItems(that, item.items, path, offset, skipFirstItem, take);
                                if (skipFirstItem) {
                                    if (offsetInfo.offset - offset > 1) {
                                        item.isContinuation = true
                                    } else {
                                        needRemoveFirstItem = true
                                    }
                                }
                                offset = offsetInfo.offset;
                                take = offsetInfo.take;
                                if (take < 0) {
                                    if (item.items.length) {
                                        item.isContinuationOnNextPage = true
                                    } else {
                                        removeLastItemsCount++
                                    }
                                }
                            }
                        }
                        path.pop()
                    } else {
                        if (skipFirstItem) {
                            needRemoveFirstItem = true
                        }
                        offset++;
                        take--;
                        if (take < 0) {
                            removeLastItemsCount++
                        }
                    }
                    skipFirstItem = false
                }
                if (needRemoveFirstItem) {
                    items.splice(0, 1)
                }
                if (removeLastItemsCount) {
                    items.splice(-removeLastItemsCount, removeLastItemsCount)
                }
                return {
                    offset: offset,
                    take: take
                }
            };
            var pathEquals = function(path1, path2) {
                var i;
                if (path1.length !== path2.length) {
                    return false
                }
                for (i = 0; i < path1.length; i++) {
                    if (!dataUtils.keysEqual(null, path1[i], path2[i])) {
                        return false
                    }
                }
                return true
            };
            var updateGroupOffsets = function(that, items, path, offset, additionalGroupInfo) {
                var i, item;
                if (!items) {
                    return
                }
                for (i = 0; i < items.length; i++) {
                    item = items[i];
                    if ("key" in item && void 0 !== item.items) {
                        path.push(item.key);
                        if (additionalGroupInfo && pathEquals(additionalGroupInfo.path, path) && !item.isContinuation) {
                            additionalGroupInfo.offset = offset
                        }
                        var groupInfo = that.findGroupInfo(path);
                        if (groupInfo && !item.isContinuation) {
                            groupInfo.offset = offset
                        }
                        if (groupInfo && !groupInfo.isExpanded) {
                            offset += groupInfo.count
                        } else {
                            offset = updateGroupOffsets(that, item.items, path, offset, additionalGroupInfo)
                        }
                        path.pop()
                    } else {
                        offset++
                    }
                }
                return offset
            };
            var removeGroupLoadOption = function(storeLoadOptions, loadOptions) {
                var groups, sorts;
                if (loadOptions.group) {
                    groups = normalizeSortingInfo(loadOptions.group);
                    sorts = normalizeSortingInfo(storeLoadOptions.sort);
                    storeLoadOptions.sort = Store.arrangeSortingInfo(groups, sorts);
                    delete loadOptions.group
                }
            };
            var createNotGroupFilter = function(path, storeLoadOptions, group) {
                var i, j, filterElement, groups = normalizeSortingInfo(group || storeLoadOptions.group),
                    filter = [];
                for (i = 0; i < path.length; i++) {
                    filterElement = [];
                    for (j = 0; j <= i; j++) {
                        filterElement.push([groups[j].selector, i === j ? "<>" : "=", path[j]])
                    }
                    filter.push(gridCore.combineFilters(filterElement))
                }
                filter = gridCore.combineFilters(filter, "or");
                return gridCore.combineFilters([filter, storeLoadOptions.filter])
            };
            var createOffsetFilter = function(path, storeLoadOptions) {
                var i, j, filterElement, groups = normalizeSortingInfo(storeLoadOptions.group),
                    filter = [];
                for (i = 0; i < path.length; i++) {
                    filterElement = [];
                    for (j = 0; j <= i; j++) {
                        filterElement.push([groups[j].selector, i === j ? groups[j].desc ? ">" : "<" : "=", path[j]])
                    }
                    filter.push(gridCore.combineFilters(filterElement))
                }
                filter = gridCore.combineFilters(filter, "or");
                return gridCore.combineFilters([filter, storeLoadOptions.filter])
            };
            var getGroupCount = function(item, groupCount) {
                var i, count = item.count || item.items.length;
                if (!item.count && groupCount > 1) {
                    count = 0;
                    for (i = 0; i < item.items.length; i++) {
                        count += getGroupCount(item.items[i], groupCount - 1)
                    }
                }
                return count
            };
            return {
                handleDataLoading: function(options) {
                    var loadOptions, take, that = this,
                        storeLoadOptions = options.storeLoadOptions,
                        collapsedGroups = [],
                        collapsedItemsCount = 0,
                        skipFirstItem = false,
                        group = options.loadOptions.group,
                        skipCorrection = 0;
                    removeGroupLoadOption(storeLoadOptions, options.loadOptions);
                    options.group = options.group || group;
                    if (options.isCustomLoading) {
                        return
                    }
                    loadOptions = $.extend({}, storeLoadOptions);
                    loadOptions.skip = correctSkipLoadOption(that, storeLoadOptions.skip);
                    if (loadOptions.skip && loadOptions.take && group) {
                        loadOptions.skip--;
                        loadOptions.take++;
                        skipFirstItem = true
                    }
                    if (loadOptions.take && group) {
                        take = loadOptions.take;
                        loadOptions.take++
                    }
                    foreachCollapsedGroups(that, function(groupInfo) {
                        if (groupInfo.offset >= loadOptions.skip + loadOptions.take + skipCorrection) {
                            return false
                        } else {
                            if (groupInfo.offset >= loadOptions.skip + skipCorrection && groupInfo.count) {
                                skipCorrection += groupInfo.count - 1;
                                collapsedGroups.push(groupInfo);
                                collapsedItemsCount += groupInfo.count
                            }
                        }
                    });
                    $.each(collapsedGroups, function() {
                        loadOptions.filter = createNotGroupFilter(this.path, loadOptions, group)
                    });
                    options.storeLoadOptions = loadOptions;
                    options.collapsedGroups = collapsedGroups;
                    options.collapsedItemsCount = collapsedItemsCount;
                    options.skip = loadOptions.skip || 0;
                    options.skipFirstItem = skipFirstItem;
                    options.take = take
                },
                handleDataLoaded: function(options, callBase) {
                    var pathIndex, query, that = this,
                        data = options.data,
                        collapsedGroups = options.collapsedGroups,
                        groups = normalizeSortingInfo(options.group),
                        groupCount = groups.length;

                    function appendCollapsedPath(data, path, groups, collapsedGroup, offset) {
                        if (!data || !path.length || !groups.length) {
                            return
                        }
                        var i, keyValue, pathValue = toComparable(path[0], true);
                        for (i = 0; i < data.length; i++) {
                            keyValue = toComparable(data[i].key, true);
                            if (offset >= collapsedGroup.offset || pathValue === keyValue) {
                                break
                            } else {
                                offset += getGroupCount(data[i], groups.length)
                            }
                        }
                        if (!data.length || pathValue !== keyValue) {
                            data.splice(i, 0, {
                                key: path[0],
                                items: [],
                                count: 1 === path.length ? collapsedGroup.count : void 0
                            })
                        }
                        appendCollapsedPath(data[i].items, path.slice(1), groups.slice(1), collapsedGroup, offset)
                    }
                    callBase(options);
                    if (groupCount) {
                        query = dataQuery(data);
                        Store.multiLevelGroup(query, groups).enumerate().done(function(groupedData) {
                            data = groupedData
                        });
                        if (collapsedGroups) {
                            for (pathIndex = 0; pathIndex < collapsedGroups.length; pathIndex++) {
                                appendCollapsedPath(data, collapsedGroups[pathIndex].path, groups, collapsedGroups[pathIndex], options.skip)
                            }
                        }
                        if (!options.isCustomLoading) {
                            processGroupItems(that, data, [], options.skip, options.skipFirstItem, options.take);
                            that.updateItemsCount(data, groupCount)
                        }
                        options.data = data;
                        if (options.collapsedItemsCount && options.extra && options.extra.totalCount >= 0) {
                            options.extra.totalCount += options.collapsedItemsCount
                        }
                    }
                },
                updateTotalItemsCount: function() {
                    var itemsCountCorrection = 0;
                    foreachCollapsedGroups(this, function(groupInfo) {
                        if (groupInfo.count) {
                            itemsCountCorrection -= groupInfo.count - 1
                        }
                    });
                    this.callBase(itemsCountCorrection)
                },
                changeRowExpand: function(path) {
                    var groupCountQuery, that = this,
                        dataSource = that._dataSource,
                        beginPageIndex = dataSource.beginPageIndex ? dataSource.beginPageIndex() : dataSource.pageIndex(),
                        dataSourceItems = dataSource.items(),
                        offset = correctSkipLoadOption(that, beginPageIndex * dataSource.pageSize()),
                        groupInfo = that.findGroupInfo(path);
                    if (groupInfo && !groupInfo.isExpanded) {
                        groupCountQuery = $.Deferred().resolve(groupInfo.count)
                    } else {
                        groupCountQuery = loadTotalCount(dataSource, {
                            filter: createGroupFilter(path, {
                                filter: dataSource.filter(),
                                group: dataSource.group()
                            })
                        })
                    }
                    return $.when(groupCountQuery).done(function(count) {
                        count = parseInt(count.length ? count[0] : count);
                        if (groupInfo) {
                            updateGroupOffsets(that, dataSourceItems, [], offset);
                            groupInfo.isExpanded = !groupInfo.isExpanded;
                            groupInfo.count = count
                        } else {
                            groupInfo = {
                                offset: -1,
                                count: count,
                                path: path,
                                isExpanded: false
                            };
                            updateGroupOffsets(that, dataSourceItems, [], offset, groupInfo);
                            if (groupInfo.offset >= 0) {
                                that.addGroupInfo(groupInfo)
                            }
                        }
                        that.updateTotalItemsCount()
                    }).fail(function() {
                        dataSource.fireEvent("loadError", arguments)
                    })
                },
                allowCollapseAll: function() {
                    return false
                },
                refresh: function(options, isReload, operationTypes) {
                    var that = this,
                        storeLoadOptions = options.storeLoadOptions,
                        dataSource = that._dataSource;
                    this.callBase.apply(this, arguments);
                    if (isReload || operationTypes.reload) {
                        return foreachCollapsedGroups(that, function(groupInfo) {
                            var groupCountQuery = loadTotalCount(dataSource, {
                                    filter: createGroupFilter(groupInfo.path, storeLoadOptions)
                                }),
                                groupOffsetQuery = loadTotalCount(dataSource, {
                                    filter: createOffsetFilter(groupInfo.path, storeLoadOptions)
                                });
                            return $.when(groupOffsetQuery, groupCountQuery).done(function(offset, count) {
                                offset = parseInt(offset.length ? offset[0] : offset);
                                count = parseInt(count.length ? count[0] : count);
                                groupInfo.offset = offset;
                                if (groupInfo.count !== count) {
                                    groupInfo.count = count;
                                    that.updateTotalItemsCount()
                                }
                            })
                        }, true)
                    }
                }
            }
        }())
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.grouping.core.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            normalizeSortingInfo = __webpack_require__( /*! ../../data/utils */ 137).normalizeSortingInfo;
        exports.createGroupFilter = function(path, storeLoadOptions) {
            var i, groups = normalizeSortingInfo(storeLoadOptions.group),
                filter = [];
            for (i = 0; i < path.length; i++) {
                filter.push([groups[i].selector, "=", path[i]])
            }
            if (storeLoadOptions.filter) {
                filter.push(storeLoadOptions.filter)
            }
            return gridCore.combineFilters(filter)
        };
        exports.GroupingHelper = Class.inherit(function() {
            var findGroupInfoByKey = function(groupsInfo, key) {
                var hash = groupsInfo.hash;
                return hash && hash[key]
            };
            var getGroupInfoIndexByOffset = function(groupsInfo, offset) {
                var index;
                for (index = 0; index < groupsInfo.length; index++) {
                    if (groupsInfo[index].offset > offset) {
                        break
                    }
                }
                return index
            };
            var updateGroupInfoOffsets = function(groupsInfo, parents) {
                var groupInfo, index, newIndex;
                for (index = 0; index < groupsInfo.length; index++) {
                    groupInfo = groupsInfo[index];
                    if (groupInfo.data && groupInfo.data.offset !== groupInfo.offset) {
                        groupsInfo.splice(index, 1);
                        groupInfo.offset = groupInfo.data.offset;
                        if (parents) {
                            for (var parentIndex = 0; parentIndex < parents.length; parentIndex++) {
                                parents[parentIndex].offset = groupInfo.offset
                            }
                        }
                        newIndex = getGroupInfoIndexByOffset(groupsInfo, groupInfo.offset);
                        groupsInfo.splice(newIndex, 0, groupInfo);
                        if (newIndex > index) {
                            index--
                        }
                    }
                }
            };
            var cleanGroupsInfo = function(groupsInfo, groupIndex, groupsCount) {
                var i;
                for (i = 0; i < groupsInfo.length; i++) {
                    if (groupIndex + 1 >= groupsCount) {
                        groupsInfo[i].children = []
                    } else {
                        cleanGroupsInfo(groupsInfo[i].children, groupIndex + 1, groupsCount)
                    }
                }
            };
            return {
                ctor: function(dataSourceAdapter) {
                    this._dataSource = dataSourceAdapter;
                    this.reset()
                },
                reset: function() {
                    this._groupsInfo = [];
                    this._totalCountCorrection = 0;
                    this._itemsCount = 0
                },
                totalCountCorrection: function() {
                    return this._totalCountCorrection
                },
                updateTotalItemsCount: function(totalCountCorrection) {
                    this._totalCountCorrection = totalCountCorrection || 0
                },
                _isGroupItemCountable: function(item) {
                    return !this._isVirtualPaging() || !item.isContinuation
                },
                _isVirtualPaging: function() {
                    var scrollingMode = this._dataSource.option("scrolling.mode");
                    return "virtual" === scrollingMode || "infinite" === scrollingMode
                },
                itemsCount: function() {
                    return this._itemsCount
                },
                updateItemsCount: function(data, groupsCount) {
                    function calculateItemsCount(that, items, groupsCount) {
                        var i, result = 0;
                        if (items) {
                            if (!groupsCount) {
                                result = items.length
                            } else {
                                for (i = 0; i < items.length; i++) {
                                    if (that._isGroupItemCountable(items[i])) {
                                        result++
                                    }
                                    result += calculateItemsCount(that, items[i].items, groupsCount - 1)
                                }
                            }
                        }
                        return result
                    }
                    this._itemsCount = calculateItemsCount(this, data, groupsCount)
                },
                foreachGroups: function(callback, childrenAtFirst, foreachCollapsedGroups, updateOffsets, updateParentOffsets) {
                    var that = this;

                    function foreachGroupsCore(groupsInfo, callback, childrenAtFirst, parents) {
                        var i, callbackResult, callbackResults = [];

                        function executeCallback(callback, data, parents, callbackResults) {
                            var callbackResult = data && callback(data, parents);
                            callbackResults.push(callbackResult);
                            return callbackResult
                        }
                        for (i = 0; i < groupsInfo.length; i++) {
                            parents.push(groupsInfo[i].data);
                            if (!childrenAtFirst && false === executeCallback(callback, groupsInfo[i].data, parents, callbackResults)) {
                                return false
                            }
                            if (!groupsInfo[i].data || groupsInfo[i].data.isExpanded || foreachCollapsedGroups) {
                                callbackResult = foreachGroupsCore(groupsInfo[i].children, callback, childrenAtFirst, parents);
                                callbackResults.push(callbackResult);
                                if (false === callbackResult) {
                                    return false
                                }
                            }
                            if (childrenAtFirst && false === executeCallback(callback, groupsInfo[i].data, parents, callbackResults)) {
                                return false
                            }
                            if (!groupsInfo[i].data || groupsInfo[i].data.offset !== groupsInfo[i].offset) {
                                updateOffsets = true
                            }
                            parents.pop()
                        }
                        var currentParents = updateParentOffsets && parents.slice(0);
                        return updateOffsets && $.when.apply($, callbackResults).always(function() {
                            updateGroupInfoOffsets(groupsInfo, currentParents)
                        })
                    }
                    return foreachGroupsCore(that._groupsInfo, callback, childrenAtFirst, [])
                },
                findGroupInfo: function(path) {
                    var pathIndex, groupInfo, that = this,
                        groupsInfo = that._groupsInfo;
                    for (pathIndex = 0; groupsInfo && pathIndex < path.length; pathIndex++) {
                        groupInfo = findGroupInfoByKey(groupsInfo, path[pathIndex]);
                        groupsInfo = groupInfo && groupInfo.children
                    }
                    return groupInfo && groupInfo.data
                },
                addGroupInfo: function(groupInfoData) {
                    var index, groupInfo, pathIndex, that = this,
                        path = groupInfoData.path,
                        groupsInfo = that._groupsInfo;
                    for (pathIndex = 0; pathIndex < path.length; pathIndex++) {
                        groupInfo = findGroupInfoByKey(groupsInfo, path[pathIndex]);
                        if (!groupInfo) {
                            groupInfo = {
                                key: path[pathIndex],
                                offset: groupInfoData.offset,
                                data: {
                                    offset: groupInfoData.offset,
                                    isExpanded: true,
                                    path: path.slice(0, pathIndex + 1)
                                },
                                children: []
                            };
                            index = getGroupInfoIndexByOffset(groupsInfo, groupInfoData.offset);
                            groupsInfo.splice(index, 0, groupInfo);
                            groupsInfo.hash = groupsInfo.hash || {};
                            groupsInfo.hash[groupInfo.key] = groupInfo
                        }
                        if (pathIndex === path.length - 1) {
                            groupInfo.data = groupInfoData;
                            if (groupInfo.offset !== groupInfoData.offset) {
                                updateGroupInfoOffsets(groupsInfo)
                            }
                        }
                        groupsInfo = groupInfo.children
                    }
                },
                allowCollapseAll: function() {
                    return true
                },
                refresh: function(options) {
                    var groupIndex, that = this,
                        storeLoadOptions = options.storeLoadOptions,
                        oldGroups = normalizeSortingInfo(that._group || []),
                        groups = normalizeSortingInfo(storeLoadOptions.group || []),
                        groupsCount = Math.min(oldGroups.length, groups.length);
                    that._group = storeLoadOptions.group;
                    for (groupIndex = 0; groupIndex < groupsCount; groupIndex++) {
                        if (oldGroups[groupIndex].selector !== groups[groupIndex].selector) {
                            groupsCount = groupIndex;
                            break
                        }
                    }
                    if (!groupsCount) {
                        that.reset()
                    } else {
                        cleanGroupsInfo(that._groupsInfo, 0, groupsCount)
                    }
                },
                handleDataLoading: function(options) {},
                handleDataLoaded: function(options, callBase) {
                    callBase(options)
                },
                handleDataLoadedCore: function(options, callBase) {
                    callBase(options)
                }
            }
        }())
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.grouping.client.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            normalizeSortingInfo = gridCore.normalizeSortingInfo,
            groupingCore = __webpack_require__( /*! ./ui.data_grid.grouping.core */ 359),
            dataQuery = __webpack_require__( /*! ../../data/query */ 158),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10);
        exports.GroupingHelper = groupingCore.GroupingHelper.inherit(function() {
            var foreachExpandedGroups = function(that, callback) {
                return that.foreachGroups(function(groupInfo, parents) {
                    if (groupInfo.isExpanded) {
                        return callback(groupInfo, parents)
                    }
                }, true)
            };
            var processGroupItems = function(that, items, groupsCount, expandedInfo, path, isCustomLoading, isLastGroupExpanded) {
                var i, item, groupInfo, isExpanded;
                expandedInfo.items = expandedInfo.items || [];
                expandedInfo.paths = expandedInfo.paths || [];
                expandedInfo.count = expandedInfo.count || 0;
                expandedInfo.lastCount = expandedInfo.lastCount || 0;
                if (!groupsCount) {
                    return
                }
                for (i = 0; i < items.length; i++) {
                    item = items[i];
                    if (void 0 !== item.items) {
                        path.push(item.key);
                        if (isCustomLoading) {
                            isExpanded = true
                        } else {
                            groupInfo = that.findGroupInfo(path);
                            isExpanded = groupInfo && groupInfo.isExpanded
                        }
                        if (!isExpanded) {
                            item.collapsedItems = item.items;
                            item.items = null
                        } else {
                            if (item.items) {
                                processGroupItems(that, item.items, groupsCount - 1, expandedInfo, path, isCustomLoading, isLastGroupExpanded)
                            } else {
                                if (1 === groupsCount && item.count && (!isCustomLoading || isLastGroupExpanded)) {
                                    expandedInfo.items.push(item);
                                    expandedInfo.paths.push(path.slice(0));
                                    expandedInfo.count += expandedInfo.lastCount;
                                    expandedInfo.lastCount = item.count
                                }
                            }
                        }
                        path.pop()
                    }
                }
            };
            var updateGroupInfos = function(that, items, groupsCount, offset) {
                return updateGroupInfosCore(that, items, 0, groupsCount, [], offset)
            };
            var updateGroupInfosCore = function(that, items, groupIndex, groupsCount, path, offset) {
                var item, count, i, groupInfo, totalCount = 0;
                if (groupIndex >= groupsCount) {
                    return items.length
                }
                for (i = 0; i < items.length; i++) {
                    item = items[i];
                    if (item) {
                        path.push(item.key);
                        if (!item.count && !item.items || void 0 === item.items) {
                            return -1
                        }
                        groupInfo = that.findGroupInfo(path);
                        if (!groupInfo) {
                            that.addGroupInfo({
                                isExpanded: that._isGroupExpanded(groupIndex),
                                path: path.slice(0),
                                offset: offset + i,
                                count: item.count > 0 ? item.count : item.items.length
                            })
                        } else {
                            groupInfo.count = item.count > 0 ? item.count : item.items.length;
                            groupInfo.offset = offset + i
                        }
                        count = item.items || !item.count ? updateGroupInfosCore(that, item.items, groupIndex + 1, groupsCount, path, 0) : item.count;
                        if (count < 0) {
                            return -1
                        }
                        totalCount += count;
                        path.pop()
                    }
                }
                return totalCount
            };
            var isGroupExpanded = function(groups, groupIndex) {
                return groups && groups.length && groups[groupIndex] && !!groups[groupIndex].isExpanded
            };
            var getTotalOffset = function(groupInfos, pageSize, offset) {
                var groupIndex, groupSize, totalOffset = offset;
                for (groupIndex = 0; groupIndex < groupInfos.length; groupIndex++) {
                    groupSize = groupInfos[groupIndex].offset + 1;
                    if (groupIndex > 0) {
                        groupSize += groupInfos[groupIndex - 1].childrenTotalCount;
                        if (pageSize) {
                            groupSize += getContinuationGroupCount(totalOffset, pageSize, groupSize, groupIndex - 1) * groupIndex
                        }
                    }
                    totalOffset += groupSize
                }
                return totalOffset
            };
            var getContinuationGroupCount = function(groupOffset, pageSize, groupSize, groupIndex) {
                groupIndex = groupIndex || 0;
                if (pageSize > 1 && groupSize > 0) {
                    var pageOffset = groupOffset - Math.floor(groupOffset / pageSize) * pageSize || pageSize;
                    pageOffset += groupSize - groupIndex - 2;
                    if (pageOffset < 0) {
                        pageOffset += pageSize
                    }
                    return Math.floor(pageOffset / (pageSize - groupIndex - 1))
                }
                return 0
            };
            exports.getContinuationGroupCount = getContinuationGroupCount;

            function loadLastLevelGroupItems(that, options, expandedInfo) {
                var expandedFilters = [],
                    data = options.data;
                $.each(expandedInfo.paths, function(_, expandedPath) {
                    expandedFilters.push(groupingCore.createGroupFilter(expandedPath, {
                        group: options.storeLoadOptions.group
                    }))
                });
                var filter = options.storeLoadOptions.filter;
                if (!options.storeLoadOptions.isLoadingAll) {
                    filter = gridCore.combineFilters([filter, gridCore.combineFilters(expandedFilters, "or")])
                }
                options.data = $.Deferred();
                var loadOptions = $.extend({}, options.storeLoadOptions, {
                    group: null,
                    filter: filter,
                    skip: expandedInfo.skip,
                    take: expandedInfo.take
                });
                $.when(0 === expandedInfo.take ? [] : that._dataSource.store().load(loadOptions)).done(function(items, extra) {
                    $.each(expandedInfo.items, function(index, item) {
                        dataQuery(items).filter(expandedFilters[index]).enumerate().done(function(expandedItems) {
                            item.items = expandedItems
                        })
                    });
                    options.data.resolve(data)
                }).fail(options.data.reject)
            }
            return {
                updateTotalItemsCount: function(options) {
                    var totalItemsCount = 0,
                        totalCount = options.extra && options.extra.totalCount || 0,
                        totalGroupCount = options.extra && options.extra.totalGroupCount || 0,
                        pageSize = this._dataSource.pageSize(),
                        isVirtualPaging = this._isVirtualPaging();
                    foreachExpandedGroups(this, function(groupInfo, parents) {
                        groupInfo.childrenTotalCount = 0
                    });
                    foreachExpandedGroups(this, function(groupInfo, parents) {
                        var totalOffset = getTotalOffset(parents, isVirtualPaging ? 0 : pageSize, totalItemsCount),
                            count = groupInfo.count + groupInfo.childrenTotalCount;
                        if (!isVirtualPaging) {
                            count += getContinuationGroupCount(totalOffset, pageSize, count, parents.length - 1)
                        }
                        if (parents[parents.length - 2]) {
                            parents[parents.length - 2].childrenTotalCount += count
                        } else {
                            totalItemsCount += count
                        }
                    });
                    this.callBase(totalItemsCount - totalCount + totalGroupCount)
                },
                _isGroupExpanded: function(groupIndex) {
                    var groups = this._dataSource.group();
                    return isGroupExpanded(groups, groupIndex)
                },
                _updatePagingOptions: function(options) {
                    var that = this,
                        isVirtualPaging = that._isVirtualPaging(),
                        pageSize = that._dataSource.pageSize(),
                        skips = [],
                        takes = [],
                        skipChildrenTotalCount = 0,
                        childrenTotalCount = 0;
                    if (options.take) {
                        foreachExpandedGroups(this, function(groupInfo) {
                            groupInfo.childrenTotalCount = 0;
                            groupInfo.skipChildrenTotalCount = 0
                        });
                        foreachExpandedGroups(that, function(groupInfo, parents) {
                            var skip, take, takeCorrection = 0,
                                parentTakeCorrection = 0,
                                totalOffset = getTotalOffset(parents, isVirtualPaging ? 0 : pageSize, childrenTotalCount),
                                continuationGroupCount = 0,
                                skipContinuationGroupCount = 0,
                                groupInfoCount = groupInfo.count + groupInfo.childrenTotalCount,
                                childrenGroupInfoCount = groupInfoCount;
                            skip = options.skip - totalOffset;
                            if (totalOffset <= options.skip + options.take && groupInfoCount) {
                                take = options.take;
                                if (!isVirtualPaging) {
                                    continuationGroupCount = getContinuationGroupCount(totalOffset, pageSize, groupInfoCount, parents.length - 1);
                                    groupInfoCount += continuationGroupCount * parents.length;
                                    childrenGroupInfoCount += continuationGroupCount;
                                    if (pageSize && skip >= 0) {
                                        takeCorrection = parents.length;
                                        parentTakeCorrection = parents.length - 1;
                                        skipContinuationGroupCount = Math.floor(skip / pageSize)
                                    }
                                }
                                if (skip >= 0) {
                                    if (totalOffset + groupInfoCount > options.skip) {
                                        skips.unshift(skip - skipContinuationGroupCount * takeCorrection - groupInfo.skipChildrenTotalCount)
                                    }
                                    if (totalOffset + groupInfoCount >= options.skip + take) {
                                        takes.unshift(take - takeCorrection - groupInfo.childrenTotalCount + groupInfo.skipChildrenTotalCount)
                                    }
                                } else {
                                    if (totalOffset + groupInfoCount >= options.skip + take) {
                                        takes.unshift(take + skip - groupInfo.childrenTotalCount)
                                    }
                                }
                            }
                            if (totalOffset <= options.skip) {
                                if (parents[parents.length - 2]) {
                                    parents[parents.length - 2].skipChildrenTotalCount += Math.min(childrenGroupInfoCount, skip + 1 - skipContinuationGroupCount * parentTakeCorrection)
                                } else {
                                    skipChildrenTotalCount += Math.min(childrenGroupInfoCount, skip + 1)
                                }
                            }
                            if (totalOffset <= options.skip + take) {
                                groupInfoCount = Math.min(childrenGroupInfoCount, skip + take - (skipContinuationGroupCount + 1) * parentTakeCorrection);
                                if (parents[parents.length - 2]) {
                                    parents[parents.length - 2].childrenTotalCount += groupInfoCount
                                } else {
                                    childrenTotalCount += groupInfoCount
                                }
                            }
                        });
                        options.skip -= skipChildrenTotalCount;
                        options.take -= childrenTotalCount - skipChildrenTotalCount
                    }
                    options.skips = skips;
                    options.takes = takes
                },
                changeRowExpand: function(path) {
                    var that = this,
                        groupInfo = that.findGroupInfo(path);
                    if (groupInfo) {
                        groupInfo.isExpanded = !groupInfo.isExpanded;
                        return $.Deferred().resolve()
                    }
                    return $.Deferred().reject()
                },
                handleDataLoadedCore: function(options, callBase) {
                    var totalCount, that = this,
                        groupCount = normalizeSortingInfo(options.storeLoadOptions.group || options.loadOptions.group).length,
                        expandedInfo = {};
                    if (options.isCustomLoading) {
                        callBase(options);
                        processGroupItems(that, options.data, groupCount, expandedInfo, [], options.isCustomLoading, options.storeLoadOptions.isLoadingAll)
                    } else {
                        totalCount = updateGroupInfos(that, options.data, groupCount, 0);
                        if (totalCount < 0) {
                            options.data = $.Deferred().reject(errors.Error("E1037"));
                            return
                        }
                        if (!options.remoteOperations.paging) {
                            if (groupCount && options.extra && options.loadOptions.requireTotalCount) {
                                options.extra.totalCount = totalCount;
                                options.extra.totalGroupCount = options.data.length
                            }
                        }
                        that.updateTotalItemsCount(options);
                        that._updatePagingOptions(options);
                        callBase(options);
                        that._processPaging(options, groupCount);
                        processGroupItems(that, options.data, groupCount, expandedInfo, []);
                        expandedInfo.skip = options.skips[groupCount - 1];
                        if (void 0 !== options.takes[groupCount - 1]) {
                            expandedInfo.take = expandedInfo.count ? expandedInfo.count - (expandedInfo.skip || 0) : 0;
                            expandedInfo.take += options.takes[groupCount - 1]
                        }
                    }
                    if (expandedInfo.paths.length && options.storeLoadOptions.group) {
                        loadLastLevelGroupItems(that, options, expandedInfo)
                    }
                    if (!options.isCustomLoading) {
                        $.when(options.data).done(function(data) {
                            that.updateItemsCount(data, groupCount)
                        })
                    }
                },
                _processPaging: function(options, groupCount) {
                    var skips, takes, i, item, items;
                    skips = options.skips;
                    takes = options.takes;
                    items = options.data;
                    for (i = 0; items && i < groupCount; i++) {
                        item = items[0];
                        items = item && item.items;
                        if (void 0 !== skips[i]) {
                            item.isContinuation = true;
                            if (items) {
                                items = items.slice(skips[i]);
                                item.items = items
                            }
                        }
                    }
                    items = options.data;
                    for (i = 0; items && i < groupCount; i++) {
                        item = items[items.length - 1];
                        items = item && item.items;
                        if (item) {
                            var maxTakeCount = item.count - (item.isContinuation && skips[i] || 0) || items.length;
                            if (void 0 !== takes[i] && maxTakeCount > takes[i]) {
                                item.isContinuationOnNextPage = true;
                                if (items) {
                                    items = items.slice(0, takes[i]);
                                    item.items = items
                                }
                            }
                        }
                    }
                },
                refresh: function(options) {
                    var isExpanded, groupIndex, that = this,
                        storeLoadOptions = options.storeLoadOptions,
                        oldGroups = normalizeSortingInfo(that._group);

                    function handleGroup(groupInfo, parents) {
                        if (parents.length === groupIndex + 1) {
                            groupInfo.isExpanded = isExpanded
                        }
                    }
                    for (groupIndex = 0; groupIndex < oldGroups.length; groupIndex++) {
                        isExpanded = isGroupExpanded(storeLoadOptions.group, groupIndex);
                        if (isGroupExpanded(that._group, groupIndex) !== isExpanded) {
                            that.foreachGroups(handleGroup)
                        }
                    }
                    that.callBase.apply(this, arguments);
                    that.foreachGroups(function(groupInfo) {
                        groupInfo.count = 0
                    })
                }
            }
        }())
    },
    /*!*******************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.master_detail_module.js ***!
      \*******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        var DATAGRID_MASTER_DETAIL_CELL_CLASS = "dx-master-detail-cell",
            DATAGRID_MASTER_DETAIL_ROW_CLASS = "dx-master-detail-row",
            DATAGRID_CELL_FOCUS_DISABLED_CLASS = "dx-cell-focus-disabled",
            DATAGRID_ROW_LINES_CLASS = "dx-row-lines";
        gridCore.registerModule("masterDetail", {
            defaultOptions: function() {
                return {
                    masterDetail: {
                        enabled: false,
                        autoExpandAll: false,
                        template: null
                    }
                }
            },
            extenders: {
                controllers: {
                    columns: {
                        _getExpandColumnsCore: function() {
                            var expandColumns = this.callBase();
                            if (this.option("masterDetail.enabled")) {
                                expandColumns.push({})
                            }
                            return expandColumns
                        }
                    },
                    data: function() {
                        var initMasterDetail = function(that) {
                            that._expandedItems = [];
                            that._isExpandAll = that.option("masterDetail.autoExpandAll")
                        };
                        return {
                            init: function() {
                                var that = this;
                                initMasterDetail(that);
                                that.callBase()
                            },
                            expandAll: function(groupIndex) {
                                var that = this;
                                if (groupIndex < 0) {
                                    that._isExpandAll = true;
                                    that._expandedItems = [];
                                    that.updateItems()
                                } else {
                                    that.callBase.apply(that, arguments)
                                }
                            },
                            collapseAll: function(groupIndex) {
                                var that = this;
                                if (groupIndex < 0) {
                                    that._isExpandAll = false;
                                    that._expandedItems = [];
                                    that.updateItems()
                                } else {
                                    that.callBase.apply(that, arguments)
                                }
                            },
                            isRowExpanded: function(key) {
                                var that = this,
                                    expandIndex = gridCoreUtils.getIndexByKey(key, that._expandedItems);
                                if (commonUtils.isArray(key)) {
                                    return that.callBase.apply(that, arguments)
                                } else {
                                    return !!(that._isExpandAll ^ (expandIndex >= 0 && that._expandedItems[expandIndex].visible))
                                }
                            },
                            _changeRowExpandCore: function(key) {
                                var expandIndex, rowIndex, that = this;
                                if (commonUtils.isArray(key)) {
                                    return that.callBase.apply(that, arguments)
                                } else {
                                    expandIndex = gridCoreUtils.getIndexByKey(key, that._expandedItems);
                                    if (expandIndex >= 0) {
                                        var visible = that._expandedItems[expandIndex].visible;
                                        that._expandedItems[expandIndex].visible = !visible
                                    } else {
                                        that._expandedItems.push({
                                            key: key,
                                            visible: true
                                        })
                                    }
                                    rowIndex = that.getRowIndexByKey(key);
                                    that.updateItems({
                                        changeType: "update",
                                        rowIndices: [rowIndex, rowIndex + 1, rowIndex + 2]
                                    })
                                }
                            },
                            _processDataItem: function(data, options) {
                                var that = this,
                                    dataItem = that.callBase.apply(that, arguments);
                                dataItem.isExpanded = that.isRowExpanded(dataItem.key);
                                if (void 0 === options.detailColumnIndex) {
                                    options.detailColumnIndex = -1;
                                    $.each(options.visibleColumns, function(index, column) {
                                        if ("expand" === column.command && !commonUtils.isDefined(column.groupIndex)) {
                                            options.detailColumnIndex = index;
                                            return false
                                        }
                                    })
                                }
                                if (options.detailColumnIndex >= 0) {
                                    dataItem.values[options.detailColumnIndex] = dataItem.isExpanded
                                }
                                return dataItem
                            },
                            _processItems: function(items, changeType) {
                                var expandIndex, that = this,
                                    result = [];
                                items = that.callBase.apply(that, arguments);
                                if ("loadingAll" === changeType) {
                                    return items
                                }
                                if ("refresh" === changeType) {
                                    that._expandedItems = $.grep(that._expandedItems, function(item) {
                                        return item.visible
                                    })
                                }
                                $.each(items, function(index, item) {
                                    result.push(item);
                                    expandIndex = gridCoreUtils.getIndexByKey(item.key, that._expandedItems);
                                    if ("data" === item.rowType && (item.isExpanded || expandIndex >= 0) && !item.inserted) {
                                        result.push({
                                            visible: item.isExpanded,
                                            rowType: "detail",
                                            key: item.key,
                                            data: item.data,
                                            values: []
                                        })
                                    }
                                });
                                return result
                            },
                            optionChanged: function(args) {
                                var value, previousValue, isEnabledChanged, isAutoExpandAllChanged, that = this;
                                if ("masterDetail" === args.name) {
                                    args.name = "dataSource";
                                    switch (args.fullName) {
                                        case "masterDetail":
                                            value = args.value || {};
                                            previousValue = args.previousValue || {};
                                            isEnabledChanged = value.enabled !== previousValue.enabled;
                                            isAutoExpandAllChanged = value.autoExpandAll !== previousValue.autoExpandAll;
                                            break;
                                        case "masterDetail.enabled":
                                            isEnabledChanged = true;
                                            break;
                                        case "masterDetail.autoExpandAll":
                                            isAutoExpandAllChanged = true
                                    }
                                    if (isEnabledChanged || isAutoExpandAllChanged) {
                                        initMasterDetail(that)
                                    }
                                }
                                that.callBase(args)
                            }
                        }
                    }()
                },
                views: {
                    rowsView: function() {
                        return {
                            _getCellTemplate: function(options) {
                                var template, that = this,
                                    column = options.column;
                                if ("detail" === column.command) {
                                    template = that.option("masterDetail.template") || that._getDefaultTemplate(column)
                                } else {
                                    template = that.callBase.apply(that, arguments)
                                }
                                return template
                            },
                            _isDetailRow: function(row) {
                                return row && row.rowType && 0 === row.rowType.indexOf("detail")
                            },
                            _createRow: function(row) {
                                var $row = this.callBase(row);
                                if (row && this._isDetailRow(row)) {
                                    this.option("showRowLines") && $row.addClass(DATAGRID_ROW_LINES_CLASS);
                                    $row.addClass(DATAGRID_MASTER_DETAIL_ROW_CLASS).toggle(row.visible)
                                }
                                return $row
                            },
                            _getGroupCellOptions: function(options) {
                                var row = options.row,
                                    groupColumns = this._columnsController.getGroupColumns(),
                                    columnIndex = groupColumns.length + options.columnsCountBeforeGroups,
                                    emptyCellsCount = columnIndex + Number(this.option("masterDetail.enabled"));
                                if (row && this._isDetailRow(row)) {
                                    return {
                                        columnIndex: columnIndex,
                                        emptyCellsCount: emptyCellsCount,
                                        colspan: options.columns.length - emptyCellsCount
                                    }
                                }
                                return this.callBase(options)
                            },
                            _renderCells: function($row, options) {
                                var $detailCell, groupCellOptions, i, row = options.row;
                                if (row.rowType && this._isDetailRow(row)) {
                                    groupCellOptions = this._getGroupCellOptions(options);
                                    for (i = 0; i < groupCellOptions.emptyCellsCount; i++) {
                                        this._renderCell($row, {
                                            value: null,
                                            row: row,
                                            rowIndex: row.rowIndex,
                                            column: options.columns[i]
                                        })
                                    }
                                    $detailCell = this._renderCell($row, {
                                        value: null,
                                        row: row,
                                        rowIndex: row.rowIndex,
                                        column: {
                                            command: "detail"
                                        },
                                        columnIndex: groupCellOptions.columnIndex
                                    });
                                    $detailCell.addClass(DATAGRID_CELL_FOCUS_DISABLED_CLASS).addClass(DATAGRID_MASTER_DETAIL_CELL_CLASS).attr("colspan", groupCellOptions.colspan)
                                } else {
                                    this.callBase.apply(this, arguments)
                                }
                            }
                        }
                    }()
                }
            }
        })
    },
    /*!******************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.editing.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            getIndexByKey = gridCoreUtils.getIndexByKey,
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            addNamespace = eventUtils.addNamespace,
            dialog = __webpack_require__( /*! ../dialog */ 194),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            Button = __webpack_require__( /*! ../button */ 196),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            Form = __webpack_require__( /*! ../form */ 276),
            holdEvent = __webpack_require__( /*! ../../events/hold */ 164);
        __webpack_require__( /*! ./ui.data_grid.editor_factory */ 363);
        var DATAGRID_LINK_CLASS = "dx-link",
            DATAGRID_EDITOR_CELL_CLASS = "dx-editor-cell",
            DATAGRID_ROW_SELECTED = "dx-selection",
            DATAGRID_EDIT_ROW = "dx-edit-row",
            DATAGRID_EDIT_FORM_CLASS = "dx-datagrid-edit-form",
            DATAGRID_EDIT_BUTTON_CLASS = "dx-edit-button",
            DATAGRID_INSERT_INDEX = "__DX_INSERT_INDEX__",
            DATAGRID_ROW_CLASS = "dx-row",
            DATAGRID_ROW_REMOVED = "dx-row-removed",
            DATAGRID_ROW_INSERTED = "dx-row-inserted",
            DATAGRID_ROW_MODIFIED = "dx-row-modified",
            DATAGRID_CELL_MODIFIED = "dx-cell-modified",
            DATAGRID_CELL_HIGHLIGHT_OUTLINE = "dx-highlight-outline",
            DATAGRID_EDITING_NAMESPACE = "dxDataGridEditing",
            DATAGRID_FOCUS_OVERLAY_CLASS = "dx-datagrid-focus-overlay",
            DATAGRID_READONLY_CLASS = "dx-datagrid-readonly",
            DATAGRID_DATA_ROW_CLASS = "dx-data-row",
            DATAGRID_CELL_FOCUS_DISABLED_CLASS = "dx-cell-focus-disabled",
            DATAGRID_EDIT_MODE_BATCH = "batch",
            DATAGRID_EDIT_MODE_ROW = "row",
            DATAGRID_EDIT_MODE_CELL = "cell",
            DATAGRID_EDIT_MODE_FORM = "form",
            DATA_EDIT_DATA_INSERT_TYPE = "insert",
            DATA_EDIT_DATA_UPDATE_TYPE = "update",
            DATA_EDIT_DATA_REMOVE_TYPE = "remove",
            DATAGRID_POINTER_EVENTS_NONE_CLASS = "dx-pointer-events-none",
            DATAGRID_POINTER_EVENTS_TARGET_CLASS = "dx-pointer-events-target";
        var getEditMode = function(that) {
            var editMode = that.option("editing.mode");
            if (editMode === DATAGRID_EDIT_MODE_BATCH || editMode === DATAGRID_EDIT_MODE_CELL || editMode === DATAGRID_EDIT_MODE_FORM) {
                return editMode
            }
            return DATAGRID_EDIT_MODE_ROW
        };
        var isRowEditMode = function(that) {
            var editMode = getEditMode(that);
            return editMode === DATAGRID_EDIT_MODE_ROW || editMode === DATAGRID_EDIT_MODE_FORM
        };
        exports.EditingController = gridCore.ViewController.inherit(function() {
            var getDefaultEditorTemplate = function(that) {
                return function(container, options) {
                    var $editor = $("<div/>").appendTo(container);
                    that.getController("editorFactory").createEditor($editor, $.extend({}, options.column, {
                        value: options.value,
                        setValue: options.setValue,
                        row: options.row,
                        parentType: "dataRow",
                        width: null,
                        readOnly: !options.setValue,
                        id: options.id
                    }))
                }
            };
            return {
                init: function() {
                    var that = this;
                    that._insertIndex = 1;
                    that._editRowIndex = -1;
                    that._editData = [];
                    that._editColumnIndex = -1;
                    that._columnsController = that.getController("columns");
                    that._dataController = that.getController("data");
                    that._rowsView = that.getView("rowsView");
                    if (!that._dataChangedHandler) {
                        that._dataChangedHandler = $.proxy(that._handleDataChanged, that);
                        that._dataController.changed.add(that._dataChangedHandler)
                    }
                    if (!that._saveEditorHandler) {
                        that.createAction("onInitNewRow", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that.createAction("onRowInserting", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that.createAction("onRowInserted", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that.createAction("onEditingStart", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that.createAction("onRowUpdating", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that.createAction("onRowUpdated", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that.createAction("onRowRemoving", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that.createAction("onRowRemoved", {
                            excludeValidators: ["disabled", "readOnly"]
                        });
                        that._saveEditorHandler = that.createAction(function(e) {
                            var isEditorPopup, isDomElement, isFocusOverlay, isAddRowButton, isCellEditMode, $target, event = e.jQueryEvent;
                            if (!isRowEditMode(that) && !that._editCellInProgress) {
                                $target = $(event.target);
                                isEditorPopup = $target.closest(".dx-dropdowneditor-overlay").length;
                                isDomElement = $target.closest(document).length;
                                isAddRowButton = $target.closest(".dx-datagrid-addrow-button").length;
                                isFocusOverlay = $target.hasClass(DATAGRID_FOCUS_OVERLAY_CLASS);
                                isCellEditMode = getEditMode(that) === DATAGRID_EDIT_MODE_CELL;
                                if (!isEditorPopup && !isFocusOverlay && !(isAddRowButton && isCellEditMode && that.isEditing()) && isDomElement) {
                                    $.proxy(that._closeEditItem, that)($target)
                                }
                            }
                        });
                        $(document).on(clickEvent.name, that._saveEditorHandler)
                    }
                    that._updateEditColumn();
                    that._updateEditButtons()
                },
                _closeEditItem: function($targetElement) {
                    var isDataRow = $targetElement.closest("." + DATAGRID_DATA_ROW_CLASS).length,
                        $targetCell = $targetElement.closest("." + DATAGRID_ROW_CLASS + "> td"),
                        columnIndex = $targetCell[0] && $targetCell[0].cellIndex,
                        rowIndex = this.getView("rowsView").getRowIndex($targetCell.parent()),
                        visibleColumns = this._columnsController.getVisibleColumns(),
                        allowEditing = visibleColumns[columnIndex] && visibleColumns[columnIndex].allowEditing;
                    if (this.isEditing() && (!isDataRow || isDataRow && !allowEditing && !this.isEditCell(rowIndex, columnIndex))) {
                        this.closeEditCell()
                    }
                },
                _handleDataChanged: function(args) {
                    if ("standard" === this.option("scrolling.mode")) {
                        this.resetRowAndPageIndices()
                    }
                    if ("prepend" === args.changeType) {
                        $.each(this._editData, function(_, editData) {
                            editData.rowIndex += args.items.length;
                            if (editData.type === DATA_EDIT_DATA_INSERT_TYPE) {
                                editData.key.rowIndex += args.items.length
                            }
                        })
                    }
                },
                getEditMode: function() {
                    return getEditMode(this)
                },
                getFirstEditableColumnIndex: function() {
                    var columnIndex, columnsController = this.getController("columns"),
                        visibleColumns = columnsController.getVisibleColumns();
                    $.each(visibleColumns, function(index, column) {
                        if (column.allowEditing) {
                            columnIndex = index;
                            return false
                        }
                    });
                    return columnIndex
                },
                getFirstEditableCellInRow: function(rowIndex) {
                    return this.getView("rowsView").getCellElement(rowIndex ? rowIndex : 0, this.getFirstEditableColumnIndex())
                },
                getFocusedCellInRow: function(rowIndex) {
                    return this.getFirstEditableCellInRow(rowIndex)
                },
                getIndexByKey: function(key, items) {
                    return getIndexByKey(key, items)
                },
                hasChanges: function() {
                    var that = this,
                        result = false;
                    for (var i = 0; i < that._editData.length; i++) {
                        if (that._editData[i].type) {
                            result = true;
                            break
                        }
                    }
                    return result
                },
                dispose: function() {
                    this.callBase();
                    $(document).off(clickEvent.name, this._saveEditorHandler)
                },
                optionChanged: function(args) {
                    if ("editing" === args.name) {
                        this.init();
                        args.handled = true
                    } else {
                        this.callBase(args)
                    }
                },
                publicMethods: function() {
                    return ["insertRow", "addRow", "removeRow", "deleteRow", "undeleteRow", "editRow", "editCell", "closeEditCell", "saveEditData", "cancelEditData", "hasEditData"]
                },
                refresh: function() {
                    if (getEditMode(this) !== DATAGRID_EDIT_MODE_BATCH) {
                        this.init()
                    } else {
                        this._editRowIndex = -1;
                        this._editColumnIndex = -1
                    }
                },
                isEditing: function() {
                    return this._editRowIndex > -1
                },
                isEditRow: function(rowIndex) {
                    return this._editRowIndex === rowIndex && (getEditMode(this) === DATAGRID_EDIT_MODE_ROW || getEditMode(this) === DATAGRID_EDIT_MODE_FORM)
                },
                getEditRowKey: function() {
                    var items = this._dataController.items(),
                        item = items[this._editRowIndex];
                    return item && item.key
                },
                getEditFormRowIndex: function() {
                    return getEditMode(this) === DATAGRID_EDIT_MODE_FORM ? this._editRowIndex : -1
                },
                isEditCell: function(rowIndex, columnIndex) {
                    return this._editRowIndex === rowIndex && this._editColumnIndex === columnIndex
                },
                _needInsertItem: function(editData, changeType) {
                    var that = this,
                        dataSource = that._dataController.dataSource(),
                        scrollingMode = that.option("scrolling.mode"),
                        pageIndex = dataSource.pageIndex(),
                        beginPageIndex = dataSource.beginPageIndex ? dataSource.beginPageIndex() : pageIndex,
                        endPageIndex = dataSource.endPageIndex ? dataSource.endPageIndex() : pageIndex;
                    if ("standard" !== scrollingMode) {
                        switch (changeType) {
                            case "append":
                                return editData.key.pageIndex === endPageIndex;
                            case "prepend":
                                return editData.key.pageIndex === beginPageIndex;
                            case "refresh":
                                editData.key.rowIndex = 0;
                                editData.key.pageIndex = 0;
                                break;
                            default:
                                return editData.key.pageIndex >= beginPageIndex && editData.key.pageIndex <= endPageIndex
                        }
                    }
                    return editData.key.pageIndex === pageIndex
                },
                processItems: function(items, changeType) {
                    var i, key, data, that = this,
                        editData = that._editData;
                    that.update(changeType);
                    for (i = 0; i < editData.length; i++) {
                        key = editData[i].key;
                        data = {
                            key: key
                        };
                        if (editData[i].type === DATA_EDIT_DATA_INSERT_TYPE && that._needInsertItem(editData[i], changeType)) {
                            data[DATAGRID_INSERT_INDEX] = key[DATAGRID_INSERT_INDEX];
                            items.splice(key.rowIndex, 0, data)
                        }
                    }
                    return items
                },
                processDataItem: function(item, columns, generateDataValues) {
                    var editIndex, editData, data, editMode, that = this,
                        key = item.data[DATAGRID_INSERT_INDEX] ? item.data.key : item.key;
                    editIndex = getIndexByKey(key, that._editData);
                    if (editIndex >= 0) {
                        editMode = getEditMode(that);
                        editData = that._editData[editIndex];
                        data = editData.data;
                        switch (editData.type) {
                            case DATA_EDIT_DATA_INSERT_TYPE:
                                item.inserted = true;
                                item.key = key;
                                item.data = data;
                                break;
                            case DATA_EDIT_DATA_UPDATE_TYPE:
                                item.modified = true;
                                item.oldData = item.data;
                                item.data = $.extend(true, {}, item.data, data);
                                item.modifiedValues = generateDataValues(data, columns);
                                break;
                            case DATA_EDIT_DATA_REMOVE_TYPE:
                                if (editMode === DATAGRID_EDIT_MODE_BATCH) {
                                    item.data = $.extend(true, {}, item.data, data)
                                }
                                item.removed = true
                        }
                    }
                },
                insertRow: function() {
                    errors.log("W0002", "dxDataGrid", "insertRow", "15.2", "Use the 'addRow' method instead");
                    return this.addRow()
                },
                addRow: function() {
                    var $firstCell, that = this,
                        dataController = that._dataController,
                        store = dataController.store(),
                        key = store && store.key(),
                        rowsView = that.getView("rowsView"),
                        param = {
                            data: {}
                        },
                        insertKey = {
                            pageIndex: dataController.pageIndex(),
                            rowIndex: rowsView ? rowsView.getTopVisibleItemIndex() : 0
                        },
                        oldEditRowIndex = that._editRowIndex,
                        editMode = getEditMode(that);
                    if (editMode === DATAGRID_EDIT_MODE_CELL && that.hasChanges()) {
                        that.saveEditData()
                    }
                    that.refresh();
                    if (editMode !== DATAGRID_EDIT_MODE_BATCH && that._insertIndex > 1) {
                        return
                    }
                    if (!key) {
                        param.data.__KEY__ = String(new Guid)
                    }
                    that.executeAction("onInitNewRow", param);
                    if (editMode !== DATAGRID_EDIT_MODE_BATCH) {
                        that._editRowIndex = insertKey.rowIndex
                    }
                    insertKey[DATAGRID_INSERT_INDEX] = that._insertIndex++;
                    that._addEditData({
                        key: insertKey,
                        data: param.data,
                        type: DATA_EDIT_DATA_INSERT_TYPE
                    });
                    dataController.updateItems({
                        changeType: "update",
                        rowIndices: [oldEditRowIndex, insertKey.rowIndex]
                    });
                    $firstCell = that.getFirstEditableCellInRow(insertKey.rowIndex);
                    that._delayedInputFocus($firstCell, function() {
                        var $cell = that.getFirstEditableCellInRow(insertKey.rowIndex);
                        $cell && $cell.trigger(clickEvent.name)
                    });
                    that._afterInsertRow({
                        key: insertKey,
                        data: param.data
                    })
                },
                _isEditingStart: function(options) {
                    this.executeAction("onEditingStart", options);
                    return options.cancel
                },
                _beforeEditCell: function(rowIndex, columnIndex, item) {
                    if (getEditMode(this) === DATAGRID_EDIT_MODE_CELL && !item.inserted && this.hasChanges()) {
                        this.saveEditData();
                        if (this.hasChanges()) {
                            return true
                        }
                    }
                },
                _beforeUpdateItems: function(rowIndices) {},
                editRow: function(rowIndex) {
                    var $editingCell, that = this,
                        dataController = that._dataController,
                        items = dataController.items(),
                        item = items[rowIndex],
                        params = {
                            data: item.data,
                            cancel: false
                        },
                        oldEditRowIndex = that._editRowIndex;
                    if (rowIndex === oldEditRowIndex) {
                        return true
                    }
                    if (!item.inserted) {
                        params.key = item.key
                    }
                    if (that._isEditingStart(params)) {
                        return
                    }
                    that.init();
                    that._pageIndex = dataController.pageIndex();
                    that._editRowIndex = items[0].inserted ? rowIndex - 1 : rowIndex;
                    that._addEditData({
                        data: {},
                        key: item.key,
                        oldData: item.data
                    });
                    var rowIndices = [oldEditRowIndex, rowIndex];
                    that._beforeUpdateItems(rowIndices, rowIndex, oldEditRowIndex);
                    dataController.updateItems({
                        changeType: "update",
                        rowIndices: rowIndices
                    });
                    if (getEditMode(that) === DATAGRID_EDIT_MODE_ROW || getEditMode(that) === DATAGRID_EDIT_MODE_FORM) {
                        $editingCell = that.getFocusedCellInRow(that._editRowIndex);
                        that._delayedInputFocus($editingCell, function() {
                            $editingCell && that.component.focus($editingCell)
                        })
                    }
                },
                editCell: function(rowIndex, columnIndex) {
                    var $cell, showEditorAlways, that = this,
                        columnsController = that._columnsController,
                        dataController = that._dataController,
                        items = dataController.items(),
                        item = items[rowIndex],
                        params = {
                            data: item && item.data,
                            cancel: false
                        },
                        oldEditRowIndex = that._editRowIndex,
                        oldEditColumnIndex = that._editColumnIndex,
                        columns = columnsController.getVisibleColumns();
                    if (commonUtils.isString(columnIndex)) {
                        columnIndex = columnsController.columnOption(columnIndex, "index");
                        columnIndex = columnsController.getVisibleIndex(columnIndex)
                    }
                    params.column = columnsController.getVisibleColumns()[columnIndex];
                    showEditorAlways = params.column && params.column.showEditorAlways;
                    if (params.column && item && ("data" === item.rowType || "detailAdaptive" === item.rowType) && !item.removed && !isRowEditMode(that)) {
                        if (this.isEditCell(rowIndex, columnIndex)) {
                            return true
                        }
                        if (that._beforeEditCell(rowIndex, columnIndex, item)) {
                            return true
                        }
                        if (!item.inserted) {
                            params.key = item.key
                        }
                        if (that._isEditingStart(params)) {
                            return true
                        }
                        that._editRowIndex = rowIndex;
                        that._editColumnIndex = columnIndex;
                        that._pageIndex = dataController.pageIndex();
                        that._addEditData({
                            data: {},
                            key: item.key,
                            oldData: item.data
                        });
                        if (!showEditorAlways || columns[oldEditColumnIndex] && !columns[oldEditColumnIndex].showEditorAlways) {
                            that._editCellInProgress = true;
                            that.getController("editorFactory").loseFocus();
                            dataController.updateItems({
                                changeType: "update",
                                rowIndices: [oldEditRowIndex, that._editRowIndex]
                            })
                        }
                        $cell = that.getView("rowsView").getCellElement(that._editRowIndex, that._editColumnIndex);
                        if ($cell && !$cell.find(":focus").length) {
                            that._focusEditingCell(function() {
                                that._editCellInProgress = false
                            }, $cell)
                        } else {
                            that._editCellInProgress = false
                        }
                        return true
                    }
                    return false
                },
                _delayedInputFocus: function($cell, beforeFocusCallback) {
                    function inputFocus() {
                        if (beforeFocusCallback) {
                            beforeFocusCallback()
                        }
                        $cell && $cell.find("[tabindex], input").first().focus()
                    }
                    if (devices.real().ios || devices.real().android) {
                        inputFocus()
                    } else {
                        setTimeout(inputFocus)
                    }
                },
                _focusEditingCell: function(beforeFocusCallback, $editCell) {
                    var that = this;
                    $editCell = $editCell || that.getView("rowsView").getCellElement(that._editRowIndex, that._editColumnIndex);
                    that._delayedInputFocus($editCell, beforeFocusCallback)
                },
                removeRow: function(rowIndex) {
                    errors.log("W0002", "dxDataGrid", "removeRow", "15.2", "Use the 'deleteRow' method instead");
                    return this.deleteRow(rowIndex)
                },
                deleteRow: function(rowIndex) {
                    var removeByKey, showDialogTitle, that = this,
                        editingOptions = that.option("editing"),
                        editingTexts = editingOptions && editingOptions.texts,
                        confirmDeleteTitle = editingTexts && editingTexts.confirmDeleteTitle,
                        isBatchMode = editingOptions && editingOptions.mode === DATAGRID_EDIT_MODE_BATCH,
                        confirmDeleteMessage = editingTexts && editingTexts.confirmDeleteMessage,
                        dataController = that._dataController,
                        oldEditRowIndex = that._editRowIndex,
                        item = dataController.items()[rowIndex],
                        key = item && item.key;
                    if (item) {
                        removeByKey = function(key) {
                            that.refresh();
                            var editIndex = getIndexByKey(key, that._editData);
                            if (editIndex >= 0) {
                                if (that._editData[editIndex].type === DATA_EDIT_DATA_INSERT_TYPE) {
                                    that._editData.splice(editIndex, 1)
                                } else {
                                    that._editData[editIndex].type = DATA_EDIT_DATA_REMOVE_TYPE
                                }
                            } else {
                                that._addEditData({
                                    key: key,
                                    oldData: item.data,
                                    type: DATA_EDIT_DATA_REMOVE_TYPE
                                })
                            }
                            if (isBatchMode) {
                                dataController.updateItems({
                                    changeType: "update",
                                    rowIndices: [oldEditRowIndex, rowIndex]
                                })
                            } else {
                                that.saveEditData()
                            }
                        };
                        if (isBatchMode || !confirmDeleteMessage) {
                            removeByKey(key)
                        } else {
                            showDialogTitle = commonUtils.isDefined(confirmDeleteTitle) && confirmDeleteTitle.length > 0;
                            dialog.confirm(confirmDeleteMessage, confirmDeleteTitle, showDialogTitle).done(function(confirmResult) {
                                if (confirmResult) {
                                    removeByKey(key)
                                }
                            })
                        }
                    }
                },
                undeleteRow: function(rowIndex) {
                    var that = this,
                        dataController = that._dataController,
                        item = dataController.items()[rowIndex],
                        oldEditRowIndex = that._editRowIndex,
                        key = item && item.key;
                    if (item) {
                        var editData, editIndex = getIndexByKey(key, that._editData);
                        if (editIndex >= 0) {
                            editData = that._editData[editIndex];
                            if ($.isEmptyObject(editData.data)) {
                                that._editData.splice(editIndex, 1)
                            } else {
                                editData.type = DATA_EDIT_DATA_UPDATE_TYPE
                            }
                            dataController.updateItems({
                                changeType: "update",
                                rowIndices: [oldEditRowIndex, rowIndex]
                            })
                        }
                    }
                },
                _saveEditDataCore: function(deferreds, processedKeys) {
                    var that = this,
                        store = that._dataController.store(),
                        hasCanceledData = false;

                    function executeEditingAction(actionName, params, func) {
                        var deferred = $.Deferred();
                        that.executeAction(actionName, params);

                        function createFailureHandler(deferred) {
                            return function(arg) {
                                var error = arg instanceof Error ? arg : new Error(arg && String(arg) || "Unknown error");
                                deferred.reject(error)
                            }
                        }
                        $.when(params.cancel).done(function(cancel) {
                            if (cancel) {
                                deferred.resolve("cancel")
                            } else {
                                func(params).done(deferred.resolve).fail(createFailureHandler(deferred))
                            }
                        }).fail(createFailureHandler(deferred));
                        return deferred
                    }
                    $.each(that._editData, function(index, editData) {
                        var deferred, doneDeferred, params, data = editData.data,
                            oldData = editData.oldData,
                            key = editData.key,
                            type = editData.type;
                        if (that._beforeSaveEditData(editData, index)) {
                            return
                        }
                        switch (type) {
                            case DATA_EDIT_DATA_REMOVE_TYPE:
                                params = {
                                    data: oldData,
                                    key: key,
                                    cancel: false
                                };
                                deferred = executeEditingAction("onRowRemoving", params, function() {
                                    return store.remove(key)
                                });
                                break;
                            case DATA_EDIT_DATA_INSERT_TYPE:
                                params = {
                                    data: data,
                                    cancel: false
                                };
                                deferred = executeEditingAction("onRowInserting", params, function() {
                                    return store.insert(params.data)
                                });
                                break;
                            case DATA_EDIT_DATA_UPDATE_TYPE:
                                params = {
                                    newData: data,
                                    oldData: oldData,
                                    key: key,
                                    cancel: false
                                };
                                deferred = executeEditingAction("onRowUpdating", params, function() {
                                    return store.update(key, params.newData)
                                })
                        }
                        if (deferred) {
                            doneDeferred = $.Deferred();
                            deferred.always(function() {
                                processedKeys.push(key)
                            }).always(doneDeferred.resolve);
                            deferreds.push(doneDeferred.promise())
                        }
                    });
                    return hasCanceledData
                },
                _processSaveEditDataResult: function(results, processedKeys) {
                    var i, arg, editIndex, isError, that = this,
                        dataController = that._dataController,
                        hasSavedData = false,
                        editMode = getEditMode(that);
                    for (i = 0; i < results.length; i++) {
                        arg = results[i];
                        editIndex = getIndexByKey(processedKeys[i], that._editData);
                        if (that._editData[editIndex]) {
                            isError = arg && arg instanceof Error;
                            if (isError) {
                                that._editData[editIndex].error = arg;
                                dataController.dataErrorOccurred.fire(arg);
                                if (editMode !== DATAGRID_EDIT_MODE_BATCH) {
                                    break
                                }
                            } else {
                                if ("cancel" !== arg) {
                                    that._editData.splice(editIndex, 1);
                                    hasSavedData = true
                                }
                            }
                        }
                    }
                    return hasSavedData
                },
                _fireSaveEditDataEvents: function(editData) {
                    var that = this;
                    $.each(editData, function(_, itemData) {
                        var data = itemData.data,
                            key = itemData.key,
                            type = itemData.type,
                            params = {
                                key: key,
                                data: data
                            };
                        if (itemData.error) {
                            params.error = itemData.error
                        }
                        switch (type) {
                            case DATA_EDIT_DATA_REMOVE_TYPE:
                                that.executeAction("onRowRemoved", $.extend({}, params, {
                                    data: itemData.oldData
                                }));
                                break;
                            case DATA_EDIT_DATA_INSERT_TYPE:
                                that.executeAction("onRowInserted", params);
                                break;
                            case DATA_EDIT_DATA_UPDATE_TYPE:
                                that.executeAction("onRowUpdated", params)
                        }
                    })
                },
                saveEditData: function() {
                    var that = this,
                        processedKeys = [],
                        deferreds = [],
                        dataController = that._dataController,
                        editData = $.extend({}, that._editData),
                        editMode = getEditMode(that),
                        result = $.Deferred();
                    var resetEditIndices = function(that) {
                        that._editColumnIndex = -1;
                        that._editRowIndex = -1
                    };
                    if (that._beforeSaveEditData() || that._saving) {
                        that._afterSaveEditData();
                        return result.resolve().promise()
                    }
                    that._saveEditDataCore(deferreds, processedKeys);
                    if (deferreds.length) {
                        that._saving = true;
                        $.when.apply($, deferreds).done(function() {
                            if (that._processSaveEditDataResult(arguments, processedKeys)) {
                                resetEditIndices(that);
                                $.when(dataController.refresh()).always(function() {
                                    that._fireSaveEditDataEvents(editData);
                                    that._afterSaveEditData();
                                    result.resolve()
                                })
                            } else {
                                result.resolve()
                            }
                        }).fail(result.resolve);
                        return result.always(function() {
                            that._saving = false
                        }).promise()
                    }
                    if (isRowEditMode(that)) {
                        if (!that.hasChanges()) {
                            that.cancelEditData()
                        }
                    } else {
                        if (editMode === DATAGRID_EDIT_MODE_BATCH || editMode === DATAGRID_EDIT_MODE_CELL) {
                            resetEditIndices(that);
                            dataController.updateItems()
                        } else {
                            that._focusEditingCell()
                        }
                    }
                    that._afterSaveEditData();
                    return result.resolve().promise()
                },
                _updateEditColumn: function() {
                    var that = this,
                        editing = that.option("editing"),
                        editMode = getEditMode(that),
                        isEditColumnVisible = editing && ((editing.allowUpdating || editing.allowAdding) && editMode === DATAGRID_EDIT_MODE_ROW || editing.allowUpdating && editMode === DATAGRID_EDIT_MODE_FORM || editing.allowDeleting);
                    that._columnsController.addCommandColumn({
                        command: "edit",
                        visible: isEditColumnVisible,
                        cssClass: "dx-command-edit",
                        width: "auto"
                    });
                    that._columnsController.columnOption("command:edit", "visible", isEditColumnVisible)
                },
                _updateEditButtons: function() {
                    var that = this,
                        headerPanel = that.getView("headerPanel"),
                        hasChanges = that.hasChanges();
                    if (headerPanel) {
                        headerPanel.updateToolbarItemOption("saveButton", "disabled", !hasChanges);
                        headerPanel.updateToolbarItemOption("cancelButton", "disabled", !hasChanges)
                    }
                },
                _applyModified: function($element) {
                    $element && $element.addClass(DATAGRID_CELL_MODIFIED)
                },
                _beforeCloseEditCellInBatchMode: function(rowIndices) {},
                cancelEditData: function() {
                    var that = this,
                        dataController = that._dataController;
                    that._beforeCancelEditData();
                    that.init();
                    dataController.updateItems()
                },
                hasEditData: function() {
                    return this.hasChanges()
                },
                closeEditCell: function() {
                    var that = this,
                        editMode = getEditMode(that),
                        oldEditRowIndex = that._editRowIndex,
                        dataController = that._dataController;
                    if (!isRowEditMode(that)) {
                        setTimeout(function() {
                            if (editMode === DATAGRID_EDIT_MODE_CELL && that.hasChanges()) {
                                that.saveEditData()
                            } else {
                                if (oldEditRowIndex >= 0) {
                                    var rowIndices = [oldEditRowIndex];
                                    that._editRowIndex = -1;
                                    that._editColumnIndex = -1;
                                    that._beforeCloseEditCellInBatchMode(rowIndices);
                                    dataController.updateItems({
                                        changeType: "update",
                                        rowIndices: rowIndices
                                    })
                                }
                            }
                        })
                    }
                },
                update: function(changeType) {
                    var that = this,
                        dataController = that._dataController;
                    if (dataController && that._pageIndex !== dataController.pageIndex()) {
                        if ("refresh" === changeType) {
                            that.refresh()
                        }
                        that._pageIndex = dataController.pageIndex()
                    }
                    that._updateEditButtons()
                },
                updateFieldValue: function(options, value, text, forceUpdateRow) {
                    var params, that = this,
                        data = {},
                        rowKey = options.key,
                        $cellElement = options.cellElement,
                        editMode = getEditMode(that);
                    if (void 0 !== rowKey && options.column.setCellValue) {
                        if (editMode === DATAGRID_EDIT_MODE_BATCH) {
                            that._applyModified($cellElement, options)
                        }
                        options.value = value;
                        options.column.setCellValue(data, value, text);
                        if (text && options.column.displayValueMap) {
                            options.column.displayValueMap[value] = text
                        }
                        params = {
                            data: data,
                            key: rowKey,
                            oldData: options.data,
                            type: DATA_EDIT_DATA_UPDATE_TYPE
                        };
                        that._addEditData(params);
                        that._updateEditButtons();
                        if (options.column.showEditorAlways && getEditMode(that) === DATAGRID_EDIT_MODE_CELL && options.row && !options.row.inserted) {
                            that.saveEditData().always(function() {
                                that._editColumnIndex = options.columnIndex;
                                that._editRowIndex = options.row.rowIndex;
                                that._focusEditingCell()
                            })
                        } else {
                            if (options.row && (forceUpdateRow || options.column.setCellValue !== options.column.defaultSetCellValue)) {
                                that._dataController.updateItems({
                                    changeType: "update",
                                    rowIndices: [options.row.rowIndex]
                                })
                            }
                        }
                    }
                },
                _addEditData: function(options) {
                    var that = this,
                        editDataIndex = getIndexByKey(options.key, that._editData);
                    if (editDataIndex < 0) {
                        editDataIndex = that._editData.length;
                        that._editData.push(options)
                    }
                    if (that._editData[editDataIndex]) {
                        options.type = that._editData[editDataIndex].type || options.type;
                        objectUtils.deepExtendArraySafe(that._editData[editDataIndex], {
                            data: options.data,
                            type: options.type
                        })
                    }
                    return editDataIndex
                },
                _getFormEditItemTemplate: function(cellOptions, column) {
                    return column.editCellTemplate || getDefaultEditorTemplate(this)
                },
                getFormEditorTemplate: function(detailCellOptions, column, item) {
                    var that = this;
                    return function(options, $container) {
                        var cellOptions = $.extend({}, detailCellOptions, {
                                cellElement: null,
                                item: item,
                                value: column.calculateCellValue(detailCellOptions.data),
                                column: $.extend({}, column, {
                                    editorOptions: item.editorOptions
                                }),
                                id: options.component.getItemID(item.name || item.dataField),
                                columnIndex: column.index,
                                setValue: column.allowEditing && function(value) {
                                    that.updateFieldValue(cellOptions, value)
                                }
                            }),
                            template = $.proxy(that._getFormEditItemTemplate, that)(cellOptions, column);
                        that._rowsView.renderTemplate($container, template, cellOptions)
                    }
                },
                getEditFormTemplate: function() {
                    var that = this;
                    return function($container, detailOptions) {
                        var editFormOptions = that.option("editing.form"),
                            items = that.option("editing.form.items"),
                            userCustomizeItem = that.option("editing.form.customizeItem");
                        if (!items) {
                            var columns = that.getController("columns").getColumns();
                            items = [];
                            $.each(columns, function(_, column) {
                                items.push({
                                    column: column,
                                    name: column.name,
                                    dataField: column.dataField
                                })
                            })
                        }
                        that._createComponent($("<div>").appendTo($container), Form, $.extend({}, editFormOptions, {
                            items: items,
                            formID: new Guid,
                            customizeItem: function(item) {
                                var column = item.column || that._columnsController.columnOption(item.name || item.dataField);
                                if (column) {
                                    item.label = item.label || {};
                                    item.label.text = item.label.text || column.caption;
                                    item.template = item.template || that.getFormEditorTemplate(detailOptions, column, item);
                                    item.column = column;
                                    if (column.formItem) {
                                        $.extend(item, column.formItem)
                                    }
                                }
                                userCustomizeItem && userCustomizeItem.call(this, item)
                            }
                        }));
                        var $buttonsContainer = $("<div>").addClass("dx-datagrid-form-buttons-container").appendTo($container);
                        that._createComponent($("<div>").appendTo($buttonsContainer), Button, {
                            text: that.option("editing.texts.saveRowChanges"),
                            onClick: $.proxy(that.saveEditData, that)
                        });
                        that._createComponent($("<div>").appendTo($buttonsContainer), Button, {
                            text: that.option("editing.texts.cancelRowChanges"),
                            onClick: $.proxy(that.cancelEditData, that)
                        })
                    }
                },
                getColumnTemplate: function(options) {
                    var template, editingOptions, editingTexts, allowUpdating, editingStartOptions, that = this,
                        column = options.column,
                        rowIndex = options.row && options.row.rowIndex,
                        isRowMode = isRowEditMode(that),
                        isRowEditing = that.isEditRow(rowIndex),
                        isCellEditing = that.isEditCell(rowIndex, options.columnIndex);
                    if ((column.showEditorAlways || column.setCellValue && (isRowEditing && column.allowEditing || isCellEditing)) && ("data" === options.rowType || "detailAdaptive" === options.rowType) && !column.command) {
                        allowUpdating = that.option("editing.allowUpdating");
                        if (((allowUpdating || isRowEditing) && column.allowEditing || isCellEditing) && (isRowMode && isRowEditing || !isRowMode)) {
                            if (column.showEditorAlways && !isRowMode) {
                                editingStartOptions = {
                                    cancel: false,
                                    key: options.row.key,
                                    data: options.row.data,
                                    column: column
                                };
                                that._isEditingStart(editingStartOptions)
                            }
                            if (!editingStartOptions || !editingStartOptions.cancel) {
                                options.setValue = function(value, text) {
                                    that.updateFieldValue(options, value, text)
                                }
                            }
                        }
                        template = column.editCellTemplate || getDefaultEditorTemplate(that)
                    } else {
                        if ("edit" === column.command && "data" === options.rowType) {
                            template = function(container, options) {
                                var createLink = function(container, text, methodName, options) {
                                    var $link = $("<a />").addClass(DATAGRID_LINK_CLASS).text(text).on(addNamespace(clickEvent.name, DATAGRID_EDITING_NAMESPACE), that.createAction(function(params) {
                                        var e = params.jQueryEvent;
                                        e.stopPropagation();
                                        setTimeout(function() {
                                            options.row && that[methodName](options.row.rowIndex)
                                        })
                                    }));
                                    options.rtlEnabled ? container.prepend($link, "&nbsp;") : container.append($link, "&nbsp;")
                                };
                                container.css("text-align", "center");
                                options.rtlEnabled = that.option("rtlEnabled");
                                editingOptions = that.option("editing") || {};
                                editingTexts = editingOptions.texts || {};
                                if (options.row && options.row.rowIndex === that._editRowIndex && isRowMode) {
                                    createLink(container, editingTexts.saveRowChanges, "saveEditData", options);
                                    createLink(container, editingTexts.cancelRowChanges, "cancelEditData", options)
                                } else {
                                    if (editingOptions.allowUpdating && isRowMode) {
                                        createLink(container, editingTexts.editRow, "editRow", options)
                                    }
                                    if (editingOptions.allowDeleting) {
                                        if (options.row.removed) {
                                            createLink(container, editingTexts.undeleteRow, "undeleteRow", options)
                                        } else {
                                            createLink(container, editingTexts.deleteRow, "deleteRow", options)
                                        }
                                    }
                                }
                            }
                        } else {
                            if ("detail" === column.command && "detail" === options.rowType && isRowEditing) {
                                template = that.getEditFormTemplate(options)
                            }
                        }
                    }
                    return template
                },
                prepareEditButtons: function(headerPanel) {
                    var that = this,
                        editingOptions = that.option("editing") || {},
                        editingTexts = that.option("editing.texts") || {},
                        titleButtonTextByClassNames = {
                            cancel: editingTexts.cancelAllChanges,
                            save: editingTexts.saveAllChanges,
                            addrow: editingTexts.addRow
                        },
                        buttonItems = [];
                    var prepareButtonItem = function(className, methodName) {
                        var onInitialized = function(e) {
                                e.element.addClass(headerPanel._getToolbarButtonClass(DATAGRID_EDIT_BUTTON_CLASS + " dx-datagrid-" + className + "-button"))
                            },
                            hintText = titleButtonTextByClassNames[className],
                            isButtonDisabled = ("save" === className || "cancel" === className) && !that.hasChanges();
                        return {
                            widget: "dxButton",
                            options: {
                                onInitialized: onInitialized,
                                icon: "edit-button-" + className,
                                disabled: isButtonDisabled,
                                onClick: function(options) {
                                    that[methodName]()
                                },
                                text: hintText,
                                hint: hintText
                            },
                            showText: "inMenu",
                            name: className + "Button",
                            disabled: isButtonDisabled,
                            location: "after",
                            locateInMenu: "auto"
                        }
                    };
                    if (editingOptions.allowAdding) {
                        buttonItems.push(prepareButtonItem("addrow", "addRow"))
                    }
                    if ((editingOptions.allowUpdating || editingOptions.allowAdding || editingOptions.allowDeleting) && getEditMode(that) === DATAGRID_EDIT_MODE_BATCH) {
                        buttonItems.push(prepareButtonItem("save", "saveEditData"));
                        buttonItems.push(prepareButtonItem("cancel", "cancelEditData"))
                    }
                    return buttonItems
                },
                createHighlightCell: function($cell) {
                    var $highlight = $cell.find("." + DATAGRID_CELL_HIGHLIGHT_OUTLINE);
                    if (!$highlight.length) {
                        $cell.wrapInner($("<div>").addClass(DATAGRID_CELL_HIGHLIGHT_OUTLINE + " " + DATAGRID_POINTER_EVENTS_TARGET_CLASS))
                    }
                },
                resetRowAndPageIndices: function(alwaysRest) {
                    var that = this;
                    $.each(that._editData, function(_, editData) {
                        if (editData.pageIndex !== that._pageIndex || alwaysRest) {
                            delete editData.pageIndex;
                            delete editData.rowIndex
                        }
                    })
                },
                _afterInsertRow: function(options) {},
                _beforeSaveEditData: function(editData, editIndex) {},
                _afterSaveEditData: function() {},
                _beforeCancelEditData: function() {}
            }
        }());
        gridCore.registerModule("editing", {
            defaultOptions: function() {
                return {
                    editing: {
                        mode: "row",
                        allowAdding: false,
                        allowUpdating: false,
                        allowDeleting: false,
                        texts: {
                            editRow: messageLocalization.format("dxDataGrid-editingEditRow"),
                            saveAllChanges: messageLocalization.format("dxDataGrid-editingSaveAllChanges"),
                            saveRowChanges: messageLocalization.format("dxDataGrid-editingSaveRowChanges"),
                            cancelAllChanges: messageLocalization.format("dxDataGrid-editingCancelAllChanges"),
                            cancelRowChanges: messageLocalization.format("dxDataGrid-editingCancelRowChanges"),
                            addRow: messageLocalization.format("dxDataGrid-editingAddRow"),
                            deleteRow: messageLocalization.format("dxDataGrid-editingDeleteRow"),
                            undeleteRow: messageLocalization.format("dxDataGrid-editingUndeleteRow"),
                            confirmDeleteMessage: messageLocalization.format("dxDataGrid-editingConfirmDeleteMessage"),
                            confirmDeleteTitle: ""
                        },
                        form: {
                            colCount: 2
                        }
                    }
                }
            },
            controllers: {
                editing: exports.EditingController
            },
            extenders: {
                controllers: {
                    data: {
                        init: function() {
                            this._editingController = this.getController("editing");
                            this.callBase()
                        },
                        reload: function(full) {
                            var d, editingController = this.getController("editing");
                            this._editingController.refresh();
                            d = this.callBase(full);
                            return d && d.done(function() {
                                editingController.resetRowAndPageIndices(true)
                            })
                        },
                        _updateItemsCore: function(change) {
                            this.callBase(change);
                            var editFormItem = this.items()[this.getController("editing").getEditFormRowIndex()];
                            if (editFormItem) {
                                editFormItem.rowType = "detail"
                            }
                        },
                        _processItems: function(items, changeType) {
                            items = this._editingController.processItems(items, changeType);
                            return this.callBase(items, changeType)
                        },
                        _processDataItem: function(dataItem, options) {
                            this._editingController.processDataItem(dataItem, options.visibleColumns, this.generateDataValues);
                            return this.callBase(dataItem, options)
                        },
                        _processItem: function(item, options) {
                            item = this.callBase(item, options);
                            if (item.inserted) {
                                options.dataIndex--;
                                delete item.dataIndex
                            }
                            return item
                        }
                    },
                    columnsResizer: {
                        _startResizing: function(args) {
                            var that = this,
                                editingController = that.getController("editing"),
                                isCellEditing = function() {
                                    var editingOptions = that.option("editing");
                                    return editingOptions && editingOptions.mode !== DATAGRID_EDIT_MODE_ROW && editingController.isEditing()
                                };
                            that.callBase(args);
                            if (that.isResizing() && isCellEditing()) {
                                editingController.closeEditCell()
                            }
                        }
                    }
                },
                views: {
                    rowsView: {
                        publicMethods: function() {
                            return this.callBase().concat(["cellValue"])
                        },
                        _getCellTemplate: function(options) {
                            var that = this,
                                template = that.getController("editing").getColumnTemplate(options);
                            return template || that.callBase(options)
                        },
                        _isNativeClick: function() {
                            return (devices.real().ios || devices.real().android) && this.option("editing.allowUpdating")
                        },
                        _createTable: function() {
                            var that = this,
                                $table = that.callBase.apply(that, arguments);
                            if (!isRowEditMode(that) && that.option("editing.allowUpdating")) {
                                $table.on(addNamespace(holdEvent.name, "dxDataGridRowsView"), "td:not(." + DATAGRID_EDITOR_CELL_CLASS + ")", that.createAction(function(e) {
                                    var editingController = that.getController("editing");
                                    if (editingController.isEditing()) {
                                        editingController.closeEditCell()
                                    }
                                }))
                            }
                            return $table
                        },
                        _createRow: function(row) {
                            var editingController, isEditRow, isRowRemoved, isRowInserted, isRowModified, $row = this.callBase(row);
                            if (row) {
                                editingController = this.getController("editing");
                                isEditRow = editingController.isEditRow(row.rowIndex);
                                isRowRemoved = !!row.removed;
                                isRowInserted = !!row.inserted;
                                isRowModified = !!row.modified;
                                if (getEditMode(this) === DATAGRID_EDIT_MODE_BATCH) {
                                    isRowRemoved && $row.addClass(DATAGRID_ROW_REMOVED)
                                } else {
                                    isEditRow && $row.addClass(DATAGRID_EDIT_ROW)
                                }
                                isRowInserted && $row.addClass(DATAGRID_ROW_INSERTED);
                                isRowModified && $row.addClass(DATAGRID_ROW_MODIFIED);
                                if (isEditRow || isRowInserted || isRowRemoved) {
                                    $row.removeClass(DATAGRID_ROW_SELECTED)
                                }
                                if (isEditRow && "detail" === row.rowType) {
                                    $row.addClass(DATAGRID_EDIT_FORM_CLASS)
                                }
                            }
                            return $row
                        },
                        _getColumnIndexByElement: function($element) {
                            var $targetElement = $element.closest("." + DATAGRID_ROW_CLASS + "> td:not(.dx-master-detail-cell)");
                            return this.getCellIndex($targetElement)
                        },
                        _rowClick: function(e) {
                            var that = this,
                                editingController = that.getController("editing"),
                                $targetElement = $(e.jQueryEvent.target),
                                columnIndex = that._getColumnIndexByElement($targetElement),
                                allowUpdating = that.option("editing.allowUpdating"),
                                column = that._columnsController.getVisibleColumns()[columnIndex],
                                allowEditing = column && (column.allowEditing || editingController.isEditCell(e.rowIndex, columnIndex));
                            if ($targetElement.closest("." + DATAGRID_ROW_CLASS + "> td").hasClass(DATAGRID_POINTER_EVENTS_NONE_CLASS)) {
                                return
                            }
                            if (!(allowUpdating && allowEditing && editingController.editCell(e.rowIndex, columnIndex)) && !editingController.isEditRow(e.rowIndex)) {
                                that.callBase(e)
                            }
                        },
                        _cellPrepared: function($cell, parameters) {
                            var columnIndex = parameters.columnIndex,
                                editingController = this.getController("editing"),
                                isCommandCell = !!parameters.column.command,
                                isEditableCell = parameters.setValue;
                            parameters.isEditing = editingController.isEditCell(parameters.rowIndex, parameters.columnIndex) || editingController.isEditRow(parameters.rowIndex) && parameters.column.allowEditing;
                            if (!parameters.column.command && (parameters.isEditing || parameters.column.showEditorAlways)) {
                                var alignment = parameters.column.alignment;
                                $cell.addClass(DATAGRID_EDITOR_CELL_CLASS).toggleClass(DATAGRID_READONLY_CLASS, !isEditableCell).toggleClass(DATAGRID_CELL_FOCUS_DISABLED_CLASS, !isEditableCell);
                                if (alignment) {
                                    $cell.find("input").first().css("text-align", alignment)
                                }
                            }
                            var modifiedValues = parameters.row && (parameters.row.inserted ? parameters.row.values : parameters.row.modifiedValues);
                            if (modifiedValues && void 0 !== modifiedValues[columnIndex] && parameters.column && !isCommandCell && parameters.column.setCellValue) {
                                editingController.createHighlightCell($cell);
                                $cell.addClass(DATAGRID_CELL_MODIFIED)
                            } else {
                                if (isEditableCell) {
                                    editingController.createHighlightCell($cell, true)
                                }
                            }
                            this.callBase.apply(this, arguments)
                        },
                        _formItemPrepared: function(cellOptions, $container) {},
                        _updateCell: function($cell, parameters) {
                            if ("detail" === parameters.rowType && parameters.item) {
                                this._formItemPrepared(parameters, $cell)
                            } else {
                                this.callBase($cell, parameters)
                            }
                        },
                        _update: function(change) {
                            this.callBase(change);
                            if ("updateSelection" === change.changeType) {
                                this.getTableElements().children("tbody").children("." + DATAGRID_EDIT_ROW).removeClass(DATAGRID_ROW_SELECTED)
                            }
                        },
                        cellValue: function(rowIndex, columnIdentificator, value, text) {
                            var cellOptions = this.getCellOptions(rowIndex, columnIdentificator);
                            if (cellOptions) {
                                if (void 0 === value) {
                                    return cellOptions.value
                                } else {
                                    this.getController("editing").updateFieldValue(cellOptions, value, text, true)
                                }
                            }
                        }
                    },
                    headerPanel: {
                        _getToolbarItems: function() {
                            var items = this.callBase(),
                                editButtonItems = this.getController("editing").prepareEditButtons(this);
                            return editButtonItems.concat(items)
                        },
                        optionChanged: function(args) {
                            switch (args.name) {
                                case "editing":
                                    this._invalidateToolbarItems();
                                    this.callBase(args);
                                    break;
                                default:
                                    this.callBase(args)
                            }
                        },
                        isVisible: function() {
                            var that = this,
                                editingOptions = that.getController("editing").option("editing");
                            return that.callBase() || editingOptions && (editingOptions.allowAdding || (editingOptions.allowUpdating || editingOptions.allowDeleting) && editingOptions.mode === DATAGRID_EDIT_MODE_BATCH)
                        }
                    }
                }
            }
        })
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.editor_factory.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isWrapped = __webpack_require__( /*! ../../core/utils/variable_wrapper */ 38).isWrapped,
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            positionUtils = __webpack_require__( /*! ../../animation/position */ 61),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            normalizeDataSourceOptions = __webpack_require__( /*! ../../data/data_source/data_source */ 155).normalizeDataSourceOptions,
            addNamespace = eventUtils.addNamespace;
        __webpack_require__( /*! ../text_box */ 206);
        __webpack_require__( /*! ../number_box */ 255);
        __webpack_require__( /*! ../check_box */ 241);
        __webpack_require__( /*! ../select_box */ 307);
        __webpack_require__( /*! ../date_box */ 259);
        var DATAGRID_CHECKBOX_SIZE_CLASS = "dx-datagrid-checkbox-size",
            DATAGRID_CELL_FOCUS_DISABLED_CLASS = "dx-cell-focus-disabled",
            DATAGRID_EDITOR_INLINE_BLOCK = "dx-editor-inline-block",
            DATAGRID_MODULE_NAMESPACE = "dxDataGridEditorFactory",
            DATAGRID_UPDATE_FOCUS_EVENTS = addNamespace([pointerEvents.down, "focusin", clickEvent.name].join(" "), DATAGRID_MODULE_NAMESPACE),
            DATAGRID_FOCUS_OVERLAY_CLASS = "dx-datagrid-focus-overlay",
            DATAGRID_FOCUSED_ELEMENT_CLASS = "dx-focused",
            DATAGRID_CONTENT_CLASS = "dx-datagrid-content",
            DATAGRID_POINTER_EVENTS_TARGET_CLASS = "dx-pointer-events-target",
            DATAGRID_POINTER_EVENTS_NONE_CLASS = "dx-pointer-events-none",
            DX_HIDDEN = "dx-hidden",
            TAB_KEY = 9;
        exports.EditorFactoryController = gridCore.ViewController.inherit(function() {
            var getResultConfig = function(config, options) {
                return $.extend(config, {
                    readOnly: options.readOnly,
                    placeholder: options.placeholder,
                    attr: {
                        id: options.id
                    }
                }, options.editorOptions)
            };
            var getTextEditorConfig = function(options) {
                var isEnterBug = browser.msie && parseInt(browser.version) <= 11 || devices.real().ios,
                    isValueChanged = false,
                    data = {},
                    sharedData = options.sharedData || data;
                return getResultConfig({
                    placeholder: options.placeholder,
                    width: options.width,
                    value: options.value,
                    onValueChanged: function(e) {
                        var updateValue = function(e, notFireEvent) {
                            isValueChanged = false;
                            options && options.setValue(e.value, notFireEvent)
                        };
                        window.clearTimeout(data.valueChangeTimeout);
                        if (e.jQueryEvent && "keyup" === e.jQueryEvent.type) {
                            if ("filterRow" === options.parentType || "searchPanel" === options.parentType) {
                                sharedData.valueChangeTimeout = data.valueChangeTimeout = window.setTimeout(function() {
                                    updateValue(e, data.valueChangeTimeout !== sharedData.valueChangeTimeout)
                                }, commonUtils.isDefined(options.updateValueTimeout) ? options.updateValueTimeout : 0)
                            } else {
                                isValueChanged = true
                            }
                        } else {
                            updateValue(e)
                        }
                    },
                    onFocusOut: function(e) {
                        if (isEnterBug && isValueChanged) {
                            isValueChanged = false;
                            options.setValue(e.component.option("value"))
                        }
                    },
                    onKeyDown: function(e) {
                        if (isEnterBug && isValueChanged && 13 === e.jQueryEvent.keyCode) {
                            isValueChanged = false;
                            options.setValue(e.component.option("value"))
                        }
                    },
                    valueChangeEvent: "change" + ("filterRow" === options.parentType || isEnterBug ? " keyup" : "")
                }, options)
            };
            var prepareDateBox = function(options) {
                options.editorName = "dxDateBox";
                options.editorOptions = getResultConfig({
                    value: options.value,
                    onValueChanged: function(args) {
                        options.setValue(args.value)
                    },
                    displayFormat: commonUtils.isString(options.format) && dateLocalization.getPatternByFormat(options.format) || options.format,
                    formatWidthCalculator: null,
                    width: "auto"
                }, options)
            };
            var prepareTextBox = function(options) {
                var config = getTextEditorConfig(options),
                    isSearching = "searchPanel" === options.parentType,
                    toString = function(value) {
                        return commonUtils.isDefined(value) ? value.toString() : ""
                    };
                config.value = toString(options.value);
                config.valueChangeEvent += isSearching ? " keyup search" : "";
                config.mode = isSearching ? "search" : "text";
                options.editorName = "dxTextBox";
                options.editorOptions = config
            };
            var prepareNumberBox = function(options) {
                var config = getTextEditorConfig(options);
                config.value = commonUtils.isDefined(options.value) ? options.value : null;
                options.editorName = "dxNumberBox";
                options.editorOptions = config
            };
            var prepareBooleanEditor = function(options) {
                if ("filterRow" === options.parentType) {
                    prepareSelectBox($.extend(options, {
                        lookup: {
                            displayExpr: function(data) {
                                if (true === data) {
                                    return options.trueText || "true"
                                } else {
                                    if (false === data) {
                                        return options.falseText || "false"
                                    }
                                }
                            },
                            dataSource: [true, false]
                        }
                    }))
                } else {
                    prepareCheckBox(options)
                }
            };
            var prepareSelectBox = function(options) {
                var displayGetter, dataSource, postProcess, lookup = options.lookup,
                    isFilterRow = "filterRow" === options.parentType;
                if (lookup) {
                    displayGetter = compileGetter(lookup.displayExpr);
                    dataSource = lookup.dataSource;
                    if (commonUtils.isFunction(dataSource) && !isWrapped(dataSource)) {
                        dataSource = dataSource(options.row || {})
                    }
                    if (commonUtils.isObject(dataSource) || commonUtils.isArray(dataSource)) {
                        dataSource = normalizeDataSourceOptions(dataSource);
                        if (isFilterRow) {
                            postProcess = dataSource.postProcess;
                            dataSource.postProcess = function(items) {
                                if (0 === this.pageIndex()) {
                                    items = items.slice(0);
                                    items.unshift(null)
                                }
                                if (postProcess) {
                                    return postProcess.call(this, items)
                                }
                                return items
                            }
                        }
                    }
                    options.editorName = "dxSelectBox";
                    options.editorOptions = getResultConfig({
                        searchEnabled: true,
                        value: options.value,
                        valueExpr: options.lookup.valueExpr,
                        searchExpr: options.lookup.searchExpr || options.lookup.displayExpr,
                        showClearButton: Boolean(lookup.allowClearing && !isFilterRow),
                        displayExpr: function(data) {
                            if (null === data) {
                                return options.showAllText
                            }
                            return displayGetter(data)
                        },
                        dataSource: dataSource,
                        onValueChanged: function(e) {
                            var params = [e.value];
                            !isFilterRow && params.push(e.component.option("text"));
                            options.setValue.apply(this, params)
                        }
                    }, options)
                }
            };
            var prepareCheckBox = function(options) {
                options.editorName = "dxCheckBox";
                options.editorOptions = getResultConfig({
                    value: options.value,
                    hoverStateEnabled: !options.readOnly,
                    focusStateEnabled: !options.readOnly,
                    activeStateEnabled: false,
                    onValueChanged: function(e) {
                        options.setValue && options.setValue(e.value, e)
                    },
                    tabIndex: options.tabIndex ? options.tabIndex : 0
                }, options)
            };
            var createEditorCore = function(that, options) {
                if (options.editorName && options.editorOptions && options.editorElement[options.editorName]) {
                    if ("dxCheckBox" === options.editorName) {
                        options.editorElement.addClass(DATAGRID_CHECKBOX_SIZE_CLASS);
                        options.editorElement.parent().addClass(DATAGRID_EDITOR_INLINE_BLOCK);
                        if (options.command || options.editorOptions.readOnly) {
                            options.editorElement.parent().addClass(DATAGRID_CELL_FOCUS_DISABLED_CLASS)
                        }
                    }
                    that._createComponent(options.editorElement, options.editorName, options.editorOptions);
                    if ("dxTextBox" === options.editorName) {
                        options.editorElement.dxTextBox("instance").registerKeyHandler("enter", $.noop)
                    }
                }
            };
            return {
                _getFocusedElement: function($dataGridElement) {
                    return $dataGridElement.find("td[tabindex]:focus, input:focus")
                },
                _updateFocusCore: function() {
                    var $focusCell, hideBorders, $focus = this._$focusedElement,
                        $dataGridElement = this.component && this.component.element();
                    if ($dataGridElement) {
                        $focus = this._getFocusedElement($dataGridElement);
                        if ($focus.length) {
                            if (!$focus.hasClass(DATAGRID_CELL_FOCUS_DISABLED_CLASS)) {
                                $focusCell = $focus.closest(".dx-row > td, ." + DATAGRID_CELL_FOCUS_DISABLED_CLASS);
                                hideBorders = $focusCell.get(0) !== $focus.get(0) && $focusCell.hasClass(DATAGRID_EDITOR_INLINE_BLOCK);
                                $focus = $focusCell
                            }
                            if ($focus.length && !$focus.hasClass(DATAGRID_CELL_FOCUS_DISABLED_CLASS)) {
                                this.focus($focus, hideBorders);
                                return
                            }
                        }
                    }
                    this.loseFocus()
                },
                _updateFocus: function(e) {
                    var that = this,
                        isFocusOverlay = e && e.jQueryEvent && $(e.jQueryEvent.target).hasClass(DATAGRID_FOCUS_OVERLAY_CLASS);
                    that._isFocusOverlay = that._isFocusOverlay || isFocusOverlay;
                    clearTimeout(that._updateFocusTimeoutID);
                    that._updateFocusTimeoutID = setTimeout(function() {
                        delete that._updateFocusTimeoutID;
                        if (!that._isFocusOverlay) {
                            that._updateFocusCore()
                        }
                        that._isFocusOverlay = false
                    })
                },
                _updateFocusOverlaySize: function($element, position) {
                    var location = positionUtils.calculate($element, $.extend({
                        collision: "fit"
                    }, position));
                    if (location.h.oversize > 0) {
                        $element.outerWidth($element.outerWidth() - location.h.oversize)
                    }
                    if (location.v.oversize > 0) {
                        $element.outerHeight($element.outerHeight() - location.v.oversize)
                    }
                },
                callbackNames: function() {
                    return ["focused"]
                },
                focus: function($element, hideBorder) {
                    var that = this;
                    if (void 0 === $element) {
                        return that._$focusedElement
                    } else {
                        if ($element) {
                            setTimeout(function() {
                                var focusOverlayPosition, $focusOverlay = that._$focusOverlay = that._$focusOverlay || $("<div>").addClass(DATAGRID_FOCUS_OVERLAY_CLASS + " " + DATAGRID_POINTER_EVENTS_TARGET_CLASS);
                                if (hideBorder) {
                                    that._$focusOverlay && that._$focusOverlay.addClass(DX_HIDDEN)
                                } else {
                                    var align = browser.msie ? "left bottom" : browser.mozilla ? "right bottom" : "left top",
                                        $content = $element.closest("." + DATAGRID_CONTENT_CLASS);
                                    $focusOverlay.removeClass(DX_HIDDEN).appendTo($content).outerWidth($element.outerWidth() + 1).outerHeight($element.outerHeight() + 1);
                                    focusOverlayPosition = {
                                        my: align,
                                        at: align,
                                        of: $element,
                                        boundary: $content.length && $content
                                    };
                                    that._updateFocusOverlaySize($focusOverlay, focusOverlayPosition);
                                    positionUtils.setup($focusOverlay, focusOverlayPosition);
                                    $focusOverlay.css("visibility", "visible")
                                }
                                that._$focusedElement && that._$focusedElement.removeClass(DATAGRID_FOCUSED_ELEMENT_CLASS);
                                $element.addClass(DATAGRID_FOCUSED_ELEMENT_CLASS);
                                that._$focusedElement = $element;
                                that.focused.fire($element)
                            })
                        }
                    }
                },
                resize: function() {
                    var $focusedElement = this._$focusedElement;
                    if ($focusedElement) {
                        this.focus($focusedElement)
                    }
                },
                loseFocus: function() {
                    this._$focusedElement && this._$focusedElement.removeClass(DATAGRID_FOCUSED_ELEMENT_CLASS);
                    this._$focusedElement = null;
                    this._$focusOverlay && this._$focusOverlay.addClass(DX_HIDDEN)
                },
                init: function() {
                    this.createAction("onEditorPreparing", {
                        excludeValidators: ["designMode", "disabled", "readOnly"],
                        category: "rendering"
                    });
                    this.createAction("onEditorPrepared", {
                        excludeValidators: ["designMode", "disabled", "readOnly"],
                        category: "rendering"
                    });
                    this._updateFocusHandler = this._updateFocusHandler || this.createAction($.proxy(this._updateFocus, this));
                    $(document).on(DATAGRID_UPDATE_FOCUS_EVENTS, this._updateFocusHandler);
                    this._attachContainerEventHandlers()
                },
                _attachContainerEventHandlers: function() {
                    var that = this,
                        $container = that.component && that.component.element(),
                        isIE10OrLower = browser.msie && parseInt(browser.version) < 11;
                    if ($container) {
                        $container.on(addNamespace("keydown", DATAGRID_MODULE_NAMESPACE), function(e) {
                            if (e.which === TAB_KEY) {
                                that._updateFocusHandler(e)
                            }
                        });
                        isIE10OrLower && $container.on([pointerEvents.down, pointerEvents.up, clickEvent.name].join(" "), "." + DATAGRID_POINTER_EVENTS_TARGET_CLASS, $.proxy(that._focusOverlayEventProxy, that))
                    }
                },
                _focusOverlayEventProxy: function(e) {
                    var element, $target = $(e.target),
                        $currentTarget = $(e.currentTarget),
                        needProxy = $target.hasClass(DATAGRID_POINTER_EVENTS_TARGET_CLASS) || $target.hasClass(DATAGRID_POINTER_EVENTS_NONE_CLASS),
                        $focusedElement = this._$focusedElement;
                    if (!needProxy || $currentTarget.hasClass(DX_HIDDEN)) {
                        return
                    }
                    $currentTarget.addClass(DX_HIDDEN);
                    element = $target.get(0).ownerDocument.elementFromPoint(e.clientX, e.clientY);
                    eventUtils.fireEvent({
                        originalEvent: e,
                        target: element
                    });
                    e.stopPropagation();
                    $currentTarget.removeClass(DX_HIDDEN);
                    $focusedElement && $focusedElement.find("input").focus()
                },
                dispose: function() {
                    clearTimeout(this._updateFocusTimeoutID);
                    $(document).off(DATAGRID_UPDATE_FOCUS_EVENTS, this._updateFocusHandler)
                },
                createEditor: function($container, options) {
                    options.cancel = false;
                    options.editorElement = $container;
                    if (options.lookup) {
                        prepareSelectBox(options)
                    } else {
                        switch (options.dataType) {
                            case "date":
                                prepareDateBox(options);
                                break;
                            case "boolean":
                                prepareBooleanEditor(options);
                                break;
                            case "number":
                                prepareNumberBox(options);
                                break;
                            default:
                                prepareTextBox(options)
                        }
                    }
                    this.executeAction("onEditorPreparing", options);
                    if (options.cancel) {
                        return
                    }
                    createEditorCore(this, options);
                    this.executeAction("onEditorPrepared", options)
                }
            }
        }());
        gridCore.registerModule("editorFactory", {
            defaultOptions: function() {
                return {}
            },
            controllers: {
                editorFactory: exports.EditorFactoryController
            },
            extenders: {
                controllers: {
                    columnsResizer: {
                        _startResizing: function(args) {
                            this.callBase(args);
                            if (this.isResizing()) {
                                this.getController("editorFactory").loseFocus()
                            }
                        }
                    }
                }
            }
        })
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.validation_module.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            Button = __webpack_require__( /*! ../button */ 196),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            ValidationEngine = __webpack_require__( /*! ../validation_engine */ 117),
            Validator = __webpack_require__( /*! ../validator */ 279),
            Tooltip = __webpack_require__( /*! ../tooltip */ 303),
            Overlay = __webpack_require__( /*! ../overlay */ 109);
        __webpack_require__( /*! ./ui.data_grid.editing */ 362);
        var DATAGRID_INVALIDATE_CLASS = "dx-datagrid-invalid",
            DATAGRID_INVALID_MESSAGE_CLASS = "dx-invalid-message",
            DATAGRID_INVALID_MESSAGE_ALWAYS_CLASS = "dx-invalid-message-always",
            DATAGRID_REVERT_BUTTON_CLASS = "dx-revert-button",
            DATAGRID_REVERT_TOOLTIP_CLASS = "dx-datagrid-revert-tooltip",
            DATAGRID_CELL_HIGHLIGHT_OUTLINE = "dx-highlight-outline",
            DATAGRID_INSERT_INDEX = "__DX_INSERT_INDEX__",
            DATAGRID_EDIT_MODE_ROW = "row",
            DATAGRID_EDIT_MODE_FORM = "form",
            DATAGRID_EDIT_MODE_BATCH = "batch",
            DATAGRID_EDIT_MODE_CELL = "cell";
        exports.ValidatingController = gridCore.Controller.inherit(function() {
            return {
                init: function() {
                    this._editingController = this.getController("editing");
                    this.createAction("onRowValidating")
                },
                _rowValidating: function(editData, validate) {
                    var that = this,
                        brokenRules = validate ? validate.brokenRules || validate.brokenRule && [validate.brokenRule] : [],
                        isValid = validate ? validate.isValid : editData.isValid,
                        parameters = {
                            brokenRules: brokenRules,
                            isValid: isValid,
                            key: editData.key,
                            newData: editData.data,
                            oldData: editData.oldData,
                            errorText: null
                        };
                    that.executeAction("onRowValidating", parameters);
                    editData.isValid = parameters.isValid;
                    editData.errorText = parameters.errorText;
                    return parameters
                },
                validate: function(isFull) {
                    var that = this,
                        isValid = true,
                        editingController = that._editingController;
                    isFull = isFull || editingController.getEditMode() === DATAGRID_EDIT_MODE_ROW;
                    if (that._isValidationInProgress) {
                        return false
                    }
                    that._isValidationInProgress = true;
                    if (isFull) {
                        $.each(editingController._editData, function(index, editData) {
                            var validationResult;
                            if (editData.type && "remove" !== editData.type) {
                                validationResult = that.validateGroup(editData);
                                if (!validationResult.isValid) {
                                    $.each(validationResult.brokenRules, function() {
                                        var value = this.validator.option("adapter").getValue();
                                        if (void 0 === value) {
                                            value = null
                                        }
                                        if (this.column) {
                                            editingController.updateFieldValue({
                                                key: editData.key,
                                                column: this.column
                                            }, value, null, true)
                                        }
                                    })
                                }
                                isValid = isValid && validationResult.isValid
                            }
                        })
                    } else {
                        if (that._currentCellValidator) {
                            isValid = that.validateGroup(that._currentCellValidator._findGroup()).isValid
                        }
                    }
                    that._isValidationInProgress = false;
                    return isValid
                },
                validateGroup: function(editData) {
                    var validationResults, that = this,
                        validateGroup = ValidationEngine.getGroupConfig(editData);
                    if (validateGroup && validateGroup.validators.length) {
                        validationResults = ValidationEngine.validateGroup(editData)
                    }
                    return that._rowValidating(editData, validationResults)
                },
                updateEditData: function(editData) {
                    if (this._editingController.getEditMode() !== DATAGRID_EDIT_MODE_FORM) {
                        this.setDisableApplyValidationResults(true);
                        editData.isValid = ValidationEngine.getGroupConfig(editData) ? ValidationEngine.validateGroup(editData).isValid : true;
                        this.setDisableApplyValidationResults(false)
                    } else {
                        editData.isValid = true
                    }
                },
                setValidator: function(validator) {
                    this._currentCellValidator = validator
                },
                getValidator: function() {
                    return this._currentCellValidator
                },
                removeValidators: function(editIndex) {
                    var that = this,
                        editingController = that._editingController;
                    $.each(editingController._editData, function(index, editData) {
                        var validateGroup = ValidationEngine.getGroupConfig(editData);
                        if (!commonUtils.isDefined(editIndex) || editIndex === index) {
                            if (validateGroup) {
                                for (var i = 0; i < validateGroup.validators.length; i++) {
                                    validateGroup.validators[i]._dispose();
                                    i--
                                }
                            }
                        }
                    })
                },
                createValidator: function(parameters, $container) {
                    var editData, editIndex, that = this,
                        editingController = that._editingController,
                        column = parameters.column,
                        defaultValidationResult = function(options) {
                            if (options.brokenRule) {
                                options.brokenRule.columnIndex = column.index;
                                options.brokenRule.column = column
                            }
                            if ($container && !that.getDisableApplyValidationResults()) {
                                if (!options.isValid) {
                                    var $focus = $container.find(":focus");
                                    editingController.createHighlightCell($container, true);
                                    if (!$focus.is(":focus")) {
                                        $focus.focus().trigger(pointerEvents.down)
                                    }
                                }
                                $container.toggleClass(DATAGRID_INVALIDATE_CLASS, !options.isValid)
                            }
                        };
                    if (!column.validationRules || !commonUtils.isArray(column.validationRules) || commonUtils.isDefined(column.command)) {
                        return
                    }
                    editIndex = editingController.getIndexByKey(parameters.key, editingController._editData);
                    if (editIndex < 0 && column.showEditorAlways) {
                        editIndex = editingController._addEditData({
                            key: parameters.key
                        })
                    }
                    if (editIndex >= 0) {
                        editData = editingController._editData[editIndex];
                        return new Validator($container || {}, {
                            name: column.caption,
                            validationRules: $.extend(true, [], column.validationRules),
                            validationGroup: editData,
                            adapter: $container && $container.hasClass("dx-widget") ? null : {
                                getValue: function() {
                                    var value = column.calculateCellValue(editData.data || {});
                                    return void 0 !== value ? value : parameters.value
                                },
                                applyValidationResults: defaultValidationResult
                            }
                        })
                    }
                },
                setDisableApplyValidationResults: function(flag) {
                    this._disableApplyValidationResults = flag
                },
                getDisableApplyValidationResults: function() {
                    return this._disableApplyValidationResults
                }
            }
        }());
        gridCore.registerModule("validating", {
            defaultOptions: function() {
                return {
                    editing: {
                        texts: {
                            validationCancelChanges: messageLocalization.format("dxDataGrid-validationCancelChanges")
                        }
                    }
                }
            },
            controllers: {
                validating: exports.ValidatingController
            },
            extenders: {
                controllers: {
                    editing: {
                        _addEditData: function(options) {
                            var editData, that = this,
                                validatingController = that.getController("validating"),
                                editDataIndex = that.callBase(options);
                            if (editDataIndex >= 0) {
                                editData = that._editData[editDataIndex];
                                validatingController.updateEditData(editData)
                            }
                            return editDataIndex
                        },
                        _updateRowAndPageIndices: function() {
                            var that = this,
                                startInsertIndex = that.getView("rowsView").getTopVisibleItemIndex(),
                                rowIndex = startInsertIndex;
                            $.each(that._editData, function(_, editData) {
                                if (!editData.isValid && editData.pageIndex !== that._pageIndex) {
                                    editData.pageIndex = that._pageIndex;
                                    if ("insert" === editData.type) {
                                        editData.rowIndex = startInsertIndex
                                    } else {
                                        editData.rowIndex = rowIndex
                                    }
                                    rowIndex++
                                }
                            })
                        },
                        _needInsertItem: function(editData, changeType) {
                            var result = this.callBase.apply(this, arguments);
                            if (result && !editData.isValid) {
                                result = editData.key.pageIndex === this._pageIndex
                            }
                            return result
                        },
                        processItems: function(items, changeType) {
                            var i, itemsCount, that = this,
                                insertCount = 0,
                                editData = that._editData,
                                dataController = that.getController("data"),
                                getIndexByEditData = function(editData, items) {
                                    var index = -1,
                                        isInsert = "insert" === editData.type,
                                        key = editData.key;
                                    $.each(items, function(i, item) {
                                        if (gridCoreUtils.equalKeys(key, isInsert ? item : dataController.keyOf(item))) {
                                            index = i;
                                            return false
                                        }
                                    });
                                    return index
                                },
                                addInValidItem = function(editData) {
                                    var rowIndex, data = {
                                            key: editData.key
                                        },
                                        index = getIndexByEditData(editData, items);
                                    if (index >= 0) {
                                        return
                                    }
                                    editData.rowIndex = editData.rowIndex > itemsCount ? editData.rowIndex % itemsCount : editData.rowIndex;
                                    rowIndex = editData.rowIndex;
                                    data[DATAGRID_INSERT_INDEX] = 1;
                                    if (index >= 0) {
                                        items.splice(index, 1);
                                        rowIndex -= insertCount
                                    }
                                    items.splice(rowIndex, 0, data);
                                    insertCount++
                                };
                            items = that.callBase(items, changeType);
                            itemsCount = items.length;
                            if (that.getEditMode() === DATAGRID_EDIT_MODE_BATCH && "prepend" !== changeType && "append" !== changeType) {
                                for (i = 0; i < editData.length; i++) {
                                    if (editData[i].type && editData[i].pageIndex === that._pageIndex && editData[i].key.pageIndex !== that._pageIndex) {
                                        addInValidItem(editData[i])
                                    }
                                }
                            }
                            return items
                        },
                        processDataItem: function(item, columns, generateDataValues) {
                            var editIndex, editData, that = this,
                                isInserted = item.data[DATAGRID_INSERT_INDEX],
                                key = isInserted ? item.data.key : item.key,
                                editMode = that.getEditMode();
                            if (editMode === DATAGRID_EDIT_MODE_BATCH && isInserted && key) {
                                editIndex = gridCoreUtils.getIndexByKey(key, that._editData);
                                if (editIndex >= 0) {
                                    editData = that._editData[editIndex];
                                    if ("insert" !== editData.type) {
                                        item.data = $.extend(true, {}, editData.oldData, editData.data);
                                        item.key = key
                                    }
                                }
                            }
                            that.callBase.apply(that, arguments)
                        },
                        _afterInsertRow: function(options) {
                            var validatingController = this.getController("validating"),
                                invisibleColumns = $.grep(this.getController("columns").getInvisibleColumns(), function(column) {
                                    return !column.isBand
                                });
                            $.each(invisibleColumns, function(_, column) {
                                validatingController.createValidator({
                                    column: column,
                                    key: options.key,
                                    value: column.calculateCellValue(options.data)
                                })
                            });
                            this.callBase(options)
                        },
                        _beforeSaveEditData: function(editData, editIndex) {
                            var isValid, isFullValid, that = this,
                                result = that.callBase.apply(that, arguments),
                                validatingController = that.getController("validating");
                            if (editData) {
                                isValid = "remove" === editData.type || editData.isValid;
                                if (isValid) {
                                    validatingController.removeValidators(editIndex)
                                }
                                result = result || !isValid
                            } else {
                                isFullValid = validatingController.validate(true);
                                that._updateRowAndPageIndices();
                                if (that.getEditMode() === DATAGRID_EDIT_MODE_CELL) {
                                    if (!isFullValid) {
                                        that._focusEditingCell();
                                        result = true
                                    }
                                } else {
                                    if (that.getEditMode() === DATAGRID_EDIT_MODE_ROW) {
                                        result = !isFullValid
                                    }
                                }
                            }
                            return result
                        },
                        _beforeEditCell: function(rowIndex, columnIndex, item) {
                            var result = this.callBase(rowIndex, columnIndex, item),
                                $cell = this.component.getCellElement(rowIndex, columnIndex),
                                validator = $cell.data("dxValidator");
                            if (this.getEditMode(this) === DATAGRID_EDIT_MODE_CELL && (!validator || validator.validate().isValid)) {
                                return result
                            }
                        },
                        _afterSaveEditData: function() {
                            var that = this;
                            $.each(that._editData, function(_, editData) {
                                that._showErrorRow(editData)
                            })
                        },
                        _beforeCancelEditData: function() {
                            var validatingController = this.getController("validating");
                            validatingController.removeValidators();
                            this.callBase()
                        },
                        _showErrorRow: function(editData) {
                            var errorHandling = this.getController("errorHandling"),
                                items = this.getController("data").items(),
                                rowIndex = this.getIndexByKey(editData.key, items);
                            if (!editData.isValid && editData.errorText && rowIndex >= 0) {
                                errorHandling && errorHandling.renderErrorRow(editData.errorText, rowIndex)
                            }
                        },
                        updateFieldValue: function(options, value) {
                            var that = this;
                            that.callBase.apply(that, arguments);
                            if (that.getEditMode() === DATAGRID_EDIT_MODE_ROW) {
                                var currentValidator = that.getController("validating").getValidator();
                                currentValidator && currentValidator.validate()
                            }
                        },
                        createHighlightCell: function($cell, skipValidation) {
                            var validator, isValid = true;
                            if (!skipValidation) {
                                validator = $cell.data("dxValidator");
                                if (validator) {
                                    isValid = validator.validate().isValid
                                }
                            }
                            if (isValid) {
                                this.callBase($cell)
                            }
                        },
                        getEditDataByKey: function(key) {
                            return this._editData[gridCoreUtils.getIndexByKey(key, this._editData)]
                        }
                    },
                    editorFactory: {
                        _showRevertButton: function($cell) {
                            var that = this,
                                $targetElement = $cell.find("." + DATAGRID_CELL_HIGHLIGHT_OUTLINE).first();
                            if ($targetElement.length) {
                                new Tooltip($("<div>").addClass(DATAGRID_REVERT_TOOLTIP_CLASS).appendTo($cell), {
                                    animation: null,
                                    visible: true,
                                    target: $targetElement,
                                    closeOnOutsideClick: false,
                                    closeOnTargetScroll: false,
                                    boundary: that._rowsView.element(),
                                    contentTemplate: function() {
                                        return new Button($("<div>").addClass(DATAGRID_REVERT_BUTTON_CLASS), {
                                            icon: "revert",
                                            hint: that.option("editing.texts.validationCancelChanges"),
                                            onClick: function() {
                                                that._editingController.cancelEditData()
                                            }
                                        }).element()
                                    },
                                    position: {
                                        my: "left top",
                                        at: "right top",
                                        of: $targetElement,
                                        offset: "1 0",
                                        collision: "flip"
                                    }
                                })
                            }
                        },
                        _showValidationMessage: function($cell, message, alignment) {
                            var that = this,
                                $highlightContainer = $cell.find("." + DATAGRID_CELL_HIGHLIGHT_OUTLINE);
                            new Overlay($("<div/>").addClass(DATAGRID_INVALID_MESSAGE_CLASS).addClass(DATAGRID_INVALID_MESSAGE_ALWAYS_CLASS).text(message).appendTo($cell), {
                                target: $highlightContainer.length ? $highlightContainer : $cell,
                                container: $cell,
                                shading: false,
                                width: "auto",
                                height: "auto",
                                visible: true,
                                animation: false,
                                closeOnOutsideClick: false,
                                closeOnTargetScroll: false,
                                position: {
                                    collision: "fit flip",
                                    boundary: that._rowsView.element(),
                                    boundaryOffset: "0 0",
                                    my: "top " + alignment,
                                    at: "bottom " + alignment
                                },
                                onPositioned: function() {
                                    that._rowsView.element() && that._rowsView.updateFreeSpaceRowHeight()
                                }
                            })
                        },
                        init: function() {
                            this.callBase();
                            this._editingController = this.getController("editing");
                            this._rowsView = this.getView("rowsView")
                        },
                        loseFocus: function(skipValidator) {
                            if (!skipValidator) {
                                this.getController("validating").setValidator(null)
                            }
                            this.callBase()
                        },
                        focus: function($element, hideBorder) {
                            var validationResult, that = this,
                                $cell = $element && $element.closest("td"),
                                validator = $cell && $cell.data("dxValidator"),
                                rowOptions = $cell && $cell.parent().data("options"),
                                editData = rowOptions ? that.getController("editing").getEditDataByKey(rowOptions.key) : null,
                                $tooltips = $cell && $cell.closest(".dx-datagrid-rowsview").find(".dx-editor-cell .dx-tooltip, .dx-editor-cell .dx-invalid-message"),
                                column = $cell && that.getController("columns").getVisibleColumns()[$cell.index()];
                            if (!arguments.length) {
                                return that.callBase()
                            }
                            $tooltips && $tooltips.remove();
                            if (validator && column) {
                                that.getController("validating").setValidator(validator);
                                if (void 0 !== validator.option("adapter").getValue()) {
                                    validationResult = validator.validate();
                                    if (!validationResult.isValid) {
                                        hideBorder = true;
                                        that._showValidationMessage($cell, validationResult.brokenRule.message, column.alignment)
                                    }
                                }
                            }
                            if (validationResult && !validationResult.isValid || editData && "update" === editData.type) {
                                if (that._editingController.getEditMode() === DATAGRID_EDIT_MODE_CELL) {
                                    that._showRevertButton($cell)
                                }
                            }!hideBorder && that._rowsView.element() && that._rowsView.updateFreeSpaceRowHeight();
                            return that.callBase($element, hideBorder)
                        }
                    }
                },
                views: {
                    rowsView: {
                        updateFreeSpaceRowHeight: function($table) {
                            var that = this,
                                $rowElements = that._getRowElements(),
                                $freeSpaceRowElements = that._getFreeSpaceRowElements($table),
                                $freeSpaceRowElement = $freeSpaceRowElements.first(),
                                $tooltipContent = that.element().find(".dx-invalid-message .dx-overlay-content");
                            that.callBase($table);
                            if ($tooltipContent.length && $freeSpaceRowElement && 1 === $rowElements.length && (!$freeSpaceRowElement.is(":visible") || $tooltipContent.outerHeight() > $freeSpaceRowElement.outerHeight())) {
                                $freeSpaceRowElements.show();
                                $freeSpaceRowElements.height($tooltipContent.outerHeight())
                            }
                        },
                        _formItemPrepared: function(cellOptions, $container) {
                            this.callBase.apply(this, arguments);
                            this.getController("validating").createValidator(cellOptions, $container.children(".dx-widget"))
                        },
                        _cellPrepared: function($cell, parameters) {
                            this.getController("validating").createValidator(parameters, $cell);
                            this.callBase.apply(this, arguments)
                        }
                    }
                }
            }
        })
    },
    /*!***********************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.virtual_scrolling_module.js ***!
      \***********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            virtualScrollingCore = __webpack_require__( /*! ../grid_core/ui.grid_core.virtual_scrolling */ 366),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            dataSourceAdapter = __webpack_require__( /*! ./ui.data_grid.data_source_adapter */ 344),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            LoadIndicator = __webpack_require__( /*! ../load_indicator */ 231);
        var DATAGRID_TABLE_CLASS = "dx-datagrid-table",
            DATAGRID_ROW_CLASS = "dx-row",
            DATAGRID_FREESPACE_CLASS = "dx-freespace-row",
            DATAGRID_COLUMN_LINES_CLASS = "dx-column-lines",
            DATAGRID_BOTTOM_LOAD_PANEL_CLASS = "dx-datagrid-bottom-load-panel",
            DATAGRID_TABLE_CONTENT_CLASS = "dx-datagrid-table-content",
            DATAGRID_GROUP_SPACE_CLASS = "dx-datagrid-group-space",
            DATAGRID_SCROLLABLE_CONTAINER = "dx-scrollable-container",
            DATAGRID_SCROLLABLE_CONTENT = "dx-scrollable-content",
            DATAGRID_CONTENT_CLASS = "dx-datagrid-content",
            SCROLLING_MODE_INFINITE = "infinite",
            SCROLLING_MODE_VIRTUAL = "virtual",
            PIXELS_LIMIT = 25e4,
            CONTENT_HEIHGT_LIMIT = browser.msie ? 4e6 : 15e6;
        __webpack_require__( /*! ./ui.data_grid.grouping_module */ 357);
        var isVirtualMode = function(that) {
            return that.option("scrolling.mode") === SCROLLING_MODE_VIRTUAL
        };
        var isAppendMode = function(that) {
            return that.option("scrolling.mode") === SCROLLING_MODE_INFINITE
        };
        var VirtualScrollingDataSourceAdapterExtender = function() {
            var updateLoading = function(that) {
                var beginPageIndex = that._virtualScrollController.beginPageIndex(-1);
                if (isVirtualMode(that)) {
                    if (beginPageIndex < 0 || that.viewportSize() >= 0 && that.getViewportItemIndex() >= 0 && (beginPageIndex * that.pageSize() > that.getViewportItemIndex() || beginPageIndex * that.pageSize() + that.itemsCount() < that.getViewportItemIndex() + that.viewportSize()) && that._dataSource.isLoading()) {
                        if (!that._isLoading) {
                            that._isLoading = true;
                            that.loadingChanged.fire(true)
                        }
                    } else {
                        if (that._isLoading) {
                            that._isLoading = false;
                            that.loadingChanged.fire(false)
                        }
                    }
                }
            };
            return {
                init: function(dataSource) {
                    var that = this;
                    that.callBase.apply(that, arguments);
                    that._isLoading = true;
                    that._items = [];
                    that._isLoaded = true;
                    that._virtualScrollController = new virtualScrollingCore.VirtualScrollController(that.component, {
                        pageSize: function() {
                            return that.pageSize()
                        },
                        totalItemsCount: function() {
                            return that.totalItemsCount()
                        },
                        hasKnownLastPage: function() {
                            return that.hasKnownLastPage()
                        },
                        pageIndex: function(index) {
                            return dataSource.pageIndex(index)
                        },
                        isLoading: function() {
                            return dataSource.isLoading()
                        },
                        pageCount: function() {
                            return that.pageCount()
                        },
                        load: function() {
                            return dataSource.load()
                        },
                        updateLoading: function() {
                            updateLoading(that)
                        },
                        itemsCount: function() {
                            return that.itemsCount(true)
                        },
                        items: function() {
                            return dataSource.items()
                        },
                        viewportItems: function(items) {
                            if (items) {
                                that._items = items
                            }
                            return that._items
                        },
                        onChanged: function(e) {
                            that.changed.fire(e)
                        }
                    })
                },
                _handleLoadingChanged: function(isLoading) {
                    var that = this;
                    if (!isVirtualMode(that)) {
                        that._isLoading = isLoading;
                        that.callBase.apply(that, arguments)
                    }
                },
                _handleLoadError: function() {
                    var that = this;
                    that._isLoading = false;
                    that.loadingChanged.fire(false);
                    that.callBase.apply(that, arguments)
                },
                _handleDataChanged: function() {
                    var callBase = $.proxy(this.callBase, this);
                    this._virtualScrollController.handleDataChanged(callBase)
                },
                items: function() {
                    return this._items
                },
                itemsCount: function(isBase) {
                    if (isBase) {
                        return this.callBase()
                    }
                    return this._virtualScrollController.itemsCount()
                },
                virtualItemsCount: function() {
                    return this._virtualScrollController.virtualItemsCount()
                },
                getViewportItemIndex: function() {
                    return this._virtualScrollController.getViewportItemIndex()
                },
                setViewportItemIndex: function(itemIndex) {
                    return this._virtualScrollController.setViewportItemIndex(itemIndex)
                },
                viewportSize: function(size) {
                    return this._virtualScrollController.viewportSize(size)
                },
                pageIndex: function(pageIndex) {
                    return this._virtualScrollController.pageIndex(pageIndex)
                },
                beginPageIndex: function() {
                    return this._virtualScrollController.beginPageIndex()
                },
                endPageIndex: function() {
                    return this._virtualScrollController.endPageIndex()
                },
                load: function(loadOptions) {
                    if (loadOptions) {
                        return this.callBase(loadOptions)
                    }
                    return this._virtualScrollController.load()
                },
                loadIfNeed: function() {
                    return this._virtualScrollController.loadIfNeed()
                },
                isLoading: function() {
                    return this._isLoading
                },
                isLoaded: function() {
                    return this._dataSource.isLoaded() && this._isLoaded
                },
                _changeRowExpandCore: function() {
                    var result = this.callBase.apply(this, arguments);
                    this._virtualScrollController.reset();
                    updateLoading(this);
                    return result
                },
                refresh: function(options, isReload, operationTypes) {
                    var that = this,
                        storeLoadOptions = options.storeLoadOptions,
                        dataSource = that._dataSource;
                    if (isReload || operationTypes.reload) {
                        that._virtualScrollController.reset();
                        that._isLoaded = false;
                        updateLoading(that);
                        that._isLoaded = true;
                        if (isAppendMode(that)) {
                            that.pageIndex(0);
                            dataSource.pageIndex(0);
                            storeLoadOptions.pageIndex = 0;
                            storeLoadOptions.skip = 0
                        } else {
                            dataSource.pageIndex(that.pageIndex());
                            if (dataSource.paginate()) {
                                storeLoadOptions.skip = that.pageIndex() * that.pageSize()
                            }
                        }
                    }
                    return that.callBase.apply(that, arguments)
                }
            }
        }();
        dataSourceAdapter.extend(VirtualScrollingDataSourceAdapterExtender);
        var VirtualScrollingRowsViewExtender = function() {
            return {
                init: function() {
                    var that = this,
                        dataController = that.getController("data");
                    that.callBase();
                    dataController.pageChanged.add(function() {
                        that.scrollToPage(dataController.pageIndex())
                    })
                },
                scrollToPage: function(pageIndex) {
                    var scrollPosition, that = this,
                        dataController = that._dataController,
                        pageSize = dataController ? dataController.pageSize() : 0;
                    if (isVirtualMode(that) || isAppendMode(that)) {
                        scrollPosition = pageIndex * that._rowHeight * pageSize
                    } else {
                        scrollPosition = 0
                    }
                    that.scrollTo({
                        y: scrollPosition,
                        x: that._scrollLeft
                    })
                },
                _renderCore: function() {
                    var that = this,
                        startRenderDate = new Date;
                    that.callBase.apply(that, arguments);
                    that._updateContentPosition();
                    that._renderTime = new Date - startRenderDate
                },
                _renderContent: function(contentElement, tableElement) {
                    var that = this,
                        virtualItemsCount = that._dataController.virtualItemsCount();
                    if (virtualItemsCount) {
                        tableElement.addClass(DATAGRID_TABLE_CONTENT_CLASS);
                        if (!contentElement.children().length) {
                            contentElement.append(tableElement)
                        } else {
                            contentElement.children().first().replaceWith(tableElement)
                        }
                        if (1 === contentElement.children("table").length) {
                            contentElement.append(that._createTable());
                            that._contentHeight = 0
                        }
                        return contentElement
                    } else {
                        return that.callBase.apply(that, arguments)
                    }
                },
                _updateContent: function(tableElement, change) {
                    var contentTable, that = this,
                        contentElement = that._findContentElement(),
                        changeType = change && change.changeType;
                    if ("append" === changeType || "prepend" === changeType) {
                        contentTable = contentElement.children().first();
                        tableElement.children("tbody").children("tr")["append" === changeType ? "appendTo" : "prependTo"](contentTable);
                        tableElement.remove();
                        that._getFreeSpaceRowElements().not(":last").remove()
                    } else {
                        that.callBase.apply(that, arguments)
                    }
                    that._updateBottomLoading()
                },
                _updateContentPosition: commonUtils.deferUpdater(function() {
                    var contentElement, contentHeight, $tables, $contentTable, virtualTable, isRenderVirtualTableContentRequired, that = this,
                        rowHeight = that._rowHeight || 20,
                        virtualItemsCount = that._dataController.virtualItemsCount();
                    if (virtualItemsCount) {
                        contentElement = that._findContentElement();
                        $tables = contentElement.children();
                        $contentTable = $tables.eq(0);
                        virtualTable = $tables.eq(1);
                        that._contentTableHeight = $contentTable.outerHeight();
                        contentHeight = (virtualItemsCount.begin + virtualItemsCount.end + that._dataController.itemsCount()) * that._rowHeight;
                        if (contentHeight > CONTENT_HEIHGT_LIMIT) {
                            that._heightRatio = CONTENT_HEIHGT_LIMIT / contentHeight
                        } else {
                            that._heightRatio = 1
                        }
                        contentHeight = (virtualItemsCount.begin + virtualItemsCount.end) * rowHeight * that._heightRatio + that._contentTableHeight;
                        var top = Math.floor(virtualItemsCount.begin * rowHeight * that._heightRatio);
                        commonUtils.deferRender(function() {
                            translator.move($contentTable, {
                                left: 0,
                                top: top
                            });
                            isRenderVirtualTableContentRequired = that._contentHeight !== contentHeight || 0 === contentHeight || !that._isTableLinesDisplaysCorrect(virtualTable) || !that._isColumnElementsEqual($contentTable.find("col"), virtualTable.find("col"));
                            if (isRenderVirtualTableContentRequired) {
                                that._contentHeight = contentHeight;
                                that._renderVirtualTableContent(virtualTable, contentHeight)
                            }
                            if (that._scrollTop < top && that._dataController.pageIndex() > 0) {
                                that.scrollTo({
                                    top: top,
                                    left: that._scrollLeft
                                })
                            }
                        })
                    }
                }),
                _isTableLinesDisplaysCorrect: function(table) {
                    var hasColumnLines = table.find("." + DATAGRID_COLUMN_LINES_CLASS).length > 0;
                    return hasColumnLines === this.option("showColumnLines")
                },
                _isColumnElementsEqual: function($columns, $virtualColumns) {
                    var result = $columns.length === $virtualColumns.length;
                    if (result) {
                        $.each($columns, function(index, element) {
                            if (element.style.width !== $virtualColumns[index].style.width) {
                                result = false;
                                return result
                            }
                        })
                    }
                    return result
                },
                _renderVirtualTableContent: function(container, height) {
                    var i, that = this,
                        columns = that._columnsController.getVisibleColumns(),
                        html = that._createColGroup(columns).prop("outerHTML"),
                        freeSpaceCellsHtml = "",
                        columnLinesClass = that.option("showColumnLines") ? DATAGRID_COLUMN_LINES_CLASS : "",
                        createFreeSpaceRowHtml = function(height) {
                            return "<tr style='height:" + height + "px;' class='" + DATAGRID_FREESPACE_CLASS + " " + DATAGRID_ROW_CLASS + " " + columnLinesClass + "' >" + freeSpaceCellsHtml + "</tr>"
                        };
                    for (i = 0; i < columns.length; i++) {
                        freeSpaceCellsHtml += "expand" === columns[i].command ? "<td class='" + DATAGRID_GROUP_SPACE_CLASS + "'/>" : "<td />"
                    }
                    while (height > PIXELS_LIMIT) {
                        html += createFreeSpaceRowHtml(PIXELS_LIMIT);
                        height -= PIXELS_LIMIT
                    }
                    html += createFreeSpaceRowHtml(height);
                    container.addClass(DATAGRID_TABLE_CLASS);
                    container.html(html)
                },
                _findBottomLoadPanel: function() {
                    var $element = this.element();
                    var $bottomLoadPanel = $element && $element.find("." + DATAGRID_BOTTOM_LOAD_PANEL_CLASS);
                    if ($bottomLoadPanel && $bottomLoadPanel.length) {
                        return $bottomLoadPanel
                    }
                },
                _updateBottomLoading: function() {
                    var that = this,
                        scrollingMode = that.option("scrolling.mode"),
                        virtualMode = scrollingMode === SCROLLING_MODE_VIRTUAL,
                        appendMode = scrollingMode === SCROLLING_MODE_INFINITE,
                        showBottomLoading = !that._dataController.hasKnownLastPage() && that._dataController.isLoaded() && (virtualMode || appendMode),
                        bottomLoadPanelElement = that._findBottomLoadPanel();
                    if (showBottomLoading) {
                        if (!bottomLoadPanelElement) {
                            $("<div>").addClass(DATAGRID_BOTTOM_LOAD_PANEL_CLASS).append(that._createComponent($("<div>"), LoadIndicator).element()).appendTo(that._findContentElement())
                        }
                    } else {
                        if (bottomLoadPanelElement) {
                            bottomLoadPanelElement.remove()
                        }
                    }
                },
                _handleScroll: function(e) {
                    var that = this;
                    if (that._hasHeight && that._rowHeight) {
                        that._setViewportScrollTop(e.scrollOffset.top)
                    }
                    that.callBase.apply(that, arguments)
                },
                _setViewportScrollTop: function(scrollTop) {
                    var that = this,
                        scrollingTimeout = Math.min(that.option("scrolling.timeout") || 0, that._renderTime || 0);
                    clearTimeout(that._scrollTimeoutID);
                    if (scrollingTimeout > 0) {
                        that._scrollTimeoutID = setTimeout(function() {
                            that._setViewportScrollTopCore(scrollTop)
                        }, scrollingTimeout)
                    } else {
                        that._setViewportScrollTopCore(scrollTop)
                    }
                },
                _setViewportScrollTopCore: function(scrollTop) {
                    var that = this,
                        virtualItemsCount = that._dataController.virtualItemsCount(),
                        heightRatio = that._heightRatio || 1,
                        rowHeight = that._rowHeight,
                        beginHeight = virtualItemsCount ? Math.floor(virtualItemsCount.begin * rowHeight * heightRatio) : 0;
                    if (virtualItemsCount && scrollTop >= beginHeight && scrollTop <= beginHeight + that._contentTableHeight) {
                        that._dataController.setViewportItemIndex(virtualItemsCount.begin + (scrollTop - beginHeight) / rowHeight)
                    } else {
                        that._dataController.setViewportItemIndex(scrollTop / (rowHeight * heightRatio))
                    }
                },
                _needUpdateRowHeight: function(itemsCount) {
                    var that = this;
                    return that.callBase.apply(that, arguments) || itemsCount > 0 && that.option("scrolling.mode") === SCROLLING_MODE_INFINITE
                },
                _updateRowHeight: function() {
                    var viewportHeight, that = this;
                    that.callBase.apply(that, arguments);
                    if (that._rowHeight) {
                        that._updateContentPosition();
                        viewportHeight = that._hasHeight ? that.element().outerHeight() : $(window).outerHeight();
                        that._dataController.viewportSize(Math.round(viewportHeight / that._rowHeight))
                    }
                },
                setLoading: function(isLoading, messageText) {
                    var that = this,
                        callBase = that.callBase,
                        hasBottomLoadPanel = !!that._findBottomLoadPanel() && that._dataController.isLoaded();
                    if (hasBottomLoadPanel) {
                        isLoading = false
                    }
                    callBase.call(that, isLoading, messageText)
                },
                _resizeCore: function() {
                    var that = this,
                        $element = that.element();
                    that.callBase();
                    if (that.component.element() && !that._windowScroll && $element.closest(document).length) {
                        that._windowScroll = virtualScrollingCore.subscribeToExternalScrollers($element, function(scrollPos) {
                            if (!that._hasHeight && that._rowHeight) {
                                that._setViewportScrollTop(scrollPos)
                            }
                        }, that.component.element());
                        that.on("disposing", function() {
                            that._windowScroll.dispose()
                        })
                    }
                    var dataSource = that._dataController.dataSource();
                    if (dataSource && dataSource.loadIfNeed) {
                        dataSource.loadIfNeed()
                    }
                },
                getTableElements: function(isVirtualTable) {
                    var selector, result = this.callBase();
                    if (isVirtualTable && "virtual" === this.option("scrolling.mode")) {
                        selector = "> ." + DATAGRID_CONTENT_CLASS;
                        if (this.getScrollable()) {
                            selector = "> ." + DATAGRID_SCROLLABLE_CONTAINER + " > ." + DATAGRID_SCROLLABLE_CONTENT + selector
                        }
                        result = result.add(this.element().find(selector).children(":not(." + DATAGRID_TABLE_CONTENT_CLASS + ")"))
                    }
                    return result
                },
                dispose: function() {
                    clearTimeout(this._scrollTimeoutID);
                    this.callBase()
                }
            }
        }();
        gridCore.registerModule("virtualScrolling", {
            defaultOptions: function() {
                return {
                    scrolling: {
                        timeout: 300,
                        mode: "standard",
                        preloadEnabled: false,
                        useNative: "auto"
                    }
                }
            },
            extenders: {
                controllers: {
                    data: function() {
                        var members = {};
                        gridCore.proxyMethod(members, "virtualItemsCount");
                        gridCore.proxyMethod(members, "viewportSize");
                        gridCore.proxyMethod(members, "setViewportItemIndex");
                        return members
                    }()
                },
                views: {
                    rowsView: VirtualScrollingRowsViewExtender
                }
            }
        })
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/grid_core/ui.grid_core.virtual_scrolling.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            Class = __webpack_require__( /*! ../../core/class */ 20);
        var SCROLLING_MODE_INFINITE = "infinite",
            SCROLLING_MODE_VIRTUAL = "virtual",
            CONTENT_HEIHGT_LIMIT = browser.msie ? 4e6 : 15e6;
        var isVirtualMode = function(that) {
            return that.option("scrolling.mode") === SCROLLING_MODE_VIRTUAL
        };
        var isAppendMode = function(that) {
            return that.option("scrolling.mode") === SCROLLING_MODE_INFINITE
        };
        exports.subscribeToExternalScrollers = function($element, scrollChangedHandler, $targetElement) {
            var $scrollElement, scrollableArray = [],
                scrollToArray = [],
                disposeArray = [];
            $targetElement = $targetElement || $element;

            function getElementOffset(scrollable) {
                var $scrollableElement = scrollable.element ? scrollable.element() : scrollable,
                    scrollableOffset = $scrollableElement.offset();
                if (!scrollableOffset) {
                    return $element.offset().top
                }
                return scrollable.scrollTop() - (scrollableOffset.top - $element.offset().top)
            }

            function createWindowScrollHandler(scrollable) {
                return function(e) {
                    var scrollTop = scrollable.scrollTop() - getElementOffset(scrollable);
                    scrollTop = scrollTop > 0 ? scrollTop : 0;
                    scrollChangedHandler(scrollTop)
                }
            }

            function subscribeToScrollEvents($scrollElement) {
                var handler, isDocument = "#document" === $scrollElement.get(0).nodeName,
                    scrollable = $scrollElement.data("dxScrollable") || isDocument && $(window) || "auto" === $scrollElement.css("overflow-y") && $scrollElement;
                if (scrollable) {
                    handler = createWindowScrollHandler(scrollable);
                    scrollable.on("scroll", handler);
                    scrollToArray.push(function(pos) {
                        var topOffset = getElementOffset(scrollable),
                            scrollMethod = scrollable.scrollTo ? "scrollTo" : "scrollTop";
                        if (pos - topOffset >= 0) {
                            scrollable[scrollMethod](pos + topOffset)
                        }
                    });
                    scrollableArray.push(scrollable);
                    disposeArray.push(function() {
                        scrollable.off("scroll", handler)
                    })
                }
            }
            for ($scrollElement = $targetElement.parent(); $scrollElement.length; $scrollElement = $scrollElement.parent()) {
                subscribeToScrollEvents($scrollElement)
            }
            return {
                scrollTo: function(pos) {
                    $.each(scrollToArray, function(_, scrollTo) {
                        scrollTo(pos)
                    })
                },
                dispose: function() {
                    $.each(disposeArray, function(_, dispose) {
                        dispose()
                    })
                }
            }
        };
        exports.VirtualScrollController = Class.inherit(function() {
            var getViewportPageCount = function(that) {
                var pageSize = that._dataSource.pageSize();
                return pageSize && that._viewportSize >= 0 ? Math.ceil(that._viewportSize / pageSize) : 1
            };
            var getPreloadPageCount = function(that) {
                var preloadEnabled = that.option("scrolling.preloadEnabled"),
                    pageCount = getViewportPageCount(that);
                if (pageCount) {
                    if (preloadEnabled) {
                        pageCount++
                    }
                    if (isAppendMode(that)) {
                        pageCount--
                    }
                }
                return pageCount
            };
            var getBeginPageIndex = function(that) {
                return that._cache.length ? that._cache[0].pageIndex : -1
            };
            var getEndPageIndex = function(that) {
                return that._cache.length ? that._cache[that._cache.length - 1].pageIndex : -1
            };
            var fireChanged = function(that, changed, args) {
                that._isChangedFiring = true;
                changed(args);
                that._isChangedFiring = false
            };
            var processDelayChanged = function(that, changed) {
                if (that._isDelayChanged) {
                    that._isDelayChanged = false;
                    fireChanged(that, changed);
                    return true
                }
            };
            var processChanged = function(that, changed, changeType, isDelayChanged) {
                var change, dataSource = that._dataSource,
                    items = dataSource.items();
                if (changeType && !that._isDelayChanged) {
                    change = {
                        changeType: changeType,
                        items: items
                    }
                }
                var viewportItems = that._dataSource.viewportItems();
                if ("append" === changeType) {
                    viewportItems.push.apply(viewportItems, items)
                } else {
                    if ("prepend" === changeType) {
                        viewportItems.unshift.apply(viewportItems, items)
                    } else {
                        that._dataSource.viewportItems(items)
                    }
                }
                dataSource.updateLoading();
                that._lastPageIndex = that.pageIndex();
                that._isDelayChanged = isDelayChanged;
                if (!isDelayChanged) {
                    fireChanged(that, changed, change)
                }
            };
            return {
                ctor: function(component, dataSource) {
                    var that = this;
                    that._dataSource = dataSource;
                    that.component = component;
                    that._pageIndex = that._lastPageIndex = dataSource.pageIndex();
                    that._viewportSize = 0;
                    that._viewportItemSize = 20;
                    that._viewportItemIndex = -1;
                    that._sizeRatio = 1;
                    that._items = [];
                    that._cache = []
                },
                option: function(name) {
                    return this.component.option.apply(this.component, arguments)
                },
                virtualItemsCount: function() {
                    var pageIndex, beginItemsCount, endItemsCount, that = this,
                        itemsCount = 0;
                    if (isVirtualMode(that)) {
                        pageIndex = getBeginPageIndex(that);
                        if (pageIndex < 0) {
                            pageIndex = 0
                        }
                        beginItemsCount = pageIndex * that._dataSource.pageSize();
                        itemsCount = that._cache.length * that._dataSource.pageSize();
                        endItemsCount = Math.max(0, that._dataSource.totalItemsCount() - itemsCount - beginItemsCount);
                        return {
                            begin: beginItemsCount,
                            end: endItemsCount
                        }
                    }
                },
                _setViewportPositionCore: function(position, isNear) {
                    var that = this,
                        scrollingTimeout = Math.min(that.option("scrolling.timeout") || 0, that._dataSource.changingDuration());
                    if (isNear && scrollingTimeout < that.option("scrolling.renderingThreshold")) {
                        scrollingTimeout = 10
                    }
                    clearTimeout(that._scrollTimeoutID);
                    if (scrollingTimeout > 0) {
                        that._scrollTimeoutID = setTimeout(function() {
                            that.setViewportItemIndex(position)
                        }, scrollingTimeout)
                    } else {
                        that.setViewportItemIndex(position)
                    }
                },
                getViewportPosition: function() {
                    return this._position || 0
                },
                setViewportPosition: function(position) {
                    var that = this,
                        virtualItemsCount = that.virtualItemsCount(),
                        sizeRatio = that._sizeRatio || 1,
                        itemSize = that._viewportItemSize,
                        offset = virtualItemsCount ? Math.floor(virtualItemsCount.begin * itemSize * sizeRatio) : 0;
                    that._position = position;
                    if (virtualItemsCount && position >= offset && position <= offset + that._contentSize) {
                        that._setViewportPositionCore(virtualItemsCount.begin + (position - offset) / itemSize, true)
                    } else {
                        that._setViewportPositionCore(position / (itemSize * sizeRatio))
                    }
                },
                setContentSize: function(size) {
                    var that = this,
                        virtualItemsCount = that.virtualItemsCount();
                    that._contentSize = size;
                    if (virtualItemsCount) {
                        var virtualContentSize = (virtualItemsCount.begin + virtualItemsCount.end + that.itemsCount()) * that._viewportItemSize;
                        if (virtualContentSize > CONTENT_HEIHGT_LIMIT) {
                            that._sizeRatio = CONTENT_HEIHGT_LIMIT / virtualContentSize
                        } else {
                            that._sizeRatio = 1
                        }
                    }
                },
                getContentOffset: function() {
                    var that = this,
                        virtualItemsCount = that.virtualItemsCount();
                    return virtualItemsCount ? Math.floor(virtualItemsCount.begin * that._viewportItemSize * that._sizeRatio) : 0
                },
                getVirtualContentSize: function() {
                    var that = this,
                        virtualItemsCount = that.virtualItemsCount();
                    return virtualItemsCount ? (virtualItemsCount.begin + virtualItemsCount.end) * that._viewportItemSize * that._sizeRatio + that._contentSize : 0
                },
                getViewportItemIndex: function() {
                    return this._viewportItemIndex
                },
                setViewportItemIndex: function(itemIndex) {
                    var lastPageSize, maxPageIndex, newPageIndex, that = this,
                        pageSize = that._dataSource.pageSize(),
                        pageCount = that._dataSource.pageCount(),
                        virtualMode = isVirtualMode(that),
                        appendMode = isAppendMode(that),
                        totalItemsCount = that._dataSource.totalItemsCount(),
                        needLoad = that._viewportItemIndex < 0;
                    that._viewportItemIndex = itemIndex;
                    if (pageSize && (virtualMode || appendMode) && totalItemsCount >= 0) {
                        if (that._viewportSize && itemIndex + that._viewportSize >= totalItemsCount) {
                            if (that._dataSource.hasKnownLastPage()) {
                                newPageIndex = pageCount - 1;
                                lastPageSize = totalItemsCount % pageSize;
                                if (newPageIndex > 0 && lastPageSize > 0 && lastPageSize < pageSize / 2) {
                                    newPageIndex--
                                }
                            } else {
                                newPageIndex = pageCount
                            }
                        } else {
                            newPageIndex = Math.floor(itemIndex / pageSize);
                            maxPageIndex = pageCount - 1;
                            newPageIndex = Math.max(newPageIndex, 0);
                            newPageIndex = Math.min(newPageIndex, maxPageIndex)
                        }
                        if (that.pageIndex() !== newPageIndex || needLoad) {
                            that.pageIndex(newPageIndex);
                            that.load()
                        }
                    }
                },
                viewportItemSize: function(size) {
                    if (void 0 !== size) {
                        this._viewportItemSize = size
                    }
                    return this._viewportItemSize
                },
                viewportSize: function(size) {
                    if (void 0 !== size) {
                        this._viewportSize = size
                    }
                    return this._viewportSize
                },
                pageIndex: function(pageIndex) {
                    if (isVirtualMode(this) || isAppendMode(this)) {
                        if (void 0 !== pageIndex) {
                            this._pageIndex = pageIndex
                        }
                        return this._pageIndex
                    } else {
                        return this._dataSource.pageIndex(pageIndex)
                    }
                },
                beginPageIndex: function(defaultPageIndex) {
                    var beginPageIndex = getBeginPageIndex(this);
                    if (beginPageIndex < 0) {
                        beginPageIndex = void 0 !== defaultPageIndex ? defaultPageIndex : this.pageIndex()
                    }
                    return beginPageIndex
                },
                endPageIndex: function() {
                    var endPageIndex = getEndPageIndex(this);
                    return endPageIndex > 0 ? endPageIndex : this._lastPageIndex
                },
                load: function() {
                    var result, beginPageIndex = getBeginPageIndex(this),
                        pageIndexForLoad = -1,
                        dataSource = this._dataSource;
                    var loadCore = function(that, pageIndex) {
                        var dataSource = that._dataSource;
                        if (pageIndex === that.pageIndex() || !dataSource.isLoading() && pageIndex < dataSource.pageCount() || !dataSource.hasKnownLastPage() && pageIndex === dataSource.pageCount()) {
                            dataSource.pageIndex(pageIndex);
                            return dataSource.load()
                        }
                    };
                    if (isVirtualMode(this) || isAppendMode(this)) {
                        if (beginPageIndex < 0 || !this._cache[this._pageIndex - beginPageIndex]) {
                            pageIndexForLoad = this._pageIndex
                        }
                        if (beginPageIndex >= 0 && pageIndexForLoad < 0 && this._viewportSize >= 0) {
                            if (beginPageIndex > 0 && getEndPageIndex(this) + 1 === dataSource.pageCount() && this._cache.length < getPreloadPageCount(this) + 1) {
                                pageIndexForLoad = beginPageIndex - 1
                            } else {
                                if (beginPageIndex + this._cache.length <= this._pageIndex + getPreloadPageCount(this)) {
                                    pageIndexForLoad = beginPageIndex + this._cache.length
                                }
                            }
                        }
                        if (pageIndexForLoad >= 0) {
                            result = loadCore(this, pageIndexForLoad)
                        }
                        dataSource.updateLoading()
                    } else {
                        result = dataSource.load()
                    }
                    if (!result && this._lastPageIndex !== this.pageIndex()) {
                        this._dataSource.onChanged({
                            changeType: "pageIndex"
                        })
                    }
                    return result || $.Deferred().resolve()
                },
                loadIfNeed: function() {
                    var that = this;
                    if ((isVirtualMode(that) || isAppendMode(that)) && !that._dataSource.isLoading() && !that._isChangedFiring) {
                        that.load()
                    }
                },
                handleDataChanged: function(callBase) {
                    var beginPageIndex, changeType, removeInvisiblePages, cacheItem, that = this,
                        dataSource = that._dataSource,
                        lastCacheLength = that._cache.length;
                    if (isVirtualMode(that) || isAppendMode(that)) {
                        beginPageIndex = getBeginPageIndex(that);
                        if (beginPageIndex >= 0) {
                            if (isVirtualMode(that) && beginPageIndex + that._cache.length !== dataSource.pageIndex() && beginPageIndex - 1 !== dataSource.pageIndex()) {
                                that._cache = []
                            }
                            if (isAppendMode(that)) {
                                if (0 === dataSource.pageIndex()) {
                                    that._cache = []
                                } else {
                                    if (dataSource.pageIndex() < getEndPageIndex(that)) {
                                        fireChanged(that, callBase, {
                                            changeType: "append",
                                            items: []
                                        });
                                        return
                                    }
                                }
                            }
                        }
                        cacheItem = {
                            pageIndex: dataSource.pageIndex(),
                            itemsCount: that.itemsCount(true)
                        };
                        if (that.option("scrolling.removeInvisiblePages")) {
                            removeInvisiblePages = that._cache.length > Math.max(getPreloadPageCount(this), 2)
                        } else {
                            processDelayChanged(that, callBase)
                        }
                        if (beginPageIndex === dataSource.pageIndex() + 1) {
                            if (removeInvisiblePages) {
                                that._cache.pop()
                            } else {
                                changeType = "prepend"
                            }
                            that._cache.unshift(cacheItem)
                        } else {
                            if (removeInvisiblePages) {
                                that._cache.shift()
                            } else {
                                changeType = "append"
                            }
                            that._cache.push(cacheItem)
                        }
                        processChanged(that, callBase, that._cache.length > 1 ? changeType : void 0, 0 === lastCacheLength);
                        that.load().done(function() {
                            if (processDelayChanged(that, callBase)) {
                                that.load()
                            }
                        })
                    } else {
                        processChanged(that, callBase)
                    }
                },
                itemsCount: function(isBase) {
                    var itemsCount = 0;
                    if (!isBase && isVirtualMode(this)) {
                        $.each(this._cache, function() {
                            itemsCount += this.itemsCount
                        })
                    } else {
                        itemsCount = this._dataSource.itemsCount()
                    }
                    return itemsCount
                },
                reset: function() {
                    this._cache = []
                },
                subscribeToWindowScrollEvents: function($element) {
                    var that = this;
                    that._windowScroll = that._windowScroll || exports.subscribeToExternalScrollers($element, function(scrollTop) {
                        if (that.viewportItemSize()) {
                            that.setViewportPosition(scrollTop)
                        }
                    })
                },
                dispose: function() {
                    clearTimeout(this._scrollTimeoutID);
                    this._windowScroll && this._windowScroll.dispose();
                    this._windowScroll = null
                },
                scrollTo: function(pos) {
                    this._windowScroll && this._windowScroll.scrollTo(pos)
                }
            }
        }())
    },
    /*!*********************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.filter_row.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            Overlay = __webpack_require__( /*! ../overlay */ 109),
            Menu = __webpack_require__( /*! ../menu */ 368);
        __webpack_require__( /*! ./ui.data_grid.editor_factory */ 363);
        var OPERATION_ICONS = {
            "=": "filter-operation-equals",
            "<>": "filter-operation-not-equals",
            "<": "filter-operation-less",
            "<=": "filter-operation-less-equal",
            ">": "filter-operation-greater",
            ">=": "filter-operation-greater-equal",
            "default": "filter-operation-default",
            notcontains: "filter-operation-not-contains",
            contains: "filter-operation-contains",
            startswith: "filter-operation-starts-with",
            endswith: "filter-operation-ends-with",
            between: "filter-operation-between"
        };
        var FILTERING_TIMEOUT = 700,
            CORRECT_FILTER_RANGE_OVERLAY_WIDTH = 1,
            DATAGRID_CLASS = "dx-datagrid",
            DATAGRID_FILTER_ROW_CLASS = "dx-datagrid-filter-row",
            DATAGRID_MENU_CLASS = "dx-menu",
            DATAGRID_EDITOR_WITH_MENU_CLASS = "dx-editor-with-menu",
            DATAGRID_EDITOR_CONTAINER_CLASS = "dx-editor-container",
            DATAGRID_EDITOR_CELL_CLASS = "dx-editor-cell",
            DATAGRID_FILTER_MENU = "dx-filter-menu",
            DATAGRID_APPLY_BUTTON_CLASS = "dx-apply-button",
            DATAGRID_HIGHLIGHT_OUTLINE_CLASS = "dx-highlight-outline",
            DATAGRID_FOCUSED_CLASS = "dx-focused",
            DATAGRID_CELL_FOCUS_DISABLED_CLASS = "dx-cell-focus-disabled",
            DATAGRID_FILTER_RANGE_OVERLAY_CLASS = "dx-datagrid-filter-range-overlay",
            DATAGRID_FILTER_RANGE_CONTENT_CLASS = "dx-filter-range-content",
            DATAGRID_FILTER_RANGE_START_CLASS = "dx-datagrid-filter-range-start",
            DATAGRID_FILTER_RANGE_END_CLASS = "dx-datagrid-filter-range-end";

        function isOnClickApplyFilterMode(that) {
            return "onClick" === that.option("filterRow.applyFilter")
        }
        var ColumnHeadersViewFilterRowExtender = function() {
            var getEditorInstance = function($editorContainer) {
                var $editor = $editorContainer && $editorContainer.children(),
                    componentNames = $editor && $editor.data("dxComponents"),
                    editor = componentNames && componentNames.length && $editor.data(componentNames[0]);
                if (editor instanceof Editor) {
                    return editor
                }
            };
            var getRangeTextByFilterValue = function(that, column) {
                var filterValue = getColumnFilterValue(that, column),
                    result = "";
                if (commonUtils.isArray(filterValue)) {
                    result = gridCore.formatValue(filterValue[0], column);
                    if ("" !== gridCore.formatValue(filterValue[1], column)) {
                        result += " - " + gridCore.formatValue(filterValue[1], column)
                    }
                } else {
                    if (commonUtils.isDefined(filterValue)) {
                        result = gridCore.formatValue(filterValue, column)
                    }
                }
                return result
            };
            var getColumnFilterValue = function(that, column) {
                if (column) {
                    return isOnClickApplyFilterMode(that) && void 0 !== column.bufferedFilterValue ? column.bufferedFilterValue : column.filterValue
                }
            };
            var getColumnSelectedFilterOperation = function(that, column) {
                if (column) {
                    return isOnClickApplyFilterMode(that) && void 0 !== column.bufferedSelectedFilterOperation ? column.bufferedSelectedFilterOperation : column.selectedFilterOperation
                }
            };
            var getFilterValue = function(that, columnIndex, $editorContainer) {
                var column = that._columnsController.columnOption(columnIndex),
                    filterValue = getColumnFilterValue(that, column),
                    isFilterRange = $editorContainer.closest("." + DATAGRID_FILTER_RANGE_OVERLAY_CLASS).length,
                    isRangeStart = $editorContainer.hasClass(DATAGRID_FILTER_RANGE_START_CLASS);
                if (filterValue && commonUtils.isArray(filterValue) && "between" === getColumnSelectedFilterOperation(that, column)) {
                    if (isRangeStart) {
                        return filterValue[0]
                    } else {
                        return filterValue[1]
                    }
                }
                return !isFilterRange ? filterValue : void 0
            };
            var normalizeFilterValue = function(that, filterValue, column, $editorContainer) {
                if ("between" === getColumnSelectedFilterOperation(that, column)) {
                    var columnFilterValue = getColumnFilterValue(that, column);
                    if ($editorContainer.hasClass(DATAGRID_FILTER_RANGE_START_CLASS)) {
                        return [filterValue, commonUtils.isArray(columnFilterValue) ? columnFilterValue[1] : void 0]
                    } else {
                        return [commonUtils.isArray(columnFilterValue) ? columnFilterValue[0] : columnFilterValue, filterValue]
                    }
                }
                return filterValue
            };
            var updateFilterValue = function(that, options) {
                var value = "" === options.value ? null : options.value,
                    $editorContainer = options.container,
                    column = that._columnsController.columnOption(options.column.index),
                    filterValue = getFilterValue(that, column.index, $editorContainer);
                if (!commonUtils.isDefined(filterValue) && !commonUtils.isDefined(value)) {
                    return
                }
                that._applyFilterViewController.setHighLight($editorContainer, filterValue !== value);
                that._columnsController.columnOption(column.index, isOnClickApplyFilterMode(that) ? "bufferedFilterValue" : "filterValue", normalizeFilterValue(that, value, column, $editorContainer), options.notFireEvent)
            };
            return {
                _updateEditorValue: function(column, $editorContainer) {
                    var that = this,
                        editor = getEditorInstance($editorContainer);
                    editor && editor.option("value", getFilterValue(that, column.index, $editorContainer))
                },
                _columnOptionChanged: function(e) {
                    var overlayInstance, visibleIndex, column, $cell, $editorContainer, $editorRangeElements, $rangeContent, $menu, that = this,
                        optionNames = e.optionNames;
                    if (gridCore.checkChanges(optionNames, ["filterValue", "bufferedFilterValue", "selectedFilterOperation", "bufferedSelectedFilterOperation"]) && void 0 !== e.columnIndex) {
                        visibleIndex = that.getController("columns").getVisibleIndex(e.columnIndex);
                        column = that.getController("columns").columnOption(e.columnIndex);
                        $cell = that.getCellElement(that.element().find("." + DATAGRID_FILTER_ROW_CLASS).index(), visibleIndex) || $();
                        $rangeContent = $cell.find("." + DATAGRID_FILTER_RANGE_CONTENT_CLASS);
                        $editorContainer = $cell.find("." + DATAGRID_EDITOR_CONTAINER_CLASS).first();
                        if (optionNames.filterValue || optionNames.bufferedFilterValue) {
                            that._updateEditorValue(column, $editorContainer);
                            overlayInstance = $cell.find("." + DATAGRID_FILTER_RANGE_OVERLAY_CLASS).data("dxOverlay");
                            if (overlayInstance) {
                                $editorRangeElements = overlayInstance.content().find("." + DATAGRID_EDITOR_CONTAINER_CLASS);
                                that._updateEditorValue(column, $editorRangeElements.first());
                                that._updateEditorValue(column, $editorRangeElements.last())
                            }
                            if (!overlayInstance || !overlayInstance.option("visible")) {
                                that._updateFilterRangeContent($cell, getRangeTextByFilterValue(that, column))
                            }
                        }
                        if (optionNames.selectedFilterOperation || optionNames.bufferedSelectedFilterOperation) {
                            if (visibleIndex >= 0 && column) {
                                $menu = $cell.find("." + DATAGRID_MENU_CLASS);
                                if ($menu.length) {
                                    that._updateFilterOperationChooser($menu, column, $editorContainer);
                                    if ("between" === getColumnSelectedFilterOperation(that, column)) {
                                        that._renderFilterRangeContent($cell, column);
                                        that._showFilterRange($cell, column)
                                    } else {
                                        if ($editorContainer.find("." + DATAGRID_FILTER_RANGE_CONTENT_CLASS).length) {
                                            that._renderEditor($editorContainer, that._getEditorOptions($editorContainer, column));
                                            that._hideFilterRange()
                                        }
                                    }
                                }
                            }
                        }
                        return
                    }
                    that.callBase(e)
                },
                _resizeCore: function() {
                    this.callBase.apply(this, arguments);
                    this._filterRangeOverlayInstance && this._filterRangeOverlayInstance.repaint()
                },
                isFilterRowVisible: function() {
                    return this._isElementVisible(this.option("filterRow"))
                },
                isVisible: function() {
                    return this.callBase() || this.isFilterRowVisible()
                },
                init: function() {
                    this.callBase();
                    this._applyFilterViewController = this.getController("applyFilter")
                },
                _initFilterRangeOverlay: function($cell, column) {
                    var that = this,
                        sharedData = {},
                        $editorContainer = $cell.find(".dx-editor-container"),
                        $overlay = $("<div/>").addClass(DATAGRID_FILTER_RANGE_OVERLAY_CLASS).appendTo($cell);
                    return that._createComponent($overlay, Overlay, {
                        height: "auto",
                        shading: false,
                        showTitle: false,
                        focusStateEnabled: false,
                        closeOnTargetScroll: true,
                        closeOnOutsideClick: true,
                        animation: false,
                        position: {
                            my: "top",
                            at: "top",
                            of: $editorContainer.length && $editorContainer || $cell,
                            offset: "0 -1"
                        },
                        contentTemplate: function(contentElement) {
                            var $editor = $("<div/>").addClass(DATAGRID_EDITOR_CONTAINER_CLASS + " " + DATAGRID_FILTER_RANGE_START_CLASS).appendTo(contentElement),
                                editorOptions = that._getEditorOptions($editor, column);
                            editorOptions.sharedData = sharedData;
                            that._renderEditor($editor, editorOptions);
                            $editor.find("input").on("keydown", function(e) {
                                var $prevElement = $cell.find("[tabindex]").not(e.target).first();
                                if (9 === e.which && e.shiftKey) {
                                    e.preventDefault();
                                    that._hideFilterRange();
                                    if (!$prevElement.length) {
                                        $prevElement = $cell.prev().find("[tabindex]").last()
                                    }
                                    $prevElement.focus()
                                }
                            });
                            $editor = $("<div/>").addClass(DATAGRID_EDITOR_CONTAINER_CLASS + " " + DATAGRID_FILTER_RANGE_END_CLASS).appendTo(contentElement);
                            editorOptions = that._getEditorOptions($editor, column);
                            editorOptions.sharedData = sharedData;
                            that._renderEditor($editor, editorOptions);
                            $editor.find("input").on("keydown", function(e) {
                                if (9 === e.which && !e.shiftKey) {
                                    e.preventDefault();
                                    that._hideFilterRange();
                                    $cell.next().find("[tabindex]").first().focus()
                                }
                            });
                            return contentElement.addClass(DATAGRID_CLASS)
                        },
                        onShown: function(e) {
                            var $editor = e.component.content().find("." + DATAGRID_EDITOR_CONTAINER_CLASS).first();
                            $editor.find("input").focus()
                        },
                        onHidden: function() {
                            var updatedColumn = that._columnsController.columnOption(column.index);
                            $cell.find("." + DATAGRID_MENU_CLASS).parent().addClass(DATAGRID_EDITOR_WITH_MENU_CLASS);
                            if ("between" === getColumnSelectedFilterOperation(that, updatedColumn)) {
                                that._updateFilterRangeContent($cell, getRangeTextByFilterValue(that, updatedColumn));
                                that.component.updateDimensions()
                            }
                        }
                    })
                },
                _updateFilterRangeOverlay: function(options) {
                    var overlayInstance = this._filterRangeOverlayInstance;
                    overlayInstance && overlayInstance.option(options)
                },
                _showFilterRange: function($cell, column) {
                    var that = this,
                        $overlay = $cell.children("." + DATAGRID_FILTER_RANGE_OVERLAY_CLASS),
                        overlayInstance = $overlay.length && $overlay.data("dxOverlay");
                    if (!overlayInstance && column) {
                        overlayInstance = that._initFilterRangeOverlay($cell, column)
                    }
                    if (!overlayInstance.option("visible")) {
                        that._filterRangeOverlayInstance && that._filterRangeOverlayInstance.hide();
                        that._filterRangeOverlayInstance = overlayInstance;
                        that._updateFilterRangeOverlay({
                            width: $cell.outerWidth(true) + CORRECT_FILTER_RANGE_OVERLAY_WIDTH
                        });
                        that._filterRangeOverlayInstance && that._filterRangeOverlayInstance.show()
                    }
                },
                _hideFilterRange: function() {
                    var overlayInstance = this._filterRangeOverlayInstance;
                    overlayInstance && overlayInstance.hide()
                },
                getFilterRangeOverlayInstance: function() {
                    return this._filterRangeOverlayInstance
                },
                _createRow: function(row) {
                    var $row = this.callBase(row);
                    if ("filter" === row.rowType) {
                        $row.addClass(DATAGRID_FILTER_ROW_CLASS)
                    }
                    return $row
                },
                _getRows: function() {
                    var result = this.callBase();
                    if (this.isFilterRowVisible()) {
                        result.push({
                            rowType: "filter"
                        })
                    }
                    return result
                },
                _renderCellContent: function($cell, options) {
                    var $container, $editorContainer, that = this,
                        column = options.column;
                    if ("filter" === options.rowType) {
                        if (column.command) {
                            $cell.html("&nbsp;")
                        } else {
                            if (column.allowFiltering) {
                                that.setAria("label", messageLocalization.format("dxDataGrid-ariaColumn") + " " + column.caption + ", " + messageLocalization.format("dxDataGrid-ariaFilterCell"), $cell);
                                $cell.addClass(DATAGRID_EDITOR_CELL_CLASS);
                                $container = $("<div />").appendTo($cell);
                                $editorContainer = $("<div />").addClass(DATAGRID_EDITOR_CONTAINER_CLASS).appendTo($container);
                                if ("between" === getColumnSelectedFilterOperation(that, column)) {
                                    that._renderFilterRangeContent($cell, column)
                                } else {
                                    that._renderEditor($editorContainer, that._getEditorOptions($editorContainer, column))
                                }
                                if (column.alignment) {
                                    $cell.find("input").first().css("text-align", column.alignment)
                                }
                                if (column.filterOperations && column.filterOperations.length) {
                                    that._renderFilterOperationChooser($container, column, $editorContainer)
                                }
                            }
                        }
                    }
                    that.callBase($cell, options)
                },
                _getEditorOptions: function($editorContainer, column) {
                    var that = this,
                        result = $.extend({}, column, {
                            value: getFilterValue(that, column.index, $editorContainer),
                            parentType: "filterRow",
                            showAllText: that.option("filterRow.showAllText"),
                            updateValueTimeout: "onClick" === that.option("filterRow.applyFilter") ? 0 : FILTERING_TIMEOUT,
                            width: null,
                            setValue: function(value, notFireEvent) {
                                updateFilterValue(that, {
                                    column: column,
                                    value: value,
                                    container: $editorContainer,
                                    notFireEvent: notFireEvent
                                })
                            }
                        });
                    if ("between" === getColumnSelectedFilterOperation(that, column)) {
                        if ($editorContainer.hasClass(DATAGRID_FILTER_RANGE_START_CLASS)) {
                            result.placeholder = that.option("filterRow.betweenStartText")
                        } else {
                            result.placeholder = that.option("filterRow.betweenEndText")
                        }
                    }
                    return result
                },
                _renderEditor: function($editorContainer, options) {
                    $editorContainer.empty();
                    return this.getController("editorFactory").createEditor($("<div />").appendTo($editorContainer), options)
                },
                _renderFilterRangeContent: function($cell, column) {
                    var that = this,
                        $editorContainer = $cell.find("." + DATAGRID_EDITOR_CONTAINER_CLASS).first();
                    $editorContainer.empty();
                    $("<div/>").addClass(DATAGRID_FILTER_RANGE_CONTENT_CLASS).attr("tabindex", 0).on("focusin", function(e) {
                        that._showFilterRange($cell, column)
                    }).appendTo($editorContainer);
                    that._updateFilterRangeContent($cell, getRangeTextByFilterValue(that, column))
                },
                _updateFilterRangeContent: function($cell, value) {
                    var $filterRangeContent = $cell.find("." + DATAGRID_FILTER_RANGE_CONTENT_CLASS);
                    if ($filterRangeContent.length) {
                        if ("" === value) {
                            $filterRangeContent.html("&nbsp;")
                        } else {
                            $filterRangeContent.text(value)
                        }
                    }
                },
                _updateFilterOperationChooser: function($menu, column, $editorContainer) {
                    var isCellWasFocused, that = this;
                    that._createComponent($menu, Menu, {
                        _templates: {},
                        activeStateEnabled: false,
                        selectionMode: "single",
                        cssClass: DATAGRID_CLASS + " " + DATAGRID_CELL_FOCUS_DISABLED_CLASS + " " + DATAGRID_FILTER_MENU,
                        showFirstSubmenuMode: "onHover",
                        hideSubmenuOnMouseLeave: true,
                        items: [{
                            disabled: column.filterOperations && column.filterOperations.length ? false : true,
                            icon: OPERATION_ICONS[getColumnSelectedFilterOperation(that, column) || "default"],
                            selectable: false,
                            items: that._getFilterOperationMenuItems(column)
                        }],
                        onItemClick: function(properties) {
                            var selectedFilterOperation = properties.itemData.name,
                                columnSelectedFilterOperation = getColumnSelectedFilterOperation(that, column),
                                notFocusEditor = false,
                                isOnClickMode = isOnClickApplyFilterMode(that),
                                options = {};
                            if (properties.itemData.items || selectedFilterOperation === columnSelectedFilterOperation) {
                                return
                            }
                            if (selectedFilterOperation) {
                                options[isOnClickMode ? "bufferedSelectedFilterOperation" : "selectedFilterOperation"] = selectedFilterOperation;
                                if ("between" === selectedFilterOperation || "between" === columnSelectedFilterOperation) {
                                    notFocusEditor = "between" === selectedFilterOperation;
                                    options[isOnClickMode ? "bufferedFilterValue" : "filterValue"] = null
                                }
                            } else {
                                options[isOnClickMode ? "bufferedSelectedFilterOperation" : "selectedFilterOperation"] = column.defaultSelectedFilterOperation || null;
                                options[isOnClickMode ? "bufferedFilterValue" : "filterValue"] = null
                            }
                            that._columnsController.columnOption(column.index, options);
                            that._applyFilterViewController.setHighLight($editorContainer, true);
                            !notFocusEditor && that._focusEditor($editorContainer)
                        },
                        onSubmenuShown: function() {
                            isCellWasFocused = that._isEditorFocused($editorContainer);
                            that.getController("editorFactory").loseFocus()
                        },
                        onSubmenuHiding: function(e) {
                            $menu.blur();
                            Menu.getInstance($menu).option("focusedElement", null);
                            isCellWasFocused && that._focusEditor($editorContainer)
                        },
                        rtlEnabled: that.option("rtlEnabled")
                    })
                },
                _isEditorFocused: function($container) {
                    return $container.hasClass(DATAGRID_FOCUSED_CLASS) || $container.parents("." + DATAGRID_FOCUSED_CLASS).length
                },
                _focusEditor: function($container) {
                    this.getController("editorFactory").focus($container);
                    $container.find("input").focus()
                },
                _renderFilterOperationChooser: function($container, column, $editorContainer) {
                    var $menu, that = this;
                    if (that.option("filterRow.showOperationChooser")) {
                        $container.addClass(DATAGRID_EDITOR_WITH_MENU_CLASS);
                        $menu = $("<div />").prependTo($container);
                        that._updateFilterOperationChooser($menu, column, $editorContainer)
                    }
                },
                _getFilterOperationMenuItems: function(column) {
                    var that = this,
                        result = [{}],
                        filterRowOptions = that.option("filterRow"),
                        operationDescriptions = filterRowOptions && filterRowOptions.operationDescriptions || {};
                    if (column.filterOperations && column.filterOperations.length) {
                        result = $.map(column.filterOperations, function(value) {
                            return {
                                name: value,
                                selected: (getColumnSelectedFilterOperation(that, column) || column.defaultFilterOperation) === value,
                                text: operationDescriptions[value],
                                icon: OPERATION_ICONS[value]
                            }
                        });
                        result.push({
                            name: null,
                            text: filterRowOptions && filterRowOptions.resetOperationText,
                            icon: OPERATION_ICONS.default
                        })
                    }
                    return result
                },
                optionChanged: function(args) {
                    var that = this;
                    switch (args.name) {
                        case "filterRow":
                        case "showColumnLines":
                            this._invalidate(true, true);
                            args.handled = true;
                            break;
                        default:
                            that.callBase(args)
                    }
                }
            }
        }();
        var DataControllerFilterRowExtender = {
            _calculateAdditionalFilter: function() {
                var that = this,
                    filters = [that.callBase()],
                    columns = that._columnsController.getVisibleColumns();
                $.each(columns, function() {
                    var filter;
                    if (this.allowFiltering && this.calculateFilterExpression && commonUtils.isDefined(this.filterValue)) {
                        filter = this.createFilterExpression(this.filterValue, this.selectedFilterOperation || this.defaultFilterOperation, "filterRow");
                        filters.push(filter)
                    }
                });
                return gridCore.combineFilters(filters)
            }
        };
        exports.ApplyFilterViewController = gridCore.ViewController.inherit({
            _getHeaderPanel: function() {
                if (!this._headerPanel) {
                    this._headerPanel = this.getView("headerPanel")
                }
                return this._headerPanel
            },
            setHighLight: function($element, value) {
                if (isOnClickApplyFilterMode(this)) {
                    $element && $element.toggleClass(DATAGRID_HIGHLIGHT_OUTLINE_CLASS, value);
                    this._getHeaderPanel().enableApplyButton(value)
                }
            },
            applyFilter: function() {
                var columnsController = this.getController("columns"),
                    columns = columnsController.getColumns();
                columnsController.beginUpdate();
                for (var i = 0; i < columns.length; i++) {
                    if (void 0 !== columns[i].bufferedFilterValue) {
                        columnsController.columnOption(i, "filterValue", columns[i].bufferedFilterValue);
                        columns[i].bufferedFilterValue = void 0
                    }
                    if (void 0 !== columns[i].bufferedSelectedFilterOperation) {
                        columnsController.columnOption(i, "selectedFilterOperation", columns[i].bufferedSelectedFilterOperation);
                        columns[i].bufferedSelectedFilterOperation = void 0
                    }
                }
                columnsController.endUpdate();
                this.removeHighLights()
            },
            removeHighLights: function() {
                if (isOnClickApplyFilterMode(this)) {
                    var columnHeadersView = this.getView("columnHeadersView");
                    columnHeadersView.element().find("." + DATAGRID_FILTER_ROW_CLASS + " ." + DATAGRID_HIGHLIGHT_OUTLINE_CLASS).removeClass(DATAGRID_HIGHLIGHT_OUTLINE_CLASS);
                    this._getHeaderPanel().enableApplyButton(false)
                }
            }
        });
        gridCore.registerModule("filterRow", {
            defaultOptions: function() {
                return {
                    filterRow: {
                        visible: false,
                        showOperationChooser: true,
                        showAllText: messageLocalization.format("dxDataGrid-filterRowShowAllText"),
                        resetOperationText: messageLocalization.format("dxDataGrid-filterRowResetOperationText"),
                        applyFilter: "auto",
                        applyFilterText: messageLocalization.format("dxDataGrid-applyFilterText"),
                        operationDescriptions: {
                            "=": messageLocalization.format("dxDataGrid-filterRowOperationEquals"),
                            "<>": messageLocalization.format("dxDataGrid-filterRowOperationNotEquals"),
                            "<": messageLocalization.format("dxDataGrid-filterRowOperationLess"),
                            "<=": messageLocalization.format("dxDataGrid-filterRowOperationLessOrEquals"),
                            ">": messageLocalization.format("dxDataGrid-filterRowOperationGreater"),
                            ">=": messageLocalization.format("dxDataGrid-filterRowOperationGreaterOrEquals"),
                            startswith: messageLocalization.format("dxDataGrid-filterRowOperationStartsWith"),
                            contains: messageLocalization.format("dxDataGrid-filterRowOperationContains"),
                            notcontains: messageLocalization.format("dxDataGrid-filterRowOperationNotContains"),
                            endswith: messageLocalization.format("dxDataGrid-filterRowOperationEndsWith"),
                            between: messageLocalization.format("dxDataGrid-filterRowOperationBetween")
                        },
                        betweenStartText: messageLocalization.format("dxDataGrid-filterRowOperationBetweenStartText"),
                        betweenEndText: messageLocalization.format("dxDataGrid-filterRowOperationBetweenEndText")
                    }
                }
            },
            controllers: {
                applyFilter: exports.ApplyFilterViewController
            },
            extenders: {
                controllers: {
                    data: DataControllerFilterRowExtender,
                    columnsResizer: {
                        _startResizing: function() {
                            var cellIndex, overlayInstance, that = this;
                            that.callBase.apply(that, arguments);
                            if (that.isResizing()) {
                                overlayInstance = that._columnHeadersView.getFilterRangeOverlayInstance();
                                if (overlayInstance) {
                                    cellIndex = overlayInstance.element().closest("td").index();
                                    if (cellIndex === that._targetPoint.columnIndex || cellIndex === that._targetPoint.columnIndex + 1) {
                                        overlayInstance.content().hide()
                                    }
                                }
                            }
                        },
                        _endResizing: function(args) {
                            var $cell, overlayInstance, that = this;
                            if (that.isResizing()) {
                                overlayInstance = that._columnHeadersView.getFilterRangeOverlayInstance();
                                if (overlayInstance) {
                                    $cell = overlayInstance.element().closest("td");
                                    that._columnHeadersView._updateFilterRangeOverlay({
                                        width: $cell.outerWidth(true) + CORRECT_FILTER_RANGE_OVERLAY_WIDTH
                                    });
                                    overlayInstance.content().show()
                                }
                            }
                            that.callBase.apply(that, arguments)
                        }
                    }
                },
                views: {
                    columnHeadersView: ColumnHeadersViewFilterRowExtender,
                    headerPanel: {
                        _getToolbarItems: function() {
                            var items = this.callBase(),
                                filterItem = this._prepareFilterItem(items);
                            return filterItem.concat(items)
                        },
                        _prepareFilterItem: function(items) {
                            var that = this,
                                itemDisabledState = that.getToolbarItemOption("filterRow", "disabled"),
                                disabled = commonUtils.isDefined(itemDisabledState) ? itemDisabledState : true,
                                filterItem = [];
                            if (that._isShowApplyFilterButton()) {
                                var hintText = that.option("filterRow.applyFilterText"),
                                    onInitialized = function(e) {
                                        e.element.addClass(that._getToolbarButtonClass(DATAGRID_APPLY_BUTTON_CLASS))
                                    },
                                    onClickHandler = function() {
                                        that._applyFilterViewController.applyFilter()
                                    },
                                    toolbarItem = {
                                        widget: "dxButton",
                                        options: {
                                            icon: "apply-filter",
                                            onClick: onClickHandler,
                                            hint: hintText,
                                            text: hintText,
                                            onInitialized: onInitialized
                                        },
                                        showText: "inMenu",
                                        name: "filterRow",
                                        disabled: disabled,
                                        location: "after",
                                        locateInMenu: "auto"
                                    };
                                filterItem.push(toolbarItem)
                            }
                            return filterItem
                        },
                        _isShowApplyFilterButton: function() {
                            var filterRowOptions = this.option("filterRow");
                            return filterRowOptions && filterRowOptions.visible && "onClick" === filterRowOptions.applyFilter
                        },
                        init: function() {
                            this.callBase();
                            this._dataController = this.getController("data");
                            this._applyFilterViewController = this.getController("applyFilter")
                        },
                        enableApplyButton: function(value) {
                            this.updateToolbarItemOption("filterRow", "disabled", !value)
                        },
                        isVisible: function() {
                            return this.callBase() || this._isShowApplyFilterButton()
                        },
                        optionChanged: function(args) {
                            if ("filterRow" === args.name) {
                                this._invalidate();
                                this._invalidateToolbarItems();
                                args.handled = true
                            } else {
                                this.callBase(args)
                            }
                        }
                    }
                }
            }
        });
        exports.ColumnHeadersViewFilterRowExtender = ColumnHeadersViewFilterRowExtender;
        exports.DataControllerFilterRowExtender = DataControllerFilterRowExtender
    },
    /*!****************************!*\
      !*** ./Scripts/ui/menu.js ***!
      \****************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./menu/ui.menu */ 369)
    },
    /*!************************************!*\
      !*** ./Scripts/ui/menu/ui.menu.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            hoverEvents = __webpack_require__( /*! ../../events/hover */ 102),
            MenuBase = __webpack_require__( /*! ../context_menu/ui.menu_base */ 329),
            Overlay = __webpack_require__( /*! ../overlay */ 109),
            Submenu = __webpack_require__( /*! ./ui.submenu */ 370),
            Button = __webpack_require__( /*! ../button */ 196),
            TreeView = __webpack_require__( /*! ../tree_view */ 356);
        var DX_MENU_CLASS = "dx-menu",
            DX_MENU_VERTICAL_CLASS = DX_MENU_CLASS + "-vertical",
            DX_MENU_HORIZONTAL_CLASS = DX_MENU_CLASS + "-horizontal",
            DX_MENU_ITEM_CLASS = DX_MENU_CLASS + "-item",
            DX_MENU_ITEMS_CONTAINER_CLASS = DX_MENU_CLASS + "-items-container",
            DX_MENU_ITEM_EXPANDED_CLASS = DX_MENU_ITEM_CLASS + "-expanded",
            DX_CONTEXT_MENU_CLASS = "dx-context-menu",
            DX_CONTEXT_MENU_CONTAINER_BORDER_CLASS = DX_CONTEXT_MENU_CLASS + "-container-border",
            DX_CONTEXT_MENU_CONTENT_DELIMITER_CLASS = "dx-context-menu-content-delimiter",
            DX_SUBMENU_CLASS = "dx-submenu",
            DX_STATE_DISABLED_CLASS = "dx-state-disabled",
            DX_STATE_HOVER_CLASS = "dx-state-hover",
            DX_STATE_ACTIVE_CLASS = "dx-state-active",
            DX_ADAPTIVE_MODE_CLASS = DX_MENU_CLASS + "-adaptive-mode",
            DX_ADAPTIVE_HAMBURGER_BUTTON_CLASS = DX_MENU_CLASS + "-hamburger-button",
            FOCUS_UP = "up",
            FOCUS_DOWN = "down",
            FOCUS_LEFT = "left",
            FOCUS_RIGHT = "right",
            SHOW_SUBMENU_OPERATION = "showSubmenu",
            NEXTITEM_OPERATION = "nextItem",
            PREVITEM_OPERATION = "prevItem",
            DEFAULT_DELAY = {
                show: 50,
                hide: 300
            },
            ACTIONS = ["onSubmenuShowing", "onSubmenuShown", "onSubmenuHiding", "onSubmenuHidden", "onItemContextMenu", "onItemClick", "onSelectionChanged"];
        var Menu = MenuBase.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    orientation: "horizontal",
                    submenuDirection: "auto",
                    showFirstSubmenuMode: {
                        name: "onClick",
                        delay: {
                            show: 50,
                            hide: 300
                        }
                    },
                    hideSubmenuOnMouseLeave: false,
                    onSubmenuShowing: null,
                    onSubmenuShown: null,
                    onSubmenuHiding: null,
                    onSubmenuHidden: null,
                    adaptivityEnabled: false
                })
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    animation: true,
                    selectedItem: true
                })
            },
            _focusTarget: function() {
                return this.element()
            },
            _isMenuHorizontal: function() {
                return "horizontal" === this.option("orientation")
            },
            _moveFocus: function(location) {
                var argument, operation, navigationAction, $newTarget, $items = this._itemElements().filter(":visible"),
                    isMenuHorizontal = this._isMenuHorizontal(),
                    $activeItem = this._getActiveItem(true);
                switch (location) {
                    case FOCUS_UP:
                        operation = isMenuHorizontal ? SHOW_SUBMENU_OPERATION : this._getItemsNavigationOperation(PREVITEM_OPERATION);
                        argument = isMenuHorizontal ? $activeItem : $items;
                        navigationAction = this._getKeyboardNavigationAction(operation, argument);
                        $newTarget = navigationAction();
                        break;
                    case FOCUS_DOWN:
                        operation = isMenuHorizontal ? SHOW_SUBMENU_OPERATION : this._getItemsNavigationOperation(NEXTITEM_OPERATION);
                        argument = isMenuHorizontal ? $activeItem : $items;
                        navigationAction = this._getKeyboardNavigationAction(operation, argument);
                        $newTarget = navigationAction();
                        break;
                    case FOCUS_RIGHT:
                        operation = isMenuHorizontal ? this._getItemsNavigationOperation(NEXTITEM_OPERATION) : SHOW_SUBMENU_OPERATION;
                        argument = isMenuHorizontal ? $items : $activeItem;
                        navigationAction = this._getKeyboardNavigationAction(operation, argument);
                        $newTarget = navigationAction();
                        break;
                    case FOCUS_LEFT:
                        operation = isMenuHorizontal ? this._getItemsNavigationOperation(PREVITEM_OPERATION) : SHOW_SUBMENU_OPERATION;
                        argument = isMenuHorizontal ? $items : $activeItem;
                        navigationAction = this._getKeyboardNavigationAction(operation, argument);
                        $newTarget = navigationAction();
                        break;
                    default:
                        return this.callBase(location)
                }
                if ($newTarget && 0 !== $newTarget.length) {
                    this.option("focusedElement", $newTarget)
                }
            },
            _getItemsNavigationOperation: function(operation) {
                var navOperation = operation;
                if (this.option("rtlEnabled")) {
                    navOperation = operation === PREVITEM_OPERATION ? NEXTITEM_OPERATION : PREVITEM_OPERATION
                }
                return navOperation
            },
            _getKeyboardNavigationAction: function(operation, argument) {
                var action = $.noop;
                switch (operation) {
                    case SHOW_SUBMENU_OPERATION:
                        if (!argument.hasClass(DX_STATE_DISABLED_CLASS)) {
                            action = $.proxy(this._showSubmenu, this, argument)
                        }
                        break;
                    case NEXTITEM_OPERATION:
                        action = $.proxy(this._nextItem, this, argument);
                        break;
                    case PREVITEM_OPERATION:
                        action = $.proxy(this._prevItem, this, argument)
                }
                return action
            },
            _clean: function() {
                this.callBase();
                this.option("templatesRenderAsynchronously") && clearTimeout(this._resizeEventTimer)
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this._dimensionChanged()
                }
            },
            _isAdaptivityEnabled: function() {
                return this.option("adaptivityEnabled") && "horizontal" === this.option("orientation")
            },
            _dimensionChanged: function() {
                if (!this._isAdaptivityEnabled()) {
                    return
                }
                var $menuItems = this.element().find("ul:first>li>." + DX_MENU_ITEM_CLASS),
                    menuItemsWidth = 0,
                    containerWidth = this.element().outerWidth();
                $menuItems.each(function(_, menuItem) {
                    menuItemsWidth += $(menuItem).outerWidth(true)
                });
                this._toggleAdaptiveMode(menuItemsWidth > containerWidth)
            },
            _init: function() {
                this.callBase();
                this._submenus = []
            },
            _initActions: function() {
                this._actions = {};
                $.each(ACTIONS, $.proxy(function(index, action) {
                    this._actions[action] = this._createActionByOption(action)
                }, this))
            },
            _render: function() {
                this._visibleSubmenu = null;
                this.callBase();
                this.element().addClass(DX_MENU_CLASS);
                this._isAdaptivityEnabled() && this._initAdaptivity();
                this.setAria("role", "menubar")
            },
            _renderHamburgerButton: function() {
                this._hamburger = new Button($("<div>", {
                    "class": DX_ADAPTIVE_HAMBURGER_BUTTON_CLASS
                }), {
                    icon: "menu",
                    activeStateEnabled: false,
                    onClick: $.proxy(this._toggleTreeView, this)
                });
                return this._hamburger.element()
            },
            _toggleTreeView: function(state) {
                if ($.isPlainObject(state)) {
                    state = !this._overlay.option("visible")
                }
                this._overlay.option("visible", state);
                this._toggleHamburgerActiveState(state)
            },
            _toggleHamburgerActiveState: function(state) {
                this._hamburger && this._hamburger.element().toggleClass(DX_STATE_ACTIVE_CLASS, state)
            },
            _toggleAdaptiveMode: function(state) {
                var $menuItemsContainer = this.element().find("." + DX_MENU_ITEMS_CONTAINER_CLASS),
                    $adaptiveElements = this.element().find("." + DX_ADAPTIVE_MODE_CLASS);
                if (state) {
                    this._hideVisibleSubmenu()
                } else {
                    this._treeView && this._treeView.collapseAll();
                    this._overlay && this._toggleTreeView(state)
                }
                $menuItemsContainer.toggle(!state);
                $adaptiveElements.toggle(state)
            },
            _removeAdaptivity: function() {
                if (!this._$adaptiveContainer) {
                    return
                }
                this._toggleAdaptiveMode(false);
                this._$adaptiveContainer.remove();
                this._$adaptiveContainer = null;
                this._treeView = null;
                this._hamburger = null;
                this._overlay = null
            },
            _treeviewItemClickHandler: function(e) {
                this._actions.onItemClick(e);
                if (!e.node.children.length) {
                    this._toggleTreeView(false)
                }
            },
            _getAdaptiveOverlayOptions: function() {
                var rtl = this.option("rtlEnabled"),
                    position = rtl ? "right" : "left";
                return {
                    deferRendering: false,
                    shading: false,
                    animation: false,
                    closeOnTargetScroll: true,
                    onPositioned: $.proxy(function() {
                        this._overlay.option("height", this._overlay.content().outerHeight())
                    }, this),
                    onHidden: $.proxy(function() {
                        this._toggleHamburgerActiveState(false)
                    }, this),
                    height: "auto",
                    closeOnOutsideClick: function(e) {
                        return !!!$(e.target).closest("." + DX_ADAPTIVE_HAMBURGER_BUTTON_CLASS).length
                    },
                    position: {
                        collision: "flipfit",
                        at: "bottom " + position,
                        my: "top " + position,
                        of: this._hamburger.element()
                    }
                }
            },
            _getTreeViewOptions: function() {
                var menuOptions = {},
                    that = this,
                    optionsToTransfer = ["rtlEnabled", "width", "accessKey", "activeStateEnabled", "animation", "dataSource", "disabled", "displayExpr", "displayExpr", "focusStateEnabled", "hint", "hoverStateEnabled", "itemsExpr", "items", "itemTemplate", "selectedExpr", "selectionMode", "tabIndex", "visible"],
                    actionsToTransfer = ["onItemContextMenu", "onSelectionChanged"];
                $.each(optionsToTransfer, function(_, option) {
                    menuOptions[option] = that.option(option)
                });
                $.each(actionsToTransfer, function(_, actionName) {
                    menuOptions[actionName] = $.proxy(function(e) {
                        this._actions[actionName](e)
                    }, that)
                });
                return $.extend(menuOptions, {
                    onItemClick: $.proxy(that._treeviewItemClickHandler, that),
                    onItemExpanded: $.proxy(function(e) {
                        this._actions.onSubmenuShown(e)
                    }, that),
                    onItemCollapsed: $.proxy(function(e) {
                        this._actions.onSubmenuHidden(e)
                    }, that),
                    selectNodesRecursive: false,
                    selectByClick: this.option("selectByClick"),
                    expandEvent: "click"
                })
            },
            _initAdaptivity: function() {
                if (!this._isAdaptivityEnabled()) {
                    return
                }
                this._$adaptiveContainer = $("<div>", {
                    "class": DX_ADAPTIVE_MODE_CLASS
                });
                var $hamburger = this._renderHamburgerButton();
                this._treeView = this._createComponent($("<div>"), TreeView, this._getTreeViewOptions());
                this._overlay = this._createComponent($("<div>"), Overlay, this._getAdaptiveOverlayOptions());
                this._overlay.content().append(this._treeView.element()).addClass(DX_ADAPTIVE_MODE_CLASS).addClass(this.option("cssClass"));
                this._$adaptiveContainer.append($hamburger);
                this._$adaptiveContainer.append(this._overlay.element());
                this.element().append(this._$adaptiveContainer);
                if (this.option("templatesRenderAsynchronously")) {
                    this._resizeEventTimer = setTimeout($.proxy(function() {
                        this._dimensionChanged()
                    }, this), 0)
                } else {
                    this._dimensionChanged()
                }
            },
            _getDelay: function(delayType) {
                var delay = this.option("showFirstSubmenuMode").delay;
                if (!commonUtils.isDefined(delay)) {
                    return DEFAULT_DELAY[delayType]
                } else {
                    return commonUtils.isObject(delay) ? delay[delayType] : delay
                }
            },
            _renderContainer: function() {
                var $wrapper = $("<div>");
                $wrapper.appendTo(this.element()).addClass(this._isMenuHorizontal() ? DX_MENU_HORIZONTAL_CLASS : DX_MENU_VERTICAL_CLASS);
                return this.callBase($wrapper)
            },
            _renderSubmenuItems: function(node, $itemFrame) {
                var submenu = this._createSubmenu(node, $itemFrame);
                this._submenus.push(submenu);
                this._renderBorderElement($itemFrame);
                return submenu
            },
            _createSubmenu: function(node, $rootItem) {
                var $submenuContainer = $("<div>").addClass(DX_CONTEXT_MENU_CLASS).appendTo($rootItem);
                var items = this._getChildNodes(node),
                    result = this._createComponent($submenuContainer, Submenu, $.extend(this._getSubmenuOptions(), {
                        _dataAdapter: this._dataAdapter,
                        _parentKey: node.internalFields.key,
                        items: items,
                        position: this.getSubmenuPosition($rootItem)
                    }));
                this._attachSubmenuHandlers($rootItem, result);
                return result
            },
            _getSubmenuOptions: function() {
                var $submenuTarget = $("<div>"),
                    isMenuHorizontal = this._isMenuHorizontal();
                return {
                    itemTemplate: this.option("itemTemplate"),
                    templateProvider: this.option("templateProvider"),
                    target: $submenuTarget,
                    orientation: this.option("orientation"),
                    selectionMode: this.option("selectionMode"),
                    cssClass: this.option("cssClass"),
                    selectByClick: this.option("selectByClick"),
                    hoverStateEnabled: this.option("hoverStateEnabled"),
                    activeStateEnabled: this.option("activeStateEnabled"),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    animation: this.option("animation"),
                    showSubmenuMode: this.option("showSubmenuMode"),
                    displayExpr: this.option("displayExpr"),
                    disabledExpr: this.option("disabledExpr"),
                    selectedExpr: this.option("selectedExpr"),
                    itemsExpr: this.option("itemsExpr"),
                    onSelectionChanged: $.proxy(this._nestedItemOnSelectionChangedHandler, this),
                    onItemClick: $.proxy(this._nestedItemOnItemClickHandler, this),
                    onItemRendered: this.option("onItemRendered"),
                    onLeftFirstItem: isMenuHorizontal ? null : $.proxy(this._moveMainMenuFocus, this, PREVITEM_OPERATION),
                    onLeftLastItem: isMenuHorizontal ? null : $.proxy(this._moveMainMenuFocus, this, NEXTITEM_OPERATION),
                    onCloseRootSubmenu: $.proxy(this._moveMainMenuFocus, this, isMenuHorizontal ? PREVITEM_OPERATION : null),
                    onExpandLastSubmenu: isMenuHorizontal ? $.proxy(this._moveMainMenuFocus, this, NEXTITEM_OPERATION) : null,
                    _hideDelimiter: this.option("_hideDelimiter")
                }
            },
            _getShowFirstSubmenuMode: function() {
                if (!this._isDesktopDevice()) {
                    return "onClick"
                }
                var optionValue = this.option("showFirstSubmenuMode");
                return commonUtils.isObject(optionValue) ? optionValue.name : optionValue
            },
            _moveMainMenuFocus: function(direction) {
                var $newItem, $expandedItem = this.element().find("." + DX_MENU_ITEM_EXPANDED_CLASS).first(),
                    $parent = $expandedItem.parent();
                switch (direction) {
                    case PREVITEM_OPERATION:
                        $newItem = $parent.prev();
                        if (!$newItem.length) {
                            $newItem = $parent.siblings().last()
                        }
                        break;
                    case NEXTITEM_OPERATION:
                        $newItem = $parent.next();
                        if (!$newItem.length) {
                            $newItem = $parent.siblings().first()
                        }
                        break;
                    default:
                        $newItem = $parent;
                        if (!$newItem.length) {
                            $newItem = $parent.siblings().first()
                        }
                }
                $newItem = $newItem.children();
                this._visibleSubmenu && this._hideSubmenu(this._visibleSubmenu);
                this.focus();
                this.option("focusedElement", $newItem)
            },
            _nestedItemOnSelectionChangedHandler: function(args) {
                var selectedItem = args.addedItems.length && args.addedItems[0],
                    submenu = Submenu.getInstance(args.element),
                    onSelectionChanged = this._actions.onSelectionChanged;
                onSelectionChanged(args);
                selectedItem && this._clearSelectionInSubmenus(selectedItem[0], submenu);
                this._clearRootSelection();
                this._setOptionSilent("selectedItem", selectedItem)
            },
            _clearSelectionInSubmenus: function(item, targetSubmenu) {
                var that = this,
                    cleanAllSubmenus = !arguments.length;
                $.each(this._submenus, function(index, submenu) {
                    var $submenu = submenu._itemContainer(),
                        isOtherItem = !$submenu.is(targetSubmenu && targetSubmenu._itemContainer()),
                        $selectedItem = $submenu.find("." + that._selectedItemClass());
                    if (isOtherItem && $selectedItem.length || cleanAllSubmenus) {
                        var selectedItemData;
                        $selectedItem.removeClass(that._selectedItemClass());
                        selectedItemData = that._getItemData($selectedItem);
                        if (selectedItemData) {
                            selectedItemData.selected = false
                        }
                        submenu._clearSelectedItems()
                    }
                })
            },
            _clearRootSelection: function() {
                var $prevSelectedItem = this.element().find("." + DX_MENU_ITEMS_CONTAINER_CLASS).first().children().children().filter("." + this._selectedItemClass());
                if ($prevSelectedItem.length) {
                    var prevSelectedItemData;
                    prevSelectedItemData = this._getItemData($prevSelectedItem);
                    prevSelectedItemData.selected = false;
                    $prevSelectedItem.removeClass(this._selectedItemClass())
                }
            },
            _nestedItemOnItemClickHandler: function(e) {
                this._actions.onItemClick(e)
            },
            _attachSubmenuHandlers: function($rootItem, submenu) {
                var that = this,
                    $submenuOverlayContent = submenu.getOverlayContent(),
                    submenus = $submenuOverlayContent.find("." + DX_SUBMENU_CLASS),
                    submenuMouseLeaveName = eventUtils.addNamespace(hoverEvents.end, this.NAME + "_submenu");
                submenu.option({
                    onShowing: $.proxy(this._submenuOnShowingHandler, this, $rootItem, submenu),
                    onShown: $.proxy(this._submenuOnShownHandler, this, $rootItem, submenu),
                    onHiding: $.proxy(this._submenuOnHidingHandler, this, $rootItem, submenu),
                    onHidden: $.proxy(this._submenuOnHiddenHandler, this, $rootItem, submenu)
                });
                $.each(submenus, function(index, submenu) {
                    $(submenu).off(submenuMouseLeaveName).on(submenuMouseLeaveName, null, $.proxy(that._submenuMouseLeaveHandler, that, $rootItem))
                })
            },
            _submenuOnShowingHandler: function($rootItem, submenu) {
                var $border = $rootItem.children("." + DX_CONTEXT_MENU_CONTAINER_BORDER_CLASS);
                this._actions.onSubmenuShowing({
                    rootItem: $rootItem,
                    submenu: submenu
                });
                $border.show();
                $rootItem.addClass(DX_MENU_ITEM_EXPANDED_CLASS)
            },
            _submenuOnShownHandler: function($rootItem, submenu) {
                this._actions.onSubmenuShown({
                    rootItem: $rootItem,
                    submenu: submenu
                })
            },
            _submenuOnHidingHandler: function($rootItem, submenu, eventArgs) {
                var $border = $rootItem.children("." + DX_CONTEXT_MENU_CONTAINER_BORDER_CLASS),
                    args = eventArgs;
                args.rootItem = $rootItem;
                args.submenu = submenu;
                this._actions.onSubmenuHiding(args);
                eventArgs = args;
                if (!eventArgs.cancel) {
                    if (this._visibleSubmenu === submenu) {
                        this._visibleSubmenu = null
                    }
                    $border.hide();
                    $rootItem.removeClass(DX_MENU_ITEM_EXPANDED_CLASS)
                }
            },
            _submenuOnHiddenHandler: function($rootItem, submenu) {
                this._actions.onSubmenuHidden({
                    rootItem: $rootItem,
                    submenu: submenu
                })
            },
            _submenuMouseLeaveHandler: function($rootItem, eventArgs) {
                var that = this,
                    target = $(eventArgs.relatedTarget).parents("." + DX_CONTEXT_MENU_CLASS)[0],
                    contextmenu = that._getSubmenuByRootElement($rootItem).getOverlayContent()[0];
                if (that.option("hideSubmenuOnMouseLeave") && target !== contextmenu) {
                    that._clearTimeouts();
                    setTimeout($.proxy(that._hideSubmenuAfterTimeout, that), that._getDelay("hide"))
                }
            },
            _hideSubmenuAfterTimeout: function() {
                if (!this._visibleSubmenu) {
                    return
                }
                var isRootItemHovered = $(this._visibleSubmenu.element().context).hasClass(DX_STATE_HOVER_CLASS),
                    isSubmenuItemHovered = this._visibleSubmenu.getOverlayContent().find("." + DX_STATE_HOVER_CLASS).length;
                if (!isSubmenuItemHovered && !isRootItemHovered) {
                    this._visibleSubmenu.hide()
                }
            },
            _getSubmenuByRootElement: function($rootItem) {
                if (!$rootItem) {
                    return false
                }
                var $submenu = $rootItem.children("." + DX_CONTEXT_MENU_CLASS);
                return $submenu.length && Submenu.getInstance($submenu)
            },
            getSubmenuPosition: function($rootItem) {
                var isHorizontalMenu = this._isMenuHorizontal(),
                    submenuDirection = this.option("submenuDirection").toLowerCase(),
                    rtlEnabled = this.option("rtlEnabled"),
                    submenuPosition = {
                        collision: "flip",
                        of: $rootItem
                    };
                switch (submenuDirection) {
                    case "leftortop":
                        submenuPosition.at = "left top";
                        submenuPosition.my = isHorizontalMenu ? "left bottom" : "right top";
                        break;
                    case "rightorbottom":
                        submenuPosition.at = isHorizontalMenu ? "left bottom" : "right top";
                        submenuPosition.my = "left top";
                        break;
                    default:
                        if (isHorizontalMenu) {
                            submenuPosition.at = rtlEnabled ? "right bottom" : "left bottom";
                            submenuPosition.my = rtlEnabled ? "right top" : "left top"
                        } else {
                            submenuPosition.at = rtlEnabled ? "left top" : "right top";
                            submenuPosition.my = rtlEnabled ? "right top" : "left top"
                        }
                }
                return submenuPosition
            },
            _renderBorderElement: function($item) {
                $("<div>").appendTo($item).addClass(DX_CONTEXT_MENU_CONTAINER_BORDER_CLASS).hide()
            },
            _hoverStartHandler: function(e) {
                var mouseMoveEventName = eventUtils.addNamespace(pointerEvents.move, this.NAME),
                    $item = this._getItemElementByEventArgs(e),
                    node = this._dataAdapter.getNodeByItem(this._getItemData($item)),
                    isSelectionActive = commonUtils.isDefined(e.buttons) && 1 === e.buttons || !commonUtils.isDefined(e.buttons) && 1 === e.which;
                if (this._isItemDisabled($item)) {
                    return
                }
                $item.off(mouseMoveEventName);
                if (!this._hasChildren(node)) {
                    setTimeout($.proxy(this._hideSubmenuAfterTimeout, this), this._getDelay("hide"));
                    return
                }
                if ("onHover" === this._getShowFirstSubmenuMode() && !isSelectionActive) {
                    var submenu = this._getSubmenuByElement($item);
                    this._clearTimeouts();
                    if (!submenu.isOverlayVisible()) {
                        $item.on(mouseMoveEventName, $.proxy(this._itemMouseMoveHandler, this));
                        this._showSubmenuTimer = this._getDelay("hide")
                    }
                }
            },
            _hoverEndHandler: function(eventArg) {
                var that = this,
                    $item = that._getItemElementByEventArgs(eventArg),
                    relatedTarget = $(eventArg.relatedTarget);
                if (that._isItemDisabled($item)) {
                    return
                }
                if (relatedTarget.hasClass(DX_CONTEXT_MENU_CONTENT_DELIMITER_CLASS)) {
                    return
                }
                if (that.option("hideSubmenuOnMouseLeave") && !relatedTarget.hasClass(DX_MENU_ITEMS_CONTAINER_CLASS)) {
                    that._clearTimeouts();
                    that._hideSubmenuTimer = setTimeout(function() {
                        that._hideSubmenuAfterTimeout()
                    }, that._getDelay("hide"))
                }
            },
            _hideVisibleSubmenu: function() {
                if (!this._visibleSubmenu) {
                    return false
                }
                this._hideSubmenu(this._visibleSubmenu);
                return true
            },
            _showSubmenu: function($itemElement) {
                var submenu = this._getSubmenuByElement($itemElement);
                if (this._visibleSubmenu !== submenu) {
                    this._hideVisibleSubmenu()
                }
                submenu && submenu.show();
                this._visibleSubmenu = submenu;
                this._hoveredRootItem = $itemElement
            },
            _hideSubmenu: function(submenu) {
                submenu && submenu.hide();
                if (this._visibleSubmenu === submenu) {
                    this._visibleSubmenu = null
                }
                this._hoveredRootItem = null
            },
            _itemMouseMoveHandler: function(e) {
                if (e.pointers && e.pointers.length) {
                    return
                }
                var that = this,
                    $item = $(e.currentTarget);
                if (!commonUtils.isDefined(that._showSubmenuTimer)) {
                    return
                }
                that._clearTimeouts();
                that._showSubmenuTimer = setTimeout(function() {
                    var submenu = that._getSubmenuByElement($item);
                    if (submenu && !submenu.isOverlayVisible()) {
                        that._showSubmenu($item)
                    }
                }, that._getDelay("show"))
            },
            _clearTimeouts: function() {
                clearTimeout(this._hideSubmenuTimer);
                clearTimeout(this._showSubmenuTimer)
            },
            _getSubmenuByElement: function($itemElement, itemData) {
                var submenu = this._getSubmenuByRootElement($itemElement);
                if (submenu) {
                    return submenu
                } else {
                    itemData = itemData || this._getItemData($itemElement);
                    var node = this._dataAdapter.getNodeByItem(itemData);
                    return this._hasChildren(node) && this._renderSubmenuItems(node, $itemElement)
                }
            },
            _updateSubmenuVisibilityOnClick: function(actionArgs) {
                var currentSubmenu, args = actionArgs.args.length && actionArgs.args[0];
                if (!args || this._disabledGetter(args.itemData)) {
                    return
                }
                args.jQueryEvent.stopPropagation();
                currentSubmenu = this._getSubmenuByElement(args.itemElement, args.itemData);
                this._updateSelectedItemOnClick(actionArgs);
                if (this._visibleSubmenu) {
                    if (this._visibleSubmenu === currentSubmenu) {
                        if ("onClick" === this.option("showFirstSubmenuMode")) {
                            this._hideSubmenu(this._visibleSubmenu)
                        }
                        return
                    } else {
                        this._hideSubmenu(this._visibleSubmenu)
                    }
                }
                if (!currentSubmenu) {
                    return
                }
                if (!currentSubmenu.isOverlayVisible()) {
                    this._showSubmenu(args.itemElement);
                    return
                }
            },
            _optionChanged: function(args) {
                if (this._cancelOptionChange === args.name) {
                    return
                }
                this._hideShownSubmenuOnOptionChange(args.name);
                switch (args.name) {
                    case "orientation":
                    case "submenuDirection":
                    case "hideSubmenuOnMouseLeave":
                    case "showFirstSubmenuMode":
                        this._invalidate();
                        break;
                    case "showSubmenuMode":
                        this._changeSubmenusOption(args.name, args.value);
                        break;
                    case "onSubmenuShowing":
                    case "onSubmenuShown":
                    case "onSubmenuHiding":
                    case "onSubmenuHidden":
                        this._initActions();
                        break;
                    case "adaptivityEnabled":
                        args.value ? this._initAdaptivity() : this._removeAdaptivity();
                        break;
                    case "width":
                        if (this._isAdaptivityEnabled()) {
                            this._treeView.option(args.name, args.value);
                            this._overlay.option(args.name, args.value)
                        }
                        this.callBase(args);
                        this._dimensionChanged();
                        break;
                    default:
                        if (this._isAdaptivityEnabled()) {
                            this._treeView.option(args.name, args.value)
                        }
                        this.callBase(args)
                }
            },
            _hideShownSubmenuOnOptionChange: function(optionName) {
                if ("focusedElement" !== optionName && this._visibleSubmenu) {
                    this._hideSubmenu(this._visibleSubmenu)
                }
            },
            _changeSubmenusOption: function(name, value) {
                $.each(this._submenus, function(index, submenu) {
                    submenu.option(name, value)
                })
            },
            selectItem: function(itemElement) {
                this._hideSubmenu(this._visibleSubmenu);
                this.callBase(itemElement)
            },
            unselectItem: function(itemElement) {
                this._hideSubmenu(this._visibleSubmenu);
                this.callBase(itemElement)
            }
        });
        registerComponent("dxMenu", Menu);
        module.exports = Menu
    },
    /*!***************************************!*\
      !*** ./Scripts/ui/menu/ui.submenu.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            positionUtils = __webpack_require__( /*! ../../animation/position */ 61),
            ContextMenu = __webpack_require__( /*! ../context_menu */ 327);
        var DX_CONTEXT_MENU_CONTENT_DELIMITER_CLASS = "dx-context-menu-content-delimiter",
            DX_SUBMENU_CLASS = "dx-submenu";
        var Submenu = ContextMenu.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    orientation: "horizontal"
                })
            },
            _initDataAdapter: function() {
                this._dataAdapter = this.option("_dataAdapter");
                if (this._dataAdapter) {
                    this._dataAdapter.options.rooValue = this.option("_parentKey")
                } else {
                    this.callBase()
                }
            },
            _renderContentImpl: function() {
                this._renderContextMenuOverlay();
                this._detachShowContextMenuEvents(this.option("target"));
                this._attachShowContextMenuEvents();
                this._attachInvokeContextMenuEvents();
                var node = this._dataAdapter.getNodeByKey(this.option("_parentKey"));
                node && this._renderItems(this._getChildNodes(node));
                if (!this.option("_hideDelimiter")) {
                    this._renderDelimiter()
                }
            },
            _renderDelimiter: function() {
                this.$contentDelimiter = $("<div>").appendTo(this._itemContainer()).addClass(DX_CONTEXT_MENU_CONTENT_DELIMITER_CLASS)
            },
            _overlayPositionedActionHandler: function(arg) {
                this._showDelimiter(arg)
            },
            _hoverEndHandler: function(e) {
                this._toggleFocusClass(false, e.currentTarget)
            },
            _isMenuHorizontal: function() {
                return "horizontal" === this.option("orientation")
            },
            _hoverStartHandler: function(e) {
                this.callBase(e);
                this._toggleFocusClass(true, e.currentTarget)
            },
            _showDelimiter: function(arg) {
                var containerOffset, rootOffset, $submenu = this._itemContainer().children("." + DX_SUBMENU_CLASS).eq(0),
                    $rootItem = this.option("position").of,
                    position = {
                        of: $submenu
                    };
                if (this.$contentDelimiter) {
                    containerOffset = arg.position;
                    rootOffset = $rootItem.offset();
                    this.$contentDelimiter.css("display", "block");
                    if (this._isMenuHorizontal()) {
                        this.$contentDelimiter.width($rootItem.width() < $submenu.width() ? $rootItem.width() - 2 : $submenu.width() - 2);
                        this.$contentDelimiter.height(2);
                        if (containerOffset.v.location > rootOffset.top) {
                            if (Math.round(containerOffset.h.location) === Math.round(rootOffset.left)) {
                                position.offset = "1 -1";
                                position.at = "left top";
                                position.my = "left top"
                            } else {
                                position.offset = "-1 -1";
                                position.at = "right top";
                                position.my = "right top"
                            }
                        } else {
                            this.$contentDelimiter.height(5);
                            if (Math.round(containerOffset.h.location) === Math.round(rootOffset.left)) {
                                position.offset = "1 4";
                                position.at = "left bottom";
                                position.my = "left bottom"
                            } else {
                                position.offset = "-1 2";
                                position.at = "right bottom";
                                position.my = "right bottom"
                            }
                        }
                    } else {
                        this.$contentDelimiter.width(2);
                        this.$contentDelimiter.height($rootItem.height() < $submenu.height() ? $rootItem.height() - 2 : $submenu.height() - 2);
                        if (containerOffset.h.location > rootOffset.left) {
                            if (Math.round(containerOffset.v.location) === Math.round(rootOffset.top)) {
                                position.offset = "-1 1";
                                position.at = "left top";
                                position.my = "left top"
                            } else {
                                position.offset = "-1 -1";
                                position.at = "left bottom";
                                position.my = "left bottom"
                            }
                        } else {
                            if (Math.round(containerOffset.v.location) === Math.round(rootOffset.top)) {
                                position.offset = "1 1";
                                position.at = "right top";
                                position.my = "right top"
                            } else {
                                position.offset = "1 -1";
                                position.at = "right bottom";
                                position.my = "right bottom"
                            }
                        }
                    }
                    positionUtils.setup(this.$contentDelimiter, position)
                }
            },
            isOverlayVisible: function() {
                return this._overlay.option("visible")
            },
            getOverlayContent: function() {
                return this._overlay.content()
            }
        });
        Submenu.publicName("dxSubmenu");
        module.exports = Submenu
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.header_filter.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            headerFilterCore = __webpack_require__( /*! ../grid_core/ui.grid_core.header_filter */ 372),
            headerFilterMixin = headerFilterCore.headerFilterMixin,
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            allowHeaderFiltering = headerFilterCore.allowHeaderFiltering,
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            dataUtils = __webpack_require__( /*! ../../data/utils */ 137),
            dataCoreUtils = __webpack_require__( /*! ../../core/utils/data */ 36),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            normalizeDataSourceOptions = __webpack_require__( /*! ../../data/data_source/data_source */ 155).normalizeDataSourceOptions,
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var DATE_INTERVAL_FORMATS = {
            month: function(value) {
                return dateLocalization.getMonthNames()[value - 1]
            },
            quarter: function(value) {
                return dateLocalization.format(new Date(2e3, 3 * value - 1), "quarter")
            }
        };
        exports.HeaderFilterController = gridCore.ViewController.inherit(function() {
            var getFormatOptions = function(value, column, currentLevel) {
                var groupInterval = gridCore.getGroupInterval(column),
                    result = $.extend({
                        target: "headerFilter"
                    }, column);
                if (groupInterval) {
                    result.groupInterval = groupInterval[currentLevel];
                    if ("date" === column.dataType) {
                        result.format = DATE_INTERVAL_FORMATS[groupInterval[currentLevel]]
                    } else {
                        if ("number" === column.dataType) {
                            result.getDisplayFormat = function() {
                                var formatOptions = {
                                        format: column.format,
                                        precision: column.precision
                                    },
                                    firstValueText = gridCore.formatValue(value, formatOptions),
                                    secondValue = value + groupInterval[currentLevel],
                                    secondValueText = gridCore.formatValue(secondValue, formatOptions);
                                return firstValueText && secondValueText ? firstValueText + " - " + secondValueText : ""
                            }
                        }
                    }
                }
                return result
            };
            return {
                init: function() {
                    this._columnsController = this.getController("columns");
                    this._dataController = this.getController("data");
                    this._headerFilterView = this.getView("headerFilterView")
                },
                _updateSelectedState: function(items, column, parent) {
                    var i = items.length,
                        isExclude = "exclude" === column.filterType;
                    while (i--) {
                        var item = items[i];
                        if ("items" in items[i]) {
                            this._updateSelectedState(items[i].items, column, items[i])
                        }
                        headerFilterCore.updateHeaderFilterItemSelectionState(item, gridCoreUtils.getIndexByKey(items[i].value, column.filterValues, null) > -1, isExclude)
                    }
                },
                _normalizeGroupItem: function(item, currentLevel, options) {
                    var value, displayValue, path = options.path,
                        valueSelector = options.valueSelector,
                        displaySelector = options.displaySelector,
                        column = options.column;
                    if (valueSelector && displaySelector) {
                        value = valueSelector(item);
                        displayValue = displaySelector(item)
                    } else {
                        value = item.key;
                        displayValue = value
                    }
                    item = commonUtils.isObject(item) ? item : {};
                    path.push(value);
                    if (1 === path.length) {
                        item.value = path[0]
                    } else {
                        item.value = path.join("/")
                    }
                    item.text = gridCore.formatValue(displayValue, getFormatOptions(displayValue, column, currentLevel));
                    if (!item.text) {
                        item.text = options.headerFilterOptions.texts.emptyValue
                    }
                    delete item.key;
                    return item
                },
                _processGroupItems: function(groupItems, currentLevel, path, options) {
                    var displaySelector, valueSelector, that = this,
                        column = options.column,
                        lookup = column.lookup,
                        level = options.level;
                    path = path || [];
                    currentLevel = currentLevel || 0;
                    if (lookup) {
                        displaySelector = dataCoreUtils.compileGetter(lookup.displayExpr);
                        valueSelector = dataCoreUtils.compileGetter(lookup.valueExpr)
                    }
                    for (var i = 0; i < groupItems.length; i++) {
                        groupItems[i] = that._normalizeGroupItem(groupItems[i], currentLevel, {
                            column: options.column,
                            headerFilterOptions: options.headerFilterOptions,
                            displaySelector: displaySelector,
                            valueSelector: valueSelector,
                            path: path
                        });
                        if ("items" in groupItems[i]) {
                            if (currentLevel === level || !commonUtils.isDefined(groupItems[i].value)) {
                                delete groupItems[i].items
                            } else {
                                that._processGroupItems(groupItems[i].items, currentLevel + 1, path, options)
                            }
                        }
                        path.pop()
                    }
                },
                getDataSource: function(column) {
                    var filter, cutoffLevel, origPostProcess, that = this,
                        dataSource = that._dataController.dataSource(),
                        group = gridCore.getHeaderFilterGroupParameters(column, dataSource.remoteOperations().grouping),
                        headerFilterDataSource = column.headerFilter && column.headerFilter.dataSource,
                        headerFilterOptions = that.option("headerFilter"),
                        options = {
                            component: that.component
                        };
                    if (commonUtils.isDefined(headerFilterDataSource) && !commonUtils.isFunction(headerFilterDataSource)) {
                        dataSource = normalizeDataSourceOptions(headerFilterDataSource);
                        dataSource.postProcess = function(items) {
                            that._updateSelectedState(items, column);
                            return items
                        };
                        return dataSource
                    }
                    if (column.lookup) {
                        dataSource = normalizeDataSourceOptions(column.lookup.dataSource);
                        dataSource.postProcess = function(items) {
                            if (0 === this.pageIndex()) {
                                items = items.slice(0);
                                items.unshift(null)
                            }
                            that._processGroupItems(items, null, null, {
                                level: 0,
                                column: column,
                                headerFilterOptions: headerFilterOptions
                            });
                            that._updateSelectedState(items, column);
                            return items
                        };
                        options.dataSource = dataSource
                    } else {
                        cutoffLevel = commonUtils.isArray(group) ? group.length - 1 : 0;
                        that._currentColumn = column;
                        filter = that._dataController.getCombinedFilter();
                        that._currentColumn = null;
                        options.dataSource = {
                            filter: filter,
                            group: group,
                            load: function(options) {
                                var d = $.Deferred();
                                options.dataField = column.dataField || column.name;
                                dataSource.load(options).done(function(data) {
                                    that._processGroupItems(data, null, null, {
                                        level: cutoffLevel,
                                        column: column,
                                        headerFilterOptions: headerFilterOptions
                                    });
                                    that._updateSelectedState(data, column);
                                    d.resolve(data)
                                }).fail(d.reject);
                                return d
                            }
                        }
                    }
                    if (commonUtils.isFunction(headerFilterDataSource)) {
                        headerFilterDataSource.call(column, options);
                        origPostProcess = options.dataSource.postProcess;
                        options.dataSource.postProcess = function(data) {
                            var items = origPostProcess && origPostProcess.apply(this, arguments) || data;
                            that._updateSelectedState(items, column);
                            return items
                        }
                    }
                    return options.dataSource
                },
                getCurrentColumn: function() {
                    return this._currentColumn
                },
                showHeaderFilterMenu: function(columnIndex) {
                    var that = this,
                        column = $.extend(true, {}, that._columnsController.getColumns()[columnIndex]);
                    if (column) {
                        var visibleIndex = that._columnsController.getVisibleIndex(columnIndex),
                            isGroupColumn = column && commonUtils.isDefined(column.groupIndex),
                            view = isGroupColumn ? that.getView("headerPanel") : that.getView("columnHeadersView"),
                            $columnElement = view.getColumnElements().eq(isGroupColumn ? column.groupIndex : visibleIndex),
                            groupInterval = gridCore.getGroupInterval(column);
                        var options = $.extend(column, {
                            type: groupInterval && groupInterval.length > 1 ? "tree" : "list",
                            apply: function() {
                                that._columnsController.columnOption(columnIndex, {
                                    filterValues: this.filterValues,
                                    filterType: this.filterType
                                })
                            },
                            onShowing: function(e) {
                                var dxResizableInstance = e.component.overlayContent().dxResizable("instance");
                                dxResizableInstance && dxResizableInstance.option("onResizeEnd", function(e) {
                                    var columnsController = that.getController("columns"),
                                        headerFilterByColumn = columnsController.columnOption(options.dataField, "headerFilter");
                                    headerFilterByColumn = headerFilterByColumn || {};
                                    headerFilterByColumn.width = e.width;
                                    headerFilterByColumn.height = e.height;
                                    columnsController.columnOption(options.dataField, "headerFilter", headerFilterByColumn, true)
                                })
                            }
                        });
                        options.dataSource = that.getDataSource(options);
                        that._headerFilterView.showHeaderFilterMenu($columnElement, options)
                    }
                },
                hideHeaderFilterMenu: function() {
                    this._headerFilterView.hideHeaderFilterMenu()
                }
            }
        }());
        var ColumnHeadersViewHeaderFilterExtender = $.extend({}, headerFilterCore.headerFilterMixin, {
            _renderCellContent: function($cell, options) {
                var $headerFilterIndicator, that = this,
                    column = options.column;
                that.callBase($cell, options);
                if (!column.command && !commonUtils.isDefined(column.groupIndex) && allowHeaderFiltering(column) && that.option("headerFilter.visible") && "header" === options.rowType) {
                    $headerFilterIndicator = that._applyColumnState({
                        name: "headerFilter",
                        rootElement: $cell,
                        column: column,
                        showColumnLines: that.option("showColumnLines")
                    });
                    $headerFilterIndicator && that._subscribeToIndicatorEvent($headerFilterIndicator, column, "headerFilter")
                }
            },
            _subscribeToIndicatorEvent: function($indicator, column, indicatorName) {
                var that = this;
                if ("headerFilter" === indicatorName) {
                    $indicator.on(clickEvent.name, that.createAction(function(e) {
                        var event = e.jQueryEvent;
                        event.stopPropagation();
                        that.getController("headerFilter").showHeaderFilterMenu(column.index)
                    }))
                }
            },
            _updateIndicator: function($cell, column, indicatorName) {
                var $indicator = this.callBase($cell, column, indicatorName);
                $indicator && this._subscribeToIndicatorEvent($indicator, column, indicatorName)
            },
            _columnOptionChanged: function(e) {
                var optionNames = e.optionNames;
                if (gridCore.checkChanges(optionNames, ["filterValues", "filterType"])) {
                    if (this.option("headerFilter.visible")) {
                        this._updateIndicators("headerFilter")
                    }
                    return
                }
                this.callBase(e)
            }
        });
        var HeaderPanelHeaderFilterExtender = $.extend({}, headerFilterMixin, {
            _createGroupPanelItem: function($rootElement, groupColumn) {
                var $headerFilterIndicator, that = this,
                    $item = that.callBase.apply(that, arguments);
                if (!groupColumn.command && allowHeaderFiltering(groupColumn) && that.option("headerFilter.visible")) {
                    $headerFilterIndicator = that._applyColumnState({
                        name: "headerFilter",
                        rootElement: $item,
                        column: {
                            alignment: commonUtils.getDefaultAlignment(that.option("rtlEnabled")),
                            filterValues: groupColumn.filterValues,
                            allowHeaderFiltering: true
                        },
                        showColumnLines: true
                    });
                    $headerFilterIndicator && $headerFilterIndicator.on(clickEvent.name, that.createAction(function(e) {
                        var event = e.jQueryEvent;
                        event.stopPropagation();
                        that.getController("headerFilter").showHeaderFilterMenu(groupColumn.index)
                    }))
                }
                return $item
            }
        });
        var INVERTED_BINARY_OPERATIONS = {
            "=": "<>",
            "<>": "=",
            ">": "<=",
            ">=": "<",
            "<": ">=",
            "<=": ">",
            contains: "notcontains",
            notcontains: "contains",
            startswith: "notcontains",
            endswith: "notcontains"
        };

        function invertFilterExpression(filter) {
            var i, currentGroupOperation, result;
            if ($.isArray(filter[0])) {
                result = [];
                for (i = 0; i < filter.length; i++) {
                    if ($.isArray(filter[i])) {
                        if (currentGroupOperation) {
                            result.push(currentGroupOperation)
                        }
                        result.push(invertFilterExpression(filter[i]));
                        currentGroupOperation = "or"
                    } else {
                        currentGroupOperation = dataUtils.isConjunctiveOperator(filter[i]) ? "or" : "and"
                    }
                }
                return result
            }
            result = dataUtils.normalizeBinaryCriterion(filter);
            result[1] = INVERTED_BINARY_OPERATIONS[result[1]] || result[1];
            return result
        }
        exports.invertFilterExpression = invertFilterExpression;
        var DataControllerFilterRowExtender = {
            _calculateAdditionalFilter: function() {
                var that = this,
                    filters = [that.callBase()],
                    columns = that._columnsController.getVisibleColumns(),
                    headerFilterController = that.getController("headerFilter"),
                    currentColumn = headerFilterController.getCurrentColumn();
                $.each(columns, function(_, column) {
                    var filter;
                    if (currentColumn && currentColumn.index === column.index) {
                        return
                    }
                    if (allowHeaderFiltering(column) && column.calculateFilterExpression && commonUtils.isArray(column.filterValues) && column.filterValues.length) {
                        var filterValues = [],
                            isExclude = "exclude" === column.filterType;
                        $.each(column.filterValues, function(_, filterValue) {
                            if (commonUtils.isArray(filterValue)) {
                                filter = isExclude ? invertFilterExpression(filterValue) : filterValue
                            } else {
                                if (column.deserializeValue && "date" !== column.dataType && "number" !== column.dataType) {
                                    filterValue = column.deserializeValue(filterValue)
                                }
                                filter = column.createFilterExpression(filterValue, isExclude ? "<>" : "=", "headerFilter")
                            }
                            if (filter) {
                                filter.columnIndex = column.index
                            }
                            filterValues.push(filter)
                        });
                        filterValues = gridCore.combineFilters(filterValues, isExclude ? "and" : "or");
                        filters.push(filterValues)
                    }
                });
                return gridCore.combineFilters(filters)
            }
        };
        gridCore.registerModule("headerFilter", {
            defaultOptions: function() {
                return {
                    headerFilter: {
                        visible: false,
                        width: 252,
                        height: 300,
                        texts: {
                            emptyValue: messageLocalization.format("dxDataGrid-headerFilterEmptyValue"),
                            ok: messageLocalization.format("dxDataGrid-headerFilterOK"),
                            cancel: messageLocalization.format("dxDataGrid-headerFilterCancel")
                        }
                    }
                }
            },
            controllers: {
                headerFilter: exports.HeaderFilterController
            },
            views: {
                headerFilterView: headerFilterCore.HeaderFilterView
            },
            extenders: {
                controllers: {
                    data: DataControllerFilterRowExtender
                },
                views: {
                    columnHeadersView: ColumnHeadersViewHeaderFilterExtender,
                    headerPanel: HeaderPanelHeaderFilterExtender
                }
            }
        })
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/grid_core/ui.grid_core.header_filter.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            modules = __webpack_require__( /*! ./ui.grid_core.modules */ 338),
            gridCoreUtils = __webpack_require__( /*! ./ui.grid_core.utils */ 341),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Popup = __webpack_require__( /*! ../popup */ 195),
            TreeView = __webpack_require__( /*! ../tree_view */ 356),
            List = __webpack_require__( /*! ../list */ 213);
        var DATAGRID_HEADER_FILTER_CLASS = "dx-header-filter",
            DATAGRID_HEADER_FILTER_MENU_CLASS = "dx-header-filter-menu";

        function resetChildrenItemSelection(items) {
            items = items || [];
            for (var i = 0; i < items.length; i++) {
                items[i].selected = false;
                resetChildrenItemSelection(items[i].items)
            }
        }
        exports.updateHeaderFilterItemSelectionState = function(item, filterValuesMatch, isExcludeFilter) {
            if (filterValuesMatch ^ isExcludeFilter) {
                item.selected = true;
                if (isExcludeFilter && item.items) {
                    for (var j = 0; j < item.items.length; j++) {
                        if (!item.items[j].selected) {
                            item.selected = void 0;
                            break
                        }
                    }
                }
            } else {
                if (isExcludeFilter) {
                    item.selected = false;
                    resetChildrenItemSelection(item.items)
                }
            }
        };
        exports.HeaderFilterView = modules.View.inherit({
            getPopupContainer: function() {
                return this._popupContainer
            },
            getListContainer: function() {
                return this._listContainer
            },
            applyHeaderFilter: function(options) {
                var that = this,
                    list = that.getListContainer(),
                    isSelectAll = list.element().find(".dx-checkbox").eq(0).hasClass("dx-checkbox-checked"),
                    filterValues = [];
                var fillSelectedItemKeys = function(filterValues, items, isExclude) {
                    $.each(items, function(_, item) {
                        if (void 0 !== item.selected && !!item.selected ^ isExclude) {
                            filterValues.push(item.value)
                        } else {
                            if (item.items && item.items.length) {
                                fillSelectedItemKeys(filterValues, item.items, isExclude)
                            }
                        }
                    })
                };
                if (!isSelectAll) {
                    if ("tree" === options.type) {
                        fillSelectedItemKeys(filterValues, list.option("items"), "exclude" === options.filterType);
                        options.filterValues = filterValues
                    }
                } else {
                    if (commonUtils.isArray(options.filterValues)) {
                        options.filterValues = []
                    }
                }
                if (options.filterValues && !options.filterValues.length) {
                    options.filterValues = void 0
                }
                options.apply();
                that.hideHeaderFilterMenu()
            },
            showHeaderFilterMenu: function($columnElement, options) {
                var popupContainer, that = this;
                if (options) {
                    that._initializePopupContainer(options);
                    popupContainer = that.getPopupContainer();
                    that.hideHeaderFilterMenu();
                    that.updatePopup($columnElement, options);
                    popupContainer.show()
                }
            },
            hideHeaderFilterMenu: function() {
                var headerFilterMenu = this.getPopupContainer();
                headerFilterMenu && headerFilterMenu.hide()
            },
            updatePopup: function($element, options) {
                var that = this,
                    alignment = "right" === options.alignment ? "left" : "right";
                if (that._popupContainer) {
                    that._cleanPopupContent();
                    that._popupContainer.option("position", {
                        my: alignment + " top",
                        at: alignment + " bottom",
                        of: $element,
                        collision: "flip fit"
                    })
                }
            },
            _cleanPopupContent: function() {
                this._popupContainer && this._popupContainer.content().empty()
            },
            _initializePopupContainer: function(options) {
                var that = this,
                    $element = that.element(),
                    headerFilterOptions = that.option("headerFilter"),
                    width = options.headerFilter && options.headerFilter.width || headerFilterOptions && headerFilterOptions.width,
                    height = options.headerFilter && options.headerFilter.height || headerFilterOptions && headerFilterOptions.height,
                    dxPopupOptions = {
                        width: width,
                        height: height,
                        visible: false,
                        shading: false,
                        showTitle: false,
                        showCloseButton: false,
                        closeOnTargetScroll: true,
                        dragEnabled: false,
                        closeOnOutsideClick: true,
                        toolbarItems: [{
                            toolbar: "bottom",
                            location: "after",
                            widget: "dxButton",
                            options: {
                                text: headerFilterOptions.texts.ok,
                                onClick: function() {
                                    that.applyHeaderFilter(options)
                                }
                            }
                        }, {
                            toolbar: "bottom",
                            location: "after",
                            widget: "dxButton",
                            options: {
                                text: headerFilterOptions.texts.cancel,
                                onClick: function() {
                                    that.hideHeaderFilterMenu()
                                }
                            }
                        }],
                        resizeEnabled: true,
                        onShowing: function(e) {
                            that._initializeListContainer(options);
                            options.onShowing && options.onShowing(e)
                        },
                        onInitialized: function(e) {
                            var component = e.component;
                            component.option("animation", component._getDefaultOptions().animation)
                        }
                    };
                if (!commonUtils.isDefined(that._popupContainer)) {
                    that._popupContainer = that._createComponent($element, Popup, dxPopupOptions)
                } else {
                    that._popupContainer.option(dxPopupOptions)
                }
            },
            _initializeListContainer: function(options) {
                var that = this,
                    $content = that._popupContainer.content(),
                    widgetOptions = {
                        dataSource: options.dataSource,
                        onContentReady: function() {
                            that.renderCompleted.fire()
                        },
                        itemTemplate: function(data, _, $element) {
                            if (options.encodeHtml) {
                                return $element.text(data.text)
                            }
                            return $element.html(data.text)
                        }
                    };
                if ("tree" === options.type) {
                    that._listContainer = that._createComponent($("<div>").appendTo($content), TreeView, $.extend(widgetOptions, {
                        showCheckBoxesMode: "selectAll",
                        keyExpr: "id"
                    }))
                } else {
                    that._listContainer = that._createComponent($("<div>").appendTo($content), List, $.extend(widgetOptions, {
                        pageLoadMode: "scrollBottom",
                        showSelectionControls: true,
                        selectionMode: "all",
                        onSelectionChanged: function(e) {
                            var items = e.component.option("items"),
                                selectedItems = e.component.option("selectedItems");
                            if (!e.component._selectedItemsUpdating) {
                                if (0 === selectedItems.length && items.length) {
                                    options.filterType = "include";
                                    options.filterValues = []
                                } else {
                                    if (selectedItems.length === items.length) {
                                        options.filterType = "exclude";
                                        options.filterValues = []
                                    }
                                }
                            }
                            $.each(items, function(index, item) {
                                var filterValueIndex, selected = gridCoreUtils.getIndexByKey(item, selectedItems, null) >= 0,
                                    oldSelected = !!item.selected;
                                if (oldSelected !== selected) {
                                    item.selected = selected;
                                    options.filterValues = options.filterValues || [];
                                    filterValueIndex = gridCoreUtils.getIndexByKey(item.value, options.filterValues, null);
                                    if (filterValueIndex >= 0) {
                                        options.filterValues.splice(filterValueIndex, 1)
                                    }
                                    if (selected ^ "exclude" === options.filterType) {
                                        options.filterValues.push(item.value)
                                    }
                                }
                            })
                        },
                        onContentReady: function(e) {
                            var component = e.component,
                                items = component.option("items"),
                                selectedItems = [],
                                selectAllCheckBox = e.element.find(".dx-list-select-all-checkbox").dxCheckBox("instance");
                            $.each(items, function() {
                                if (this.selected) {
                                    selectedItems.push(this)
                                }
                            });
                            component._selectedItemsUpdating = true;
                            component.option("selectedItems", selectedItems);
                            component._selectedItemsUpdating = false;
                            if (options.filterValues && options.filterValues.length) {
                                selectAllCheckBox.option("value", void 0)
                            }
                        }
                    }))
                }
            },
            _renderCore: function(options) {
                this.element().addClass(DATAGRID_HEADER_FILTER_MENU_CLASS)
            }
        });
        var allowHeaderFiltering = exports.allowHeaderFiltering = function(column) {
            return commonUtils.isDefined(column.allowHeaderFiltering) ? column.allowHeaderFiltering : column.allowFiltering
        };
        exports.headerFilterMixin = {
            _applyColumnState: function(options) {
                var $headerFilterIndicator, rootElement = options.rootElement,
                    column = options.column;
                if ("headerFilter" === options.name) {
                    rootElement.find("." + DATAGRID_HEADER_FILTER_CLASS).remove();
                    if (allowHeaderFiltering(column)) {
                        $headerFilterIndicator = this.callBase(options).toggleClass("dx-header-filter-empty", !column.filterValues || !column.filterValues.length)
                    }
                    return $headerFilterIndicator
                }
                return this.callBase(options)
            },
            _getIndicatorClassName: function(name) {
                if ("headerFilter" === name) {
                    return DATAGRID_HEADER_FILTER_CLASS
                }
                return this.callBase(name)
            },
            _renderIndicator: function(options) {
                var rtlEnabled, $container = options.container,
                    $indicator = options.indicator;
                if ("headerFilter" === options.name) {
                    rtlEnabled = this.option("rtlEnabled");
                    if ($container.children().length && (!rtlEnabled && "right" === options.columnAlignment || rtlEnabled && "left" === options.columnAlignment)) {
                        $container.prepend($indicator);
                        return
                    }
                }
                this.callBase(options)
            },
            optionChanged: function(args) {
                if ("headerFilter" === args.name) {
                    this._invalidate();
                    args.handled = true
                } else {
                    this.callBase(args)
                }
            }
        }
    },
    /*!*****************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.search.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            selectors = __webpack_require__( /*! ../widget/jquery.selectors */ 101),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dataQuery = __webpack_require__( /*! ../../data/query */ 158);
        __webpack_require__( /*! ./ui.data_grid.editor_factory */ 363);
        var DATAGRID_SEARCH_PANEL_CLASS = "dx-datagrid-search-panel",
            DATAGRID_SEARCH_TEXT_CLASS = "dx-datagrid-search-text",
            FILTERING_TIMEOUT = 700;

        function allowSearch(column) {
            return commonUtils.isDefined(column.allowSearch) ? column.allowSearch : column.allowFiltering
        }

        function parseValue(column, text) {
            var lookup = column.lookup;
            if (lookup) {
                return column.parseValue.call(lookup, text)
            } else {
                return column.parseValue ? column.parseValue(text) : text
            }
        }
        gridCore.registerModule("search", {
            defaultOptions: function() {
                return {
                    searchPanel: {
                        visible: false,
                        width: 160,
                        placeholder: messageLocalization.format("dxDataGrid-searchPanelPlaceholder"),
                        highlightSearchText: true,
                        text: "",
                        searchVisibleColumnsOnly: false
                    }
                }
            },
            extenders: {
                controllers: {
                    data: function() {
                        var calculateSearchFilter = function(that, text) {
                            var i, column, filterValue, lookup, columns = that._columnsController.getColumns(),
                                searchVisibleColumnsOnly = that.option("searchPanel.searchVisibleColumnsOnly"),
                                filters = [];
                            if (!text) {
                                return null
                            }

                            function onQueryDone(items) {
                                var i, value, valueGetter = compileGetter(lookup.valueExpr);
                                for (i = 0; i < items.length; i++) {
                                    value = valueGetter(items[i]);
                                    filters.push(column.createFilterExpression(value, null, "search"))
                                }
                            }
                            for (i = 0; i < columns.length; i++) {
                                column = columns[i];
                                if (searchVisibleColumnsOnly && !column.visible) {
                                    continue
                                }
                                if (allowSearch(column) && column.calculateFilterExpression) {
                                    lookup = column.lookup;
                                    filterValue = parseValue(column, text);
                                    if (lookup && lookup.items) {
                                        dataQuery(lookup.items).filter(column.createFilterExpression.call({
                                            dataField: lookup.displayExpr,
                                            dataType: lookup.dataType,
                                            calculateFilterExpression: column.calculateFilterExpression
                                        }, filterValue, null, "search")).enumerate().done(onQueryDone)
                                    } else {
                                        if (void 0 !== filterValue) {
                                            filters.push(column.createFilterExpression(filterValue, null, "search"))
                                        }
                                    }
                                }
                            }
                            return gridCore.combineFilters(filters, "or")
                        };
                        return {
                            publicMethods: function() {
                                return this.callBase().concat(["searchByText"])
                            },
                            _calculateAdditionalFilter: function() {
                                var that = this,
                                    filter = that.callBase(),
                                    searchFilter = calculateSearchFilter(that, that.option("searchPanel.text"));
                                return gridCore.combineFilters([filter, searchFilter])
                            },
                            searchByText: function(text) {
                                this.option("searchPanel.text", text)
                            },
                            optionChanged: function(args) {
                                var that = this;
                                switch (args.fullName) {
                                    case "searchPanel.text":
                                    case "searchPanel":
                                        that._applyFilter();
                                        args.handled = true;
                                        break;
                                    default:
                                        that.callBase(args)
                                }
                            }
                        }
                    }()
                },
                views: {
                    headerPanel: function() {
                        var getSearchPanelOptions = function(that) {
                            return that.option("searchPanel")
                        };
                        return {
                            _getToolbarItems: function() {
                                var items = this.callBase();
                                return this._prepareSearchItem(items)
                            },
                            _prepareSearchItem: function(items) {
                                var that = this,
                                    dataController = that.getController("data"),
                                    searchPanelOptions = getSearchPanelOptions(that);
                                if (searchPanelOptions && searchPanelOptions.visible) {
                                    var toolbarItem = {
                                        template: function(data, index, $container) {
                                            var $search = $("<div />").addClass(DATAGRID_SEARCH_PANEL_CLASS).appendTo($container);
                                            that.setAria("label", messageLocalization.format("dxDataGrid-ariaSearchInGrid"), $search);
                                            that.getController("editorFactory").createEditor($search, {
                                                width: searchPanelOptions.width,
                                                placeholder: searchPanelOptions.placeholder,
                                                parentType: "searchPanel",
                                                value: that.option("searchPanel.text"),
                                                updateValueTimeout: FILTERING_TIMEOUT,
                                                setValue: function(value) {
                                                    dataController.searchByText(value)
                                                }
                                            });
                                            that.resize()
                                        },
                                        name: "searchPanel",
                                        location: "after",
                                        locateInMenu: "never"
                                    };
                                    items.push(toolbarItem)
                                }
                                return items
                            },
                            focus: function() {
                                var $searchPanel = this.element().find("." + DATAGRID_SEARCH_PANEL_CLASS);
                                if ($searchPanel.length) {
                                    $searchPanel.dxTextBox("instance").focus()
                                }
                            },
                            isVisible: function() {
                                var searchPanelOptions = getSearchPanelOptions(this);
                                return this.callBase() || searchPanelOptions && searchPanelOptions.visible
                            },
                            optionChanged: function(args) {
                                if ("searchPanel" === args.name) {
                                    this._invalidateToolbarItems();
                                    if ("searchPanel.text" === args.fullName) {
                                        this.focus()
                                    }
                                    args.handled = true
                                } else {
                                    this.callBase(args)
                                }
                            }
                        }
                    }(),
                    rowsView: {
                        _highlightSearchText: function(cellElement, isEquals, column) {
                            var $parent, searchHTML, that = this,
                                searchText = that.option("searchPanel.text");
                            if (searchText && that.option("searchPanel.highlightSearchText")) {
                                var store = that._dataController.store(),
                                    isODataStore = store && store._url && store._version,
                                    normalizeString = isODataStore ? function(str) {
                                        return str
                                    } : function(str) {
                                        return str.toLowerCase()
                                    };
                                if (isEquals && column) {
                                    var value = parseValue(column, searchText);
                                    searchText = gridCore.formatValue(value, column);
                                    if (!searchText) {
                                        return
                                    }
                                }
                                searchHTML = $("<div>").text(searchText).html();
                                $parent = cellElement.parent();
                                if (!$parent.length) {
                                    $parent = $("<div>").append(cellElement)
                                }
                                $.each($parent.find(selectors.icontains + "('" + searchText + "')"), function(index, element) {
                                    $.each($(element).contents(), function(index, content) {
                                        if (3 !== content.nodeType) {
                                            return
                                        }
                                        var highlightSearchTextInTextNode = function($content, searchText) {
                                            var $searchTextSpan = $("<span />").addClass(DATAGRID_SEARCH_TEXT_CLASS),
                                                text = $content.text(),
                                                index = normalizeString(text).indexOf(normalizeString(searchText));
                                            if (index >= 0) {
                                                if ($content[0].textContent) {
                                                    $content[0].textContent = text.substr(0, index)
                                                } else {
                                                    $content[0].nodeValue = text.substr(0, index)
                                                }
                                                $content.after($searchTextSpan.text(text.substr(index, searchText.length)));
                                                $content = $(document.createTextNode(text.substr(index + searchText.length))).insertAfter($searchTextSpan);
                                                return highlightSearchTextInTextNode($content, searchText)
                                            }
                                        };
                                        if (isEquals) {
                                            if (normalizeString($(content).text()) === normalizeString(searchText)) {
                                                $(this).replaceWith($("<span />").addClass(DATAGRID_SEARCH_TEXT_CLASS).text($(content).text()))
                                            }
                                        } else {
                                            highlightSearchTextInTextNode($(content), searchText)
                                        }
                                    })
                                })
                            }
                        },
                        _renderCore: function($table, options) {
                            this.callBase.apply(this, arguments);
                            if (this.option("rowTemplate")) {
                                this._highlightSearchText(this._getTableElement())
                            }
                        },
                        _updateCell: function($cell, parameters) {
                            var that = this,
                                column = parameters.column,
                                isEquals = "string" !== column.dataType;
                            if (allowSearch(column)) {
                                that._highlightSearchText($cell, isEquals, column)
                            }
                            that.callBase($cell, parameters)
                        }
                    }
                }
            }
        })
    },
    /*!****************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.pager.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            Pager = __webpack_require__( /*! ./pager */ 375),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        var DATAGRID_PAGER_CLASS = "dx-datagrid-pager",
            MAX_PAGES_COUNT = 10;
        exports.PagerView = gridCore.View.inherit({
            init: function() {
                var that = this,
                    dataController = that.getController("data");
                that._isVisible = false;
                dataController.changed.add(function(e) {
                    if (!e || "update" !== e.changeType) {
                        that.render()
                    }
                })
            },
            _getPager: function() {
                var $element = this.element();
                return $element && $element.data("dxPager")
            },
            _renderCore: function() {
                var that = this,
                    $element = that.element().addClass(DATAGRID_PAGER_CLASS),
                    pagerOptions = that.option("pager") || {},
                    dataController = that.getController("data"),
                    options = {
                        maxPagesCount: MAX_PAGES_COUNT,
                        pageIndex: 1 + (parseInt(dataController.pageIndex()) || 0),
                        pageCount: dataController.pageCount(),
                        pageSize: dataController.pageSize(),
                        showPageSizes: pagerOptions.showPageSizeSelector,
                        showInfo: pagerOptions.showInfo,
                        pagesNavigatorVisible: pagerOptions.visible,
                        showNavigationButtons: pagerOptions.showNavigationButtons,
                        pageSizes: that.getPageSizes(),
                        totalCount: dataController.totalCount(),
                        hasKnownLastPage: dataController.hasKnownLastPage(),
                        pageIndexChanged: function(pageIndex) {
                            if (dataController.pageIndex() !== pageIndex - 1) {
                                setTimeout(function() {
                                    dataController.pageIndex(pageIndex - 1)
                                })
                            }
                        },
                        pageSizeChanged: function(pageSize) {
                            setTimeout(function() {
                                dataController.pageSize(pageSize)
                            })
                        }
                    };
                if (commonUtils.isDefined(pagerOptions.infoText)) {
                    options.infoText = pagerOptions.infoText
                }
                that._createComponent($element, Pager, options)
            },
            getPageSizes: function() {
                var that = this,
                    dataController = that.getController("data"),
                    pagerOptions = that.option("pager"),
                    allowedPageSizes = pagerOptions && pagerOptions.allowedPageSizes,
                    pageSize = dataController.pageSize();
                if (!commonUtils.isDefined(that._pageSizes) || $.inArray(pageSize, that._pageSizes) === -1) {
                    that._pageSizes = [];
                    if (pagerOptions) {
                        if ($.isArray(allowedPageSizes)) {
                            that._pageSizes = allowedPageSizes
                        } else {
                            if (allowedPageSizes && pageSize > 1) {
                                that._pageSizes = [Math.floor(pageSize / 2), pageSize, 2 * pageSize]
                            }
                        }
                    }
                }
                return that._pageSizes
            },
            isVisible: function() {
                var that = this,
                    dataController = that.getController("data"),
                    pagerOptions = that.option("pager"),
                    pagerVisible = pagerOptions && pagerOptions.visible,
                    scrolling = that.option("scrolling");
                if (that._isVisible) {
                    return true
                }
                if ("auto" === pagerVisible) {
                    if (scrolling && ("virtual" === scrolling.mode || "infinite" === scrolling.mode)) {
                        pagerVisible = false
                    } else {
                        pagerVisible = dataController.pageCount() > 1 || dataController.isLoaded() && !dataController.hasKnownLastPage()
                    }
                }
                that._isVisible = pagerVisible;
                return pagerVisible
            },
            getHeight: function() {
                var $element = this.element();
                return $element ? $element.outerHeight(true) : 0
            },
            optionChanged: function(args) {
                var that = this,
                    name = args.name,
                    isPager = "pager" === name,
                    isPaging = "paging" === name,
                    isDataSource = "dataSource" === name,
                    isScrolling = "scrolling" === name;
                if (isPager || isPaging || isScrolling || isDataSource) {
                    if (isPager || isPaging) {
                        that._pageSizes = null
                    }
                    if (isPager || isPaging || isScrolling) {
                        that._isVisible = false
                    }
                    if (!isDataSource) {
                        that._invalidate();
                        if (isPager && that.component) {
                            that.component.resize()
                        }
                    }
                    args.handled = true
                }
            }
        });
        gridCore.registerModule("pager", {
            defaultOptions: function() {
                return {
                    pager: {
                        visible: "auto",
                        showPageSizeSelector: false,
                        allowedPageSizes: "auto"
                    }
                }
            },
            views: {
                pagerView: exports.PagerView
            }
        })
    },
    /*!***************************************!*\
      !*** ./Scripts/ui/data_grid/pager.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            SelectBox = __webpack_require__( /*! ../select_box */ 307),
            NumberBox = __webpack_require__( /*! ../number_box */ 255),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62);
        var PAGES_LIMITER = 4,
            PAGER_CLASS = "dx-pager",
            PAGER_PAGE_CLASS = "dx-page",
            PAGER_PAGES_CLASS = "dx-pages",
            LIGHT_MODE_CLASS = "dx-light-mode",
            LIGHT_PAGES_CLASS = "dx-light-pages",
            PAGER_PAGE_INDEX_CLASS = "dx-page-index",
            PAGER_PAGES_COUNT_CLASS = "dx-pages-count",
            PAGER_SELECTION_CLASS = "dx-selection",
            PAGER_PAGE_SEPARATOR_CLASS = "dx-separator",
            PAGER_PAGE_SIZES_CLASS = "dx-page-sizes",
            PAGER_PAGE_SIZE_CLASS = "dx-page-size",
            PAGER_NAVIGATE_BUTTON = "dx-navigate-button",
            PAGER_PREV_BUTTON_CLASS = "dx-prev-button",
            PAGER_NEXT_BUTTON_CLASS = "dx-next-button",
            PAGER_INFO_CLASS = "dx-info",
            PAGER_INFO_TEXT_CLASS = "dx-info-text",
            PAGER_BUTTON_DISABLE_CLASS = "dx-button-disable";
        var Page = Class.inherit({
            ctor: function(value, index) {
                var that = this;
                that.index = index;
                that._$page = $("<div />").text(value).addClass(PAGER_PAGE_CLASS)
            },
            value: function(value) {
                var that = this;
                if (commonUtils.isDefined(value)) {
                    that._$page.text(value)
                } else {
                    var text = that._$page.text();
                    if (commonUtils.isNumber(text)) {
                        return parseInt(text)
                    } else {
                        return text
                    }
                }
            },
            element: function() {
                return this._$page
            },
            select: function(value) {
                this._$page.toggleClass(PAGER_SELECTION_CLASS, value)
            },
            render: function(rootElement, rtlEnabled) {
                rtlEnabled ? this._$page.prependTo(rootElement) : this._$page.appendTo(rootElement)
            }
        });
        var Pager = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    visible: true,
                    pagesNavigatorVisible: "auto",
                    pageIndex: 1,
                    maxPagesCount: 10,
                    pageCount: 10,
                    totalCount: 0,
                    pageSize: 5,
                    showPageSizes: true,
                    pageSizes: [5, 10],
                    hasKnownLastPage: true,
                    showNavigationButtons: false,
                    showInfo: false,
                    infoText: messageLocalization.getFormatter("dxPager-infoText"),
                    pagesCountText: messageLocalization.getFormatter("dxPager-pagesCountText"),
                    rtlEnabled: false,
                    lightModeEnabled: false,
                    pageIndexChanged: $.noop,
                    pageSizeChanged: $.noop
                })
            },
            _toggleVisibility: function(value) {
                var $element = this.element();
                if ($element) {
                    $element.css("display", value ? "" : "none")
                }
            },
            _getPages: function(currentPage, count) {
                var firstValue, i, pages = [],
                    showMoreButton = !this.option("hasKnownLastPage");
                this._testPagesCount = count;
                this._testShowMoreButton = showMoreButton;
                if (count > 0 || showMoreButton) {
                    if (count <= this.option("maxPagesCount")) {
                        for (i = 1; i <= count; i++) {
                            pages.push(new Page(i, i - 1))
                        }
                        if (showMoreButton) {
                            pages.push(new Page(">", i - 1))
                        }
                    } else {
                        pages.push(new Page(1, 0));
                        firstValue = currentPage ? currentPage.value() - currentPage.index : 1;
                        for (i = 1; i <= PAGES_LIMITER; i++) {
                            pages.push(new Page(firstValue + i, i))
                        }
                        pages.push(new Page(count, PAGES_LIMITER + 1));
                        if (showMoreButton) {
                            pages.push(new Page(">", PAGES_LIMITER + 1))
                        }
                    }
                }
                return pages
            },
            _getPageByValue: function(value) {
                var page, i, that = this;
                for (i = 0; i < that._pages.length; i++) {
                    page = that._pages[i];
                    if (page.value() === value) {
                        return page
                    }
                }
            },
            _processSelectedPage: function(maxPagesCount, pageIndex, pageCount) {
                var selectedPageIndex, that = this,
                    isPageIndexValid = false;
                if (that._pages) {
                    $.each(that._pages, function(key, page) {
                        if (pageIndex === page.value()) {
                            isPageIndexValid = true
                        }
                    });
                    if (!isPageIndexValid) {
                        that.selectedPage = null
                    }
                }
                if (commonUtils.isDefined(that.selectedPage)) {
                    if (pageIndex === pageCount && pageCount > maxPagesCount && that.selectedPage.index !== PAGES_LIMITER + 1) {
                        that.selectedPage.index = PAGES_LIMITER + 1
                    }
                } else {
                    if (pageIndex > PAGES_LIMITER && pageIndex < pageCount) {
                        selectedPageIndex = pageCount - PAGES_LIMITER < pageIndex ? PAGES_LIMITER - (pageCount - pageIndex) + 1 : 2;
                        that.selectedPage = new Page(pageIndex, selectedPageIndex)
                    }
                }
            },
            _selectPageByValue: function(value) {
                var i, prevPage, nextPage, morePage, that = this,
                    page = that._getPageByValue(value),
                    pages = that._pages,
                    pagesLength = pages.length;
                if (!commonUtils.isDefined(page)) {
                    return
                }
                prevPage = that._pages[page.index - 1];
                nextPage = that._pages[page.index + 1];
                if (nextPage && ">" === nextPage.value()) {
                    morePage = nextPage;
                    nextPage = void 0;
                    pagesLength--;
                    pages.pop()
                }
                if (that.selectedPage) {
                    that.selectedPage.select(false)
                }
                page.select(true);
                that.selectedPage = page;
                if (nextPage && nextPage.value() - value > 1) {
                    if (0 !== page.index) {
                        prevPage.value(value + 1);
                        that._pages.splice(page.index, 1);
                        that._pages.splice(page.index - 1, 0, page);
                        that._pages[page.index].index = page.index;
                        page.index = page.index - 1;
                        for (i = page.index - 1; i > 0; i--) {
                            that._pages[i].value(that._pages[i + 1].value() - 1)
                        }
                    } else {
                        for (i = 0; i < pagesLength - 1; i++) {
                            that._pages[i].value(i + 1)
                        }
                    }
                }
                if (prevPage && value - prevPage.value() > 1) {
                    if (page.index !== pagesLength - 1) {
                        nextPage.value(value - 1);
                        that._pages.splice(page.index, 1);
                        that._pages.splice(page.index + 1, 0, page);
                        that._pages[page.index].index = page.index;
                        page.index = page.index + 1;
                        for (i = page.index + 1; i < pagesLength - 1; i++) {
                            that._pages[i].value(that._pages[i - 1].value() + 1)
                        }
                    } else {
                        for (i = 1; i <= pagesLength - 2; i++) {
                            that._pages[pagesLength - 1 - i].value(that._pages[pagesLength - 1].value() - i)
                        }
                    }
                }
                if (morePage) {
                    pages.push(morePage)
                }
            },
            _nextPage: function(direction) {
                var pageIndex = this.option("pageIndex"),
                    pageCount = this.option("pageCount");
                if (commonUtils.isDefined(pageIndex)) {
                    pageIndex = "next" === direction ? ++pageIndex : --pageIndex;
                    if (pageIndex > 0 && pageIndex <= pageCount) {
                        this.option("pageIndex", pageIndex)
                    }
                }
            },
            _renderPages: function(pages) {
                var $separator, page, that = this,
                    pageslength = pages.length,
                    clickPagesIndexAction = that._createAction(function(args) {
                        var e = args.jQueryEvent,
                            pageNumber = $(e.target).text(),
                            pageIndex = ">" === pageNumber ? that.option("pageCount") + 1 : Number(pageNumber);
                        that._testPageIndex = pageIndex;
                        that.option("pageIndex", pageIndex)
                    });
                if (pageslength > 1) {
                    that._pageClickHandler = function(e) {
                        clickPagesIndexAction({
                            jQueryEvent: e
                        })
                    };
                    that._$pagesChooser.on(eventUtils.addNamespace(clickEvent.name, that.Name + "Pages"), "." + PAGER_PAGE_CLASS, that._pageClickHandler)
                }
                for (var i = 0; i < pageslength; i++) {
                    page = pages[i];
                    page.render(that._$pagesChooser, that.option("rtlEnabled"));
                    that.setAria({
                        role: "button",
                        label: "Page " + page.value()
                    }, page.element());
                    if (pages[i + 1] && pages[i + 1].value() - page.value() > 1) {
                        $separator = $("<div>. . .</div>").addClass(PAGER_PAGE_SEPARATOR_CLASS);
                        that.option("rtlEnabled") ? $separator.prependTo(that._$pagesChooser) : $separator.appendTo(that._$pagesChooser)
                    }
                }
            },
            _calculateLightPagesWidth: function($pageIndex, pageCount) {
                return Number($pageIndex.css("min-width").replace("px", "")) + 10 * pageCount.toString().length
            },
            _renderLightPages: function() {
                var $pageCount, $pageIndex, that = this,
                    pageCount = this.option("pageCount"),
                    pageIndex = this.option("pageIndex"),
                    clickAction = that._createAction(function() {
                        that.option("pageIndex", pageCount)
                    }),
                    pagesCountText = this.option("pagesCountText");
                var $container = $("<div/>").addClass(LIGHT_PAGES_CLASS).appendTo(this._$pagesChooser);
                $pageIndex = $("<div/>").addClass(PAGER_PAGE_INDEX_CLASS).appendTo($container);
                that._pageIndexEditor = that._createComponent($pageIndex, NumberBox, {
                    value: pageIndex,
                    min: 1,
                    max: pageCount,
                    width: that._calculateLightPagesWidth($pageIndex, pageCount),
                    onValueChanged: function(e) {
                        that.option("pageIndex", e.value)
                    }
                });
                $("<span/>").text(pagesCountText).addClass(PAGER_INFO_TEXT_CLASS + " " + PAGER_INFO_CLASS).appendTo($container);
                $pageCount = $("<span/>").addClass(PAGER_PAGES_COUNT_CLASS).text(pageCount).on(eventUtils.addNamespace(clickEvent.name, that.Name + "PagesCount"), function(e) {
                    clickAction({
                        jQueryEvent: e
                    })
                }).appendTo($container);
                that.setAria({
                    role: "button",
                    label: "Navigates to the last page"
                }, $pageCount)
            },
            _renderPagesChooser: function() {
                var that = this,
                    lightModeEnabled = that.option("lightModeEnabled"),
                    pagesNavigatorVisible = that.option("pagesNavigatorVisible"),
                    $element = that.element();
                that._$pagesChooser && that._$pagesChooser.remove();
                if (!pagesNavigatorVisible) {
                    return
                }
                if (that._pages && 0 === that._pages.length) {
                    that.selectedPage = null;
                    return
                }
                that._$pagesChooser = $("<div />").addClass(PAGER_PAGES_CLASS).appendTo($element);
                if ("auto" === pagesNavigatorVisible) {
                    that._$pagesChooser.css("visibility", 1 === that.option("pageCount") ? "hidden" : "")
                }
                if (!lightModeEnabled) {
                    that._renderInfo()
                }
                that._renderNavigateButton("prev");
                if (lightModeEnabled) {
                    that._renderLightPages()
                } else {
                    that._renderPages(that._pages)
                }
                that._renderNavigateButton("next");
                that._updatePagesChooserWidth()
            },
            _renderPageSizes: function() {
                var i, pageSizeValue, $pageSize, that = this,
                    pageSizes = that.option("pageSizes"),
                    pagesSizesLength = pageSizes && pageSizes.length,
                    currentPageSize = that.option("pageSize"),
                    clickPagesSizeAction = that._createAction(function(args) {
                        var e = args.jQueryEvent;
                        pageSizeValue = parseInt($(e.target).text());
                        that._testPageSizeIndex = pageSizeValue;
                        that.option("pageSize", pageSizeValue)
                    });
                that._testCurrentPageSize = currentPageSize;
                that._$pagesSizeChooser.on(eventUtils.addNamespace(clickEvent.name, that.Name + "PageSize"), "." + PAGER_PAGE_SIZE_CLASS, function(e) {
                    clickPagesSizeAction({
                        jQueryEvent: e
                    })
                });
                for (i = 0; i < pagesSizesLength; i++) {
                    $pageSize = $("<div />").text(pageSizes[i]).addClass(PAGER_PAGE_SIZE_CLASS);
                    that.setAria({
                        role: "button",
                        label: "Display " + pageSizes[i] + " items on page"
                    }, $pageSize);
                    if (currentPageSize === pageSizes[i]) {
                        $pageSize.addClass(PAGER_SELECTION_CLASS)
                    }
                    that._$pagesSizeChooser.append($pageSize)
                }
            },
            _calculateLightPageSizesWidth: function(pageSizes) {
                return Number(this._$pagesSizeChooser.css("min-width").replace("px", "")) + 10 * Math.max.apply(Math, pageSizes).toString().length
            },
            _renderLightPageSizes: function() {
                var $editor, that = this,
                    pageSizes = that.option("pageSizes");
                $editor = $("<div/>").appendTo(that._$pagesSizeChooser);
                that._pageSizeEditor = that._createComponent($editor, SelectBox, {
                    dataSource: pageSizes,
                    value: that.option("pageSize"),
                    onSelectionChanged: function(e) {
                        that._testPageSizeIndex = e.selectedItem;
                        that.option("pageSize", e.selectedItem)
                    },
                    width: that._calculateLightPageSizesWidth(pageSizes)
                })
            },
            _renderPagesSizeChooser: function() {
                var that = this,
                    pageSizes = that.option("pageSizes"),
                    showPageSizes = that.option("showPageSizes"),
                    pagesSizesLength = pageSizes && pageSizes.length,
                    $element = that.element();
                if (!showPageSizes || !pagesSizesLength) {
                    return
                }
                that._$pagesSizeChooser && that._$pagesSizeChooser.remove();
                that._$pagesSizeChooser = $("<div />").addClass(PAGER_PAGE_SIZES_CLASS).appendTo($element);
                if (that.option("lightModeEnabled")) {
                    that._renderLightPageSizes()
                } else {
                    that._renderPageSizes()
                }
                that._pagesSizeChooserWidth = that._$pagesSizeChooser.width()
            },
            _renderInfo: function() {
                var infoText = this.option("infoText");
                if (this.option("showInfo") && commonUtils.isDefined(infoText)) {
                    this._$info = $("<div>").css("display", this._isInfoHide ? "none" : "").addClass(PAGER_INFO_CLASS).text(stringUtils.format(infoText, this.selectedPage && this.selectedPage.value(), this.option("pageCount"), this.option("totalCount"))).appendTo(this._$pagesChooser);
                    if (!this._isInfoHide) {
                        this._infoWidth = this._$info.outerWidth(true)
                    }
                }
            },
            _renderNavigateButton: function(direction) {
                var $button, that = this,
                    clickAction = that._createAction(function(e) {
                        that._nextPage(direction)
                    });
                if (that.option("showNavigationButtons") || that.option("lightModeEnabled")) {
                    $button = $("<div>").addClass(PAGER_NAVIGATE_BUTTON).on(eventUtils.addNamespace(clickEvent.name, that.Name + "Pages"), function(e) {
                        clickAction({
                            jQueryEvent: e
                        })
                    });
                    that.setAria({
                        role: "button",
                        label: "prev" === direction ? "Previous page" : " Next page"
                    }, $button);
                    if (that.option("rtlEnabled")) {
                        $button.addClass("prev" === direction ? PAGER_NEXT_BUTTON_CLASS : PAGER_PREV_BUTTON_CLASS);
                        $button.prependTo(this._$pagesChooser)
                    } else {
                        $button.addClass("prev" === direction ? PAGER_PREV_BUTTON_CLASS : PAGER_NEXT_BUTTON_CLASS);
                        $button.appendTo(this._$pagesChooser)
                    }
                }
            },
            _render: function() {
                this.callBase();
                this.element().addClass(PAGER_CLASS).toggleClass(LIGHT_MODE_CLASS, this.option("lightModeEnabled"));
                this._toggleVisibility(this.option("visible"));
                this._updatePageSizes(true);
                this._updatePages(true);
                this._updateLightMode()
            },
            _updatePageSizes: function(forceRender) {
                var lightModeEnabled = this.option("lightModeEnabled"),
                    pageSize = this.option("pageSize"),
                    pageSizes = this.option("pageSizes");
                if (lightModeEnabled) {
                    this._pageSizeEditor && this._pageSizeEditor.option({
                        value: pageSize,
                        dataSource: pageSizes,
                        width: this._calculateLightPageSizesWidth(pageSizes)
                    })
                }
                if (!lightModeEnabled || forceRender) {
                    this._renderPagesSizeChooser()
                }
            },
            _updatePages: function(forceRender) {
                var pageCount = this.option("pageCount"),
                    pageIndex = this.option("pageIndex"),
                    lightModeEnabled = this.option("lightModeEnabled");
                if (!lightModeEnabled) {
                    this._processSelectedPage(this.option("maxPagesCount"), pageIndex, pageCount);
                    this._pages = this._getPages(this.selectedPage, pageCount);
                    this._selectPageByValue(pageIndex)
                } else {
                    this._pageIndexEditor && this._pageIndexEditor.option({
                        value: pageIndex,
                        width: this._calculateLightPagesWidth(this._pageIndexEditor.element(), pageCount)
                    })
                }
                if (!lightModeEnabled || forceRender) {
                    this._renderPagesChooser()
                }
                this._updateButtonsState(pageIndex)
            },
            _updateButtonsState: function(pageIndex) {
                var nextButton = this.element().find("." + PAGER_NEXT_BUTTON_CLASS),
                    prevButton = this.element().find("." + PAGER_PREV_BUTTON_CLASS);
                nextButton.toggleClass(PAGER_BUTTON_DISABLE_CLASS, pageIndex >= this.option("pageCount"));
                prevButton.toggleClass(PAGER_BUTTON_DISABLE_CLASS, pageIndex <= 1)
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "visible":
                        this._toggleVisibility(args.value);
                        break;
                    case "pageIndex":
                        var pageIndexChanged = this.option("pageIndexChanged");
                        if (pageIndexChanged) {
                            pageIndexChanged(args.value)
                        }
                        this._updatePages();
                        break;
                    case "maxPagesCount":
                    case "pageCount":
                    case "totalCount":
                    case "hasKnownLastPage":
                    case "pagesNavigatorVisible":
                    case "showNavigationButtons":
                        this._updatePages();
                        break;
                    case "pageSize":
                        var pageSizeChanged = this.option("pageSizeChanged");
                        if (pageSizeChanged) {
                            pageSizeChanged(args.value)
                        }
                        this._updatePageSizes();
                        break;
                    case "pageSizes":
                        this._updatePageSizes();
                        break;
                    default:
                        this._invalidate()
                }
            },
            _clean: function() {
                this._$pagesChooser && this._$pagesChooser.off(eventUtils.addNamespace(clickEvent.name, this.Name + "Pages"), "." + PAGER_PAGE_CLASS, this._pageClickHandler);
                this.callBase()
            },
            _getMinPagerWidth: function() {
                var pagesChooserWidth = commonUtils.isDefined(this._pagesChooserWidth) ? this._pagesChooserWidth : 0,
                    pagesSizeChooserWidth = commonUtils.isDefined(this._pagesSizeChooserWidth) ? this._pagesSizeChooserWidth : 0;
                return pagesChooserWidth + pagesSizeChooserWidth
            },
            _updatePagesChooserWidth: commonUtils.deferUpdater(function() {
                var lastPageWidth = this._pages && this._pages.length > 0 ? this._pages[this._pages.length - 1]._$page.width() : 0;
                this._pagesChooserWidth = this._$pagesChooser.width() + lastPageWidth
            }),
            _updateLightMode: commonUtils.deferUpdater(function() {
                var that = this,
                    width = this.element().width(),
                    infoWidth = commonUtils.isDefined(this._infoWidth) ? this._infoWidth : 0;
                commonUtils.deferRender(function() {
                    if (that._isInfoHide && width > that._getMinPagerWidth() + infoWidth) {
                        that._$info.show();
                        that._updatePagesChooserWidth();
                        that._isInfoHide = false
                    }
                    if (!that._isInfoHide && width > that._getMinPagerWidth() - infoWidth && width < that._getMinPagerWidth()) {
                        that._$info.hide();
                        that._updatePagesChooserWidth();
                        that._isInfoHide = true
                    }
                    commonUtils.deferUpdate(function() {
                        commonUtils.deferRender(function() {
                            if (width < that._getMinPagerWidth() && !that._isLightMode) {
                                that._optimalPagerWidth = that._getMinPagerWidth();
                                that._isLightMode = true;
                                that.option("lightModeEnabled", that._isLightMode)
                            }
                            if (width > that._optimalPagerWidth && that._isLightMode) {
                                that._isLightMode = false;
                                that.option("lightModeEnabled", that._isLightMode)
                            }
                        })
                    })
                })
            }),
            _dimensionChanged: function() {
                this._updateLightMode()
            },
            getHeight: function() {
                return this.option("visible") ? this.element().outerHeight() : 0
            }
        });
        module.exports = Pager;
        registerComponent("dxPager", Pager)
    },
    /*!*********************************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.columns_resizing_reordering_module.js ***!
      \*********************************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            dragEvents = __webpack_require__( /*! ../../events/drag */ 110),
            addNamespace = eventUtils.addNamespace,
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            fx = __webpack_require__( /*! ../../animation/fx */ 59);
        var DATAGRID_COLUMNS_SEPARATOR_CLASS = "dx-datagrid-columns-separator",
            DATAGRID_COLUMNS_SEPARATOR_TRANSPARENT = "dx-datagrid-columns-separator-transparent",
            DATAGRID_DRAGGING_HEADER_CLASS = "dx-datagrid-drag-header",
            DATAGRID_CELL_CONTENT_CLASS = "dx-datagrid-text-content",
            DATAGRID_HEADERS_DRAG_ACTION_CLASS = "dx-datagrid-drag-action",
            DATAGRID_TRACKER_CLASS = "dx-datagrid-tracker",
            DATAGRID_BLOCK_SEPARATOR_CLASS = "dx-block-separator",
            DATAGRID_HEADERS_DROP_HIGHLIGHT_CLASS = "dx-datagrid-drop-highlight",
            DATAGRID_HEADER_ROW_CLASS = "dx-header-row",
            WIDGET_CLASS = "dx-widget",
            DATAGRID_MODULE_NAMESPACE = "dxDataGridResizingReordering",
            COLUMNS_SEPARATOR_TOUCH_TRACKER_WIDTH = 10,
            DRAGGING_DELTA = 5;
        var allowResizing = function(that) {
            return that.option("allowColumnResizing") || that.getController("columns").isColumnOptionUsed("allowResizing")
        };
        var allowReordering = function(that) {
            return that.option("allowColumnReordering") || that.getController("columns").isColumnOptionUsed("allowReordering")
        };
        exports.TrackerView = gridCore.View.inherit({
            _renderCore: function() {
                this.callBase();
                this.element().addClass(DATAGRID_TRACKER_CLASS);
                this.hide()
            },
            _unsubscribeFromCallback: function() {
                if (this._positionChanged) {
                    this._tablePositionController.positionChanged.remove(this._positionChanged)
                }
            },
            _subscribeToCallback: function() {
                var that = this;
                that._positionChanged = function(position) {
                    var $element = that.element();
                    if ($element && $element.hasClass(DATAGRID_TRACKER_CLASS)) {
                        $element.css({
                            top: position.top
                        });
                        $element.height(position.height)
                    }
                };
                this._tablePositionController.positionChanged.add(that._positionChanged)
            },
            optionChanged: function(args) {
                if ("allowColumnResizing" === args.name) {
                    this._unsubscribeFromCallback();
                    if (args.value) {
                        this._subscribeToCallback();
                        this._invalidate()
                    }
                }
                this.callBase(args)
            },
            init: function() {
                this.callBase();
                this._tablePositionController = this.getController("tablePosition");
                this._subscribeToCallback()
            },
            isVisible: function() {
                return allowResizing(this)
            },
            show: function() {
                this.element().show()
            },
            hide: function() {
                this.element().hide()
            },
            setHeight: function(value) {
                this.element().height(value)
            },
            dispose: function() {
                this._unsubscribeFromCallback();
                this.callBase()
            }
        });
        exports.SeparatorView = gridCore.View.inherit({
            _renderSeparator: function() {},
            _renderCore: function(options) {
                this.callBase(options);
                this._isShown = true;
                this._renderSeparator();
                this.hide()
            },
            show: function() {
                this._isShown = true
            },
            hide: function() {
                this._isShown = false
            },
            height: function(value) {
                var $element = this.element();
                if ($element) {
                    if (commonUtils.isDefined(value)) {
                        $element.height(value)
                    } else {
                        return $element.height()
                    }
                }
            },
            width: function(value) {
                var $element = this.element();
                if ($element) {
                    if (commonUtils.isDefined(value)) {
                        $element.width(value)
                    } else {
                        return $element.width()
                    }
                }
            }
        });
        exports.ColumnsSeparatorView = exports.SeparatorView.inherit({
            _renderSeparator: function() {
                this.callBase();
                var $element = this.element();
                $element.addClass(DATAGRID_COLUMNS_SEPARATOR_CLASS)
            },
            _subscribeToCallback: function() {
                var $element, that = this;
                that._positionChanged = function(position) {
                    $element = that.element();
                    if ($element) {
                        $element.css({
                            top: position.top
                        });
                        $element.height(position.height)
                    }
                };
                that._tablePositionController.positionChanged.add(that._positionChanged)
            },
            _unsubscribeFromCallback: function() {
                this._positionChanged && this._tablePositionController.positionChanged.remove(this._positionChanged)
            },
            _init: function() {
                this._isTransparent = allowResizing(this);
                if (this.isVisible()) {
                    this._subscribeToCallback()
                }
            },
            isVisible: function() {
                return this.option("showColumnHeaders") && (allowReordering(this) || allowResizing(this))
            },
            optionChanged: function(args) {
                if ("allowColumnResizing" === args.name) {
                    if (args.value) {
                        this._init();
                        this._invalidate();
                        this.hide(true)
                    } else {
                        this._unsubscribeFromCallback();
                        this._isTransparent = allowResizing(this);
                        this.hide(true)
                    }
                }
                this.callBase(args)
            },
            init: function() {
                this.callBase();
                this._tablePositionController = this.getController("tablePosition");
                this._init()
            },
            show: function() {
                var that = this,
                    $element = this.element();
                if ($element && !that._isShown) {
                    if (that._isTransparent) {
                        $element.removeClass(DATAGRID_COLUMNS_SEPARATOR_TRANSPARENT)
                    } else {
                        $element.show()
                    }
                }
                this.callBase()
            },
            hide: function(force) {
                var $element = this.element();
                if ($element && (this._isShown || force)) {
                    if (this._isTransparent) {
                        $element.addClass(DATAGRID_COLUMNS_SEPARATOR_TRANSPARENT);
                        if ("none" === $element.css("display")) {
                            $element.show()
                        }
                    } else {
                        if ($element.hasClass(DATAGRID_COLUMNS_SEPARATOR_TRANSPARENT)) {
                            $element.removeClass(DATAGRID_COLUMNS_SEPARATOR_TRANSPARENT)
                        }
                        $element.hide()
                    }
                }
                this.callBase()
            },
            moveByX: function(outerX) {
                var $element = this.element();
                if ($element) {
                    $element.css("left", outerX - this._parentElement().offset().left);
                    this._testPosx = outerX
                }
            },
            changeCursor: function(cursorName) {
                cursorName = commonUtils.isDefined(cursorName) ? cursorName : "";
                var $element = this.element();
                if ($element) {
                    $element.css("cursor", cursorName);
                    this._testCursorName = cursorName
                }
            },
            dispose: function() {
                this._unsubscribeFromCallback();
                this.callBase()
            }
        });
        exports.BlockSeparatorView = exports.SeparatorView.inherit({
            init: function() {
                var that = this;
                this.callBase();
                this.getController("data").loadingChanged.add(function(isLoading, messageText) {
                    var element = that.element();
                    if (!isLoading && element && "none" !== element.css("display")) {
                        that.hide()
                    }
                })
            },
            _renderSeparator: function() {
                this.callBase();
                this.element().addClass(DATAGRID_BLOCK_SEPARATOR_CLASS).html("&nbsp;")
            },
            hide: function() {
                var that = this,
                    $parent = this._parentElement(),
                    $element = this.element();
                if ($element && this._isShown) {
                    $element.hide()
                }
                if ($parent && !$parent.children("." + DATAGRID_BLOCK_SEPARATOR_CLASS).length) {
                    $parent.prepend(that.element())
                }
                that.callBase()
            },
            isVisible: function() {
                var groupPanelOptions = this.option("groupPanel"),
                    columnChooserOptions = this.option("columnChooser");
                return groupPanelOptions && groupPanelOptions.visible || columnChooserOptions && columnChooserOptions.enabled
            },
            show: function(targetLocation) {
                var that = this,
                    $element = this.element(),
                    startAnimate = function(toOptions) {
                        fx.stop($element, true);
                        fx.animate($element, {
                            type: "slide",
                            from: {
                                width: 0,
                                display: toOptions.display
                            },
                            to: toOptions,
                            duration: 300,
                            easing: "swing"
                        })
                    };
                if ($element && !that._isShown) {
                    switch (targetLocation) {
                        case "group":
                            startAnimate({
                                width: "50px",
                                display: "inline-block"
                            });
                            break;
                        case "columnChooser":
                            startAnimate({
                                width: "100%",
                                display: "block"
                            });
                            break;
                        default:
                            $element.show()
                    }
                }
                that.callBase()
            }
        });
        exports.DraggingHeaderView = gridCore.View.inherit({
            _isDragging: false,
            _getDraggingPanelByPos: function(pos) {
                var result, that = this;
                $.each(that._dragOptions.draggingPanels, function(index, draggingPanel) {
                    if (draggingPanel) {
                        var boundingRect = draggingPanel.getBoundingRect();
                        if (boundingRect && (void 0 === boundingRect.bottom || pos.y < boundingRect.bottom) && (void 0 === boundingRect.top || pos.y > boundingRect.top) && (void 0 === boundingRect.left || pos.x > boundingRect.left) && (void 0 === boundingRect.right || pos.x < boundingRect.right)) {
                            result = draggingPanel;
                            return false
                        }
                    }
                });
                return result
            },
            _renderCore: function() {
                this.element().addClass(DATAGRID_DRAGGING_HEADER_CLASS + " " + DATAGRID_CELL_CONTENT_CLASS + " " + WIDGET_CLASS).css("display", "none")
            },
            _resetTargetColumnOptions: function() {
                var params = this._dropOptions;
                params.targetColumnIndex = -1;
                delete params.targetColumnElement;
                delete params.isLast;
                delete params.posX;
                delete params.posY
            },
            _getVisibleIndexObject: function(rowIndex, visibleIndex) {
                if (commonUtils.isDefined(rowIndex)) {
                    return {
                        columnIndex: visibleIndex,
                        rowIndex: rowIndex
                    }
                }
                return visibleIndex
            },
            dispose: function() {
                var element = this.element();
                this._dragOptions = null;
                element && element.parent().find("." + DATAGRID_DRAGGING_HEADER_CLASS).remove()
            },
            isVisible: function() {
                var columnsController = this.getController("columns"),
                    commonColumnSettings = columnsController.getCommonSettings();
                return this.option("showColumnHeaders") && (allowReordering(this) || commonColumnSettings.allowGrouping || commonColumnSettings.allowHiding)
            },
            init: function() {
                var that = this;
                this.callBase();
                this._controller = this.getController("draggingHeader");
                this._columnsResizerViewController = this.getController("columnsResizer");
                this.getController("data").loadingChanged.add(function(isLoading, messageText) {
                    var element = that.element();
                    if (!isLoading && element && "none" !== element.css("display")) {
                        element.hide()
                    }
                })
            },
            dragHeader: function(options) {
                var that = this,
                    columnElement = options.columnElement;
                that._isDragging = true;
                that._dragOptions = options;
                that._dropOptions = {
                    sourceIndex: options.index,
                    sourceColumnIndex: that._getVisibleIndexObject(options.rowIndex, options.columnIndex),
                    sourceColumnElement: options.columnElement,
                    sourceLocation: options.sourceLocation
                };
                that._onSelectStart = document.onselectstart;
                document.onselectstart = function() {
                    return false
                };
                that.element().css({
                    textAlign: columnElement && columnElement.css("text-align"),
                    height: columnElement && columnElement.height(),
                    width: columnElement && columnElement.width(),
                    whiteSpace: columnElement && columnElement.css("white-space")
                }).addClass(DATAGRID_HEADERS_DRAG_ACTION_CLASS).text(options.sourceColumn.caption);
                that.element().appendTo($(document.body))
            },
            moveHeader: function(args) {
                var newLeft, newTop, moveDeltaX, moveDeltaY, e = args.jQueryEvent,
                    that = e.data.that,
                    eventData = eventUtils.eventData(e),
                    isResizing = that._columnsResizerViewController ? that._columnsResizerViewController.isResizing() : false,
                    dragOptions = that._dragOptions;
                if (that._isDragging && !isResizing) {
                    moveDeltaX = Math.abs(eventData.x - dragOptions.columnElement.offset().left - dragOptions.deltaX);
                    moveDeltaY = Math.abs(eventData.y - dragOptions.columnElement.offset().top - dragOptions.deltaY);
                    if (that.element().is(":visible") || moveDeltaX > DRAGGING_DELTA || moveDeltaY > DRAGGING_DELTA) {
                        that.element().show();
                        newLeft = eventData.x - dragOptions.deltaX;
                        newTop = eventData.y - dragOptions.deltaY;
                        that.element().offset({
                            left: newLeft,
                            top: newTop
                        });
                        that.dockHeader(eventData)
                    }
                    e.preventDefault()
                }
            },
            dockHeader: function(eventData) {
                var i, centerPosition, that = this,
                    targetDraggingPanel = that._getDraggingPanelByPos(eventData),
                    controller = that._controller,
                    params = that._dropOptions;
                if (targetDraggingPanel) {
                    var rtlEnabled = that.option("rtlEnabled"),
                        isVerticalOrientation = "columnChooser" === targetDraggingPanel.getName(),
                        axisName = isVerticalOrientation ? "y" : "x",
                        targetLocation = targetDraggingPanel.getName(),
                        rowIndex = "headers" === targetLocation ? that._dragOptions.rowIndex : void 0,
                        sourceColumn = that._dragOptions.sourceColumn,
                        columnElements = targetDraggingPanel.getColumnElements(rowIndex, sourceColumn && sourceColumn.ownerBand) || [],
                        pointsByColumns = controller._generatePointsByColumns($.extend({}, that._dragOptions, {
                            targetDraggingPanel: targetDraggingPanel,
                            columns: targetDraggingPanel.getColumns(rowIndex),
                            columnElements: columnElements,
                            isVerticalOrientation: isVerticalOrientation,
                            startColumnIndex: "headers" === targetLocation && $(columnElements[0]).index()
                        }));
                    this._testPointsByColumns = pointsByColumns;
                    params.targetLocation = targetLocation;
                    if (pointsByColumns.length > 0) {
                        for (i = 0; i < pointsByColumns.length; i++) {
                            centerPosition = pointsByColumns[i + 1] && (pointsByColumns[i][axisName] + pointsByColumns[i + 1][axisName]) / 2;
                            if (void 0 === centerPosition || (rtlEnabled && "x" === axisName ? eventData[axisName] > centerPosition : eventData[axisName] < centerPosition)) {
                                params.targetColumnIndex = that._getVisibleIndexObject(rowIndex, pointsByColumns[i].columnIndex);
                                if (columnElements[i]) {
                                    params.targetColumnElement = columnElements.eq(i);
                                    params.isLast = false
                                } else {
                                    params.targetColumnElement = columnElements.last();
                                    params.isLast = true
                                }
                                params.posX = pointsByColumns[i].x;
                                params.posY = pointsByColumns[i].y;
                                controller.dock(params);
                                break
                            }
                        }
                    } else {
                        that._resetTargetColumnOptions();
                        controller.dock(params)
                    }
                }
            },
            dropHeader: function(args) {
                var e = args.jQueryEvent,
                    that = e.data.that,
                    controller = that._controller;
                that.element().hide();
                if (controller && that._isDragging) {
                    controller.drop(that._dropOptions)
                }
                that.element().appendTo(that._parentElement());
                that._dragOptions = null;
                that._dropOptions = null;
                that._isDragging = false;
                document.onselectstart = that._onSelectStart || null
            }
        });
        exports.ColumnsResizerViewController = gridCore.ViewController.inherit({
            _isHeadersRowArea: function(posY) {
                if (this._columnHeadersView) {
                    var headersRowHeight, offsetTop, element = this._columnHeadersView.element();
                    if (element) {
                        offsetTop = element.offset().top;
                        headersRowHeight = this._columnHeadersView.getHeadersRowHeight();
                        return posY >= offsetTop && posY <= offsetTop + headersRowHeight
                    }
                }
                return false
            },
            _pointCreated: function(point, cellsLength, columns) {
                var currentColumn, nextColumn;
                if (point.index > 0 && point.index < cellsLength) {
                    point.columnIndex -= 1;
                    currentColumn = columns[point.columnIndex] || {};
                    nextColumn = columns[point.columnIndex + 1] || {};
                    return !(currentColumn.allowResizing && nextColumn.allowResizing)
                }
                return true
            },
            _getTargetPoint: function(pointsByColumns, currentX, deltaX) {
                if (pointsByColumns) {
                    for (var i = 0; i < pointsByColumns.length; i++) {
                        if (pointsByColumns[i].x - deltaX <= currentX && currentX <= pointsByColumns[i].x + deltaX) {
                            return pointsByColumns[i]
                        }
                    }
                }
                return null
            },
            _moveSeparator: function(args) {
                var e = args.jQueryEvent,
                    that = e.data,
                    columnsSeparatorWidth = that._columnsSeparatorView.width(),
                    columnsSeparatorOffset = that._columnsSeparatorView.element().offset(),
                    deltaX = columnsSeparatorWidth / 2,
                    parentOffset = that._$parentContainer.offset(),
                    parentOffsetLeft = parentOffset.left,
                    eventData = eventUtils.eventData(e);
                if (that._isResizing) {
                    if (parentOffsetLeft <= eventData.x && eventData.x <= parentOffsetLeft + that._$parentContainer.width()) {
                        if (that._updateColumnsWidthIfNeeded(eventData.x)) {
                            that._columnsSeparatorView.moveByX(that._targetPoint.x + (eventData.x - that._resizingInfo.startPosX));
                            that._tablePositionController.update(that._targetPoint.y);
                            e.preventDefault()
                        }
                    }
                } else {
                    if (that._isHeadersRowArea(eventData.y)) {
                        if (that._previousParentOffset) {
                            if (that._previousParentOffset.left !== parentOffset.left || that._previousParentOffset.top !== parentOffset.top) {
                                that.pointsByColumns(null)
                            }
                        }
                        that._targetPoint = that._getTargetPoint(that.pointsByColumns(), eventData.x, columnsSeparatorWidth);
                        that._previousParentOffset = parentOffset;
                        that._isReadyResizing = false;
                        if (that._targetPoint && that._targetPoint.y <= eventData.y && columnsSeparatorOffset.top + that._columnsSeparatorView.height() >= eventData.y) {
                            that._columnsSeparatorView.changeCursor("col-resize");
                            that._columnsSeparatorView.moveByX(that._targetPoint.x - deltaX);
                            that._tablePositionController.update(that._targetPoint.y);
                            that._isReadyResizing = true;
                            e.preventDefault()
                        } else {
                            that._columnsSeparatorView.changeCursor()
                        }
                    } else {
                        that.pointsByColumns(null);
                        that._isReadyResizing = false;
                        that._columnsSeparatorView.changeCursor()
                    }
                }
            },
            _endResizing: function(args) {
                var e = args.jQueryEvent,
                    that = e.data;
                if (that._isResizing) {
                    that.pointsByColumns(null);
                    that._resizingInfo = null;
                    that._columnsSeparatorView.hide();
                    that._columnsSeparatorView.changeCursor();
                    that._trackerView.hide();
                    that._isReadyResizing = false;
                    that._isResizing = false
                }
            },
            _getNextColumnIndex: function(currentColumnIndex) {
                return currentColumnIndex + 1
            },
            _setupResizingInfo: function(posX) {
                var that = this,
                    currentColumnIndex = that._targetPoint.columnIndex,
                    nextColumnIndex = that._getNextColumnIndex(currentColumnIndex),
                    currentHeader = that._columnHeadersView.getHeaderElement(currentColumnIndex),
                    nextHeader = that._columnHeadersView.getHeaderElement(nextColumnIndex);
                that._resizingInfo = {
                    startPosX: posX,
                    currentColumnIndex: currentColumnIndex,
                    currentColumnWidth: currentHeader && currentHeader.length > 0 ? currentHeader.outerWidth() : 0,
                    nextColumnIndex: nextColumnIndex,
                    nextColumnWidth: nextHeader && nextHeader.length > 0 ? nextHeader.outerWidth() : 0
                }
            },
            _startResizing: function(args) {
                var e = args.jQueryEvent,
                    that = e.data,
                    eventData = eventUtils.eventData(e);
                if (eventUtils.isTouchEvent(e)) {
                    if (that._isHeadersRowArea(eventData.y)) {
                        that._targetPoint = that._getTargetPoint(that.pointsByColumns(), eventData.x, COLUMNS_SEPARATOR_TOUCH_TRACKER_WIDTH);
                        if (that._targetPoint) {
                            that._columnsSeparatorView.moveByX(that._targetPoint.x - that._columnsSeparatorView.width() / 2);
                            that._isReadyResizing = true
                        }
                    } else {
                        that._isReadyResizing = false
                    }
                }
                if (that._isReadyResizing) {
                    if (that._targetPoint) {
                        that._testColumnIndex = that._targetPoint.columnIndex
                    }
                    that._setupResizingInfo(eventData.x);
                    that._tablePositionController.update(that._targetPoint.y);
                    that._columnsSeparatorView.show();
                    that._trackerView.show();
                    that._isResizing = true;
                    e.preventDefault();
                    e.stopPropagation()
                }
            },
            _generatePointsByColumns: function() {
                var that = this,
                    columns = that._columnsController ? that._columnsController.getVisibleColumns() : [],
                    cells = that._columnHeadersView.getColumnElements(),
                    pointsByColumns = [];
                if (cells && cells.length > 0) {
                    pointsByColumns = gridCore.getPointsByColumns(cells, function(point) {
                        return that._pointCreated(point, cells.length, columns)
                    })
                }
                that._pointsByColumns = pointsByColumns
            },
            _unsubscribeFromEvents: function() {
                this._moveSeparatorHandler && this._$parentContainer.off(addNamespace(pointerEvents.move, DATAGRID_MODULE_NAMESPACE), this._moveSeparatorHandler);
                this._startResizingHandler && this._$parentContainer.off(addNamespace(pointerEvents.down, DATAGRID_MODULE_NAMESPACE), this._startResizingHandler);
                if (this._endResizingHandler) {
                    this._columnsSeparatorView.element().off(addNamespace(pointerEvents.up, DATAGRID_MODULE_NAMESPACE), this._endResizingHandler);
                    $(document).off(addNamespace(pointerEvents.up, DATAGRID_MODULE_NAMESPACE), this._endResizingHandler)
                }
            },
            _subscribeToEvents: function() {
                this._moveSeparatorHandler = this.createAction(this._moveSeparator);
                this._startResizingHandler = this.createAction(this._startResizing);
                this._endResizingHandler = this.createAction(this._endResizing);
                this._$parentContainer.on(addNamespace(pointerEvents.move, DATAGRID_MODULE_NAMESPACE), this, this._moveSeparatorHandler);
                this._$parentContainer.on(addNamespace(pointerEvents.down, DATAGRID_MODULE_NAMESPACE), this, this._startResizingHandler);
                this._columnsSeparatorView.element().on(addNamespace(pointerEvents.up, DATAGRID_MODULE_NAMESPACE), this, this._endResizingHandler);
                $(document).on(addNamespace(pointerEvents.up, DATAGRID_MODULE_NAMESPACE), this, this._endResizingHandler)
            },
            _updateColumnsWidthIfNeeded: function(posX) {
                var deltaX, nextCellWidth, column, nextColumn, cellWidth, isUpdated = false,
                    columnsController = this._columnsController,
                    visibleColumns = columnsController.getVisibleColumns(),
                    columnsSeparatorWidth = this._columnsSeparatorView.width(),
                    contentWidth = this._rowsView.contentWidth(),
                    adaptColumnWidthByRatio = this.option("adaptColumnWidthByRatio") && !this.option("columnAutoWidth");

                function setColumnWidth(column, columnWidth, contentWidth, adaptColumnWidthByRatio) {
                    if (column) {
                        var oldColumnWidth = column.width;
                        if (oldColumnWidth) {
                            adaptColumnWidthByRatio = commonUtils.isString(oldColumnWidth) && "%" === oldColumnWidth.slice(-1)
                        }
                        if (adaptColumnWidthByRatio) {
                            column && columnsController.columnOption(column.index, "visibleWidth", columnWidth);
                            column && columnsController.columnOption(column.index, "width", (columnWidth / contentWidth * 100).toFixed(3) + "%")
                        } else {
                            column && columnsController.columnOption(column.index, "visibleWidth", void 0);
                            column && columnsController.columnOption(column.index, "width", columnWidth)
                        }
                    }
                }
                deltaX = posX - this._resizingInfo.startPosX;
                if (this.option("rtlEnabled")) {
                    deltaX = -deltaX
                }
                cellWidth = this._resizingInfo.currentColumnWidth + deltaX;
                nextCellWidth = this._resizingInfo.nextColumnWidth - deltaX;
                isUpdated = !(cellWidth <= columnsSeparatorWidth || nextCellWidth <= columnsSeparatorWidth);
                if (isUpdated) {
                    column = visibleColumns[this._resizingInfo.currentColumnIndex];
                    nextColumn = visibleColumns[this._resizingInfo.nextColumnIndex];
                    columnsController.beginUpdate();
                    cellWidth = Math.floor(cellWidth);
                    nextCellWidth = Math.floor(nextCellWidth);
                    setColumnWidth(column, cellWidth, contentWidth, adaptColumnWidthByRatio);
                    setColumnWidth(nextColumn, nextCellWidth, contentWidth, adaptColumnWidthByRatio);
                    columnsController.endUpdate()
                }
                return isUpdated
            },
            _subscribeToCallback: function(callback, handler) {
                callback.add(handler);
                this._subscribesToCallbacks.push({
                    callback: callback,
                    handler: handler
                })
            },
            _unsubscribeFromCallbacks: function() {
                var i, subscribe;
                for (i = 0; i < this._subscribesToCallbacks.length; i++) {
                    subscribe = this._subscribesToCallbacks[i];
                    subscribe.callback.remove(subscribe.handler)
                }
                this._subscribesToCallbacks = []
            },
            _unsubscribes: function() {
                this._unsubscribeFromEvents();
                this._unsubscribeFromCallbacks()
            },
            _init: function() {
                var gridView, previousScrollbarVisibility, that = this,
                    generatePointsByColumnsHandler = function() {
                        if (!that._isResizing) {
                            that.pointsByColumns(null)
                        }
                    },
                    generatePointsByColumnsScrollHandler = function(offset) {
                        if (that._scrollLeft !== offset.left) {
                            that._scrollLeft = offset.left;
                            that.pointsByColumns(null)
                        }
                    };
                that._columnsSeparatorView = that.getView("columnsSeparatorView");
                that._columnHeadersView = that.getView("columnHeadersView");
                that._trackerView = that.getView("trackerView");
                that._rowsView = that.getView("rowsView");
                that._columnsController = that.getController("columns");
                that._tablePositionController = that.getController("tablePosition");
                that._$parentContainer = that._columnsSeparatorView.component.element();
                that._subscribeToCallback(that._columnHeadersView.renderCompleted, generatePointsByColumnsHandler);
                that._subscribeToCallback(that._columnHeadersView.resizeCompleted, generatePointsByColumnsHandler);
                that._subscribeToCallback(that._columnsSeparatorView.renderCompleted, function() {
                    that._unsubscribeFromEvents();
                    that._subscribeToEvents()
                });
                that._subscribeToCallback(that._rowsView.renderCompleted, function() {
                    that._rowsView.scrollChanged.remove(generatePointsByColumnsScrollHandler);
                    that._rowsView.scrollChanged.add(generatePointsByColumnsScrollHandler)
                });
                gridView = that.getView("gridView");
                previousScrollbarVisibility = 0 !== that._rowsView.getScrollbarWidth();
                that._subscribeToCallback(that.getController("tablePosition").positionChanged, function() {
                    if (that._isResizing && !that._rowsView.isResizing) {
                        var scrollbarVisibility = 0 !== that._rowsView.getScrollbarWidth();
                        if (previousScrollbarVisibility !== scrollbarVisibility) {
                            previousScrollbarVisibility = scrollbarVisibility;
                            gridView.resize()
                        } else {
                            that._rowsView.updateFreeSpaceRowHeight()
                        }
                    }
                })
            },
            optionChanged: function(args) {
                this.callBase(args);
                if ("allowColumnResizing" === args.name) {
                    if (args.value) {
                        this._init();
                        this._subscribeToEvents()
                    } else {
                        this._unsubscribes()
                    }
                }
            },
            isResizing: function() {
                return this._isResizing
            },
            init: function() {
                this._subscribesToCallbacks = [];
                if (allowResizing(this)) {
                    this._init()
                }
            },
            pointsByColumns: function(value) {
                if (void 0 !== value) {
                    this._pointsByColumns = value
                } else {
                    if (!this._pointsByColumns) {
                        this._generatePointsByColumns()
                    }
                    return this._pointsByColumns
                }
            },
            dispose: function() {
                this._unsubscribes();
                this.callBase()
            }
        });
        exports.TablePositionViewController = gridCore.ViewController.inherit({
            update: function(top) {
                var that = this,
                    $element = that._columnHeadersView.element(),
                    offset = $element && $element.offset(),
                    offsetTop = offset && offset.top || 0,
                    diffOffsetTop = commonUtils.isDefined(top) ? Math.abs(top - offsetTop) : 0,
                    columnsHeadersHeight = that._columnHeadersView ? that._columnHeadersView.getHeight() : 0,
                    rowsHeight = that._rowsView ? that._rowsView.height() - that._rowsView.getScrollbarWidth(true) : 0;
                that.positionChanged.fire({
                    height: columnsHeadersHeight + rowsHeight - diffOffsetTop,
                    top: $element && $element.length && $element[0].offsetTop + diffOffsetTop
                })
            },
            init: function() {
                var that = this;
                that.callBase();
                that._columnHeadersView = this.getView("columnHeadersView");
                that._rowsView = this.getView("rowsView");
                that._pagerView = this.getView("pagerView");
                that._rowsView.resizeCompleted.add(function() {
                    that.update()
                })
            },
            ctor: function(component) {
                this.callBase(component);
                this.positionChanged = $.Callbacks()
            }
        });
        exports.DraggingHeaderViewController = gridCore.ViewController.inherit({
            _generatePointsByColumns: function(options) {
                var that = this;
                return gridCore.getPointsByColumns(options.columnElements, function(point) {
                    return that._pointCreated(point, options.columns, options.targetDraggingPanel.getName(), options.sourceColumn)
                }, options.isVerticalOrientation, options.startColumnIndex)
            },
            _pointCreated: function(point, columns, location, sourceColumn) {
                var targetColumn = columns[point.columnIndex],
                    prevColumn = columns[point.columnIndex - 1];
                switch (location) {
                    case "columnChooser":
                        return true;
                    case "headers":
                        return sourceColumn && !sourceColumn.allowReordering || (!targetColumn || !targetColumn.allowReordering) && (!prevColumn || !prevColumn.allowReordering);
                    default:
                        return 0 === columns.length
                }
            },
            _subscribeToEvents: function(draggingHeader, draggingPanels) {
                var that = this;
                $.each(draggingPanels, function(_, draggingPanel) {
                    if (draggingPanel) {
                        var i, columns, columnElements, rowCount = draggingPanel.getRowCount ? draggingPanel.getRowCount() : 1,
                            nameDraggingPanel = draggingPanel.getName(),
                            subscribeToEvents = function(index, columnElement) {
                                var $columnElement = $(columnElement),
                                    column = columns[index];
                                if (draggingPanel.allowDragging(columns[index], nameDraggingPanel, draggingPanels)) {
                                    $columnElement.addClass(DATAGRID_HEADERS_DRAG_ACTION_CLASS);
                                    $columnElement.on(addNamespace(dragEvents.start, DATAGRID_MODULE_NAMESPACE), that.createAction(function(args) {
                                        var e = args.jQueryEvent,
                                            eventData = eventUtils.eventData(e);
                                        draggingHeader.dragHeader({
                                            deltaX: eventData.x - $(e.currentTarget).offset().left,
                                            deltaY: eventData.y - $(e.currentTarget).offset().top,
                                            sourceColumn: column,
                                            index: column.index,
                                            columnIndex: index,
                                            columnElement: $columnElement,
                                            sourceLocation: nameDraggingPanel,
                                            draggingPanels: draggingPanels,
                                            rowIndex: that._columnsController.getRowIndex(column.index, true)
                                        })
                                    }));
                                    $columnElement.on(addNamespace(dragEvents.move, DATAGRID_MODULE_NAMESPACE), {
                                        that: draggingHeader
                                    }, that.createAction(draggingHeader.moveHeader));
                                    $columnElement.on(addNamespace(dragEvents.end, DATAGRID_MODULE_NAMESPACE), {
                                        that: draggingHeader
                                    }, that.createAction(draggingHeader.dropHeader))
                                }
                            };
                        for (i = 0; i < rowCount; i++) {
                            columnElements = draggingPanel.getColumnElements(i) || [];
                            columns = draggingPanel.getColumns(i) || [];
                            $.each(columnElements, subscribeToEvents)
                        }
                    }
                })
            },
            _unsubscribeFromEvents: function(draggingHeader, draggingPanels) {
                $.each(draggingPanels, function(_, draggingPanel) {
                    if (draggingPanel) {
                        var columnElements = draggingPanel.getColumnElements() || [];
                        $.each(columnElements, function(index, columnElement) {
                            var $columnElement = $(columnElement);
                            $columnElement.off(addNamespace(dragEvents.start, DATAGRID_MODULE_NAMESPACE));
                            $columnElement.off(addNamespace(dragEvents.move, DATAGRID_MODULE_NAMESPACE));
                            $columnElement.off(addNamespace(dragEvents.end, DATAGRID_MODULE_NAMESPACE));
                            $columnElement.removeClass(DATAGRID_HEADERS_DRAG_ACTION_CLASS)
                        })
                    }
                })
            },
            _getSeparator: function(targetLocation) {
                return "headers" === targetLocation ? this._columnsSeparatorView : this._blockSeparatorView
            },
            hideSeparators: function() {
                var blockSeparator = this._blockSeparatorView,
                    columnsSeparator = this._columnsSeparatorView;
                this._animationColumnIndex = null;
                blockSeparator && blockSeparator.hide();
                columnsSeparator && columnsSeparator.hide()
            },
            init: function() {
                var subscribeToEvents, that = this;
                that.callBase();
                that._columnsController = that.getController("columns");
                that._columnHeadersView = that.getView("columnHeadersView");
                that._columnsSeparatorView = that.getView("columnsSeparatorView");
                that._draggingHeaderView = that.getView("draggingHeaderView");
                that._rowsView = that.getView("rowsView");
                that._blockSeparatorView = that.getView("blockSeparatorView");
                that._headerPanelView = that.getView("headerPanel");
                that._columnChooserView = that.getView("columnChooserView");
                subscribeToEvents = function() {
                    if (that._draggingHeaderView) {
                        var draggingPanels = [that._columnChooserView, that._columnHeadersView, that._headerPanelView];
                        that._unsubscribeFromEvents(that._draggingHeaderView, draggingPanels);
                        that._subscribeToEvents(that._draggingHeaderView, draggingPanels)
                    }
                };
                that._columnHeadersView.renderCompleted.add(subscribeToEvents);
                that._headerPanelView && that._headerPanelView.renderCompleted.add(subscribeToEvents);
                that._columnChooserView && that._columnChooserView.renderCompleted.add(subscribeToEvents)
            },
            allowDrop: function(parameters) {
                return this._columnsController.allowMoveColumn(parameters.sourceColumnIndex, parameters.targetColumnIndex, parameters.sourceLocation, parameters.targetLocation)
            },
            dock: function(parameters) {
                var that = this,
                    targetColumnIndex = commonUtils.isObject(parameters.targetColumnIndex) ? parameters.targetColumnIndex.columnIndex : parameters.targetColumnIndex,
                    sourceLocation = parameters.sourceLocation,
                    sourceIndex = parameters.sourceIndex,
                    sourceColumnElement = parameters.sourceColumnElement,
                    targetLocation = parameters.targetLocation,
                    separator = that._getSeparator(targetLocation),
                    hasTargetVisibleIndex = targetColumnIndex >= 0;
                var showSeparator = function() {
                    if (that._animationColumnIndex !== targetColumnIndex) {
                        that.hideSeparators();
                        separator.element()[parameters.isLast ? "insertAfter" : "insertBefore"](parameters.targetColumnElement);
                        that._animationColumnIndex = targetColumnIndex;
                        separator.show(targetLocation)
                    }
                };
                that._columnHeadersView.element().find("." + DATAGRID_HEADER_ROW_CLASS).toggleClass(DATAGRID_HEADERS_DROP_HIGHLIGHT_CLASS, "headers" !== sourceLocation && "headers" === targetLocation && !hasTargetVisibleIndex);
                if (separator) {
                    if (sourceColumnElement) {
                        sourceColumnElement.css({
                            opacity: .5
                        });
                        if ("headers" === sourceLocation) {
                            that._columnHeadersView.setRowsOpacity(sourceIndex, .5);
                            that._rowsView.setRowsOpacity(sourceIndex, .5)
                        }
                    }
                    if (that.allowDrop(parameters) && hasTargetVisibleIndex) {
                        if ("group" === targetLocation || "columnChooser" === targetLocation) {
                            showSeparator()
                        } else {
                            that.hideSeparators();
                            that.getController("tablePosition").update(parameters.posY);
                            separator.moveByX(parameters.posX - separator.width());
                            separator.show()
                        }
                    } else {
                        that.hideSeparators()
                    }
                }
            },
            drop: function(parameters) {
                var sourceColumnElement = parameters.sourceColumnElement;
                if (sourceColumnElement) {
                    sourceColumnElement.css({
                        opacity: ""
                    });
                    this._columnHeadersView.setRowsOpacity(parameters.sourceIndex, "");
                    this._rowsView.setRowsOpacity(parameters.sourceIndex, "");
                    this._columnHeadersView.element().find("." + DATAGRID_HEADER_ROW_CLASS).removeClass(DATAGRID_HEADERS_DROP_HIGHLIGHT_CLASS)
                }
                if (this.allowDrop(parameters)) {
                    var separator = this._getSeparator(parameters.targetLocation);
                    if (separator) {
                        separator.hide()
                    }
                    this._columnsController.moveColumn(parameters.sourceColumnIndex, parameters.targetColumnIndex, parameters.sourceLocation, parameters.targetLocation)
                }
            },
            dispose: function() {
                if (this._draggingHeaderView) {
                    this._unsubscribeFromEvents(this._draggingHeaderView, [this._columnChooserView, this._columnHeadersView, this._headerPanelView])
                }
            }
        });
        gridCore.registerModule("columnsResizingReordering", {
            views: {
                columnsSeparatorView: exports.ColumnsSeparatorView,
                blockSeparatorView: exports.BlockSeparatorView,
                draggingHeaderView: exports.DraggingHeaderView,
                trackerView: exports.TrackerView
            },
            controllers: {
                draggingHeader: exports.DraggingHeaderViewController,
                tablePosition: exports.TablePositionViewController,
                columnsResizer: exports.ColumnsResizerViewController
            }
        })
    },
    /*!******************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.keyboard_navigation.js ***!
      \******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            KeyboardProcessor = __webpack_require__( /*! ../widget/ui.keyboard_processor */ 100),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65);
        var DATAGRID_ROW_CLASS = "dx-row",
            DATAGRID_DATA_ROW_CLASS = "dx-data-row",
            DATAGRID_GROUP_ROW_CLASS = "dx-group-row",
            DATAGRID_ROWS_VIEW_CLASS = "dx-datagrid-rowsview",
            DATAGRID_MASTER_DETAIL_ROW_CLASS = "dx-master-detail-row",
            DATAGRID_MASTER_DETAIL_CELL_CLASS = "dx-master-detail-cell",
            DATAGRID_EDIT_FORM_CLASS = "dx-datagrid-edit-form",
            DATAGRID_GROUP_FOOTER_CLASS = "dx-datagrid-group-footer",
            DATAGRID_COMMAND_EXPAND_CLASS = "dx-command-expand",
            DATAGRID_CLASS_SELECTOR = ".dx-datagrid",
            DATAGRID_INTERACTIVE_ELEMENTS_SELECTOR = "input, textarea, a, [tabindex]",
            DATAGRID_VIEWS = ["rowsView"],
            DATAGRID_EDIT_MODE_ROW = "row",
            DATAGRID_EDIT_MODE_FORM = "form";

        function isGroupRow($row) {
            return $row && $row.hasClass(DATAGRID_GROUP_ROW_CLASS)
        }

        function isDetailRow($row) {
            return $row && $row.hasClass(DATAGRID_MASTER_DETAIL_ROW_CLASS)
        }
        exports.KeyboardNavigationController = gridCore.ViewController.inherit({
            _isRowEditMode: function() {
                var editMode = this._editingController.getEditMode();
                return editMode === DATAGRID_EDIT_MODE_ROW || editMode === DATAGRID_EDIT_MODE_FORM
            },
            _focusView: function(view, viewIndex) {
                this._focusedViews.viewIndex = viewIndex;
                this._focusedView = view
            },
            _getInteractiveElement: function($cell, isLast) {
                var $focusedElement = $cell.find(DATAGRID_INTERACTIVE_ELEMENTS_SELECTOR).filter(":visible");
                return isLast ? $focusedElement.last() : $focusedElement.first()
            },
            _focusInteractiveElement: function($cell, isLast) {
                if (!$cell) {
                    return
                }
                var $focusedElement = this._getInteractiveElement($cell, isLast);
                this._testInteractiveElement = $focusedElement;
                $focusedElement.focus()
            },
            _updateFocus: function() {
                var that = this,
                    $cell = that._getFocusedCell();
                if ($cell) {
                    if (that._hasSkipRow($cell.parent())) {
                        $cell = that._getNextCell(this._focusedCellPosition && this._focusedCellPosition.rowIndex > 0 ? "upArrow" : "downArrow")
                    }
                    if ($cell && $cell.length > 0) {
                        setTimeout(function() {
                            if (that.getController("editorFactory").focus()) {
                                that._focus($cell)
                            }
                            that._editingController.isEditing() && $.proxy(that._focusInteractiveElement, that)($cell)
                        })
                    }
                }
            },
            _clickHandler: function(e) {
                var event = e.jQueryEvent,
                    $cell = $(event.currentTarget),
                    $grid = $(event.target).closest(DATAGRID_CLASS_SELECTOR).parent(),
                    data = event.data;
                if ($grid.is(this.component.element()) && this._isCellValid($cell)) {
                    this._focusView(data.view, data.viewIndex);
                    this._updateFocusedCellPosition($cell);
                    if (!this._editingController.isEditing()) {
                        data.view.element().attr("tabIndex", 0);
                        data.view.element().find(".dx-row > td[tabIndex]").attr("tabIndex", null);
                        $cell.focus()
                    }
                } else {
                    this._resetFocusedCell()
                }
            },
            _initFocusedViews: function() {
                var that = this,
                    clickAction = that.createAction(that._clickHandler);
                that._focusedViews = [];
                $.each(DATAGRID_VIEWS, function(key, viewName) {
                    var view = that.getView(viewName);
                    if (view && view.isVisible()) {
                        that._focusedViews.push(view)
                    }
                });
                $.each(that._focusedViews, function(index, view) {
                    if (view) {
                        view.renderCompleted.add(function() {
                            var $element = view.element();
                            $element.off(eventUtils.addNamespace(pointerEvents.down, "dxDataGridKeyboardNavigation"), clickAction);
                            $element.on(eventUtils.addNamespace(pointerEvents.down, "dxDataGridKeyboardNavigation"), "." + DATAGRID_ROW_CLASS + " td", {
                                viewIndex: index,
                                view: view
                            }, clickAction);
                            that._initKeyDownProcessor(that, $element, that._keyDownHandler);
                            if (that._focusedView && that._focusedView.name === view.name && that._isNeedFocus) {
                                that._updateFocus()
                            }
                        })
                    }
                })
            },
            _initKeyDownProcessor: function(context, element, handler) {
                if (this._keyDownProcessor) {
                    this._keyDownProcessor.dispose();
                    this._keyDownProcessor = null
                }
                this._keyDownProcessor = new KeyboardProcessor({
                    element: element,
                    context: context,
                    handler: handler
                })
            },
            _getFocusedCell: function() {
                if (this._focusedView && this._focusedCellPosition) {
                    return this._focusedView.getCell(this._focusedCellPosition)
                }
            },
            _updateFocusedCellPosition: function($cell) {
                var that = this;
                if ($cell.length > 0 && that._focusedView) {
                    this._focusedCellPosition = {
                        columnIndex: that._focusedView.getCellIndex($cell),
                        rowIndex: $cell.parent().length > 0 && that._focusedView.getRowIndex($cell.parent())
                    }
                }
            },
            _isCellValid: function($cell) {
                if (commonUtils.isDefined($cell)) {
                    var rowsView = this.getView("rowsView"),
                        visibleColumns = this._columnsController.getVisibleColumns(),
                        rowIndex = rowsView.getRowIndex($cell.parent()),
                        columnIndex = rowsView.getCellIndex($cell),
                        column = visibleColumns[columnIndex],
                        visibleColumnCount = this._getVisibleColumnCount(rowIndex),
                        editingController = this._editingController,
                        editMode = editingController && editingController.getEditMode(),
                        isEditingCurrentRow = editingController && (editMode === DATAGRID_EDIT_MODE_ROW ? editingController.isEditRow(rowIndex) : editingController.isEditing()),
                        isMasterDetailRow = isDetailRow($cell.parent()),
                        isValidGroupSpaceColumn = function() {
                            return !isMasterDetailRow && column && !commonUtils.isDefined(column.groupIndex) || parseInt($cell.attr("colspan")) > 1
                        };
                    if (visibleColumnCount > columnIndex && isValidGroupSpaceColumn()) {
                        var isExpandColumn = "expand" === column.command;
                        return column && !column.command && (!isEditingCurrentRow || column.allowEditing) || isExpandColumn
                    }
                }
            },
            _isCellByPositionValid: function(cellPosition) {
                var $cell = this._focusedView && this._focusedView.getCell(cellPosition);
                return this._isCellValid($cell)
            },
            _focus: function($cell) {
                var $focusElement, $row = $cell.parent(),
                    $focusedCell = this._getFocusedCell(),
                    focusedView = this._focusedView;
                $focusedCell && $focusedCell.attr("tabIndex", null);
                if (isGroupRow($row)) {
                    $focusElement = $row;
                    if (focusedView) {
                        this._focusedCellPosition.rowIndex = focusedView.getRowIndex($row)
                    }
                } else {
                    $focusElement = $cell;
                    this._updateFocusedCellPosition($cell)
                }
                focusedView && focusedView.element().attr("tabIndex", null);
                $focusElement.attr("tabindex", 0);
                $focusElement.focus();
                this.getController("editorFactory").focus($focusElement)
            },
            _hasSkipRow: function($row) {
                return $row && ("none" === $row.css("display") || $row.hasClass(DATAGRID_GROUP_FOOTER_CLASS) || isDetailRow($row) && !$row.hasClass(DATAGRID_EDIT_FORM_CLASS))
            },
            _enterKeyHandler: function(eventArgs, isEditing) {
                var $cell = this._getFocusedCell(),
                    editingOptions = this.option("editing"),
                    rowIndex = this._focusedCellPosition ? this._focusedCellPosition.rowIndex : null,
                    $row = this._focusedView && this._focusedView.getRow(rowIndex);
                if (this.option("grouping.allowCollapsing") && isGroupRow($row) || this.option("masterDetail.enabled") && $cell && $cell.hasClass(DATAGRID_COMMAND_EXPAND_CLASS)) {
                    var key = this._dataController.getKeyByRowIndex(rowIndex),
                        item = this._dataController.items()[rowIndex];
                    if (void 0 !== key && item && item.data && !item.data.isContinuation) {
                        this._dataController.changeRowExpand(key)
                    }
                } else {
                    if (isEditing) {
                        $cell = this._getCellElementFromTarget(eventArgs.originalEvent.target);
                        this._updateFocusedCellPosition($cell);
                        if (this._isRowEditMode()) {
                            this._focusEditFormCell($cell);
                            setTimeout($.proxy(this._editingController.saveEditData, this._editingController))
                        } else {
                            this._editingController.closeEditCell()
                        }
                    } else {
                        var column = this._columnsController.getVisibleColumns()[this._focusedCellPosition.columnIndex];
                        if (editingOptions.allowUpdating && column && column.allowEditing) {
                            if (this._isRowEditMode()) {
                                this._editingController.editRow(rowIndex)
                            } else {
                                this._focusedCellPosition && this._editingController.editCell(rowIndex, this._focusedCellPosition.columnIndex)
                            }
                        }
                    }
                }
            },
            _leftRightKeysHandler: function(eventArgs, isEditing) {
                var directionCode, $cell, rowIndex = this._focusedCellPosition ? this._focusedCellPosition.rowIndex : null,
                    $row = this._focusedView && this._focusedView.getRow(rowIndex);
                if (!isEditing && $row && !isGroupRow($row) && !isDetailRow($row)) {
                    directionCode = this._getDirectionCodeByKey(eventArgs.key);
                    $cell = this._getNextCell(directionCode);
                    if ($cell && this._isCellValid($cell)) {
                        this._focus($cell)
                    }
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _getDirectionCodeByKey: function(key) {
                var directionCode;
                if (this.option("rtlEnabled")) {
                    directionCode = "leftArrow" === key ? "nextInRow" : "previousInRow"
                } else {
                    directionCode = "leftArrow" === key ? "previousInRow" : "nextInRow"
                }
                return directionCode
            },
            _upDownKeysHandler: function(eventArgs, isEditing) {
                var $cell, rowIndex = this._focusedCellPosition ? this._focusedCellPosition.rowIndex : null,
                    $row = this._focusedView && this._focusedView.getRow(rowIndex);
                if (!isEditing && !isDetailRow($row)) {
                    if (0 === rowIndex || this._focusedView && rowIndex === this._focusedView.getRowsCount() - 1) {}
                    $cell = this._getNextCell(eventArgs.key);
                    if ($cell && this._isCellValid($cell)) {
                        this._focus($cell)
                    }
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _pageUpKeyHandler: function(eventArgs) {
                var scrollingMode = this.option("scrolling.mode"),
                    pageIndex = this._dataController.pageIndex(),
                    isVirtualScrolling = "virtual" === scrollingMode || "infinite" === scrollingMode;
                if (pageIndex > 0 && !isVirtualScrolling) {
                    this._dataController.pageIndex(pageIndex - 1);
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _pageDownKeyHandler: function(eventArgs) {
                var scrollingMode = this.option("scrolling.mode"),
                    isVirtualScrolling = "virtual" === scrollingMode || "infinite" === scrollingMode,
                    pageIndex = this._dataController.pageIndex(),
                    pageCount = this._dataController.pageCount();
                if (pageIndex < pageCount - 1 && !isVirtualScrolling) {
                    this._dataController.pageIndex(pageIndex + 1);
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _spaceKeyHandler: function(eventArgs, isEditing) {
                var rowIndex = this._focusedCellPosition ? this._focusedCellPosition.rowIndex : null,
                    $target = $(eventArgs.originalEvent && eventArgs.originalEvent.target);
                if (this.option("selection") && "none" !== this.option("selection").mode && !isEditing && ($target.parent().hasClass(DATAGRID_DATA_ROW_CLASS) || $target.hasClass(DATAGRID_ROWS_VIEW_CLASS))) {
                    this._selectionController.changeItemSelection(rowIndex, {
                        shift: eventArgs.shift,
                        control: eventArgs.ctrl
                    });
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _ctrlAKeyHandler: function(eventArgs, isEditing) {
                if (!isEditing && eventArgs.ctrl && "multiple" === this.option("selection.mode") && this.option("selection.allowSelectAll")) {
                    this._selectionController.selectAll();
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _tabKeyHandler: function(eventArgs, isEditing) {
                var $cell, editingOptions = this.option("editing"),
                    direction = eventArgs.shift ? "previous" : "next",
                    isOriginalHandlerRequired = !eventArgs.shift && this._isLastValidCell(this._focusedCellPosition) || eventArgs.shift && this._isFirstValidCell(this._focusedCellPosition),
                    eventTarget = eventArgs.originalEvent.target,
                    $masterDetailCell = $(eventTarget).closest("." + DATAGRID_MASTER_DETAIL_CELL_CLASS),
                    $masterDetailGrid = $masterDetailCell.closest(DATAGRID_CLASS_SELECTOR).parent();
                if ($masterDetailCell.length && $masterDetailGrid.is(this.component.element())) {
                    this._updateFocusedCellPosition($masterDetailCell);
                    $cell = this._getNextCell(direction, null, null, true);
                    $cell.attr("tabindex", 0);
                    return
                }
                if (editingOptions && eventTarget && !isOriginalHandlerRequired) {
                    if ($(eventTarget).hasClass(DATAGRID_ROWS_VIEW_CLASS)) {
                        this._resetFocusedCell()
                    }
                    if (isEditing) {
                        var column, isEditingAllowed;
                        this._updateFocusedCellPosition(this._getCellElementFromTarget(eventTarget));
                        $cell = this._getNextCell(direction);
                        column = this._columnsController.getVisibleColumns()[this.getView("rowsView").getCellIndex($cell)];
                        isEditingAllowed = editingOptions.allowUpdating && column.allowEditing;
                        if (!isEditingAllowed) {
                            this._editingController.closeEditCell()
                        }
                        if (this._focusCell($cell)) {
                            if (!this._isRowEditMode() && isEditingAllowed) {
                                this._editingController.editCell(this._focusedCellPosition.rowIndex, this._focusedCellPosition.columnIndex)
                            } else {
                                this._focusInteractiveElement($cell, eventArgs.shift)
                            }
                        }
                    } else {
                        $cell = $(eventTarget).closest(".dx-row > td");
                        var $lastIteractiveElement = this._getInteractiveElement($cell, !eventArgs.shift);
                        if ($lastIteractiveElement.length && eventTarget !== $lastIteractiveElement.get(0)) {
                            isOriginalHandlerRequired = true
                        } else {
                            $cell = this._getNextCell(direction, this._getElementType(eventTarget));
                            this._focusCell($cell);
                            this._focusInteractiveElement($cell, eventArgs.shift)
                        }
                    }
                }
                if (isOriginalHandlerRequired) {
                    this.getController("editorFactory").loseFocus();
                    if (this._editingController.isEditing() && !this._isRowEditMode()) {
                        this._resetFocusedCell();
                        this._editingController.closeEditCell()
                    }
                } else {
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _focusCell: function($cell) {
                if (this._isCellValid($cell)) {
                    this._focus($cell);
                    return true
                }
            },
            _getElementType: function(target) {
                return $(target).is("tr") ? "row" : "cell"
            },
            _focusEditFormCell: function($cell) {
                if ($cell.hasClass(DATAGRID_MASTER_DETAIL_CELL_CLASS)) {
                    this.getController("editorFactory").focus($cell, true)
                }
            },
            _escapeKeyHandler: function(eventArgs, isEditing) {
                if (isEditing) {
                    var $cell = this._getCellElementFromTarget(eventArgs.originalEvent.target);
                    this._updateFocusedCellPosition($cell);
                    if (!this._isRowEditMode()) {
                        this._editingController.closeEditCell()
                    } else {
                        this._focusEditFormCell($cell);
                        this._editingController.cancelEditData()
                    }
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _ctrlFKeyHandler: function(eventArgs) {
                if (eventArgs.ctrl && this.option("searchPanel") && this.option("searchPanel").visible) {
                    this._testHeaderPanelFocused = true;
                    this._headerPanel.focus();
                    eventArgs.originalEvent.preventDefault()
                }
            },
            _keyDownHandler: function(e) {
                var isEditing = this._editingController.isEditing(),
                    needStopPropagation = true,
                    args = {
                        handled: false,
                        jQueryEvent: e.originalEvent
                    };
                this.executeAction("onKeyDown", args);
                if (e.originalEvent.isDefaultPrevented()) {
                    return
                }
                this._isNeedFocus = true;
                this._isNeedScroll = true;
                this._updateFocusedCellPosition(this._getCellElementFromTarget(args.jQueryEvent.target));
                if (!args.handled) {
                    switch (e.key) {
                        case "leftArrow":
                        case "rightArrow":
                            this._leftRightKeysHandler(e, isEditing);
                            break;
                        case "upArrow":
                        case "downArrow":
                            this._upDownKeysHandler(e, isEditing);
                            break;
                        case "pageUp":
                            this._pageUpKeyHandler(e);
                            break;
                        case "pageDown":
                            this._pageDownKeyHandler(e);
                            break;
                        case "space":
                            this._spaceKeyHandler(e, isEditing);
                            break;
                        case "A":
                            this._ctrlAKeyHandler(e, isEditing);
                            break;
                        case "tab":
                            this._tabKeyHandler(e, isEditing);
                            break;
                        case "enter":
                            this._enterKeyHandler(e, isEditing);
                            break;
                        case "escape":
                            this._escapeKeyHandler(e, isEditing);
                            break;
                        case "F":
                            this._ctrlFKeyHandler(e);
                            break;
                        default:
                            this._isNeedFocus = false;
                            this._isNeedScroll = false;
                            needStopPropagation = false
                    }
                    if (needStopPropagation) {
                        e.originalEvent.stopPropagation()
                    }
                }
            },
            _isLastRow: function(rowIndex) {
                return rowIndex === this.getController("data").items().length - 1
            },
            _getNextCell: function(keyCode, elementType, cellPosition) {
                var rowIndex, newFocusedCellPosition, $cell, $row, focusedCellPosition = cellPosition || this._focusedCellPosition,
                    includeCommandCells = $.inArray(keyCode, ["next", "previous"]) > -1;
                if (this._focusedView && focusedCellPosition) {
                    newFocusedCellPosition = this._getNewPositionByCode({
                        columnIndex: focusedCellPosition.columnIndex,
                        rowIndex: focusedCellPosition.rowIndex
                    }, elementType, keyCode);
                    $cell = this._focusedView.getCell(newFocusedCellPosition);
                    if (!this._isCellValid($cell) && this._isCellInRow(newFocusedCellPosition, includeCommandCells)) {
                        $cell = this._getNextCell(keyCode, "cell", newFocusedCellPosition)
                    }
                    $row = $cell && $cell.parent();
                    if (this._hasSkipRow($row)) {
                        rowIndex = this._focusedView.getRowIndex($row);
                        if (!this._isLastRow(rowIndex)) {
                            $cell = this._getNextCell(keyCode, "row", {
                                columnIndex: focusedCellPosition.columnIndex,
                                rowIndex: rowIndex
                            })
                        } else {
                            return null
                        }
                    }
                    return $cell
                }
                return null
            },
            _getNewPositionByCode: function(cellPosition, elementType, code) {
                var visibleColumnsCount, columnIndex = cellPosition.columnIndex,
                    rowIndex = cellPosition.rowIndex;
                if (void 0 === cellPosition.rowIndex && "next" === code) {
                    return {
                        columnIndex: 0,
                        rowIndex: 0
                    }
                }
                switch (code) {
                    case "nextInRow":
                    case "next":
                        visibleColumnsCount = this._getVisibleColumnCount(rowIndex);
                        if (columnIndex < visibleColumnsCount - 1 && !this._isLastValidCell({
                                columnIndex: columnIndex,
                                rowIndex: rowIndex
                            }) && "row" !== elementType) {
                            columnIndex++
                        } else {
                            if (!this._isLastRow(rowIndex) && "next" === code) {
                                columnIndex = 0;
                                rowIndex++
                            }
                        }
                        break;
                    case "previousInRow":
                    case "previous":
                        if (columnIndex > 0 && !this._isFirstValidCell({
                                columnIndex: columnIndex,
                                rowIndex: rowIndex
                            }) && "row" !== elementType) {
                            columnIndex--
                        } else {
                            if (rowIndex > 0 && "previous" === code) {
                                rowIndex--;
                                visibleColumnsCount = this._getVisibleColumnCount(rowIndex);
                                columnIndex = visibleColumnsCount - 1
                            }
                        }
                        break;
                    case "upArrow":
                        rowIndex = rowIndex > 0 ? rowIndex - 1 : rowIndex;
                        break;
                    case "downArrow":
                        rowIndex = !this._isLastRow(rowIndex) ? rowIndex + 1 : rowIndex
                }
                return {
                    columnIndex: columnIndex,
                    rowIndex: rowIndex
                }
            },
            _isFirstValidCell: function(cellPosition) {
                var isFirstValidCell = false;
                if (0 === cellPosition.rowIndex && cellPosition.columnIndex >= 0) {
                    isFirstValidCell = isFirstValidCell || !this._haveValidCellBeforePosition(cellPosition)
                }
                return isFirstValidCell
            },
            _haveValidCellBeforePosition: function(cellPosition) {
                var columnIndex = cellPosition.columnIndex,
                    hasValidCells = false;
                while (columnIndex > 0 && !hasValidCells) {
                    var checkingPosition = {
                        columnIndex: --columnIndex,
                        rowIndex: cellPosition.rowIndex
                    };
                    hasValidCells = this._isCellByPositionValid(checkingPosition)
                }
                return hasValidCells
            },
            _isLastValidCell: function(cellPosition) {
                var checkingPosition = {
                        columnIndex: cellPosition.columnIndex + 1,
                        rowIndex: cellPosition.rowIndex
                    },
                    visibleColumnsCount = this._getVisibleColumnCount(cellPosition.rowIndex),
                    isCheckingCellValid = this._isCellByPositionValid(checkingPosition);
                if (!this._isLastRow(cellPosition.rowIndex)) {
                    return false
                }
                if (cellPosition.columnIndex === visibleColumnsCount - 1) {
                    return true
                }
                if (isCheckingCellValid) {
                    return false
                }
                return this._isLastValidCell(checkingPosition)
            },
            _getVisibleColumnCount: function(rowIndex) {
                var row = this.getController("data").items()[rowIndex],
                    visibleColumns = this.getController("columns").getVisibleColumns(),
                    visibleColumnCount = 0;
                if (row && "detail" === row.rowType) {
                    while (visibleColumns[visibleColumnCount] && visibleColumns[visibleColumnCount].command) {
                        visibleColumnCount++
                    }
                    visibleColumnCount++
                } else {
                    visibleColumnCount = visibleColumns.length
                }
                return visibleColumnCount
            },
            _isCellInRow: function(cellPosition, includeCommandCells) {
                var columnIndex = cellPosition.columnIndex,
                    visibleColumnsCount = this._getVisibleColumnCount(cellPosition.rowIndex);
                return includeCommandCells ? columnIndex >= 0 && columnIndex <= visibleColumnsCount - 1 : columnIndex > 0 && columnIndex < visibleColumnsCount - 1
            },
            _resetFocusedCell: function() {
                var that = this,
                    $cell = that._getFocusedCell();
                $cell && $cell.attr("tabIndex", null);
                that._focusedView && that._focusedView.renderFocusState && that._focusedView.renderFocusState();
                that._isNeedFocus = false;
                that._isNeedScroll = false;
                that._focusedCellPosition = {}
            },
            _getCellElementFromTarget: function(target) {
                return $(target).closest("." + DATAGRID_ROW_CLASS + "> td")
            },
            init: function() {
                var that = this;
                if (that.option("useKeyboard")) {
                    that._dataController = that.getController("data");
                    that._selectionController = that.getController("selection");
                    that._editingController = that.getController("editing");
                    that._headerPanel = that.getView("headerPanel");
                    that._columnsController = that.getController("columns");
                    that.getController("editorFactory").focused.add(function($element) {
                        that.setupFocusedView();
                        if (that._isNeedScroll) {
                            if ($element.is(":visible") && that._focusedView && that._focusedView.getScrollable) {
                                that._scrollToElement($element);
                                that._isNeedScroll = false
                            }
                        }
                    });
                    that._focusedCellPosition = {};
                    that._dataController.changed.add(function(change) {
                        if (that._focusedCellPosition && change && "prepend" === change.changeType) {
                            that._focusedCellPosition.rowIndex += change.items.length
                        }
                    });
                    that._initFocusedViews();
                    that._documentClickHandler = that.createAction(function(e) {
                        if (!$(e.jQueryEvent.target).closest("." + DATAGRID_ROWS_VIEW_CLASS).length) {
                            that._resetFocusedCell()
                        }
                    });
                    that.createAction("onKeyDown");
                    $(document).on(eventUtils.addNamespace(pointerEvents.down, "dxDataGridKeyboardNavigation"), that._documentClickHandler)
                }
            },
            _scrollToElement: function($element, offset) {
                var scrollable = this._focusedView.getScrollable();
                scrollable && scrollable.scrollToElement($element, offset)
            },
            focus: function($element) {
                var focusView = this._getFocusedViewByElement($element);
                if (focusView) {
                    this._focusView(focusView.view, focusView.viewIndex);
                    this._isNeedFocus = true;
                    this._isNeedScroll = true;
                    this._focus($element);
                    this._focusInteractiveElement($element)
                }
            },
            getFocusedView: function() {
                return this._focusedView
            },
            _getFocusedViewByElement: function($element) {
                var condition = function(view) {
                    return $element.closest(view._$element).length
                };
                return this._getFocusedViewByCondition(condition)
            },
            _getFocusedViewByCondition: function(conditionFunction) {
                var focusView;
                $.each(this._focusedViews, function(index, view) {
                    if (conditionFunction(view)) {
                        focusView = {
                            viewIndex: index,
                            view: view
                        };
                        return false
                    }
                });
                return focusView
            },
            _isHeaderView: function(viewName) {
                return "columnHeadersView" === viewName
            },
            focusViewByName: function(viewName) {
                var view = this._getFocusedViewByName(viewName);
                this._focusView(view.view, view.viewIndex)
            },
            setupFocusedView: function() {
                if (!commonUtils.isDefined(this._focusedView)) {
                    this.focusViewByName("rowsView")
                }
            },
            _getFocusedViewByName: function(viewName) {
                var condition = function(view) {
                    return view.name === viewName
                };
                return this._getFocusedViewByCondition(condition)
            },
            optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "useKeyboard":
                        args.handled = true;
                        break;
                    default:
                        that.callBase(args)
                }
            },
            dispose: function() {
                this.callBase();
                this._focusedView = null;
                this._focusedViews = null;
                this._keyDownProcessor && this._keyDownProcessor.dispose();
                $(document).off(eventUtils.addNamespace(pointerEvents.down, "dxDataGridKeyboardNavigation"), this._documentClickHandler)
            }
        });
        gridCore.registerModule("keyboardNavigation", {
            defaultOptions: function() {
                return {
                    useKeyboard: true
                }
            },
            controllers: {
                keyboardNavigation: exports.KeyboardNavigationController
            },
            extenders: {
                views: {
                    rowsView: {
                        renderFocusState: function() {
                            var $row, $cell, that = this,
                                cellElements = that.getCellElements(0),
                                keyboardNavigation = that.getController("keyboardNavigation"),
                                oldFocusedView = keyboardNavigation._focusedView;
                            that.element().attr("tabIndex", null);
                            if (that.option("useKeyboard") && cellElements) {
                                $row = cellElements.eq(0).parent();
                                if (isGroupRow($row)) {
                                    $row.attr("tabIndex", 0)
                                } else {
                                    keyboardNavigation._focusedView = that;
                                    for (var i = 0; i < cellElements.length; i++) {
                                        $cell = cellElements.eq(i);
                                        if (keyboardNavigation._isCellValid($cell)) {
                                            $cell.attr("tabIndex", 0);
                                            break
                                        }
                                    }
                                    keyboardNavigation._focusedView = oldFocusedView
                                }
                            }
                        },
                        renderDelayedTemplates: function() {
                            this.callBase.apply(this, arguments);
                            this.renderFocusState()
                        },
                        _renderCore: function(change) {
                            this.callBase(change);
                            this.renderFocusState()
                        }
                    }
                },
                controllers: {
                    editing: {
                        editCell: function(rowIndex, columnIndex) {
                            var isCellEditing = this.callBase(rowIndex, columnIndex),
                                keyboardNavigationController = this.getController("keyboardNavigation");
                            if (isCellEditing) {
                                keyboardNavigationController.setupFocusedView()
                            }
                            return isCellEditing
                        },
                        getFocusedCellInRow: function(rowIndex) {
                            var keyboardNavigationController = this.getController("keyboardNavigation"),
                                $cell = this.callBase(rowIndex);
                            if (this.option("useKeyboard") && keyboardNavigationController._focusedCellPosition.rowIndex === rowIndex) {
                                $cell = keyboardNavigationController._getFocusedCell() || $cell
                            }
                            return $cell
                        }
                    }
                }
            }
        })
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.summary_module.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dataSourceAdapter = __webpack_require__( /*! ./ui.data_grid.data_source_adapter */ 344),
            columnsView = __webpack_require__( /*! ./ui.data_grid.columns_view */ 340),
            AggregateCalculator = __webpack_require__( /*! ./aggregate_calculator */ 379),
            dataQuery = __webpack_require__( /*! ../../data/query */ 158),
            dataUtils = __webpack_require__( /*! ../../data/utils */ 137);
        var DATAGRID_TOTAL_FOOTER_CLASS = "dx-datagrid-total-footer",
            DATAGRID_SUMMARY_ITEM_CLASS = "dx-datagrid-summary-item",
            DATAGRID_TEXT_CONTENT_CLASS = "dx-datagrid-text-content",
            DATAGRID_GROUP_FOOTER_CLASS = "dx-datagrid-group-footer",
            DATAGRID_GROUP_TEXT_CONTENT_CLASS = "dx-datagrid-group-text-content",
            DATAGRID_NOWRAP_CLASS = "dx-datagrid-nowrap",
            DATAGRID_GROUP_FOOTER_ROW_TYPE = "groupFooter";
        var renderSummaryCell = function($cell, options) {
                var i, summaryItem, column = options.column,
                    summaryItems = options.summaryItems,
                    $summaryItems = [];
                if (!column.command && summaryItems) {
                    for (i = 0; i < summaryItems.length; i++) {
                        summaryItem = summaryItems[i];
                        $summaryItems.push($("<div>").css("text-align", summaryItem.alignment || column.alignment).addClass(DATAGRID_SUMMARY_ITEM_CLASS).addClass(DATAGRID_TEXT_CONTENT_CLASS).addClass(summaryItem.cssClass).toggleClass(DATAGRID_GROUP_TEXT_CONTENT_CLASS, "group" === options.rowType).text(gridCore.getSummaryText(summaryItem, options.summaryTexts)))
                    }
                    $cell.append($summaryItems)
                }
            },
            getSummaryCellOptions = function(that, options) {
                var summaryTexts = that.option("summary.texts") || {};
                return {
                    totalItem: options.row,
                    summaryItems: options.row.summaryCells[options.columnIndex],
                    summaryTexts: summaryTexts
                }
            };
        var getGroupAggregates = function(data) {
            return data.summary || data.aggregates || []
        };
        exports.FooterView = columnsView.ColumnsView.inherit(function() {
            return {
                _getRows: function() {
                    return this._dataController.footerItems()
                },
                _getCellOptions: function(options) {
                    return $.extend(this.callBase(options), getSummaryCellOptions(this, options))
                },
                _renderCellContent: function($cell, options) {
                    renderSummaryCell($cell, options);
                    this.callBase($cell, options)
                },
                _renderCore: function() {
                    var totalItem = this._dataController.footerItems()[0];
                    this.element().empty().addClass(DATAGRID_TOTAL_FOOTER_CLASS).toggleClass(DATAGRID_NOWRAP_CLASS, !this.option("wordWrapEnabled"));
                    if (totalItem && totalItem.summaryCells && totalItem.summaryCells.length) {
                        this._updateContent(this._renderTable())
                    }
                },
                _rowClick: function(e) {
                    var item = this._dataController.footerItems()[e.rowIndex] || {};
                    this.executeAction("onRowClick", $.extend({}, e, item))
                },
                _columnOptionChanged: function(e) {
                    var optionNames = e.optionNames;
                    if (e.changeTypes.grouping) {
                        return
                    }
                    if (optionNames.width || optionNames.visibleWidth) {
                        this.callBase(e)
                    }
                },
                _handleDataChanged: function(e) {
                    if ("refresh" === e.changeType) {
                        this.render()
                    }
                },
                getHeight: function() {
                    var $element = this.element();
                    return $element ? $element.outerHeight(true) : 0
                },
                isVisible: function() {
                    return !!this._dataController.footerItems().length
                }
            }
        }());
        var SummaryDataSourceAdapterExtender = function() {
            return {
                init: function() {
                    this.callBase.apply(this, arguments);
                    this._totalAggregates = []
                },
                summary: function(summary) {
                    if (!arguments.length) {
                        return this._summary
                    }
                    this._summary = summary
                },
                totalAggregates: function() {
                    return this._totalAggregates
                }
            }
        }();
        var SummaryDataSourceAdapterClientExtender = function() {
            var calculateAggregates = function(that, summary, data, groupLevel) {
                var calculator;
                if (summary) {
                    calculator = new AggregateCalculator({
                        totalAggregates: summary.totalAggregates,
                        groupAggregates: summary.groupAggregates,
                        data: data,
                        groupLevel: groupLevel
                    });
                    calculator.calculate()
                }
                return calculator ? calculator.totalAggregates() : []
            };
            var sortGroupsBySummaryCore = function(items, groups, sortByGroups) {
                if (!items || !groups.length) {
                    return items
                }
                var query, group = groups[0],
                    sorts = sortByGroups[0];
                if (group && sorts && sorts.length) {
                    query = dataQuery(items);
                    $.each(sorts, function(index) {
                        if (0 === index) {
                            query = query.sortBy(this.selector, this.desc)
                        } else {
                            query = query.thenBy(this.selector, this.desc)
                        }
                    });
                    query.enumerate().done(function(sortedItems) {
                        items = sortedItems
                    })
                }
                groups = groups.slice(1);
                sortByGroups = sortByGroups.slice(1);
                if (groups.length && sortByGroups.length) {
                    $.each(items, function() {
                        this.items = sortGroupsBySummaryCore(this.items, groups, sortByGroups)
                    })
                }
                return items
            };
            var sortGroupsBySummary = function(data, group, summary) {
                var sortByGroups = summary && summary.sortByGroups && summary.sortByGroups();
                if (sortByGroups && sortByGroups.length) {
                    return sortGroupsBySummaryCore(data, group, sortByGroups)
                }
                return data
            };
            return {
                _customizeRemoteOperations: function(options) {
                    var summary = this.summary();
                    if (summary) {
                        if (options.remoteOperations.summary) {
                            if (!options.isCustomLoading || options.storeLoadOptions.isLoadingAll) {
                                if (options.storeLoadOptions.group) {
                                    if (options.remoteOperations.grouping) {
                                        options.storeLoadOptions.groupSummary = summary.groupAggregates
                                    } else {
                                        if (summary.groupAggregates.length) {
                                            options.remoteOperations.paging = false
                                        }
                                    }
                                }
                                options.storeLoadOptions.totalSummary = summary.totalAggregates
                            }
                        } else {
                            if (summary.totalAggregates.length || summary.groupAggregates.length && options.storeLoadOptions.group) {
                                options.remoteOperations.paging = false
                            }
                        }
                    }
                    this.callBase.apply(this, arguments)
                },
                _handleDataLoadedCore: function(options) {
                    var totalAggregates, that = this,
                        groups = dataUtils.normalizeSortingInfo(options.loadOptions.group || []),
                        summary = that.summary(),
                        remoteOperations = options.remoteOperations || {};
                    if (remoteOperations.summary) {
                        if (!remoteOperations.paging && !remoteOperations.grouping && groups.length && summary) {
                            calculateAggregates(that, {
                                groupAggregates: summary.groupAggregates
                            }, options.data, groups.length);
                            options.data = sortGroupsBySummary(options.data, groups, summary)
                        }
                        that._totalAggregates = options.extra && options.extra.summary || that._totalAggregates
                    } else {
                        if (!remoteOperations.paging) {
                            totalAggregates = calculateAggregates(that, summary, options.data, groups.length);
                            options.data = sortGroupsBySummary(options.data, groups, summary);
                            options.extra = options.extra || {};
                            that._totalAggregates = options.extra.summary = totalAggregates
                        }
                    }
                    that.callBase(options)
                }
            }
        }();
        dataSourceAdapter.extend(SummaryDataSourceAdapterExtender);
        dataSourceAdapter.extend(SummaryDataSourceAdapterClientExtender);
        exports.renderSummaryCell = renderSummaryCell;
        gridCore.registerModule("summary", {
            defaultOptions: function() {
                return {
                    summary: {
                        groupItems: void 0,
                        totalItems: void 0,
                        calculateCustomSummary: void 0,
                        skipEmptyValues: true,
                        texts: {
                            sum: messageLocalization.getFormatter("dxDataGrid-summarySum"),
                            sumOtherColumn: messageLocalization.getFormatter("dxDataGrid-summarySumOtherColumn"),
                            min: messageLocalization.getFormatter("dxDataGrid-summaryMin"),
                            minOtherColumn: messageLocalization.getFormatter("dxDataGrid-summaryMinOtherColumn"),
                            max: messageLocalization.getFormatter("dxDataGrid-summaryMax"),
                            maxOtherColumn: messageLocalization.getFormatter("dxDataGrid-summaryMaxOtherColumn"),
                            avg: messageLocalization.getFormatter("dxDataGrid-summaryAvg"),
                            avgOtherColumn: messageLocalization.getFormatter("dxDataGrid-summaryAvgOtherColumn"),
                            count: messageLocalization.getFormatter("dxDataGrid-summaryCount")
                        }
                    },
                    sortByGroupSummaryInfo: void 0
                }
            },
            views: {
                footerView: exports.FooterView
            },
            extenders: {
                controllers: {
                    data: function() {
                        return {
                            _isDataColumn: function(column) {
                                return column && (!commonUtils.isDefined(column.groupIndex) || column.showWhenGrouped)
                            },
                            _isGroupFooterVisible: function() {
                                var groupItem, column, i, groupItems = this.option("summary.groupItems") || [];
                                for (i = 0; i < groupItems.length; i++) {
                                    groupItem = groupItems[i];
                                    column = this._columnsController.columnOption(groupItem.showInColumn || groupItem.column);
                                    if (groupItem.showInGroupFooter && this._isDataColumn(column)) {
                                        return true
                                    }
                                }
                                return false
                            },
                            _processGroupItems: function(items, groupCount, options) {
                                var result = this.callBase.apply(this, arguments);
                                if (options) {
                                    if (void 0 === options.isGroupFooterVisible) {
                                        options.isGroupFooterVisible = this._isGroupFooterVisible()
                                    }
                                    if (options.data && options.data.items && options.isGroupFooterVisible && (options.collectContinuationItems || !options.data.isContinuationOnNextPage)) {
                                        result.push({
                                            rowType: DATAGRID_GROUP_FOOTER_ROW_TYPE,
                                            data: options.data,
                                            groupIndex: options.path.length - 1,
                                            values: []
                                        })
                                    }
                                }
                                return result
                            },
                            _processGroupItem: function(groupItem, options) {
                                var that = this;
                                if (!options.summaryGroupItems) {
                                    options.summaryGroupItems = that.option("summary.groupItems") || []
                                }
                                if ("group" === groupItem.rowType) {
                                    var groupColumnIndex = -1,
                                        afterGroupColumnIndex = -1;
                                    $.each(options.visibleColumns, function(visibleIndex) {
                                        var prevColumn = options.visibleColumns[visibleIndex - 1];
                                        if (groupItem.groupIndex === this.groupIndex) {
                                            groupColumnIndex = this.index
                                        }
                                        if (visibleIndex > 0 && "expand" === prevColumn.command && "expand" !== this.command) {
                                            afterGroupColumnIndex = this.index
                                        }
                                    });
                                    groupItem.summaryCells = this._calculateSummaryCells(options.summaryGroupItems, getGroupAggregates(groupItem.data), options.visibleColumns, function(summaryItem, column) {
                                        if (summaryItem.showInGroupFooter) {
                                            return -1
                                        }
                                        if (summaryItem.alignByColumn && column && !commonUtils.isDefined(column.groupIndex) && column.index !== afterGroupColumnIndex) {
                                            return column.index
                                        } else {
                                            return groupColumnIndex
                                        }
                                    })
                                }
                                if (groupItem.rowType === DATAGRID_GROUP_FOOTER_ROW_TYPE) {
                                    groupItem.summaryCells = this._calculateSummaryCells(options.summaryGroupItems, getGroupAggregates(groupItem.data), options.visibleColumns, function(summaryItem, column) {
                                        return summaryItem.showInGroupFooter && that._isDataColumn(column) ? column.index : -1
                                    })
                                }
                                return groupItem
                            },
                            _calculateSummaryCells: function(summaryItems, aggregates, visibleColumns, calculateTargetColumnIndex) {
                                var that = this,
                                    summaryCells = [],
                                    summaryCellsByColumns = {};
                                $.each(summaryItems, function(summaryIndex, summaryItem) {
                                    var aggregate, column = that._columnsController.columnOption(summaryItem.column),
                                        showInColumn = summaryItem.showInColumn && that._columnsController.columnOption(summaryItem.showInColumn) || column,
                                        columnIndex = calculateTargetColumnIndex(summaryItem, showInColumn);
                                    if (columnIndex >= 0) {
                                        if (!summaryCellsByColumns[columnIndex]) {
                                            summaryCellsByColumns[columnIndex] = []
                                        }
                                        aggregate = aggregates[summaryIndex];
                                        if (aggregate === aggregate) {
                                            summaryCellsByColumns[columnIndex].push($.extend({}, summaryItem, {
                                                value: commonUtils.isString(aggregate) && column && column.deserializeValue ? column.deserializeValue(aggregate) : aggregate,
                                                valueFormat: !commonUtils.isDefined(summaryItem.valueFormat) ? gridCore.getFormatByDataType(column && column.dataType) : summaryItem.valueFormat,
                                                columnCaption: column && column.index !== columnIndex ? column.caption : void 0
                                            }))
                                        }
                                    }
                                });
                                if (!$.isEmptyObject(summaryCellsByColumns)) {
                                    $.each(visibleColumns, function() {
                                        summaryCells.push(summaryCellsByColumns[this.index] || [])
                                    })
                                }
                                return summaryCells
                            },
                            _getSummaryCells: function(summaryTotalItems, totalAggregates) {
                                var that = this,
                                    columnsController = that._columnsController;
                                return that._calculateSummaryCells(summaryTotalItems, totalAggregates, columnsController.getVisibleColumns(), function(summaryItem, column) {
                                    return that._isDataColumn(column) ? column.index : -1
                                })
                            },
                            _updateItemsCore: function(change) {
                                var summaryCells, totalAggregates, that = this,
                                    dataSource = that._dataSource,
                                    summaryTotalItems = that.option("summary.totalItems");
                                that.callBase(change);
                                that._footerItems = [];
                                if (dataSource && summaryTotalItems && summaryTotalItems.length) {
                                    totalAggregates = dataSource.totalAggregates();
                                    summaryCells = this._getSummaryCells(summaryTotalItems, totalAggregates);
                                    if (summaryCells.length) {
                                        that._footerItems.push({
                                            rowType: "totalFooter",
                                            summaryCells: summaryCells
                                        })
                                    }
                                }
                            },
                            _getAggregates: function(summaryItems, remoteOperations) {
                                var that = this,
                                    columnsController = that.getController("columns"),
                                    calculateCustomSummary = that.option("summary.calculateCustomSummary"),
                                    commonSkipEmptyValues = that.option("summary.skipEmptyValues");
                                return $.map(summaryItems || [], function(summaryItem) {
                                    var options, column = columnsController.columnOption(summaryItem.column),
                                        calculateCellValue = column && column.calculateCellValue ? $.proxy(column, "calculateCellValue") : compileGetter(column ? column.dataField : summaryItem.column),
                                        aggregator = summaryItem.summaryType || "count",
                                        selector = summaryItem.column,
                                        skipEmptyValues = commonUtils.isDefined(summaryItem.skipEmptyValues) ? summaryItem.skipEmptyValues : commonSkipEmptyValues;
                                    if (remoteOperations) {
                                        return {
                                            selector: summaryItem.column,
                                            summaryType: summaryItem.summaryType
                                        }
                                    } else {
                                        if ("avg" === aggregator || "sum" === aggregator) {
                                            selector = function(data) {
                                                var value = calculateCellValue(data);
                                                return commonUtils.isDefined(value) ? Number(value) : value
                                            }
                                        } else {
                                            selector = calculateCellValue
                                        }
                                        if ("custom" === aggregator) {
                                            if (!calculateCustomSummary) {
                                                errors.log("E1026");
                                                calculateCustomSummary = function() {}
                                            }
                                            options = {
                                                component: that.component,
                                                name: summaryItem.name
                                            };
                                            calculateCustomSummary(options);
                                            options.summaryProcess = "calculate";
                                            aggregator = {
                                                seed: function() {
                                                    options.summaryProcess = "start";
                                                    options.totalValue = void 0;
                                                    delete options.value;
                                                    calculateCustomSummary(options);
                                                    return options.totalValue
                                                },
                                                step: function(totalValue, value) {
                                                    options.summaryProcess = "calculate";
                                                    options.totalValue = totalValue;
                                                    options.value = value;
                                                    calculateCustomSummary(options);
                                                    return options.totalValue
                                                },
                                                finalize: function(totalValue) {
                                                    options.summaryProcess = "finalize";
                                                    options.totalValue = totalValue;
                                                    delete options.value;
                                                    calculateCustomSummary(options);
                                                    return options.totalValue
                                                }
                                            }
                                        }
                                        return {
                                            selector: selector,
                                            aggregator: aggregator,
                                            skipEmptyValues: skipEmptyValues
                                        }
                                    }
                                })
                            },
                            _addSortInfo: function(sortByGroups, groupColumn, selector, sortOrder) {
                                var groupIndex;
                                if (groupColumn) {
                                    groupIndex = groupColumn.groupIndex;
                                    sortOrder = sortOrder || groupColumn.sortOrder;
                                    if (commonUtils.isDefined(groupIndex)) {
                                        sortByGroups[groupIndex] = sortByGroups[groupIndex] || [];
                                        sortByGroups[groupIndex].push({
                                            selector: selector,
                                            desc: "desc" === sortOrder
                                        })
                                    }
                                }
                            },
                            _findSummaryItem: function(summaryItems, name) {
                                var summaryItemIndex = -1;
                                var getFullName = function(summaryItem) {
                                    var summaryType = summaryItem.summaryType,
                                        column = summaryItem.column;
                                    return summaryType && column && summaryType + "_" + column
                                };
                                if (commonUtils.isDefined(name)) {
                                    $.each(summaryItems || [], function(index) {
                                        if (this.name === name || index === name || this.summaryType === name || this.column === name || getFullName(this) === name) {
                                            summaryItemIndex = index;
                                            return false
                                        }
                                    })
                                }
                                return summaryItemIndex
                            },
                            _getSummarySortByGroups: function(sortByGroupSummaryInfo, groupSummaryItems) {
                                var that = this,
                                    columnsController = that._columnsController,
                                    groupColumns = columnsController.getGroupColumns(),
                                    sortByGroups = [];
                                if (!groupSummaryItems || !groupSummaryItems.length) {
                                    return
                                }
                                $.each(sortByGroupSummaryInfo || [], function() {
                                    var sortOrder = this.sortOrder,
                                        groupColumn = this.groupColumn,
                                        summaryItemIndex = that._findSummaryItem(groupSummaryItems, this.summaryItem);
                                    if (summaryItemIndex < 0) {
                                        return
                                    }
                                    var selector = function(data) {
                                        return getGroupAggregates(data)[summaryItemIndex]
                                    };
                                    if (commonUtils.isDefined(groupColumn)) {
                                        groupColumn = columnsController.columnOption(groupColumn);
                                        that._addSortInfo(sortByGroups, groupColumn, selector, sortOrder)
                                    } else {
                                        $.each(groupColumns, function(groupIndex, groupColumn) {
                                            that._addSortInfo(sortByGroups, groupColumn, selector, sortOrder)
                                        })
                                    }
                                });
                                return sortByGroups
                            },
                            _createDataSourceAdapterCore: function(dataSource, remoteOperations) {
                                var summary = this._getSummaryOptions(remoteOperations),
                                    dataSourceAdapter = this.callBase(dataSource, remoteOperations);
                                dataSourceAdapter.summary(summary);
                                return dataSourceAdapter
                            },
                            _getSummaryOptions: function(remoteOperations) {
                                var that = this,
                                    groupSummaryItems = that.option("summary.groupItems"),
                                    totalSummaryItems = that.option("summary.totalItems"),
                                    sortByGroupSummaryInfo = that.option("sortByGroupSummaryInfo"),
                                    groupAggregates = that._getAggregates(groupSummaryItems, remoteOperations && remoteOperations.grouping && remoteOperations.summary),
                                    totalAggregates = that._getAggregates(totalSummaryItems, remoteOperations && remoteOperations.summary),
                                    sortByGroups = function() {
                                        return that._getSummarySortByGroups(sortByGroupSummaryInfo, groupSummaryItems)
                                    };
                                if (groupAggregates.length || totalAggregates.length) {
                                    return {
                                        groupAggregates: groupAggregates,
                                        totalAggregates: totalAggregates,
                                        sortByGroups: sortByGroups
                                    }
                                }
                            },
                            publicMethods: function() {
                                var methods = this.callBase();
                                methods.push("getTotalSummaryValue");
                                return methods
                            },
                            getTotalSummaryValue: function(summaryItemName) {
                                var summaryItemIndex = this._findSummaryItem(this.option("summary.totalItems"), summaryItemName),
                                    aggregates = this._dataSource.totalAggregates();
                                if (aggregates.length && summaryItemIndex > -1) {
                                    return aggregates[summaryItemIndex]
                                }
                            },
                            optionChanged: function(args) {
                                if ("summary" === args.name || "sortByGroupSummaryInfo" === args.name) {
                                    args.name = "dataSource"
                                }
                                this.callBase(args)
                            },
                            init: function() {
                                this._footerItems = [];
                                this.callBase()
                            },
                            footerItems: function() {
                                return this._footerItems
                            }
                        }
                    }()
                },
                views: {
                    rowsView: function() {
                        return {
                            _createRow: function(row) {
                                var $row = this.callBase(row);
                                row && $row.addClass(row.rowType === DATAGRID_GROUP_FOOTER_ROW_TYPE ? DATAGRID_GROUP_FOOTER_CLASS : "");
                                return $row
                            },
                            _renderCells: function($row, options) {
                                this.callBase.apply(this, arguments);
                                if ("group" === options.row.rowType && options.row.summaryCells && options.row.summaryCells.length) {
                                    this._renderGroupSummaryCells($row, options)
                                }
                            },
                            _hasAlignByColumnSummaryItems: function(columnIndex, options) {
                                return !commonUtils.isDefined(options.columns[columnIndex].groupIndex) && options.row.summaryCells[columnIndex].length
                            },
                            _getAlignByColumnCellCount: function(groupCellColSpan, options) {
                                var columnIndex, alignByColumnCellCount = 0;
                                for (var i = 1; i < groupCellColSpan; i++) {
                                    columnIndex = options.row.summaryCells.length - i;
                                    alignByColumnCellCount = this._hasAlignByColumnSummaryItems(columnIndex, options) ? i : alignByColumnCellCount
                                }
                                return alignByColumnCellCount
                            },
                            _renderGroupSummaryCells: function($row, options) {
                                var $groupCell = $row.children().last(),
                                    groupCellColSpan = Number($groupCell.attr("colspan")) || 1,
                                    alignByColumnCellCount = this._getAlignByColumnCellCount(groupCellColSpan, options);
                                this._renderGroupSummaryCellsCore($groupCell, options, groupCellColSpan, alignByColumnCellCount)
                            },
                            _renderGroupSummaryCellsCore: function($groupCell, options, groupCellColSpan, alignByColumnCellCount) {
                                if (alignByColumnCellCount > 0) {
                                    $groupCell.attr("colspan", groupCellColSpan - alignByColumnCellCount);
                                    for (var i = 0; i < alignByColumnCellCount; i++) {
                                        var columnIndex = options.columns.length - alignByColumnCellCount + i;
                                        this._renderCell($groupCell.parent(), $.extend({
                                            column: options.columns[columnIndex],
                                            columnIndex: this._getSummaryCellIndex(columnIndex, options.columns)
                                        }, options))
                                    }
                                }
                            },
                            _getSummaryCellIndex: function(columnIndex, columns) {
                                return columnIndex
                            },
                            _getCellTemplate: function(options) {
                                if (!options.column.command && !commonUtils.isDefined(options.column.groupIndex) && options.summaryItems && options.summaryItems.length) {
                                    return renderSummaryCell
                                } else {
                                    return this.callBase(options)
                                }
                            },
                            _getCellOptions: function(options) {
                                var that = this,
                                    parameters = that.callBase(options);
                                if (options.row.summaryCells) {
                                    return $.extend(parameters, getSummaryCellOptions(that, options))
                                } else {
                                    return parameters
                                }
                            }
                        }
                    }()
                }
            }
        })
    },
    /*!******************************************************!*\
      !*** ./Scripts/ui/data_grid/aggregate_calculator.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            compileGetter = __webpack_require__( /*! ../../core/utils/data */ 36).compileGetter,
            errors = __webpack_require__( /*! ../../data/errors */ 157).errors,
            dataUtils = __webpack_require__( /*! ../../data/utils */ 137);

        function dfs(i, depth, root, callback) {
            var j = 0;
            if (i < depth) {
                for (; j < root.items.length; j++) {
                    dfs(i + 1, depth, root.items[j], callback)
                }
            }
            if (i === depth) {
                callback(root)
            }
        }

        function map(array, callback) {
            var i, ret;
            if ("map" in array) {
                return array.map(callback)
            }
            ret = new Array(array.length);
            for (i in array) {
                ret[i] = callback(array[i], i)
            }
            return ret
        }

        function isEmpty(x) {
            return x !== x || "" === x || null === x || void 0 === x
        }

        function isCount(aggregator) {
            return aggregator === dataUtils.aggregators.count
        }

        function normalizeAggregate(aggregate) {
            var selector = compileGetter(aggregate.selector),
                skipEmptyValues = "skipEmptyValues" in aggregate ? aggregate.skipEmptyValues : true,
                aggregator = aggregate.aggregator;
            if ("string" === typeof aggregator) {
                aggregator = dataUtils.aggregators[aggregator];
                if (!aggregator) {
                    throw errors.Error("E4001", aggregate.aggregator)
                }
            }
            return {
                selector: selector,
                aggregator: aggregator,
                skipEmptyValues: skipEmptyValues
            }
        }
        module.exports = Class.inherit({
            ctor: function(options) {
                this._data = options.data;
                this._groupLevel = options.groupLevel || 0;
                this._totalAggregates = map(options.totalAggregates || [], normalizeAggregate);
                this._groupAggregates = map(options.groupAggregates || [], normalizeAggregate);
                this._totals = []
            },
            calculate: function() {
                if (this._totalAggregates.length) {
                    this._calculateTotals(0, {
                        items: this._data
                    })
                }
                if (this._groupAggregates.length && this._groupLevel > 0) {
                    this._calculateGroups({
                        items: this._data
                    })
                }
            },
            totalAggregates: function() {
                return this._totals
            },
            _aggregate: function(aggregates, data, container) {
                var i, j;
                for (i = 0; i < aggregates.length; i++) {
                    if (isCount(aggregates[i].aggregator)) {
                        container[i] = (container[i] || 0) + data.items.length;
                        continue
                    }
                    for (j = 0; j < data.items.length; j++) {
                        this._accumulate(i, aggregates[i], container, data.items[j])
                    }
                }
            },
            _calculateTotals: function(level, data) {
                var i;
                if (0 === level) {
                    this._totals = this._seed(this._totalAggregates)
                }
                if (level === this._groupLevel) {
                    this._aggregate(this._totalAggregates, data, this._totals)
                } else {
                    for (i = 0; i < data.items.length; i++) {
                        this._calculateTotals(level + 1, data.items[i])
                    }
                }
                if (0 === level) {
                    this._totals = this._finalize(this._totalAggregates, this._totals)
                }
            },
            _calculateGroups: function(root) {
                var maxLevel = this._groupLevel,
                    currentLevel = maxLevel + 1,
                    seedFn = $.proxy(this._seed, this, this._groupAggregates),
                    stepFn = $.proxy(this._aggregate, this, this._groupAggregates),
                    finalizeFn = $.proxy(this._finalize, this, this._groupAggregates);

                function aggregator(node) {
                    node.aggregates = seedFn();
                    if (currentLevel === maxLevel) {
                        stepFn(node, node.aggregates)
                    } else {
                        dfs(currentLevel, maxLevel, node, function(innerNode) {
                            stepFn(innerNode, node.aggregates)
                        })
                    }
                    node.aggregates = finalizeFn(node.aggregates)
                }
                while (--currentLevel > 0) {
                    dfs(0, currentLevel, root, aggregator)
                }
            },
            _seed: function(aggregates) {
                return map(aggregates, function(aggregate) {
                    var aggregator = aggregate.aggregator,
                        seed = "seed" in aggregator ? $.isFunction(aggregator.seed) ? aggregator.seed() : aggregator.seed : NaN;
                    return seed
                })
            },
            _accumulate: function(aggregateIndex, aggregate, results, item) {
                var value = aggregate.selector(item),
                    aggregator = aggregate.aggregator,
                    skipEmptyValues = aggregate.skipEmptyValues;
                if (skipEmptyValues && isEmpty(value)) {
                    return
                }
                if (results[aggregateIndex] !== results[aggregateIndex]) {
                    results[aggregateIndex] = value
                } else {
                    results[aggregateIndex] = aggregator.step(results[aggregateIndex], value)
                }
            },
            _finalize: function(aggregates, results) {
                return map(aggregates, function(aggregate, index) {
                    var fin = aggregate.aggregator.finalize;
                    return fin ? fin(results[index]) : results[index]
                })
            }
        })
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.fixed_columns.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            browser = __webpack_require__( /*! ../../core/utils/browser */ 18),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            wheelEvent = __webpack_require__( /*! ../../events/core/wheel */ 77),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337);
        var DATAGRID_CONTENT_CLASS = "dx-datagrid-content",
            DATAGRID_MASTER_DETAIL_CELL_CLASS = "dx-master-detail-cell",
            DATAGRID_FIRST_CELL_CLASS = "dx-first-cell",
            DATAGRID_LAST_CELL_CLASS = "dx-last-cell",
            DATAGRID_HOVER_STATE_CLASS = "dx-state-hover",
            DATAGRID_CONTENT_FIXED_CLASS = "dx-datagrid-content-fixed",
            DATAGRID_FIXED_COL_CLASS = "dx-col-fixed",
            DATAGRID_POINTER_EVENTS_TARGET_CLASS = "dx-pointer-events-target",
            DATAGRID_POINTER_EVENTS_NONE_CLASS = "dx-pointer-events-none",
            getTransparentColumnIndex = function(fixedColumns) {
                var transparentColumnIndex = -1;
                $.each(fixedColumns, function(index, column) {
                    if ("transparent" === column.command) {
                        transparentColumnIndex = index;
                        return false
                    }
                });
                return transparentColumnIndex
            },
            normalizeColumnWidths = function(fixedColumns, widths, fixedWidths) {
                var i, fixedColumnIndex = 0;
                if (fixedColumns && widths && fixedWidths) {
                    for (i = 0; i < fixedColumns.length; i++) {
                        if ("transparent" === fixedColumns[i].command) {
                            fixedColumnIndex += fixedColumns[i].colspan
                        } else {
                            if (widths[fixedColumnIndex] < fixedWidths[i]) {
                                widths[fixedColumnIndex] = fixedWidths[i]
                            }
                            fixedColumnIndex++
                        }
                    }
                }
                return widths
            };
        var baseFixedColumns = {
            init: function() {
                this.callBase();
                this._isFixedTableRendering = false;
                this._isFixedColumns = false
            },
            _createCol: function(column) {
                return this.callBase(column).toggleClass(DATAGRID_FIXED_COL_CLASS, !!(this._isFixedTableRendering && (column.fixed || column.command && "transparent" !== column.command)))
            },
            _createColGroup: function(columns) {
                if (this._isFixedTableRendering) {
                    var visibleColumns = this._columnsController.getVisibleColumns();
                    for (var i = 0; i < visibleColumns.length; i++) {
                        if (!visibleColumns[i].visibleWidth && !visibleColumns[i].width) {
                            columns = visibleColumns;
                            break
                        }
                    }
                }
                return this.callBase(columns)
            },
            _renderTable: function(options) {
                var $fixedTable, $table, that = this,
                    fixedColumns = that.getFixedColumns();
                that._isFixedColumns = !!fixedColumns.length;
                $table = that.callBase(options);
                if (that._isFixedColumns) {
                    that._isFixedTableRendering = true;
                    $fixedTable = that._createTable(fixedColumns);
                    that._renderRows($fixedTable, $.extend({}, options, {
                        columns: fixedColumns
                    }));
                    that._updateContent($fixedTable, options && options.change);
                    that._isFixedTableRendering = false
                } else {
                    that._fixedTableElement && that._fixedTableElement.remove();
                    that._fixedTableElement = null
                }
                return $table
            },
            _createCell: function(options) {
                var fixedColumns, prevFixedColumn, transparentColumnIndex, that = this,
                    column = options.column,
                    columnCommand = column && column.command,
                    rowType = options.rowType,
                    $cell = that.callBase.apply(that, arguments);
                if (that._isFixedTableRendering || "filter" === rowType) {
                    fixedColumns = that.getFixedColumns();
                    transparentColumnIndex = getTransparentColumnIndex(fixedColumns);
                    prevFixedColumn = fixedColumns[transparentColumnIndex - 1]
                }
                if (that._isFixedTableRendering) {
                    if ("transparent" === columnCommand) {
                        $cell.addClass(DATAGRID_POINTER_EVENTS_NONE_CLASS).toggleClass(DATAGRID_FIRST_CELL_CLASS, 0 === transparentColumnIndex || prevFixedColumn && "expand" === prevFixedColumn.command).toggleClass(DATAGRID_LAST_CELL_CLASS, fixedColumns.length && transparentColumnIndex === fixedColumns.length - 1).html("freeSpace" !== rowType ? "&nbsp;" : "")
                    }
                } else {
                    if ("filter" === rowType) {
                        $cell.toggleClass(DATAGRID_FIRST_CELL_CLASS, options.columnIndex === transparentColumnIndex)
                    }
                }
                return $cell
            },
            _wrapTableInScrollContainer: function() {
                var $scrollContainer = this.callBase.apply(this, arguments);
                if (this._isFixedTableRendering) {
                    $scrollContainer.addClass(DATAGRID_CONTENT_FIXED_CLASS + " " + DATAGRID_POINTER_EVENTS_TARGET_CLASS)
                }
                return $scrollContainer
            },
            _renderCellContent: function($cell, options) {
                var columns, isEmptyCell, trasparentColumnIndex, alignByFixedColumnCellCount, that = this,
                    column = options.column;
                if (!that._isFixedTableRendering && that._isFixedColumns) {
                    isEmptyCell = column.fixed || column.command;
                    if ("group" === options.rowType && commonUtils.isDefined(column.groupIndex)) {
                        isEmptyCell = false;
                        if (options.row.summaryCells && options.row.summaryCells.length) {
                            columns = that._columnsController.getVisibleColumns();
                            alignByFixedColumnCellCount = that._getAlignByColumnCellCount ? that._getAlignByColumnCellCount(column.colspan, {
                                columns: columns,
                                row: options.row,
                                isFixed: true
                            }) : 0;
                            if (alignByFixedColumnCellCount > 0) {
                                trasparentColumnIndex = getTransparentColumnIndex(that._columnsController.getFixedColumns());
                                isEmptyCell = columns.length - alignByFixedColumnCellCount < trasparentColumnIndex
                            }
                        }
                    }
                    if (isEmptyCell) {
                        $cell.html("&nbsp;").addClass(column.cssClass);
                        return
                    }
                }
                if ("transparent" !== column.command) {
                    that.callBase($cell, options)
                }
            },
            getCellElements: function(rowIndex) {
                var fixedColumns, fixedColumnIndex, fixedCellElements, that = this,
                    cellElements = that.callBase(rowIndex),
                    index = "columnHeadersView" === that.name ? rowIndex : void 0;
                if (that._fixedTableElement && cellElements) {
                    fixedColumns = that.getFixedColumns(index);
                    fixedCellElements = that._getRowElements(that._fixedTableElement).eq(rowIndex).children("td");
                    $.each(fixedColumns, function(columnIndex, column) {
                        if ("transparent" === column.command) {
                            if (fixedCellElements.eq(columnIndex).hasClass(DATAGRID_MASTER_DETAIL_CELL_CLASS)) {
                                cellElements[columnIndex] = fixedCellElements.get(columnIndex)
                            }
                        } else {
                            fixedColumnIndex = that._columnsController.getVisibleIndex(column.index, index);
                            cellElements[fixedColumnIndex] = fixedCellElements.get(columnIndex)
                        }
                    })
                }
                return cellElements
            },
            getColumnWidths: function() {
                var fixedWidths, that = this,
                    result = that.callBase(),
                    fixedColumns = that.getFixedColumns();
                if (that._fixedTableElement && result.length) {
                    fixedWidths = that.callBase(that._fixedTableElement)
                }
                return normalizeColumnWidths(fixedColumns, result, fixedWidths)
            },
            _getTableElement: function() {
                var tableElement = this._isFixedTableRendering ? this._fixedTableElement : this.callBase();
                return tableElement
            },
            _setTableElement: function(tableElement) {
                if (this._isFixedTableRendering) {
                    this._fixedTableElement = tableElement.addClass(DATAGRID_POINTER_EVENTS_NONE_CLASS)
                } else {
                    this.callBase(tableElement)
                }
            },
            getColumns: function(rowIndex, $tableElement) {
                $tableElement = $tableElement || this._getTableElement();
                if (this._isFixedTableRendering || $tableElement && $tableElement.closest("table").parent("." + DATAGRID_CONTENT_FIXED_CLASS).length) {
                    return this.getFixedColumns(rowIndex)
                }
                return this.callBase(rowIndex, $tableElement)
            },
            getRowIndex: function($row) {
                var $fixedTable = this._fixedTableElement;
                if ($fixedTable && $fixedTable.find($row).length) {
                    return this._getRowElements($fixedTable).index($row)
                }
                return this.callBase($row)
            },
            getTableElements: function() {
                var result = this.callBase.apply(this, arguments);
                if (this._fixedTableElement) {
                    result = result.add(this._fixedTableElement)
                }
                return result
            },
            getFixedColumns: function(rowIndex) {
                return this._columnsController.getFixedColumns(rowIndex)
            },
            getFixedColumnsOffset: function() {
                var $transparentColumn, positionTransparentColumn, offset = {
                    left: 0,
                    right: 0
                };
                if (this._fixedTableElement) {
                    $transparentColumn = this.getTransparentColumnElement();
                    positionTransparentColumn = $transparentColumn.position();
                    offset = {
                        left: positionTransparentColumn.left,
                        right: this.element().outerWidth(true) - ($transparentColumn.outerWidth(true) + positionTransparentColumn.left)
                    }
                }
                return offset
            },
            getTransparentColumnElement: function() {
                return this._fixedTableElement && this._fixedTableElement.find("." + DATAGRID_POINTER_EVENTS_NONE_CLASS).first()
            },
            getFixedTableElement: function() {
                return this._fixedTableElement
            },
            isFixedColumns: function() {
                return this._isFixedColumns
            },
            _resizeCore: function() {
                this.callBase();
                this.synchronizeRows()
            },
            setColumnWidths: function(widths) {
                this.callBase(widths);
                this.synchronizeRows()
            },
            _getClientHeight: function(element) {
                var boundingClientRectElement = element.getBoundingClientRect && element.getBoundingClientRect();
                return boundingClientRectElement && boundingClientRectElement.height ? boundingClientRectElement.height : element.clientHeight
            },
            synchronizeRows: function() {
                var rowHeight, fixedRowHeight, rowIndex, heightTable, heightFixedTable, $rowElements, $fixedRowElements, that = this,
                    rowHeights = [],
                    fixedRowHeights = [];
                if (that._isFixedColumns && that._tableElement && that._fixedTableElement) {
                    heightTable = that._getClientHeight(that._tableElement.get(0));
                    heightFixedTable = that._getClientHeight(that._fixedTableElement.get(0));
                    $rowElements = that._getRowElements(that._tableElement);
                    $fixedRowElements = that._getRowElements(that._fixedTableElement);
                    if (heightTable !== heightFixedTable) {
                        $rowElements.css("height", "");
                        $fixedRowElements.css("height", "");
                        for (rowIndex = 0; rowIndex < $rowElements.length; rowIndex++) {
                            rowHeights.push(that._getClientHeight($rowElements.get(rowIndex)));
                            fixedRowHeights.push(that._getClientHeight($fixedRowElements.get(rowIndex)))
                        }
                        for (rowIndex = 0; rowIndex < $rowElements.length; rowIndex++) {
                            rowHeight = rowHeights[rowIndex];
                            fixedRowHeight = fixedRowHeights[rowIndex];
                            if (rowHeight > fixedRowHeight) {
                                $fixedRowElements.eq(rowIndex).css("height", rowHeight)
                            } else {
                                if (rowHeight < fixedRowHeight) {
                                    $rowElements.eq(rowIndex).css("height", fixedRowHeight)
                                }
                            }
                        }
                    }
                }
            }
        };
        var ColumnHeadersViewFixedColumnsExtender = $.extend({}, baseFixedColumns, {
            _getRowVisibleColumns: function(rowIndex) {
                if (this._isFixedTableRendering) {
                    return this.getFixedColumns(rowIndex)
                }
                return this.callBase(rowIndex)
            },
            getContextMenuItems: function(options) {
                var onItemClick, that = this,
                    column = options.column,
                    columnFixingOptions = that.option("columnFixing"),
                    items = that.callBase(options);
                if (options.row && "header" === options.row.rowType) {
                    if (column && column.allowFixing) {
                        onItemClick = function(params) {
                            switch (params.itemData.value) {
                                case "none":
                                    that._columnsController.columnOption(column.index, "fixed", false);
                                    break;
                                case "left":
                                    that._columnsController.columnOption(column.index, {
                                        fixed: true,
                                        fixedPosition: "left"
                                    });
                                    break;
                                case "right":
                                    that._columnsController.columnOption(column.index, {
                                        fixed: true,
                                        fixedPosition: "right"
                                    })
                            }
                        };
                        items = items || [];
                        items.push({
                            text: columnFixingOptions.texts.fix,
                            beginGroup: true,
                            items: [{
                                text: columnFixingOptions.texts.leftPosition,
                                value: "left",
                                disabled: column.fixed && (!column.fixedPosition || "left" === column.fixedPosition),
                                onItemClick: onItemClick
                            }, {
                                text: columnFixingOptions.texts.rightPosition,
                                value: "right",
                                disabled: column.fixed && "right" === column.fixedPosition,
                                onItemClick: onItemClick
                            }]
                        }, {
                            text: columnFixingOptions.texts.unfix,
                            value: "none",
                            disabled: !column.fixed,
                            onItemClick: onItemClick
                        })
                    }
                }
                return items
            },
            setScrollerSpacing: function(width) {
                var that = this,
                    rtlEnabled = that.option("rtlEnabled");
                that.callBase(width);
                that.element().children("." + DATAGRID_CONTENT_FIXED_CLASS).css(rtlEnabled ? {
                    paddingLeft: width
                } : {
                    paddingRight: width
                })
            },
            getFixedColumnElements: function(rowIndex) {
                var columnElements, transparentColumnIndex, $transparentColumnElement, that = this;
                if (commonUtils.isDefined(rowIndex)) {
                    return this._fixedTableElement && this._getRowElements(this._fixedTableElement).eq(rowIndex).children()
                }
                columnElements = that.getColumnElements();
                $transparentColumnElement = that.getTransparentColumnElement();
                if (columnElements && $transparentColumnElement && $transparentColumnElement.length) {
                    transparentColumnIndex = getTransparentColumnIndex(that.getFixedColumns());
                    columnElements.splice(transparentColumnIndex, $transparentColumnElement.get(0).colSpan, $transparentColumnElement.get(0))
                }
                return columnElements
            },
            getColumnWidths: function() {
                var fixedWidths, that = this,
                    result = that.callBase(),
                    $fixedColumnElements = that.getFixedColumnElements(),
                    fixedColumns = that.getFixedColumns();
                if (that._fixedTableElement) {
                    if ($fixedColumnElements && $fixedColumnElements.length) {
                        fixedWidths = that._getWidths($fixedColumnElements)
                    } else {
                        fixedWidths = that.callBase(that._fixedTableElement)
                    }
                }
                return normalizeColumnWidths(fixedColumns, result, fixedWidths)
            }
        });
        var RowsViewFixedColumnsExtender = $.extend({}, baseFixedColumns, {
            _detachHoverEvents: function() {
                this._fixedTableElement && this._fixedTableElement.off("mouseover mouseout", ".dx-data-row");
                this._tableElement && this._tableElement.off("mouseover mouseout", ".dx-data-row")
            },
            _attachHoverEvents: function() {
                var that = this,
                    attachHoverEvent = function($table) {
                        $table.on("mouseover mouseout", ".dx-data-row", that.createAction(function(args) {
                            var event = args.jQueryEvent,
                                rowIndex = that.getRowIndex($(event.target).closest(".dx-row")),
                                isHover = "mouseover" === event.type;
                            if (rowIndex >= 0) {
                                that._tableElement && that._getRowElements(that._tableElement).eq(rowIndex).toggleClass(DATAGRID_HOVER_STATE_CLASS, isHover);
                                that._fixedTableElement && that._getRowElements(that._fixedTableElement).eq(rowIndex).toggleClass(DATAGRID_HOVER_STATE_CLASS, isHover)
                            }
                        }))
                    };
                if (that._fixedTableElement && that._tableElement) {
                    attachHoverEvent(that._fixedTableElement);
                    attachHoverEvent(that._tableElement)
                }
            },
            _findContentElement: function() {
                var $content, scrollable, scrollTop, that = this,
                    element = that.element();
                if (element && that._isFixedTableRendering) {
                    $content = element.children("." + DATAGRID_CONTENT_CLASS);
                    scrollable = that.getScrollable();
                    if (!$content.length && scrollable) {
                        $content = $("<div/>").addClass(DATAGRID_CONTENT_CLASS).on("scroll", function(e) {
                            scrollTop = $(e.target).scrollTop();
                            if (scrollTop) {
                                $(e.target).scrollTop(0);
                                scrollable.scrollTo({
                                    y: that._scrollTop + scrollTop
                                })
                            }
                        }).on(wheelEvent.name, function(e) {
                            if (scrollable) {
                                scrollTop = scrollable.scrollTop();
                                scrollable.scrollTo({
                                    y: scrollTop - e.delta
                                });
                                if (scrollable.scrollTop() > 0 && scrollable.scrollTop() + scrollable.clientHeight() < scrollable.scrollHeight() + that.getScrollbarWidth()) {
                                    return false
                                }
                            }
                        }).appendTo(element)
                    }
                    return $content
                }
                return that.callBase()
            },
            _updateBottomLoading: function() {
                if (!this._isFixedTableRendering) {
                    this.callBase()
                }
            },
            _updateScrollable: function() {
                this.callBase();
                var scrollable = this.getScrollable(),
                    scrollTop = scrollable && scrollable.scrollOffset().top;
                this._updateFixedTablePosition(-scrollTop)
            },
            _renderContent: function(contentElement, tableElement) {
                if (this._isFixedTableRendering) {
                    return contentElement.empty().addClass(DATAGRID_CONTENT_CLASS + " " + DATAGRID_CONTENT_FIXED_CLASS + " " + DATAGRID_POINTER_EVENTS_TARGET_CLASS).append(tableElement)
                }
                return this.callBase(contentElement, tableElement)
            },
            _getGroupCellOptions: function(options) {
                if (this._isFixedTableRendering) {
                    return this.callBase($.extend({}, options, {
                        columns: this._columnsController.getVisibleColumns()
                    }))
                }
                return this.callBase(options)
            },
            _renderGroupSummaryCells: function($row, options) {
                if (this._isFixedTableRendering) {
                    this.callBase($row, $.extend({}, options, {
                        columns: this._columnsController.getVisibleColumns()
                    }))
                } else {
                    this.callBase($row, options)
                }
            },
            _hasAlignByColumnSummaryItems: function(columnIndex, options) {
                var result = this.callBase.apply(this, arguments),
                    column = options.columns[columnIndex];
                if (options.isFixed) {
                    return column.fixed && (result || "right" === column.fixedPosition) || "edit" === column.command
                }
                return result && !column.fixed
            },
            _renderGroupSummaryCellsCore: function($groupCell, options, groupCellColSpan, alignByColumnCellCount) {
                var startColumnIndex, transparentColumnIndex, alignByFixedColumnCellCount;
                if (this._isFixedTableRendering) {
                    options.isFixed = true;
                    alignByFixedColumnCellCount = this._getAlignByColumnCellCount(groupCellColSpan, options);
                    options.isFixed = false;
                    startColumnIndex = options.columns.length - alignByFixedColumnCellCount;
                    options = $.extend({}, options, {
                        columns: this.getFixedColumns()
                    });
                    transparentColumnIndex = getTransparentColumnIndex(options.columns);
                    if (startColumnIndex < transparentColumnIndex) {
                        alignByFixedColumnCellCount -= options.columns[transparentColumnIndex].colspan - 1 || 0;
                        groupCellColSpan -= options.columns[transparentColumnIndex].colspan - 1 || 0
                    } else {
                        if (alignByColumnCellCount > 0) {
                            if (browser.mozilla) {
                                $groupCell.css("display", "none")
                            } else {
                                $groupCell.css("visibility", "hidden")
                            }
                        }
                    }
                    alignByColumnCellCount = alignByFixedColumnCellCount
                }
                this.callBase($groupCell, options, groupCellColSpan, alignByColumnCellCount)
            },
            _getSummaryCellIndex: function(columnIndex, columns) {
                var transparentColumnIndex;
                if (this._isFixedTableRendering) {
                    transparentColumnIndex = getTransparentColumnIndex(columns);
                    if (columnIndex > transparentColumnIndex) {
                        columnIndex += columns[transparentColumnIndex].colspan - 1
                    }
                    return columnIndex
                }
                return this.callBase.apply(this, arguments)
            },
            _renderCore: function(change) {
                this._detachHoverEvents();
                this.callBase(change);
                if (this.option("hoverStateEnabled") && this._isFixedColumns) {
                    this._attachHoverEvents()
                }
            },
            optionChanged: function(args) {
                var that = this;
                that.callBase(args);
                if ("hoverStateEnabled" === args.name && that._isFixedColumns) {
                    args.value ? this._attachHoverEvents() : this._detachHoverEvents()
                }
            },
            getCellIndex: function($cell) {
                var columns, $fixedTable = this._fixedTableElement,
                    cellIndex = 0;
                if ($fixedTable && $fixedTable.find($cell).length) {
                    columns = this.getFixedColumns();
                    $.each(columns, function(index, column) {
                        if (index === $cell[0].cellIndex) {
                            return false
                        }
                        if (column.colspan) {
                            cellIndex += column.colspan;
                            return
                        }
                        cellIndex++
                    });
                    return cellIndex
                }
                return this.callBase($cell)
            },
            _updateFixedTablePosition: function(scrollTop) {
                if (this._fixedTableElement && this._tableElement) {
                    var editorFactory = this.getController("editorFactory"),
                        $focusedElement = editorFactory.focus();
                    this._fixedTableElement.css("top", scrollTop + this._tableElement.position().top);
                    if ($focusedElement) {
                        editorFactory.focus($focusedElement)
                    }
                }
            },
            setScrollerSpacing: function(vWidth, hWidth) {
                var styles, that = this;
                var $fixedContent = that.element().children("." + DATAGRID_CONTENT_FIXED_CLASS);
                if ($fixedContent.length) {
                    styles = that.option("rtlEnabled") ? {
                        marginLeft: vWidth
                    } : {
                        marginRight: vWidth
                    };
                    styles.marginBottom = hWidth;
                    $fixedContent.css(styles)
                }
            },
            _handleScroll: function(e) {
                this._updateFixedTablePosition(-e.scrollOffset.top);
                this.callBase(e)
            },
            _updateContentPosition: function() {
                var isUpdated = this.callBase();
                if (isUpdated) {
                    this._updateFixedTablePosition(-this._scrollTop)
                }
                return isUpdated
            },
            _afterRowPrepared: function(e) {
                if (this._isFixedTableRendering) {
                    return
                }
                this.callBase(e)
            }
        });
        var FooterViewFixedColumnsExtender = baseFixedColumns;
        gridCore.registerModule("fixedColumns", {
            defaultOptions: function() {
                return {
                    columnFixing: {
                        enabled: false,
                        texts: {
                            fix: messageLocalization.format("dxDataGrid-columnFixingFix"),
                            unfix: messageLocalization.format("dxDataGrid-columnFixingUnfix"),
                            leftPosition: messageLocalization.format("dxDataGrid-columnFixingLeftPosition"),
                            rightPosition: messageLocalization.format("dxDataGrid-columnFixingRightPosition")
                        }
                    }
                }
            },
            extenders: {
                views: {
                    columnHeadersView: ColumnHeadersViewFixedColumnsExtender,
                    rowsView: RowsViewFixedColumnsExtender,
                    footerView: FooterViewFixedColumnsExtender
                },
                controllers: function() {
                    var normalizeColumnIndicesByPoints = function(columns, fixedColumns, pointsByColumns) {
                        var transparentColumnIndex = getTransparentColumnIndex(fixedColumns),
                            correctIndex = columns.length - fixedColumns.length;
                        $.each(pointsByColumns, function(_, point) {
                            if (point.index > transparentColumnIndex) {
                                point.columnIndex += correctIndex;
                                point.index += correctIndex
                            }
                        });
                        return pointsByColumns
                    };
                    return {
                        draggingHeader: {
                            _generatePointsByColumns: function(options) {
                                var pointsByColumns, visibleColumns = options.columns,
                                    targetDraggingPanel = options.targetDraggingPanel;
                                if (targetDraggingPanel && "headers" === targetDraggingPanel.getName() && targetDraggingPanel.isFixedColumns()) {
                                    if (options.sourceColumn.fixed) {
                                        if (!options.rowIndex) {
                                            options.columnElements = targetDraggingPanel.getFixedColumnElements(0)
                                        }
                                        options.columns = targetDraggingPanel.getFixedColumns(options.rowIndex);
                                        pointsByColumns = this.callBase(options);
                                        normalizeColumnIndicesByPoints(visibleColumns, options.columns, pointsByColumns);
                                        return pointsByColumns
                                    }
                                }
                                return this.callBase(options)
                            },
                            _pointCreated: function(point, columns, location, sourceColumn) {
                                var boundingRect, result = this.callBase.apply(this, arguments),
                                    $transparentColumn = this._columnHeadersView.getTransparentColumnElement();
                                if (!result && "headers" === location && $transparentColumn && $transparentColumn.length) {
                                    boundingRect = $transparentColumn.get(0).getBoundingClientRect();
                                    if (sourceColumn && sourceColumn.fixed) {
                                        return "right" === sourceColumn.fixedPosition ? point.x < boundingRect.right : point.x > boundingRect.left
                                    } else {
                                        return point.x < boundingRect.left || point.x > boundingRect.right
                                    }
                                }
                                return result
                            }
                        },
                        columnsResizer: {
                            _generatePointsByColumns: function() {
                                var that = this,
                                    columnsController = that._columnsController,
                                    columns = columnsController && that._columnsController.getVisibleColumns(),
                                    fixedColumns = columnsController && that._columnsController.getFixedColumns(),
                                    cells = that._columnHeadersView.getFixedColumnElements(),
                                    pointsByFixedColumns = [];
                                that.callBase();
                                if (cells && cells.length > 0) {
                                    pointsByFixedColumns = gridCore.getPointsByColumns(cells, function(point) {
                                        return that._pointCreated(point, cells.length, fixedColumns)
                                    });
                                    that._pointsByFixedColumns = normalizeColumnIndicesByPoints(columns, fixedColumns, pointsByFixedColumns)
                                }
                            },
                            _pointCreated: function(point, cellsLength, columns) {
                                var currentColumn, nextColumn;
                                if (point.index > 0 && point.index < cellsLength) {
                                    currentColumn = columns[point.columnIndex - 1] || {};
                                    nextColumn = columns[point.columnIndex] || {};
                                    if (currentColumn.fixed || nextColumn.fixed) {
                                        point.columnIndex -= 1;
                                        return !((currentColumn.allowResizing || "transparent" === currentColumn.command) && (nextColumn.allowResizing || "transparent" === nextColumn.command))
                                    }
                                }
                                return this.callBase.apply(this, arguments)
                            },
                            _getTargetPoint: function(pointsByColumns, currentX, deltaX) {
                                var boundingRect, $transparentColumn = this._columnHeadersView.getTransparentColumnElement();
                                if ($transparentColumn && $transparentColumn.length) {
                                    boundingRect = $transparentColumn.get(0).getBoundingClientRect();
                                    if (currentX <= boundingRect.left || currentX >= boundingRect.right) {
                                        return this.callBase(this._pointsByFixedColumns, currentX, deltaX)
                                    }
                                }
                                return this.callBase(pointsByColumns, currentX, deltaX)
                            }
                        },
                        keyboardNavigation: {
                            _scrollToElement: function($element) {
                                var focusedView = this.getFocusedView();
                                this.callBase($element, focusedView && focusedView.getFixedColumnsOffset())
                            }
                        }
                    }
                }()
            }
        })
    },
    /*!*********************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.adaptivity.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            gridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            Form = __webpack_require__( /*! ../form */ 276),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            DATAGRID_ADAPTIVE_NAMESPACE = "dxDataGridAdaptivity",
            DATAGRID_HIDDEN_COLUMNS_WIDTH = "adaptiveHidden",
            DATAGRID_ADAPTIVE_ROW_TYPE = "detailAdaptive",
            FORM_ITEM_CONTENT_CLASS = "dx-field-item-content",
            FORM_ITEM_MODIFIED = "dx-item-modified",
            DATAGRID_ADAPTIVE_COLUMN_CLASS = "dx-command-adaptive",
            DATAGRID_ADAPTIVE_DETAIL_ROW_CLASS = "dx-adaptive-detail-row",
            DATAGRID_ADAPTIVE_ITEM_TEXT_CLASS = "dx-adaptive-item-text",
            DATAGRID_EDIT_MODE_ROW = "row",
            DATAGRID_EDIT_MODE_FORM = "form",
            DATAGRID_ADAPTIVE_COLUMN_BUTTON_CLASS = "dx-datagrid-adaptive-more";

        function getColumnId(column) {
            return column.command ? "command:" + column.command : column.index
        }
        exports.AdaptiveColumnsController = gridCore.ViewController.inherit({
            _isRowEditMode: function() {
                var editMode = this._editingController.getEditMode();
                return editMode === DATAGRID_EDIT_MODE_ROW
            },
            _isFormEditMode: function() {
                var editMode = this._editingController.getEditMode();
                return editMode === DATAGRID_EDIT_MODE_FORM
            },
            _isItemModified: function(item, cellOptions) {
                var columnIndex = this._columnsController.getVisibleIndex(item.column.index),
                    rowIndex = this._dataController.getRowIndexByKey(cellOptions.key),
                    row = this._dataController.items()[rowIndex + 1];
                return row && row.modifiedValues && commonUtils.isDefined(row.modifiedValues[columnIndex])
            },
            _getFormViewTemplate: function(item, cellOptions) {
                var that = this,
                    column = item.column,
                    cellValue = column.calculateCellValue(cellOptions.data),
                    cellText = gridCore.formatValue(cellValue, column),
                    templateAdapter = column.cellTemplate ? function(options, $container) {
                        var templateOptions = $.extend({}, cellOptions, {
                            value: cellValue,
                            text: cellText
                        });
                        that._rowsView.renderTemplate($container, column.cellTemplate, templateOptions)
                    } : null;
                return templateAdapter || function(options, $container) {
                    var container = $container.get(0);
                    if (column.encodeHtml) {
                        container.textContent = cellText
                    } else {
                        container.innerHTML = cellText
                    }
                    $container.addClass(DATAGRID_ADAPTIVE_ITEM_TEXT_CLASS);
                    if (!commonUtils.isDefined(cellText) || "" === cellText) {
                        $container.html("&nbsp;")
                    }
                    if (!that._isRowEditMode()) {
                        if (that._isItemModified(item, cellOptions)) {
                            $container.addClass(FORM_ITEM_MODIFIED)
                        }
                    }
                }
            },
            _getTemplate: function(item, cellOptions) {
                var column = item.column,
                    editingController = this.getController("editing");
                if (this._isItemEdited(item) || column.showEditorAlways) {
                    return editingController.getFormEditorTemplate(cellOptions, column, item)
                } else {
                    return this._getFormViewTemplate(item, cellOptions)
                }
            },
            _isVisibleColumnsValid: function(visibleColumns) {
                var getCommandColumnsCount = function() {
                    var j, visibleColumn, result = 0;
                    for (j = 0; j < visibleColumns.length; j++) {
                        visibleColumn = visibleColumns[j];
                        if (visibleColumn.command) {
                            result++
                        }
                    }
                    return result
                };
                if (visibleColumns < 2) {
                    return false
                }
                if (visibleColumns.length - getCommandColumnsCount() <= 1) {
                    return false
                }
                return true
            },
            _calculatePercentWidths: function(widths, visibleColumns) {
                var that = this,
                    percentWidths = 0;
                visibleColumns.forEach(function(item, index) {
                    if (widths[index] !== DATAGRID_HIDDEN_COLUMNS_WIDTH) {
                        percentWidths += that._getItemPercentWidth(item)
                    }
                });
                return percentWidths
            },
            _isPercentWidth: function(width) {
                return commonUtils.isString(width) && "%" === width.slice(-1)
            },
            _getNotTruncatedColumnWidth: function(column, containerWidth, columnsCount, columnsCanFit) {
                var colWidth, columnId = getColumnId(column),
                    widthOption = this._columnsController.columnOption(columnId, "width"),
                    bestFitWidth = this._columnsController.columnOption(columnId, "bestFitWidth");
                if (widthOption && "auto" !== widthOption) {
                    if (this._isPercentWidth(widthOption)) {
                        var columnFitted = column.visibleIndex < columnsCount - 1 && columnsCanFit,
                            partialWidth = containerWidth * parseFloat(widthOption) / 100,
                            resultWidth = columnsCanFit && partialWidth < bestFitWidth ? bestFitWidth : partialWidth;
                        colWidth = columnFitted ? this.component.element().width() * parseFloat(widthOption) / 100 : resultWidth
                    } else {
                        return widthOption
                    }
                } else {
                    var columnAutoWidth = this.option("columnAutoWidth");
                    colWidth = columnAutoWidth || !!column.command ? bestFitWidth : containerWidth / columnsCount
                }
                var isTruncated = colWidth < bestFitWidth;
                return isTruncated ? null : colWidth
            },
            _getItemPercentWidth: function(item) {
                var result = 0;
                if (item.width && this._isPercentWidth(item.width)) {
                    result = parseFloat(item.width)
                }
                return result
            },
            _getCommandColumnsWidth: function() {
                var that = this,
                    columns = that._columnsController.getVisibleColumns(),
                    colWidth = 0;
                $.each(columns, function(index, column) {
                    if (column.index < 0 || column.command) {
                        colWidth += that._columnsController.columnOption(getColumnId(column), "bestFitWidth") || 0
                    }
                });
                return colWidth
            },
            _isItemEdited: function(item) {
                if (this._isFormEditMode()) {
                    return false
                }
                if (this._isRowEditMode()) {
                    var editRowKey = this._editingController.getEditRowKey();
                    if (gridCoreUtils.equalKeys(editRowKey, this._dataController.adaptiveExpandedKey())) {
                        return true
                    }
                } else {
                    var rowIndex = this._dataController.getRowIndexByKey(this._dataController.adaptiveExpandedKey()) + 1,
                        columnIndex = this._columnsController.getVisibleIndex(item.column.visibleIndex);
                    return this._editingController.isEditCell(rowIndex, columnIndex)
                }
            },
            _renderAdaptiveDetailRowPreparingAction: function(actionFunc) {
                var action = actionFunc || "onAdaptiveDetailRowPreparing";
                this.createAction(action)
            },
            _getFormItemsByHiddenColumns: function(hiddenColumns) {
                var items = [];
                $.each(hiddenColumns, function(_, column) {
                    items.push({
                        column: column,
                        name: column.name,
                        dataField: column.dataField,
                        visibleIndex: column.visibleIndex
                    })
                });
                return items
            },
            hideRedundantColumns: function(resultWidths, visibleColumns, hiddenQueue) {
                var visibleColumn, that = this;
                this._hiddenColumns = [];
                if (that._isVisibleColumnsValid(visibleColumns) && hiddenQueue.length) {
                    var percentWidths, columnsCanFit, i, needHideColumn, totalWidth = 0,
                        $rootElement = that.component.element(),
                        rootElementWidth = $rootElement.width() - that._getCommandColumnsWidth(),
                        contentColumns = visibleColumns.filter(function(item) {
                            return !item.command
                        }),
                        contentColumnCount = contentColumns.length;
                    do {
                        needHideColumn = false;
                        totalWidth = 0;
                        percentWidths = that._calculatePercentWidths(resultWidths, visibleColumns);
                        columnsCanFit = percentWidths < 100 && 0 !== percentWidths;
                        for (i = 0; i < visibleColumns.length; i++) {
                            visibleColumn = visibleColumns[i];
                            var columnWidth = that._getNotTruncatedColumnWidth(visibleColumn, rootElementWidth, contentColumnCount, columnsCanFit),
                                columnId = getColumnId(visibleColumn),
                                widthOption = that._columnsController.columnOption(columnId, "width"),
                                columnBestFitWidth = that._columnsController.columnOption(columnId, "bestFitWidth");
                            if (resultWidths[i] === DATAGRID_HIDDEN_COLUMNS_WIDTH) {
                                continue
                            }
                            if (!columnWidth && !visibleColumn.command && !visibleColumn.fixed) {
                                needHideColumn = true;
                                break
                            }
                            if (widthOption && "auto" !== widthOption) {
                                totalWidth += columnWidth
                            } else {
                                totalWidth += columnBestFitWidth || 0
                            }
                        }
                        needHideColumn = needHideColumn || totalWidth > $rootElement.width();
                        if (needHideColumn) {
                            var column = hiddenQueue.pop(),
                                visibleIndex = that._columnsController.getVisibleIndex(column.index);
                            resultWidths[visibleIndex] = DATAGRID_HIDDEN_COLUMNS_WIDTH;
                            contentColumnCount--;
                            this._hiddenColumns.push(column)
                        }
                    } while (needHideColumn && contentColumnCount > 1 && hiddenQueue.length);
                    if (contentColumnCount === contentColumns.length) {
                        resultWidths[resultWidths.length - 1] = DATAGRID_HIDDEN_COLUMNS_WIDTH
                    }
                } else {
                    visibleColumn = visibleColumns[visibleColumns.length - 1];
                    if (visibleColumn && "adaptive" === visibleColumn.command) {
                        resultWidths[resultWidths.length - 1] = DATAGRID_HIDDEN_COLUMNS_WIDTH
                    }
                }
            },
            getItemContentByColumnIndex: function(visibleColumnIndex) {
                var $itemContent, i, item;
                for (i = 0; i < this._$itemContents.length; i++) {
                    $itemContent = this._$itemContents.eq(i);
                    item = $itemContent.data("dx-form-item");
                    if (item && item.column && this._columnsController.getVisibleIndex(item.column.index) === visibleColumnIndex) {
                        return $itemContent
                    }
                }
            },
            toggleExpandAdaptiveDetailRow: function(key) {
                if (!(this._isFormEditMode() && this._editingController.isEditing())) {
                    this.getController("data").toggleExpandAdaptiveDetailRow(key)
                }
            },
            createFormByHiddenColumns: function($container, options) {
                var that = this,
                    userFormOptions = {
                        items: that._getFormItemsByHiddenColumns(that._hiddenColumns),
                        formID: new Guid
                    };
                this.executeAction("onAdaptiveDetailRowPreparing", {
                    formOptions: userFormOptions
                });
                that._$itemContents = null;
                that._form = that._createComponent($("<div>").appendTo($container), Form, $.extend({}, userFormOptions, {
                    customizeItem: function(item) {
                        var column = item.column || that._columnsController.columnOption(item.name || item.dataField);
                        if (column) {
                            item.label = item.label || {};
                            item.label.text = item.label.text || column.caption;
                            item.template = that._getTemplate(item, options, $.proxy(that.updateForm, that));
                            item.column = column
                        }
                        userFormOptions.customizeItem && userFormOptions.customizeItem.call(this, item)
                    },
                    onContentReady: function(e) {
                        userFormOptions.onContentReady && userFormOptions.onContentReady.call(this, e);
                        that._$itemContents = $container.find("." + FORM_ITEM_CONTENT_CLASS)
                    }
                }))
            },
            hasAdaptiveDetailRowExpanded: function() {
                return commonUtils.isDefined(this._dataController.adaptiveExpandedKey())
            },
            updateForm: function(hiddenColumns) {
                if (this.hasAdaptiveDetailRowExpanded()) {
                    if (this._form && commonUtils.isDefined(this._form._contentReadyAction)) {
                        if (hiddenColumns && hiddenColumns.length) {
                            this._form.option("items", this._getFormItemsByHiddenColumns(hiddenColumns))
                        } else {
                            this._form.repaint()
                        }
                    }
                }
            },
            updateHidingQueue: function(columns) {
                var columnsHasHidingPriority, i, that = this,
                    hideableColumns = columns.filter(function(column) {
                        return column.visible && !column.fixed && !(commonUtils.isDefined(column.groupIndex) && column.groupIndex >= 0)
                    });
                that._hidingColumnsQueue = [];
                for (i = 0; i < hideableColumns.length; i++) {
                    if (commonUtils.isDefined(hideableColumns[i].hidingPriority) && hideableColumns[i].hidingPriority >= 0) {
                        columnsHasHidingPriority = true;
                        that._hidingColumnsQueue[hideableColumns[i].hidingPriority] = hideableColumns[i]
                    }
                }
                if (columnsHasHidingPriority) {
                    that._hidingColumnsQueue.reverse()
                } else {
                    if (that.option("columnHidingEnabled")) {
                        for (i = 0; i < hideableColumns.length; i++) {
                            var visibleIndex = that._columnsController.columnOption(getColumnId(hideableColumns[i]), "visibleIndex");
                            that._hidingColumnsQueue[visibleIndex] = hideableColumns[i]
                        }
                    }
                }
                that._hidingColumnsQueue = that._hidingColumnsQueue.filter(Object);
                return that._hidingColumnsQueue
            },
            getHiddenColumns: function() {
                return this._hiddenColumns
            },
            hasHiddenColumns: function() {
                return this._hiddenColumns.length > 0
            },
            getHidingColumnsQueue: function() {
                return this._hidingColumnsQueue
            },
            init: function() {
                var that = this;
                that._columnsController = that.getController("columns");
                that._dataController = that.getController("data");
                that._rowsView = that.getView("rowsView");
                that._columnsController.addCommandColumn({
                    command: "adaptive",
                    visible: false,
                    cssClass: DATAGRID_ADAPTIVE_COLUMN_CLASS,
                    width: "auto"
                });
                that._columnsController.columnsChanged.add(function() {
                    var isAdaptiveVisible = !!that.updateHidingQueue(that._columnsController.getColumns()).length;
                    that._columnsController.columnOption("command:adaptive", "visible", isAdaptiveVisible, true)
                });
                that._editingController = that.getController("editing");
                that._hidingColumnsQueue = [];
                that._hiddenColumns = [];
                that._renderAdaptiveDetailRowPreparingAction();
                that.callBase()
            },
            optionChanged: function(args) {
                if ("onAdaptiveDetailRowPreparing" === args.name) {
                    this._renderAdaptiveDetailRowPreparingAction(args.value)
                }
                if ("columnHidingEnabled" === args.name) {
                    this._columnsController.columnOption("command:adaptive", "visible", args.value)
                }
                this.callBase(args)
            },
            publicMethods: function() {
                return ["isAdaptiveDetailRowExpanded", "expandAdaptiveDetailRow", "collapseAdaptiveDetailRow"]
            },
            isAdaptiveDetailRowExpanded: function(key) {
                return this._dataController.adaptiveExpandedKey() && gridCoreUtils.equalKeys(this._dataController.adaptiveExpandedKey(), key)
            },
            expandAdaptiveDetailRow: function(key) {
                if (!this.hasAdaptiveDetailRowExpanded()) {
                    this.toggleExpandAdaptiveDetailRow(key)
                }
            },
            collapseAdaptiveDetailRow: function() {
                if (this.hasAdaptiveDetailRowExpanded()) {
                    this.toggleExpandAdaptiveDetailRow()
                }
            }
        });
        gridCore.registerModule("adaptivity", {
            defaultOptions: function() {
                return {
                    columnHidingEnabled: false,
                    onAdaptiveDetailRowPreparing: null
                }
            },
            controllers: {
                adaptiveColumns: exports.AdaptiveColumnsController
            },
            extenders: {
                views: {
                    rowsView: {
                        _getCellTemplate: function(options) {
                            var that = this,
                                column = options.column;
                            if ("adaptive" === column.command && "groupFooter" !== options.rowType) {
                                return function(container) {
                                    $("<span/>").addClass(DATAGRID_ADAPTIVE_COLUMN_BUTTON_CLASS).on(eventUtils.addNamespace(clickEvent.name, DATAGRID_ADAPTIVE_NAMESPACE), that.createAction(function() {
                                        that._adaptiveColumnsController.toggleExpandAdaptiveDetailRow(options.key)
                                    })).appendTo(container)
                                }
                            }
                            if (options.rowType === DATAGRID_ADAPTIVE_ROW_TYPE && "detail" === column.command) {
                                return function(container, options) {
                                    that._adaptiveColumnsController.createFormByHiddenColumns(container, options)
                                }
                            }
                            return that.callBase(options)
                        },
                        _createRow: function(row) {
                            var $row = this.callBase(row);
                            if (row && row.rowType === DATAGRID_ADAPTIVE_ROW_TYPE && row.key === this._dataController.adaptiveExpandedKey()) {
                                $row.addClass(DATAGRID_ADAPTIVE_DETAIL_ROW_CLASS)
                            }
                            return $row
                        },
                        _getColumnIndexByElement: function($element) {
                            var $itemContent = $element.closest("." + FORM_ITEM_CONTENT_CLASS);
                            if ($itemContent.length && $itemContent.closest(this.component.element()).length) {
                                var formItem = $itemContent.length ? $itemContent.first().data("dx-form-item") : null;
                                return formItem && formItem.column && this._columnsController.getVisibleIndex(formItem.column.index)
                            } else {
                                return this.callBase($element)
                            }
                        },
                        getCellElement: function(rowIndex, columnIdentificator) {
                            var item = this._dataController.items()[rowIndex];
                            if (item && item.rowType === DATAGRID_ADAPTIVE_ROW_TYPE) {
                                return this._adaptiveColumnsController.getItemContentByColumnIndex(columnIdentificator)
                            } else {
                                return this.callBase(rowIndex, columnIdentificator)
                            }
                        },
                        isClickableElement: function($target) {
                            var isClickable = this.callBase ? this.callBase($target) : false;
                            return isClickable || !!$target.closest("." + DATAGRID_ADAPTIVE_COLUMN_CLASS).length
                        },
                        init: function() {
                            this.callBase();
                            this._adaptiveColumnsController = this.getController("adaptiveColumns")
                        }
                    }
                },
                controllers: {
                    "export": {
                        _updateColumnWidth: function(column, width) {
                            this.callBase(column, column.visibleWidth === DATAGRID_HIDDEN_COLUMNS_WIDTH ? column.bestFitWidth : width)
                        }
                    },
                    columnsResizer: {
                        _pointCreated: function(point, cellsLength, columns) {
                            var result = this.callBase(point, cellsLength, columns),
                                currentColumn = columns[point.columnIndex] || {},
                                nextColumnIndex = this._getNextColumnIndex(point.columnIndex),
                                nextColumn = columns[nextColumnIndex] || {},
                                hasHiddenColumnsOnly = nextColumnIndex !== point.columnIndex + 1 && nextColumn.command,
                                hasAdaptiveHiddenWidth = currentColumn.visibleWidth === DATAGRID_HIDDEN_COLUMNS_WIDTH || hasHiddenColumnsOnly;
                            return result || hasAdaptiveHiddenWidth
                        },
                        _getNextColumnIndex: function(currentColumnIndex) {
                            var visibleColumns = this._columnsController.getVisibleColumns(),
                                index = this.callBase(currentColumnIndex);
                            while (visibleColumns[index] && visibleColumns[index].visibleWidth === DATAGRID_HIDDEN_COLUMNS_WIDTH) {
                                index++
                            }
                            return index
                        }
                    },
                    draggingHeader: {
                        _pointCreated: function(point, columns, location, sourceColumn) {
                            var result = this.callBase(point, columns, location, sourceColumn),
                                column = columns[point.columnIndex] || {},
                                hasAdaptiveHiddenWidth = column.visibleWidth === DATAGRID_HIDDEN_COLUMNS_WIDTH;
                            return result || hasAdaptiveHiddenWidth
                        }
                    },
                    editing: {
                        _getFormEditItemTemplate: function(cellOptions, column) {
                            if (this.getEditMode() !== DATAGRID_EDIT_MODE_ROW && "detailAdaptive" === cellOptions.rowType) {
                                cellOptions.columnIndex = this._columnsController.getVisibleIndex(column.visibleIndex);
                                return this.getColumnTemplate(cellOptions)
                            }
                            return this.callBase(cellOptions, column)
                        },
                        _closeEditItem: function($targetElement) {
                            var $itemContents = $targetElement.closest("." + FORM_ITEM_CONTENT_CLASS),
                                rowIndex = this._dataController.getRowIndexByKey(this._dataController.adaptiveExpandedKey()) + 1,
                                formItem = $itemContents.length ? $itemContents.first().data("dx-form-item") : null,
                                columnIndex = formItem && formItem.column && this._columnsController.getVisibleIndex(formItem.column.index);
                            if (!this.isEditCell(rowIndex, columnIndex)) {
                                this.callBase($targetElement)
                            }
                        },
                        _beforeUpdateItems: function(rowIndices, rowIndex) {
                            if (this.getEditMode() !== DATAGRID_EDIT_MODE_FORM && this._adaptiveController.hasHiddenColumns()) {
                                var items = this._dataController.items(),
                                    item = items[rowIndex],
                                    oldExpandRowIndex = gridCoreUtils.getIndexByKey(this._dataController.adaptiveExpandedKey(), items);
                                this._isForceRowAdaptiveExpand = !this._adaptiveController.hasAdaptiveDetailRowExpanded();
                                if (oldExpandRowIndex >= 0 && rowIndex > oldExpandRowIndex) {
                                    this._editRowIndex--
                                }
                                if (oldExpandRowIndex >= 0) {
                                    rowIndices.push(oldExpandRowIndex + 1)
                                }
                                rowIndices.push(rowIndex + 1);
                                this._dataController.adaptiveExpandedKey(item.key)
                            }
                        },
                        _afterInsertRow: function(options) {
                            this.callBase(options);
                            if (this._adaptiveController.hasHiddenColumns()) {
                                this._adaptiveController.expandAdaptiveDetailRow(options.key);
                                this._isForceRowAdaptiveExpand = true
                            }
                        },
                        _collapseAdaptiveDetailRow: function() {
                            if (this.getEditMode() === DATAGRID_EDIT_MODE_ROW && this._isForceRowAdaptiveExpand) {
                                this._adaptiveController.collapseAdaptiveDetailRow();
                                this._isForceRowAdaptiveExpand = false
                            }
                        },
                        _cancelEditAdaptiveDetailRow: function() {
                            if (this._adaptiveController.hasHiddenColumns()) {
                                this._collapseAdaptiveDetailRow()
                            }
                        },
                        _afterSaveEditData: function() {
                            this.callBase();
                            this._cancelEditAdaptiveDetailRow()
                        },
                        _beforeCancelEditData: function() {
                            this.callBase();
                            this._cancelEditAdaptiveDetailRow()
                        },
                        _beforeCloseEditCellInBatchMode: function(rowIndices) {
                            var rowIndex, expandedKey = this._dataController._adaptiveExpandedKey;
                            if (expandedKey) {
                                rowIndex = gridCoreUtils.getIndexByKey(expandedKey, this._dataController.items());
                                if (rowIndex > -1) {
                                    rowIndices.unshift(rowIndex)
                                }
                            }
                        },
                        editRow: function(rowIndex) {
                            if (this.getEditMode() === DATAGRID_EDIT_MODE_FORM) {
                                this._adaptiveController.collapseAdaptiveDetailRow()
                            }
                            this.callBase(rowIndex)
                        },
                        init: function() {
                            this.callBase();
                            this._adaptiveController = this.getController("adaptiveColumns")
                        }
                    },
                    resizing: {
                        _isNeedToCalcBestFitWidths: function(needBestFit) {
                            return this.callBase(needBestFit) || this._adaptiveColumnsController.getHidingColumnsQueue().length
                        },
                        _correctColumnWidths: function(resultWidths, visibleColumns) {
                            var hiddenColumns, adaptiveController = this._adaptiveColumnsController,
                                oldHiddenColumns = adaptiveController.getHiddenColumns(),
                                hidingColumnsQueue = adaptiveController.updateHidingQueue(this._columnsController.getColumns());
                            adaptiveController.hideRedundantColumns(resultWidths, visibleColumns, hidingColumnsQueue);
                            hiddenColumns = adaptiveController.getHiddenColumns();
                            if (adaptiveController.hasAdaptiveDetailRowExpanded()) {
                                if (oldHiddenColumns.length !== hiddenColumns.length) {
                                    adaptiveController.updateForm(hiddenColumns)
                                }
                            }!hiddenColumns.length && adaptiveController.collapseAdaptiveDetailRow();
                            return this.callBase(resultWidths, visibleColumns)
                        },
                        init: function() {
                            this._adaptiveColumnsController = this.getController("adaptiveColumns");
                            this.callBase()
                        }
                    },
                    data: {
                        _processItems: function(items, changeType) {
                            var item, expandRowIndex, that = this;
                            items = that.callBase.apply(that, arguments);
                            if ("loadingAll" === changeType || !commonUtils.isDefined(that._adaptiveExpandedKey)) {
                                return items
                            }
                            expandRowIndex = gridCoreUtils.getIndexByKey(that._adaptiveExpandedKey, items);
                            if (expandRowIndex >= 0) {
                                item = items[expandRowIndex];
                                items.splice(expandRowIndex + 1, 0, {
                                    visible: true,
                                    rowType: DATAGRID_ADAPTIVE_ROW_TYPE,
                                    key: item.key,
                                    data: item.data,
                                    modifiedValues: item.modifiedValues,
                                    inserted: item.inserted,
                                    values: []
                                })
                            } else {
                                that._adaptiveExpandedKey = void 0
                            }
                            return items
                        },
                        adaptiveExpandedKey: function(value) {
                            if (commonUtils.isDefined(value)) {
                                this._adaptiveExpandedKey = value
                            } else {
                                return this._adaptiveExpandedKey
                            }
                        },
                        toggleExpandAdaptiveDetailRow: function(key) {
                            var that = this;
                            var oldExpandRowIndex = gridCoreUtils.getIndexByKey(that._adaptiveExpandedKey, that._items);
                            var newExpandRowIndex = gridCoreUtils.getIndexByKey(key, that._items);
                            if (oldExpandRowIndex >= 0 && oldExpandRowIndex === newExpandRowIndex) {
                                key = void 0;
                                newExpandRowIndex = -1
                            }
                            that._adaptiveExpandedKey = key;
                            if (oldExpandRowIndex >= 0) {
                                oldExpandRowIndex++
                            }
                            if (newExpandRowIndex >= 0) {
                                newExpandRowIndex++
                            }
                            that.updateItems({
                                changeType: "update",
                                rowIndices: [oldExpandRowIndex, newExpandRowIndex]
                            })
                        },
                        init: function() {
                            this.callBase();
                            this._adaptiveExpandedKey = void 0
                        }
                    }
                }
            }
        })
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/data_grid/ui.data_grid.export_controller.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            dataGridCore = __webpack_require__( /*! ./ui.data_grid.core */ 337),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            clientExporter = __webpack_require__( /*! ../../client_exporter */ 7),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            excelExporter = clientExporter.excel,
            Button = __webpack_require__( /*! ../button */ 196),
            List = __webpack_require__( /*! ../list */ 213),
            ContextMenu = __webpack_require__( /*! ../context_menu */ 327);
        var DATAGRID_EXPORT_MENU_CLASS = "dx-datagrid-export-menu",
            DATAGRID_EXPORT_BUTTON_CLASS = "dx-datagrid-export-button",
            DATAGRID_EXPORT_ICON = "export-to",
            DATAGRID_EXPORT_EXCEL_ICON = "exportxlsx",
            DATAGRID_EXPORT_SELECTED_ICON = "exportselected",
            DATAGRID_EXPORT_EXCEL_BUTTON_ICON = "export-excel-button";
        exports.DataProvider = Class.inherit({
            _getGroupValue: function(item) {
                var visibleIndex, groupColumn = this._options.groupColumns[item.groupIndex],
                    value = dataGridCore.getDisplayValue(groupColumn, item.values[item.groupIndex], item.data, item.rowType),
                    result = groupColumn.caption + ": " + dataGridCore.formatValue(value, groupColumn);
                visibleIndex = this._options.getVisibleIndex(groupColumn.index);
                if (item.summaryCells && item.summaryCells.length && item.summaryCells[visibleIndex].length) {
                    result += " " + dataGridCore.getGroupRowSummaryText(item.summaryCells[visibleIndex], this._options.summaryTexts)
                }
                return result
            },
            _correctCellIndex: function(cellIndex) {
                var startIndex = this._options.startValueIndex,
                    endIndex = this._options.endValueIndex;
                return cellIndex <= endIndex ? startIndex + cellIndex : null
            },
            _initOptions: function() {
                var exportController = this._exportController,
                    groupColumns = exportController._columnsController.getGroupColumns(),
                    startEndIndexes = exportController._getStartEndValueIndexces(exportController._columnsController.getVisibleColumns());
                this._options = {
                    columns: exportController._getColumns(),
                    groupColumns: groupColumns,
                    items: !!exportController._selectionOnly ? exportController._getSelectedItems() : exportController._getAllItems(),
                    getVisibleIndex: $.proxy(exportController._columnsController.getVisibleIndex, exportController._columnsController),
                    startValueIndex: startEndIndexes.startIndex,
                    endValueIndex: startEndIndexes.endIndex,
                    isHeadersVisible: exportController.option("showColumnHeaders"),
                    summaryTexts: exportController.option("summary.texts"),
                    customizeExportData: exportController.option("customizeExportData")
                }
            },
            ctor: function(exportController) {
                this._exportController = exportController
            },
            getColumns: function(getColumnsByAllRows) {
                var columns = this._options.columns;
                return getColumnsByAllRows ? columns : columns[columns.length - 1]
            },
            getRowsCount: function() {
                return this._options.items.length
            },
            getHeaderRowCount: function() {
                if (this.isHeadersVisible()) {
                    return this._options.columns.length - 1
                }
                return 0
            },
            isGroupRow: function(rowIndex) {
                return rowIndex < this._options.items.length && "group" === this._options.items[rowIndex].rowType
            },
            getGroupLevel: function(rowIndex) {
                var item = this._options.items[rowIndex],
                    groupIndex = item && item.groupIndex;
                if (item && "totalFooter" === item.rowType) {
                    return 0
                }
                return commonUtils.isDefined(groupIndex) ? groupIndex : this._options.groupColumns.length
            },
            getCellType: function(rowIndex, cellIndex) {
                var columns = this.getColumns();
                if (cellIndex < columns.length) {
                    var item = this._options.items.length && this._options.items[rowIndex],
                        column = columns[cellIndex];
                    if (item && "data" === item.rowType) {
                        if (isFinite(item.values[this._correctCellIndex(cellIndex)]) && !commonUtils.isDefined(column.customizeText)) {
                            return commonUtils.isDefined(column.lookup) ? column.lookup.dataType : column.dataType
                        }
                    }
                    return "string"
                }
            },
            ready: function() {
                var options, that = this;
                that._initOptions();
                options = this._options;
                return $.when(options.items).done(function(items) {
                    options.customizeExportData && options.customizeExportData(that.getColumns(that.getHeaderRowCount() > 1), items);
                    options.items = items
                })
            },
            getCellValue: function(rowIndex, cellIndex) {
                var column, value, i, summaryItems, itemValues, columns = this.getColumns(),
                    correctedCellIndex = this._correctCellIndex(cellIndex),
                    item = this._options.items.length && this._options.items[rowIndex];
                if (item) {
                    itemValues = item.values;
                    switch (item.rowType) {
                        case "groupFooter":
                        case "totalFooter":
                            if (correctedCellIndex < itemValues.length) {
                                value = itemValues[correctedCellIndex];
                                if (commonUtils.isDefined(value)) {
                                    return dataGridCore.getSummaryText(value, this._options.summaryTexts)
                                }
                            }
                            break;
                        case "group":
                            if (cellIndex < 1) {
                                return this._getGroupValue(item)
                            } else {
                                summaryItems = item.values[correctedCellIndex];
                                if (commonUtils.isArray(summaryItems)) {
                                    value = "";
                                    for (i = 0; i < summaryItems.length; i++) {
                                        value += (i > 0 ? " \n " : "") + dataGridCore.getSummaryText(summaryItems[i], this._options.summaryTexts)
                                    }
                                    return value
                                }
                            }
                            break;
                        default:
                            column = columns[cellIndex];
                            if (column) {
                                value = dataGridCore.getDisplayValue(column, itemValues[correctedCellIndex], item.data, item.rowType);
                                return !isFinite(value) || column.customizeText ? dataGridCore.formatValue(value, column) : value
                            }
                    }
                }
            },
            isHeadersVisible: function() {
                return this._options.isHeadersVisible
            },
            isTotalCell: function(rowIndex, cellIndex) {
                var items = this._options.items,
                    item = items[rowIndex],
                    correctCellIndex = this._correctCellIndex(cellIndex),
                    isSummaryAlignByColumn = item.summaryCells && item.summaryCells[correctCellIndex] && item.summaryCells[correctCellIndex].length > 0 && item.summaryCells[correctCellIndex][0].alignByColumn;
                return item && "groupFooter" === item.rowType || "totalFooter" === item.rowType || isSummaryAlignByColumn
            },
            getCellMerging: function(rowIndex, cellIndex) {
                var columns = this._options.columns,
                    column = columns[rowIndex] && columns[rowIndex][cellIndex];
                return column ? {
                    colspan: (column.colspan || 1) - 1,
                    rowspan: (column.rowspan || 1) - 1
                } : {
                    colspan: 0,
                    rowspan: 0
                }
            },
            getFrozenArea: function() {
                var that = this;
                return {
                    x: 0,
                    y: that.getHeaderRowCount()
                }
            }
        });
        exports.ExportController = dataGridCore.ViewController.inherit({}).include(gridCoreUtils.exportMixin).inherit({
            _getEmptyCell: function() {
                return {
                    caption: "",
                    colspan: 1,
                    rowspan: 1
                }
            },
            _updateColumnWidth: function(column, width) {
                column.width = width
            },
            _getColumns: function() {
                var i, j, column, columns, result = [],
                    columnsController = this._columnsController,
                    rowCount = columnsController.getRowCount(),
                    columnWidths = this._headersView && this._headersView.isVisible() ? this._headersView.getColumnWidths() : this._rowsView.getColumnWidths();
                for (i = 0; i <= rowCount; i++) {
                    result.push([]);
                    columns = columnsController.getVisibleColumns(i);
                    for (j = 0; j < columns.length; j++) {
                        column = $.extend({}, columns[j]);
                        if (!column.command) {
                            if (i === rowCount && columnWidths && columnWidths.length) {
                                this._updateColumnWidth(column, columnWidths[j])
                            }
                            result[i].push(column)
                        }
                    }
                }
                columns = result[rowCount];
                result = this._prepareItems(0, result.slice(0, -1));
                result.push(columns);
                return result
            },
            _getFooterSummaryItems: function(summaryCells, isTotal) {
                var values, itemslength, summaryCell, j, result = [],
                    estimatedItemsCount = 1,
                    i = 0;
                do {
                    values = [];
                    for (j = 0; j < summaryCells.length; j++) {
                        summaryCell = summaryCells[j];
                        itemslength = summaryCell.length;
                        if (estimatedItemsCount < itemslength) {
                            estimatedItemsCount = itemslength
                        }
                        values.push(summaryCell[i])
                    }
                    result.push({
                        values: values,
                        rowType: isTotal ? "totalFooter" : "groupFooter"
                    })
                } while (i++ < estimatedItemsCount - 1);
                return result
            },
            _hasSummaryGroupFooters: function() {
                var i, groupItems = this.option("summary.groupItems");
                if (commonUtils.isDefined(groupItems)) {
                    for (i = 0; i < groupItems.length; i++) {
                        if (groupItems[i].showInGroupFooter) {
                            return true
                        }
                    }
                }
                return false
            },
            _getItemsWithSummaryGroupFooters: function(sourceItems) {
                var item, i, result = [],
                    beforeGroupFooterItems = [],
                    groupFooterItems = [];
                for (i = 0; i < sourceItems.length; i++) {
                    item = sourceItems[i];
                    if ("groupFooter" === item.rowType) {
                        groupFooterItems = this._getFooterSummaryItems(item.summaryCells);
                        result = result.concat(beforeGroupFooterItems, groupFooterItems);
                        beforeGroupFooterItems = []
                    } else {
                        beforeGroupFooterItems.push(item)
                    }
                }
                return result.length ? result : beforeGroupFooterItems
            },
            _updateGroupValuesWithSummaryByColumn: function(sourceItems) {
                var item, summaryCells, summaryItem, groupColumnCount, k, j, i, summaryValues = [];
                for (i = 0; i < sourceItems.length; i++) {
                    item = sourceItems[i];
                    summaryCells = item.summaryCells;
                    if ("group" === item.rowType && summaryCells && summaryCells.length > 1) {
                        groupColumnCount = item.values.length;
                        for (j = 1; j < summaryCells.length; j++) {
                            for (k = 0; k < summaryCells[j].length; k++) {
                                summaryItem = summaryCells[j][k];
                                if (summaryItem && summaryItem.alignByColumn) {
                                    if (!commonUtils.isArray(summaryValues[j - groupColumnCount])) {
                                        summaryValues[j - groupColumnCount] = []
                                    }
                                    summaryValues[j - groupColumnCount].push(summaryItem)
                                }
                            }
                        }
                        if (summaryValues.length > 0) {
                            $.merge(item.values, summaryValues);
                            summaryValues = []
                        }
                    }
                }
            },
            _getAllItems: function(data) {
                var summaryCells, summaryItems, that = this,
                    d = $.Deferred(),
                    dataController = this.getController("data"),
                    footerItems = dataController.footerItems(),
                    totalItem = footerItems.length && footerItems[0],
                    summaryTotalItems = that.option("summary.totalItems");
                dataController.loadAll(data).done(function(sourceItems, totalAggregates) {
                    that._updateGroupValuesWithSummaryByColumn(sourceItems);
                    if (that._hasSummaryGroupFooters()) {
                        sourceItems = that._getItemsWithSummaryGroupFooters(sourceItems)
                    }
                    summaryCells = totalItem && totalItem.summaryCells;
                    if (commonUtils.isDefined(totalAggregates) && summaryTotalItems) {
                        summaryCells = dataController._getSummaryCells(summaryTotalItems, totalAggregates)
                    }
                    summaryItems = totalItem && that._getFooterSummaryItems(summaryCells, true);
                    if (summaryItems) {
                        sourceItems = sourceItems.concat(summaryItems)
                    }
                    d.resolve(sourceItems)
                }).fail(d.reject);
                return d
            },
            _getSelectedItems: function() {
                var selectionController = this.getController("selection"),
                    selectedRowData = selectionController.getSelectedRowsData();
                return this._getAllItems(selectedRowData)
            },
            _getStartEndValueIndexces: function(visibleColumns) {
                var i, startIndex, endIndex, visibleColumnslength = visibleColumns.length;
                for (i = 0; i < visibleColumnslength; i++) {
                    if (!commonUtils.isDefined(visibleColumns[i].command)) {
                        startIndex = i;
                        break
                    }
                }
                for (i = visibleColumnslength - 1; i >= 0; i--) {
                    if (!commonUtils.isDefined(visibleColumns[i].command)) {
                        endIndex = i;
                        break
                    }
                }
                return {
                    startIndex: startIndex,
                    endIndex: endIndex
                }
            },
            init: function() {
                this._columnsController = this.getController("columns");
                this._rowsView = this.getView("rowsView");
                this._headersView = this.getView("columnHeadersView");
                this.createAction("onExporting", {
                    excludeValidators: ["disabled", "readOnly"]
                });
                this.createAction("onExported", {
                    excludeValidators: ["disabled", "readOnly"]
                });
                this.createAction("onFileSaving", {
                    excludeValidators: ["disabled", "readOnly"]
                })
            },
            callbackNames: function() {
                return ["selectionOnlyChanged"]
            },
            getExportFormat: function() {
                return ["EXCEL"]
            },
            getDataProvider: function() {
                return new exports.DataProvider(this)
            },
            exportToExcel: function(selectionOnly) {
                var that = this,
                    excelWrapTextEnabled = this.option("export.excelWrapTextEnabled");
                that._selectionOnly = selectionOnly;
                clientExporter.export(that.component.getDataProvider(), {
                    fileName: that.option("export.fileName"),
                    proxyUrl: that.option("export.proxyUrl"),
                    format: "EXCEL",
                    wrapTextEnabled: commonUtils.isDefined(excelWrapTextEnabled) ? excelWrapTextEnabled : !!this.option("wordWrapEnabled"),
                    autoFilterEnabled: !!that.option("export.excelFilterEnabled"),
                    rtlEnabled: that.option("rtlEnabled"),
                    exportingAction: that.getAction("onExporting"),
                    exportedAction: that.getAction("onExported"),
                    fileSavingAction: that.getAction("onFileSaving")
                }, excelExporter.getData)
            },
            publicMethods: function() {
                return ["getDataProvider", "getExportFormat", "exportToExcel"]
            },
            selectionOnly: function(value) {
                if (commonUtils.isDefined(value)) {
                    this._isSelectedRows = value;
                    this.selectionOnlyChanged.fire()
                } else {
                    return this._isSelectedRows
                }
            }
        });
        dataGridCore.registerModule("export", {
            defaultOptions: function() {
                return {
                    "export": {
                        enabled: false,
                        fileName: "DataGrid",
                        excelFilterEnabled: false,
                        excelWrapTextEnabled: void 0,
                        proxyUrl: void 0,
                        allowExportSelectedData: false,
                        texts: {
                            exportTo: messageLocalization.format("dxDataGrid-exportTo"),
                            exportAll: messageLocalization.format("dxDataGrid-exportAll"),
                            exportSelectedRows: messageLocalization.format("dxDataGrid-exportSelectedRows")
                        }
                    }
                }
            },
            controllers: {
                "export": exports.ExportController
            },
            extenders: {
                controllers: {
                    editing: {
                        callbackNames: function() {
                            var callbackList = this.callBase();
                            return commonUtils.isDefined(callbackList) ? callbackList.push("editingChanged") : ["editingChanged"]
                        },
                        _updateEditButtons: function() {
                            this.callBase();
                            this.editingChanged.fire(this.hasChanges())
                        }
                    }
                },
                views: {
                    headerPanel: {
                        _getToolbarItems: function() {
                            var items = this.callBase();
                            return this._appendExportItems(items)
                        },
                        _appendExportItems: function(items) {
                            var that = this,
                                exportOptions = that.option("export");
                            if (exportOptions.enabled) {
                                var exportItems = [];
                                if (exportOptions.allowExportSelectedData) {
                                    exportItems.push({
                                        template: function(data, index, $container) {
                                            that._renderButton(data, $container);
                                            that._renderExportMenu($container)
                                        },
                                        menuItemTemplate: function(data, index, $container) {
                                            that._renderList(data, $container)
                                        },
                                        name: "export",
                                        allowExportSelected: true,
                                        location: "after",
                                        locateInMenu: "auto"
                                    })
                                } else {
                                    exportItems.push({
                                        template: function(data, index, $container) {
                                            that._renderButton(data, $container)
                                        },
                                        menuItemTemplate: function(data, index, $container) {
                                            that._renderButton(data, $container, true)
                                        },
                                        name: "export",
                                        location: "after",
                                        locateInMenu: "auto"
                                    })
                                }
                                items = items.concat(exportItems);
                                that._correctSearchPanelPosition(items)
                            }
                            return items
                        },
                        _renderButton: function(data, $container, withText) {
                            var that = this,
                                buttonOptions = that._getButtonOptions(data.allowExportSelected),
                                $buttonContainer = that._getButtonContainer().addClass(DATAGRID_EXPORT_BUTTON_CLASS).appendTo($container);
                            if (withText) {
                                $container.wrapInner("<div class='dx-toolbar-item-auto-hide'></div>").parent().addClass("dx-toolbar-menu-action dx-toolbar-menu-button dx-toolbar-hidden-button");
                                buttonOptions.text = buttonOptions.hint
                            }
                            that._createComponent($buttonContainer, Button, buttonOptions)
                        },
                        _renderList: function(data, $container) {
                            var that = this,
                                texts = that.option("export.texts"),
                                renderFakeButton = function(data, $container, iconName) {
                                    var $icon = $("<div />").addClass("dx-icon dx-icon-" + iconName),
                                        $text = $("<span class='dx-button-text'/>").text(data.text),
                                        $content = $("<div class='dx-button-content' />").append($icon).append($text),
                                        $button = $("<div class='dx-button dx-button-has-text dx-button-has-icon dx-datagrid-toolbar-button'>").append($content),
                                        $toolbarItem = $("<div class ='dx-toolbar-item-auto-hide' />").append($button);
                                    $container.append($toolbarItem).parent().addClass("dx-toolbar-menu-custom dx-toolbar-hidden-button")
                                },
                                items = [{
                                    template: function(data, index, $container) {
                                        renderFakeButton(data, $container, DATAGRID_EXPORT_EXCEL_ICON)
                                    },
                                    text: texts.exportAll
                                }, {
                                    template: function(data, index, $container) {
                                        renderFakeButton(data, $container, DATAGRID_EXPORT_SELECTED_ICON)
                                    },
                                    text: texts.exportSelectedRows,
                                    exportSelected: true
                                }];
                            that._createComponent($container, List, {
                                items: items,
                                onItemClick: function(e) {
                                    that._exportController.exportToExcel(e.itemData.exportSelected)
                                },
                                scrollingEnabled: false
                            })
                        },
                        _correctSearchPanelPosition: function(items) {
                            items.sort(function(itemA, itemB) {
                                var result = 0;
                                if ("searchPanel" === itemA.name || "columnChooser" === itemA.name && "searchPanel" !== itemB.name) {
                                    result = 1
                                } else {
                                    if ("searchPanel" === itemB.name) {
                                        result = -1
                                    }
                                }
                                return result
                            })
                        },
                        _renderExportMenu: function($buttonContainer) {
                            var that = this,
                                $button = $buttonContainer.find(".dx-button"),
                                texts = that.option("export.texts"),
                                menuItems = [{
                                    text: texts.exportAll,
                                    icon: DATAGRID_EXPORT_EXCEL_ICON
                                }, {
                                    text: texts.exportSelectedRows,
                                    exportSelected: true,
                                    icon: DATAGRID_EXPORT_SELECTED_ICON
                                }];
                            that._createComponent($("<div>").appendTo(that.component.element()), ContextMenu, {
                                alternativeInvocationMode: {
                                    enabled: true,
                                    invokingElement: $button
                                },
                                items: menuItems,
                                cssClass: DATAGRID_EXPORT_MENU_CLASS,
                                onItemClick: function(e) {
                                    that._exportController.exportToExcel(e.itemData.exportSelected)
                                },
                                target: $button,
                                position: {
                                    at: "left bottom",
                                    my: "left top",
                                    offset: "0 3",
                                    collision: "fit",
                                    boundary: that._$parent,
                                    boundaryOffset: "1 1"
                                }
                            })
                        },
                        _isExportButtonVisible: function() {
                            return this.option("export.enabled")
                        },
                        _getButtonOptions: function(allowExportSelected) {
                            var options, that = this,
                                texts = that.option("export.texts");
                            if (allowExportSelected) {
                                options = {
                                    hint: texts.exportTo,
                                    icon: DATAGRID_EXPORT_ICON,
                                    onClick: null
                                }
                            } else {
                                options = {
                                    hint: texts.exportAll,
                                    icon: DATAGRID_EXPORT_EXCEL_BUTTON_ICON,
                                    onClick: function() {
                                        that._exportController.exportToExcel()
                                    }
                                }
                            }
                            return options
                        },
                        optionChanged: function(args) {
                            this.callBase(args);
                            if ("export" === args.name) {
                                args.handled = true;
                                this._invalidate();
                                this._invalidateToolbarItems()
                            }
                        },
                        init: function() {
                            var that = this;
                            this.callBase();
                            this._exportController = this.getController("export");
                            this._editingController = this.getController("editing");
                            this._editingController.editingChanged.add(function(hasChanges) {
                                that.updateToolbarItemOption("export", "disabled", hasChanges)
                            })
                        },
                        isVisible: function() {
                            return this.callBase() || this._isExportButtonVisible()
                        }
                    }
                }
            }
        })
    },
    /*!**********************************!*\
      !*** ./Scripts/ui/pivot_grid.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./pivot_grid/ui.pivot_grid */ 384)
    },
    /*!************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            pivotGridUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            pivotGridDataController = __webpack_require__( /*! ./ui.pivot_grid.data_controller */ 386),
            PivotGridDataSource = __webpack_require__( /*! ./data_source */ 387),
            dataAreaNamespace = __webpack_require__( /*! ./ui.pivot_grid.data_area */ 391),
            headersArea = __webpack_require__( /*! ./ui.pivot_grid.headers_area */ 393),
            fieldsArea = __webpack_require__( /*! ./ui.pivot_grid.fields_area */ 394),
            PivotGridFieldChooser = __webpack_require__( /*! ./ui.pivot_grid.field_chooser */ 397),
            PivotGridFieldChooserBase = __webpack_require__( /*! ./ui.pivot_grid.field_chooser_base */ 395),
            ExportMixin = __webpack_require__( /*! ./ui.pivot_grid.export */ 398).ExportMixin,
            chartIntegrationMixin = __webpack_require__( /*! ./ui.pivot_grid.chart_integration */ 399),
            isDefined = commonUtils.isDefined,
            Popup = __webpack_require__( /*! ../popup */ 195),
            ContextMenu = __webpack_require__( /*! ../context_menu */ 327),
            DATA_AREA_CELL_CLASS = "dx-area-data-cell",
            ROW_AREA_CELL_CLASS = "dx-area-row-cell",
            COLUMN_AREA_CELL_CLASS = "dx-area-column-cell",
            DESCRIPTION_AREA_CELL_CLASS = "dx-area-description-cell",
            BORDERS_CLASS = "dx-pivotgrid-border",
            PIVOTGRID_CLASS = "dx-pivotgrid",
            ROW_LINES_CLASS = "dx-row-lines",
            BOTTOM_ROW_CLASS = "dx-bottom-row",
            BOTTOM_BORDER_CLASS = "dx-bottom-border",
            FIELDS_CONTAINER_CLASS = "dx-pivotgrid-fields-container",
            FIELDS_CLASS = "dx-area-fields",
            FIELD_CHOOSER_POPUP_CLASS = "dx-fieldchooser-popup",
            INCOMPRESSIBLE_FIELDS_CLASS = "dx-incompressible-fields",
            TR = "<tr>",
            TD = "<td>",
            DIV = "<div>",
            TEST_HEIGHT = 66666;

        function getArraySum(array) {
            var sum = 0;
            $.each(array, function(_, value) {
                sum += value || 0
            });
            return sum
        }

        function adjustSizeArray(sizeArray, space) {
            var delta = space / sizeArray.length;
            for (var i = 0; i < sizeArray.length; i++) {
                sizeArray[i] -= delta
            }
        }

        function subscribeToScrollEvent(area, handler) {
            area.off("scroll").off("stop").on("scroll", handler).on("stop", handler)
        }
        var scrollBarInfoCache = {};

        function getScrollBarInfo(rootElement, useNativeScrolling) {
            if (scrollBarInfoCache[useNativeScrolling]) {
                return scrollBarInfoCache[useNativeScrolling]
            }
            var scrollBarUseNative, scrollBarWidth = 0,
                options = {};
            var container = $(DIV).css({
                position: "absolute",
                visibility: "hidden",
                width: 100,
                height: 100
            }).appendTo(rootElement);
            var content = $("<p>").css({
                width: "100%",
                height: 200
            }).appendTo(container);
            if ("auto" !== useNativeScrolling) {
                options.useNative = !!useNativeScrolling;
                options.useSimulatedScrollbar = !useNativeScrolling
            }
            container.dxScrollable(options);
            scrollBarUseNative = container.dxScrollable("instance").option("useNative");
            scrollBarWidth = scrollBarUseNative ? container.width() - content.width() : 0;
            container.remove();
            scrollBarInfoCache[useNativeScrolling] = {
                scrollBarWidth: scrollBarWidth,
                scrollBarUseNative: scrollBarUseNative
            };
            return scrollBarInfoCache[useNativeScrolling]
        }

        function getCommonBorderWidth(elements, direction) {
            var outerSize = "width" === direction ? "outerWidth" : "outerHeight",
                width = 0;
            $.each(elements, function(_, elem) {
                width += elem[outerSize]() - elem[direction]()
            });
            return width
        }

        function clickedOnFieldsArea($targetElement) {
            return $targetElement.closest("." + FIELDS_CLASS).length || $targetElement.find("." + FIELDS_CLASS).length
        }
        var PivotGrid = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    scrolling: {
                        timeout: 300,
                        renderingThreshold: 150,
                        mode: "standard",
                        useNative: "auto",
                        removeInvisiblePages: true
                    },
                    encodeHtml: true,
                    dataSource: null,
                    activeStateEnabled: false,
                    fieldChooser: {
                        minWidth: 250,
                        minHeight: 250,
                        enabled: true,
                        layout: 0,
                        title: messageLocalization.format("dxPivotGrid-fieldChooserTitle"),
                        width: 600,
                        height: 600
                    },
                    onContextMenuPreparing: null,
                    allowSorting: false,
                    allowSortingBySummary: false,
                    allowFiltering: false,
                    allowExpandAll: false,
                    wordWrapEnabled: true,
                    fieldPanel: {
                        showColumnFields: true,
                        showFilterFields: true,
                        showDataFields: true,
                        showRowFields: true,
                        allowFieldDragging: true,
                        visible: false,
                        texts: {
                            columnFieldArea: messageLocalization.format("dxPivotGrid-columnFieldArea"),
                            rowFieldArea: messageLocalization.format("dxPivotGrid-rowFieldArea"),
                            filterFieldArea: messageLocalization.format("dxPivotGrid-filterFieldArea"),
                            dataFieldArea: messageLocalization.format("dxPivotGrid-dataFieldArea")
                        }
                    },
                    dataFieldArea: "column",
                    "export": {
                        enabled: false,
                        fileName: "PivotGrid",
                        proxyUrl: void 0
                    },
                    showRowTotals: true,
                    showRowGrandTotals: true,
                    showColumnTotals: true,
                    showColumnGrandTotals: true,
                    hideEmptySummaryCells: true,
                    showTotalsPrior: "none",
                    rowHeaderLayout: "standard",
                    loadPanel: {
                        enabled: true,
                        text: messageLocalization.format("Loading"),
                        width: 200,
                        height: 70,
                        showIndicator: true,
                        indicatorSrc: "",
                        showPane: true
                    },
                    texts: {
                        grandTotal: messageLocalization.format("dxPivotGrid-grandTotal"),
                        total: messageLocalization.getFormatter("dxPivotGrid-total"),
                        noData: messageLocalization.format("dxDataGrid-noDataText"),
                        showFieldChooser: messageLocalization.format("dxPivotGrid-showFieldChooser"),
                        expandAll: messageLocalization.format("dxPivotGrid-expandAll"),
                        collapseAll: messageLocalization.format("dxPivotGrid-collapseAll"),
                        sortColumnBySummary: messageLocalization.getFormatter("dxPivotGrid-sortColumnBySummary"),
                        sortRowBySummary: messageLocalization.getFormatter("dxPivotGrid-sortRowBySummary"),
                        removeAllSorting: messageLocalization.format("dxPivotGrid-removeAllSorting"),
                        exportToExcel: messageLocalization.format("dxDataGrid-exportToExcel")
                    },
                    onCellClick: null,
                    onCellPrepared: null,
                    showBorders: false,
                    stateStoring: {
                        enabled: false,
                        storageKey: null,
                        type: "localStorage",
                        customLoad: null,
                        customSave: null,
                        savingTimeout: 2e3
                    },
                    onExpandValueChanging: null,
                    renderCellCountLimit: 2e4,
                    onExporting: null,
                    onExported: null,
                    onFileSaving: null
                })
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    useNativeScrolling: {
                        since: "15.2",
                        alias: "scrolling.useNative"
                    }
                })
            },
            _getDataControllerOptions: function() {
                var that = this;
                return {
                    component: that,
                    dataSource: that.option("dataSource"),
                    texts: that.option("texts"),
                    showRowTotals: that.option("showRowTotals"),
                    showRowGrandTotals: that.option("showRowGrandTotals"),
                    showColumnTotals: that.option("showColumnTotals"),
                    showTotalsPrior: that.option("showTotalsPrior"),
                    showColumnGrandTotals: that.option("showColumnGrandTotals"),
                    dataFieldArea: that.option("dataFieldArea"),
                    rowHeaderLayout: that.option("rowHeaderLayout"),
                    hideEmptySummaryCells: that.option("hideEmptySummaryCells"),
                    onFieldsPrepared: function(fields) {
                        $.each(fields, function(index, field) {
                            $.each(["allowSorting", "allowSortingBySummary", "allowFiltering", "allowExpandAll"], function(_, optionName) {
                                if (void 0 === field[optionName]) {
                                    pivotGridUtils.setFieldProperty(field, optionName, that.option(optionName))
                                }
                            })
                        })
                    }
                }
            },
            _initDataController: function() {
                var that = this;
                that._dataController && that._dataController.dispose();
                that._dataController = new pivotGridDataController.DataController(that._getDataControllerOptions());
                that._dataController.changed.add(function() {
                    that._render();
                    that._trigger("onChanged")
                });
                that._dataController.scrollChanged.add(function(options) {
                    that._scrollLeft = options.left;
                    that._scrollTop = options.top
                });
                that._dataController.loadingChanged.add(function(isLoading, progress) {
                    that._updateLoading(progress)
                });
                var expandValueChanging = that.option("onExpandValueChanging");
                if (expandValueChanging) {
                    that._dataController.expandValueChanging.add(function(e) {
                        expandValueChanging(e)
                    })
                }
            },
            _init: function() {
                var that = this;
                that.callBase();
                that._initDataController();
                that._scrollLeft = that._scrollTop = null;
                that._initActions()
            },
            _initActions: function() {
                var that = this;
                that._actions = {
                    onChanged: that._createActionByOption("onChanged"),
                    onContextMenuPreparing: that._createActionByOption("onContextMenuPreparing"),
                    onCellClick: that._createActionByOption("onCellClick"),
                    onExporting: that._createActionByOption("onExporting"),
                    onExported: that._createActionByOption("onExported"),
                    onFileSaving: that._createActionByOption("onFileSaving"),
                    onCellPrepared: that._createActionByOption("onCellPrepared")
                }
            },
            _trigger: function(eventName, eventArg) {
                this._actions[eventName](eventArg)
            },
            _optionValuesEqual: function(name, oldValue, newValue) {
                if ("dataSource" === name && newValue instanceof PivotGridDataSource && oldValue instanceof PivotGridDataSource) {
                    return newValue === oldValue
                }
                return this.callBase.apply(this, arguments)
            },
            _optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "dataSource":
                    case "allowSorting":
                    case "allowFiltering":
                    case "allowExpandAll":
                    case "allowSortingBySummary":
                    case "scrolling":
                    case "stateStoring":
                        that._initDataController();
                        that._fieldChooserPopup.hide();
                        that._renderFieldChooser();
                        that._invalidate();
                        break;
                    case "texts":
                    case "showTotalsPrior":
                    case "showRowTotals":
                    case "showRowGrandTotals":
                    case "showColumnTotals":
                    case "showColumnGrandTotals":
                    case "hideEmptySummaryCells":
                    case "dataFieldArea":
                        that._dataController.updateViewOptions(that._getDataControllerOptions());
                        break;
                    case "useNativeScrolling":
                    case "encodeHtml":
                    case "renderCellCountLimit":
                        break;
                    case "rtlEnabled":
                        that.callBase(args);
                        that._renderFieldChooser();
                        that._renderContextMenu();
                        that._renderLoadPanel(that._dataArea.groupElement(), that.element());
                        that._invalidate();
                        break;
                    case "export":
                        that._renderDescriptionArea();
                        break;
                    case "onExpandValueChanging":
                        break;
                    case "onCellClick":
                    case "onContextMenuPreparing":
                    case "onExporting":
                    case "onExported":
                    case "onFileSaving":
                    case "onCellPrepared":
                        that._actions[args.name] = that._createActionByOption(args.name);
                        break;
                    case "fieldChooser":
                        that._renderFieldChooser();
                        that._renderDescriptionArea();
                        break;
                    case "loadPanel":
                        that._renderLoadPanel(that._dataArea.groupElement(), that.element());
                        that._invalidate();
                        break;
                    case "fieldPanel":
                        that._renderDescriptionArea();
                        that._invalidate();
                        break;
                    case "showBorders":
                        that._tableElement().toggleClass(BORDERS_CLASS, !!args.value);
                        that.updateDimensions();
                        break;
                    case "wordWrapEnabled":
                        that._tableElement().toggleClass("dx-word-wrap", !!args.value);
                        that.updateDimensions();
                        break;
                    case "rowHeaderLayout":
                        that._tableElement().find("." + ROW_AREA_CELL_CLASS).toggleClass("dx-area-tree-view", "tree" === args.value);
                        that._dataController.updateViewOptions(that._getDataControllerOptions());
                        break;
                    case "height":
                    case "width":
                        that._hasHeight = null;
                        that.callBase(args);
                        that.resize();
                        break;
                    default:
                        that.callBase(args)
                }
            },
            _updateScrollPosition: function(columnsArea, rowsArea, dataArea) {
                var scrollTop, scrollLeft, that = this,
                    scrolled = that._scrollTop || that._scrollLeft;
                if (rowsArea && !rowsArea.hasScroll() && that._hasHeight) {
                    that._scrollTop = null
                }
                if (columnsArea && !columnsArea.hasScroll()) {
                    that._scrollLeft = null
                }
                if (null !== that._scrollTop || null !== that._scrollLeft || scrolled) {
                    scrollTop = that._scrollTop || 0;
                    scrollLeft = that._scrollLeft || 0;
                    dataArea.scrollTo({
                        x: scrollLeft,
                        y: scrollTop
                    });
                    columnsArea.scrollTo(scrollLeft);
                    rowsArea.scrollTo(scrollTop);
                    that._dataController.updateWindowScrollPosition(that._scrollTop)
                }
            },
            _subscribeToEvents: function(columnsArea, rowsArea, dataArea) {
                var that = this,
                    scrollHandler = function(e) {
                        var scrollOffset = e.scrollOffset,
                            leftOffset = isDefined(scrollOffset.left) ? scrollOffset.left : that._scrollLeft,
                            topOffset = isDefined(scrollOffset.top) && that._hasHeight ? scrollOffset.top : that._scrollTop;
                        if ((that._scrollLeft || 0) !== (leftOffset || 0) || (that._scrollTop || 0) !== (topOffset || 0)) {
                            that._scrollLeft = leftOffset;
                            that._scrollTop = topOffset;
                            that._updateScrollPosition(columnsArea, rowsArea, dataArea);
                            if ("virtual" === that.option("scrolling.mode")) {
                                that._dataController.setViewportPosition(that._scrollLeft, that._scrollTop)
                            }
                        }
                    };
                $.each([columnsArea, rowsArea, dataArea], function(_, area) {
                    subscribeToScrollEvent(area, scrollHandler)
                });
                !that._hasHeight && that._dataController.subscribeToWindowScrollEvents(dataArea.groupElement())
            },
            _clean: $.noop,
            _needDelayResizing: function(cellsInfo) {
                var cellsCount = cellsInfo.length * (cellsInfo.length ? cellsInfo[0].length : 0);
                return cellsCount > this.option("renderCellCountLimit")
            },
            _renderFieldChooser: function() {
                var that = this,
                    container = that._pivotGridContainer,
                    fieldChooserOptions = that.option("fieldChooser") || {},
                    fieldChooserComponentOptions = {
                        layout: fieldChooserOptions.layout,
                        texts: fieldChooserOptions.texts || {},
                        dataSource: that.getDataSource(),
                        width: void 0,
                        height: void 0
                    },
                    popupOptions = {
                        shading: false,
                        title: fieldChooserOptions.title,
                        width: fieldChooserOptions.width,
                        height: fieldChooserOptions.height,
                        showCloseButton: true,
                        resizeEnabled: true,
                        minWidth: fieldChooserOptions.minWidth,
                        minHeight: fieldChooserOptions.minHeight,
                        onResize: function(e) {
                            e.component.content().dxPivotGridFieldChooser("updateDimensions")
                        },
                        onShown: function(e) {
                            that._createComponent(e.component.content(), PivotGridFieldChooser, fieldChooserComponentOptions)
                        }
                    };
                if (that._fieldChooserPopup) {
                    that._fieldChooserPopup.option(popupOptions);
                    that._fieldChooserPopup.content().dxPivotGridFieldChooser(fieldChooserComponentOptions)
                } else {
                    that._fieldChooserPopup = that._createComponent($(DIV).addClass(FIELD_CHOOSER_POPUP_CLASS).appendTo(container), Popup, popupOptions)
                }
            },
            _renderContextMenu: function() {
                var that = this,
                    $container = that._pivotGridContainer;
                if (that._contextMenu) {
                    that._contextMenu.element().remove()
                }
                that._contextMenu = that._createComponent($(DIV).appendTo($container), ContextMenu, {
                    onPositioning: function(actionArgs) {
                        var targetElement, args, items, event = actionArgs.jQueryEvent;
                        actionArgs.cancel = true;
                        if (!event) {
                            return
                        }
                        targetElement = event.target.cellIndex >= 0 ? event.target : $(event.target).closest("td").get(0);
                        if (!targetElement) {
                            return
                        }
                        args = that._createEventArgs(targetElement, event);
                        items = that._getContextMenuItems(args);
                        if (items) {
                            actionArgs.component.option("items", items);
                            actionArgs.cancel = false;
                            return
                        }
                    },
                    onItemClick: function(params) {
                        params.itemData.onItemClick && params.itemData.onItemClick(params)
                    },
                    cssClass: PIVOTGRID_CLASS,
                    target: that.element()
                })
            },
            _getContextMenuItems: function(e) {
                var that = this,
                    items = [],
                    texts = that.option("texts");
                if ("row" === e.area || "column" === e.area) {
                    var areaFields = e[e.area + "Fields"],
                        oppositeAreaFields = e["column" === e.area ? "rowFields" : "columnFields"],
                        field = e.cell.path && areaFields[e.cell.path.length - 1],
                        dataSource = that.getDataSource();
                    if (field && field.allowExpandAll && e.cell.path.length < e[e.area + "Fields"].length) {
                        items.push({
                            beginGroup: true,
                            icon: "none",
                            text: texts.expandAll,
                            onItemClick: function() {
                                dataSource.expandAll(field.index)
                            }
                        });
                        items.push({
                            text: texts.collapseAll,
                            icon: "none",
                            onItemClick: function() {
                                dataSource.collapseAll(field.index)
                            }
                        })
                    }
                    if (e.cell.isLast) {
                        var sortingBySummaryItemCount = 0;
                        $.each(oppositeAreaFields, function(index, field) {
                            if (!field.allowSortingBySummary) {
                                return
                            }
                            $.each(e.dataFields, function(dataIndex, dataField) {
                                if (isDefined(e.cell.dataIndex) && e.cell.dataIndex !== dataIndex) {
                                    return
                                }
                                var showDataFieldCaption = !isDefined(e.cell.dataIndex) && e.dataFields.length > 1,
                                    textFormat = "column" === e.area ? texts.sortColumnBySummary : texts.sortRowBySummary,
                                    checked = pivotGridUtils.findField(e.dataFields, field.sortBySummaryField) === dataIndex && (e.cell.path || []).join("/") === (field.sortBySummaryPath || []).join("/"),
                                    text = stringUtils.format(textFormat, showDataFieldCaption ? field.caption + " - " + dataField.caption : field.caption);
                                items.push({
                                    beginGroup: 0 === sortingBySummaryItemCount,
                                    icon: checked ? "desc" === field.sortOrder ? "sortdowntext" : "sortuptext" : "none",
                                    text: text,
                                    onItemClick: function() {
                                        dataSource.field(field.index, {
                                            sortBySummaryField: dataField.caption || dataField.dataField,
                                            sortBySummaryPath: e.cell.path,
                                            sortOrder: "desc" === field.sortOrder ? "asc" : "desc"
                                        });
                                        dataSource.load()
                                    }
                                });
                                sortingBySummaryItemCount++
                            })
                        });
                        $.each(oppositeAreaFields, function(index, field) {
                            if (!field.allowSortingBySummary || !isDefined(field.sortBySummaryField)) {
                                return
                            }
                            items.push({
                                beginGroup: 0 === sortingBySummaryItemCount,
                                icon: "none",
                                text: texts.removeAllSorting,
                                onItemClick: function() {
                                    $.each(oppositeAreaFields, function(index, field) {
                                        dataSource.field(field.index, {
                                            sortBySummaryField: void 0,
                                            sortBySummaryPath: void 0,
                                            sortOrder: void 0
                                        })
                                    });
                                    dataSource.load()
                                }
                            });
                            return false
                        })
                    }
                }
                if (that.option("fieldChooser.enabled")) {
                    items.push({
                        beginGroup: true,
                        icon: "columnchooser",
                        text: texts.showFieldChooser,
                        onItemClick: function() {
                            that._fieldChooserPopup.show()
                        }
                    })
                }
                if (that.option("export.enabled")) {
                    items.push({
                        beginGroup: true,
                        icon: "exportxlsx",
                        text: texts.exportToExcel,
                        onItemClick: function() {
                            that.exportToExcel()
                        }
                    })
                }
                e.items = items;
                that._trigger("onContextMenuPreparing", e);
                items = e.items;
                if (items && items.length) {
                    return items
                }
            },
            _createEventArgs: function(targetElement, jQueryEvent) {
                var that = this,
                    dataSource = that.getDataSource(),
                    args = {
                        rowFields: dataSource.getAreaFields("row"),
                        columnFields: dataSource.getAreaFields("column"),
                        dataFields: dataSource.getAreaFields("data"),
                        jQueryEvent: jQueryEvent
                    };
                if (clickedOnFieldsArea($(targetElement))) {
                    return $.extend(that._createFieldArgs(targetElement), args)
                } else {
                    return $.extend(that._createCellArgs(targetElement), args)
                }
            },
            _createFieldArgs: function(targetElement) {
                var field = $(targetElement).children().data("field"),
                    args = {
                        field: field
                    };
                return commonUtils.isDefined(field) ? args : {}
            },
            _createCellArgs: function(cellElement) {
                var $cellElement = $(cellElement),
                    columnIndex = cellElement.cellIndex,
                    rowIndex = cellElement.parentElement.rowIndex,
                    $table = $cellElement.closest("table"),
                    data = $table.data("data"),
                    cell = data && data[rowIndex] && data[rowIndex][columnIndex],
                    args = {
                        area: $table.data("area"),
                        rowIndex: rowIndex,
                        columnIndex: columnIndex,
                        cellElement: $cellElement,
                        cell: cell
                    };
                return args
            },
            _handleCellClick: function(e) {
                var that = this,
                    args = that._createEventArgs(e.currentTarget, e),
                    cell = args.cell;
                if (!cell || !args.area && (args.rowIndex || args.columnIndex)) {
                    return
                }
                that._trigger("onCellClick", args);
                cell && !args.cancel && isDefined(cell.expanded) && setTimeout(function() {
                    that._dataController[cell.expanded ? "collapseHeaderItem" : "expandHeaderItem"](args.area, cell.path)
                })
            },
            _getNoDataText: function() {
                return this.option("texts.noData")
            },
            _renderNoDataText: gridCoreUtils.renderNoDataText,
            _renderLoadPanel: gridCoreUtils.renderLoadPanel,
            _updateLoading: function(progress) {
                var loadPanelVisible, that = this,
                    isLoading = that._dataController.isLoading();
                if (!that._loadPanel) {
                    return
                }
                loadPanelVisible = that._loadPanel.option("visible");
                if (!loadPanelVisible) {
                    that._startLoadingTime = new Date
                }
                if (isLoading) {
                    if (progress) {
                        if (new Date - that._startLoadingTime >= 1e3) {
                            that._loadPanel.option("message", Math.floor(100 * progress) + "%")
                        }
                    } else {
                        that._loadPanel.option("message", that.option("loadPanel.text"))
                    }
                }
                clearTimeout(that._hideLoadingTimeoutID);
                if (loadPanelVisible && !isLoading) {
                    that._hideLoadingTimeoutID = setTimeout(function() {
                        that._loadPanel.option("visible", false)
                    })
                } else {
                    that._loadPanel.option("visible", isLoading)
                }
            },
            _renderDescriptionArea: function() {
                var that = this,
                    $element = that.element(),
                    $descriptionCell = $element.find("." + DESCRIPTION_AREA_CELL_CLASS),
                    $toolbarContainer = $(DIV).addClass("dx-pivotgrid-toolbar"),
                    fieldPanel = that.option("fieldPanel"),
                    $filterHeader = $element.find(".dx-filter-header"),
                    $columnHeader = $element.find(".dx-column-header");
                var $targetContainer;
                if (fieldPanel.visible && fieldPanel.showFilterFields) {
                    $targetContainer = $filterHeader
                } else {
                    if (fieldPanel.visible && (fieldPanel.showDataFields || fieldPanel.showColumnFields)) {
                        $targetContainer = $columnHeader
                    } else {
                        $targetContainer = $descriptionCell
                    }
                }
                $columnHeader.toggleClass(BOTTOM_BORDER_CLASS, !!(fieldPanel.visible && (fieldPanel.showDataFields || fieldPanel.showColumnFields)));
                $filterHeader.toggleClass(BOTTOM_BORDER_CLASS, !!(fieldPanel.visible && fieldPanel.showFilterFields));
                $descriptionCell.toggleClass("dx-pivotgrid-background", fieldPanel.visible && (fieldPanel.showDataFields || fieldPanel.showColumnFields || fieldPanel.showRowFields));
                that.element().find(".dx-pivotgrid-toolbar").remove();
                $toolbarContainer.prependTo($targetContainer);
                if (that.option("fieldChooser.enabled")) {
                    that._createComponent($(DIV).appendTo($toolbarContainer).addClass("dx-pivotgrid-field-chooser-button"), "dxButton", {
                        icon: "columnchooser",
                        hint: that.option("texts.showFieldChooser"),
                        onClick: function() {
                            that.getFieldChooserPopup().show()
                        }
                    })
                }
                if (that.option("export.enabled")) {
                    that._createComponent($(DIV).appendTo($toolbarContainer).addClass("dx-pivotgrid-export-button"), "dxButton", {
                        icon: "exportxlsx",
                        hint: that.option("texts.exportToExcel"),
                        onClick: function() {
                            that.exportToExcel()
                        }
                    })
                }
            },
            _detectHasContainerHeight: function() {
                var testElement, that = this,
                    element = that.element();
                if (commonUtils.isDefined(that._hasHeight) || element.is(":hidden")) {
                    return
                }
                that._pivotGridContainer.addClass("dx-hidden");
                testElement = $(DIV).height(TEST_HEIGHT);
                element.append(testElement);
                that._hasHeight = element.height() !== TEST_HEIGHT;
                that._pivotGridContainer.removeClass("dx-hidden");
                testElement.remove()
            },
            _renderHeaders: function(rowHeaderContainer, columnHeaderContainer, filterHeaderContainer, dataHeaderContainer) {
                var that = this,
                    dataSource = that.getDataSource(),
                    FieldsArea = fieldsArea.FieldsArea;
                that._rowFields = that._rowFields || new FieldsArea(that, "row");
                that._rowFields.render(rowHeaderContainer, dataSource.getAreaFields("row"));
                that._columnFields = that._columnFields || new FieldsArea(that, "column");
                that._columnFields.render(columnHeaderContainer, dataSource.getAreaFields("column"));
                that._filterFields = that._filterFields || new FieldsArea(that, "filter");
                that._filterFields.render(filterHeaderContainer, dataSource.getAreaFields("filter"));
                that._dataFields = that._dataFields || new FieldsArea(that, "data");
                that._dataFields.render(dataHeaderContainer, dataSource.getAreaFields("data"))
            },
            _createTableElement: function() {
                var that = this;
                return $("<table>").css({
                    width: "100%"
                }).toggleClass(BORDERS_CLASS, !!that.option("showBorders")).toggleClass("dx-word-wrap", !!that.option("wordWrapEnabled")).on(eventUtils.addNamespace(clickEvent.name, "dxPivotGrid"), "td", $.proxy(that, "_handleCellClick"))
            },
            _renderDataArea: function(dataAreaElement) {
                var that = this,
                    dataArea = that._dataArea || new dataAreaNamespace.DataArea(that);
                that._dataArea = dataArea;
                dataArea.render(dataAreaElement, that._dataController.getCellsInfo());
                return dataArea
            },
            _renderRowsArea: function(rowsAreaElement) {
                var that = this,
                    rowsArea = that._rowsArea || new headersArea.VerticalHeadersArea(that);
                that._rowsArea = rowsArea;
                rowsArea.render(rowsAreaElement, that._dataController.getRowsInfo());
                return rowsArea
            },
            _renderColumnsArea: function(columnsAreaElement) {
                var that = this,
                    columnsArea = that._columnsArea || new headersArea.HorizontalHeadersArea(that);
                that._columnsArea = columnsArea;
                columnsArea.render(columnsAreaElement, that._dataController.getColumnsInfo());
                return columnsArea
            },
            _renderContentImpl: function() {
                var columnsAreaElement, rowsAreaElement, dataAreaElement, tableElement, dataArea, rowsArea, columnsArea, rowHeaderContainer, columnHeaderContainer, filterHeaderContainer, dataHeaderContainer, updateHandler, that = this,
                    scrollBarInfo = getScrollBarInfo(that.element(), that.option("scrolling.useNative")),
                    isFirstDrawing = !that._pivotGridContainer;
                that._scrollBarWidth = scrollBarInfo.scrollBarWidth;
                that._scrollBarUseNative = scrollBarInfo.scrollBarUseNative;
                tableElement = !isFirstDrawing && that._tableElement();
                if (!tableElement) {
                    that.element().addClass(PIVOTGRID_CLASS).addClass(ROW_LINES_CLASS).addClass(FIELDS_CONTAINER_CLASS);
                    that._pivotGridContainer = $(DIV);
                    that._renderFieldChooser();
                    that._renderContextMenu();
                    columnsAreaElement = $(TD).addClass(COLUMN_AREA_CELL_CLASS);
                    rowsAreaElement = $(TD).addClass(ROW_AREA_CELL_CLASS);
                    dataAreaElement = $(TD).addClass(DATA_AREA_CELL_CLASS);
                    tableElement = that._createTableElement();
                    dataHeaderContainer = $(TD).addClass("dx-data-header");
                    filterHeaderContainer = $("<td colspan='2'>").addClass("dx-filter-header");
                    columnHeaderContainer = $(TD).addClass("dx-column-header");
                    rowHeaderContainer = $(TD).addClass(DESCRIPTION_AREA_CELL_CLASS);
                    $(TR).append(filterHeaderContainer).appendTo(tableElement);
                    $(TR).append(dataHeaderContainer).append(columnHeaderContainer).appendTo(tableElement);
                    $(TR).append(rowHeaderContainer).append(columnsAreaElement).appendTo(tableElement);
                    $(TR).addClass(BOTTOM_ROW_CLASS).append(rowsAreaElement).append(dataAreaElement).appendTo(tableElement);
                    that._pivotGridContainer.append(tableElement);
                    that.element().append(that._pivotGridContainer);
                    if ("tree" === that.option("rowHeaderLayout")) {
                        rowsAreaElement.addClass("dx-area-tree-view")
                    }
                }
                that._createComponent(that.element(), PivotGridFieldChooserBase, {
                    dataSource: that.getDataSource(),
                    allowFieldDragging: that.option("fieldPanel.allowFieldDragging")
                });
                that.element().addClass("dx-overflow-hidden");
                dataArea = that._renderDataArea(dataAreaElement);
                rowsArea = that._renderRowsArea(rowsAreaElement);
                columnsArea = that._renderColumnsArea(columnsAreaElement);
                dataArea.tableElement().prepend(columnsArea.headElement());
                if (isFirstDrawing) {
                    that._renderLoadPanel(dataArea.groupElement().parent(), that.element());
                    that._renderDescriptionArea();
                    rowsArea.processScroll();
                    columnsArea.processScroll()
                }
                updateHandler = function() {
                    that.updateDimensions().done(function() {
                        that._subscribeToEvents(columnsArea, rowsArea, dataArea);
                        that.element().removeClass("dx-overflow-hidden")
                    })
                };
                that._renderHeaders(rowHeaderContainer, columnHeaderContainer, filterHeaderContainer, dataHeaderContainer);
                if (that._needDelayResizing(that._dataController.getCellsInfo()) && isFirstDrawing) {
                    setTimeout(updateHandler)
                } else {
                    updateHandler()
                }
            },
            _fireContentReadyAction: function() {
                if (!this._dataController.isLoading()) {
                    this.callBase()
                }
            },
            getScrollPath: function(area) {
                var that = this;
                if ("column" === area) {
                    return that._columnsArea.getScrollPath(that._scrollLeft)
                } else {
                    return that._rowsArea.getScrollPath(that._scrollTop)
                }
            },
            getDataSource: function() {
                return this._dataController.getDataSource()
            },
            getFieldChooserPopup: function() {
                return this._fieldChooserPopup
            },
            hasScroll: function(area) {
                var that = this;
                return "column" === area ? that._columnsArea.hasScroll() : that._rowsArea.hasScroll()
            },
            _dimensionChanged: function() {
                this.updateDimensions()
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this.updateDimensions()
                }
            },
            _dispose: function() {
                var that = this;
                clearTimeout(that._hideLoadingTimeoutID);
                that.callBase.apply(that, arguments);
                if (that._dataController) {
                    that._dataController.dispose()
                }
            },
            _tableElement: function() {
                return this.element().find("table").first()
            },
            resize: function() {
                this.updateDimensions()
            },
            isReady: function() {
                return this.callBase() && !this._dataController.isLoading()
            },
            updateDimensions: function() {
                var groupWidth, groupHeight, dataAreaHeights, rowsAreaHeights, resultHeights, resultWidths, rowsAreaColumnWidths, bordersWidth, hasRowsScroll, hasColumnsScroll, elementWidth, columnsAreaHeight, descriptionCellHeight, columnsAreaRowHeights, rowHeights, columnsAreaRowCount, that = this,
                    tableElement = that._tableElement(),
                    rowsArea = that._rowsArea,
                    columnsArea = that._columnsArea,
                    dataArea = that._dataArea,
                    totalWidth = 0,
                    totalHeight = 0,
                    rowsAreaWidth = 0,
                    scrollBarWidth = that._scrollBarWidth || 0,
                    dataAreaCell = tableElement.find("." + DATA_AREA_CELL_CLASS),
                    rowAreaCell = tableElement.find("." + ROW_AREA_CELL_CLASS),
                    columnAreaCell = tableElement.find("." + COLUMN_AREA_CELL_CLASS),
                    descriptionCell = tableElement.find("." + DESCRIPTION_AREA_CELL_CLASS),
                    filterHeaderCell = tableElement.find(".dx-filter-header"),
                    rowFieldsHeader = that._rowFields,
                    needSynchronizeFieldPanel = rowFieldsHeader.isVisible() && "tree" !== that.option("rowHeaderLayout"),
                    d = $.Deferred();
                that._detectHasContainerHeight();
                if (!dataArea.headElement().length) {
                    dataArea.tableElement().prepend(columnsArea.headElement())
                }
                if (needSynchronizeFieldPanel) {
                    rowsArea.updateColspans(rowFieldsHeader.getColumnsCount());
                    rowsArea.tableElement().prepend(rowFieldsHeader.headElement())
                }
                tableElement.addClass(INCOMPRESSIBLE_FIELDS_CLASS);
                dataArea.reset();
                rowsArea.reset();
                columnsArea.reset();
                rowFieldsHeader.reset();
                commonUtils.deferUpdate(function() {
                    resultWidths = dataArea.getColumnsWidth();
                    rowHeights = rowsArea.getRowsHeight();
                    rowsAreaHeights = needSynchronizeFieldPanel ? rowHeights.slice(1) : rowHeights;
                    dataAreaHeights = dataArea.getRowsHeight();
                    descriptionCellHeight = descriptionCell.outerHeight() + (needSynchronizeFieldPanel ? rowHeights[0] : 0);
                    columnsAreaRowCount = that._dataController.getColumnsInfo().length;
                    resultHeights = pivotGridUtils.mergeArraysByMaxValue(rowsAreaHeights, dataAreaHeights.slice(columnsAreaRowCount));
                    columnsAreaRowHeights = dataAreaHeights.slice(0, columnsAreaRowCount);
                    columnsAreaHeight = getArraySum(columnsAreaRowHeights);
                    rowsAreaColumnWidths = rowsArea.getColumnsWidth();
                    if (that._hasHeight) {
                        bordersWidth = getCommonBorderWidth([columnAreaCell, dataAreaCell, tableElement, tableElement.find(".dx-column-header"), filterHeaderCell], "height");
                        groupHeight = that.element().height() - filterHeaderCell.height() - tableElement.find(".dx-data-header").height() - (Math.max(dataArea.headElement().height(), columnAreaCell.height(), descriptionCellHeight) + bordersWidth)
                    }
                    totalWidth = dataArea.tableElement().width();
                    totalHeight = getArraySum(resultHeights);
                    rowsAreaWidth = getArraySum(rowsAreaColumnWidths);
                    elementWidth = that.element().width();
                    bordersWidth = getCommonBorderWidth([rowAreaCell, dataAreaCell, tableElement], "width");
                    groupWidth = elementWidth - rowsAreaWidth - bordersWidth;
                    hasRowsScroll = that._hasHeight && totalHeight - groupHeight >= 1;
                    hasColumnsScroll = totalWidth - groupWidth >= 1;
                    if (!hasRowsScroll) {
                        groupHeight = totalHeight + (hasColumnsScroll ? scrollBarWidth : 0)
                    }
                    commonUtils.deferRender(function() {
                        columnsArea.tableElement().append(dataArea.headElement());
                        rowFieldsHeader.tableElement().append(rowsArea.headElement());
                        if (!hasColumnsScroll && hasRowsScroll && scrollBarWidth) {
                            adjustSizeArray(resultWidths, scrollBarWidth)
                        }
                        if (descriptionCellHeight > columnsAreaHeight) {
                            adjustSizeArray(columnsAreaRowHeights, columnsAreaHeight - descriptionCellHeight);
                            columnsArea.setRowsHeight(columnsAreaRowHeights)
                        }
                        tableElement.removeClass(INCOMPRESSIBLE_FIELDS_CLASS);
                        columnsArea.groupWidth(groupWidth);
                        columnsArea.processScrollBarSpacing(hasRowsScroll ? scrollBarWidth : 0);
                        columnsArea.setColumnsWidth(resultWidths);
                        rowsArea.groupHeight(that._hasHeight ? groupHeight : "auto");
                        rowsArea.processScrollBarSpacing(hasColumnsScroll ? scrollBarWidth : 0);
                        rowsArea.setColumnsWidth(rowsAreaColumnWidths);
                        rowsArea.setRowsHeight(resultHeights);
                        dataArea.setColumnsWidth(resultWidths);
                        dataArea.setRowsHeight(resultHeights);
                        dataArea.groupWidth(groupWidth);
                        dataArea.groupHeight(that._hasHeight ? groupHeight : "auto");
                        needSynchronizeFieldPanel && rowFieldsHeader.setColumnsWidth(rowsAreaColumnWidths);
                        dataAreaCell.toggleClass(BOTTOM_BORDER_CLASS, !(hasRowsScroll || scrollBarWidth));
                        rowAreaCell.toggleClass(BOTTOM_BORDER_CLASS, !(hasRowsScroll && !scrollBarWidth));
                        if (!that._hasHeight && elementWidth !== that.element().width()) {
                            var diff = elementWidth - that.element().width();
                            if (!hasColumnsScroll) {
                                adjustSizeArray(resultWidths, diff);
                                columnsArea.setColumnsWidth(resultWidths);
                                dataArea.setColumnsWidth(resultWidths)
                            }
                            dataArea.groupWidth(groupWidth - diff);
                            columnsArea.groupWidth(groupWidth - diff)
                        }
                        if ("virtual" === that.option("scrolling.mode") && !that._dataController.isEmpty()) {
                            var virtualContentParams = that._dataController.calculateVirtualContentParams({
                                contentWidth: totalWidth,
                                contentHeight: totalHeight,
                                rowCount: resultHeights.length,
                                columnCount: resultWidths.length,
                                viewportWidth: groupWidth,
                                viewportHeight: that._hasHeight ? groupHeight : $(window).outerHeight()
                            });
                            dataArea.setVirtualContentParams({
                                top: virtualContentParams.contentTop,
                                left: virtualContentParams.contentLeft,
                                width: virtualContentParams.width,
                                height: virtualContentParams.height
                            });
                            rowsArea.setVirtualContentParams({
                                top: virtualContentParams.contentTop,
                                width: rowsAreaWidth,
                                height: virtualContentParams.height
                            });
                            columnsArea.setVirtualContentParams({
                                left: virtualContentParams.contentLeft,
                                width: virtualContentParams.width,
                                height: columnsArea.groupElement().height()
                            })
                        }
                        $.each([columnsArea, rowsArea, dataArea], function(_, area) {
                            area && area.updateScrollable()
                        });
                        commonUtils.deferRender(function() {
                            that._updateScrollPosition(columnsArea, rowsArea, dataArea)
                        });
                        dataArea.processScroll(that._scrollBarUseNative);
                        that._updateLoading();
                        that._renderNoDataText(dataArea.groupElement());
                        that._testResultWidths = resultWidths;
                        that._testResultHeights = resultHeights;
                        d.resolve()
                    })
                });
                return d
            },
            applyPartialDataSource: function(area, path, dataSource) {
                this._dataController.applyPartialDataSource(area, path, dataSource)
            }
        }).inherit(ExportMixin).include(chartIntegrationMixin);
        registerComponent("dxPivotGrid", PivotGrid);
        module.exports = PivotGrid
    },
    /*!******************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.utils.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            formatHelper = __webpack_require__( /*! ../../format_helper */ 55);
        exports.setFieldProperty = function(field, property, value, isInitialization) {
            var initProperties = field._initProperties = field._initProperties || {},
                initValue = isInitialization ? value : field[property];
            if (!initProperties.hasOwnProperty(property) || isInitialization) {
                initProperties[property] = initValue
            }
            field[property] = value
        };
        exports.sendRequest = function(options) {
            return $.ajax(options)
        };
        var foreachTreeAsyncDate = new Date;

        function createForeachTreeFunc(isAsync) {
            var foreachTreeFunc = function(items, callback, parentAtFirst, members, index, isChildrenProcessing) {
                members = members || [];
                items = items || [];
                var item, i, deferred, childrenDeferred;
                index = index || 0;

                function createForeachTreeAsyncHandler(deferred, i, isChildrenProcessing) {
                    $.when(foreachTreeFunc(items, callback, parentAtFirst, members, i, isChildrenProcessing)).done(deferred.resolve)
                }
                for (i = index; i < items.length; i++) {
                    if (isAsync && i > index && i % 1e4 === 0 && new Date - foreachTreeAsyncDate >= 300) {
                        foreachTreeAsyncDate = new Date;
                        deferred = $.Deferred();
                        setTimeout(createForeachTreeAsyncHandler(deferred, i, false), 0);
                        return deferred
                    }
                    item = items[i];
                    if (!isChildrenProcessing) {
                        members.unshift(item);
                        if (parentAtFirst && false === callback(members, i)) {
                            return
                        }
                        if (item.children) {
                            childrenDeferred = foreachTreeFunc(item.children, callback, parentAtFirst, members);
                            if (isAsync && childrenDeferred) {
                                deferred = $.Deferred();
                                childrenDeferred.done(createForeachTreeAsyncHandler(deferred, i, true));
                                return deferred
                            }
                        }
                    }
                    isChildrenProcessing = false;
                    if (!parentAtFirst && false === callback(members, i)) {
                        return
                    }
                    members.shift();
                    if (items[i] !== item) {
                        i--
                    }
                }
            };
            return foreachTreeFunc
        }
        exports.foreachTree = createForeachTreeFunc(false);
        exports.foreachTreeAsync = createForeachTreeFunc(true);
        exports.findField = function(fields, id) {
            var i, field;
            if (fields && commonUtils.isDefined(id)) {
                for (i = 0; i < fields.length; i++) {
                    field = fields[i];
                    if (field.name === id || field.caption === id || field.dataField === id || field.index === id) {
                        return i
                    }
                }
            }
            return -1
        };
        exports.formatValue = function(value, options) {
            var formatObject = {
                value: value,
                valueText: formatHelper.format(value, options.format, options.precision) || ""
            };
            return options.customizeText ? options.customizeText.call(options, formatObject) : formatObject.valueText
        };
        exports.getCompareFunction = function(valueSelector) {
            return function(a, b) {
                var result = 0;
                if (valueSelector(a) > valueSelector(b)) {
                    result = 1
                } else {
                    if (valueSelector(a) < valueSelector(b)) {
                        result = -1
                    }
                }
                return result
            }
        };
        exports.createPath = function(items) {
            var i, result = [];
            for (i = items.length - 1; i >= 0; i--) {
                result.push(items[i].key || items[i].value)
            }
            return result
        };
        exports.foreachDataLevel = function foreachDataLevel(data, callback, index, childrenField) {
            var item, i;
            index = index || 0;
            childrenField = childrenField || "children";
            if (data.length) {
                callback(data, index)
            }
            for (i = 0; i < data.length; i++) {
                item = data[i];
                if (item[childrenField] && item[childrenField].length) {
                    foreachDataLevel(item[childrenField], callback, index + 1, childrenField)
                }
            }
        };
        exports.mergeArraysByMaxValue = function(values1, values2) {
            var i, result = [];
            for (i = 0; i < values1.length; i++) {
                result.push(Math.max(values1[i] || 0, values2[i] || 0))
            }
            return result
        }
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.data_controller.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            stringUtils = __webpack_require__( /*! ../../core/utils/string */ 13),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            virtualScrolling = __webpack_require__( /*! ../grid_core/ui.grid_core.virtual_scrolling */ 366),
            stateStoring = __webpack_require__( /*! ../grid_core/ui.grid_core.state_storing */ 353),
            PivotGridDataSource = __webpack_require__( /*! ./data_source */ 387),
            pivotGridUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            foreachTree = pivotGridUtils.foreachTree,
            foreachTreeAsync = pivotGridUtils.foreachTreeAsync,
            createPath = pivotGridUtils.createPath,
            formatValue = pivotGridUtils.formatValue,
            math = Math,
            GRAND_TOTAL_TYPE = "GT",
            TOTAL_TYPE = "T",
            DATA_TYPE = "D";
        var proxyMethod = function(instance, methodName, defaultResult) {
            if (!instance[methodName]) {
                instance[methodName] = function() {
                    var dataSource = this._dataSource;
                    return dataSource ? dataSource[methodName].apply(dataSource, arguments) : defaultResult
                }
            }
        };
        exports.DataController = Class.inherit(function() {
            function getHeaderItemText(item, description, options) {
                var text = item.text;
                if (commonUtils.isDefined(item.displayText)) {
                    text = item.displayText
                } else {
                    if (commonUtils.isDefined(item.caption)) {
                        text = item.caption
                    } else {
                        if (item.type === GRAND_TOTAL_TYPE) {
                            text = options.texts.grandTotal
                        }
                    }
                }
                if (item.isAdditionalTotal) {
                    text = stringUtils.format(options.texts.total || "", text)
                }
                return text
            }
            var createHeaderInfo = function() {
                var getHeaderItemsDepth = function(headerItems) {
                    var depth = 0;
                    foreachTree(headerItems, function(items) {
                        depth = math.max(depth, items.length)
                    });
                    return depth
                };
                var createInfoItem = function(headerItem, breadth, isHorizontal, isTree) {
                    var infoItem = {
                        type: headerItem.type,
                        text: headerItem.text
                    };
                    if (headerItem.path) {
                        infoItem.path = headerItem.path
                    }
                    if (headerItem.width) {
                        infoItem.width = headerItem.width
                    }
                    if (commonUtils.isDefined(headerItem.wordWrapEnabled)) {
                        infoItem.wordWrapEnabled = headerItem.wordWrapEnabled
                    }
                    if (headerItem.isLast) {
                        infoItem.isLast = true
                    }
                    if (headerItem.sorted) {
                        infoItem.sorted = true
                    }
                    if (headerItem.isMetric) {
                        infoItem.dataIndex = headerItem.dataIndex
                    }
                    if (commonUtils.isDefined(headerItem.expanded)) {
                        infoItem.expanded = headerItem.expanded
                    }
                    if (breadth > 1) {
                        infoItem[isHorizontal ? "colspan" : "rowspan"] = breadth
                    }
                    if (headerItem.depthSize && headerItem.depthSize > 1) {
                        infoItem[isHorizontal ? "rowspan" : "colspan"] = headerItem.depthSize
                    }
                    if (headerItem.index >= 0) {
                        infoItem.dataSourceIndex = headerItem.index
                    }
                    if (isTree && headerItem.children && headerItem.children.length && !headerItem.children[0].isMetric) {
                        infoItem.width = null;
                        infoItem.isWhiteSpace = true
                    }
                    return infoItem
                };
                var addInfoItem = function(info, options) {
                    var itemInfo, breadth = options.lastIndex - options.index || 1,
                        addInfoItemCore = function(info, infoItem, itemIndex, depthIndex, isHorizontal) {
                            var index = isHorizontal ? depthIndex : itemIndex;
                            while (!info[index]) {
                                info.push([])
                            }
                            if (isHorizontal) {
                                info[index].push(infoItem)
                            } else {
                                info[index].unshift(infoItem)
                            }
                        };
                    itemInfo = createInfoItem(options.headerItem, breadth, options.isHorizontal, options.isTree);
                    addInfoItemCore(info, itemInfo, options.index, options.depth, options.isHorizontal);
                    if (!options.headerItem.children || 0 === options.headerItem.children.length) {
                        return options.lastIndex + 1
                    }
                    return options.lastIndex
                };
                var isItemSorted = function(items, sortBySummaryPath) {
                    var path, item = items[0],
                        stringValuesUsed = commonUtils.isString(sortBySummaryPath[0]),
                        headerItem = item.dataIndex >= 0 ? items[1] : item;
                    if (stringValuesUsed && sortBySummaryPath[0].indexOf("&[") !== -1 && headerItem.key || !headerItem.key) {
                        path = createPath(items)
                    } else {
                        path = $.map(items, function(item) {
                            return item.dataIndex >= 0 ? item.value : item.text
                        }).reverse()
                    }
                    if (item.type === GRAND_TOTAL_TYPE) {
                        path = path.slice(1)
                    }
                    return path.join("/") === sortBySummaryPath.join("/")
                };
                var getViewHeaderItems = function(headerItems, headerDescriptions, cellDescriptions, depthSize, options) {
                    var cellDescriptionsCount = cellDescriptions.length,
                        viewHeaderItems = options.showData ? createViewHeaderItems(headerItems, headerDescriptions) : [],
                        d = $.Deferred();
                    $.when(viewHeaderItems).done(function(viewHeaderItems) {
                        options.notifyProgress(.5);
                        if (options.showGrandTotals || 0 === headerDescriptions.length) {
                            viewHeaderItems[!options.showTotalsPrior ? "push" : "unshift"]({
                                type: GRAND_TOTAL_TYPE,
                                isEmpty: options.isEmptyGrandTotal
                            })
                        }
                        if (false !== options.showTotals || "tree" === options.layout) {
                            addAdditionalTotalHeaderItems(viewHeaderItems, headerDescriptions, options.showTotalsPrior, "tree" === options.layout)
                        }
                        $.when(foreachTreeAsync(viewHeaderItems, function(items) {
                            var item = items[0];
                            if (!item.children || 0 === item.children.length) {
                                item.depthSize = depthSize - items.length + 1
                            }
                        })).done(function() {
                            if (cellDescriptionsCount > 1) {
                                addMetricHeaderItems(viewHeaderItems, cellDescriptions, options.hiddenGrandTotals, options.hiddenTotals)
                            }!options.showEmpty && removeHiddenItems(viewHeaderItems);
                            var columnIndex = 0;
                            options.notifyProgress(.75);
                            $.when(foreachTreeAsync(viewHeaderItems, function(items) {
                                var item = items[0],
                                    isMetric = item.isMetric,
                                    field = headerDescriptions[items.length - 1] || {};
                                if (item.type === DATA_TYPE && !isMetric) {
                                    item.width = field.width
                                }
                                if (isMetric) {
                                    item.wordWrapEnabled = cellDescriptions[item.dataIndex].wordWrapEnabled
                                } else {
                                    item.wordWrapEnabled = field.wordWrapEnabled
                                }
                                item.isLast = !item.children || !item.children.length;
                                if (item.isLast) {
                                    $.each(options.sortBySummaryPaths, function(index, sortBySummaryPath) {
                                        if (!commonUtils.isDefined(item.dataIndex)) {
                                            sortBySummaryPath = sortBySummaryPath.slice(0);
                                            sortBySummaryPath.pop()
                                        }
                                        if (isItemSorted(items, sortBySummaryPath)) {
                                            item.sorted = true;
                                            return false
                                        }
                                    });
                                    columnIndex++
                                }
                                item.text = getHeaderItemText(item, field, options)
                            })).done(function() {
                                if (!viewHeaderItems.length) {
                                    viewHeaderItems.push({})
                                }
                                options.notifyProgress(1);
                                d.resolve(viewHeaderItems)
                            })
                        })
                    });
                    return d
                };

                function createHeaderItem(childrenStack, depth, index) {
                    var parent = childrenStack[depth] = childrenStack[depth] || [],
                        node = parent[index] = {};
                    if (childrenStack[depth + 1]) {
                        node.children = childrenStack[depth + 1];
                        childrenStack.length = depth + 1
                    }
                    return node
                }

                function createViewHeaderItems(headerItems, headerDescriptions) {
                    var headerItem, headerDescriptionsCount = headerDescriptions && headerDescriptions.length || 0,
                        childrenStack = [],
                        d = $.Deferred();
                    $.when(foreachTreeAsync(headerItems, function(items, index) {
                        var item = items[0],
                            path = createPath(items);
                        headerItem = createHeaderItem(childrenStack, path.length, index);
                        headerItem.type = DATA_TYPE;
                        headerItem.value = item.value;
                        headerItem.path = path;
                        headerItem.text = item.text;
                        headerItem.index = item.index;
                        headerItem.displayText = item.displayText;
                        headerItem.key = item.key;
                        headerItem.isEmpty = item.isEmpty;
                        if (path.length < headerDescriptionsCount && (!item.children || 0 !== item.children.length)) {
                            headerItem.expanded = !!item.children
                        }
                    })).done(function() {
                        d.resolve(createHeaderItem(childrenStack, 0, 0).children || [])
                    });
                    return d
                }
                var addMetricHeaderItems = function(headerItems, cellDescriptions, hiddenGrandTotals, hiddenTotals) {
                    foreachTree(headerItems, function(items) {
                        var i, item = items[0];
                        if (!item.children || 0 === item.children.length) {
                            item.children = [];
                            for (i = 0; i < cellDescriptions.length; i++) {
                                if (cellDescriptions.length) {
                                    if (item.type === GRAND_TOTAL_TYPE && $.inArray(i, hiddenGrandTotals) !== -1 || item.type !== GRAND_TOTAL_TYPE && $.inArray(i, hiddenTotals) !== -1) {
                                        continue
                                    }
                                }
                                item.children.push({
                                    caption: cellDescriptions[i].caption,
                                    path: item.path,
                                    type: item.type,
                                    value: i,
                                    index: item.index,
                                    dataIndex: i,
                                    isMetric: true,
                                    isEmpty: item.isEmpty && item.isEmpty[i]
                                })
                            }
                        }
                    })
                };
                var addAdditionalTotalHeaderItems = function(headerItems, headerDescriptions, showTotalsPrior, isTree) {
                    showTotalsPrior = showTotalsPrior || isTree;
                    foreachTree(headerItems, function(items, index) {
                        var item = items[0],
                            parentChildren = (items[1] ? items[1].children : headerItems) || [],
                            dataField = headerDescriptions[items.length - 1];
                        if (item.type === DATA_TYPE && item.expanded && (false !== dataField.showTotals || isTree)) {
                            index !== -1 && parentChildren.splice(showTotalsPrior ? index : index + 1, 0, $.extend({}, item, {
                                children: null,
                                type: TOTAL_TYPE,
                                expanded: showTotalsPrior ? true : null,
                                isAdditionalTotal: true
                            }));
                            if (showTotalsPrior) {
                                item.expanded = null
                            }
                        }
                    })
                };
                var removeEmptyParent = function(items, index) {
                    var parent = items[index + 1];
                    if (!items[index].children.length && parent && parent.children) {
                        parent.children.splice($.inArray(items[index], parent.children), 1);
                        removeEmptyParent(items, index + 1)
                    }
                };
                var removeHiddenItems = function(headerItems) {
                    foreachTree([{
                        children: headerItems
                    }], function(items, index) {
                        var item = items[0],
                            parentChildren = (items[1] ? items[1].children : headerItems) || [];
                        if (item && !item.children && (item.isEmpty && item.isEmpty.length ? item.isEmpty[0] : item.isEmpty)) {
                            parentChildren.splice(index, 1);
                            removeEmptyParent(items, 1)
                        }
                    })
                };
                var fillHeaderInfo = function(info, viewHeaderItems, depthSize, isHorizontal, isTree) {
                    var index, depth, lastIndex = 0,
                        indexesByDepth = [0];
                    foreachTree(viewHeaderItems, function(items) {
                        var headerItem = items[0];
                        depth = headerItem.isMetric ? depthSize : items.length - 1;
                        while (indexesByDepth.length - 1 < depth) {
                            indexesByDepth.push(indexesByDepth[indexesByDepth.length - 1])
                        }
                        index = indexesByDepth[depth] || 0;
                        lastIndex = addInfoItem(info, {
                            headerItem: headerItem,
                            index: index,
                            lastIndex: lastIndex,
                            depth: depth,
                            isHorizontal: isHorizontal,
                            isTree: isTree
                        });
                        indexesByDepth.length = depth;
                        indexesByDepth.push(lastIndex)
                    })
                };
                return function(headerItems, headerDescriptions, cellDescriptions, isHorizontal, options) {
                    var info = [],
                        depthSize = getHeaderItemsDepth(headerItems) || 1,
                        d = $.Deferred();
                    getViewHeaderItems(headerItems, headerDescriptions, cellDescriptions, depthSize, options).done(function(viewHeaderItems) {
                        fillHeaderInfo(info, viewHeaderItems, depthSize, isHorizontal, "tree" === options.layout);
                        options.notifyProgress(1);
                        d.resolve(info)
                    });
                    return d
                }
            }();

            function createSortPaths(headerFields, dataFields) {
                var sortBySummaryPaths = [];
                $.each(headerFields, function(index, headerField) {
                    var fieldIndex = pivotGridUtils.findField(dataFields, headerField.sortBySummaryField);
                    if (fieldIndex >= 0) {
                        sortBySummaryPaths.push((headerField.sortBySummaryPath || []).concat([fieldIndex]))
                    }
                });
                return sortBySummaryPaths
            }

            function foreachRowInfo(rowsInfo, callback) {
                var columnOffset = 0,
                    columnOffsetResetIndexes = [];
                for (var i = 0; i < rowsInfo.length; i++) {
                    for (var j = 0; j < rowsInfo[i].length; j++) {
                        var rowSpanOffset = (rowsInfo[i][j].rowspan || 1) - 1,
                            visibleIndex = i + rowSpanOffset;
                        if (columnOffsetResetIndexes[i]) {
                            columnOffset -= columnOffsetResetIndexes[i];
                            columnOffsetResetIndexes[i] = 0
                        }
                        if (false === callback(rowsInfo[i][j], visibleIndex, i, j, columnOffset)) {
                            break
                        }
                        columnOffsetResetIndexes[i + (rowsInfo[i][j].rowspan || 1)] = (columnOffsetResetIndexes[i + (rowsInfo[i][j].rowspan || 1)] || 0) + 1;
                        columnOffset++
                    }
                }
            }

            function foreachColumnInfo(info, callback, rowIndex, offsets, columnCount, lastProcessedIndexes) {
                rowIndex = rowIndex || 0;
                offsets = offsets || [];
                lastProcessedIndexes = lastProcessedIndexes || [];
                offsets[rowIndex] = offsets[rowIndex] || 0;
                var row = info[rowIndex],
                    startIndex = lastProcessedIndexes[rowIndex] + 1 || 0,
                    processedColumnCount = 0;
                if (!row) {
                    return
                }
                for (var colIndex = startIndex; colIndex < row.length; colIndex++) {
                    var cell = row[colIndex],
                        visibleIndex = colIndex + offsets[rowIndex],
                        colspan = cell.colspan || 1;
                    foreachColumnInfo(info, callback, rowIndex + (cell.rowspan || 1), offsets, colspan, lastProcessedIndexes);
                    offsets[rowIndex] += colspan - 1;
                    processedColumnCount += colspan;
                    if (cell.rowspan) {
                        for (var i = rowIndex + 1; i < rowIndex + cell.rowspan; i++) {
                            offsets[i] = offsets[i] || 0;
                            offsets[i] += cell.colspan || 1
                        }
                    }
                    if (false === callback(cell, visibleIndex, rowIndex, colIndex)) {
                        break
                    }
                    if (void 0 !== columnCount && processedColumnCount >= columnCount) {
                        break
                    }
                }
                lastProcessedIndexes[rowIndex] = colIndex
            }

            function createCellsInfo(rowsInfo, columnsInfo, data, dataFields, dataFieldArea) {
                var info = [],
                    dataFieldAreaInRows = "row" === dataFieldArea,
                    dataSourceCells = data.values;
                dataSourceCells.length && foreachRowInfo(rowsInfo, function(rowInfo, rowIndex) {
                    var row = info[rowIndex] = [],
                        dataRow = dataSourceCells[rowInfo.dataSourceIndex >= 0 ? rowInfo.dataSourceIndex : data.grandTotalRowIndex] || [];
                    rowInfo.isLast && foreachColumnInfo(columnsInfo, function(columnInfo, columnIndex) {
                        var dataIndex = (dataFieldAreaInRows ? rowInfo.dataIndex : columnInfo.dataIndex) || 0,
                            dataField = dataFields[dataIndex];
                        if (columnInfo.isLast && dataField) {
                            var cellValue, cell = dataRow[columnInfo.dataSourceIndex >= 0 ? columnInfo.dataSourceIndex : data.grandTotalColumnIndex];
                            if (!$.isArray(cell)) {
                                cell = [cell]
                            }
                            cellValue = cell[dataIndex];
                            row[columnIndex] = {
                                text: formatValue(cellValue, dataField),
                                value: cellValue,
                                format: dataField.format,
                                precision: dataField.precision,
                                dataType: dataField.dataType,
                                columnType: columnInfo.type,
                                rowType: rowInfo.type,
                                rowPath: rowInfo.path || [],
                                columnPath: columnInfo.path || [],
                                dataIndex: dataIndex
                            };
                            if (dataField.width) {
                                row[columnIndex].width = dataField.width
                            }
                        }
                    })
                });
                return info
            }

            function getHeaderIndexedItems(headerItems, maxDepth, options) {
                var visibleIndex = 0,
                    indexedItems = [];
                foreachTree(headerItems, function(items) {
                    var headerItem = items[0],
                        path = createPath(items);
                    if (headerItem.children && false === options.showTotals) {
                        return
                    }
                    var indexedItem = $.extend(true, {}, headerItem, {
                        visibleIndex: visibleIndex++,
                        path: path
                    });
                    if (commonUtils.isDefined(indexedItem.index)) {
                        indexedItems[indexedItem.index] = indexedItem
                    } else {
                        indexedItems.push(indexedItem)
                    }
                });
                return indexedItems
            }

            function createScrollController(dataController, component, dataAdapter) {
                if (component && "virtual" === component.option("scrolling.mode")) {
                    return new virtualScrolling.VirtualScrollController(component, $.extend({
                        hasKnownLastPage: function() {
                            return true
                        },
                        pageCount: function() {
                            return math.ceil(this.totalItemsCount() / this.pageSize())
                        },
                        updateLoading: function() {},
                        itemsCount: function() {
                            if (this.pageIndex() < this.pageCount() - 1) {
                                return this.pageSize()
                            } else {
                                this.totalItemsCount() % this.pageSize()
                            }
                        },
                        items: function() {
                            return []
                        },
                        viewportItems: function(items) {
                            return []
                        },
                        onChanged: function(e) {},
                        isLoading: function() {
                            return dataController.isLoading()
                        },
                        changingDuration: function() {
                            return dataController._changingDuration || 0
                        }
                    }, dataAdapter))
                }
            }

            function getHiddenTotals(dataFields) {
                var result = [];
                $.each(dataFields, function(index, field) {
                    if (false === field.showTotals) {
                        result.push(index)
                    }
                });
                return result
            }

            function getHiddenGrandTotalsTotals(dataFields, columnFields) {
                var result = [];
                $.each(dataFields, function(index, field) {
                    if (false === field.showGrandTotals) {
                        result.push(index)
                    }
                });
                if (0 === columnFields.length && result.length === dataFields.length) {
                    result = []
                }
                return result
            }
            var members = {
                ctor: function(options) {
                    var that = this,
                        virtualScrollControllerChanged = $.proxy(that._fireChanged, that);
                    options = that._options = options || {};
                    that._dataSource = that._createDataSource(options);
                    that._rowsScrollController = createScrollController(that, options.component, {
                        totalItemsCount: function() {
                            return that.totalRowCount()
                        },
                        pageIndex: function(index) {
                            return that.rowPageIndex(index)
                        },
                        pageSize: function() {
                            return that.rowPageSize()
                        },
                        load: function() {
                            if (that._rowsScrollController.pageIndex() >= this.pageCount()) {
                                that._rowsScrollController.pageIndex(this.pageCount() - 1)
                            }
                            return that._rowsScrollController.handleDataChanged(virtualScrollControllerChanged)
                        }
                    });
                    that._columnsScrollController = createScrollController(that, options.component, {
                        totalItemsCount: function() {
                            return that.totalColumnCount()
                        },
                        pageIndex: function(index) {
                            return that.columnPageIndex(index)
                        },
                        pageSize: function() {
                            return that.columnPageSize()
                        },
                        load: function() {
                            if (that._columnsScrollController.pageIndex() >= this.pageCount()) {
                                that._columnsScrollController.pageIndex(this.pageCount() - 1)
                            }
                            return that._columnsScrollController.handleDataChanged(virtualScrollControllerChanged)
                        }
                    });
                    that._stateStoringController = new stateStoring.StateStoringController(options.component).init();
                    that._columnsInfo = [];
                    that._rowsInfo = [];
                    that._cellsInfo = [];
                    that.expandValueChanging = $.Callbacks();
                    that.loadingChanged = $.Callbacks();
                    that.scrollChanged = $.Callbacks();
                    that.load();
                    that._update();
                    that.changed = $.Callbacks()
                },
                _fireChanged: function() {
                    var that = this,
                        startChanging = new Date;
                    that.changed && !that._lockChanged && that.changed.fire();
                    that._changingDuration = new Date - startChanging
                },
                load: function() {
                    var that = this,
                        stateStoringController = this._stateStoringController;
                    if (stateStoringController.isEnabled() && !stateStoringController.isLoaded()) {
                        stateStoringController.load().always(function(state) {
                            if (state) {
                                that._dataSource.state(state)
                            } else {
                                that._dataSource.load()
                            }
                        })
                    } else {
                        that._dataSource.load()
                    }
                },
                calculateVirtualContentParams: function(contentParams) {
                    var oldColumnViewportItemSize, oldRowViewportItemSize, newLeftPosition, newTopPosition, that = this,
                        rowsScrollController = that._rowsScrollController,
                        columnsScrollController = that._columnsScrollController,
                        rowViewportItemSize = contentParams.contentHeight / contentParams.rowCount,
                        columnViewportItemSize = contentParams.contentWidth / contentParams.columnCount;
                    if (rowsScrollController && columnsScrollController) {
                        oldColumnViewportItemSize = columnsScrollController.viewportItemSize();
                        oldRowViewportItemSize = rowsScrollController.viewportItemSize();
                        rowsScrollController.viewportItemSize(rowViewportItemSize);
                        columnsScrollController.viewportItemSize(columnViewportItemSize);
                        rowsScrollController.viewportSize(contentParams.viewportHeight / rowsScrollController.viewportItemSize());
                        rowsScrollController.setContentSize(contentParams.contentHeight);
                        columnsScrollController.viewportSize(contentParams.viewportWidth / columnsScrollController.viewportItemSize());
                        columnsScrollController.setContentSize(contentParams.contentWidth);
                        columnsScrollController.loadIfNeed();
                        rowsScrollController.loadIfNeed();
                        newLeftPosition = columnsScrollController.getViewportPosition() * columnViewportItemSize / oldColumnViewportItemSize;
                        newTopPosition = rowsScrollController.getViewportPosition() * rowViewportItemSize / oldRowViewportItemSize;
                        that.setViewportPosition(newLeftPosition, newTopPosition);
                        that.scrollChanged.fire({
                            left: newLeftPosition,
                            top: newTopPosition
                        });
                        return {
                            contentTop: rowsScrollController.getContentOffset(),
                            contentLeft: columnsScrollController.getContentOffset(),
                            width: columnsScrollController.getVirtualContentSize(),
                            height: rowsScrollController.getVirtualContentSize()
                        }
                    }
                },
                setViewportPosition: function(left, top) {
                    this._rowsScrollController.setViewportPosition(top || 0);
                    this._columnsScrollController.setViewportPosition(left || 0)
                },
                subscribeToWindowScrollEvents: function($element) {
                    this._rowsScrollController && this._rowsScrollController.subscribeToWindowScrollEvents($element)
                },
                updateWindowScrollPosition: function(position) {
                    this._rowsScrollController && this._rowsScrollController.scrollTo(position)
                },
                updateViewOptions: function(options) {
                    $.extend(this._options, options);
                    this._update()
                },
                _handleExpandValueChanging: function(e) {
                    this.expandValueChanging.fire(e)
                },
                _handleLoadingChanged: function(isLoading, progress) {
                    this.loadingChanged.fire(isLoading, progress)
                },
                _handleFieldsPrepared: function(e) {
                    this._options.onFieldsPrepared && this._options.onFieldsPrepared(e)
                },
                _createDataSource: function(options) {
                    var dataSource, that = this,
                        dataSourceOptions = options.dataSource;
                    that._isSharedDataSource = dataSourceOptions instanceof PivotGridDataSource;
                    if (that._isSharedDataSource) {
                        dataSource = dataSourceOptions
                    } else {
                        dataSource = new PivotGridDataSource(dataSourceOptions)
                    }
                    that._changedHandler = $.proxy(that, "_update");
                    that._expandValueChangingHandler = $.proxy(that, "_handleExpandValueChanging");
                    that._loadingChangedHandler = $.proxy(that, "_handleLoadingChanged");
                    that._fieldsPreparedHandler = $.proxy(that, "_handleFieldsPrepared");
                    dataSource.on("changed", that._changedHandler);
                    dataSource.on("expandValueChanging", that._expandValueChangingHandler);
                    dataSource.on("loadingChanged", that._loadingChangedHandler);
                    dataSource.on("fieldsPrepared", that._fieldsPreparedHandler);
                    return dataSource
                },
                getDataSource: function() {
                    return this._dataSource
                },
                isLoading: function() {
                    return this._dataSource.isLoading()
                },
                beginLoading: function() {
                    this._dataSource._changeLoadingCount(1)
                },
                endLoading: function() {
                    this._dataSource._changeLoadingCount(-1)
                },
                isEmpty: function() {
                    var dataFields = this._dataSource.getAreaFields("data"),
                        data = this._dataSource.getData();
                    return !dataFields.length || !data.values.length
                },
                _update: function() {
                    var that = this,
                        dataSource = that._dataSource,
                        options = that._options,
                        columnFields = dataSource.getAreaFields("column"),
                        rowFields = dataSource.getAreaFields("row"),
                        dataFields = dataSource.getAreaFields("data"),
                        dataFieldsForRows = "row" === options.dataFieldArea ? dataFields : [],
                        dataFieldsForColumns = "row" !== options.dataFieldArea ? dataFields : [],
                        data = dataSource.getData(),
                        hiddenTotals = getHiddenTotals(dataFields),
                        hiddenGrandTotals = getHiddenGrandTotalsTotals(dataFields, columnFields),
                        grandTotalsAreHiddenForNotAllDataFields = dataFields.length > 0 ? hiddenGrandTotals.length !== dataFields.length : true,
                        dataIsHiddenForNotAllDataFields = dataFields.length > 0 ? hiddenTotals.length !== dataFields.length : true,
                        notifyProgress = function(progress) {
                            this.progress = progress;
                            dataSource._changeLoadingCount(0, .8 + .1 * rowOptions.progress + .1 * columnOptions.progress)
                        },
                        rowOptions = {
                            isEmptyGrandTotal: data.isEmptyGrandTotalRow,
                            texts: options.texts || {},
                            hiddenTotals: hiddenTotals,
                            hiddenGrandTotals: [],
                            showTotals: options.showRowTotals,
                            showData: dataIsHiddenForNotAllDataFields,
                            showGrandTotals: false !== options.showRowGrandTotals && grandTotalsAreHiddenForNotAllDataFields,
                            sortBySummaryPaths: createSortPaths(columnFields, dataFields),
                            showTotalsPrior: "rows" === options.showTotalsPrior || "both" === options.showTotalsPrior,
                            showEmpty: !options.hideEmptySummaryCells,
                            layout: options.rowHeaderLayout,
                            fields: rowFields,
                            progress: 0,
                            notifyProgress: notifyProgress
                        },
                        columnOptions = {
                            isEmptyGrandTotal: data.isEmptyGrandTotalColumn,
                            texts: options.texts || {},
                            hiddenTotals: hiddenTotals,
                            showData: dataIsHiddenForNotAllDataFields,
                            hiddenGrandTotals: hiddenGrandTotals,
                            showTotals: options.showColumnTotals,
                            showTotalsPrior: "columns" === options.showTotalsPrior || "both" === options.showTotalsPrior,
                            showGrandTotals: false !== options.showColumnGrandTotals && grandTotalsAreHiddenForNotAllDataFields,
                            sortBySummaryPaths: createSortPaths(rowFields, dataFields),
                            showEmpty: !options.hideEmptySummaryCells,
                            fields: columnFields,
                            progress: 0,
                            notifyProgress: notifyProgress
                        };
                    if (!commonUtils.isDefined(data.grandTotalRowIndex)) {
                        data.grandTotalRowIndex = getHeaderIndexedItems(data.rows, rowFields.length - 1, rowOptions).length
                    }
                    if (!commonUtils.isDefined(data.grandTotalColumnIndex)) {
                        data.grandTotalColumnIndex = getHeaderIndexedItems(data.columns, columnFields.length - 1, columnOptions).length
                    }
                    dataSource._changeLoadingCount(1, .8);
                    $.when(createHeaderInfo(data.columns, columnFields, dataFieldsForColumns, true, columnOptions), createHeaderInfo(data.rows, rowFields, dataFieldsForRows, false, rowOptions)).done(function(columnsInfo, rowsInfo) {
                        that._columnsInfo = columnsInfo;
                        that._rowsInfo = rowsInfo;
                        if (that._rowsScrollController && that._columnsScrollController && that.changed) {
                            that._rowsScrollController.reset();
                            that._columnsScrollController.reset();
                            that._lockChanged = true;
                            that._rowsScrollController.load();
                            that._columnsScrollController.load();
                            that._lockChanged = false
                        }
                    }).always(function() {
                        dataSource._changeLoadingCount(-1)
                    }).done(function() {
                        that._fireChanged();
                        if (that._stateStoringController.isEnabled() && !that._dataSource.isLoading()) {
                            that._stateStoringController.state(that._dataSource.state());
                            that._stateStoringController.save()
                        }
                    })
                },
                getRowsInfo: function(getAllData) {
                    var rowspan, i, that = this,
                        rowsInfo = that._rowsInfo,
                        scrollController = that._rowsScrollController;
                    if (scrollController && !getAllData) {
                        var startIndex = scrollController.beginPageIndex() * that.rowPageSize(),
                            endIndex = scrollController.endPageIndex() * that.rowPageSize() + that.rowPageSize(),
                            newRowsInfo = [],
                            maxDepth = 1;
                        foreachRowInfo(rowsInfo, function(rowInfo, visibleIndex, rowIndex, _, columnIndex) {
                            var isVisible = visibleIndex >= startIndex && rowIndex < endIndex,
                                index = rowIndex < startIndex ? 0 : rowIndex - startIndex,
                                cell = rowInfo;
                            if (isVisible) {
                                newRowsInfo[index] = newRowsInfo[index] || [];
                                rowspan = rowIndex < startIndex ? rowInfo.rowspan - (startIndex - rowIndex) || 1 : rowInfo.rowspan;
                                if (startIndex + index + rowspan > endIndex) {
                                    rowspan = endIndex - (index + startIndex) || 1
                                }
                                if (rowspan !== rowInfo.rowspan) {
                                    cell = $.extend({}, cell, {
                                        rowspan: rowspan
                                    })
                                }
                                newRowsInfo[index].push(cell);
                                maxDepth = math.max(maxDepth, columnIndex + 1)
                            } else {
                                if (i > endIndex) {
                                    return false
                                }
                            }
                        });
                        foreachRowInfo(newRowsInfo, function(rowInfo, visibleIndex, rowIndex, columnIndex, realColumnIndex) {
                            var colspan = rowInfo.colspan || 1;
                            if (realColumnIndex + colspan > maxDepth) {
                                newRowsInfo[rowIndex][columnIndex] = $.extend({}, rowInfo, {
                                    colspan: maxDepth - realColumnIndex || 1
                                })
                            }
                        });
                        return newRowsInfo
                    }
                    return rowsInfo
                },
                getColumnsInfo: function(getAllData) {
                    var that = this,
                        info = that._columnsInfo,
                        scrollController = that._columnsScrollController;
                    if (scrollController && !getAllData) {
                        var startIndex = scrollController.beginPageIndex() * that.columnPageSize(),
                            endIndex = scrollController.endPageIndex() * that.columnPageSize() + that.columnPageSize(),
                            newInfo = [];
                        foreachColumnInfo(info, function(columnInfo, visibleIndex, rowIndex) {
                            var colspan, cell = columnInfo,
                                isVisible = visibleIndex + (cell.colspan - 1 || 0) >= startIndex && visibleIndex < endIndex;
                            newInfo[rowIndex] = newInfo[rowIndex] || [];
                            if (isVisible) {
                                if (visibleIndex < startIndex) {
                                    colspan = cell.colspan - (startIndex - visibleIndex);
                                    visibleIndex = startIndex
                                } else {
                                    colspan = cell.colspan
                                }
                                if (visibleIndex + colspan > endIndex) {
                                    colspan = endIndex - visibleIndex
                                }
                                if (colspan !== cell.colspan) {
                                    cell = $.extend({}, cell, {
                                        colspan: colspan
                                    })
                                }
                                newInfo[rowIndex].push(cell)
                            } else {
                                if (visibleIndex > endIndex) {
                                    return false
                                }
                            }
                        });
                        info = newInfo
                    }
                    return info
                },
                totalRowCount: function() {
                    return this._rowsInfo.length
                },
                rowPageIndex: function(index) {
                    if (void 0 !== index) {
                        this._rowPageIndex = index
                    }
                    return this._rowPageIndex || 0
                },
                totalColumnCount: function() {
                    var count = 0;
                    if (this._columnsInfo && this._columnsInfo.length) {
                        for (var i = 0; i < this._columnsInfo[0].length; i++) {
                            count += this._columnsInfo[0][i].colspan || 1
                        }
                    }
                    return count
                },
                rowPageSize: function(size) {
                    if (void 0 !== size) {
                        this._rowPageSize = size
                    }
                    return this._rowPageSize || 20
                },
                columnPageSize: function(size) {
                    if (void 0 !== size) {
                        this._columnPageSize = size
                    }
                    return this._columnPageSize || 20
                },
                columnPageIndex: function(index) {
                    if (void 0 !== index) {
                        this._columnPageIndex = index
                    }
                    return this._columnPageIndex || 0
                },
                getCellsInfo: function(getAllData) {
                    var rowsInfo = this.getRowsInfo(getAllData),
                        columnsInfo = this.getColumnsInfo(getAllData),
                        data = this._dataSource.getData();
                    return createCellsInfo(rowsInfo, columnsInfo, data, this._dataSource.getAreaFields("data"), this._options.dataFieldArea)
                },
                dispose: function() {
                    var that = this;
                    if (that._isSharedDataSource) {
                        that._dataSource.off("changed", that._changedHandler);
                        that._dataSource.off("expandValueChanging", that._expandValueChangingHandler);
                        that._dataSource.off("loadingChanged", that._loadingChangedHandler)
                    } else {
                        that._dataSource.dispose()
                    }
                    that._columnsScrollController && that._columnsScrollController.dispose();
                    that._rowsScrollController && that._rowsScrollController.dispose();
                    that._stateStoringController.dispose();
                    that.expandValueChanging.empty();
                    that.changed.empty();
                    that.loadingChanged.empty();
                    that.scrollChanged.empty()
                }
            };
            proxyMethod(members, "applyPartialDataSource");
            proxyMethod(members, "collapseHeaderItem");
            proxyMethod(members, "expandHeaderItem");
            proxyMethod(members, "getData");
            return members
        }())
    },
    /*!**********************************************!*\
      !*** ./Scripts/ui/pivot_grid/data_source.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            DataSource = __webpack_require__( /*! ../../data/data_source/data_source */ 155).DataSource,
            Store = __webpack_require__( /*! ../../data/abstract_store */ 156),
            ArrayStore = __webpack_require__( /*! ../../data/array_store */ 162),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isDefined = commonUtils.isDefined,
            each = $.each,
            when = $.when,
            Class = __webpack_require__( /*! ../../core/class */ 20),
            EventsMixin = __webpack_require__( /*! ../../core/events_mixin */ 39),
            inflector = __webpack_require__( /*! ../../core/utils/inflector */ 49),
            normalizeIndexes = __webpack_require__( /*! ../../core/utils/array */ 111).normalizeIndexes,
            localStore = __webpack_require__( /*! ./local_store */ 388),
            xmlaStore = __webpack_require__( /*! ./xmla_store/xmla_store */ 389),
            summaryDisplayModes = __webpack_require__( /*! ./ui.pivot_grid.summary_display_modes */ 390),
            pivotGridUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            foreachTree = pivotGridUtils.foreachTree,
            foreachTreeAsync = pivotGridUtils.foreachTreeAsync,
            findField = pivotGridUtils.findField,
            formatValue = pivotGridUtils.formatValue,
            getCompareFunction = pivotGridUtils.getCompareFunction,
            createPath = pivotGridUtils.createPath,
            foreachDataLevel = pivotGridUtils.foreachDataLevel,
            setFieldProperty = pivotGridUtils.setFieldProperty,
            DESCRIPTION_NAME_BY_AREA = {
                row: "rows",
                column: "columns",
                data: "values",
                filter: "filters"
            },
            STATE_PROPERTIES = ["area", "areaIndex", "sortOrder", "filterType", "filterValues", "sortBy", "sortBySummaryField", "sortBySummaryPath", "expanded", "summaryType", "summaryDisplayMode"],
            CALCULATED_PROPERTIES = ["format", "selector", "customizeText", "caption"];

        function createCaption(field) {
            var caption = field.dataField || field.groupName || "",
                summaryType = (field.summaryType || "").toLowerCase();
            if (commonUtils.isString(field.groupInterval)) {
                caption += "_" + field.groupInterval
            }
            if (summaryType && "custom" !== summaryType) {
                summaryType = summaryType.replace(/^./, summaryType[0].toUpperCase());
                if (caption.length) {
                    summaryType = " (" + summaryType + ")"
                }
            } else {
                summaryType = ""
            }
            return inflector.titleize(caption) + summaryType
        }

        function resetFieldState(field, properties) {
            var initialProperties = field._initProperties || {};
            $.each(properties, function(_, prop) {
                if (initialProperties.hasOwnProperty(prop)) {
                    field[prop] = initialProperties[prop]
                }
            })
        }

        function updateCalculatedFieldProperties(field, calculatedProperties) {
            resetFieldState(field, calculatedProperties);
            if (!isDefined(field.caption)) {
                setFieldProperty(field, "caption", createCaption(field))
            }
        }

        function areExpressionsUsed(descriptions) {
            var expressionsUsed = false;
            each(descriptions.values, function(_, field) {
                if (field.summaryDisplayMode || field.calculateSummaryValue || field.runningTotal) {
                    expressionsUsed = true;
                    return false
                }
            });
            return expressionsUsed
        }
        module.exports = Class.inherit(function() {
            var findHeaderItem = function(headerItems, path) {
                if (headerItems._cacheByPath) {
                    return headerItems._cacheByPath[path.join(".")] || null
                }
            };
            var getHeaderItemsLastIndex = function(headerItems, grandTotalIndex) {
                var i, headerItem, lastIndex = -1;
                if (headerItems) {
                    for (i = 0; i < headerItems.length; i++) {
                        headerItem = headerItems[i];
                        lastIndex = Math.max(lastIndex, headerItem.index);
                        if (headerItem.children) {
                            lastIndex = Math.max(lastIndex, getHeaderItemsLastIndex(headerItem.children))
                        } else {
                            if (headerItem.collapsedChildren) {
                                lastIndex = Math.max(lastIndex, getHeaderItemsLastIndex(headerItem.collapsedChildren))
                            }
                        }
                    }
                }
                if (isDefined(grandTotalIndex)) {
                    lastIndex = Math.max(lastIndex, grandTotalIndex)
                }
                return lastIndex
            };
            var updateHeaderItemChildren = function(headerItems, headerItem, children, grandTotalIndex) {
                var index, applyingHeaderItemsCount = getHeaderItemsLastIndex(children) + 1,
                    emptyIndex = getHeaderItemsLastIndex(headerItems, grandTotalIndex) + 1,
                    applyingItemIndexesToCurrent = [],
                    d = $.Deferred();
                for (index = 0; index < applyingHeaderItemsCount; index++) {
                    applyingItemIndexesToCurrent[index] = emptyIndex++
                }
                headerItem.children = children;
                when(foreachTreeAsync(headerItem.children, function(items) {
                    items[0].index = applyingItemIndexesToCurrent[items[0].index]
                })).done(function() {
                    d.resolve(applyingItemIndexesToCurrent)
                });
                return d
            };
            var updateHeaderItems = function(headerItems, newHeaderItems) {
                var d = $.Deferred();
                var applyingItemIndexesToCurrent = [];
                when(foreachTreeAsync(headerItems, function(items) {
                    delete items[0].collapsedChildren
                })).done(function() {
                    when(foreachTreeAsync(newHeaderItems, function(items) {
                        var headerItem = findHeaderItem(headerItems, createPath(items));
                        if (headerItem) {
                            applyingItemIndexesToCurrent[items[0].index] = headerItem.index
                        }
                    })).done(function() {
                        d.resolve(applyingItemIndexesToCurrent)
                    })
                });
                return d
            };
            var updateDataSourceCells = function(dataSource, newDataSourceCells, newRowItemIndexesToCurrent, newColumnItemIndexesToCurrent) {
                var newRowIndex, newColumnIndex, newRowCells, newCell, rowIndex, columnIndex, dataSourceCells = dataSource.values;
                if (newDataSourceCells) {
                    for (newRowIndex = 0; newRowIndex <= newDataSourceCells.length; newRowIndex++) {
                        newRowCells = newDataSourceCells[newRowIndex];
                        rowIndex = newRowItemIndexesToCurrent[newRowIndex];
                        if (!isDefined(rowIndex)) {
                            rowIndex = dataSource.grandTotalRowIndex
                        }
                        if (newRowCells && isDefined(rowIndex)) {
                            if (!dataSourceCells[rowIndex]) {
                                dataSourceCells[rowIndex] = []
                            }
                            for (newColumnIndex = 0; newColumnIndex <= newRowCells.length; newColumnIndex++) {
                                newCell = newRowCells[newColumnIndex];
                                columnIndex = newColumnItemIndexesToCurrent[newColumnIndex];
                                if (!isDefined(columnIndex)) {
                                    columnIndex = dataSource.grandTotalColumnIndex
                                }
                                if (isDefined(newCell) && isDefined(columnIndex)) {
                                    dataSourceCells[rowIndex][columnIndex] = newCell
                                }
                            }
                        }
                    }
                }
            };

            function createStore(dataSourceOptions) {
                var store, storeOptions;
                if ($.isPlainObject(dataSourceOptions) && dataSourceOptions.load) {
                    store = new localStore.LocalStore(dataSourceOptions)
                } else {
                    if (dataSourceOptions && !dataSourceOptions.store) {
                        dataSourceOptions = {
                            store: dataSourceOptions
                        }
                    }
                    storeOptions = dataSourceOptions.store;
                    if ("xmla" === storeOptions.type) {
                        store = new xmlaStore.XmlaStore(storeOptions)
                    } else {
                        if ($.isPlainObject(storeOptions) && storeOptions.type || storeOptions instanceof Store || $.isArray(storeOptions)) {
                            store = new localStore.LocalStore(dataSourceOptions)
                        } else {
                            if (storeOptions instanceof Class) {
                                store = storeOptions
                            }
                        }
                    }
                }
                return store
            }

            function getExpandedPaths(dataSource, loadOptions, dimensionName) {
                var result = [],
                    fields = loadOptions && loadOptions[dimensionName] || [];
                foreachTree(dataSource[dimensionName], function(items) {
                    var item = items[0],
                        path = createPath(items);
                    if (item.children && fields[path.length - 1] && !fields[path.length - 1].expanded) {
                        path.length < fields.length && result.push(path.slice())
                    }
                }, true);
                return result
            }

            function setFieldProperties(field, srcField, skipInitPropertySave, properties) {
                if (srcField) {
                    each(properties, function(_, name) {
                        if (skipInitPropertySave) {
                            field[name] = srcField[name]
                        } else {
                            if (("summaryType" === name || "summaryDisplayMode" === name) && void 0 === srcField[name]) {
                                return
                            }
                            if (srcField.hasOwnProperty(name)) {
                                setFieldProperty(field, name, srcField[name])
                            }
                        }
                    })
                } else {
                    resetFieldState(field, properties)
                }
                return field
            }

            function getFieldsState(fields, properties) {
                var result = [];
                each(fields, function(_, field) {
                    result.push(setFieldProperties({
                        dataField: field.dataField,
                        name: field.name
                    }, field, true, properties))
                });
                return result
            }

            function getFieldStateId(field) {
                if (field.name) {
                    return field.name
                }
                return field.dataField + ""
            }

            function getFieldsById(fields, id) {
                var result = [];
                each(fields || [], function(_, field) {
                    if (getFieldStateId(field) === id) {
                        result.push(field)
                    }
                });
                return result
            }

            function setFieldsStateCore(stateFields, fields) {
                stateFields = stateFields || [];
                each(fields, function(index, field) {
                    setFieldProperties(field, stateFields[index], false, STATE_PROPERTIES);
                    updateCalculatedFieldProperties(field, CALCULATED_PROPERTIES)
                });
                return fields
            }

            function setFieldsState(stateFields, fields) {
                stateFields = stateFields || [];
                var id, fieldsById = {};
                each(fields, function(_, field) {
                    id = getFieldStateId(field);
                    if (!fieldsById[id]) {
                        fieldsById[id] = getFieldsById(fields, getFieldStateId(field))
                    }
                });
                each(fieldsById, function(id, fields) {
                    setFieldsStateCore(getFieldsById(stateFields, id), fields)
                });
                return fields
            }

            function getFieldsByGroup(fields, grouppingField) {
                return $.map(fields, function(field) {
                    if (field.groupName === grouppingField.groupName && commonUtils.isNumber(field.groupIndex) && false !== field.visible) {
                        return $.extend(field, {
                            areaIndex: grouppingField.areaIndex,
                            area: grouppingField.area,
                            expanded: isDefined(field.expanded) ? field.expanded : grouppingField.expanded,
                            dataField: field.dataField || grouppingField.dataField,
                            dataType: field.dataType || grouppingField.dataType,
                            sortBy: field.sortBy || grouppingField.sortBy,
                            sortOrder: field.sortOrder || grouppingField.sortOrder,
                            sortBySummaryField: field.sortBySummaryField || grouppingField.sortBySummaryField,
                            sortBySummaryPath: field.sortBySummaryPath || grouppingField.sortBySummaryPath,
                            visible: field.visible || grouppingField.visible,
                            showTotals: isDefined(field.showTotals) ? field.showTotals : grouppingField.showTotals,
                            showGrandTotals: isDefined(field.showGrandTotals) ? field.showGrandTotals : grouppingField.showGrandTotals
                        })
                    }
                    return null
                }).sort(function(a, b) {
                    return a.groupIndex - b.groupIndex
                })
            }

            function sortFieldsByAreaIndex(fields) {
                fields.sort(function(field1, field2) {
                    return field1.areaIndex - field2.areaIndex
                })
            }

            function isAreaField(field, area) {
                return field.area === area && !isDefined(field.groupIndex) && false !== field.visible
            }

            function getFieldId(field) {
                return (field.dataField || field.groupName || "") + (field.groupInterval ? field.groupName || "" : "NOGROUP") + (field.groupInterval || "")
            }

            function mergeFields(fields, storeFields, retrieveFieldsOptionValue) {
                var result = [],
                    fieldsDictionary = {},
                    removedFields = {},
                    mergedGroups = [],
                    dataTypes = getFieldsDataType(fields);
                if (storeFields) {
                    each(storeFields, function(_, field) {
                        fieldsDictionary[getFieldId(field)] = field
                    });
                    each(fields, function(_, field) {
                        var mergedField, fieldKey = getFieldId(field),
                            storeField = fieldsDictionary[fieldKey] || removedFields[fieldKey];
                        if (storeField) {
                            mergedField = $.extend({}, storeField, field)
                        } else {
                            fieldsDictionary[fieldKey] = mergedField = field
                        }
                        $.extend(mergedField, {
                            dataType: dataTypes[field.dataField]
                        });
                        delete fieldsDictionary[fieldKey];
                        removedFields[fieldKey] = storeField;
                        result.push(mergedField)
                    });
                    if (retrieveFieldsOptionValue) {
                        each(fieldsDictionary, function(_, field) {
                            result.push(field)
                        })
                    }
                } else {
                    result = fields
                }
                result.push.apply(result, mergedGroups);
                return result
            }

            function getFieldsDataType(fields) {
                var result = {};
                each(fields, function(_, field) {
                    result[field.dataField] = result[field.dataField] || field.dataType
                });
                return result
            }

            function getFields(that) {
                var mergedFields, result = $.Deferred(),
                    store = that._store,
                    storeFields = store && store.getFields(getFieldsDataType(that._fields));
                when(storeFields).done(function(storeFields) {
                    that._storeFields = storeFields;
                    mergedFields = mergeFields(that._fields, storeFields, that._retrieveFields);
                    result.resolve(mergedFields)
                }).fail(function() {
                    result.resolve(that._fields)
                });
                return result
            }

            function getSliceIndex(items, path) {
                var index = null,
                    pathValue = (path || []).join(".");
                if (pathValue.length) {
                    foreachTree(items, function(items) {
                        var item = items[0],
                            itemPath = createPath(items).join("."),
                            textPath = $.map(items, function(item) {
                                return item.text
                            }).reverse().join(".");
                        if (pathValue === itemPath || item.key && textPath === pathValue) {
                            index = items[0].index;
                            return false
                        }
                    })
                }
                return index
            }

            function getFieldSummaryValueSelector(field, dataSource, loadOptions, dimensionName) {
                var values = dataSource.values,
                    sortBySummaryFieldIndex = findField(loadOptions.values, field.sortBySummaryField),
                    areRows = "rows" === dimensionName,
                    sortByDimension = areRows ? dataSource.columns : dataSource.rows,
                    grandTotalIndex = areRows ? dataSource.grandTotalRowIndex : dataSource.grandTotalColumnIndex,
                    sortBySummaryPath = field.sortBySummaryPath || [],
                    sliceIndex = sortBySummaryPath.length ? getSliceIndex(sortByDimension, sortBySummaryPath) : grandTotalIndex;
                if (values && values.length && sortBySummaryFieldIndex >= 0 && isDefined(sliceIndex)) {
                    return function(field) {
                        var rowIndex = areRows ? field.index : sliceIndex,
                            columnIndex = areRows ? sliceIndex : field.index;
                        return ((values[rowIndex] || [
                            []
                        ])[columnIndex] || [])[sortBySummaryFieldIndex] || null
                    }
                }
            }

            function getSortingMethod(field, dataSource, loadOptions, dimensionName, getAscOrder) {
                var sortOrder = getAscOrder ? "asc" : field.sortOrder,
                    sortBy = getAscOrder ? "value" : "displayText" === field.sortBy ? "text" : "value",
                    defaultCompare = field.sortingMethod || getCompareFunction(function(item) {
                        return item[sortBy]
                    }),
                    summaryValueSelector = !getAscOrder && getFieldSummaryValueSelector(field, dataSource, loadOptions, dimensionName),
                    summaryCompare = summaryValueSelector && getCompareFunction(summaryValueSelector),
                    sortingMethod = function(a, b) {
                        var result = summaryCompare && summaryCompare(a, b) || 0;
                        if (0 === result) {
                            result = defaultCompare(a, b)
                        }
                        return "desc" === sortOrder ? -result : result
                    };
                return sortingMethod
            }

            function sortDimension(dataSource, loadOptions, dimensionName, getAscOrder) {
                var fields = loadOptions[dimensionName] || [],
                    baseIndex = loadOptions.headerName === dimensionName ? loadOptions.path.length : 0,
                    sortingMethodByLevel = [];
                foreachDataLevel(dataSource[dimensionName], function(item, index) {
                    var field = fields[index] || {},
                        sortingMethod = sortingMethodByLevel[index] = sortingMethodByLevel[index] || getSortingMethod(field, dataSource, loadOptions, dimensionName, getAscOrder);
                    item.sort(sortingMethod)
                }, baseIndex)
            }

            function sort(loadOptions, dataSource, getAscOrder) {
                sortDimension(dataSource, loadOptions, "rows", getAscOrder);
                sortDimension(dataSource, loadOptions, "columns", getAscOrder)
            }

            function formatHeaderItems(data, loadOptions, headerName) {
                return foreachTreeAsync(data[headerName], function(items) {
                    var item = items[0];
                    item.text = item.text || formatValue(item.value, loadOptions[headerName][createPath(items).length - 1])
                })
            }

            function formatHeaders(loadOptions, data) {
                return when(formatHeaderItems(data, loadOptions, "columns"), formatHeaderItems(data, loadOptions, "rows"))
            }

            function updateCache(headerItems) {
                var d = $.Deferred();
                var cacheByPath = {};
                when(foreachTreeAsync(headerItems, function(items) {
                    var path = createPath(items).join(".");
                    cacheByPath[path] = items[0]
                })).done(d.resolve);
                headerItems._cacheByPath = cacheByPath;
                return d
            }
            exports.sort = sort;
            return {
                ctor: function(options) {
                    options = options || {};
                    var that = this,
                        store = createStore(options);
                    that._store = store;
                    that._data = {
                        rows: [],
                        columns: [],
                        values: []
                    };
                    that._loadingCount = 0;
                    each(["changed", "loadError", "loadingChanged", "fieldsPrepared", "expandValueChanging"], $.proxy(function(_, eventName) {
                        var optionName = "on" + eventName[0].toUpperCase() + eventName.slice(1);
                        if (options.hasOwnProperty(optionName)) {
                            this.on(eventName, options[optionName])
                        }
                    }, this));
                    that._retrieveFields = isDefined(options.retrieveFields) ? options.retrieveFields : true;
                    that._fields = options.fields || [];
                    that._descriptions = options.descriptions ? $.extend(that._createDescriptions(), options.descriptions) : void 0;
                    if (!store) {
                        $.extend(true, that._data, options.store || options)
                    }
                },
                getData: function() {
                    return this._data
                },
                getAreaFields: function(area, collectGroups) {
                    var descriptions, areaFields = [];
                    if (collectGroups || "data" === area) {
                        each(this._fields, function() {
                            if (isAreaField(this, area)) {
                                areaFields.push(this)
                            }
                        });
                        sortFieldsByAreaIndex(areaFields)
                    } else {
                        descriptions = this._descriptions || {};
                        areaFields = descriptions[DESCRIPTION_NAME_BY_AREA[area]] || []
                    }
                    return areaFields
                },
                fields: function(fields) {
                    var that = this;
                    if (fields) {
                        that._fields = mergeFields(fields, that._storeFields, that._retrieveFields);
                        that._fieldsPrepared(that._fields)
                    }
                    return that._fields
                },
                field: function(id, options) {
                    var levels, that = this,
                        fields = that._fields,
                        field = fields && fields[commonUtils.isNumber(id) ? id : findField(fields, id)];
                    if (field && options) {
                        each(options, function(optionName, optionValue) {
                            var isInitialization = $.inArray(optionName, STATE_PROPERTIES) < 0;
                            setFieldProperty(field, optionName, optionValue, isInitialization);
                            if ("sortOrder" === optionName) {
                                levels = field.levels || [];
                                for (var i = 0; i < levels.length; i++) {
                                    levels[i][optionName] = optionValue
                                }
                            }
                        });
                        updateCalculatedFieldProperties(field, CALCULATED_PROPERTIES);
                        that._descriptions = that._createDescriptions(field)
                    }
                    return field
                },
                getFieldValues: function(index) {
                    var that = this,
                        field = this._fields && this._fields[index],
                        store = this.store(),
                        loadFields = [],
                        loadOptions = {
                            columns: loadFields,
                            rows: [],
                            values: this.getAreaFields("data"),
                            filters: []
                        },
                        d = $.Deferred();
                    if (field && store) {
                        each(field.levels || [field], function() {
                            loadFields.push($.extend({}, this, {
                                expanded: true,
                                filterValues: null,
                                sortOrder: "asc",
                                sortBySummaryField: null
                            }))
                        });
                        store.load(loadOptions).done(function(data) {
                            formatHeaders(loadOptions, data);
                            that._sort(loadOptions, data);
                            d.resolve(data.columns)
                        }).fail(d)
                    } else {
                        d.reject()
                    }
                    return d
                },
                reload: function() {
                    return this.load({
                        reload: true
                    })
                },
                filter: function() {
                    var store = this._store;
                    return store.filter.apply(store, arguments)
                },
                load: function(options) {
                    var that = this,
                        d = $.Deferred();
                    options = options || {};
                    that._changeLoadingCount(1);
                    d.progress(function(progress) {
                        that._changeLoadingCount(0, .8 * progress)
                    });
                    d.fail(function(e) {
                        that.fireEvent("loadError", [e])
                    }).always(function() {
                        that._changeLoadingCount(-1)
                    });

                    function loadTask() {
                        that._delayedLoadTask = void 0;
                        if (!that._descriptions) {
                            when(getFields(that)).done(function(fields) {
                                that._fieldsPrepared(fields);
                                that._loadCore(options, d)
                            }).fail(d.reject).fail(that._loadErrorHandler)
                        } else {
                            that._loadCore(options, d)
                        }
                    }
                    if (that.store()) {
                        that._delayedLoadTask = commonUtils.executeAsync(loadTask)
                    } else {
                        loadTask()
                    }
                    return d
                },
                createDrillDownDataSource: function(params) {
                    function createCustomStoreMethod(methodName) {
                        return function(options) {
                            var d;
                            if (arrayStore) {
                                d = arrayStore[methodName](options)
                            } else {
                                d = $.Deferred();
                                when(items).done(function(data) {
                                    arrayStore = new ArrayStore(data);
                                    arrayStore[methodName](options).done(d.resolve).fail(d.reject)
                                }).fail(d.reject)
                            }
                            return d
                        }
                    }
                    var arrayStore, items = this._store.getDrillDownItems(this._descriptions, params),
                        dataSource = new DataSource({
                            load: createCustomStoreMethod("load"),
                            totalCount: createCustomStoreMethod("totalCount"),
                            key: this._store.key()
                        });
                    return dataSource
                },
                _createDescriptions: function(currentField) {
                    var that = this,
                        fields = that.fields(),
                        descriptions = {
                            rows: [],
                            columns: [],
                            values: [],
                            filters: []
                        };
                    each(["row", "column", "data", "filter"], function(_, areaName) {
                        var areaFields = [];
                        each(fields, function(index, field) {
                            if (isAreaField(field, areaName)) {
                                areaFields.push(field)
                            }
                        });
                        normalizeIndexes(areaFields, "areaIndex", currentField)
                    });
                    each(fields || [], function(_, field) {
                        var descriptionName = DESCRIPTION_NAME_BY_AREA[field.area],
                            dimension = descriptions[descriptionName],
                            groupName = field.groupName;
                        if (groupName && !commonUtils.isNumber(field.groupIndex)) {
                            field.levels = getFieldsByGroup(fields, field)
                        }
                        if (!dimension || groupName && commonUtils.isNumber(field.groupIndex) || false === field.visible && "data" !== field.area) {
                            return
                        }
                        if (field.levels && dimension !== descriptions.filters && dimension !== descriptions.values) {
                            dimension.push.apply(dimension, field.levels);
                            if (field.filterValues && field.filterValues.length) {
                                descriptions.filters.push(field)
                            }
                        } else {
                            dimension.push(field)
                        }
                    });
                    each(descriptions, function(_, fields) {
                        sortFieldsByAreaIndex(fields)
                    });
                    var indices = {};
                    each(descriptions.values, function(_, field) {
                        var expression = field.calculateSummaryValue;
                        if (commonUtils.isFunction(expression)) {
                            var summaryCell = summaryDisplayModes.createMockSummaryCell(descriptions, fields, indices);
                            expression(summaryCell)
                        }
                    });
                    return descriptions
                },
                _fieldsPrepared: function(fields) {
                    var that = this;
                    that._fields = fields;
                    each(fields, function(index, field) {
                        field.index = index;
                        updateCalculatedFieldProperties(field, CALCULATED_PROPERTIES.concat(["allowSorting", "allowSortingBySummary", "allowFiltering", "allowExpandAll"]))
                    });
                    var currentFieldState = getFieldsState(fields, ["caption"]);
                    that.fireEvent("fieldsPrepared", [fields]);
                    for (var i = 0; i < fields.length; i++) {
                        if (fields[i].caption !== currentFieldState[i].caption) {
                            setFieldProperty(fields[i], "caption", fields[i].caption, true)
                        }
                    }
                    that._descriptions = that._createDescriptions()
                },
                isLoading: function() {
                    return this._loadingCount > 0
                },
                state: function(state) {
                    var that = this;
                    if (arguments.length) {
                        state = $.extend({
                            rowExpandedPaths: [],
                            columnExpandedPaths: []
                        }, state);
                        if (!that._descriptions) {
                            that._changeLoadingCount(1);
                            when(getFields(that)).done(function(fields) {
                                that._fields = setFieldsState(state.fields, fields);
                                that._fieldsPrepared(fields);
                                that.load(state)
                            }).always(function() {
                                that._changeLoadingCount(-1)
                            })
                        } else {
                            that._fields = setFieldsState(state.fields, that._fields);
                            that._descriptions = that._createDescriptions();
                            that.load(state)
                        }
                    } else {
                        return {
                            fields: getFieldsState(that._fields, STATE_PROPERTIES),
                            columnExpandedPaths: getExpandedPaths(that._data, that._descriptions, "columns"),
                            rowExpandedPaths: getExpandedPaths(that._data, that._descriptions, "rows")
                        }
                    }
                },
                _changeLoadingCount: function(increment, progress) {
                    var newLoading, oldLoading = this.isLoading();
                    this._loadingCount += increment;
                    newLoading = this.isLoading();
                    if (oldLoading ^ newLoading || progress) {
                        this.fireEvent("loadingChanged", [newLoading, progress])
                    }
                },
                _loadCore: function(options, deferred) {
                    var that = this,
                        store = this._store,
                        descriptions = this._descriptions,
                        headerName = DESCRIPTION_NAME_BY_AREA[options.area];
                    options = options || {};
                    if (store) {
                        $.extend(options, descriptions);
                        options.columnExpandedPaths = options.columnExpandedPaths || getExpandedPaths(this._data, options, "columns");
                        options.rowExpandedPaths = options.rowExpandedPaths || getExpandedPaths(this._data, options, "rows");
                        if (headerName) {
                            options.headerName = headerName
                        }
                        that._changeLoadingCount(1);
                        deferred.always(function() {
                            that._changeLoadingCount(-1)
                        });
                        when(store.load(options)).progress(deferred.notify).done(function(data) {
                            if (options.path) {
                                that.applyPartialDataSource(options.area, options.path, data, deferred)
                            } else {
                                $.extend(that._data, data);
                                that._update(deferred)
                            }
                        }).fail(deferred.reject)
                    } else {
                        that._update(deferred)
                    }
                },
                _sort: function(descriptions, data, getAscOrder) {
                    var store = this._store;
                    if (store) {
                        sort(descriptions, data, getAscOrder)
                    }
                },
                _update: function(deferred) {
                    var that = this,
                        descriptions = that._descriptions,
                        loadedData = that._data,
                        expressionsUsed = areExpressionsUsed(descriptions);
                    when(formatHeaders(descriptions, loadedData), updateCache(loadedData.rows), updateCache(loadedData.columns)).done(function() {
                        if (expressionsUsed) {
                            that._sort(descriptions, loadedData, expressionsUsed);
                            summaryDisplayModes.applyDisplaySummaryMode(descriptions, loadedData)
                        }
                        that._sort(descriptions, loadedData);
                        that._data = loadedData;
                        when(deferred).done(function() {
                            that.fireEvent("changed");
                            if (isDefined(that._data.grandTotalRowIndex)) {
                                loadedData.grandTotalRowIndex = that._data.grandTotalRowIndex
                            }
                            if (isDefined(that._data.grandTotalColumnIndex)) {
                                loadedData.grandTotalColumnIndex = that._data.grandTotalColumnIndex
                            }
                        });
                        deferred && deferred.resolve(that._data)
                    })
                },
                store: function() {
                    return this._store
                },
                collapseHeaderItem: function(area, path) {
                    var that = this,
                        headerItems = "column" === area ? that._data.columns : that._data.rows,
                        headerItem = findHeaderItem(headerItems, path),
                        field = that.getAreaFields(area)[path.length - 1];
                    if (headerItem && headerItem.children) {
                        that.fireEvent("expandValueChanging", [{
                            area: area,
                            path: path,
                            expanded: false
                        }]);
                        if (field) {
                            field.expanded = false
                        }
                        headerItem.collapsedChildren = headerItem.children;
                        delete headerItem.children;
                        that._update();
                        return true
                    }
                    return false
                },
                collapseAll: function(id) {
                    var dataChanged = false,
                        field = this.field(id) || {},
                        areaOffset = $.inArray(field, this.getAreaFields(field.area));
                    field.expanded = false;
                    foreachTree(this._data[field.area + "s"], function(items) {
                        var item = items[0],
                            path = createPath(items);
                        if (item && item.children && areaOffset === path.length - 1) {
                            item.collapsedChildren = item.children;
                            delete item.children;
                            dataChanged = true
                        }
                    }, true);
                    dataChanged && this._update()
                },
                expandAll: function(id) {
                    var field = this.field(id);
                    if (field && field.area) {
                        field.expanded = true;
                        this.load()
                    }
                },
                expandHeaderItem: function(area, path) {
                    var hasCache, options, that = this,
                        headerItems = "column" === area ? that._data.columns : that._data.rows,
                        headerItem = findHeaderItem(headerItems, path);
                    if (headerItem && !headerItem.children) {
                        hasCache = !!headerItem.collapsedChildren;
                        options = {
                            area: area,
                            path: path,
                            expanded: true,
                            needExpandData: !hasCache
                        };
                        that.fireEvent("expandValueChanging", [options]);
                        if (hasCache) {
                            headerItem.children = headerItem.collapsedChildren;
                            delete headerItem.collapsedChildren;
                            that._update()
                        } else {
                            that.load(options)
                        }
                        return hasCache
                    }
                    return false
                },
                applyPartialDataSource: function(area, path, dataSource, deferred) {
                    var headerItem, newRowItemIndexesToCurrent, newColumnItemIndexesToCurrent, that = this,
                        loadedData = that._data,
                        headerItems = "column" === area ? loadedData.columns : loadedData.rows;
                    if (dataSource && dataSource.values) {
                        dataSource.rows = dataSource.rows || [];
                        dataSource.columns = dataSource.columns || [];
                        headerItem = findHeaderItem(headerItems, path);
                        if (headerItem) {
                            if ("column" === area) {
                                newColumnItemIndexesToCurrent = updateHeaderItemChildren(headerItems, headerItem, dataSource.columns, loadedData.grandTotalColumnIndex);
                                newRowItemIndexesToCurrent = updateHeaderItems(loadedData.rows, dataSource.rows)
                            } else {
                                newRowItemIndexesToCurrent = updateHeaderItemChildren(headerItems, headerItem, dataSource.rows, loadedData.grandTotalRowIndex);
                                newColumnItemIndexesToCurrent = updateHeaderItems(loadedData.columns, dataSource.columns)
                            }
                            when(newRowItemIndexesToCurrent, newColumnItemIndexesToCurrent).done(function(newRowItemIndexesToCurrent, newColumnItemIndexesToCurrent) {
                                updateDataSourceCells(loadedData, dataSource.values, newRowItemIndexesToCurrent, newColumnItemIndexesToCurrent);
                                that._update(deferred)
                            })
                        }
                    }
                },
                dispose: function() {
                    var that = this,
                        delayedLoadTask = that._delayedLoadTask;
                    this._disposeEvents();
                    if (delayedLoadTask) {
                        delayedLoadTask.abort()
                    }
                    this._isDisposed = true
                },
                isDisposed: function() {
                    return !!this._isDisposed
                }
            }
        }()).include(EventsMixin);
        module.exports.sort = exports.sort
    },
    /*!**********************************************!*\
      !*** ./Scripts/ui/pivot_grid/local_store.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dataUtils = __webpack_require__( /*! ../../data/utils */ 137),
            DataSourceModule = __webpack_require__( /*! ../../data/data_source/data_source */ 155),
            normalizeDataSourceOptions = DataSourceModule.normalizeDataSourceOptions,
            dataCoreUtils = __webpack_require__( /*! ../../core/utils/data */ 36),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            formatHelper = __webpack_require__( /*! ../../format_helper */ 55),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            pivotGridUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            setFieldProperty = pivotGridUtils.setFieldProperty;
        exports.LocalStore = Class.inherit(function() {
            var DATE_INTERVAL_SELECTORS = {
                year: function(date) {
                    return date && date.getFullYear()
                },
                quarter: function(date) {
                    return date && Math.floor(date.getMonth() / 3) + 1
                },
                month: function(date) {
                    return date && date.getMonth() + 1
                },
                day: function(date) {
                    return date && date.getDate()
                },
                dayOfWeek: function(date) {
                    return date && date.getDay()
                }
            };
            var DATE_INTERVAL_FORMATS = {
                month: function(value) {
                    return dateLocalization.getMonthNames()[value - 1]
                },
                quarter: function(value) {
                    return dateLocalization.format(new Date(2e3, 3 * value - 1), "quarter")
                },
                dayOfWeek: function(value) {
                    return dateLocalization.getDayNames()[value]
                }
            };

            function prepareFields(fields) {
                $.each(fields || [], function(_, field) {
                    var fieldSelector, intervalSelector, groupInterval, dataSelector, dataField = field.dataField,
                        levels = field.levels;
                    if (!field.selector) {
                        if (!dataField) {
                            dataSelector = function(data) {
                                return data
                            }
                        } else {
                            dataSelector = dataField.indexOf(".") !== -1 ? dataCoreUtils.compileGetter(dataField) : function(data) {
                                return data[dataField]
                            }
                        }
                        if (levels) {
                            prepareFields(levels)
                        }
                        if ("date" === field.dataType) {
                            intervalSelector = DATE_INTERVAL_SELECTORS[field.groupInterval];
                            fieldSelector = function(data) {
                                var value = dataSelector(data);
                                if (value && !(value instanceof Date)) {
                                    value = new Date(value)
                                }
                                return intervalSelector ? intervalSelector(value) : value
                            };
                            if (!field.format) {
                                setFieldProperty(field, "format", DATE_INTERVAL_FORMATS[field.groupInterval])
                            }
                        } else {
                            if ("number" === field.dataType) {
                                groupInterval = commonUtils.isNumber(field.groupInterval) && field.groupInterval > 0 && field.groupInterval;
                                if (groupInterval && !field.customizeText) {
                                    setFieldProperty(field, "customizeText", function(formatObject) {
                                        var secondValue = formatObject.value + groupInterval,
                                            secondValueText = formatHelper.format(secondValue, field.format, field.precision);
                                        return formatObject.valueText && secondValueText ? formatObject.valueText + " - " + secondValueText : ""
                                    })
                                }
                                fieldSelector = function(data) {
                                    var value = dataSelector(data);
                                    if (commonUtils.isString(value)) {
                                        value = Number(value)
                                    }
                                    return groupInterval ? Math.floor(value / groupInterval) * groupInterval : value
                                }
                            } else {
                                fieldSelector = dataSelector
                            }
                        }
                        setFieldProperty(field, "selector", fieldSelector)
                    }
                })
            }
            var addHierarchyItem = function(value, hierarchyItems, pathHash, childrenHash) {
                var hierarchyItem = childrenHash[pathHash];
                if (!hierarchyItem) {
                    hierarchyItem = {
                        value: value,
                        index: childrenHash.length++
                    };
                    childrenHash[pathHash] = hierarchyItem;
                    hierarchyItems.push(hierarchyItem)
                }
                return hierarchyItem
            };

            function fillHierarchyItemIndexesCore(indexes, options, children, expandIndex, pathHash) {
                var dimensionValue, hierarchyItem, dimension = options.dimensions[expandIndex],
                    expandedPathsHash = options.expandedPathsHash;
                if (dimension) {
                    dimensionValue = dimension.selector(options.data);
                    pathHash = void 0 !== pathHash ? pathHash + "." + dimensionValue : dimensionValue + "";
                    hierarchyItem = addHierarchyItem(dimensionValue, children, pathHash, options.childrenHash);
                    indexes.push(hierarchyItem.index);
                    if (expandedPathsHash && expandedPathsHash[pathHash] || dimension.expanded) {
                        if (!hierarchyItem.children) {
                            hierarchyItem.children = []
                        }
                        fillHierarchyItemIndexesCore(indexes, options, hierarchyItem.children, expandIndex + 1, pathHash)
                    }
                }
            }

            function generateHierarchyItems(data, loadOptions, headers, headerName) {
                var result = [0],
                    expandIndex = loadOptions.headerName === headerName ? loadOptions.path.length : 0,
                    expandedPaths = "rows" === headerName ? loadOptions.rowExpandedPaths : loadOptions.columnExpandedPaths,
                    options = {
                        data: data,
                        childrenHash: headers[headerName + "Hash"],
                        dimensions: loadOptions[headerName],
                        expandedPathsHash: loadOptions.headerName !== headerName && expandedPaths && expandedPaths.hash
                    };
                fillHierarchyItemIndexesCore(result, options, headers[headerName], expandIndex);
                return result
            }

            function generateAggregationCells(data, cells, headers, options) {
                var x, y, rowIndex, columnIndex, cellSet = [];
                var rowIndexes = generateHierarchyItems(data, options, headers, "rows");
                var columnIndexes = generateHierarchyItems(data, options, headers, "columns");
                for (y = 0; y < rowIndexes.length; y++) {
                    rowIndex = rowIndexes[y];
                    cells[rowIndex] = cells[rowIndex] || [];
                    for (x = 0; x < columnIndexes.length; x++) {
                        columnIndex = columnIndexes[x];
                        cellSet.push(cells[rowIndex][columnIndex] = cells[rowIndex][columnIndex] || [])
                    }
                }
                return cellSet
            }

            function fillHashExpandedPath(expandedPaths) {
                if (expandedPaths) {
                    expandedPaths.hash = {};
                    $.each(expandedPaths, function() {
                        expandedPaths.hash[this.join(".")] = true
                    })
                }
            }

            function prepareLoadOption(options) {
                options.rows = options.rows || [];
                options.columns = options.columns || [];
                options.filters = options.filters || [];
                fillHashExpandedPath(options.columnExpandedPaths);
                fillHashExpandedPath(options.rowExpandedPaths);
                prepareFields(options.columns);
                prepareFields(options.rows);
                prepareFields(options.values);
                prepareFields(options.filters)
            }

            function getAggregator(field) {
                if ("custom" === field.summaryType) {
                    field.calculateCustomSummary = field.calculateCustomSummary || $.noop;
                    return {
                        seed: function() {
                            var options = {
                                summaryProcess: "start",
                                totalValue: void 0
                            };
                            field.calculateCustomSummary(options);
                            return options
                        },
                        step: function(options, value) {
                            options.summaryProcess = "calculate";
                            options.value = value;
                            field.calculateCustomSummary(options);
                            return options
                        },
                        finalize: function(options) {
                            options.summaryProcess = "finalize";
                            delete options.value;
                            field.calculateCustomSummary(options);
                            return options.totalValue
                        }
                    }
                }
                return dataUtils.aggregators[field.summaryType] || dataUtils.aggregators.count
            }

            function aggregationStep(measures, aggregationCells, data) {
                for (var aggregatorIndex = 0; aggregatorIndex < measures.length; aggregatorIndex++) {
                    var cellField = measures[aggregatorIndex];
                    var cellValue = cellField.selector(data);
                    var aggregator = getAggregator(cellField),
                        isAggregatorSeedFunction = "function" === typeof aggregator.seed;
                    for (var cellSetIndex = 0; cellSetIndex < aggregationCells.length; cellSetIndex++) {
                        var cell = aggregationCells[cellSetIndex];
                        if (cell.length <= aggregatorIndex) {
                            cell[aggregatorIndex] = isAggregatorSeedFunction ? aggregator.seed() : aggregator.seed
                        }
                        if (void 0 === cell[aggregatorIndex]) {
                            cell[aggregatorIndex] = cellValue
                        } else {
                            if (commonUtils.isDefined(cellValue)) {
                                cell[aggregatorIndex] = aggregator.step(cell[aggregatorIndex], cellValue)
                            }
                        }
                    }
                }
            }

            function aggregationFinalize(measures, cells) {
                $.each(measures, function(aggregatorIndex, cellField) {
                    var aggregator = getAggregator(cellField);
                    if (aggregator.finalize) {
                        $.each(cells, function(_, row) {
                            $.each(row, function(_, cell) {
                                if (cell && void 0 !== cell[aggregatorIndex]) {
                                    cell[aggregatorIndex] = aggregator.finalize(cell[aggregatorIndex])
                                }
                            })
                        })
                    }
                })
            }

            function areValuesEqual(filterValue, fieldValue) {
                if (commonUtils.isArray(filterValue)) {
                    fieldValue = fieldValue || [];
                    for (var i = 0; i < filterValue.length; i++) {
                        if (filterValue[i] !== fieldValue[i]) {
                            return false
                        }
                    }
                    return true
                } else {
                    return filterValue === fieldValue
                }
            }

            function getGroupValue(levels, data) {
                var value = [];
                $.each(levels, function(_, field) {
                    value.push(field.selector(data))
                });
                return value
            }

            function createDimensionFilters(dimension) {
                var filters = [];
                $.each(dimension, function(_, field) {
                    var filter, filterValues = field.filterValues || [],
                        groupName = field.groupName;
                    if (groupName && commonUtils.isNumber(field.groupIndex)) {
                        return
                    }
                    filter = function(dataItem) {
                        var value = field.levels ? getGroupValue(field.levels, dataItem) : field.selector(dataItem),
                            result = false;
                        for (var i = 0; i < filterValues.length; i++) {
                            if (areValuesEqual(filterValues[i], value)) {
                                result = true;
                                break
                            }
                        }
                        return "exclude" === field.filterType ? !result : result
                    };
                    filterValues.length && filters.push(filter)
                });
                return filters
            }

            function createFilter(options) {
                var filters = createDimensionFilters(options.rows).concat(createDimensionFilters(options.columns)).concat(createDimensionFilters(options.filters)),
                    expandedDimensions = options[options.headerName],
                    path = options.path;
                if (expandedDimensions) {
                    filters.push(function(dataItem) {
                        var expandValue;
                        for (var i = 0; i < path.length; i++) {
                            expandValue = expandedDimensions[i].selector(dataItem);
                            if (dataCoreUtils.toComparable(expandValue, true) !== dataCoreUtils.toComparable(path[i], true)) {
                                return false
                            }
                        }
                        return true
                    })
                }
                return function(dataItem) {
                    for (var i = 0; i < filters.length; i++) {
                        if (!filters[i](dataItem)) {
                            return false
                        }
                    }
                    return true
                }
            }

            function loadCore(items, options) {
                var aggregationCells, filter, data, headers = {
                        columns: [],
                        rows: [],
                        columnsHash: {
                            length: 1
                        },
                        rowsHash: {
                            length: 1
                        }
                    },
                    values = [
                        [
                            []
                        ]
                    ],
                    d = $.Deferred(),
                    i = 0;
                prepareLoadOption(options);
                filter = createFilter(options);

                function processData() {
                    var t = new Date,
                        startIndex = i;
                    for (; i < items.length; i++) {
                        if (i > startIndex && i % 1e4 === 0) {
                            if (new Date - t >= 300) {
                                d.notify(i / items.length);
                                setTimeout(processData, 0);
                                return
                            }
                        }
                        data = items[i];
                        if (filter(data)) {
                            aggregationCells = generateAggregationCells(data, values, headers, options);
                            aggregationStep(options.values, aggregationCells, data)
                        }
                    }
                    aggregationFinalize(options.values, values);
                    d.notify(1);
                    d.resolve({
                        rows: headers.rows,
                        columns: headers.columns,
                        values: values,
                        grandTotalRowIndex: 0,
                        grandTotalColumnIndex: 0
                    })
                }
                processData();
                return d
            }

            function createGroupFields(item) {
                return $.map(["year", "quarter", "month"], function(value, index) {
                    return $.extend({}, item, {
                        groupInterval: value,
                        groupIndex: index
                    })
                })
            }

            function parseFields(dataSource, fieldsList, path, fieldsDataType) {
                var result = [];
                $.each(fieldsList || [], function(field, value) {
                    var items, dataIndex = 1,
                        currentPath = path.length ? path + "." + field : field,
                        dataType = fieldsDataType[currentPath],
                        getter = dataCoreUtils.compileGetter(currentPath);
                    while (!commonUtils.isDefined(value) && dataSource[dataIndex]) {
                        value = getter(dataSource[dataIndex]);
                        dataIndex++
                    }
                    if (!dataType && commonUtils.isDefined(value)) {
                        dataType = $.type(value)
                    }
                    items = [{
                        dataField: currentPath,
                        dataType: dataType,
                        groupName: "date" === dataType ? field : void 0,
                        groupInterval: void 0,
                        displayFolder: path
                    }];
                    if ("date" === dataType) {
                        items = items.concat(createGroupFields(items[0]))
                    } else {
                        if ("object" === dataType) {
                            items = parseFields(dataSource, value, currentPath, fieldsDataType)
                        }
                    }
                    result.push.apply(result, items)
                });
                return result
            }

            function discover(items, fieldsDataType) {
                fieldsDataType = fieldsDataType || {};
                return parseFields(items, items[0], "", fieldsDataType)
            }

            function loadDataSource(dataSource, reload) {
                var d = $.Deferred();
                if (!dataSource.isLoaded() || reload) {
                    var loadDeferred = reload ? dataSource.load() : dataSource.reload();
                    $.when(loadDeferred).always(function() {
                        loadDataSource(dataSource).done(d.resolve).fail(d.reject)
                    })
                } else {
                    d.resolve(dataSource.items())
                }
                return d
            }

            function getFilterPathFields(fields, path) {
                var result = [];
                path = path || [];
                for (var i = 0; i < path.length; i++) {
                    result.push($.extend({}, fields[i], {
                        groupIndex: null,
                        groupName: null,
                        filterType: "include",
                        filterValues: [path[i]]
                    }))
                }
                return result
            }
            return {
                ctor: function(options) {
                    options = $.extend(normalizeDataSourceOptions(options), {
                        paginate: false,
                        onChanged: null
                    });
                    this._dataSource = new DataSourceModule.DataSource(options)
                },
                getFields: function(fieldsDataType) {
                    var that = this,
                        dataSource = that._dataSource,
                        d = $.Deferred();
                    loadDataSource(dataSource).done(function(data) {
                        d.resolve(discover(data, fieldsDataType))
                    }).fail(d.reject);
                    return d
                },
                key: function() {
                    return this._dataSource.key()
                },
                load: function(options) {
                    var that = this,
                        dataSource = that._dataSource,
                        d = $.Deferred();
                    loadDataSource(dataSource, options.reload).done(function(data) {
                        $.when(loadCore(data, options)).progress(d.notify).done(d.resolve)
                    }).fail(d.reject);
                    return d
                },
                filter: function() {
                    var dataSource = this._dataSource;
                    return dataSource.filter.apply(dataSource, arguments)
                },
                supportSorting: function() {
                    return false
                },
                getDrillDownItems: function(loadOptions, params) {
                    loadOptions = loadOptions || {};
                    params = params || {};
                    prepareLoadOption(loadOptions);
                    var item, drillDownItems = [],
                        items = this._dataSource.items(),
                        maxRowCount = params.maxRowCount,
                        customColumns = params.customColumns,
                        filter = createFilter(loadOptions),
                        pathFilter = createFilter({
                            rows: getFilterPathFields(loadOptions.rows, params.rowPath),
                            columns: getFilterPathFields(loadOptions.columns, params.columnPath),
                            filters: []
                        });
                    for (var i = 0; i < items.length; i++) {
                        if (pathFilter(items[i]) && filter(items[i])) {
                            if (customColumns) {
                                item = {};
                                for (var j = 0; j < customColumns.length; j++) {
                                    item[customColumns[j]] = items[i][customColumns[j]]
                                }
                            } else {
                                item = items[i]
                            }
                            drillDownItems.push(item)
                        }
                        if (maxRowCount > 0 && drillDownItems.length === maxRowCount) {
                            break
                        }
                    }
                    return drillDownItems
                }
            }
        }())
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/pivot_grid/xmla_store/xmla_store.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../../core/class */ 20),
            stringFormat = __webpack_require__( /*! ../../../core/utils/string */ 13).format,
            errors = __webpack_require__( /*! ../../../data/errors */ 157).errors,
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            pivotGridUtils = __webpack_require__( /*! ../ui.pivot_grid.utils */ 385);
        exports.XmlaStore = Class.inherit(function() {
            var discover = '<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Body><Discover xmlns="urn:schemas-microsoft-com:xml-analysis"><RequestType>{2}</RequestType><Restrictions><RestrictionList><CATALOG_NAME>{0}</CATALOG_NAME><CUBE_NAME>{1}</CUBE_NAME></RestrictionList></Restrictions><Properties><PropertyList><Catalog>{0}</Catalog></PropertyList></Properties></Discover></Body></Envelope>',
                execute = '<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Body><Execute xmlns="urn:schemas-microsoft-com:xml-analysis"><Command><Statement>{0}</Statement></Command><Properties><PropertyList><Catalog>{1}</Catalog><ShowHiddenCubes>True</ShowHiddenCubes><SspropInitAppName>Microsoft SQL Server Management Studio</SspropInitAppName><Timeout>3600</Timeout></PropertyList></Properties></Execute></Body></Envelope>',
                mdx = "SELECT {2} FROM {0} {1} CELL PROPERTIES VALUE, FORMAT_STRING, LANGUAGE, BACK_COLOR, FORE_COLOR, FONT_FLAGS",
                mdxFilterSelect = "(SELECT {0} FROM {1})",
                mdxWith = "{0} {1} as {2}",
                mdxSlice = "WHERE ({0})",
                mdxNonEmpty = "NonEmpty({0}, {1})",
                mdxAxis = "{0} DIMENSION PROPERTIES PARENT_UNIQUE_NAME,HIERARCHY_UNIQUE_NAME, MEMBER_VALUE ON {1}",
                mdxCrossJoin = "CrossJoin({0})",
                mdxSet = "{{0}}",
                each = $.each,
                MEASURE_DEMENSION_KEY = "DX_MEASURES",
                MD_DIMTYPE_MEASURE = "2";

            function execXMLA(requestOptions, data) {
                var deferred = $.Deferred(),
                    beforeSend = requestOptions.beforeSend,
                    ajaxSettings = {
                        url: requestOptions.url,
                        dataType: "text",
                        data: data,
                        headers: {
                            "Content-Type": "text/xml"
                        },
                        xhrFields: {},
                        method: "POST"
                    };
                if (commonUtils.isFunction(beforeSend)) {
                    beforeSend(ajaxSettings)
                }
                pivotGridUtils.sendRequest(ajaxSettings).fail(function() {
                    deferred.reject(arguments)
                }).done(function(text) {
                    var xml;
                    try {
                        xml = $.parseXML(text)
                    } catch (e) {
                        deferred.reject({
                            statusText: e.message,
                            stack: e.stack,
                            responseText: text
                        })
                    }
                    deferred.resolve(xml)
                });
                return deferred
            }

            function mdxDescendants(level, levelMember, nextLevel) {
                levelMember = levelMember ? "." + levelMember : "";
                return "Descendants({" + level + levelMember + "}, " + nextLevel + ", SELF_AND_BEFORE)"
            }

            function getAllMember(dimension) {
                return (dimension.hierarchyName || dimension.dataField) + ".[All]"
            }

            function getAllMembers(field) {
                return field.dataField + ".allMembers"
            }

            function crossJoinElements(elements) {
                var elementsString = elements.join(",");
                return elements.length > 1 ? stringFormat(mdxCrossJoin, elementsString) : elementsString
            }

            function union(elements) {
                var elementsString = elements.join(",");
                return elements.length > 1 ? "Union(" + elementsString + ")" : elementsString
            }

            function generateCrossJoin(path, expandLevel, expandAllCount, expandIndex, slicePath, options, axisName) {
                var dataField, allMember, hierarchyName, arg, prevDimension, prevHierarchyName, isLastDimensionInGroup, isFirstDimensionInGroup, expandAllIndex, field, member, i, crossJoinArgs = [],
                    dimensions = options[axisName],
                    fields = [];
                for (i = expandIndex; i <= expandLevel; i++) {
                    field = dimensions[i];
                    dataField = field.dataField;
                    prevHierarchyName = dimensions[i - 1] && dimensions[i - 1].hierarchyName;
                    hierarchyName = field.hierarchyName;
                    isLastDimensionInGroup = !hierarchyName || !dimensions[i + 1] || dimensions[i + 1].hierarchyName !== hierarchyName;
                    expandAllIndex = path.length + expandAllCount + expandIndex;
                    arg = null;
                    fields.push(field);
                    if (i < path.length) {
                        if (isLastDimensionInGroup) {
                            arg = "(" + dataField + "." + preparePathValue(path[i]) + ")"
                        }
                    } else {
                        if (i <= expandAllIndex) {
                            if (0 === i && 0 === expandAllCount) {
                                allMember = getAllMember(dimensions[expandIndex]);
                                if (!hierarchyName) {
                                    arg = getAllMembers(dimensions[expandIndex])
                                } else {
                                    arg = allMember + "," + dimensions[expandIndex].dataField
                                }
                            } else {
                                if (hierarchyName) {
                                    member = preparePathValue(slicePath[slicePath.length - 1]);
                                    if (isLastDimensionInGroup || i === expandAllIndex) {
                                        if (prevHierarchyName === hierarchyName) {
                                            if (slicePath.length) {
                                                prevDimension = dimensions[slicePath.length - 1]
                                            }
                                            if (!prevDimension || prevDimension.hierarchyName !== hierarchyName) {
                                                prevDimension = dimensions[i - 1];
                                                member = ""
                                            }
                                            arg = mdxDescendants(prevDimension.dataField, member, dataField)
                                        } else {
                                            arg = getAllMembers(field)
                                        }
                                    }
                                } else {
                                    arg = getAllMembers(field)
                                }
                            }
                        } else {
                            isFirstDimensionInGroup = !hierarchyName || prevHierarchyName !== hierarchyName;
                            if (isFirstDimensionInGroup) {
                                arg = "(" + getAllMember(field) + ")"
                            }
                        }
                    }
                    if (arg) {
                        arg = stringFormat(mdxSet, arg);
                        crossJoinArgs.push(arg)
                    }
                }
                return crossJoinElements(crossJoinArgs)
            }

            function fillCrossJoins(crossJoins, path, expandLevel, expandIndex, slicePath, options, axisName, cellsString) {
                var dimensionIndex, expandAllCount = -1,
                    dimensions = options[axisName];
                do {
                    expandAllCount++;
                    dimensionIndex = path.length + expandAllCount + expandIndex;
                    crossJoins.push(stringFormat(mdxNonEmpty, generateCrossJoin(path, expandLevel, expandAllCount, expandIndex, slicePath, options, axisName), cellsString))
                } while (dimensions[dimensionIndex] && dimensions[dimensionIndex + 1] && dimensions[dimensionIndex].expanded)
            }

            function declare(expression, withArray, name, type) {
                name = name || "[DX_Set_" + withArray.length + "]";
                type = type || "set";
                withArray.push(stringFormat(mdxWith, type, name, expression));
                return name
            }

            function generateAxisMdx(options, axisName, cells, withArray, parseOptions) {
                var dimensions = options[axisName],
                    crossJoins = [],
                    path = [],
                    expandedPaths = [],
                    expandIndex = 0,
                    expandLevel = 0,
                    result = [],
                    cellsString = stringFormat(mdxSet, cells.join(","));
                if (dimensions && dimensions.length) {
                    if (options.headerName === axisName) {
                        path = options.path;
                        expandLevel = expandIndex = path.length
                    } else {
                        expandedPaths = ("columns" === axisName ? options.columnExpandedPaths : options.rowExpandedPaths) || expandedPaths;
                        each(expandedPaths, function(_, path) {
                            expandLevel = Math.max(expandLevel, path.length)
                        })
                    }
                    while (dimensions[expandLevel + 1] && dimensions[expandLevel].expanded) {
                        expandLevel++
                    }
                    fillCrossJoins(crossJoins, [], expandLevel, expandIndex, path, options, axisName, cellsString);
                    each(expandedPaths, function(_, expandedPath) {
                        fillCrossJoins(crossJoins, expandedPath, expandLevel, expandIndex, expandedPath, options, axisName, cellsString)
                    });
                    for (var i = expandLevel; i >= path.length; i--) {
                        if (dimensions[i].hierarchyName) {
                            parseOptions.visibleLevels[dimensions[i].hierarchyName] = parseOptions.visibleLevels[dimensions[i].hierarchyName] || [];
                            parseOptions.visibleLevels[dimensions[i].hierarchyName].push(dimensions[i].dataField)
                        }
                    }
                }
                if (crossJoins.length) {
                    result.push(declare(union(crossJoins), withArray, "[DX_" + axisName + "]"))
                }
                if ("columns" === axisName && cells.length) {
                    result.push(cellsString)
                }
                return stringFormat(mdxAxis, crossJoinElements(result), axisName)
            }

            function generateAxisFieldsFilter(fields) {
                var filterMembers = [];
                each(fields, function(_, field) {
                    var filterStringExpression, dataField = field.dataField,
                        filterExpression = [],
                        filterValues = field.filterValues || [];
                    if (field.hierarchyName && commonUtils.isNumber(field.groupIndex)) {
                        return
                    }
                    each(filterValues, function(_, filterValue) {
                        var filterMdx = dataField + "." + preparePathValue(commonUtils.isArray(filterValue) ? filterValue[filterValue.length - 1] : filterValue);
                        if ("exclude" === field.filterType) {
                            filterExpression.push(filterMdx + ".parent");
                            filterMdx = "Descendants(" + filterMdx + ")"
                        }
                        filterExpression.push(filterMdx)
                    });
                    if (filterValues.length) {
                        filterStringExpression = stringFormat(mdxSet, filterExpression.join(","));
                        if ("exclude" === field.filterType) {
                            filterStringExpression = "Except(" + getAllMembers(field) + "," + filterStringExpression + ")"
                        }
                        filterMembers.push(filterStringExpression)
                    }
                });
                return filterMembers.length ? crossJoinElements(filterMembers) : ""
            }

            function generateFrom(columnsFilter, rowsFilter, filter, cubeName) {
                var from = "[" + cubeName + "]";
                each([columnsFilter, rowsFilter, filter], function(_, filter) {
                    if (filter) {
                        from = stringFormat(mdxFilterSelect, filter + "on 0", from)
                    }
                });
                return from
            }

            function generateMdxCore(axisStrings, withArray, columns, rows, filters, slice, cubeName) {
                var mdxString = "",
                    withString = (withArray.length ? "with " + withArray.join(" ") : "") + " ";
                if (axisStrings.length) {
                    mdxString = withString + stringFormat(mdx, generateFrom(generateAxisFieldsFilter(columns), generateAxisFieldsFilter(rows), generateAxisFieldsFilter(filters || []), cubeName), slice.length ? stringFormat(mdxSlice, slice.join(",")) : "", axisStrings.join(","))
                }
                return mdxString
            }

            function prepareDataFields(withArray, valueFields) {
                return $.map(valueFields, function(cell) {
                    if (commonUtils.isString(cell.expression)) {
                        declare(cell.expression, withArray, cell.dataField, "member")
                    }
                    return cell.dataField
                })
            }

            function generateMDX(options, cubeName, parseOptions) {
                var columns = options.columns || [],
                    rows = options.rows || [],
                    values = options.values && options.values.length ? options.values : [{
                        dataField: "[Measures]"
                    }],
                    slice = [],
                    withArray = [],
                    axisStrings = [],
                    dataFields = prepareDataFields(withArray, values);
                parseOptions.measureCount = values.length;
                parseOptions.visibleLevels = {};
                if (options.headerName && options.path) {
                    each(options.path, function(index, value) {
                        var dimension = options[options.headerName][index];
                        if (!dimension.hierarchyName || dimension.hierarchyName !== options[options.headerName][index + 1].hierarchyName) {
                            slice.push(dimension.dataField + "." + preparePathValue(value))
                        }
                    })
                }
                if (columns.length || dataFields.length) {
                    axisStrings.push(generateAxisMdx(options, "columns", dataFields, withArray, parseOptions))
                }
                if (rows.length) {
                    axisStrings.push(generateAxisMdx(options, "rows", dataFields, withArray, parseOptions))
                }
                return generateMdxCore(axisStrings, withArray, columns, rows, options.filters, slice, cubeName)
            }

            function createDrillDownAxisSlice(slice, fields, path) {
                each(path, function(index, value) {
                    var field = fields[index];
                    if (field.hierarchyName && (fields[index + 1] || {}).hierarchyName === field.hierarchyName) {
                        return
                    }
                    slice.push(field.dataField + "." + preparePathValue(value))
                })
            }

            function generateDrillDownMDX(options, cubeName, params) {
                var coreMDX, columns = options.columns || [],
                    rows = options.rows || [],
                    values = options.values && options.values.length ? options.values : [{
                        dataField: "[Measures]"
                    }],
                    slice = [],
                    withArray = [],
                    axisStrings = [],
                    dataFields = prepareDataFields(withArray, values),
                    maxRowCount = params.maxRowCount,
                    customColumns = params.customColumns || [],
                    customColumnsString = customColumns.length > 0 ? " return " + customColumns.join(",") : "";
                createDrillDownAxisSlice(slice, columns, params.columnPath || []);
                createDrillDownAxisSlice(slice, rows, params.rowPath || []);
                if (columns.length || columns.length || dataFields.length) {
                    axisStrings.push([(dataFields[params.dataIndex] || dataFields[0]) + " on 0"])
                }
                coreMDX = generateMdxCore(axisStrings, withArray, columns, rows, options.filters, slice, cubeName);
                return coreMDX ? "drillthrough" + (maxRowCount > 0 ? " maxrows " + maxRowCount : "") + coreMDX + customColumnsString : coreMDX
            }

            function getNumber(str) {
                return parseInt(str, 10)
            }

            function parseValue(valueText) {
                return $.isNumeric(valueText) ? parseFloat(valueText) : valueText
            }

            function getFirstChild(node, tagName) {
                return (node.getElementsByTagName(tagName) || [])[0]
            }

            function getFirstChildText(node, childTagName) {
                return getNodeText(getFirstChild(node, childTagName))
            }

            function parseAxes(xml) {
                var axes = [];
                each(xml.getElementsByTagName("Axis"), function(_, axisElement) {
                    var name = axisElement.getAttribute("name"),
                        axis = [],
                        index = 0;
                    if (0 === name.indexOf("Axis") && commonUtils.isNumber(getNumber(name.substr(4)))) {
                        axes.push(axis);
                        each(axisElement.getElementsByTagName("Tuple"), function(_, tupleElement) {
                            var tuple, level, i, tupleMembers = tupleElement.childNodes,
                                levelSum = 0,
                                members = [],
                                membersCount = tupleMembers.length - 1,
                                isAxisWithMeasure = 1 === axes.length;
                            if (isAxisWithMeasure) {
                                membersCount--
                            }
                            axis.push(members);
                            for (i = membersCount; i >= 0; i--) {
                                tuple = tupleMembers[i];
                                level = getNumber(getFirstChildText(tuple, "LNum"));
                                members[i] = {
                                    caption: getFirstChildText(tuple, "Caption"),
                                    value: parseValue(getFirstChildText(tuple, "MEMBER_VALUE")),
                                    level: level,
                                    index: index++,
                                    hasValue: !levelSum && (!!level || 0 === i),
                                    name: getFirstChildText(tuple, "UName"),
                                    hierarchyName: tupleMembers[i].getAttribute("Hierarchy"),
                                    parentName: getFirstChildText(tuple, "PARENT_UNIQUE_NAME"),
                                    levelName: getFirstChildText(tuple, "LName")
                                };
                                levelSum += level
                            }
                        })
                    }
                });
                while (axes.length < 2) {
                    axes.push([
                        [{
                            level: 0
                        }]
                    ])
                }
                return axes
            }

            function getNodeText(node) {
                return node && node && (node.textContent || node.text || node.innerHTML) || ""
            }

            function parseCells(xml, axes, measureCount) {
                var measureIndex, row, cells = [],
                    cell = [],
                    index = 0,
                    cellsOriginal = [],
                    cellElements = xml.getElementsByTagName("Cell");
                for (var i = 0; i < cellElements.length; i++) {
                    var xmlCell = cellElements[i],
                        valueElement = xmlCell.getElementsByTagName("Value")[0],
                        text = getNodeText(valueElement),
                        value = parseFloat(text),
                        isNumeric = text - value + 1 > 0;
                    cellsOriginal[getNumber(xmlCell.getAttribute("CellOrdinal"))] = {
                        value: isNumeric ? value : text || null
                    }
                }
                each(axes[1], function() {
                    row = [];
                    cells.push(row);
                    each(axes[0], function() {
                        measureIndex = index % measureCount;
                        if (0 === measureIndex) {
                            cell = [];
                            row.push(cell)
                        }
                        cell.push(cellsOriginal[index] ? cellsOriginal[index].value : null);
                        index++
                    })
                });
                return cells
            }

            function preparePathValue(pathValue) {
                if (pathValue) {
                    return commonUtils.isString(pathValue) && pathValue.indexOf("&[") !== -1 ? pathValue : "[" + pathValue + "]"
                }
            }

            function getItem(hash, name, member, index) {
                var item = hash[name];
                if (!item) {
                    item = {};
                    hash[name] = item
                }
                if (!item.value && member) {
                    item.text = member.caption;
                    item.value = member.value;
                    item.key = name ? name.slice(name.indexOf("&[")) : "";
                    item.levelName = member.levelName;
                    item.hierarchyName = member.hierarchyName;
                    item.parentName = member.parentName;
                    item.index = index;
                    item.level = member.level
                }
                return item
            }

            function getVisibleChildren(item, visibleLevels) {
                var result = [],
                    children = item.children && (item.children.length ? item.children : $.map(item.children.grandTotalHash || [], function(e) {
                        return e.children
                    })),
                    firstChild = children && children[0];
                if (firstChild && (visibleLevels[firstChild.hierarchyName] && $.inArray(firstChild.levelName, visibleLevels[firstChild.hierarchyName]) !== -1 || !visibleLevels[firstChild.hierarchyName] || 0 === firstChild.level)) {
                    var newChildren = $.map(children, function(child) {
                        return child.hierarchyName === firstChild.hierarchyName ? child : null
                    });
                    newChildren.grandTotalHash = children.grandTotalHash;
                    return newChildren
                } else {
                    if (firstChild) {
                        for (var i = 0; i < children.length; i++) {
                            if (children[i].hierarchyName === firstChild.hierarchyName) {
                                result.push.apply(result, getVisibleChildren(children[i], visibleLevels))
                            }
                        }
                    }
                }
                return result
            }

            function processMember(dataIndex, member, parentItem) {
                var currentItem, children = parentItem.children = parentItem.children || [],
                    hash = children.hash = children.hash || {},
                    grandTotalHash = children.grandTotalHash = children.grandTotalHash || {};
                if (member.parentName) {
                    parentItem = getItem(hash, member.parentName);
                    children = parentItem.children = parentItem.children || []
                }
                currentItem = getItem(hash, member.name, member, dataIndex);
                if (member.hasValue && !currentItem.added) {
                    currentItem.index = dataIndex;
                    currentItem.added = true;
                    children.push(currentItem)
                }
                if ((!parentItem.value || !parentItem.parentName) && member.parentName) {
                    grandTotalHash[member.parentName] = parentItem
                } else {
                    if (grandTotalHash[parentItem.name]) {
                        delete grandTotalHash[member.parentName]
                    }
                }
                return currentItem
            }

            function getGrandTotalIndex(parentItem, visibleLevels) {
                var grandTotalIndex;
                if (1 === parentItem.children.length && "" === parentItem.children[0].parentName) {
                    grandTotalIndex = parentItem.children[0].index;
                    var grandTotalHash = parentItem.children.grandTotalHash;
                    parentItem.children = parentItem.children[0].children || [];
                    parentItem.children.grandTotalHash = grandTotalHash;
                    parentItem.children = getVisibleChildren(parentItem, visibleLevels)
                } else {
                    if (0 === parentItem.children.length) {
                        grandTotalIndex = 0
                    }
                }
                return grandTotalIndex
            }

            function fillDataSourceAxes(dataSourceAxis, axisTuples, measureCount, visibleLevels) {
                var grandTotalIndex, result = [];
                each(axisTuples, function(tupleIndex, members) {
                    var parentItem = {
                            children: result
                        },
                        dataIndex = commonUtils.isDefined(measureCount) ? Math.floor(tupleIndex / measureCount) : tupleIndex;
                    each(members, function(_, member) {
                        parentItem = processMember(dataIndex, member, parentItem)
                    })
                });
                var parentItem = {
                    children: result
                };
                parentItem.children = getVisibleChildren(parentItem, visibleLevels);
                grandTotalIndex = getGrandTotalIndex(parentItem, visibleLevels);
                pivotGridUtils.foreachTree(parentItem.children, function(items) {
                    var item = items[0],
                        children = getVisibleChildren(item, visibleLevels);
                    if (children.length) {
                        item.children = children
                    } else {
                        delete item.children
                    }
                    delete item.levelName;
                    delete item.hierarchyName;
                    delete item.added;
                    delete item.parentName;
                    delete item.level
                }, true);
                each(parentItem.children || [], function(_, e) {
                    dataSourceAxis.push(e)
                });
                return grandTotalIndex
            }

            function checkError(xml) {
                var description, error, errorElement = $(xml).find("Error");
                if (errorElement.length) {
                    description = errorElement.attr("Description");
                    error = new errors.Error("E4000", description);
                    errors.log("E4000", description);
                    return error
                }
                return null
            }

            function parseResult(xml, parseOptions) {
                var axes, dataSource = {
                        columns: [],
                        rows: []
                    },
                    measureCount = parseOptions.measureCount;
                axes = parseAxes(xml);
                dataSource.grandTotalColumnIndex = fillDataSourceAxes(dataSource.columns, axes[0], measureCount, parseOptions.visibleLevels);
                dataSource.grandTotalRowIndex = fillDataSourceAxes(dataSource.rows, axes[1], void 0, parseOptions.visibleLevels);
                dataSource.values = parseCells(xml, axes, measureCount);
                return dataSource
            }

            function parseDiscoverRowSet(xml, schema, dimensions) {
                var result = [],
                    isMeasure = "MEASURE" === schema,
                    displayFolderField = isMeasure ? "MEASUREGROUP_NAME" : schema + "_DISPLAY_FOLDER";
                each(xml.getElementsByTagName("row"), function(_, row) {
                    var hierarchyName = "LEVEL" === schema ? getFirstChildText(row, "HIERARCHY_UNIQUE_NAME") : void 0,
                        levelNumber = getFirstChildText(row, "LEVEL_NUMBER");
                    if (("0" !== levelNumber || "true" !== getFirstChildText(row, schema + "_IS_VISIBLE")) && getFirstChildText(row, "DIMENSION_TYPE") !== MD_DIMTYPE_MEASURE) {
                        var dimension = isMeasure ? MEASURE_DEMENSION_KEY : getFirstChildText(row, "DIMENSION_UNIQUE_NAME"),
                            dataField = getFirstChildText(row, schema + "_UNIQUE_NAME");
                        result.push({
                            dimension: dimensions.names[dimension] || dimension,
                            groupIndex: levelNumber ? getNumber(levelNumber) - 1 : void 0,
                            dataField: dataField,
                            caption: getFirstChildText(row, schema + "_CAPTION"),
                            hierarchyName: hierarchyName,
                            groupName: hierarchyName,
                            displayFolder: getFirstChildText(row, displayFolderField),
                            isMeasure: isMeasure,
                            isDefault: !!dimensions.defaultHierarchies[dataField]
                        })
                    }
                });
                return result
            }

            function parseDimensionsDiscoverRowSet(xml) {
                var result = {
                    names: {},
                    defaultHierarchies: {}
                };
                each($(xml).find("row"), function() {
                    var $row = $(this),
                        type = $row.children("DIMENSION_TYPE").text(),
                        dimensionName = type === MD_DIMTYPE_MEASURE ? MEASURE_DEMENSION_KEY : $row.children("DIMENSION_UNIQUE_NAME").text();
                    result.names[dimensionName] = $row.children("DIMENSION_CAPTION").text();
                    result.defaultHierarchies[$row.children("DEFAULT_HIERARCHY").text()] = true
                });
                return result
            }

            function parseStringWithUnicodeSymbols(str) {
                str = str.replace(/_x(....)_/g, function(whole, group1) {
                    return String.fromCharCode(parseInt(group1, 16))
                });
                var stringArray = str.match(/\[.+?\]/gi);
                if (stringArray && stringArray.length) {
                    str = stringArray[stringArray.length - 1]
                }
                return str.replace(/\[/gi, "").replace(/\]/gi, "").replace(/\$/gi, "").replace(/\./gi, " ")
            }

            function parseDrillDownRowset(xml) {
                var rows = xml.getElementsByTagName("row"),
                    result = [],
                    columnNames = {};
                for (var i = 0; i < rows.length; i++) {
                    var children = rows[i].childNodes,
                        item = {};
                    for (var j = 0; j < children.length; j++) {
                        var tagName = children[j].tagName,
                            name = columnNames[tagName] = columnNames[tagName] || parseStringWithUnicodeSymbols(tagName);
                        item[name] = getNodeText(children[j])
                    }
                    result.push(item)
                }
                return result
            }

            function sendQuery(storeOptions, mdxString) {
                mdxString = $("<div>").text(mdxString).html();
                return execXMLA(storeOptions, stringFormat(execute, mdxString, storeOptions.catalog))
            }
            return {
                ctor: function(options) {
                    this._options = options
                },
                getFields: function() {
                    var options = this._options,
                        catalog = options.catalog,
                        cube = options.cube,
                        dimensionsRequest = execXMLA(options, stringFormat(discover, catalog, cube, "MDSCHEMA_DIMENSIONS")),
                        measuresRequest = execXMLA(options, stringFormat(discover, catalog, cube, "MDSCHEMA_MEASURES")),
                        hierarchiesRequest = execXMLA(options, stringFormat(discover, catalog, cube, "MDSCHEMA_HIERARCHIES")),
                        levelsRequest = execXMLA(options, stringFormat(discover, catalog, cube, "MDSCHEMA_LEVELS")),
                        result = $.Deferred();
                    $.when(dimensionsRequest, measuresRequest, hierarchiesRequest, levelsRequest).done(function(dimensionsResponse, measuresResponse, hierarchiesResponse, levelsResponse) {
                        var dimensions = parseDimensionsDiscoverRowSet(dimensionsResponse),
                            hierarchies = parseDiscoverRowSet(hierarchiesResponse, "HIERARCHY", dimensions),
                            levels = parseDiscoverRowSet(levelsResponse, "LEVEL", dimensions),
                            fields = parseDiscoverRowSet(measuresResponse, "MEASURE", dimensions).concat(hierarchies),
                            levelsByHierarchy = {};
                        each(levels, function(_, level) {
                            levelsByHierarchy[level.hierarchyName] = levelsByHierarchy[level.hierarchyName] || [];
                            levelsByHierarchy[level.hierarchyName].push(level)
                        });
                        each(hierarchies, function(_, hierarchy) {
                            if (levelsByHierarchy[hierarchy.dataField] && levelsByHierarchy[hierarchy.dataField].length > 1) {
                                hierarchy.groupName = hierarchy.hierarchyName = hierarchy.dataField;
                                fields.push.apply(fields, levelsByHierarchy[hierarchy.hierarchyName])
                            }
                        });
                        result.resolve(fields)
                    }).fail(result.reject);
                    return result
                },
                load: function(options) {
                    var result = $.Deferred(),
                        storeOptions = this._options,
                        parseOptions = {},
                        mdxString = generateMDX(options, storeOptions.cube, parseOptions);
                    if (mdxString) {
                        $.when(sendQuery(storeOptions, mdxString)).done(function(executeXml) {
                            var error = checkError(executeXml);
                            if (!error) {
                                result.resolve(parseResult(executeXml, parseOptions))
                            } else {
                                result.reject(error)
                            }
                        }).fail(result.reject)
                    } else {
                        result.resolve({
                            columns: [],
                            rows: [],
                            values: [],
                            grandTotalColumnIndex: 0,
                            grandTotalRowIndex: 0
                        })
                    }
                    return result
                },
                supportSorting: function() {
                    return true
                },
                getDrillDownItems: function(options, params) {
                    var result = $.Deferred(),
                        storeOptions = this._options,
                        mdxString = generateDrillDownMDX(options, storeOptions.cube, params);
                    if (mdxString) {
                        $.when(sendQuery(storeOptions, mdxString)).done(function(executeXml) {
                            var error = checkError(executeXml);
                            if (!error) {
                                result.resolve(parseDrillDownRowset(executeXml))
                            } else {
                                result.reject(error)
                            }
                        }).fail(result.reject)
                    } else {
                        result.resolve([])
                    }
                    return result
                },
                key: $.noop,
                filter: $.noop
            }
        }())
    },
    /*!**********************************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.summary_display_modes.js ***!
      \**********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isDefined = commonUtils.isDefined,
            pivotGridUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            findField = pivotGridUtils.findField,
            foreachTree = pivotGridUtils.foreachTree,
            COLUMN = "column",
            ROW = "row",
            NULL = null,
            percentOfGrandTotal = function(e, dimension) {
                var parent = e.grandTotal(dimension);
                if (isDefined(e.value())) {
                    return e.value() / parent.value()
                }
                return NULL
            },
            percentOfParent = function(e, dimension) {
                var parent = e.parent(dimension),
                    parentValue = parent ? parent.value() : e.value();
                if (isDefined(e.value())) {
                    return e.value() / parentValue
                }
                return NULL
            },
            createAbsoluteVariationExp = function(allowGrossGroup) {
                return function(e) {
                    var prevCell = e.prev(COLUMN, allowGrossGroup),
                        prevValue = prevCell && prevCell.value();
                    if (isDefined(prevValue) && isDefined(e.value())) {
                        return e.value() - prevValue
                    }
                    return NULL
                }
            },
            createPercentVariationExp = function(allowGrossGroup) {
                var absoluteExp = createAbsoluteVariationExp(allowGrossGroup);
                return function(e) {
                    var absVar = absoluteExp(e);
                    return absVar !== NULL ? absVar / e.prev(COLUMN, allowGrossGroup).value() : NULL
                }
            },
            summaryDictionary = {
                percentOfColumnTotal: function(e) {
                    return percentOfParent(e, ROW)
                },
                percentOfRowTotal: function(e) {
                    return percentOfParent(e, COLUMN)
                },
                percentOfColumnGrandTotal: function(e) {
                    return percentOfGrandTotal(e, ROW)
                },
                percentOfRowGrandTotal: function(e) {
                    return percentOfGrandTotal(e, COLUMN)
                },
                percentOfGrandTotal: function(e) {
                    return percentOfGrandTotal(e)
                }
            },
            getPrevCellCrossGroup = function(cell, direction) {
                if (!cell || !cell.parent(direction)) {
                    return
                }
                var prevCell = cell.prev(direction);
                if (!prevCell) {
                    prevCell = getPrevCellCrossGroup(cell.parent(direction), direction)
                }
                return prevCell
            },
            createRunningTotalExpr = function(getValue, allowGrossGroupCalculation, direction) {
                direction = direction === COLUMN ? ROW : COLUMN;
                return function(e) {
                    var prevCell = allowGrossGroupCalculation ? getPrevCellCrossGroup(e, direction) : e.prev(direction, false),
                        value = getValue(e);
                    return (prevCell && prevCell.value(true) || 0) + (value || 0)
                }
            },
            defaultExpr = function(e) {
                return e.value()
            };

        function getFieldPos(descriptions, field) {
            var fieldIndex, allFields, fieldParams = {
                index: -1
            };
            if (!commonUtils.isObject(field)) {
                allFields = descriptions.columns.concat(descriptions.rows).concat(descriptions.values);
                fieldIndex = findField(allFields, field);
                field = allFields[fieldIndex]
            }
            if (field) {
                fieldParams.area = field.area || "data";
                fieldParams.index = $.inArray(field, descriptions["data" === fieldParams.area ? "values" : fieldParams.area + "s"])
            }
            return fieldParams
        }

        function getPathFieldName(dimension) {
            return dimension === ROW ? "_rowPath" : "_columnPath"
        }
        var SummaryCell = function(columnPath, rowPath, data, descriptions, fieldIndex) {
            this._columnPath = columnPath;
            this._rowPath = rowPath;
            this._fieldIndex = fieldIndex;
            this._data = data;
            this._descriptions = descriptions;
            var cell = data.values && data.values[rowPath[0].index] && data.values[rowPath[0].index][columnPath[0].index];
            if (cell) {
                cell.originalCell = cell.originalCell || cell.slice();
                this._cell = cell
            }
        };
        SummaryCell.prototype = $.extend(SummaryCell.prototype, {
            _getPath: function(dimension) {
                return this[getPathFieldName(dimension)]
            },
            _getDimension: function(dimension) {
                dimension = dimension === ROW ? "rows" : "columns";
                return this._descriptions[dimension]
            },
            _createCell: function(config) {
                var that = this;
                return new SummaryCell(config._columnPath || that._columnPath, config._rowPath || that._rowPath, that._data, that._descriptions, that._fieldIndex)
            },
            parent: function(direction) {
                var path = this._getPath(direction).slice(),
                    config = {};
                path.shift();
                if (path.length) {
                    config[getPathFieldName(direction)] = path;
                    return this._createCell(config)
                }
                return NULL
            },
            children: function(direction) {
                var path = this._getPath(direction).slice(),
                    item = path[0],
                    result = [],
                    cellConfig = {};
                if (item.children) {
                    for (var i = 0; i < item.children.length; i++) {
                        cellConfig[getPathFieldName(direction)] = [item.children[i]].concat(path.slice());
                        result.push(this._createCell(cellConfig))
                    }
                }
                return result
            },
            grandTotal: function(direction) {
                var config = {},
                    rowPath = this._rowPath,
                    columnPath = this._columnPath,
                    dimensionPath = this._getPath(direction),
                    pathFieldName = getPathFieldName(direction);
                if (!direction) {
                    config._rowPath = [rowPath[rowPath.length - 1]];
                    config._columnPath = [columnPath[columnPath.length - 1]]
                } else {
                    config[pathFieldName] = [dimensionPath[dimensionPath.length - 1]]
                }
                return this._createCell(config)
            },
            next: function(direction, allowGrossGroup) {
                var siblings, index, currentPath = this._getPath(direction),
                    item = currentPath[0],
                    parent = this.parent(direction);
                if (parent) {
                    index = $.inArray(item, currentPath[1].children);
                    siblings = parent.children(direction);
                    if (siblings[index + 1]) {
                        return siblings[index + 1]
                    }
                }
                if (allowGrossGroup && parent) {
                    do {
                        parent = parent.next(direction, allowGrossGroup);
                        siblings = parent ? parent.children(direction) : []
                    } while (parent && !siblings.length);
                    return siblings[0] || NULL
                }
                return NULL
            },
            prev: function(direction, allowGrossGroup) {
                var siblings, index, currentPath = this._getPath(direction),
                    item = currentPath[0],
                    parent = this.parent(direction);
                if (parent) {
                    index = $.inArray(item, currentPath[1].children);
                    siblings = parent.children(direction);
                    if (siblings[index - 1]) {
                        return siblings[index - 1]
                    }
                }
                if (allowGrossGroup && parent) {
                    do {
                        parent = parent.prev(direction, allowGrossGroup);
                        siblings = parent ? parent.children(direction) : []
                    } while (parent && !siblings.length);
                    return siblings[siblings.length - 1] || NULL
                }
                return NULL
            },
            cell: function() {
                return this._cell
            },
            field: function(area) {
                var path = this._getPath(area),
                    descriptions = this._getDimension(area),
                    field = descriptions[path.length - 2];
                return field || NULL
            },
            child: function(direction, fieldValue) {
                var childLevelField, children = this.children(direction);
                for (var i = 0; i < children.length; i++) {
                    childLevelField = childLevelField || children[i].field(direction);
                    if (children[i].value(childLevelField) === fieldValue) {
                        return children[i]
                    }
                }
                return NULL
            },
            slice: function(field, value) {
                var childItems, path, currentValue, level, that = this,
                    config = {},
                    fieldPos = getFieldPos(this._descriptions, field),
                    area = fieldPos.area,
                    fieldIndex = fieldPos.index,
                    sliceCell = NULL,
                    newPath = [];
                if (area === ROW || area === COLUMN) {
                    path = this._getPath(area).slice();
                    level = fieldIndex !== -1 && path.length - 2 - fieldIndex;
                    if (path[level]) {
                        newPath[path.length - 1] = path[path.length - 1];
                        for (var i = level; i >= 0; i--) {
                            if (path[i + 1]) {
                                childItems = path[i + 1].children || [];
                                currentValue = i === level ? value : path[i].value;
                                path[i] = void 0;
                                for (var childIndex = 0; childIndex < childItems.length; childIndex++) {
                                    if (childItems[childIndex].value === currentValue) {
                                        path[i] = childItems[childIndex];
                                        break
                                    }
                                }
                            }
                            if (void 0 === path[i]) {
                                return sliceCell
                            }
                        }
                        config[getPathFieldName(area)] = path;
                        sliceCell = that._createCell(config)
                    }
                }
                return sliceCell
            },
            value: function() {
                var path, level, cell = this._cell,
                    fieldIndex = this._fieldIndex,
                    args = arguments,
                    fistArgIsBoolean = true === args[0] || false === args[0],
                    field = !fistArgIsBoolean ? args[0] : NULL,
                    needCalculatedValue = fistArgIsBoolean && args[0] || args[1];
                if (isDefined(field)) {
                    var fieldPos = getFieldPos(this._descriptions, field);
                    fieldIndex = fieldPos.index;
                    if ("data" !== fieldPos.area) {
                        path = this._getPath(fieldPos.area);
                        level = fieldIndex !== -1 && path.length - 2 - fieldIndex;
                        return path[level] && path[level].value
                    }
                }
                if (cell && cell.originalCell) {
                    return needCalculatedValue ? cell[fieldIndex] : cell.originalCell[fieldIndex]
                }
                return NULL
            }
        });

        function getExpression(field) {
            var summaryDisplayMode = field.summaryDisplayMode,
                crossGroupCalculation = field.allowCrossGroupCalculation,
                expression = NULL;
            if (commonUtils.isFunction(field.calculateSummaryValue)) {
                expression = field.calculateSummaryValue
            } else {
                if (summaryDisplayMode) {
                    if ("absoluteVariation" === summaryDisplayMode) {
                        expression = createAbsoluteVariationExp(crossGroupCalculation)
                    } else {
                        if ("percentVariation" === summaryDisplayMode) {
                            expression = createPercentVariationExp(crossGroupCalculation)
                        } else {
                            expression = summaryDictionary[summaryDisplayMode]
                        }
                    }
                    if (expression && !field.format && summaryDisplayMode.indexOf("percent") !== -1) {
                        pivotGridUtils.setFieldProperty(field, "format", "percent")
                    }
                }
            }
            if (field.runningTotal) {
                expression = expression || defaultExpr;
                return createRunningTotalExpr(expression, crossGroupCalculation, field.runningTotal)
            }
            return expression
        }
        exports.applyDisplaySummaryMode = function(descriptions, data) {
            var expressions = [],
                columnElements = [{
                    index: data.grandTotalColumnIndex,
                    children: data.columns
                }],
                rowElements = [{
                    index: data.grandTotalRowIndex,
                    children: data.rows
                }],
                valueFields = descriptions.values;
            data.values = data.values || [];
            foreachTree(rowElements, function(rowPath) {
                var rowItem = rowPath[0];
                rowItem.isEmpty = true;
                data.values[rowItem.index] = data.values[rowItem.index] || [];
                foreachTree(columnElements, function(columnPath) {
                    var expression, expressionArg, cell, field, isEmptyCell, value, columnItem = columnPath[0];
                    columnItem.isEmpty = columnItem.isEmpty || [];
                    data.values[rowItem.index][columnItem.index] = data.values[rowItem.index][columnItem.index] || [];
                    for (var i = 0; i < valueFields.length; i++) {
                        field = valueFields[i];
                        expression = expressions[i] = expressions[i] || getExpression(field);
                        isEmptyCell = false;
                        if (expression) {
                            expressionArg = new SummaryCell(columnPath, rowPath, data, descriptions, i);
                            cell = expressionArg.cell();
                            value = cell[i] = expression(expressionArg);
                            isEmptyCell = null === value || void 0 === value
                        }
                        if (void 0 === columnItem.isEmpty[i]) {
                            columnItem.isEmpty[i] = true
                        }
                        if (!isEmptyCell) {
                            columnItem.isEmpty[i] = false;
                            rowItem.isEmpty = false
                        }
                    }
                }, false)
            }, false);
            data.isEmptyGrandTotalRow = rowElements[0].isEmpty;
            data.isEmptyGrandTotalColumn = columnElements[0].isEmpty
        };
        exports.createMockSummaryCell = function(descriptions, fields, indices) {
            var summaryCell = new SummaryCell([], [], {}, descriptions, 0);
            summaryCell.value = function(fieldId) {
                if (commonUtils.isDefined(fieldId)) {
                    var index = findField(fields, fieldId),
                        field = fields[index];
                    if (!indices[index] && field && !commonUtils.isDefined(field.area)) {
                        descriptions.values.push(field);
                        indices[index] = true
                    }
                }
            };
            summaryCell.grandTotal = function() {
                return this
            };
            summaryCell.children = function() {
                return []
            };
            return summaryCell
        };
        exports.Cell = SummaryCell;
        exports.summaryDictionary = summaryDictionary;
        exports.getExpression = getExpression
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.data_area.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            areaItem = __webpack_require__( /*! ./ui.pivot_grid.area_item */ 392);
        var PIVOTGRID_AREA_CLASS = "dx-pivotgrid-area",
            PIVOTGRID_AREA_DATA_CLASS = "dx-pivotgrid-area-data",
            PIVOTGRID_TOTAL_CLASS = "dx-total",
            PIVOTGRID_GRAND_TOTAL_CLASS = "dx-grandtotal",
            PIVOTGRID_ROW_TOTAL_CLASS = "dx-row-total";
        exports.DataArea = areaItem.AreaItem.inherit({
            _getAreaName: function() {
                return "data"
            },
            _createGroupElement: function() {
                return $("<div>").addClass(PIVOTGRID_AREA_CLASS).addClass(PIVOTGRID_AREA_DATA_CLASS)
            },
            _applyCustomStyles: function(options) {
                var cell = options.cell,
                    classArray = options.classArray;
                if ("T" === cell.rowType || "T" === cell.columnType) {
                    classArray.push(PIVOTGRID_TOTAL_CLASS)
                }
                if ("GT" === cell.rowType || "GT" === cell.columnType) {
                    classArray.push(PIVOTGRID_GRAND_TOTAL_CLASS)
                }
                if ("T" === cell.rowType || "GT" === cell.rowType) {
                    classArray.push(PIVOTGRID_ROW_TOTAL_CLASS)
                }
                if (options.rowIndex === options.rowsCount - 1) {
                    options.cssArray.push("border-bottom: 0px")
                }
                this.callBase(options)
            },
            _moveFakeTable: function(scrollPos) {
                this._moveFakeTableLeft(scrollPos.x);
                this._moveFakeTableTop(scrollPos.y);
                this.callBase()
            },
            processScroll: function(useNativeScrolling) {
                this._groupElement.css("border-top-width", 0).dxScrollable({
                    useNative: !!useNativeScrolling,
                    useSimulatedScrollbar: !useNativeScrolling,
                    direction: "both",
                    bounceEnabled: false,
                    updateManually: true
                })
            },
            setVirtualContentParams: function(params) {
                this.callBase(params);
                this._virtualContent.parent().height(params.height);
                this.tableElement().css({
                    top: params.top,
                    left: params.left
                })
            }
        })
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.area_item.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14);
        var PIVOTGRID_EXPAND_CLASS = "dx-expand";
        var getRealElementWidth = function(element) {
            var clientRect, width = 0;
            if (element.getBoundingClientRect) {
                clientRect = element.getBoundingClientRect();
                width = clientRect.width;
                if (!width) {
                    width = clientRect.right - clientRect.left
                }
            }
            if (width > 0) {
                return width
            } else {
                return element.offsetWidth
            }
        };

        function getFakeTableOffset(scrollPos, elementOffset, tableSize, viewPortSize) {
            var offset = 0,
                halfTableCount = 0,
                halfTableSize = tableSize / 2;
            if (scrollPos + viewPortSize - (elementOffset + tableSize) > 1) {
                if (scrollPos >= elementOffset + tableSize + halfTableSize) {
                    halfTableCount = parseInt((scrollPos - (elementOffset + tableSize)) / halfTableSize, 10)
                }
                offset = elementOffset + tableSize + halfTableSize * halfTableCount
            } else {
                if (scrollPos < elementOffset) {
                    if (scrollPos <= elementOffset - halfTableSize) {
                        halfTableCount = parseInt((scrollPos - (elementOffset - halfTableSize)) / halfTableSize, 10)
                    }
                    offset = elementOffset - (tableSize - halfTableSize * halfTableCount)
                } else {
                    offset = elementOffset
                }
            }
            return offset
        }
        exports.getRealElementWidth = getRealElementWidth;
        exports.AreaItem = Class.inherit({
            _getRowElement: function(index) {
                var that = this;
                if (that._tableElement && that._tableElement.length > 0) {
                    return that._tableElement[0].rows[index]
                }
                return null
            },
            _createGroupElement: function() {
                return $("<div>")
            },
            _createTableElement: function() {
                return $("<table>")
            },
            _getCellText: function(cell, encodeHtml) {
                var cellText = cell.isWhiteSpace ? "" : cell.text || "";
                if (encodeHtml && (cellText.indexOf("<") !== -1 || cellText.indexOf(">") !== -1)) {
                    cellText = $("<div>").text(cellText).html()
                }
                return cellText
            },
            _getRowClassNames: function() {},
            _applyCustomStyles: function(options) {
                if (options.cell.width) {
                    options.cssArray.push("min-width:" + options.cell.width + "px")
                }
                if (options.cell.sorted) {
                    options.classArray.push("dx-pivotgrid-sorted")
                }
            },
            _getMainElementMarkup: function() {
                return "<tbody>"
            },
            _getCloseMainElementMarkup: function() {
                return "</tbody>"
            },
            _renderTableContent: function(tableElement, data) {
                var row, cell, i, j, rowElement, cellElement, cellText, rowClassNames, that = this,
                    rowsCount = data.length,
                    rtlEnabled = that.option("rtlEnabled"),
                    markupArray = [],
                    encodeHtml = that.option("encodeHtml"),
                    colspan = "colspan='",
                    rowspan = "rowspan='";
                tableElement.data("area", that._getAreaName());
                tableElement.data("data", data);
                tableElement.css("width", "");
                markupArray.push(that._getMainElementMarkup());
                for (i = 0; i < rowsCount; i++) {
                    row = data[i];
                    var columnMarkupArray = [];
                    rowClassNames = [];
                    markupArray.push("<tr ");
                    for (j = 0; j < row.length; j++) {
                        cell = row[j];
                        this._getRowClassNames(i, cell, rowClassNames);
                        columnMarkupArray.push("<td ");
                        if (cell) {
                            cell.rowspan && columnMarkupArray.push(rowspan + (cell.rowspan || 1) + "'");
                            cell.colspan && columnMarkupArray.push(colspan + (cell.colspan || 1) + "'");
                            var styleOptions = {
                                cellElement: cellElement,
                                cell: cell,
                                cellsCount: row.length,
                                cellIndex: j,
                                rowElement: rowElement,
                                rowIndex: i,
                                rowsCount: rowsCount,
                                rtlEnabled: rtlEnabled,
                                classArray: [],
                                cssArray: []
                            };
                            that._applyCustomStyles(styleOptions);
                            if (styleOptions.cssArray.length) {
                                columnMarkupArray.push("style='");
                                columnMarkupArray.push(styleOptions.cssArray.join(";"));
                                columnMarkupArray.push("'")
                            }
                            if (styleOptions.classArray.length) {
                                columnMarkupArray.push("class='");
                                columnMarkupArray.push(styleOptions.classArray.join(" "));
                                columnMarkupArray.push("'")
                            }
                            columnMarkupArray.push(">");
                            if (commonUtils.isDefined(cell.expanded)) {
                                columnMarkupArray.push("<div class='dx-expand-icon-container'><span class='" + PIVOTGRID_EXPAND_CLASS + "'></span></div>")
                            }
                            cellText = this._getCellText(cell, encodeHtml)
                        } else {
                            cellText = ""
                        }
                        columnMarkupArray.push("<span ");
                        if (commonUtils.isDefined(cell.wordWrapEnabled)) {
                            columnMarkupArray.push("style='white-space:", cell.wordWrapEnabled ? "normal" : "nowrap", ";'")
                        }
                        columnMarkupArray.push(">" + cellText + "</span>");
                        if (cell.sorted) {
                            columnMarkupArray.push("<span class='dx-icon-sorted'></span>")
                        }
                        columnMarkupArray.push("</td>")
                    }
                    if (rowClassNames.length) {
                        markupArray.push("class='");
                        markupArray.push(rowClassNames.join(" "));
                        markupArray.push("'")
                    }
                    markupArray.push(">");
                    markupArray.push(columnMarkupArray.join(""));
                    markupArray.push("</tr>")
                }
                markupArray.push(this._getCloseMainElementMarkup());
                tableElement.append(markupArray.join(""));
                this._triggerOnCellPrepared(tableElement, data)
            },
            _triggerOnCellPrepared: function(tableElement, data) {
                var rowElement, cellElement, onCellPreparedArgs, row, cell, rowIndex, columnIndex, that = this,
                    rowElements = tableElement.find("tr"),
                    areaName = that._getAreaName(),
                    onCellPrepared = that.option("onCellPrepared"),
                    hasEvent = that.component.hasEvent("cellPrepared"),
                    defaultActionArgs = this.component._defaultActionArgs();
                if (onCellPrepared || hasEvent) {
                    for (rowIndex = 0; rowIndex < data.length; rowIndex++) {
                        row = data[rowIndex];
                        rowElement = rowElements.eq(rowIndex);
                        for (columnIndex = 0; columnIndex < row.length; columnIndex++) {
                            cell = row[columnIndex];
                            cellElement = rowElement.children().eq(columnIndex);
                            onCellPreparedArgs = {
                                area: areaName,
                                rowIndex: rowIndex,
                                columnIndex: columnIndex,
                                cellElement: cellElement,
                                cell: cell
                            };
                            if (hasEvent) {
                                that.component._trigger("onCellPrepared", onCellPreparedArgs)
                            } else {
                                onCellPrepared($.extend(onCellPreparedArgs, defaultActionArgs))
                            }
                        }
                    }
                }
            },
            _getRowHeight: function(index) {
                var clientRect, row = this._getRowElement(index),
                    height = 0;
                if (row && row.lastChild) {
                    if (row.getBoundingClientRect) {
                        clientRect = row.getBoundingClientRect();
                        height = clientRect.height
                    }
                    if (height > 0) {
                        return height
                    } else {
                        return row.offsetHeight
                    }
                }
                return 0
            },
            _setRowHeight: function(index, value) {
                var row = this._getRowElement(index);
                if (row) {
                    row.style.height = value + "px"
                }
            },
            ctor: function(component) {
                this.component = component
            },
            option: function() {
                return this.component.option.apply(this.component, arguments)
            },
            getRowsLength: function() {
                var that = this;
                if (that._tableElement && that._tableElement.length > 0) {
                    return that._tableElement[0].rows.length
                }
                return 0
            },
            getRowsHeight: function() {
                var i, that = this,
                    result = [],
                    rowsLength = that.getRowsLength();
                for (i = 0; i < rowsLength; i++) {
                    result.push(that._getRowHeight(i))
                }
                return result
            },
            setRowsHeight: function(values) {
                var i, that = this,
                    totalHeight = 0,
                    valuesLength = values.length;
                for (i = 0; i < valuesLength; i++) {
                    totalHeight += values[i];
                    that._setRowHeight(i, values[i])
                }
                this._tableHeight = totalHeight;
                this._tableElement[0].style.height = totalHeight + "px"
            },
            getColumnsWidth: function() {
                var rowIndex, row, i, columnIndex, rowsLength = this.getRowsLength(),
                    processedCells = [],
                    result = [],
                    fillCells = function(cells, rowIndex, columnIndex, rowSpan, colSpan) {
                        var rowOffset, columnOffset;
                        for (rowOffset = 0; rowOffset < rowSpan; rowOffset++) {
                            for (columnOffset = 0; columnOffset < colSpan; columnOffset++) {
                                cells[rowIndex + rowOffset] = cells[rowIndex + rowOffset] || [];
                                cells[rowIndex + rowOffset][columnIndex + columnOffset] = true
                            }
                        }
                    };
                if (rowsLength) {
                    for (rowIndex = 0; rowIndex < rowsLength; rowIndex++) {
                        processedCells[rowIndex] = processedCells[rowIndex] || [];
                        row = this._getRowElement(rowIndex);
                        for (i = 0; i < row.cells.length; i++) {
                            for (columnIndex = 0; processedCells[rowIndex][columnIndex]; columnIndex++) {}
                            fillCells(processedCells, rowIndex, columnIndex, row.cells[i].rowSpan, row.cells[i].colSpan);
                            if (1 === row.cells[i].colSpan) {
                                result[columnIndex] = result[columnIndex] || getRealElementWidth(row.cells[i])
                            }
                        }
                    }
                }
                return result
            },
            setColumnsWidth: function(values) {
                var i, totalWidth = 0,
                    tableElement = this._tableElement[0],
                    colgroupElementHTML = "",
                    columnsCount = this.getColumnsCount(),
                    columnWidth = [];
                for (i = 0; i < columnsCount; i++) {
                    columnWidth.push(values[i] || 0)
                }
                for (i = columnsCount; i < values.length && values; i++) {
                    columnWidth[columnsCount - 1] += values[i]
                }
                for (i = 0; i < columnsCount; i++) {
                    totalWidth += columnWidth[i];
                    colgroupElementHTML += '<col style="width: ' + columnWidth[i] + 'px">'
                }
                this._colgroupElement.html(colgroupElementHTML);
                this._tableWidth = totalWidth;
                tableElement.style.width = totalWidth + "px";
                tableElement.style.tableLayout = "fixed"
            },
            resetColumnsWidth: function() {
                this._colgroupElement.find("col").width("auto");
                this._tableElement.css({
                    width: "",
                    tableLayout: ""
                })
            },
            groupWidth: function(value) {
                if (void 0 === value) {
                    return this._groupElement.width()
                } else {
                    if (value >= 0) {
                        this._groupWidth = value;
                        return this._groupElement[0].style.width = value + "px"
                    } else {
                        return this._groupElement[0].style.width = value
                    }
                }
            },
            groupHeight: function(value) {
                if (void 0 === value) {
                    return this._groupElement.height()
                }
                this._groupHeight = null;
                if (value >= 0) {
                    this._groupHeight = value;
                    this._groupElement[0].style.height = value + "px"
                } else {
                    this._groupElement[0].style.height = value
                }
            },
            groupElement: function() {
                return this._groupElement
            },
            tableElement: function() {
                return this._tableElement
            },
            element: function() {
                return this._rootElement
            },
            headElement: function() {
                return this._tableElement.find("thead")
            },
            setVirtualContentParams: function(params) {
                this._virtualContent.css({
                    width: params.width,
                    height: params.height
                });
                this.groupElement().addClass("dx-virtual-mode")
            },
            disableVirtualMode: function() {
                this.groupElement().removeClass("dx-virtual-mode")
            },
            _renderVirtualContent: function() {
                var that = this;
                if (!that._virtualContent && "virtual" === that.option("scrolling.mode")) {
                    that._virtualContent = $("<div>").addClass("dx-virtual-content").insertBefore(that._tableElement)
                }
            },
            reset: function() {
                var that = this,
                    tableElement = that._tableElement[0];
                that._fakeTable && that._fakeTable.detach();
                that._fakeTable = null;
                that.disableVirtualMode();
                that.groupWidth("100%");
                that.groupHeight("auto");
                that.resetColumnsWidth();
                if (tableElement) {
                    for (var i = 0; i < tableElement.rows.length; i++) {
                        tableElement.rows[i].style.height = ""
                    }
                    tableElement.style.height = "";
                    tableElement.style.width = "100%"
                }
            },
            _updateFakeTableVisibility: function() {
                var that = this,
                    tableElement = that.tableElement()[0],
                    fakeTableElement = that._fakeTable[0];
                if (tableElement.style.top === fakeTableElement.style.top && fakeTableElement.style.left === tableElement.style.left) {
                    that._fakeTable.addClass("dx-hidden")
                } else {
                    that._fakeTable.removeClass("dx-hidden")
                }
            },
            _moveFakeTableLeft: function(scrollPos) {
                var that = this,
                    tableElementOffsetLeft = parseFloat(that.tableElement()[0].style.left),
                    offsetLeft = getFakeTableOffset(scrollPos, tableElementOffsetLeft, that._tableWidth, that._groupWidth);
                if (parseFloat(that._fakeTable[0].style.left) !== offsetLeft) {
                    that._fakeTable[0].style.left = offsetLeft + "px"
                }
            },
            _moveFakeTableTop: function(scrollPos) {
                var that = this,
                    tableElementOffsetTop = parseFloat(that.tableElement()[0].style.top),
                    offsetTop = getFakeTableOffset(scrollPos, tableElementOffsetTop, that._tableHeight, that._groupHeight);
                if (parseFloat(that._fakeTable[0].style.top) !== offsetTop) {
                    that._fakeTable[0].style.top = offsetTop + "px"
                }
            },
            _moveFakeTable: function(scrollPos) {
                this._updateFakeTableVisibility()
            },
            _createFakeTable: function(scrollPos) {
                var that = this;
                if (!that._fakeTable) {
                    that._fakeTable = that.tableElement().clone().addClass("dx-pivot-grid-fake-table").appendTo(that._virtualContent)
                }
            },
            render: function(rootElement, data) {
                var that = this;
                if (that._tableElement) {
                    try {
                        that._tableElement[0].innerHTML = ""
                    } catch (e) {
                        that._tableElement.empty()
                    }
                    that._tableElement.attr("style", "")
                } else {
                    that._groupElement = that._createGroupElement();
                    that._tableElement = that._createTableElement();
                    that._tableElement.appendTo(that._groupElement);
                    that._groupElement.appendTo(rootElement);
                    that._rootElement = rootElement
                }
                that._colgroupElement = $("<colgroup>").appendTo(that._tableElement);
                that._renderTableContent(that._tableElement, data);
                that._renderVirtualContent()
            },
            _getScrollable: function() {
                return this.groupElement().data("dxScrollable")
            },
            on: function(eventName, handler) {
                var scrollable = this._getScrollable();
                if (scrollable) {
                    scrollable.on(eventName, handler)
                }
                return this
            },
            off: function() {
                var scrollable = this._getScrollable();
                if (scrollable) {
                    scrollable.off.apply(scrollable, arguments)
                }
                return this
            },
            scrollTo: function(pos) {
                var scrollable = this._getScrollable();
                if (scrollable) {
                    scrollable.scrollTo(pos);
                    if (this._virtualContent) {
                        this._createFakeTable();
                        this._moveFakeTable(pos)
                    }
                }
            },
            updateScrollable: function() {
                var scrollable = this._getScrollable();
                if (scrollable) {
                    scrollable.update()
                }
            },
            getColumnsCount: function() {
                var cells, columnCount = 0,
                    row = this._getRowElement(0);
                if (row) {
                    cells = row.cells;
                    for (var i = 0, len = cells.length; i < len; ++i) {
                        columnCount += cells[i].colSpan
                    }
                }
                return columnCount
            }
        })
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.headers_area.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            areaItem = __webpack_require__( /*! ./ui.pivot_grid.area_item */ 392);
        var PIVOTGRID_AREA_CLASS = "dx-pivotgrid-area",
            PIVOTGRID_AREA_COLUMN_CLASS = "dx-pivotgrid-horizontal-headers",
            PIVOTGRID_AREA_ROW_CLASS = "dx-pivotgrid-vertical-headers",
            PIVOTGRID_TOTAL_CLASS = "dx-total",
            PIVOTGRID_GRAND_TOTAL_CLASS = "dx-grandtotal",
            PIVOTGRID_ROW_TOTAL_CLASS = "dx-row-total",
            PIVOTGRID_EXPANDED_CLASS = "dx-pivotgrid-expanded",
            PIVOTGRID_COLLAPSED_CLASS = "dx-pivotgrid-collapsed",
            PIVOTGRID_LAST_CELL_CLASS = "dx-last-cell",
            PIVOTGRID_VERTICAL_SCROLL_CLASS = "dx-vertical-scroll",
            PIVOTGRID_EXPAND_BORDER = "dx-expand-border";

        function getCellPath(tableElement, cell) {
            if (cell) {
                var data = tableElement.data().data,
                    rowIndex = cell.parentNode.rowIndex,
                    cellIndex = cell.cellIndex;
                return data[rowIndex] && data[rowIndex][cellIndex] && data[rowIndex][cellIndex].path
            }
        }
        exports.HorizontalHeadersArea = areaItem.AreaItem.inherit({
            _getAreaName: function() {
                return "column"
            },
            _getAreaClassName: function() {
                return PIVOTGRID_AREA_COLUMN_CLASS
            },
            _createGroupElement: function() {
                return $("<div>").addClass(this._getAreaClassName()).addClass(PIVOTGRID_AREA_CLASS)
            },
            _applyCustomStyles: function(options) {
                var cssArray = options.cssArray,
                    cell = options.cell,
                    rowsCount = options.rowsCount,
                    classArray = options.classArray;
                if (options.cellIndex === options.cellsCount - 1) {
                    cssArray.push((options.rtlEnabled ? "border-left:" : "border-right:") + "0px")
                }
                if (cell.rowspan === rowsCount - options.rowIndex || options.rowIndex + 1 === rowsCount) {
                    cssArray.push("border-bottom-width:0px")
                }
                if ("T" === cell.type || "GT" === cell.type) {
                    classArray.push(PIVOTGRID_ROW_TOTAL_CLASS)
                }
                if ("T" === options.cell.type) {
                    classArray.push(PIVOTGRID_TOTAL_CLASS)
                }
                if ("GT" === options.cell.type) {
                    classArray.push(PIVOTGRID_GRAND_TOTAL_CLASS)
                }
                if (commonUtils.isDefined(cell.expanded)) {
                    classArray.push(cell.expanded ? PIVOTGRID_EXPANDED_CLASS : PIVOTGRID_COLLAPSED_CLASS)
                }
                this.callBase(options)
            },
            _getMainElementMarkup: function() {
                return "<thead class='" + this._getAreaClassName() + "'>"
            },
            _getCloseMainElementMarkup: function() {
                return "</thead>"
            },
            setVirtualContentParams: function(params) {
                this.callBase(params);
                this.tableElement().css({
                    left: params.left,
                    top: 0
                });
                this._virtualContentWidth = params.width
            },
            hasScroll: function() {
                var tableWidth = this._virtualContent ? this._virtualContentWidth : this._tableWidth;
                if (this._groupWidth && tableWidth) {
                    return tableWidth - this._groupWidth >= 1
                }
                return false
            },
            processScroll: function() {
                if (!this._getScrollable()) {
                    this._groupElement.dxScrollable({
                        useNative: false,
                        useSimulatedScrollbar: false,
                        showScrollbar: false,
                        bounceEnabled: false,
                        direction: "horizontal",
                        updateManually: true
                    })
                }
            },
            processScrollBarSpacing: function(scrollBarWidth) {
                var that = this;
                if (that._groupWidth) {
                    that.groupWidth(that._groupWidth - scrollBarWidth)
                }
                if (that._scrollBarWidth) {
                    that._groupElement.next().remove()
                }
                that._groupElement.toggleClass(PIVOTGRID_VERTICAL_SCROLL_CLASS, scrollBarWidth > 0);
                that._groupElement.css("float", "left").width(that._groupHeight);
                that._scrollBarWidth = scrollBarWidth
            },
            ctor: function(component) {
                this.callBase(component);
                this._scrollBarWidth = 0
            },
            getScrollPath: function(offset) {
                var cell, tableElement = this.tableElement();
                offset -= parseInt(tableElement[0].style.left, 10) || 0;
                $.each(tableElement.find("td"), function(_, td) {
                    if (1 === td.colSpan && td.offsetLeft < offset && td.offsetWidth + td.offsetLeft > offset) {
                        cell = td;
                        return false
                    }
                });
                return getCellPath(tableElement, cell)
            },
            _moveFakeTable: function(scrollPos) {
                this._moveFakeTableLeft(scrollPos);
                this.callBase()
            }
        });
        exports.VerticalHeadersArea = exports.HorizontalHeadersArea.inherit({
            _getAreaClassName: function() {
                return PIVOTGRID_AREA_ROW_CLASS
            },
            _applyCustomStyles: function(options) {
                this.callBase(options);
                if (options.cellIndex === options.cellsCount - 1) {
                    options.classArray.push(PIVOTGRID_LAST_CELL_CLASS)
                }
                if (options.rowIndex === options.rowsCount - 1) {
                    options.cssArray.push("border-bottom: 0px")
                }
                if (options.cell.isWhiteSpace) {
                    options.classArray.push("dx-white-space-column")
                }
            },
            _getAreaName: function() {
                return "row"
            },
            setVirtualContentParams: function(params) {
                this.callBase(params);
                this.tableElement().css({
                    top: params.top,
                    left: 0
                });
                this._virtualContentHeight = params.height
            },
            hasScroll: function() {
                var tableHeight = this._virtualContent ? this._virtualContentHeight : this._tableHeight;
                if (this._groupHeight && tableHeight) {
                    return tableHeight - this._groupHeight >= 1
                }
                return false
            },
            processScroll: function() {
                if (!this._getScrollable()) {
                    this._groupElement.dxScrollable({
                        useNative: false,
                        useSimulatedScrollbar: false,
                        showScrollbar: false,
                        bounceEnabled: false,
                        direction: "vertical",
                        updateManually: true
                    })
                }
            },
            processScrollBarSpacing: function(scrollBarWidth) {
                var that = this;
                if (that._groupHeight) {
                    that.groupHeight(that._groupHeight - scrollBarWidth)
                }
                if (that._scrollBarWidth) {
                    that._groupElement.next().remove()
                }
                if (scrollBarWidth) {
                    that._groupElement.after($("<div>").width("100%").height(scrollBarWidth - 1))
                }
                that._scrollBarWidth = scrollBarWidth
            },
            getScrollPath: function(offset) {
                var cell, tableElement = this.tableElement();
                offset -= parseInt(tableElement[0].style.top, 10) || 0;
                $.each(tableElement.find("tr"), function(_, tr) {
                    var td = tr.childNodes[tr.childNodes.length - 1];
                    if (td && 1 === td.rowSpan && td.offsetTop < offset && td.offsetHeight + td.offsetTop > offset) {
                        cell = td;
                        return false
                    }
                });
                return getCellPath(tableElement, cell)
            },
            _moveFakeTable: function(scrollPos) {
                this._moveFakeTableTop(scrollPos);
                this.callBase()
            },
            _getRowClassNames: function(rowIndex, cell, rowClassNames) {
                if (0 !== rowIndex & cell.expanded && $.inArray(PIVOTGRID_EXPAND_BORDER, rowClassNames) === -1) {
                    rowClassNames.push(PIVOTGRID_EXPAND_BORDER)
                }
            },
            _getMainElementMarkup: function() {
                return "<tbody class='" + this._getAreaClassName() + "'>"
            },
            _getCloseMainElementMarkup: function() {
                return "</tbody>"
            },
            updateColspans: function(columnCount) {
                var diff, i, j, rows = this.tableElement()[0].rows,
                    columnOffset = 0,
                    columnOffsetResetIndexes = [];
                if (this.getColumnsCount() - columnCount > 0) {
                    return
                }
                for (i = 0; i < rows.length; i++) {
                    for (j = 0; j < rows[i].cells.length; j++) {
                        var cell = rows[i].cells[j],
                            rowSpan = cell.rowSpan;
                        if (columnOffsetResetIndexes[i]) {
                            columnOffset -= columnOffsetResetIndexes[i];
                            columnOffsetResetIndexes[i] = 0
                        }
                        diff = columnCount - (columnOffset + cell.colSpan);
                        if (j === rows[i].cells.length - 1 && diff > 0) {
                            cell.colSpan = cell.colSpan + diff
                        }
                        columnOffsetResetIndexes[i + rowSpan] = (columnOffsetResetIndexes[i + rowSpan] || 0) + cell.colSpan;
                        columnOffset += cell.colSpan
                    }
                }
            }
        })
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.fields_area.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            areaItem = __webpack_require__( /*! ./ui.pivot_grid.area_item */ 392),
            Popup = __webpack_require__( /*! ../popup */ 195),
            Button = __webpack_require__( /*! ../button */ 196),
            DIV = "<div>";
        __webpack_require__( /*! ./ui.pivot_grid.field_chooser_base */ 395);

        function capitalizeFirstLetter(string) {
            return string.charAt(0).toUpperCase() + string.slice(1)
        }

        function renderGroupConnector(field, nextField, prevField, $container) {
            if (prevField && prevField.groupName && prevField.groupName === field.groupName) {
                $(DIV).addClass("dx-group-connector").addClass("dx-group-connector-prev").appendTo($container)
            }
            if (nextField && nextField.groupName && nextField.groupName === field.groupName) {
                $(DIV).addClass("dx-group-connector").addClass("dx-group-connector-next").appendTo($container)
            }
        }
        exports.FieldsArea = areaItem.AreaItem.inherit({
            ctor: function(component, area) {
                this.callBase(component);
                this._area = area
            },
            _getAreaName: function() {
                return "fields"
            },
            _createGroupElement: function() {
                return $(DIV).addClass("dx-pivotgrid-fields-area").addClass("dx-area-fields").attr("group", this._area)
            },
            isVisible: function() {
                return !!this.option("fieldPanel.visible") && this.option("fieldPanel.show" + capitalizeFirstLetter(this._area) + "Fields")
            },
            _renderButton: function(element) {
                var that = this,
                    container = $("<td>").appendTo($("<tr>").appendTo(element)),
                    button = that.component._createComponent($(DIV).appendTo(container), Button, {
                        text: "Fields",
                        icon: "menu",
                        width: "auto",
                        onClick: function() {
                            var popup = that.tableElement().find(".dx-fields-area-popup").dxPopup("instance");
                            if (!popup.option("visible")) {
                                popup.show()
                            }
                        }
                    });
                button.element().addClass("dx-pivotgrid-fields-area-hamburger")
            },
            _getPopupOptions: function(row, button) {
                return {
                    contentTemplate: function() {
                        return $("<table>").addClass("dx-area-field-container").append($("<thead>").addClass("dx-pivotgrid-fields-area-head").append(row))
                    },
                    height: "auto",
                    width: "auto",
                    position: {
                        at: "left",
                        my: "left",
                        of: button
                    },
                    dragEnabled: false,
                    animation: {
                        show: {
                            type: "pop",
                            duration: 200
                        }
                    },
                    shading: false,
                    showTitle: false,
                    closeOnOutsideClick: true,
                    container: button.parent()
                }
            },
            _renderPopup: function(tableElement, row) {
                var that = this,
                    button = tableElement.find(".dx-button"),
                    popupOptions = that._getPopupOptions(row, button),
                    FieldChooserBase = that.component.element().dxPivotGridFieldChooserBase("instance");
                if (that._rowPopup) {
                    that._rowPopup.element().remove()
                }
                that._rowPopup = that.component._createComponent($(DIV).appendTo(tableElement), Popup, popupOptions);
                that._rowPopup.element().addClass("dx-fields-area-popup");
                that._rowPopup.content().addClass("dx-pivotgrid-fields-container");
                that._rowPopup.content().parent().attr("group", "row");
                FieldChooserBase.subscribeToEvents(that._rowPopup.content());
                FieldChooserBase.renderSortable(that._rowPopup.content())
            },
            _shouldCreateButton: function(area) {
                return false
            },
            _renderTableContent: function(tableElement, data) {
                var that = this,
                    groupElement = this.groupElement(),
                    isVisible = this.isVisible(),
                    fieldChooserBase = that.component.element().dxPivotGridFieldChooserBase("instance"),
                    head = $("<thead>").addClass("dx-pivotgrid-fields-area-head").appendTo(tableElement),
                    area = that._area,
                    row = $("<tr>");
                groupElement.toggleClass("dx-hidden", !isVisible);
                tableElement.addClass("dx-area-field-container");
                if (!isVisible) {
                    return
                }
                $.each(data, function(index, field) {
                    if (field.area === area) {
                        var td = $("<td>").append(fieldChooserBase.renderField(field, "row" === field.area)),
                            indicators = td.find(".dx-column-indicators");
                        if (indicators.length && that._shouldCreateButton(area)) {
                            indicators.insertAfter(indicators.next())
                        }
                        td.appendTo(row);
                        renderGroupConnector(field, data[index + 1], data[index - 1], td)
                    }
                });
                if (!row.children().length) {
                    $("<td>").append($(DIV).addClass("dx-empty-area-text").text(this.option("fieldPanel.texts." + area + "FieldArea"))).appendTo(row)
                }
                if (that._shouldCreateButton(area)) {
                    that._renderButton(head);
                    that._renderPopup(tableElement, row)
                } else {
                    head.append(row)
                }
            },
            _renderVirtualContent: $.noop
        })
    },
    /*!*******************************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.field_chooser_base.js ***!
      \*******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            ArrayStore = __webpack_require__( /*! ../../data/array_store */ 162),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            headerFilter = __webpack_require__( /*! ../grid_core/ui.grid_core.header_filter */ 372),
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341),
            sorting = __webpack_require__( /*! ../grid_core/ui.grid_core.sorting */ 346),
            pivotGridUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            Sortable = __webpack_require__( /*! ./ui.sortable */ 396),
            inArray = $.inArray,
            each = $.each,
            IE_FIELD_WIDTH_CORRECTION = 1,
            DIV = "<div>",
            HeaderFilterView = headerFilter.HeaderFilterView;
        var processItems = function(groupItems, field) {
            var filterValues = [],
                isTree = !!field.groupName,
                isExcludeFilterType = "exclude" === field.filterType;
            if (field.filterValues) {
                each(field.filterValues, function(_, filterValue) {
                    filterValues.push(commonUtils.isArray(filterValue) ? filterValue.join("/") : filterValue)
                })
            }
            pivotGridUtils.foreachTree(groupItems, function(items) {
                var preparedFilterValue, item = items[0],
                    path = pivotGridUtils.createPath(items),
                    preparedFilterValueByText = isTree ? $.map(items, function(item) {
                        return item.text
                    }).reverse().join("/") : item.text;
                item.value = isTree ? path.slice(0) : item.key || item.value;
                preparedFilterValue = isTree ? path.join("/") : item.value;
                if (item.children) {
                    item.items = item.children;
                    item.children = null
                }
                headerFilter.updateHeaderFilterItemSelectionState(item, item.key && inArray(preparedFilterValueByText, filterValues) > -1 || inArray(preparedFilterValue, filterValues) > -1, isExcludeFilterType)
            })
        };

        function getMainGroupField(dataSource, sourceField) {
            var field = sourceField;
            if (commonUtils.isDefined(sourceField.groupIndex)) {
                field = dataSource.getAreaFields(sourceField.area, true)[sourceField.areaIndex]
            }
            return field
        }
        var FieldChooserBase = Widget.inherit(gridCoreUtils.columnStateMixin).inherit(sorting.sortingMixin).inherit(headerFilter.headerFilterMixin).inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    allowFieldDragging: true,
                    headerFilter: {
                        width: 252,
                        height: 300,
                        texts: {
                            emptyValue: messageLocalization.format("dxDataGrid-headerFilterEmptyValue"),
                            ok: messageLocalization.format("dxDataGrid-headerFilterOK"),
                            cancel: messageLocalization.format("dxDataGrid-headerFilterCancel")
                        }
                    }
                })
            },
            _init: function() {
                this.callBase();
                this._headerFilterView = new HeaderFilterView(this);
                this._refreshDataSource();
                this.subscribeToEvents()
            },
            _refreshDataSource: function() {
                var dataSource = this.option("dataSource");
                if (dataSource && dataSource.fields && dataSource.load) {
                    this._dataSource = dataSource
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "dataSource":
                        this._refreshDataSource();
                        break;
                    case "headerFilter":
                    case "allowFieldDragging":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            renderField: function(field, showColumnLines) {
                var that = this,
                    $fieldContent = $(DIV).addClass("dx-area-field-content").text(field.caption || field.dataField),
                    $fieldElement = $(DIV).addClass("dx-area-field").addClass("dx-area-box").data("field", field).append($fieldContent),
                    mainGroupField = getMainGroupField(that._dataSource, field);
                if ("data" !== field.area) {
                    if (field.allowSorting) {
                        that._applyColumnState({
                            name: "sort",
                            rootElement: $fieldElement,
                            column: {
                                alignment: that.option("rtlEnabled") ? "right" : "left",
                                sortOrder: "desc" === field.sortOrder ? "desc" : "asc"
                            },
                            showColumnLines: showColumnLines
                        })
                    }
                    that._applyColumnState({
                        name: "headerFilter",
                        rootElement: $fieldElement,
                        column: {
                            alignment: that.option("rtlEnabled") ? "right" : "left",
                            filterValues: mainGroupField.filterValues,
                            allowFiltering: mainGroupField.allowFiltering && !field.groupIndex
                        },
                        showColumnLines: showColumnLines
                    })
                }
                if (field.groupName) {
                    $fieldElement.attr("item-group", field.groupName)
                }
                return $fieldElement
            },
            _clean: function() {},
            _renderContentImpl: function() {
                var element = this.element();
                this.renderSortable(element);
                this._headerFilterView.render(element)
            },
            renderSortable: function(element) {
                var that = this;
                that._createComponent(element, Sortable, $.extend({
                    allowDragging: that.option("allowFieldDragging"),
                    itemSelector: ".dx-area-field",
                    itemContainerSelector: ".dx-area-field-container",
                    groupSelector: ".dx-area-fields",
                    groupFilter: function() {
                        var dataSource = that._dataSource,
                            $sortable = $(this).closest(".dx-sortable"),
                            pivotGrid = $sortable.data("dxPivotGrid"),
                            pivotGridFieldChooser = $sortable.data("dxPivotGridFieldChooser");
                        if (pivotGrid) {
                            return pivotGrid.getDataSource() === dataSource
                        }
                        if (pivotGridFieldChooser) {
                            return pivotGridFieldChooser.option("dataSource") === dataSource
                        }
                        return false
                    },
                    itemRender: function($sourceItem, target) {
                        var $item;
                        if ($sourceItem.hasClass("dx-area-box")) {
                            $item = $sourceItem.clone();
                            if ("drag" === target) {
                                $.each($sourceItem, function(index, sourceItem) {
                                    $item.eq(index).css("width", parseInt($(sourceItem).css("width"), 10) + IE_FIELD_WIDTH_CORRECTION)
                                })
                            }
                        } else {
                            $item = $(DIV).addClass("dx-area-field").addClass("dx-area-box").text($sourceItem.text())
                        }
                        if ("drag" === target) {
                            var wrapperContainer = $(DIV);
                            $.each($item, function(_, item) {
                                var wrapper = $("<div>").addClass("dx-pivotgrid-fields-container").addClass("dx-widget").append($(item));
                                wrapperContainer.append(wrapper)
                            });
                            return wrapperContainer.children()
                        }
                        return $item
                    },
                    onDragging: function(e) {
                        var field = e.sourceElement.data("field"),
                            targetGroup = e.targetGroup;
                        e.cancel = false;
                        if (true === field.isMeasure) {
                            if ("column" === targetGroup || "row" === targetGroup || "filter" === targetGroup) {
                                e.cancel = true
                            }
                        } else {
                            if (false === field.isMeasure && "data" === targetGroup) {
                                e.cancel = true
                            }
                        }
                    },
                    useIndicator: true,
                    onChanged: function(e) {
                        var dataSource = that._dataSource,
                            field = e.sourceElement.data("field");
                        e.removeSourceElement = !!e.sourceGroup;
                        that._adjustSortableOnChangedArgs(e);
                        if (field) {
                            dataSource.field(getMainGroupField(dataSource, field).index, {
                                area: e.targetGroup,
                                areaIndex: e.targetIndex
                            });
                            dataSource.load()
                        }
                    }
                }, that._getSortableOptions()))
            },
            _adjustSortableOnChangedArgs: function(e) {
                e.removeSourceElement = false;
                e.removeTargetElement = true;
                e.removeSourceClass = false
            },
            _getSortableOptions: function() {
                return {
                    direction: "auto"
                }
            },
            subscribeToEvents: function(element) {
                var that = this,
                    func = function(e) {
                        var field = $(e.currentTarget).data("field"),
                            mainGroupField = $.extend(true, {}, getMainGroupField(that._dataSource, field)),
                            isHeaderFilter = $(e.target).hasClass("dx-header-filter"),
                            dataSource = that._dataSource;
                        if (isHeaderFilter) {
                            that._headerFilterView.showHeaderFilterMenu($(e.currentTarget), $.extend(mainGroupField, {
                                type: mainGroupField.groupName ? "tree" : "list",
                                dataSource: {
                                    load: function(options) {
                                        var userData = options.userData;
                                        if (userData.store) {
                                            return userData.store.load(options)
                                        } else {
                                            var d = $.Deferred();
                                            dataSource.getFieldValues(mainGroupField.index).done(function(data) {
                                                userData.store = new ArrayStore(data);
                                                userData.store.load(options).done(d.resolve).fail(d.reject)
                                            }).fail(d.reject);
                                            return d
                                        }
                                    },
                                    postProcess: function(data) {
                                        processItems(data, mainGroupField);
                                        return data
                                    }
                                },
                                apply: function() {
                                    dataSource.field(mainGroupField.index, {
                                        filterValues: this.filterValues,
                                        filterType: this.filterType
                                    });
                                    dataSource.load()
                                }
                            }))
                        } else {
                            if (field.allowSorting && "data" !== field.area) {
                                dataSource.field(field.index, {
                                    sortOrder: "desc" === field.sortOrder ? "asc" : "desc"
                                });
                                dataSource.load()
                            }
                        }
                    };
                if (element) {
                    element.on(clickEvent.name, ".dx-area-field.dx-area-box", func);
                    return
                }
                that.element().on(clickEvent.name, ".dx-area-field.dx-area-box", func)
            },
            _initTemplates: $.noop
        });
        registerComponent("dxPivotGridFieldChooserBase", FieldChooserBase);
        module.exports = FieldChooserBase
    },
    /*!**********************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.sortable.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            addNamespace = eventUtils.addNamespace,
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            DOMComponent = __webpack_require__( /*! ../../core/dom_component */ 29),
            dragEvents = __webpack_require__( /*! ../../events/drag */ 110);
        var SORTABLE_NAMESPACE = "dxSortable",
            SORTABLE_CLASS = "dx-sortable";

        function elementHasPoint(element, x, y) {
            var $item = $(element),
                offset = $item.offset();
            if (x >= offset.left && x <= offset.left + $item.outerWidth(true)) {
                if (y >= offset.top && y <= offset.top + $item.outerHeight(true)) {
                    return true
                }
            }
        }

        function checkHorizontalPosition(position, itemOffset, rtl) {
            if (commonUtils.isDefined(itemOffset.posHorizontal)) {
                return rtl ? position > itemOffset.posHorizontal : position < itemOffset.posHorizontal
            } else {
                return true
            }
        }

        function getIndex($items, $item) {
            var index = -1,
                itemElement = $item.get(0);
            $.each($items, function(elementIndex, element) {
                var $element = $(element);
                if (!($element.attr("item-group") && $element.attr("item-group") === $items.eq(elementIndex - 1).attr("item-group"))) {
                    index++
                }
                if (element === itemElement) {
                    return false
                }
            });
            return index === $items.length ? -1 : index
        }

        function getTargetGroup(e, $groups) {
            var result;
            $.each($groups, function() {
                if (elementHasPoint(this, e.pageX, e.pageY)) {
                    result = $(this)
                }
            });
            return result
        }

        function getItemsOffset($elements, isVertical, $itemsContainer) {
            var result = [];
            for (var i = 0; i < $elements.length; i += $item.length) {
                var $item = $elements.eq(i);
                if ($item.attr("item-group")) {
                    $item = $itemsContainer.find("[item-group='" + $item.attr("item-group") + "']")
                }
                if ($item.is(":visible")) {
                    var offset = {
                        item: $item,
                        index: result.length,
                        posHorizontal: isVertical ? void 0 : ($item.last().outerWidth(true) + $item.last().offset().left + $item.offset().left) / 2
                    };
                    if (isVertical) {
                        offset.posVertical = ($item.last().offset().top + $item.offset().top + $item.last().outerHeight(true)) / 2
                    } else {
                        offset.posVertical = $item.last().outerHeight(true) + $item.last().offset().top
                    }
                    result.push(offset)
                }
            }
            return result
        }
        var Sortable = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    onChanged: null,
                    onDragging: null,
                    itemRender: null,
                    groupSelector: null,
                    itemSelector: ".dx-sort-item",
                    itemContainerSelector: ".dx-sortable",
                    sourceClass: "dx-drag-source",
                    dragClass: "dx-drag",
                    targetClass: "dx-drag-target",
                    direction: "vertical",
                    allowDragging: true,
                    groupFilter: null,
                    useIndicator: false
                })
            },
            _renderItem: function($sourceItem, target) {
                var $item, itemRender = this.option("itemRender");
                if (itemRender) {
                    $item = itemRender($sourceItem, target)
                } else {
                    $item = $sourceItem.clone();
                    $item.css({
                        width: $sourceItem.width(),
                        height: $sourceItem.height()
                    })
                }
                return $item
            },
            _renderIndicator: function($item, isVertical, $targetGroup, isLast) {
                var height = $item.outerHeight(true),
                    width = $item.outerWidth(true),
                    top = $item.offset().top - $targetGroup.offset().top,
                    left = $item.offset().left - $targetGroup.offset().left;
                this._indicator.css({
                    position: "absolute",
                    top: isLast && isVertical ? top + height : top,
                    left: isLast && !isVertical ? left + width : left
                }).toggleClass("dx-position-indicator-horizontal", !isVertical).toggleClass("dx-position-indicator-vertical", !!isVertical).toggleClass("dx-position-indicator-last", !!isLast).height("").width("").appendTo($targetGroup);
                isVertical ? this._indicator.width(width) : this._indicator.height(height)
            },
            _renderDraggable: function($sourceItem) {
                this._$draggable && this._$draggable.remove();
                this._$draggable = this._renderItem($sourceItem, "drag").addClass(this.option("dragClass")).appendTo("body").css({
                    zIndex: 1e6,
                    position: "absolute"
                })
            },
            _detachEventHandlers: function() {
                this.element().off(addNamespace([dragEvents.move, dragEvents.start, dragEvents.end, dragEvents.enter, dragEvents.leave, dragEvents.drop].join(" "), SORTABLE_NAMESPACE))
            },
            _getItemOffset: function(isVertical, itemsOffset, e) {
                for (var i = 0; i < itemsOffset.length; i++) {
                    var shouldInsert = isVertical ? e.pageY < itemsOffset[i].posVertical : checkHorizontalPosition(e.pageX, itemsOffset[i], this.option("rtlEnabled"));
                    if (shouldInsert) {
                        return itemsOffset[i]
                    }
                }
            },
            _attachEventHandlers: function() {
                var $sourceItem, sourceIndex, $targetItem, $targetGroup, startPositions, sourceGroup, $groups, that = this,
                    itemSelector = that.option("itemSelector"),
                    itemContainerSelector = that.option("itemContainerSelector"),
                    groupSelector = that.option("groupSelector"),
                    sourceClass = that.option("sourceClass"),
                    targetClass = that.option("targetClass"),
                    onDragging = that.option("onDragging"),
                    groupFilter = that.option("groupFilter"),
                    element = that.element(),
                    targetIndex = -1;
                var setStartPositions = function() {
                    startPositions = [];
                    $.each($sourceItem, function(_, item) {
                        startPositions.push($(item).offset())
                    })
                };
                var createGroups = function() {
                    if (!groupSelector) {
                        return element
                    } else {
                        return groupFilter ? $(groupSelector).filter(groupFilter) : element.find(groupSelector)
                    }
                };
                var invokeOnDraggingEvent = function() {
                    var draggingArgs = {
                        sourceGroup: sourceGroup,
                        sourceIndex: sourceIndex,
                        sourceElement: $sourceItem,
                        targetGroup: $targetGroup.attr("group"),
                        targetIndex: $targetGroup.find(itemSelector).index($targetItem)
                    };
                    onDragging && onDragging(draggingArgs);
                    if (draggingArgs.cancel) {
                        $targetGroup = void 0
                    }
                };
                that._detachEventHandlers();
                that.option("allowDragging") && element.on(addNamespace(dragEvents.start, SORTABLE_NAMESPACE), itemSelector, function(e) {
                    $sourceItem = $(e.currentTarget);
                    var $sourceGroup = $sourceItem.closest(groupSelector);
                    sourceGroup = $sourceGroup.attr("group");
                    sourceIndex = getIndex((groupSelector ? $sourceGroup : element).find(itemSelector), $sourceItem);
                    if ($sourceItem.attr("item-group")) {
                        $sourceItem = $sourceGroup.find("[item-group='" + $sourceItem.attr("item-group") + "']")
                    }
                    that._renderDraggable($sourceItem);
                    $targetItem = that._renderItem($sourceItem, "target").addClass(targetClass);
                    $sourceItem.addClass(sourceClass);
                    setStartPositions();
                    $groups = createGroups();
                    that._indicator = $("<div>").addClass("dx-position-indicator")
                }).on(addNamespace(dragEvents.move, SORTABLE_NAMESPACE), function(e) {
                    var $item, $itemContainer, $items, $lastItem, isVertical, itemOffset, $prevItem, itemsOffset = [];
                    if (!$sourceItem) {
                        return
                    }
                    targetIndex = -1;
                    that._indicator.detach();
                    $.each(that._$draggable, function(index, draggableElement) {
                        $(draggableElement).css({
                            top: startPositions[index].top + e.offset.y,
                            left: startPositions[index].left + e.offset.x
                        })
                    });
                    $targetGroup && $targetGroup.removeClass(targetClass);
                    $targetGroup = getTargetGroup(e, $groups);
                    $targetGroup && invokeOnDraggingEvent();
                    if (!$targetGroup) {
                        $targetItem.detach();
                        return
                    }
                    $targetGroup.addClass(targetClass);
                    $itemContainer = $targetGroup.find(itemContainerSelector);
                    $items = $itemContainer.find(itemSelector);
                    var targetSortable = $targetGroup.closest("." + SORTABLE_CLASS).data("dxSortable"),
                        useIndicator = targetSortable.option("useIndicator");
                    isVertical = "vertical" === (targetSortable || that).option("direction");
                    itemsOffset = getItemsOffset($items, isVertical, $itemContainer);
                    itemOffset = that._getItemOffset(isVertical, itemsOffset, e);
                    if (itemOffset) {
                        $item = itemOffset.item;
                        $prevItem = itemsOffset[itemOffset.index - 1] && itemsOffset[itemOffset.index - 1].item;
                        if ($item.hasClass(sourceClass) || $prevItem && $prevItem.hasClass(sourceClass) && $prevItem.is(":visible")) {
                            $targetItem.detach();
                            return
                        }
                        targetIndex = itemOffset.index;
                        if (!useIndicator) {
                            $targetItem.insertBefore($item);
                            return
                        }
                        var isAnotherGroup = $targetGroup.attr("group") !== sourceGroup,
                            isSameIndex = targetIndex === sourceIndex,
                            isNextIndex = targetIndex === sourceIndex + 1;
                        if (isAnotherGroup) {
                            that._renderIndicator($item, isVertical, $targetGroup, that.option("rtlEnabled") && !isVertical);
                            return
                        }
                        if (!isSameIndex && !isNextIndex) {
                            that._renderIndicator($item, isVertical, $targetGroup, that.option("rtlEnabled") && !isVertical)
                        }
                    } else {
                        $lastItem = $items.last();
                        if ($lastItem.is(":visible") && $lastItem.hasClass(sourceClass)) {
                            return
                        }
                        if ($itemContainer.length) {
                            targetIndex = itemsOffset.length ? itemsOffset[itemsOffset.length - 1].index + 1 : 0
                        }
                        if (useIndicator) {
                            $items.length && that._renderIndicator($lastItem, isVertical, $targetGroup, !that.option("rtlEnabled") || isVertical)
                        } else {
                            $targetItem.appendTo($itemContainer)
                        }
                    }
                }).on(addNamespace(dragEvents.end, SORTABLE_NAMESPACE), function() {
                    if (!$sourceItem) {
                        return
                    }
                    var onChanged = that.option("onChanged"),
                        changedArgs = {
                            sourceIndex: sourceIndex,
                            sourceElement: $sourceItem,
                            sourceGroup: sourceGroup,
                            targetIndex: targetIndex,
                            removeSourceElement: true,
                            removeTargetElement: false,
                            removeSourceClass: true
                        };
                    if ($targetGroup) {
                        $targetGroup.removeClass(targetClass);
                        changedArgs.targetGroup = $targetGroup.attr("group");
                        if (sourceGroup !== changedArgs.targetGroup || targetIndex > -1) {
                            onChanged && onChanged(changedArgs);
                            changedArgs.removeSourceElement && $sourceItem.remove()
                        }
                    }
                    that._indicator.detach();
                    changedArgs.removeSourceClass && $sourceItem.removeClass(sourceClass);
                    $sourceItem = null;
                    that._$draggable.remove();
                    that._$draggable = null;
                    changedArgs.removeTargetElement && $targetItem.remove();
                    $targetItem.removeClass(targetClass);
                    $targetItem = null
                })
            },
            _init: function() {
                this.callBase();
                this._attachEventHandlers()
            },
            _render: function() {
                this.callBase();
                this.element().addClass(SORTABLE_CLASS)
            },
            _dispose: function() {
                var that = this;
                that.callBase.apply(that, arguments);
                that._$draggable && that._$draggable.detach();
                that._indicator && that._indicator.detach()
            },
            _optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "onDragging":
                    case "onChanged":
                    case "itemRender":
                    case "groupSelector":
                    case "itemSelector":
                    case "itemContainerSelector":
                    case "sourceClass":
                    case "targetClass":
                    case "dragClass":
                    case "allowDragging":
                    case "groupFilter":
                    case "useIndicator":
                        that._attachEventHandlers();
                        break;
                    case "direction":
                        break;
                    default:
                        that.callBase(args)
                }
            }
        });
        registerComponent("dxSortable", Sortable);
        module.exports = Sortable
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.field_chooser.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            iconUtils = __webpack_require__( /*! ../../core/utils/icon */ 99),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            pivotGridUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            TreeView = __webpack_require__( /*! ../tree_view */ 356),
            ContextMenu = __webpack_require__( /*! ../context_menu */ 327),
            BaseFieldChooser = __webpack_require__( /*! ./ui.pivot_grid.field_chooser_base */ 395),
            inArray = $.inArray,
            each = $.each,
            DIV = "<div>";
        __webpack_require__( /*! ./data_source */ 387);
        var FIELDCHOOSER_CLASS = "dx-pivotgridfieldchooser",
            FIELDCHOOSER_CONTAINER_CLASS = "dx-pivotgridfieldchooser-container",
            FIELDS_CONTAINER_CLASS = "dx-pivotgrid-fields-container";

        function getDimensionFields(item, fields) {
            var result = [];
            if (item.items) {
                for (var i = 0; i < item.items.length; i++) {
                    result.push.apply(result, getDimensionFields(item.items[i], fields))
                }
            } else {
                if (commonUtils.isDefined(item.index)) {
                    result.push(fields[item.index])
                }
            }
            return result
        }

        function getFirstItem(item, condition) {
            if (item.items) {
                for (var i = 0; i < item.items.length; i++) {
                    var childrenItem = getFirstItem(item.items[i], condition);
                    if (childrenItem) {
                        return childrenItem
                    }
                }
            }
            if (condition(item)) {
                return item
            }
        }
        var compareOrder = [function(a, b) {
            var aValue = -!!a.isMeasure,
                bValue = +!!b.isMeasure;
            return aValue + bValue
        }, function(a, b) {
            var aValue = -!!(a.items && a.items.length),
                bValue = +!!(b.items && b.items.length);
            return aValue + bValue
        }, function(a, b) {
            var aValue = +!!(a.field && a.field.levels && a.field.levels.length),
                bValue = -!!(b.field && b.field.levels && b.field.levels.length);
            return aValue + bValue
        }, pivotGridUtils.getCompareFunction(function(item) {
            return item.text
        })];

        function compareItems(a, b) {
            var result = 0,
                i = 0;
            while (!result && compareOrder[i]) {
                result = compareOrder[i++](a, b)
            }
            return result
        }

        function getScrollable(container) {
            return container.find(".dx-scrollable").dxScrollable("instance")
        }
        var FieldChooser = BaseFieldChooser.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    height: 400,
                    layout: 0,
                    dataSource: null,
                    onContextMenuPreparing: null,
                    texts: {
                        columnFields: messageLocalization.format("dxPivotGrid-columnFields"),
                        rowFields: messageLocalization.format("dxPivotGrid-rowFields"),
                        dataFields: messageLocalization.format("dxPivotGrid-dataFields"),
                        filterFields: messageLocalization.format("dxPivotGrid-filterFields"),
                        allFields: messageLocalization.format("dxPivotGrid-allFields")
                    }
                })
            },
            _refreshDataSource: function() {
                var that = this;
                that._expandedPaths = [];
                that._changedHandler = that._changedHandler || function() {
                    each(that._dataChangedHandlers, function(_, func) {
                        func()
                    })
                };
                if (that._dataSource) {
                    that._dataSource.off("changed", that._changedHandler);
                    that._dataSource = void 0
                }
                that.callBase();
                that._dataSource && that._dataSource.on("changed", that._changedHandler)
            },
            _init: function() {
                this.callBase();
                this._refreshDataSource();
                this._dataChangedHandlers = [];
                this._initActions()
            },
            _initActions: function() {
                this._actions = {
                    onContextMenuPreparing: this._createActionByOption("onContextMenuPreparing")
                }
            },
            _trigger: function(eventName, eventArg) {
                this._actions[eventName](eventArg)
            },
            _setOptionsByReference: function() {
                this.callBase();
                $.extend(this._optionsByReference, {
                    dataSource: true
                })
            },
            _optionChanged: function(args) {
                var that = this;
                switch (args.name) {
                    case "dataSource":
                        that._refreshDataSource();
                        that._invalidate();
                        break;
                    case "layout":
                    case "texts":
                        that._invalidate();
                        break;
                    case "onContextMenuPreparing":
                        that._actions[args.name] = that._createActionByOption(args.name);
                        break;
                    default:
                        that.callBase(args)
                }
            },
            _clean: function() {
                this.element().children("." + FIELDCHOOSER_CONTAINER_CLASS).remove()
            },
            _renderContentImpl: function() {
                var $col1, $col2, that = this,
                    element = this.element(),
                    $container = $(DIV).addClass(FIELDCHOOSER_CONTAINER_CLASS).appendTo(element),
                    layout = that.option("layout");
                element.addClass(FIELDCHOOSER_CLASS).addClass(FIELDS_CONTAINER_CLASS);
                that._dataChangedHandlers = [];
                that.callBase();
                if (0 === layout) {
                    $col1 = $(DIV).addClass("dx-col").appendTo($container);
                    $col2 = $(DIV).addClass("dx-col").appendTo($container);
                    that._renderArea($col1, "all");
                    that._renderArea($col1, "filter");
                    that._renderArea($col2, "row");
                    that._renderArea($col2, "column");
                    that._renderArea($col2, "data")
                } else {
                    if (1 === layout) {
                        $col1 = $(DIV).addClass("dx-col").appendTo($container);
                        $col2 = $(DIV).addClass("dx-col").appendTo($container);
                        that._renderArea($col1, "all");
                        that._renderArea($col2, "filter");
                        that._renderArea($col2, "row");
                        that._renderArea($col2, "column");
                        that._renderArea($col2, "data")
                    } else {
                        this._renderArea($container, "all");
                        $col1 = $(DIV).addClass("dx-col").appendTo($container);
                        $col2 = $(DIV).addClass("dx-col").appendTo($container);
                        that._renderArea($col1, "filter");
                        that._renderArea($col1, "row");
                        that._renderArea($col2, "column");
                        that._renderArea($col2, "data")
                    }
                }
                that.updateDimensions();
                that._renderContextMenu()
            },
            _getContextMenuArgs: function(jQueryEvent) {
                var field, area, targetFieldElement = $(jQueryEvent.target).closest(".dx-area-field"),
                    targetGroupElement = $(jQueryEvent.target).closest(".dx-area-fields");
                if (targetFieldElement.length) {
                    field = targetFieldElement.data("field")
                }
                if (targetGroupElement.length) {
                    area = targetGroupElement.attr("group")
                }
                return {
                    jQueryEvent: jQueryEvent,
                    field: field,
                    area: area,
                    items: []
                }
            },
            _renderContextMenu: function() {
                var that = this,
                    $container = that.element();
                if (that._contextMenu) {
                    that._contextMenu.element().remove()
                }
                that._contextMenu = that._createComponent($(DIV).appendTo($container), ContextMenu, {
                    onPositioning: function(actionArgs) {
                        var args, event = actionArgs.jQueryEvent;
                        if (!event) {
                            return
                        }
                        args = that._getContextMenuArgs(event);
                        that._trigger("onContextMenuPreparing", args);
                        if (args.items && args.items.length) {
                            actionArgs.component.option("items", args.items)
                        } else {
                            actionArgs.cancel = true
                        }
                    },
                    target: $container,
                    onItemClick: function(params) {
                        params.itemData.onItemClick && params.itemData.onItemClick(params)
                    },
                    cssClass: "dx-pivotgridfieldchooser-context-menu"
                })
            },
            _createTreeItems: function(fields, groupFieldNames, path) {
                var isMeasure, that = this,
                    resultItems = [],
                    groupedItems = [],
                    groupFieldName = groupFieldNames[0],
                    fieldsByGroup = {};
                if (!groupFieldName) {
                    each(fields, function(index, field) {
                        var icon;
                        if (true === field.isMeasure) {
                            icon = "measure"
                        }
                        if (false === field.isMeasure) {
                            icon = field.groupName ? "hierarchy" : "dimension"
                        }
                        resultItems.push({
                            index: field.index,
                            field: field,
                            key: field.dataField,
                            selected: commonUtils.isDefined(field.area),
                            text: field.caption || field.dataField,
                            icon: icon,
                            isMeasure: field.isMeasure,
                            isDefault: field.isDefault
                        })
                    })
                } else {
                    each(fields, function(index, field) {
                        var groupName = field[groupFieldName] || "";
                        fieldsByGroup[groupName] = fieldsByGroup[groupName] || [];
                        fieldsByGroup[groupName].push(field);
                        if (void 0 === isMeasure) {
                            isMeasure = true
                        }
                        isMeasure = isMeasure && true === field.isMeasure
                    });
                    each(fieldsByGroup, function(groupName, fields) {
                        var currentPath = path ? path + "." + groupName : groupName;
                        var items = that._createTreeItems(fields, groupFieldNames.slice(1), currentPath);
                        if (groupName) {
                            groupedItems.push({
                                key: groupName,
                                text: groupName,
                                path: currentPath,
                                isMeasure: items.isMeasure,
                                expanded: inArray(currentPath, that._expandedPaths) >= 0,
                                items: items
                            })
                        } else {
                            resultItems = items
                        }
                    });
                    resultItems = groupedItems.concat(resultItems);
                    resultItems.isMeasure = isMeasure
                }
                return resultItems
            },
            _createFieldsDataSource: function(dataSource) {
                var treeItems, fields = dataSource && dataSource.fields() || [];
                fields = $.map(fields, function(field) {
                    return false === field.visible || commonUtils.isDefined(field.groupIndex) ? null : field
                });
                treeItems = this._createTreeItems(fields, ["dimension", "displayFolder"]);
                pivotGridUtils.foreachDataLevel(treeItems, function(items) {
                    items.sort(compareItems)
                }, 0, "items");
                return treeItems
            },
            _renderFieldsTreeView: function(container) {
                var that = this,
                    dataSource = that._dataSource,
                    treeView = that._createComponent(container, TreeView, {
                        dataSource: that._createFieldsDataSource(dataSource),
                        showCheckBoxesMode: "normal",
                        itemTemplate: function(itemData, itemIndex, itemElement) {
                            if (itemData.icon) {
                                iconUtils.getImageContainer(itemData.icon).appendTo(itemElement)
                            }
                            $("<span>").toggleClass("dx-area-field", !itemData.items).data("field", itemData.field).text(itemData.text).appendTo(itemElement)
                        },
                        onItemCollapsed: function(e) {
                            var index = inArray(e.itemData.path, that._expandedPaths);
                            if (index >= 0) {
                                that._expandedPaths.splice(index, 1)
                            }
                        },
                        onItemExpanded: function(e) {
                            var index = inArray(e.itemData.path, that._expandedPaths);
                            if (index < 0) {
                                that._expandedPaths.push(e.itemData.path)
                            }
                        },
                        onItemSelectionChanged: function(e) {
                            var field, fields, area, data = e.itemData,
                                needSelectDefaultItem = true;
                            if (data.items) {
                                if (data.selected) {
                                    treeView.unselectItem(data);
                                    return
                                }
                                fields = getDimensionFields(data, dataSource.fields());
                                for (var i = 0; i < fields.length; i++) {
                                    if (fields[i].area) {
                                        needSelectDefaultItem = false;
                                        break
                                    }
                                }
                                if (needSelectDefaultItem) {
                                    var item = getFirstItem(data, function(item) {
                                        return item.isDefault
                                    }) || getFirstItem(data, function(item) {
                                        return commonUtils.isDefined(item.index)
                                    });
                                    item && treeView.selectItem(item);
                                    return
                                }
                            } else {
                                field = dataSource.fields()[data.index];
                                if (data.selected) {
                                    area = field.isMeasure ? "data" : "column"
                                }
                                if (field) {
                                    fields = [field]
                                }
                            }
                            each(fields, function(_, field) {
                                dataSource.field(field.index, {
                                    area: area,
                                    areaIndex: void 0
                                })
                            });
                            dataSource.load()
                        }
                    }),
                    dataChanged = function() {
                        var scrollable = getScrollable(container),
                            scrollTop = scrollable ? scrollable.scrollTop() : 0;
                        treeView.option({
                            dataSource: that._createFieldsDataSource(dataSource)
                        });
                        scrollable = getScrollable(container);
                        if (scrollable) {
                            scrollable.scrollTo({
                                y: scrollTop
                            });
                            scrollable.update()
                        }
                    };
                that._dataChangedHandlers.push(dataChanged)
            },
            _renderAreaFields: function($container, area) {
                var that = this,
                    dataSource = that._dataSource,
                    fields = dataSource ? dataSource.getAreaFields(area, true) : [];
                $container.empty();
                each(fields, function() {
                    that.renderField(this, true).appendTo($container)
                })
            },
            _renderArea: function(container, area) {
                var $fieldsContainer, $fieldsContent, render, that = this,
                    $areaContainer = $(DIV).addClass("dx-area").appendTo(container),
                    caption = that.option("texts." + area + "Fields");
                $("<span>").addClass("dx-area-icon").addClass("dx-area-icon-" + area).appendTo($areaContainer);
                $("<span>").html("&nbsp;").appendTo($areaContainer);
                $("<span>").addClass("dx-area-caption").text(caption).appendTo($areaContainer);
                $fieldsContainer = $(DIV).addClass("dx-area-fields").height(0).appendTo($areaContainer);
                if ("all" !== area) {
                    $fieldsContent = $(DIV).addClass("dx-area-field-container").appendTo($fieldsContainer);
                    render = function() {
                        that._renderAreaFields($fieldsContent, area)
                    };
                    that._dataChangedHandlers.push(render);
                    render();
                    $fieldsContainer.attr("group", area).dxScrollable()
                } else {
                    $fieldsContainer.addClass("dx-treeview-border-visible");
                    that._renderFieldsTreeView($fieldsContainer)
                }
            },
            _getSortableOptions: function() {
                return {}
            },
            _adjustSortableOnChangedArgs: function(e) {},
            getDataSource: function() {
                return this._dataSource
            },
            updateDimensions: function() {
                var areaHeight, $element = this.element(),
                    $container = $element.children(".dx-pivotgridfieldchooser-container"),
                    $cols = $element.find(".dx-col"),
                    $areaElements = $element.find(".dx-area-fields"),
                    $scrollableElements = $element.find(".dx-area .dx-scrollable");
                $areaElements.height(0);
                if (0 === this.option("layout")) {
                    areaHeight = Math.floor(($element.height() - $container.height()) / 3);
                    $areaElements.height(areaHeight);
                    $areaElements.eq(0).height($cols.eq(1).height() - $cols.eq(0).height() + areaHeight)
                } else {
                    if (1 === this.option("layout")) {
                        areaHeight = Math.floor(($element.height() - $container.height()) / 4);
                        $areaElements.height(areaHeight);
                        $areaElements.eq(0).height($cols.eq(1).height() - $cols.eq(0).height() + areaHeight)
                    } else {
                        areaHeight = Math.floor(($element.height() - $container.height()) / 4);
                        $areaElements.height(areaHeight);
                        $areaElements.eq(0).height(2 * areaHeight)
                    }
                }
                $scrollableElements.dxScrollable("update")
            },
            _visibilityChanged: function(visible) {
                if (visible) {
                    this.updateDimensions()
                }
            }
        });
        registerComponent("dxPivotGridFieldChooser", FieldChooser);
        module.exports = FieldChooser
    },
    /*!*******************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.export.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            utils = __webpack_require__( /*! ../../core/utils/common */ 14),
            formatHelper = __webpack_require__( /*! ../../format_helper */ 55),
            clientExporter = __webpack_require__( /*! ../../client_exporter */ 7),
            excelExporter = clientExporter.excel,
            DEFAULT_DATA_TYPE = "string",
            gridCoreUtils = __webpack_require__( /*! ../grid_core/ui.grid_core.utils */ 341);
        exports.ExportMixin = $.extend({}, gridCoreUtils.exportMixin, {
            exportToExcel: function() {
                var that = this;
                clientExporter.export(that.getDataProvider(), {
                    fileName: that.option("export.fileName"),
                    proxyUrl: that.option("export.proxyUrl"),
                    format: "EXCEL",
                    rtlEnabled: that.option("rtlEnabled"),
                    exportingAction: that._actions.onExporting,
                    exportedAction: that._actions.onExported,
                    fileSavingAction: that._actions.onFileSaving
                }, excelExporter.getData)
            },
            _getLength: function(items) {
                var cellIndex, cellCount = 0;
                for (cellIndex in items[0]) {
                    cellCount += items[0][cellIndex].colspan ? items[0][cellIndex].colspan : 1
                }
                return cellCount
            },
            _getAllItems: function(columnsInfo, rowsInfoItems, cellsInfo) {
                var cellIndex, rowIndex, sourceItems = columnsInfo.concat(cellsInfo),
                    rowsLength = this._getLength(rowsInfoItems),
                    colsLength = this._getLength(columnsInfo),
                    headerRowsCount = columnsInfo.length;
                for (rowIndex = 0; rowIndex < rowsInfoItems.length; rowIndex++) {
                    for (cellIndex = rowsInfoItems[rowIndex].length - 1; cellIndex >= 0; cellIndex--) {
                        if (!utils.isDefined(sourceItems[rowIndex + headerRowsCount])) {
                            sourceItems[rowIndex + headerRowsCount] = []
                        }
                        sourceItems[rowIndex + headerRowsCount].splice(0, 0, $.extend({}, rowsInfoItems[rowIndex][cellIndex]))
                    }
                }
                sourceItems[0].splice(0, 0, $.extend({}, this._getEmptyCell(), {
                    alignment: this._options.rtlEnabled ? "right" : "left",
                    colspan: rowsLength,
                    rowspan: headerRowsCount
                }));
                return this._prepareItems(rowsLength + colsLength, sourceItems)
            },
            getDataProvider: function() {
                var that = this,
                    dataController = this._dataController,
                    items = $.Deferred();
                dataController.beginLoading();
                setTimeout(function() {
                    var columnsInfo = $.extend(true, [], dataController.getColumnsInfo(true)),
                        rowsInfoItems = $.extend(true, [], dataController.getRowsInfo(true)),
                        cellsInfo = dataController.getCellsInfo(true);
                    items.resolve(that._getAllItems(columnsInfo, rowsInfoItems, cellsInfo));
                    dataController.endLoading()
                });
                return new exports.DataProvider({
                    items: items,
                    dataFields: this.getDataSource().getAreaFields("data")
                })
            }
        });

        function getCellDataType(cell, field) {
            if (field && field.customizeText) {
                return "string"
            }
            if (cell.dataType) {
                return cell.dataType
            }
            if (cell.format) {
                if (formatHelper.format(1, cell.format)) {
                    return "number"
                }
                if (formatHelper.format(new Date, cell.format)) {
                    return "date"
                }
            }
            return DEFAULT_DATA_TYPE
        }
        exports.DataProvider = Class.inherit({
            ctor: function(options) {
                this._options = options
            },
            ready: function() {
                var options = this._options,
                    dataFields = options.dataFields;
                return $.when(options.items).done(function(items) {
                    var cellItem, headerSize = items[0][0].rowspan,
                        columns = items[headerSize - 1];
                    $.each(columns, function(columnIndex, column) {
                        column.width = 100;
                        column.alignment = column.alignment || "center";
                        cellItem = items[headerSize] && items[headerSize][columnIndex];
                        if (cellItem) {
                            column.dataType = getCellDataType(cellItem, dataFields[cellItem.dataIndex]);
                            column.format = cellItem.format;
                            column.precision = cellItem.precision
                        }
                    });
                    options.columns = columns;
                    options.items = items
                })
            },
            getColumns: function() {
                return this._options.columns
            },
            getRowsCount: function() {
                return this._options.items.length
            },
            isGroupRow: function() {
                return false
            },
            isHeadersVisible: function() {
                return false
            },
            isTotalCell: function() {
                return false
            },
            getGroupLevel: function() {
                return 0
            },
            getCellMerging: function(rowIndex, cellIndex) {
                var items = this._options.items,
                    item = items[rowIndex] && items[rowIndex][cellIndex];
                return item ? {
                    colspan: item.colspan - 1,
                    rowspan: item.rowspan - 1
                } : {
                    colspan: 0,
                    rowspan: 0
                }
            },
            getFrozenArea: function() {
                var items = this._options.items;
                return {
                    x: items[0][0].colspan,
                    y: items[0][0].rowspan
                }
            },
            getCellType: function(rowIndex, cellIndex) {
                var items = this._options.items,
                    rowHeaderCellCount = items[0][0].rowspan,
                    columnHeaderCellCount = items[0][0].colspan,
                    column = this._options.columns[cellIndex],
                    dataType = column && column.dataType;
                if (rowIndex < rowHeaderCellCount || cellIndex < columnHeaderCellCount) {
                    return DEFAULT_DATA_TYPE
                }
                return dataType || DEFAULT_DATA_TYPE
            },
            getCellValue: function(rowIndex, cellIndex) {
                var items = this._options.items,
                    item = items[rowIndex] && items[rowIndex][cellIndex] || {};
                if ("string" === this.getCellType(rowIndex, cellIndex)) {
                    return item.text
                } else {
                    return item.value
                }
            }
        })
    },
    /*!******************************************************************!*\
      !*** ./Scripts/ui/pivot_grid/ui.pivot_grid.chart_integration.js ***!
      \******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            pivotUtils = __webpack_require__( /*! ./ui.pivot_grid.utils */ 385),
            foreachTree = pivotUtils.foreachTree,
            FORMAT_DICTIONARY = {
                number: "numeric",
                date: "datetime"
            },
            UNBIND_KEY = "dxPivotGridUnbinding";

        function getFormattedValue(path, fields) {
            var value = [],
                lastFieldIndex = fields.length - 1;
            $.each(path, function(i, item) {
                value.push(item.text || pivotUtils.formatValue(item.value, fields[lastFieldIndex - i]))
            });
            return value.reverse()
        }

        function getExpandedLevel(node) {
            var level = 0;
            foreachTree(node, function(members) {
                level = Math.max(level, members.length - 1)
            });
            return level
        }

        function processDataCell(processCellArgs, processCell) {
            var chartDataItem = processCellArgs.chartDataItem,
                processedCell = processCell && processCell(processCellArgs);
            if (processedCell) {
                chartDataItem = $.extend({}, chartDataItem, processedCell.chartDataItem);
                processedCell = $.extend({}, processCellArgs, processedCell, {
                    chartDataItem: chartDataItem
                });
                return processedCell
            }
            return processCellArgs
        }

        function createChartDataSource(pivotGridDataSource, mapOptions, axisDictionary) {
            var measureIndex, dataField, rowMemberIndex, rowVisibility, rowPathFormatted, rowPath, columnMemberIndex, columnVisibility, columnPath, columnPathFormatted, data = pivotGridDataSource.getData(),
                dataSource = [],
                dataFields = pivotGridDataSource.getAreaFields("data"),
                rowFields = pivotGridDataSource.getAreaFields("row"),
                columnFields = pivotGridDataSource.getAreaFields("column"),
                columnElements = [{
                    index: data.grandTotalColumnIndex,
                    children: data.columns
                }],
                rowElements = [{
                    index: data.grandTotalRowIndex,
                    children: data.rows
                }],
                rowLevel = getExpandedLevel(rowElements),
                columnLevel = getExpandedLevel(columnElements);

            function createDataItem() {
                var axis, dataCell = (data.values[rowMemberIndex] || [])[columnMemberIndex] || [],
                    value = dataCell[measureIndex],
                    processCellArgs = {
                        rowPath: rowPath,
                        maxRowLevel: rowLevel,
                        rowPathFormatted: rowPathFormatted,
                        rowFields: rowFields,
                        columnPathFormatted: columnPathFormatted,
                        maxColumnLevel: columnLevel,
                        columnPath: columnPath,
                        columnFields: columnFields,
                        dataFields: dataFields,
                        dataIndex: measureIndex,
                        dataValues: dataCell,
                        visible: columnVisibility && rowVisibility
                    },
                    seriesName = (mapOptions.inverted ? columnPathFormatted : rowPathFormatted).join(" - "),
                    argument = (mapOptions.inverted ? rowPathFormatted : columnPathFormatted).join("/");
                if (dataFields.length > 1) {
                    if ("args" === mapOptions.putDataFieldsInto || "both" === mapOptions.putDataFieldsInto) {
                        argument += " | " + dataField.caption
                    }
                    if ("args" !== mapOptions.putDataFieldsInto) {
                        seriesName += " | " + dataField.caption;
                        if ("singleAxis" !== mapOptions.dataFieldsDisplayMode) {
                            axis = dataField.caption
                        }
                    }
                }
                processCellArgs.chartDataItem = {
                    val: void 0 === value ? null : value,
                    series: seriesName,
                    arg: argument
                };
                processCellArgs = processDataCell(processCellArgs, mapOptions.processCell);
                if (processCellArgs.visible) {
                    axisDictionary[processCellArgs.chartDataItem.series] = axisDictionary[processCellArgs.chartDataItem.series] || axis;
                    dataSource.push(processCellArgs.chartDataItem)
                }
            }

            function foreachRowColumn(callBack) {
                foreachTree(rowElements, function(rowMembers) {
                    rowMemberIndex = rowMembers[0].index, rowMembers = rowMembers.slice(0, rowMembers.length - 1);
                    rowVisibility = rowLevel === rowMembers.length;
                    rowPath = pivotUtils.createPath(rowMembers);
                    rowPathFormatted = getFormattedValue(rowMembers, rowFields);
                    if (0 === rowPath.length) {
                        rowPathFormatted = [mapOptions.grandTotalText]
                    }
                    foreachTree(columnElements, function(columnMembers) {
                        columnMemberIndex = columnMembers[0].index;
                        columnMembers = columnMembers.slice(0, columnMembers.length - 1);
                        columnVisibility = columnLevel === columnMembers.length;
                        columnPath = pivotUtils.createPath(columnMembers);
                        columnPathFormatted = getFormattedValue(columnMembers, columnFields);
                        if (0 === columnPath.length) {
                            columnPathFormatted = [mapOptions.grandTotalText]
                        }
                        callBack()
                    })
                })
            }

            function foreachDataField(callback) {
                $.each(dataFields, function(index, field) {
                    dataField = field, measureIndex = index;
                    callback()
                })
            }
            if (false === mapOptions.alternateDataFields) {
                foreachDataField(function() {
                    foreachRowColumn(createDataItem)
                })
            } else {
                foreachRowColumn(function() {
                    foreachDataField(createDataItem)
                })
            }
            return dataSource
        }

        function createValueAxisOptions(dataSource, options) {
            var dataFields = dataSource.getAreaFields("data");
            if ("args" !== options.putDataFieldsInto && "singleAxis" !== options.dataFieldsDisplayMode || 1 === dataFields.length) {
                var valueAxisSettings = [];
                $.each(dataFields, function(_, dataField) {
                    var valueAxisOptions = {
                        name: dataField.caption,
                        title: dataField.caption,
                        valueType: FORMAT_DICTIONARY[dataField.dataType] || dataField.dataType,
                        label: {
                            format: dataField.format,
                            precision: dataField.precision
                        }
                    };
                    if (dataField.customizeText) {
                        valueAxisOptions.label.customizeText = function(formatObject) {
                            return dataField.customizeText.call(dataField, formatObject)
                        }
                    }
                    if ("splitPanes" === options.dataFieldsDisplayMode) {
                        valueAxisOptions.pane = dataField.caption
                    }
                    valueAxisSettings.push(valueAxisOptions)
                });
                return valueAxisSettings
            }
            return [{}]
        }

        function createPanesOptions(dataSource, options) {
            var panes = [];
            var dataFields = dataSource.getAreaFields("data");
            if (dataFields.length > 1 && "splitPanes" === options.dataFieldsDisplayMode && "args" !== options.putDataFieldsInto) {
                $.each(dataFields, function(_, dataField) {
                    panes.push({
                        name: dataField.caption
                    })
                })
            }
            if (!panes.length) {
                panes.push({})
            }
            return panes
        }

        function createChartOptions(dataSource, options) {
            var customizeSeries = options.customizeSeries,
                customizeChart = options.customizeChart,
                chartOptions = {
                    valueAxis: createValueAxisOptions(dataSource, options),
                    panes: createPanesOptions(dataSource, options)
                },
                axisDictionary = {};
            if (customizeChart) {
                chartOptions = $.extend(true, {}, chartOptions, customizeChart(chartOptions))
            }
            chartOptions.dataSource = createChartDataSource(dataSource, options, axisDictionary);
            chartOptions.seriesTemplate = {
                nameField: "series",
                customizeSeries: function(seriesName, seriesData) {
                    var seriesOptions = {};
                    if ("splitPanes" === options.dataFieldsDisplayMode) {
                        seriesOptions.pane = axisDictionary[seriesName]
                    } else {
                        if ("singleAxis" !== options.dataFieldsDisplayMode) {
                            seriesOptions.axis = axisDictionary[seriesName]
                        }
                    }
                    if (customizeSeries) {
                        seriesOptions = $.extend(seriesOptions, customizeSeries(seriesName, seriesOptions))
                    }
                    return seriesOptions
                }
            };
            return chartOptions
        }

        function getChartInstance(chartElement) {
            if (!chartElement) {
                return false
            }
            if (chartElement.NAME) {
                return "dxChart" === chartElement.NAME && chartElement
            }
            var element = $(chartElement);
            return element.data("dxChart") && element.dxChart("instance")
        }

        function removeBinding(chart) {
            var unbind = chart.element().data(UNBIND_KEY);
            unbind && unbind()
        }
        module.exports = {
            bindChart: function(chart, integrationOptions) {
                integrationOptions = $.extend({}, integrationOptions);
                var disposeBinding, that = this,
                    dataSource = that.getDataSource(),
                    updateChart = function() {
                        integrationOptions.grandTotalText = that.option("texts.grandTotal");
                        var chartOptions = createChartOptions(dataSource, integrationOptions);
                        chart.option(chartOptions)
                    };
                chart = getChartInstance(chart);
                if (!chart) {
                    return null
                }
                removeBinding(chart);
                that.on("changed", updateChart);
                updateChart();
                disposeBinding = function() {
                    chart.element().removeData(UNBIND_KEY);
                    that.off("changed", updateChart)
                };
                chart.on("disposing", disposeBinding);
                this.on("disposing", disposeBinding);
                chart.element().data(UNBIND_KEY, disposeBinding);
                return disposeBinding
            }
        }
    },
    /*!************************************************!*\
      !*** ./Scripts/ui/pivot_grid_field_chooser.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./pivot_grid/ui.pivot_grid.field_chooser */ 397)
    },
    /*!*********************************************!*\
      !*** ./Scripts/ui/pivot_grid/xmla_store.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./xmla_store/xmla_store */ 389).XmlaStore
    },
    /*!*********************************!*\
      !*** ./Scripts/ui/scheduler.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./scheduler/ui.scheduler */ 403)
    },
    /*!**********************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            dialog = __webpack_require__( /*! ../dialog */ 194),
            recurrenceUtils = __webpack_require__( /*! ./utils.recurrence */ 404),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            subscribes = __webpack_require__( /*! ./ui.scheduler.subscribes */ 405),
            FunctionTemplate = __webpack_require__( /*! ../widget/ui.template.function */ 97),
            DynamicTemplate = __webpack_require__( /*! ../widget/ui.template.dynamic */ 91),
            MoveTemplate = __webpack_require__( /*! ../widget/ui.template.move */ 93),
            appointmentTooltip = __webpack_require__( /*! ./ui.scheduler.appointment_tooltip */ 408),
            SchedulerHeader = __webpack_require__( /*! ./ui.scheduler.header */ 409),
            SchedulerWorkSpaceDay = __webpack_require__( /*! ./ui.scheduler.work_space_day */ 412),
            SchedulerWorkSpaceWeek = __webpack_require__( /*! ./ui.scheduler.work_space_week */ 415),
            SchedulerWorkSpaceWorkWeek = __webpack_require__( /*! ./ui.scheduler.work_space_work_week */ 416),
            SchedulerWorkSpaceMonth = __webpack_require__( /*! ./ui.scheduler.work_space_month */ 417),
            SchedulerTimelineDay = __webpack_require__( /*! ./ui.scheduler.timeline_day */ 418),
            SchedulerTimelineWeek = __webpack_require__( /*! ./ui.scheduler.timeline_week */ 420),
            SchedulerTimelineWorkWeek = __webpack_require__( /*! ./ui.scheduler.timeline_work_week */ 421),
            SchedulerTimelineMonth = __webpack_require__( /*! ./ui.scheduler.timeline_month */ 422),
            SchedulerAgenda = __webpack_require__( /*! ./ui.scheduler.agenda */ 423),
            SchedulerResourceManager = __webpack_require__( /*! ./ui.scheduler.resource_manager */ 424),
            SchedulerAppointmentModel = __webpack_require__( /*! ./ui.scheduler.appointment_model */ 425),
            SchedulerAppointments = __webpack_require__( /*! ./ui.scheduler.appointments */ 426),
            DropDownAppointments = __webpack_require__( /*! ./ui.scheduler.appointments.drop_down */ 434),
            SchedulerTimezones = __webpack_require__( /*! ./ui.scheduler.timezones */ 406),
            DataHelperMixin = __webpack_require__( /*! ../collection/ui.data_helper */ 154),
            loading = __webpack_require__( /*! ./ui.loading */ 435),
            AppointmentForm = __webpack_require__( /*! ./ui.scheduler.appointment_form */ 436),
            Popup = __webpack_require__( /*! ../popup */ 195);
        var WIDGET_CLASS = "dx-scheduler",
            WIDGET_SMALL_CLASS = "dx-scheduler-small",
            WIDGET_READONLY_CLASS = "dx-scheduler-readonly",
            APPOINTMENT_POPUP_CLASS = "dx-scheduler-appointment-popup",
            RECURRENCE_EDITOR_ITEM_CLASS = "dx-scheduler-recurrence-rule-item",
            RECURRENCE_EDITOR_OPENED_ITEM_CLASS = "dx-scheduler-recurrence-rule-item-opened",
            WIDGET_SMALL_WIDTH = 400,
            APPOINTEMENT_POPUP_WIDTH = 610;
        var VIEWS_CONFIG = {
            day: {
                workSpace: SchedulerWorkSpaceDay,
                renderingStrategy: "vertical"
            },
            week: {
                workSpace: SchedulerWorkSpaceWeek,
                renderingStrategy: "vertical"
            },
            workWeek: {
                workSpace: SchedulerWorkSpaceWorkWeek,
                renderingStrategy: "vertical"
            },
            month: {
                workSpace: SchedulerWorkSpaceMonth,
                renderingStrategy: "horizontalMonth"
            },
            timelineDay: {
                workSpace: SchedulerTimelineDay,
                renderingStrategy: "horizontal"
            },
            timelineWeek: {
                workSpace: SchedulerTimelineWeek,
                renderingStrategy: "horizontal"
            },
            timelineWorkWeek: {
                workSpace: SchedulerTimelineWorkWeek,
                renderingStrategy: "horizontal"
            },
            timelineMonth: {
                workSpace: SchedulerTimelineMonth,
                renderingStrategy: "horizontalMonthLine"
            },
            agenda: {
                workSpace: SchedulerAgenda,
                renderingStrategy: "agenda"
            }
        };
        var Scheduler = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    views: ["day", "week"],
                    currentView: "day",
                    currentDate: dateUtils.trimTime(new Date),
                    min: void 0,
                    max: void 0,
                    firstDayOfWeek: void 0,
                    groups: [],
                    resources: [],
                    dataSource: null,
                    appointmentTemplate: "item",
                    startDayHour: 0,
                    endDayHour: 24,
                    editing: {
                        allowAdding: true,
                        allowDeleting: true,
                        allowDragging: true,
                        allowResizing: true,
                        allowUpdating: true
                    },
                    showAllDayPanel: true,
                    recurrenceEditMode: "dialog",
                    cellDuration: 30,
                    onAppointmentRendered: null,
                    onAppointmentClick: null,
                    onAppointmentDblClick: null,
                    onCellClick: null,
                    onAppointmentAdding: null,
                    onAppointmentAdded: null,
                    onAppointmentUpdating: null,
                    onAppointmentUpdated: null,
                    onAppointmentDeleting: null,
                    onAppointmentDeleted: null,
                    onAppointmentFormCreated: null,
                    appointmentTooltipTemplate: "appointmentTooltip",
                    appointmentPopupTemplate: "appointmentPopup",
                    crossScrollingEnabled: false,
                    useDropDownViewSwitcher: false,
                    startDateExpr: "startDate",
                    endDateExpr: "endDate",
                    textExpr: "text",
                    descriptionExpr: "description",
                    allDayExpr: "allDay",
                    recurrenceRuleExpr: "recurrenceRule",
                    recurrenceExceptionExpr: "recurrenceException",
                    remoteFiltering: false,
                    timeZone: "",
                    startDateTimeZoneExpr: "startDateTimeZone",
                    endDateTimeZoneExpr: "endDateTimeZone",
                    noDataText: messageLocalization.format("dxCollectionWidget-noDataText"),
                    allowMultipleCellSelection: true
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return "desktop" === devices.real().deviceType && !devices.isSimulator()
                    },
                    options: {
                        focusStateEnabled: true
                    }
                }, {
                    device: function(device) {
                        return !devices.current().generic
                    },
                    options: {
                        useDropDownViewSwitcher: true,
                        editing: {
                            allowDragging: false,
                            allowResizing: false
                        }
                    }
                }])
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                $.extend(this._deprecatedOptions, {
                    horizontalScrollingEnabled: {
                        since: "16.1",
                        alias: "crossScrollingEnabled"
                    }
                })
            },
            _optionChanged: function(args) {
                var value = args.value,
                    name = args.name;
                switch (args.name) {
                    case "firstDayOfWeek":
                        this._workSpace.option(name, value);
                        this._header.option(name, value);
                        break;
                    case "currentDate":
                        value = dateUtils.trimTime(dateUtils.makeDate(value));
                        this._workSpace.option(name, value);
                        this._header.option(name, value);
                        this._appointments.option("items", []);
                        this._filterAppointmentsByDate();
                        this._reloadDataSource();
                        break;
                    case "dataSource":
                        this._initDataSource();
                        this._customizeStoreLoadOptions();
                        this._appointmentModel.setDataSource(this._dataSource);
                        this._loadResources().done($.proxy(function(resources) {
                            this._filterAppointmentsByDate();
                            this._workSpace.option("showAllDayPanel", this.option("showAllDayPanel"));
                            this._reloadDataSource()
                        }, this));
                        break;
                    case "min":
                    case "max":
                        this._header.option(name, dateUtils.makeDate(value));
                        this._workSpace.option(name, dateUtils.makeDate(value));
                        break;
                    case "views":
                    case "useDropDownViewSwitcher":
                        this._header.option(name, value);
                        break;
                    case "currentView":
                        this._appointments.option({
                            items: [],
                            allowDrag: this._allowDragging(),
                            allowResize: this._allowResizing()
                        });
                        this._header.option(name, value);
                        this._loadResources().done($.proxy(function(resources) {
                            this._appointments.option("renderingStrategy", this._getAppointmentsRenderingStrategy());
                            this._refreshWorkSpace(resources);
                            this._filterAppointmentsByDate();
                            this._appointments.option("allowAllDayResize", "day" !== value);
                            this._reloadDataSource()
                        }, this));
                        break;
                    case "appointmentTemplate":
                        this._appointments.option("itemTemplate", value);
                        break;
                    case "groups":
                        this._loadResources().done($.proxy(function(resources) {
                            this._workSpace.option(name, resources);
                            this._filterAppointmentsByDate();
                            this._reloadDataSource()
                        }, this));
                        break;
                    case "resources":
                        this._resourcesManager.setResources(this.option("resources"));
                        this._appointmentModel.setDataAccessors(this._combineDataAccessors());
                        this._loadResources().done($.proxy(function(resources) {
                            this._workSpace.option("groups", resources);
                            this._filterAppointmentsByDate();
                            this._reloadDataSource()
                        }, this));
                        break;
                    case "startDayHour":
                    case "endDayHour":
                        this._appointments.option("items", []);
                        this._workSpace.option(name, value);
                        this._appointments.option("dayDuration", this._getDayDuration());
                        this._filterAppointmentsByDate();
                        this._reloadDataSource();
                        break;
                    case "onAppointmentAdding":
                    case "onAppointmentAdded":
                    case "onAppointmentUpdating":
                    case "onAppointmentUpdated":
                    case "onAppointmentDeleting":
                    case "onAppointmentDeleted":
                    case "onAppointmentFormCreated":
                        this._actions[name] = this._createActionByOption(name);
                        break;
                    case "onAppointmentRendered":
                        this._appointments.option("onItemRendered", this._getAppointmentRenderedAction());
                        break;
                    case "onAppointmentClick":
                        this._appointments.option("onItemClick", this._createActionByOption(name));
                        break;
                    case "onAppointmentDblClick":
                        this._appointments.option(name, this._createActionByOption(name));
                        break;
                    case "noDataText":
                    case "allowMultipleCellSelection":
                    case "accessKey":
                    case "onCellClick":
                        this._workSpace.option(name, value);
                        break;
                    case "crossScrollingEnabled":
                        this._loadResources().done($.proxy(function(resources) {
                            this._refreshWorkSpace(resources);
                            this._appointments.repaint()
                        }, this));
                        break;
                    case "cellDuration":
                        this._workSpace.option("hoursInterval", value / 60);
                        this._appointments.option("appointmentDurationInMinutes", value);
                        break;
                    case "tabIndex":
                    case "focusStateEnabled":
                        this._header.option(name, value);
                        this._workSpace.option(name, value);
                        this._appointments.option(name, value);
                        this.callBase(args);
                        break;
                    case "width":
                        this._header.option(name, value);
                        if (this.option("crossScrollingEnabled")) {
                            this._workSpace.option("width", value)
                        }
                        this.callBase(args);
                        this._dimensionChanged();
                        break;
                    case "height":
                        this.callBase(args);
                        this._dimensionChanged();
                        break;
                    case "editing":
                        this._initEditing();
                        var editing = this._editing;
                        this._bringEditingModeToAppointments(editing);
                        if (this._appointmentForm) {
                            this._appointmentForm.option("readOnly", !this._editing.allowUpdating)
                        }
                        this._hideTooltip();
                        break;
                    case "showAllDayPanel":
                        this._loadResources().done($.proxy(function(resources) {
                            this._filterAppointmentsByDate();
                            this._workSpace.option("allDayExpanded", value);
                            this._workSpace.option(name, value);
                            this._reloadDataSource()
                        }, this));
                        break;
                    case "appointmentTooltipTemplate":
                    case "appointmentPopupTemplate":
                    case "recurrenceEditMode":
                    case "remoteFiltering":
                    case "timeZone":
                        this._calculateTimezoneByOption();
                        this.repaint();
                        break;
                    case "startDateExpr":
                    case "endDateExpr":
                    case "startDateTimeZoneExpr":
                    case "endDateTimeZoneExpr":
                    case "textExpr":
                    case "descriptionExpr":
                    case "allDayExpr":
                    case "recurrenceRuleExpr":
                    case "recurrenceExceptionExpr":
                        this._updateExpression(name, value);
                        if (this._useDynamicTemplate()) {
                            this._appointments.repaint()
                        }
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _bringEditingModeToAppointments: function(editing) {
                var currentView = this.option("currentView");
                var editingConfig = {
                    allowDelete: editing.allowUpdating && editing.allowDeleting
                };
                if ("agenda" !== currentView) {
                    editingConfig.allowDrag = editing.allowDragging;
                    editingConfig.allowResize = editing.allowResizing;
                    editingConfig.allowAllDayResize = editing.allowResizing && "day" !== currentView
                }
                this._appointments.option(editingConfig);
                this._dropDownAppointments.repaintExisting(this.element())
            },
            _allowDragging: function() {
                return this._editing.allowDragging && "agenda" !== this.option("currentView")
            },
            _allowResizing: function() {
                return this._editing.allowResizing && "agenda" !== this.option("currentView")
            },
            _isAllDayExpanded: function(items) {
                return this.option("showAllDayPanel") && this._appointmentModel.hasAllDayAppointments(items, this.option("startDayHour"), this.option("endDayHour"))
            },
            _getTimezoneOffsetByOption: function() {
                return this._timezone
            },
            _calculateTimezoneByOption: function() {
                this._timezone = this._calculateTimezoneByValue(this.option("timeZone"))
            },
            _calculateTimezoneByValue: function(timezone) {
                var result = timezone;
                if ("string" === typeof timezone) {
                    var date = new Date;
                    result = SchedulerTimezones.getTimezoneOffsetById(timezone, Date.UTC(date.getFullYear(), date.getMonth(), date.getDate(), date.getHours(), date.getMinutes()))
                }
                return result
            },
            _filterAppointmentsByDate: function() {
                var dateRange = this._workSpace.getDateRange();
                this._appointmentModel.filterByDate(dateRange[0], dateRange[1], this.option("remoteFiltering"))
            },
            _loadResources: function() {
                var groups = this.option("groups"),
                    result = $.Deferred();
                this._resourcesManager.loadResources(groups).done($.proxy(function(resources) {
                    this._loadedResources = resources;
                    result.resolve(resources)
                }, this));
                return result.promise()
            },
            _dataSourceLoadedCallback: $.Callbacks(),
            _reloadDataSource: function() {
                if (this._dataSource) {
                    this._dataSource.load().done($.proxy(function(result) {
                        loading.hide();
                        this._fireContentReadyAction()
                    }, this)).fail(function() {
                        loading.hide()
                    });
                    this._dataSource.isLoading() && loading.show({
                        container: this.element(),
                        position: {
                            of: this.element()
                        }
                    })
                }
            },
            _dimensionChanged: function() {
                if ("agenda" !== this.option("currentView")) {
                    this._appointments && this._appointments.repaint()
                }
                this._toggleSmallClass();
                this._hideTooltip()
            },
            _toggleSmallClass: function() {
                var width = this.element().outerWidth();
                this.element().toggleClass(WIDGET_SMALL_CLASS, width < WIDGET_SMALL_WIDTH)
            },
            _visibilityChanged: function(visible) {
                visible && this._dimensionChanged()
            },
            _dataSourceOptions: function() {
                return {
                    paginate: false
                }
            },
            _init: function() {
                this.callBase();
                this._initExpressions({
                    startDate: this.option("startDateExpr"),
                    endDate: this.option("endDateExpr"),
                    startDateTimeZone: this.option("startDateTimeZoneExpr"),
                    endDateTimeZone: this.option("endDateTimeZoneExpr"),
                    allDay: this.option("allDayExpr"),
                    text: this.option("textExpr"),
                    description: this.option("descriptionExpr"),
                    recurrenceRule: this.option("recurrenceRuleExpr"),
                    recurrenceException: this.option("recurrenceExceptionExpr")
                });
                this._initDataSource();
                this._loadedResources = [];
                this._proxiedCustomizeStoreLoadOptionsHandler = $.proxy(this._customizeStoreLoadOptionsHandler, this);
                this._customizeStoreLoadOptions();
                this.element().addClass(WIDGET_CLASS);
                this._initEditing();
                this._resourcesManager = new SchedulerResourceManager(this.option("resources"));
                var combinedDataAccessors = this._combineDataAccessors();
                this._appointmentModel = new SchedulerAppointmentModel(this._dataSource, {
                    startDateExpr: this.option("startDateExpr"),
                    endDateExpr: this.option("endDateExpr"),
                    allDayExpr: this.option("allDayExpr"),
                    recurrenceRuleExpr: this.option("recurrenceRuleExpr"),
                    recurrenceExceptionExpr: this.option("recurrenceExceptionExpr")
                }, combinedDataAccessors);
                this._initActions();
                this._dropDownAppointments = new DropDownAppointments;
                this._subscribes = subscribes;
                this._calculateTimezoneByOption()
            },
            _combineDataAccessors: function() {
                var resourcesDataAccessors = this._resourcesManager._dataAccessors,
                    result = $.extend(true, {}, this._dataAccessors);
                $.each(resourcesDataAccessors, $.proxy(function(type, accessor) {
                    result[type].resources = accessor
                }, this));
                return result
            },
            _renderContent: function() {
                this._renderContentImpl()
            },
            _dataSourceChangedHandler: function(result) {
                var filteredItems = this.fire("prerenderFilter");
                this._workSpace.option("allDayExpanded", this._isAllDayExpanded(filteredItems));
                this._appointments.option("renderingStrategy", this._getAppointmentsRenderingStrategy());
                if ("agenda" === this.option("currentView")) {
                    this._appointments._renderingStrategy.calculateRows(filteredItems, 7, this.option("currentDate"))
                }
                this._setAppointmentsData(filteredItems);
                if ("agenda" === this.option("currentView")) {
                    this._workSpace._renderView();
                    this._dataSourceLoadedCallback.fireWith(this, [result])
                }
            },
            _initExpressions: function(fields) {
                var dataCoreUtils = __webpack_require__( /*! ../../core/utils/data */ 36);
                if (!this._dataAccessors) {
                    this._dataAccessors = {
                        getter: {},
                        setter: {}
                    }
                }
                $.each(fields, $.proxy(function(name, value) {
                    if (!!value) {
                        this._dataAccessors.getter[name] = dataCoreUtils.compileGetter(value);
                        this._dataAccessors.setter[name] = dataCoreUtils.compileSetter(value)
                    } else {
                        delete this._dataAccessors.getter[name];
                        delete this._dataAccessors.setter[name]
                    }
                }, this))
            },
            _updateExpression: function(name, value) {
                var exprObj = {};
                exprObj[name.replace("Expr", "")] = value;
                this._initExpressions(exprObj)
            },
            _initEditing: function() {
                var editing = this.option("editing");
                this._editing = {
                    allowAdding: !!editing,
                    allowUpdating: !!editing,
                    allowDeleting: !!editing,
                    allowResizing: !!editing,
                    allowDragging: !!editing
                };
                if (commonUtils.isObject(editing)) {
                    this._editing = $.extend(this._editing, editing)
                }
                this._editing.allowDragging = this._editing.allowDragging && this._editing.allowUpdating;
                this._editing.allowResizing = this._editing.allowResizing && this._editing.allowUpdating;
                this.element().toggleClass(WIDGET_READONLY_CLASS, this._isReadOnly())
            },
            _isReadOnly: function() {
                var result = true,
                    editing = this._editing;
                for (var prop in editing) {
                    if (editing.hasOwnProperty(prop)) {
                        result = result && !editing[prop]
                    }
                }
                return result
            },
            _customizeStoreLoadOptions: function() {
                this._dataSource && this._dataSource.on("customizeStoreLoadOptions", this._proxiedCustomizeStoreLoadOptionsHandler)
            },
            _dispose: function() {
                this._dataSource && this._dataSource.off("customizeStoreLoadOptions", this._proxiedCustomizeStoreLoadOptionsHandler);
                this.callBase()
            },
            _customizeStoreLoadOptionsHandler: function(options) {
                options.storeLoadOptions.dxScheduler = {
                    startDate: this.getStartViewDate(),
                    endDate: this.getEndViewDate(),
                    resources: this.option("resources")
                }
            },
            _initActions: function() {
                this._actions = {
                    onAppointmentAdding: this._createActionByOption("onAppointmentAdding"),
                    onAppointmentAdded: this._createActionByOption("onAppointmentAdded"),
                    onAppointmentUpdating: this._createActionByOption("onAppointmentUpdating"),
                    onAppointmentUpdated: this._createActionByOption("onAppointmentUpdated"),
                    onAppointmentDeleting: this._createActionByOption("onAppointmentDeleting"),
                    onAppointmentDeleted: this._createActionByOption("onAppointmentDeleted"),
                    onAppointmentFormCreated: this._createActionByOption("onAppointmentFormCreated")
                }
            },
            _getAppointmentRenderedAction: function() {
                return this._createActionByOption("onAppointmentRendered", {
                    excludeValidators: ["designMode", "disabled", "readOnly"]
                })
            },
            _renderFocusTarget: $.noop,
            _render: function() {
                this.callBase();
                this._renderHeader();
                this._appointments = this._createComponent("<div>", SchedulerAppointments, this._appointmentsConfig());
                this._toggleSmallClass();
                this._loadResources().done($.proxy(function(resources) {
                    this._renderWorkSpace(resources);
                    var $fixedContainer = this._workSpace.getFixedContainer(),
                        $allDayContainer = this._workSpace.getAllDayContainer();
                    this._appointments.option({
                        fixedContainer: $fixedContainer,
                        allDayContainer: $allDayContainer
                    });
                    this._filterAppointmentsByDate();
                    this._reloadDataSource()
                }, this))
            },
            _setAppointmentsData: function(items) {
                if (items) {
                    var opts = {
                        items: items
                    };
                    if (!this._useDynamicTemplate(items) || "item" !== this.option("appointmentTemplate")) {
                        opts.itemTemplate = this._getTemplateByOption("appointmentTemplate")
                    } else {
                        opts.itemTemplate = "item"
                    }
                    this._appointments.option(opts)
                }
            },
            _renderHeader: function() {
                var $header = $("<div>").appendTo(this.element());
                this._header = this._createComponent($header, SchedulerHeader, this._headerConfig())
            },
            _headerConfig: function() {
                return {
                    observer: this,
                    min: dateUtils.makeDate(this.option("min")),
                    max: dateUtils.makeDate(this.option("max")),
                    views: this.option("views"),
                    firstDayOfWeek: this.option("firstDayOfWeek"),
                    currentView: this.option("currentView"),
                    currentDate: dateUtils.trimTime(dateUtils.makeDate(this.option("currentDate"))),
                    tabIndex: this.option("tabIndex"),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    width: this.option("width"),
                    rtlEnabled: this.option("rtlEnabled"),
                    useDropDownViewSwitcher: this.option("useDropDownViewSwitcher")
                }
            },
            _useDynamicTemplate: function(items) {
                var hash = {
                    startDateExpr: "startDate",
                    endDateExpr: "endDate",
                    textExpr: "text",
                    recurrenceRuleExpr: "recurrenceRule",
                    startDateTimeZoneExpr: "startDateTimeZone",
                    endDateTimeZoneExpr: "endDateTimeZone"
                };
                var result = !!this.option("timeZone");
                if (!result) {
                    $.each(hash, $.proxy(function(name, value) {
                        if (this.option(name) !== value) {
                            result = true;
                            return false
                        }
                    }, this))
                }
                if (!result) {
                    $.each(items || [], $.proxy(function(_, appt) {
                        if (this.fire("getField", "startDateTimeZone", appt) || this.fire("getField", "endDateTimeZone", appt)) {
                            result = true;
                            return false
                        }
                    }, this))
                }
                return result
            },
            _appointmentsConfig: function() {
                var editing = this._editing,
                    that = this;
                var config = {
                    observer: this,
                    renderingStrategy: this._getAppointmentsRenderingStrategy(),
                    onItemRendered: this._getAppointmentRenderedAction(),
                    onItemClick: this._createActionByOption("onAppointmentClick"),
                    onAppointmentDblClick: this._createActionByOption("onAppointmentDblClick"),
                    tabIndex: this.option("tabIndex"),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    appointmentDurationInMinutes: this.option("cellDuration"),
                    allowDrag: this._allowDragging(),
                    allowDelete: this._editing.allowUpdating && this._editing.allowDeleting,
                    allowResize: this._allowResizing(),
                    allowAllDayResize: editing.allowResizing && "day" !== this.option("currentView"),
                    rtlEnabled: this.option("rtlEnabled"),
                    onContentReady: function() {
                        that._workSpace && that._workSpace.option("allDayExpanded", that._isAllDayExpanded(that._appointments.option("items")))
                    },
                    dayDuration: this._getDayDuration()
                };
                return config
            },
            _getAppointmentsRenderingStrategy: function() {
                return VIEWS_CONFIG[this.option("currentView")].renderingStrategy
            },
            _getDayDuration: function() {
                return this.option("endDayHour") - this.option("startDayHour")
            },
            _renderWorkSpace: function(groups) {
                this._workSpace = this._createComponent("<div>", VIEWS_CONFIG[this.option("currentView")].workSpace, this._workSpaceConfig(groups));
                this._workSpace.getWorkArea().append(this._appointments.element());
                this.element().append(this._workSpace.element());
                domUtils.triggerShownEvent(this._workSpace.element())
            },
            _workSpaceConfig: function(groups) {
                return {
                    observer: this,
                    noDataText: this.option("noDataText"),
                    min: dateUtils.makeDate(this.option("min")),
                    max: dateUtils.makeDate(this.option("max")),
                    currentDate: dateUtils.trimTime(dateUtils.makeDate(this.option("currentDate"))),
                    firstDayOfWeek: this.option("firstDayOfWeek"),
                    groups: groups,
                    startDayHour: this.option("startDayHour"),
                    endDayHour: this.option("endDayHour"),
                    tabIndex: this.option("tabIndex"),
                    accessKey: this.option("accessKey"),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    hoursInterval: this.option("cellDuration") / 60,
                    showAllDayPanel: this.option("showAllDayPanel"),
                    allDayExpanded: this._isAllDayExpanded(this._appointments.option("items")),
                    onCellClick: this._createActionByOption("onCellClick"),
                    crossScrollingEnabled: this.option("crossScrollingEnabled"),
                    allowMultipleCellSelection: this.option("allowMultipleCellSelection")
                }
            },
            _refreshWorkSpace: function(groups) {
                this._appointments.element().detach();
                this._workSpace._dispose();
                this._workSpace.element().remove();
                delete this._workSpace;
                this._renderWorkSpace(groups);
                this._appointments.option({
                    fixedContainer: this._workSpace.getFixedContainer(),
                    allDayContainer: this._workSpace.getAllDayContainer()
                })
            },
            getWorkSpaceScrollable: function() {
                return this._workSpace.getScrollable()
            },
            getWorkSpaceScrollableScrollTop: function() {
                return this._workSpace.getScrollableScrollTop()
            },
            getWorkSpaceScrollableScrollLeft: function() {
                return this._workSpace.getScrollableScrollLeft()
            },
            getWorkSpaceScrollableContainer: function() {
                return this._workSpace.getScrollableContainer()
            },
            getWorkSpaceAllDayHeight: function() {
                return this._workSpace.getAllDayHeight()
            },
            getWorkSpaceHeaderPanelHeight: function() {
                return this._workSpace.getHeaderPanelHeight()
            },
            getWorkSpaceDateTableOffset: function() {
                return !this.option("crossScrollingEnabled") || this.option("rtlEnabled") ? this._workSpace.getTimePanelWidth() : 0
            },
            getWorkSpace: function() {
                return this._workSpace
            },
            getHeader: function() {
                return this._header
            },
            _createPopup: function(appointmentData, processTimeZone) {
                if (this._$popup) {
                    this._popup.element().remove()
                }
                this._$popup = $("<div>").addClass(APPOINTMENT_POPUP_CLASS).appendTo(this.element());
                this._initDynamicPopupTemplate(appointmentData, processTimeZone);
                this._popup = this._createComponent(this._$popup, Popup, this._popupConfig(appointmentData))
            },
            _popupContent: function(appointmentData, processTimeZone) {
                var $popupContent = this._popup.content();
                this._createAppointmentForm(appointmentData, $popupContent, processTimeZone);
                return $popupContent
            },
            _createAppointmentForm: function(appointmentData, $content, processTimeZone) {
                var allDay = this.fire("getField", "allDay", appointmentData),
                    resources = this.option("resources"),
                    startDate = this.fire("getField", "startDate", appointmentData),
                    endDate = this.fire("getField", "endDate", appointmentData);
                AppointmentForm.prepareAppointmentFormEditors(allDay, {
                    textExpr: this.option("textExpr"),
                    allDayExpr: this.option("allDayExpr"),
                    startDateExpr: this.option("startDateExpr"),
                    endDateExpr: this.option("endDateExpr"),
                    descriptionExpr: this.option("descriptionExpr"),
                    recurrenceRuleExpr: this.option("recurrenceRuleExpr"),
                    startDateTimeZoneExpr: this.option("startDateTimeZoneExpr"),
                    endDateTimeZoneExpr: this.option("endDateTimeZoneExpr")
                }, this);
                if (resources && resources.length) {
                    this._resourcesManager.setResources(this.option("resources"));
                    AppointmentForm.concatResources(this._resourcesManager.getEditors())
                }
                $.each(this._resourcesManager.getResourcesFromItem(appointmentData, true) || {}, function(resourceName, resourceValue) {
                    appointmentData[resourceName] = resourceValue
                });
                var formData = $.extend(true, {}, appointmentData);
                if (processTimeZone) {
                    startDate = this.fire("convertDateByTimezone", startDate);
                    endDate = this.fire("convertDateByTimezone", endDate);
                    this.fire("setField", "startDate", formData, startDate);
                    this.fire("setField", "endDate", formData, endDate)
                }
                this._appointmentForm = AppointmentForm.create($.proxy(this._createComponent, this), $content, this._editAppointmentData ? !this._editing.allowUpdating : false, formData);
                var recurrenceRuleExpr = this.option("recurrenceRuleExpr"),
                    recurrentEditorItem = recurrenceRuleExpr ? this._appointmentForm.itemOption(recurrenceRuleExpr) : null;
                if (recurrentEditorItem) {
                    var options = recurrentEditorItem.editorOptions || {};
                    options.startDate = startDate;
                    this._appointmentForm.itemOption(recurrenceRuleExpr, "editorOptions", options)
                }
                this._actions.onAppointmentFormCreated({
                    form: this._appointmentForm,
                    appointmentData: appointmentData
                })
            },
            _initDynamicPopupTemplate: function(appointmentData, processTimeZone) {
                var that = this;
                this._dynamicTemplates.appointmentPopup = new FunctionTemplate(function(data, index, $container) {
                    var $popupContent = that._popupContent(appointmentData, processTimeZone);
                    $container.append($popupContent);
                    return $container
                })
            },
            _popupConfig: function(appointmentData) {
                var template = this._getTemplateByOption("appointmentPopupTemplate");
                return {
                    _templates: this.option("_templates"),
                    templateProvider: this.option("templateProvider"),
                    width: APPOINTEMENT_POPUP_WIDTH,
                    onHiding: $.proxy(function() {
                        this.focus()
                    }, this),
                    contentTemplate: new DynamicTemplate(function(options) {
                        return new MoveTemplate(template.render({
                            model: appointmentData,
                            container: options.container
                        }))
                    }),
                    defaultOptionsRules: [{
                        device: function(device) {
                            return !devices.current().generic
                        },
                        options: {
                            fullScreen: true
                        }
                    }]
                }
            },
            _getPopupToolbarItems: function() {
                return [{
                    shortcut: "done",
                    location: "after",
                    onClick: $.proxy(this._doneButtonClickHandler, this)
                }, {
                    shortcut: "cancel",
                    location: "after"
                }]
            },
            _doneButtonClickHandler: function(args) {
                var validation = this._appointmentForm.validate();
                args.cancel = true;
                if (validation && !validation.isValid) {
                    return
                }
                this._saveChanges();
                var startDate = this.fire("getField", "startDate", this._appointmentForm.option("formData"));
                this._workSpace.updateScrollPosition(startDate)
            },
            _saveChanges: function() {
                var formData = this._appointmentForm.option("formData"),
                    oldData = this._editAppointmentData,
                    recData = this._updatedRecAppointment;

                function convert(obj, dateFieldName) {
                    var date = new Date(this.fire("getField", dateFieldName, obj));
                    var tzDiff = 36e5 * this._getTimezoneOffsetByOption() + this.fire("getClientTimezoneOffset");
                    return new Date(date.getTime() + tzDiff)
                }
                if (oldData) {
                    var processedStartDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "startDate", formData));
                    var processedEndDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "endDate", formData));
                    this.fire("setField", "startDate", formData, processedStartDate);
                    this.fire("setField", "endDate", formData, processedEndDate)
                }
                if (oldData && !recData) {
                    this.updateAppointment(oldData, formData)
                } else {
                    recData && this.updateAppointment(oldData, recData);
                    delete this._updatedRecAppointment;
                    if ("number" === typeof this._getTimezoneOffsetByOption()) {
                        this.fire("setField", "startDate", formData, convert.call(this, formData, "startDate"));
                        this.fire("setField", "endDate", formData, convert.call(this, formData, "endDate"))
                    }
                    this.addAppointment(formData)
                }
            },
            _checkRecurringAppointment: function(targetAppointment, singleAppointment, exceptionDate, callback, isDeleted, isPopupEditing) {
                delete this._updatedRecAppointment;
                var recurrenceRule = this.fire("getField", "recurrenceRule", targetAppointment);
                if (!recurrenceUtils.getRecurrenceRule(recurrenceRule).isValid || !this._editing.allowUpdating) {
                    callback();
                    return
                }
                var editMode = this.option("recurrenceEditMode");
                switch (editMode) {
                    case "series":
                        callback();
                        break;
                    case "occurrence":
                        this._singleAppointmentChangesHandler(targetAppointment, singleAppointment, exceptionDate, isDeleted, isPopupEditing);
                        break;
                    default:
                        this._showRecurrenceChangeConfirm(isDeleted).done($.proxy(function(result) {
                            result && callback();
                            !result && this._singleAppointmentChangesHandler(targetAppointment, singleAppointment, exceptionDate, isDeleted, isPopupEditing)
                        }, this)).fail($.proxy(function() {
                            this._appointments.moveAppointmentBack()
                        }, this))
                }
            },
            _singleAppointmentChangesHandler: function(targetAppointment, singleAppointment, exceptionDate, isDeleted, isPopupEditing) {
                exceptionDate = new Date(exceptionDate);

                function processAppointmentDates(appointment, commonTimezoneOffset) {
                    var clientTzOffset = -(this._subscribes.getClientTimezoneOffset() / 36e5);
                    var processedStartDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "startDate", appointment), this.fire("getField", "startDateTimeZone", appointment));
                    var processedEndDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "endDate", appointment), this.fire("getField", "endDateTimeZone", appointment));
                    if ("number" === typeof commonTimezoneOffset && !isNaN(commonTimezoneOffset)) {
                        var processedStartDateInUTC = processedStartDate.getTime() - 36e5 * clientTzOffset,
                            processedEndDateInUTC = processedEndDate.getTime() - 36e5 * clientTzOffset;
                        processedStartDate = new Date(processedStartDateInUTC + 36e5 * commonTimezoneOffset);
                        processedEndDate = new Date(processedEndDateInUTC + 36e5 * commonTimezoneOffset)
                    }
                    this.fire("setField", "startDate", appointment, processedStartDate);
                    this.fire("setField", "endDate", appointment, processedEndDate)
                }
                this.fire("setField", "recurrenceRule", singleAppointment, "");
                this.fire("setField", "recurrenceException", singleAppointment, "");
                if (!isDeleted && !isPopupEditing) {
                    processAppointmentDates.call(this, singleAppointment, this._getTimezoneOffsetByOption());
                    this.addAppointment(singleAppointment)
                }
                var recurrenceException = this._getRecurrenceException(exceptionDate, targetAppointment),
                    updatedAppointment = $.extend({}, targetAppointment, {
                        recurrenceException: recurrenceException
                    });
                if (isPopupEditing) {
                    this._updatedRecAppointment = updatedAppointment;
                    processAppointmentDates.call(this, singleAppointment);
                    this._showAppointmentPopup(singleAppointment, true, true);
                    this._editAppointmentData = targetAppointment
                } else {
                    this._updateAppointment(targetAppointment, updatedAppointment)
                }
            },
            _getRecurrenceException: function(exceptionDate, targetAppointment) {
                var startDate = this.getAppointmentsInstance()._getStartDate(targetAppointment),
                    exceptionByDate = this._getRecurrenceExceptionDate(exceptionDate, startDate),
                    recurrenceException = this.fire("getField", "recurrenceException", targetAppointment);
                return recurrenceException ? recurrenceException + "," + exceptionByDate : exceptionByDate
            },
            _getRecurrenceExceptionDate: function(exceptionDate, targetStartDate) {
                exceptionDate.setHours(targetStartDate.getHours());
                exceptionDate.setMinutes(targetStartDate.getMinutes());
                exceptionDate.setSeconds(targetStartDate.getSeconds());
                return dateLocalization.format(exceptionDate, "yyyyMMddTHHmmss")
            },
            _showRecurrenceChangeConfirm: function(isDeleted) {
                var message = messageLocalization.format(isDeleted ? "dxScheduler-confirmRecurrenceDeleteMessage" : "dxScheduler-confirmRecurrenceEditMessage"),
                    seriesText = messageLocalization.format(isDeleted ? "dxScheduler-confirmRecurrenceDeleteSeries" : "dxScheduler-confirmRecurrenceEditSeries"),
                    occurrenceText = messageLocalization.format(isDeleted ? "dxScheduler-confirmRecurrenceDeleteOccurrence" : "dxScheduler-confirmRecurrenceEditOccurrence");
                return dialog.custom({
                    message: message,
                    showCloseButton: true,
                    showTitle: true,
                    toolbarItems: [{
                        text: seriesText,
                        onClick: function() {
                            return true
                        }
                    }, {
                        text: occurrenceText,
                        onClick: function() {
                            return false
                        }
                    }]
                }).show()
            },
            _getUpdatedData: function(options) {
                var target = options.data || options,
                    cellData = this.getTargetCellData(),
                    targetAllDay = this.fire("getField", "allDay", target),
                    targetStartDate = dateUtils.makeDate(this.fire("getField", "startDate", target)),
                    targetEndDate = dateUtils.makeDate(this.fire("getField", "endDate", target)),
                    allDay = cellData.allDay,
                    date = cellData.date || targetStartDate,
                    groups = cellData.groups,
                    duration = targetEndDate.getTime() - targetStartDate.getTime();
                var updatedData = {};
                this.fire("setField", "allDay", updatedData, allDay);
                this.fire("setField", "startDate", updatedData, date);
                var endDate = new Date(date.getTime() + duration);
                if (this.appointmentTakesAllDay(target) && !updatedData.allDay && this._workSpace.supportAllDayRow()) {
                    endDate = this._workSpace.calculateEndDate(date)
                }
                if (targetAllDay && !this._workSpace.supportAllDayRow()) {
                    var dateCopy = new Date(date);
                    dateCopy.setHours(0);
                    endDate = new Date(dateCopy.getTime() + duration);
                    if (0 !== endDate.getHours()) {
                        endDate.setHours(this.option("endDayHour"))
                    }
                }
                this.fire("setField", "endDate", updatedData, endDate);
                for (var name in groups) {
                    if (groups.hasOwnProperty(name)) {
                        updatedData[name] = groups[name]
                    }
                }
                return updatedData
            },
            _getCoordinates: function(dates, appointmentResources, allDay) {
                var result = [];
                for (var i = 0; i < dates.length; i++) {
                    result = result.concat(this._workSpace.getCoordinatesByDateInGroup(dates[i], appointmentResources, allDay))
                }
                return result
            },
            _getSingleAppointmentData: function(appointmentData, options, $appointment, skipHoursProcessing) {
                var updatedStartDate, target = appointmentData,
                    updatedData = options.skipDateCalculation ? {} : this._getUpdatedData(options),
                    appointment = $.extend({}, target, updatedData),
                    allDay = this.fire("getField", "allDay", target),
                    allowAllDay = this._workSpace.supportAllDayRow() && allDay,
                    startDate = new Date(this.fire("getField", "startDate", appointment)),
                    endDate = new Date(this.fire("getField", "endDate", appointment)),
                    appointmentDuration = endDate.getTime() - startDate.getTime();
                if (commonUtils.isDefined($appointment)) {
                    var apptDataCalculator = this._appointments._renderingStrategy.getAppointmentDataCalculator();
                    if ($.isFunction(apptDataCalculator)) {
                        updatedStartDate = apptDataCalculator($appointment, startDate).startDate
                    } else {
                        var coordinates = translator.locate($appointment);
                        updatedStartDate = new Date(this._workSpace.getCellDataByCoordinates(coordinates, allowAllDay).startDate);
                        if (!skipHoursProcessing) {
                            updatedStartDate.setHours(startDate.getHours());
                            updatedStartDate.setMinutes(startDate.getMinutes())
                        }
                    }
                }
                if (!updatedStartDate) {
                    updatedStartDate = appointmentData.startDate
                }
                this.fire("setField", "startDate", appointment, updatedStartDate);
                this.fire("setField", "endDate", appointment, new Date(updatedStartDate.getTime() + appointmentDuration));
                return appointment
            },
            subscribe: function(subject, action) {
                this._subscribes[subject] = subscribes[subject] = action
            },
            fire: function(subject) {
                var callback = this._subscribes[subject],
                    args = Array.prototype.slice.call(arguments);
                if (!$.isFunction(callback)) {
                    throw errors.Error("E1031", subject)
                }
                return callback.apply(this, args.slice(1))
            },
            getTargetCellData: function() {
                return this._workSpace.getDataByDroppableCell()
            },
            showAppointmentTooltip: function(appointmentData, singleAppointmentData, $appointment) {
                appointmentTooltip.show(appointmentData, singleAppointmentData, $appointment, this)
            },
            _hideTooltip: function() {
                appointmentTooltip.hide()
            },
            _updateAppointment: function(target, appointment, onUpdatePrevented) {
                var updatingOptions = {
                    newData: appointment,
                    oldData: target,
                    cancel: false
                };
                this._actions.onAppointmentUpdating(updatingOptions);
                this._processActionResult(updatingOptions, function(canceled) {
                    if (!canceled) {
                        this._expandAllDayPanel(appointment);
                        this._appointmentModel.update(target, appointment).always($.proxy(function(e) {
                            this._executeActionWhenOperationIsCompleted(this._actions.onAppointmentUpdated, appointment, e)
                        }, this))
                    } else {
                        if ($.isFunction(onUpdatePrevented)) {
                            onUpdatePrevented.call(this)
                        }
                    }
                })
            },
            _processActionResult: function(actionOptions, callback) {
                $.when(actionOptions.cancel).then($.proxy(callback, this))
            },
            _expandAllDayPanel: function(appointment) {
                if (!this._isAllDayExpanded(this._appointments.option("items")) && this.appointmentTakesAllDay(appointment)) {
                    this._workSpace.option("allDayExpanded", true)
                }
            },
            _executeActionWhenOperationIsCompleted: function(action, appointment, e) {
                var options = {
                        appointmentData: appointment
                    },
                    isError = e && "Error" === e.name;
                if (isError) {
                    options.error = e
                } else {
                    if (this._popup && this._popup.option("visible")) {
                        this._popup.hide()
                    }
                }
                action(options);
                this._fireContentReadyAction()
            },
            _showAppointmentPopup: function(appointmentData, showButtons, processTimeZone) {
                this._createPopup(appointmentData, processTimeZone);
                var toolbarItems = [],
                    showCloseButton = true;
                if (!commonUtils.isDefined(showButtons) || showButtons) {
                    toolbarItems = this._getPopupToolbarItems();
                    showCloseButton = this._popup.initialOption("showCloseButton")
                }
                this._popup.option({
                    toolbarItems: toolbarItems,
                    showCloseButton: showCloseButton
                });
                this._popup.show()
            },
            getAppointmentPopup: function() {
                return this._popup
            },
            getAppointmentDetailsForm: function() {
                return this._appointmentForm
            },
            getAppointmentsInstance: function() {
                return this._appointments
            },
            getResourceManager: function() {
                return this._resourcesManager
            },
            getAppointmentResourceData: function(field, value) {
                return this._resourcesManager.getResourceDataByValue(field, value)
            },
            getActions: function() {
                return this._actions
            },
            appointmentTakesAllDay: function(appointment) {
                return this._appointmentModel.appointmentTakesAllDay(appointment, this.option("startDayHour"), this.option("endDayHour"))
            },
            recurrenceEditorVisibilityChanged: function(visible) {
                if (this._appointmentForm) {
                    this._appointmentForm.element().find("." + RECURRENCE_EDITOR_ITEM_CLASS).toggleClass(RECURRENCE_EDITOR_OPENED_ITEM_CLASS, visible)
                }
            },
            dayHasAppointment: function(day, appointment, trimTime) {
                var startDate = dateUtils.makeDate(this.fire("getField", "startDate", appointment)),
                    endDate = dateUtils.makeDate(this.fire("getField", "endDate", appointment)),
                    startDateTimeZone = this.fire("getField", "startDateTimeZone", appointment),
                    endDateTimeZone = this.fire("getField", "endDateTimeZone", appointment);
                startDate = this.fire("convertDateByTimezone", startDate, startDateTimeZone);
                endDate = this.fire("convertDateByTimezone", endDate, endDateTimeZone);
                if (day.getTime() === endDate.getTime()) {
                    return false
                }
                if (trimTime) {
                    day = dateUtils.trimTime(day);
                    startDate = dateUtils.trimTime(startDate);
                    endDate = dateUtils.trimTime(endDate)
                }
                var dayTimeStamp = day.getTime(),
                    startDateTimeStamp = startDate.getTime(),
                    endDateTimeStamp = endDate.getTime();
                return $.inArray(dayTimeStamp, [startDateTimeStamp, endDateTimeStamp]) > -1 || startDateTimeStamp < dayTimeStamp && endDateTimeStamp > dayTimeStamp
            },
            setTargetedAppointmentResources: function(targetedAppointment, appointmentElement, appointmentIndex) {
                var groups = this.option("groups");
                if (groups && groups.length) {
                    var getGroups, setResourceCallback, resourcesSetter = this._resourcesManager._dataAccessors.setter,
                        workSpace = this._workSpace;
                    if ("agenda" === this.option("currentView")) {
                        getGroups = function() {
                            var apptSettings = this.getAppointmentsInstance()._positionMap[appointmentIndex];
                            return workSpace._getCellGroups(apptSettings[0].groupIndex)
                        };
                        setResourceCallback = function(_, group) {
                            resourcesSetter[group.name](targetedAppointment, group.id)
                        }
                    } else {
                        getGroups = function() {
                            var apptPosition = appointmentElement.position();
                            return workSpace.getCellDataByCoordinates(apptPosition).groups
                        };
                        setResourceCallback = function(field, value) {
                            resourcesSetter[field](targetedAppointment, value)
                        }
                    }
                    $.each(getGroups.call(this), setResourceCallback)
                }
            },
            getStartViewDate: function() {
                return this._workSpace.getStartViewDate()
            },
            getEndViewDate: function() {
                return this._workSpace.getEndViewDate()
            },
            showAppointmentPopup: function(appointmentData, createNewAppointment, currentAppointmentData) {
                var singleAppointment = !currentAppointmentData && appointmentData.length ? this._getSingleAppointmentData(appointmentData, appointmentData) : currentAppointmentData;
                var startDate;
                if (currentAppointmentData) {
                    startDate = this.fire("getField", "startDate", currentAppointmentData)
                } else {
                    startDate = this.fire("getField", "startDate", appointmentData)
                }
                this._checkRecurringAppointment(appointmentData, singleAppointment, startDate, $.proxy(function() {
                    var editing = this._editing;
                    if (createNewAppointment) {
                        delete this._editAppointmentData;
                        editing.allowAdding && this._showAppointmentPopup(appointmentData, true, false)
                    } else {
                        this._editAppointmentData = appointmentData;
                        this._showAppointmentPopup(appointmentData, editing.allowUpdating, true)
                    }
                }, this), false, true)
            },
            scrollToTime: function(hours, minutes, date) {
                this._workSpace.scrollToTime(hours, minutes, date)
            },
            addAppointment: function(appointment) {
                var text = this.fire("getField", "text", appointment);
                if (!text) {
                    this.fire("setField", "text", appointment, "")
                }
                var addingOptions = {
                    appointmentData: appointment,
                    cancel: false
                };
                this._actions.onAppointmentAdding(addingOptions);
                this._processActionResult(addingOptions, function(canceled) {
                    if (!canceled) {
                        this._expandAllDayPanel(appointment);
                        this._appointmentModel.add(appointment, {
                            value: this._getTimezoneOffsetByOption(),
                            clientOffset: this.fire("getClientTimezoneOffset")
                        }).always($.proxy(function(e) {
                            this._executeActionWhenOperationIsCompleted(this._actions.onAppointmentAdded, appointment, e)
                        }, this))
                    }
                })
            },
            updateAppointment: function(target, appointment) {
                this._updateAppointment(target, appointment)
            },
            deleteAppointment: function(appointment) {
                var deletingOptions = {
                    appointmentData: appointment,
                    cancel: false
                };
                this._actions.onAppointmentDeleting(deletingOptions);
                this._processActionResult(deletingOptions, function(canceled) {
                    if (!canceled) {
                        this._appointmentModel.remove(appointment).always($.proxy(function(e) {
                            this._executeActionWhenOperationIsCompleted(this._actions.onAppointmentDeleted, appointment, e)
                        }, this))
                    }
                })
            },
            focus: function() {
                if (this._editAppointmentData) {
                    this._appointments.focus()
                } else {
                    this._workSpace.focus()
                }
            }
        }).include(DataHelperMixin);
        registerComponent("dxScheduler", Scheduler);
        module.exports = Scheduler
    },
    /*!**************************************************!*\
      !*** ./Scripts/ui/scheduler/utils.recurrence.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../../core/errors */ 17),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52);
        var intervalMap = {
            secondly: "seconds",
            minutely: "minutes",
            hourly: "hours",
            daily: "days",
            weekly: "weeks",
            monthly: "months",
            yearly: "years"
        };
        var dateSetterMap = {
            bysecond: function(date, value) {
                date.setSeconds(value)
            },
            byminute: function(date, value) {
                date.setMinutes(value)
            },
            byhour: function(date, value) {
                date.setHours(value)
            },
            bymonth: function(date, value) {
                date.setMonth(value)
            },
            bymonthday: function(date, value) {
                date.setDate(value);
                correctDate(date, value)
            },
            byday: function(date, dayOfWeek) {
                date.setDate(date.getDate() - date.getDay() + dayOfWeek)
            }
        };
        var dateGetterMap = {
            bysecond: "getSeconds",
            byminute: "getMinutes",
            byhour: "getHours",
            bymonth: "getMonth",
            bymonthday: "getDate",
            byday: "getDay"
        };
        var ruleNames = ["freq", "interval", "byday", "bymonth", "bymonthday", "count", "until", "byhour", "byminute", "bysecond"],
            freqNames = ["DAILY", "WEEKLY", "MONTHLY", "YEARLY", "SECONDLY", "MINUTELY", "HOURLY"],
            days = {
                SU: 0,
                MO: 1,
                TU: 2,
                WE: 3,
                TH: 4,
                FR: 5,
                SA: 6
            };
        var dateInRecurrenceRange = function(recurrenceString, currentDate, viewStartDate, viewEndDate, recurrenceException) {
            var result = [];
            if (recurrenceString) {
                result = getDatesByRecurrence(recurrenceString, currentDate, viewStartDate, viewEndDate, recurrenceException)
            }
            return !!result.length
        };
        var normalizeInterval = function(freq, interval) {
            var intervalObject = {},
                intervalField = intervalMap[freq.toLowerCase()];
            intervalObject[intervalField] = interval;
            return intervalObject
        };
        var getDatesByRecurrenceException = function(ruleValues) {
            var result = [];
            for (var i = 0, len = ruleValues.length; i < len; i++) {
                result[i] = getDateByAsciiString(ruleValues[i])
            }
            return result
        };
        var dateIsRecurrenceException = function(date, recurrenceException) {
            var result = false;
            if (!recurrenceException) {
                return result
            }
            var splittedDates = recurrenceException.split(","),
                exceptDates = getDatesByRecurrenceException(splittedDates),
                shortFormat = /\d{8}$/;
            for (var i = 0, len = exceptDates.length; i < len; i++) {
                if (splittedDates[i].match(shortFormat)) {
                    var diffs = getDatePartDiffs(date, exceptDates[i]);
                    if (0 === diffs.years && 0 === diffs.months && 0 === diffs.days) {
                        result = true
                    }
                } else {
                    if (date.getTime() === exceptDates[i].getTime()) {
                        result = true
                    }
                }
            }
            return result
        };
        var doNextIteration = function(date, startIntervalDate, endIntervalDate, recurrenceRule, iterationCount) {
            var dateInInterval, matchCountIsCorrect = true;
            endIntervalDate = endIntervalDate.getTime();
            if (recurrenceRule.until) {
                if (recurrenceRule.until.getTime() < endIntervalDate) {
                    endIntervalDate = recurrenceRule.until.getTime()
                }
            }
            if (recurrenceRule.count) {
                if (iterationCount === recurrenceRule.count) {
                    matchCountIsCorrect = false
                }
            }
            dateInInterval = date.getTime() >= startIntervalDate.getTime() && date.getTime() <= endIntervalDate;
            return dateInInterval && matchCountIsCorrect
        };
        var getDatesByRecurrence = function(recurrenceString, recurrenceStartDate, viewStartDate, viewEndDate, recurrenceException) {
            var dateRules, result = [],
                recurrenceRule = getRecurrenceRule(recurrenceString),
                rule = recurrenceRule.rule,
                iterationCount = 0;
            if (!recurrenceRule.isValid || !rule.freq) {
                return result
            }
            rule.interval = normalizeInterval(rule.freq, rule.interval);
            dateRules = splitDateRules(rule);
            getDatesByRules(dateRules, new Date(recurrenceStartDate)).forEach(function(currentDate, i) {
                while (doNextIteration(currentDate, recurrenceStartDate, viewEndDate, rule, iterationCount)) {
                    iterationCount++;
                    if (!dateIsRecurrenceException(currentDate, recurrenceException)) {
                        if (currentDate.getTime() >= viewStartDate.getTime()) {
                            if (checkDateByRule(currentDate, [dateRules[i]])) {
                                result.push(currentDate)
                            }
                        }
                    }
                    currentDate = incrementDate(currentDate, recurrenceStartDate, rule, i)
                }
            });
            return result.sort(function(a, b) {
                return a - b
            })
        };
        var correctDate = function(originalDate, date) {
            if (originalDate.getDate() !== date) {
                originalDate.setDate(date)
            }
        };
        var incrementDate = function(date, originalStartDate, rule, iterationStep) {
            date = dateUtils.addInterval(date, rule.interval);
            if ("MONTHLY" === rule.freq) {
                var expectedDate = originalStartDate.getDate();
                if (rule.bymonthday) {
                    expectedDate = Number(rule.bymonthday.split(",")[iterationStep])
                }
                correctDate(date, expectedDate)
            }
            return date
        };
        var getDatePartDiffs = function(date1, date2) {
            return {
                years: date1.getFullYear() - date2.getFullYear(),
                months: date1.getMonth() - date2.getMonth(),
                days: date1.getDate() - date2.getDate(),
                hours: date1.getHours() - date2.getHours(),
                minutes: date1.getMinutes() - date2.getMinutes(),
                seconds: date1.getSeconds() - date2.getSeconds()
            }
        };
        var getRecurrenceRule = function(recurrence) {
            var result = {
                rule: {},
                isValid: false
            };
            if (recurrence) {
                result.rule = parseRecurrenceRule(recurrence);
                result.isValid = validateRRule(result.rule, recurrence)
            }
            return result
        };
        var loggedWarnings = [];
        var validateRRule = function(rule, recurrence) {
            if (brokenRuleNameExists(rule) || $.inArray(rule.freq, freqNames) === -1 || wrongCountRule(rule) || wrongIntervalRule(rule) || wrongDayOfWeek(rule) || wrongByMonthDayRule(rule) || wrongByMonth(rule) || wrongUntilRule(rule)) {
                logBrokenRule(recurrence);
                return false
            }
            return true
        };
        var wrongUntilRule = function(rule) {
            var wrongUntil = false,
                until = rule.until;
            if (void 0 !== until && !(until instanceof Date)) {
                wrongUntil = true
            }
            return wrongUntil
        };
        var wrongCountRule = function(rule) {
            var wrongCount = false,
                count = rule.count;
            if (count && "string" === typeof count) {
                wrongCount = true
            }
            return wrongCount
        };
        var wrongByMonthDayRule = function(rule) {
            var wrongByMonthDay = false,
                byMonthDay = rule.bymonthday;
            if (byMonthDay && isNaN(parseInt(byMonthDay))) {
                wrongByMonthDay = true
            }
            return wrongByMonthDay
        };
        var wrongByMonth = function(rule) {
            var wrongByMonth = false,
                byMonth = rule.bymonth;
            if (byMonth && isNaN(parseInt(byMonth))) {
                wrongByMonth = true
            }
            return wrongByMonth
        };
        var wrongIntervalRule = function(rule) {
            var wrongInterval = false,
                interval = rule.interval;
            if (interval && "string" === typeof interval) {
                wrongInterval = true
            }
            return wrongInterval
        };
        var wrongDayOfWeek = function(rule) {
            var daysByRule = daysFromByDayRule(rule),
                brokenDaysExist = false;
            $.each(daysByRule, function(_, day) {
                if (!days.hasOwnProperty(day)) {
                    brokenDaysExist = true;
                    return false
                }
            });
            return brokenDaysExist
        };
        var brokenRuleNameExists = function(rule) {
            var brokenRuleExists = false;
            $.each(rule, function(ruleName, _) {
                if ($.inArray(ruleName, ruleNames) === -1) {
                    brokenRuleExists = true;
                    return false
                }
            });
            return brokenRuleExists
        };
        var logBrokenRule = function(recurrence) {
            if ($.inArray(recurrence, loggedWarnings) === -1) {
                errors.log("W0006", recurrence);
                loggedWarnings.push(recurrence)
            }
        };
        var parseRecurrenceRule = function(recurrence) {
            var ruleObject = {},
                ruleParts = recurrence.split(";");
            for (var i = 0, len = ruleParts.length; i < len; i++) {
                var rule = ruleParts[i].split("="),
                    ruleName = rule[0].toLowerCase(),
                    ruleValue = rule[1];
                ruleObject[ruleName] = ruleValue
            }
            var count = parseInt(ruleObject.count);
            if (!isNaN(count)) {
                ruleObject.count = count
            }
            if (ruleObject.interval) {
                var interval = parseInt(ruleObject.interval);
                if (!isNaN(interval)) {
                    ruleObject.interval = interval
                }
            } else {
                ruleObject.interval = 1
            }
            if (ruleObject.freq && ruleObject.until) {
                ruleObject.until = getDateByAsciiString(ruleObject.until)
            }
            return ruleObject
        };
        var getDateByAsciiString = function(string) {
            if ("string" !== typeof string) {
                return string
            }
            var arrayDate = string.match(/(\d{4})(\d{2})(\d{2})(T(\d{2})(\d{2})(\d{2}))?(Z)?/);
            if (!arrayDate) {
                return null
            }
            var isUTC = void 0 !== arrayDate[8],
                currentOffset = 6e4 * (new Date).getTimezoneOffset(),
                date = new(Function.prototype.bind.apply(Date, prepareDateArrayToParse(arrayDate)));
            if (isUTC) {
                date = new Date(date.getTime() - currentOffset)
            }
            return date
        };
        var prepareDateArrayToParse = function(arrayDate) {
            arrayDate.shift();
            if (void 0 === arrayDate[3]) {
                arrayDate.splice(3)
            } else {
                arrayDate.splice(3, 1);
                arrayDate.splice(6)
            }
            arrayDate[1]--;
            arrayDate.unshift(null);
            return arrayDate
        };
        var daysFromByDayRule = function(rule) {
            var result = [];
            if (rule.byday) {
                result = rule.byday.split(",")
            }
            return result
        };
        var getAsciiStringByDate = function(date) {
            var currentOffset = 6e4 * (new Date).getTimezoneOffset();
            date = new Date(date.getTime() + currentOffset);
            return date.getFullYear() + ("0" + (date.getMonth() + 1)).slice(-2) + ("0" + date.getDate()).slice(-2) + "T" + ("0" + date.getHours()).slice(-2) + ("0" + date.getMinutes()).slice(-2) + ("0" + date.getSeconds()).slice(-2) + "Z"
        };
        var splitDateRules = function(rule) {
            var result = [];
            for (var field in dateSetterMap) {
                if (!rule[field]) {
                    continue
                }
                var ruleFieldValues = rule[field].split(","),
                    ruleArray = getDateRuleArray(field, ruleFieldValues);
                result = result.length ? extendObjectArray(ruleArray, result) : ruleArray
            }
            return result
        };
        var getDateRuleArray = function(field, values) {
            var result = [];
            for (var i = 0, length = values.length; i < length; i++) {
                var dateRule = {};
                dateRule[field] = handleRuleFieldValue(field, values[i]);
                result.push(dateRule)
            }
            return result
        };
        var handleRuleFieldValue = function(field, value) {
            var result = parseInt(value);
            if ("bymonth" === field) {
                result -= 1
            }
            if ("byday" === field) {
                result = days[value]
            }
            return result
        };
        var extendObjectArray = function(firstArray, secondArray) {
            var result = [];
            for (var i = 0, firstArrayLength = firstArray.length; i < firstArrayLength; i++) {
                for (var j = 0, secondArrayLength = secondArray.length; j < secondArrayLength; j++) {
                    result.push($.extend({}, firstArray[i], secondArray[j]))
                }
            }
            return result
        };
        var getDatesByRules = function(dateRules, startDate) {
            var updatedDate = new Date(startDate),
                result = [];
            for (var i = 0, len = dateRules.length; i < len; i++) {
                var current = dateRules[i];
                for (var field in current) {
                    dateSetterMap[field](updatedDate, current[field])
                }
                result.push(new Date(updatedDate))
            }
            if (!result.length) {
                result.push(updatedDate)
            }
            return result
        };
        var checkDateByRule = function(date, rules) {
            var result = false;
            for (var i = 0; i < rules.length; i++) {
                var current = rules[i],
                    currentRuleResult = true;
                for (var field in current) {
                    if (current[field] !== date[dateGetterMap[field]]()) {
                        currentRuleResult = false
                    }
                }
                result = result || currentRuleResult
            }
            return result || !rules.length
        };
        var getRecurrenceString = function(object) {
            if (!object || !object.freq) {
                return
            }
            var result = "";
            for (var field in object) {
                var value = object[field];
                if ("interval" === field && value < 2) {
                    continue
                }
                if ("until" === field) {
                    value = getAsciiStringByDate(value)
                }
                result += field + "=" + value + ";"
            }
            result = result.substring(0, result.length - 1);
            return result.toUpperCase()
        };
        module.exports = {
            getRecurrenceString: getRecurrenceString,
            getRecurrenceRule: getRecurrenceRule,
            getAsciiStringByDate: getAsciiStringByDate,
            getDatesByRecurrence: getDatesByRecurrence,
            dateInRecurrenceRange: dateInRecurrenceRange,
            getDateByAsciiString: getDateByAsciiString,
            daysFromByDayRule: daysFromByDayRule
        }
    },
    /*!*********************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.subscribes.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            array = __webpack_require__( /*! ../../core/utils/array */ 111),
            recurrenceUtils = __webpack_require__( /*! ./utils.recurrence */ 404),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            SchedulerTimezones = __webpack_require__( /*! ./ui.scheduler.timezones */ 406);
        var subscribes = {
            currentViewUpdated: function(currentView) {
                this.option("currentView", currentView)
            },
            currentDateUpdated: function(date) {
                this.option("currentDate", date)
            },
            setCellDataCacheAlias: function(appointment, geometry) {
                this._workSpace.setCellDataCacheAlias(appointment, geometry)
            },
            needCoordinates: function(options) {
                var appointmentData = options.appointmentData,
                    startDate = options.startDate,
                    recurrenceRule = this.fire("getField", "recurrenceRule", appointmentData),
                    recurrenceException = this.fire("getField", "recurrenceException", appointmentData),
                    dateRange = this._workSpace.getDateRange(),
                    startViewDate = this.appointmentTakesAllDay(appointmentData) ? dateUtils.trimTime(new Date(dateRange[0])) : dateRange[0],
                    originalStartDate = options.originalStartDate || startDate;
                var dates = recurrenceUtils.getDatesByRecurrence(recurrenceRule, originalStartDate, startViewDate, dateRange[1], recurrenceException);
                if (!dates.length) {
                    dates.push(startDate)
                }
                var itemResources = this._resourcesManager.getResourcesFromItem(appointmentData),
                    allDay = this.appointmentTakesAllDay(appointmentData) && this._workSpace.supportAllDayRow();
                options.callback(this._getCoordinates(dates, itemResources, allDay))
            },
            showAppointmentTooltip: function(options) {
                options.skipDateCalculation = true;
                var appointmentData = options.data,
                    $appointment = $(options.target),
                    singleAppointmentData = this._getSingleAppointmentData(appointmentData, options, $appointment);
                this.showAppointmentTooltip(appointmentData, singleAppointmentData, options.target)
            },
            hideAppointmentTooltip: function() {
                this._hideTooltip()
            },
            showAddAppointmentPopup: function(appointmentData) {
                var processedData = {};
                $.each(["startDate", "endDate", "allDay"], $.proxy(function(_, field) {
                    if (void 0 !== appointmentData[field]) {
                        this.fire("setField", field, processedData, appointmentData[field]);
                        delete appointmentData[field]
                    }
                }, this));
                this.showAppointmentPopup($.extend(processedData, appointmentData), true)
            },
            showEditAppointmentPopup: function(options) {
                var appointmentData = options.data,
                    $appointment = $(options.target),
                    singleAppointmentData = this._getSingleAppointmentData(appointmentData, options, $appointment, true),
                    startDate = this.fire("getField", "startDate", singleAppointmentData);
                this.showAppointmentPopup(appointmentData, false, singleAppointmentData, startDate)
            },
            updateAppointmentAfterResize: function(options) {
                var targetAppointment = options.target,
                    $appointment = options.$appointment,
                    singleAppointment = this._getSingleAppointmentData(targetAppointment, options, $appointment),
                    startDate = this.fire("getField", "startDate", singleAppointment),
                    updatedData = $.extend(true, {}, options.data);
                var processedStartDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "startDate", updatedData), this.fire("getField", "startDateTimeZone", updatedData));
                var processedEndDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "endDate", updatedData), this.fire("getField", "endDateTimeZone", updatedData));
                this.fire("setField", "startDate", updatedData, processedStartDate);
                this.fire("setField", "endDate", updatedData, processedEndDate);
                this._checkRecurringAppointment(targetAppointment, singleAppointment, startDate, $.proxy(function() {
                    this._updateAppointment(targetAppointment, updatedData, function() {
                        this._appointments.moveAppointmentBack()
                    })
                }, this))
            },
            updateAppointmentAfterDrag: function(options) {
                var target = options.data,
                    updatedData = this._getUpdatedData(options),
                    newCellIndex = this._workSpace.getDroppableCellIndex(),
                    oldCellIndex = this._workSpace.getCellIndexByCoordinates(options.coordinates),
                    becomeAllDay = this.fire("getField", "allDay", updatedData),
                    wasAllDay = this.fire("getField", "allDay", target);
                var appointment = $.extend({}, target, updatedData);
                var movedToAllDay = this._workSpace.supportAllDayRow() && becomeAllDay,
                    cellData = this._workSpace.getCellDataByCoordinates(options.coordinates, movedToAllDay),
                    movedBetweenAllDayAndSimple = this._workSpace.supportAllDayRow() && (wasAllDay && !becomeAllDay || !wasAllDay && becomeAllDay);
                if (newCellIndex !== oldCellIndex || movedBetweenAllDayAndSimple) {
                    this._checkRecurringAppointment(target, appointment, cellData.startDate, $.proxy(function() {
                        var processedStartDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "startDate", updatedData), this.fire("getField", "startDateTimeZone", updatedData));
                        var processedEndDate = this.fire("convertDateByTimezoneBack", this.fire("getField", "endDate", updatedData), this.fire("getField", "endDateTimeZone", updatedData));
                        this.fire("setField", "startDate", appointment, processedStartDate);
                        this.fire("setField", "endDate", appointment, processedEndDate);
                        this._updateAppointment(target, appointment, function() {
                            this._appointments.moveAppointmentBack()
                        })
                    }, this))
                } else {
                    this._appointments.moveAppointmentBack()
                }
            },
            deleteAppointment: function(options) {
                var appointmentData = options.data,
                    $appointment = $(options.target),
                    singleAppointmentData = this._getSingleAppointmentData(appointmentData, options, $appointment),
                    startDate = this.fire("getField", "startDate", singleAppointmentData);
                this._checkRecurringAppointment(appointmentData, singleAppointmentData, startDate, $.proxy(function() {
                    this.deleteAppointment(appointmentData)
                }, this), true)
            },
            getAppointmentColor: function(options) {
                var resourcesManager = this._resourcesManager,
                    resourceForPainting = resourcesManager.getResourceForPainting(this.option("groups")),
                    response = $.Deferred().resolve().promise();
                if (resourceForPainting) {
                    var field = resourcesManager.getField(resourceForPainting),
                        groupIndex = options.groupIndex,
                        groups = this._workSpace._getCellGroups(groupIndex),
                        resourceValues = array.wrapToArray(options.itemData[field]),
                        groupId = resourceValues.length ? resourceValues[0] : void 0;
                    for (var i = 0; i < groups.length; i++) {
                        if (groups[i].name === field) {
                            groupId = groups[i].id;
                            break
                        }
                    }
                    response = resourcesManager.getResourceColor(field, groupId)
                }
                options.callback(response)
            },
            getResourcesFromItem: function(options) {
                options.callback(this._resourcesManager.getResourcesFromItem(options.itemData))
            },
            getCellDimensions: function(options) {
                if (this._workSpace) {
                    options.callback(this._workSpace.getCellWidth(), this._workSpace.getCellHeight(), this._workSpace.getAllDayHeight())
                }
            },
            getBoundOffset: function(options) {
                options.callback({
                    top: -this.getWorkSpaceAllDayHeight()
                })
            },
            appointmentTakesAllDay: function(options) {
                var appointment = {};
                this.fire("setField", "startDate", appointment, options.startDate);
                this.fire("setField", "endDate", appointment, options.endDate);
                options.callback(this.appointmentTakesAllDay(appointment))
            },
            appointmentTakesSeveralDays: function(appointment) {
                return this._appointmentModel.appointmentTakesSeveralDays(appointment)
            },
            checkContainerVisibility: function(options) {
                options.callback(this.element().is(":hidden"))
            },
            appointmentFocused: function() {
                this._workSpace.restoreScrollTop()
            },
            getResizableAppointmentArea: function(options) {
                var area, allDay = options.allDay;
                if (this.option("groups") && this.option("groups").length && (allDay || "month" === this.option("currentView"))) {
                    var groupBounds = this._workSpace.getGroupBounds(options.coordinates);
                    area = {
                        left: groupBounds.left,
                        right: groupBounds.right,
                        top: 0,
                        bottom: 0
                    }
                }
                options.callback(area)
            },
            getDraggableAppointmentArea: function(options) {
                options.callback(this.getWorkSpaceScrollableContainer())
            },
            getDragEventTargetElements: function(options) {
                options.callback(this.element)
            },
            correctAppointmentCoordinates: function(options) {
                var isAllDay = options.allDay,
                    containerSign = options.isFixedContainer ? -1 : 1;
                var scrollTop = !isAllDay ? this.getWorkSpaceScrollableScrollTop() : 0,
                    allDayPanelTopOffset = !isAllDay ? this.getWorkSpaceAllDayHeight() : 0,
                    headerHeight = this.getWorkSpaceHeaderPanelHeight(),
                    scrollLeft = this.getWorkSpaceScrollableScrollLeft(),
                    tableLeftOffset = this.getWorkSpaceDateTableOffset();
                var topOffset = -scrollTop + allDayPanelTopOffset + headerHeight,
                    leftOffset = -scrollLeft - tableLeftOffset;
                options.callback({
                    top: options.coordinates.top + containerSign * topOffset,
                    left: options.coordinates.left + containerSign * leftOffset
                })
            },
            allDayPanelToggled: function() {
                this._appointments.updateDraggablesBoundOffsets()
            },
            normalizeAppointmentDates: function(options) {
                var appointmentData = options.appointmentData,
                    startDate = dateUtils.makeDate(this.fire("getField", "startDate", appointmentData)),
                    endDate = dateUtils.makeDate(this.fire("getField", "endDate", appointmentData));
                this.fire("setField", "startDate", appointmentData, startDate);
                this.fire("setField", "endDate", appointmentData, endDate);
                options.callback(appointmentData)
            },
            formatDates: function(options) {
                var startDate = options.startDate,
                    endDate = options.endDate,
                    formatType = options.formatType;
                var formatTypes = {
                    DATETIME: function() {
                        var dateTimeFormat = "mediumdatemediumtime",
                            startDateString = dateLocalization.format(startDate, dateTimeFormat) + " - ";
                        var endDateString = startDate.getDate() === endDate.getDate() ? dateLocalization.format(endDate, "shorttime") : dateLocalization.format(endDate, dateTimeFormat);
                        return startDateString + endDateString
                    },
                    TIME: function() {
                        return dateLocalization.format(startDate, "shorttime") + " - " + dateLocalization.format(endDate, "shorttime")
                    },
                    DATE: function() {
                        var dateTimeFormat = "d MMMM",
                            startDateString = dateLocalization.format(startDate, dateTimeFormat),
                            isDurationMoreThanDay = endDate.getTime() - startDate.getTime() > 864e5;
                        var endDateString = isDurationMoreThanDay || endDate.getDate() !== startDate.getDate() ? " - " + dateLocalization.format(endDate, dateTimeFormat) : "";
                        return startDateString + endDateString
                    }
                };
                options.callback(formatTypes[formatType]())
            },
            getFullWeekAppointmentWidth: function(options) {
                var groupIndex = options.groupIndex,
                    groupWidth = this._workSpace.getGroupWidth(groupIndex);
                options.callback(groupWidth)
            },
            getMaxAppointmentWidth: function(options) {
                var cellCountToLastViewDate = this._workSpace.getCellCountToLastViewDate(options.date);
                options.callback(cellCountToLastViewDate * this._workSpace.getCellWidth())
            },
            updateAppointmentStartDate: function(options) {
                var updatedStartDate, appointment = options.appointment,
                    firstViewDate = this._workSpace.getStartViewDate(),
                    startDate = new Date(options.startDate);
                if (this.appointmentTakesAllDay(appointment)) {
                    updatedStartDate = dateUtils.normalizeDate(startDate, firstViewDate)
                } else {
                    var startDayHour = this.option("startDayHour");
                    if (startDate.getHours() < startDayHour) {
                        startDate.setHours(startDayHour);
                        startDate.setMinutes(0)
                    }
                    updatedStartDate = dateUtils.normalizeDate(options.startDate, new Date(startDate))
                }
                options.callback(updatedStartDate)
            },
            updateAppointmentEndDate: function(options) {
                var endDate = new Date(options.endDate),
                    updatedEndDate = endDate;
                if (endDate.getHours() >= this.option("endDayHour")) {
                    updatedEndDate.setHours(this.option("endDayHour"));
                    updatedEndDate.setMinutes(0)
                }
                options.callback(updatedEndDate)
            },
            renderDropDownAppointments: function(options) {
                this._dropDownAppointments.render(options, this)
            },
            getGroupCount: function(options) {
                var groupCount = this._workSpace._getGroupCount();
                options.callback(groupCount)
            },
            updateResizableArea: function() {
                var $allResizableElements = this.element().find(".dx-scheduler-appointment.dx-resizable");
                var horizontalResizables = $.grep($allResizableElements, function(el) {
                    var $el = $(el),
                        resizableInst = $el.dxResizable("instance"),
                        area = resizableInst.option("area");
                    return $.inArray(resizableInst.option("handles"), ["right left", "left right"]) > -1 && $.isPlainObject(area)
                });
                $.each(horizontalResizables, $.proxy(function(_, el) {
                    var $el = $(el),
                        position = translator.locate($el),
                        appointmentData = this._appointments._getItemData($el);
                    var area = this._appointments._calculateResizableArea({
                        left: position.left
                    }, appointmentData);
                    $el.dxResizable("instance").option("area", area)
                }, this))
            },
            recurrenceEditorVisibilityChanged: function(options) {
                this.recurrenceEditorVisibilityChanged(options.visible)
            },
            getField: function(field, obj) {
                if (!commonUtils.isDefined(this._dataAccessors.getter[field])) {
                    return
                }
                return this._dataAccessors.getter[field](obj)
            },
            setField: function(field, obj, value) {
                if (!commonUtils.isDefined(this._dataAccessors.setter[field])) {
                    return
                }
                var splittedExprStr = this.option(field + "Expr").split("."),
                    rootField = splittedExprStr[0];
                if (void 0 === obj[rootField] && splittedExprStr.length > 1) {
                    var emptyChain = function(arr) {
                        var result = {},
                            tmp = result,
                            arrLength = arr.length - 1;
                        for (var i = 1; i < arrLength; i++) {
                            tmp = tmp[arr[i]] = {}
                        }
                        return result
                    }(splittedExprStr);
                    obj[rootField] = emptyChain
                }
                this._dataAccessors.setter[field](obj, value);
                return obj
            },
            prerenderFilter: function() {
                var allDay, dateRange = this.getWorkSpace().getDateRange(),
                    resources = this._resourcesManager.getResourcesData();
                if (!this.option("showAllDayPanel") && this._workSpace.supportAllDayRow()) {
                    allDay = false
                }
                return this._appointmentModel.filterLoadedAppointments({
                    startDayHour: this.option("startDayHour"),
                    endDayHour: this.option("endDayHour"),
                    min: dateRange[0],
                    max: dateRange[1],
                    resources: resources,
                    allDay: allDay
                }, this._subscribes.convertDateByTimezone.bind(this))
            },
            dayHasAppointment: function(day, appointment, trimTime) {
                return this.dayHasAppointment(day, appointment, trimTime)
            },
            createResourcesTree: function() {
                return this._resourcesManager.createResourcesTree(this._loadedResources)
            },
            getResourceTreeLeaves: function(tree, appointmentResources) {
                return this._resourcesManager.getResourceTreeLeaves(tree, appointmentResources)
            },
            createReducedResourcesTree: function() {
                var tree = this._resourcesManager.createResourcesTree(this._loadedResources),
                    existingAppointments = this.getAppointmentsInstance().option("items");
                return this._resourcesManager.reduceResourcesTree(tree, existingAppointments)
            },
            groupAppointmentsByResources: function(appointments) {
                var result = {
                    0: appointments
                };
                if (this.option("groups") && this.option("groups").length && this._resourcesManager.getResourcesData().length) {
                    result = this._resourcesManager.groupAppointmentsByResources(appointments, this._loadedResources)
                }
                var totalResourceCount = 0;
                $.each(this._loadedResources, function(i, resource) {
                    if (!i) {
                        totalResourceCount = resource.items.length
                    } else {
                        totalResourceCount *= resource.items.length
                    }
                });
                for (var j = 0; j < totalResourceCount; j++) {
                    var index = j.toString();
                    if (result[index]) {
                        continue
                    }
                    result[index] = []
                }
                return result
            },
            getAgendaRows: function(options) {
                var renderingStrategy = this._appointments._renderingStrategy,
                    calculateRows = $.proxy(renderingStrategy.calculateRows, renderingStrategy),
                    d = $.Deferred();

                function rowsCalculated(appointments) {
                    var result = calculateRows(appointments, options.agendaDuration, options.currentDate);
                    this._dataSourceLoadedCallback.remove(rowsCalculated);
                    d.resolve(result)
                }
                this._dataSourceLoadedCallback.add(rowsCalculated);
                return d.promise()
            },
            getAgendaVerticalStepHeight: function() {
                return this.getWorkSpace().getAgendaVerticalStepHeight()
            },
            getStartViewDate: function() {
                return this.getStartViewDate()
            },
            getEndViewDate: function() {
                return this.getEndViewDate()
            },
            agendaIsReady: function(rows, innerRowOffset, outerRowOffset) {
                var $appts = this.getAppointmentsInstance()._itemElements(),
                    total = 0;
                $appts.css("margin-bottom", innerRowOffset);
                var applyOffset = function(_, count) {
                    var index = count + total - 1;
                    $appts.eq(index).css("margin-bottom", outerRowOffset);
                    total += count
                };
                for (var i = 0; i < rows.length; i++) {
                    $.each(rows[i], applyOffset)
                }
            },
            getTimezone: function() {
                return this._getTimezoneOffsetByOption()
            },
            getClientTimezoneOffset: function() {
                return SchedulerTimezones.getClientTimezoneOffset()
            },
            convertDateByTimezone: function(date, appointmentTimezone) {
                date = new Date(date);
                var clientTzOffset = -(this._subscribes.getClientTimezoneOffset() / 36e5);
                var commonTimezoneOffset = this._getTimezoneOffsetByOption();
                var appointmentTimezoneOffset = this._calculateTimezoneByValue(appointmentTimezone);
                if ("number" !== typeof appointmentTimezoneOffset) {
                    appointmentTimezoneOffset = clientTzOffset
                }
                var dateInUTC = date.getTime() - 36e5 * clientTzOffset;
                date = new Date(dateInUTC + 36e5 * appointmentTimezoneOffset);
                if ("number" === typeof commonTimezoneOffset) {
                    date = new Date(date.getTime() + 36e5 * (commonTimezoneOffset - appointmentTimezoneOffset))
                }
                return date
            },
            convertDateByTimezoneBack: function(date, appointmentTimezone) {
                date = new Date(date);
                var clientTzOffset = -(this._subscribes.getClientTimezoneOffset() / 36e5);
                var commonTimezoneOffset = this._getTimezoneOffsetByOption();
                var appointmentTimezoneOffset = this._calculateTimezoneByValue(appointmentTimezone);
                if ("number" !== typeof appointmentTimezoneOffset) {
                    appointmentTimezoneOffset = clientTzOffset
                }
                var dateInUTC = date.getTime() + 36e5 * clientTzOffset;
                date = new Date(dateInUTC - 36e5 * appointmentTimezoneOffset);
                if ("number" === typeof commonTimezoneOffset) {
                    date = new Date(date.getTime() - 36e5 * (commonTimezoneOffset - appointmentTimezoneOffset))
                }
                return date
            },
            getTimezonesDisplayName: function() {
                return SchedulerTimezones.getTimezonesDisplayName()
            },
            getTimezoneDisplayNameById: function(id) {
                return SchedulerTimezones.getTimezoneDisplayNameById(id)
            },
            getSimilarTimezones: function(id) {
                return SchedulerTimezones.getSimilarTimezones(id)
            },
            getTimezonesIdsByDisplayName: function(displayName) {
                return SchedulerTimezones.getTimezonesIdsByDisplayName(displayName)
            },
            getTargetedAppointmentData: function(appointmentData, appointmentElement, appointmentIndex) {
                var recurringData = this._getSingleAppointmentData(appointmentData, {
                        skipDateCalculation: true
                    }, appointmentElement),
                    result = {};
                $.extend(true, result, appointmentData, recurringData);
                this.setTargetedAppointmentResources(result, appointmentElement, appointmentIndex);
                return result
            }
        };
        module.exports = subscribes
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timezones.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var query = __webpack_require__( /*! ../../data/query */ 158),
            errors = __webpack_require__( /*! ../../core/errors */ 17),
            tzData = __webpack_require__( /*! ./ui.scheduler.timezones_data */ 407);
        var SchedulerTimezones = {
            _displayNames: tzData.displayNames,
            _list: tzData.timezones,
            getTimezones: function() {
                return this._list
            },
            getDisplayNames: function() {
                return this._displayNames
            },
            queryableTimezones: function() {
                return query(this.getTimezones())
            },
            getTimezoneById: function(id) {
                var result, i = 0,
                    tzList = this.getTimezones();
                if (id) {
                    while (!result) {
                        if (!tzList[i]) {
                            errors.log("W0009", id);
                            return
                        }
                        var currentId = tzList[i].id;
                        if (currentId === id) {
                            result = tzList[i]
                        }
                        i++
                    }
                }
                return result
            },
            getTimezoneOffsetById: function(id, dateTimeStamp) {
                var offsets, offsetIndices, untils, result, tz = this.getTimezoneById(id);
                if (tz) {
                    if (tz.link) {
                        var rootTz = this.getTimezones()[tz.link];
                        offsets = rootTz.offsets;
                        untils = rootTz.untils;
                        offsetIndices = rootTz.offsetIndices
                    } else {
                        offsets = tz.offsets;
                        untils = tz.untils;
                        offsetIndices = tz.offsetIndices
                    }
                    result = this.getUtcOffset(offsets, offsetIndices, untils, dateTimeStamp)
                }
                return result
            },
            getUtcOffset: function(offsets, offsetIndices, untils, dateTimeStamp) {
                var index = 0;
                var offsetIndicesList = offsetIndices.split("");
                var untilsList = untils.split("|").map(function(until) {
                    if ("Infinity" === until) {
                        return null
                    }
                    return 1e3 * parseInt(until, 36)
                });
                var currentUntil = 0;
                for (var i = 0, listLength = untilsList.length; i < listLength; i++) {
                    currentUntil += untilsList[i];
                    if (dateTimeStamp >= currentUntil) {
                        index = i;
                        continue
                    } else {
                        break
                    }
                }
                if (untilsList[index + 1]) {
                    index++
                }
                return offsets[Number(offsetIndicesList[index])]
            },
            getTimezoneShortDisplayNameById: function(id) {
                var result, tz = this.getTimezoneById(id);
                if (tz) {
                    result = tz.DisplayName.substring(0, 11)
                }
                return result
            },
            getTimezonesDisplayName: function() {
                return query(this.getDisplayNames()).sortBy().toArray()
            },
            getTimezoneDisplayNameById: function(id) {
                var tz = this.getTimezoneById(id);
                return tz ? this.getDisplayNames()[tz.winIndex] : ""
            },
            getSimilarTimezones: function(id) {
                if (!id) {
                    return []
                }
                var tz = this.getTimezoneById(id);
                return this.getTimezonesIdsByWinIndex(tz.winIndex)
            },
            getTimezonesIdsByWinIndex: function(winIndex) {
                return this.queryableTimezones().filter(["winIndex", winIndex]).sortBy("title").toArray().map(function(item) {
                    return {
                        id: item.id,
                        displayName: item.title
                    }
                })
            },
            getTimezonesIdsByDisplayName: function(displayName) {
                var displayNameIndex = this.getDisplayNames().indexOf(displayName);
                return this.getTimezonesIdsByWinIndex(displayNameIndex)
            },
            getClientTimezoneOffset: function() {
                return 6e4 * (new Date).getTimezoneOffset()
            },
            processDateDependOnTimezone: function(date, tzOffset) {
                var result = new Date(date);
                if (tzOffset) {
                    var tzDiff = tzOffset + this.getClientTimezoneOffset() / 36e5;
                    result = new Date(result.setHours(result.getHours() + tzDiff))
                }
                return result
            }
        };
        module.exports = SchedulerTimezones
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timezones_data.js ***!
      \*************************************************************/
    function(module, exports) {
        var displayNames = ["(UTC) Monrovia, Reykjavik", "(UTC+03:00) Nairobi", "(UTC+02:00) Harare, Pretoria", "(UTC+01:00) West Central Africa", "(UTC+02:00) Athens, Bucharest", "(UTC+03:00) Kuwait, Riyadh", "(UTC+07:00) Bangkok, Hanoi, Jakarta", "(UTC+04:00) Abu Dhabi, Muscat", "(UTC+12:00) Auckland, Wellington", "(UTC-03:00) City of Buenos Aires", "(UTC-05:00) Bogota, Lima, Quito, Rio Branco", "(UTC-08:00) Pacific Time (US & Canada)", "(UTC-05:00) Indiana (East)", "(UTC-06:00) Central Time (US & Canada)", "(UTC-05:00) Eastern Time (US & Canada)", "(UTC-07:00) Mountain Time (US & Canada)", "(UTC-04:00) Georgetown, La Paz, Manaus, San Juan", "(UTC+05:00) Ashgabat, Tashkent", "(UTC+05:30) Chennai, Kolkata, Mumbai, New Delhi", "(UTC+08:00) Beijing, Chongqing, Hong Kong, Urumqi", "(UTC+06:00) Dhaka", "(UTC+06:00) Astana", "(UTC+05:45) Kathmandu", "(UTC+02:00) Jerusalem", "(UTC+08:00) Kuala Lumpur, Singapore", "(UTC+08:00) Ulaanbaatar", "(UTC) Dublin, Edinburgh, Lisbon, London", "(UTC+01:00) Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna", "(UTC+10:00) Canberra, Melbourne, Sydney", "(UTC+09:30) Darwin", "(UTC+10:00) Brisbane", "(UTC+09:30) Adelaide", "(UTC+10:00) Hobart", "(UTC+08:00) Perth", "(UTC-02:00) Coordinated Universal Time-02", "(UTC-03:00) Brasilia", "(UTC-04:00) Atlantic Time (Canada)", "(UTC-06:00) Saskatchewan", "(UTC-03:30) Newfoundland", "(UTC-03:00) Santiago", "(UTC+02:00) Cairo", "UTC", "(UTC+03:30) Tehran", "(UTC+09:00) Osaka, Sapporo, Tokyo", "(UTC+12:00) Coordinated Universal Time+12", "(UTC+02:00) Tripoli", "(UTC-07:00) Chihuahua, La Paz, Mazatlan", "(UTC-06:00) Guadalajara, Mexico City, Monterrey", "(UTC+11:00) Solomon Is., New Caledonia", "(UTC-11:00) Coordinated Universal Time-11", "(UTC+10:00) Guam, Port Moresby", "(UTC+01:00) Sarajevo, Skopje, Warsaw, Zagreb", "(UTC+08:00) Taipei", "(UTC+09:00) Seoul", "(UTC+02:00) Istanbul", "(UTC-09:00) Alaska", "(UTC-07:00) Arizona", "(UTC-10:00) Hawaii", "(UTC+03:00) Moscow, St. Petersburg, Volgograd", "(UTC+02:00) Helsinki, Kyiv, Riga, Sofia, Tallinn, Vilnius", "(UTC+01:00) Belgrade, Bratislava, Budapest, Ljubljana, Prague", "(UTC) Casablanca", "(UTC+01:00) Brussels, Copenhagen, Madrid, Paris", "(UTC+01:00) Windhoek", "(UTC-03:00) Cayenne, Fortaleza", "(UTC-04:00) Asuncion", "(UTC-03:00) Salvador", "(UTC-06:00) Central America", "(UTC-04:00) Cuiaba", "(UTC-04:30) Caracas", "(UTC-03:00) Greenland", "(UTC-03:00) Montevideo", "(UTC-08:00) Baja California", "(UTC-01:00) Azores", "(UTC+02:00) Amman", "(UTC+10:00) Magadan", "(UTC+03:00) Baghdad", "(UTC+04:00) Baku", "(UTC+02:00) Beirut", "(UTC+09:00) Yakutsk", "(UTC+05:30) Sri Jayawardenepura", "(UTC+02:00) Damascus", "(UTC+08:00) Irkutsk", "(UTC+04:30) Kabul", "(UTC+05:00) Islamabad, Karachi", "(UTC+07:00) Krasnoyarsk", "(UTC+06:00) Novosibirsk", "(UTC+06:30) Yangon (Rangoon)", "(UTC+10:00) Vladivostok", "(UTC+04:00) Tbilisi", "(UTC+05:00) Ekaterinburg", "(UTC+04:00) Yerevan", "(UTC-01:00) Cabo Verde Is.", "(UTC-12:00) International Date Line West", "(UTC+13:00) Nuku'alofa", "(UTC+14:00) Kiritimati Island", "(UTC+02:00) Kaliningrad", "(UTC+04:00) Port Louis", "(UTC+13:00) Samoa", "(UTC+12:00) Fiji"];
        var timezones = [{
            id: "Africa/Bamako",
            title: "Bamako",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Banjul",
            title: "Banjul",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Conakry",
            title: "Conakry",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Dakar",
            title: "Dakar",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Freetown",
            title: "Freetown",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Lome",
            title: "Lome",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Nouakchott",
            title: "Nouakchott",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Ouagadougou",
            title: "Ouagadougou",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Sao_Tome",
            title: "Sao Tome",
            winIndex: 0,
            link: 185
        }, {
            id: "Atlantic/St_Helena",
            title: "St Helena",
            winIndex: 0,
            link: 185
        }, {
            id: "Africa/Addis_Ababa",
            title: "Addis Ababa",
            winIndex: 1,
            link: 198
        }, {
            id: "Africa/Asmara",
            title: "Asmara",
            winIndex: 1,
            link: 198
        }, {
            id: "Africa/Dar_es_Salaam",
            title: "Dar es Salaam",
            winIndex: 1,
            link: 198
        }, {
            id: "Africa/Djibouti",
            title: "Djibouti",
            winIndex: 1,
            link: 198
        }, {
            id: "Africa/Kampala",
            title: "Kampala",
            winIndex: 1,
            link: 198
        }, {
            id: "Africa/Mogadishu",
            title: "Mogadishu",
            winIndex: 1,
            link: 198
        }, {
            id: "Indian/Antananarivo",
            title: "Antananarivo",
            winIndex: 1,
            link: 198
        }, {
            id: "Indian/Comoro",
            title: "Comoro",
            winIndex: 1,
            link: 198
        }, {
            id: "Indian/Mayotte",
            title: "Mayotte",
            winIndex: 1,
            link: 198
        }, {
            id: "Africa/Blantyre",
            title: "Blantyre",
            winIndex: 2,
            link: 196
        }, {
            id: "Africa/Bujumbura",
            title: "Bujumbura",
            winIndex: 2,
            link: 196
        }, {
            id: "Africa/Gaborone",
            title: "Gaborone",
            winIndex: 2,
            link: 196
        }, {
            id: "Africa/Harare",
            title: "Harare",
            winIndex: 2,
            link: 196
        }, {
            id: "Africa/Kigali",
            title: "Kigali",
            winIndex: 2,
            link: 196
        }, {
            id: "Africa/Lubumbashi",
            title: "Lubumbashi",
            winIndex: 2,
            link: 196
        }, {
            id: "Africa/Lusaka",
            title: "Lusaka",
            winIndex: 2,
            link: 196
        }, {
            id: "Africa/Bangui",
            title: "Bangui",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Brazzaville",
            title: "Brazzaville",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Douala",
            title: "Douala",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Kinshasa",
            title: "Kinshasa",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Libreville",
            title: "Libreville",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Luanda",
            title: "Luanda",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Malabo",
            title: "Malabo",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Niamey",
            title: "Niamey",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Porto-Novo",
            title: "Porto-Novo",
            winIndex: 3,
            link: 195
        }, {
            id: "Africa/Maseru",
            title: "Maseru",
            winIndex: 2,
            link: 193
        }, {
            id: "Africa/Mbabane",
            title: "Mbabane",
            winIndex: 2,
            link: 193
        }, {
            id: "Africa/Juba",
            title: "Juba",
            winIndex: 1,
            link: 194
        }, {
            id: "Europe/Nicosia",
            title: "Nicosia",
            winIndex: 4,
            link: 381
        }, {
            id: "Asia/Bahrain",
            title: "Bahrain",
            winIndex: 5,
            link: 388
        }, {
            id: "Asia/Aden",
            title: "Aden",
            winIndex: 5,
            link: 391
        }, {
            id: "Asia/Kuwait",
            title: "Kuwait",
            winIndex: 5,
            link: 391
        }, {
            id: "Asia/Phnom_Penh",
            title: "Phnom Penh",
            winIndex: 6,
            link: 349
        }, {
            id: "Asia/Vientiane",
            title: "Vientiane",
            winIndex: 6,
            link: 349
        }, {
            id: "Asia/Muscat",
            title: "Muscat",
            winIndex: 7,
            link: 359
        }, {
            id: "Antarctica/McMurdo",
            title: "McMurdo",
            winIndex: 8,
            link: 511
        }, {
            id: "Africa/Asmera",
            title: "Asmera",
            winIndex: 1,
            link: 198
        }, {
            id: "Africa/Timbuktu",
            title: "Timbuktu",
            winIndex: 0,
            link: 185
        }, {
            id: "America/Buenos_Aires",
            title: "Buenos Aires",
            winIndex: 9,
            link: 206
        }, {
            id: "America/Catamarca",
            title: "Catamarca",
            winIndex: 9,
            link: 207
        }, {
            id: "America/Coral_Harbour",
            title: "Coral Harbour",
            winIndex: 10,
            link: 219
        }, {
            id: "America/Cordoba",
            title: "Cordoba",
            winIndex: 9,
            link: 208
        }, {
            id: "America/Ensenada",
            title: "Ensenada",
            winIndex: 11,
            link: 325
        }, {
            id: "America/Indianapolis",
            title: "Indianapolis",
            winIndex: 12
        }, {
            id: "America/Jujuy",
            title: "Jujuy",
            winIndex: 9,
            link: 209
        }, {
            id: "America/Knox_IN",
            title: "Knox IN",
            winIndex: 13,
            link: 261
        }, {
            id: "America/Louisville",
            title: "Louisville",
            winIndex: 14,
            link: 272
        }, {
            id: "America/Mendoza",
            title: "Mendoza",
            winIndex: 9,
            link: 211
        }, {
            id: "America/Porto_Acre",
            title: "Porto Acre",
            winIndex: 10,
            link: 312
        }, {
            id: "America/Shiprock",
            title: "Shiprock",
            winIndex: 15,
            link: 244
        }, {
            id: "America/Virgin",
            title: "Virgin",
            winIndex: 16,
            link: 303
        }, {
            id: "Antarctica/South_Pole",
            title: "South Pole",
            winIndex: 8,
            link: 511
        }, {
            id: "Asia/Ashkhabad",
            title: "Ashkhabad",
            winIndex: 17,
            link: 346
        }, {
            id: "Asia/Calcutta",
            title: "Calcutta",
            winIndex: 18,
            link: 373
        }, {
            id: "Asia/Chongqing",
            title: "Chongqing",
            winIndex: 19,
            link: 395
        }, {
            id: "Asia/Chungking",
            title: "Chungking",
            winIndex: 19,
            link: 395
        }, {
            id: "Asia/Dacca",
            title: "Dacca",
            winIndex: 20,
            link: 357
        }, {
            id: "Asia/Harbin",
            title: "Harbin",
            winIndex: 19,
            link: 395
        }, {
            id: "Asia/Kashgar",
            title: "Kashgar",
            winIndex: 21,
            link: 405
        }, {
            id: "Asia/Katmandu",
            title: "Katmandu",
            winIndex: 22,
            link: 371
        }, {
            id: "Asia/Macao",
            title: "Macao",
            winIndex: 19,
            link: 377
        }, {
            id: "Asia/Saigon",
            title: "Saigon",
            winIndex: 6,
            link: 361
        }, {
            id: "Asia/Tel_Aviv",
            title: "Tel Aviv",
            winIndex: 23,
            link: 367
        }, {
            id: "Asia/Thimbu",
            title: "Thimbu",
            winIndex: 20,
            link: 402
        }, {
            id: "Asia/Ujung_Pandang",
            title: "Ujung Pandang",
            winIndex: 24,
            link: 379
        }, {
            id: "Asia/Ulan_Bator",
            title: "Ulan Bator",
            winIndex: 25,
            link: 404
        }, {
            id: "Atlantic/Faeroe",
            title: "Faeroe",
            winIndex: 26,
            link: 415
        }, {
            id: "Atlantic/Jan_Mayen",
            title: "Jan Mayen",
            winIndex: 27,
            link: 483
        }, {
            id: "Australia/ACT",
            title: "ACT",
            winIndex: 28,
            link: 429
        }, {
            id: "Australia/Canberra",
            title: "Canberra",
            winIndex: 28,
            link: 429
        }, {
            id: "Australia/NSW",
            title: "NSW",
            winIndex: 28,
            link: 429
        }, {
            id: "Australia/North",
            title: "North",
            winIndex: 29,
            link: 424
        }, {
            id: "Australia/Queensland",
            title: "Queensland",
            winIndex: 30,
            link: 421
        }, {
            id: "Australia/South",
            title: "South",
            winIndex: 31,
            link: 420
        }, {
            id: "Australia/Tasmania",
            title: "Tasmania",
            winIndex: 32,
            link: 425
        }, {
            id: "Australia/Victoria",
            title: "Victoria",
            winIndex: 28,
            link: 427
        }, {
            id: "Australia/West",
            title: "West",
            winIndex: 33,
            link: 428
        }, {
            id: "Australia/Yancowinna",
            title: "Yancowinna",
            winIndex: 31,
            link: 422
        }, {
            id: "Brazil/Acre",
            title: "Acre",
            winIndex: 10,
            link: 312
        }, {
            id: "Brazil/DeNoronha",
            title: "DeNoronha",
            winIndex: 34,
            link: 294
        }, {
            id: "Brazil/East",
            title: "East",
            winIndex: 35,
            link: 317
        }, {
            id: "Brazil/West",
            title: "West",
            winIndex: 16,
            link: 279
        }, {
            id: "Canada/Atlantic",
            title: "Atlantic",
            winIndex: 36,
            link: 257
        }, {
            id: "Canada/Central",
            title: "Central",
            winIndex: 13,
            link: 329
        }, {
            id: "Canada/East-Saskatchewan",
            title: "East-Saskatchewan",
            winIndex: 37,
            link: 310
        }, {
            id: "Canada/Eastern",
            title: "Eastern",
            winIndex: 14,
            link: 326
        }, {
            id: "Canada/Mountain",
            title: "Mountain",
            winIndex: 15,
            link: 246
        }, {
            id: "Canada/Newfoundland",
            title: "Newfoundland",
            winIndex: 38,
            link: 320
        }, {
            id: "Canada/Pacific",
            title: "Pacific",
            winIndex: 11,
            link: 327
        }, {
            id: "Canada/Saskatchewan",
            title: "Saskatchewan",
            winIndex: 37,
            link: 310
        }, {
            id: "Canada/Yukon",
            title: "Yukon",
            winIndex: 11,
            link: 328
        }, {
            id: "Chile/Continental",
            title: "Continental",
            winIndex: 39,
            link: 315
        }, {
            id: "Cuba",
            title: "Cuba",
            winIndex: 14,
            link: 258
        }, {
            id: "Egypt",
            title: "Egypt",
            winIndex: 40,
            link: 189
        }, {
            id: "Eire",
            title: "Eire",
            winIndex: 26,
            link: 469
        }, {
            id: "Europe/Belfast",
            title: "Belfast",
            winIndex: 26,
            link: 476
        }, {
            id: "Europe/Tiraspol",
            title: "Tiraspol",
            winIndex: 4,
            link: 467
        }, {
            id: "GB",
            title: "GB",
            winIndex: 26,
            link: 476
        }, {
            id: "GB-Eire",
            title: "GB-Eire",
            winIndex: 26,
            link: 476
        }, {
            id: "GMT+0",
            title: "GMT+0",
            winIndex: 41,
            link: 150
        }, {
            id: "GMT-0",
            title: "GMT-0",
            winIndex: 41,
            link: 150
        }, {
            id: "GMT0",
            title: "GMT0",
            winIndex: 41,
            link: 150
        }, {
            id: "Greenwich",
            title: "Greenwich",
            winIndex: 41,
            link: 150
        }, {
            id: "Hongkong",
            title: "Hongkong",
            winIndex: 19,
            link: 362
        }, {
            id: "Iceland",
            title: "Iceland",
            winIndex: 0,
            link: 417
        }, {
            id: "Iran",
            title: "Iran",
            winIndex: 42,
            link: 401
        }, {
            id: "Israel",
            title: "Israel",
            winIndex: 23,
            link: 367
        }, {
            id: "Jamaica",
            title: "Jamaica",
            winIndex: 10,
            link: 270
        }, {
            id: "Japan",
            title: "Japan",
            winIndex: 43,
            link: 403
        }, {
            id: "Kwajalein",
            title: "Kwajalein",
            winIndex: 44,
            link: 524
        }, {
            id: "Libya",
            title: "Libya",
            winIndex: 45,
            link: 200
        }, {
            id: "Mexico/BajaNorte",
            title: "BajaNorte",
            winIndex: 11,
            link: 325
        }, {
            id: "Mexico/BajaSur",
            title: "BajaSur",
            winIndex: 46,
            link: 282
        }, {
            id: "Mexico/General",
            title: "General",
            winIndex: 47,
            link: 285
        }, {
            id: "NZ",
            title: "NZ",
            winIndex: 8,
            link: 511
        }, {
            id: "Navajo",
            title: "Navajo",
            winIndex: 15,
            link: 244
        }, {
            id: "PRC",
            title: "PRC",
            winIndex: 19,
            link: 395
        }, {
            id: "Pacific/Ponape",
            title: "Ponape",
            winIndex: 48,
            link: 532
        }, {
            id: "Pacific/Samoa",
            title: "Samoa",
            winIndex: 49,
            link: 530
        }, {
            id: "Pacific/Truk",
            title: "Truk",
            winIndex: 50,
            link: 512
        }, {
            id: "Poland",
            title: "Poland",
            winIndex: 51,
            link: 498
        }, {
            id: "Portugal",
            title: "Portugal",
            winIndex: 26,
            link: 475
        }, {
            id: "ROC",
            title: "ROC",
            winIndex: 52,
            link: 398
        }, {
            id: "ROK",
            title: "ROK",
            winIndex: 53,
            link: 394
        }, {
            id: "Singapore",
            title: "Singapore",
            winIndex: 24,
            link: 396
        }, {
            id: "Turkey",
            title: "Turkey",
            winIndex: 54,
            link: 472
        }, {
            id: "US/Alaska",
            title: "Alaska",
            winIndex: 55,
            link: 203
        }, {
            id: "US/Arizona",
            title: "Arizona",
            winIndex: 56,
            link: 302
        }, {
            id: "US/Central",
            title: "Central",
            winIndex: 13,
            link: 235
        }, {
            id: "US/Eastern",
            title: "Eastern",
            winIndex: 14,
            link: 291
        }, {
            id: "US/Hawaii",
            title: "Hawaii",
            winIndex: 57,
            link: 521
        }, {
            id: "US/Indiana-Starke",
            title: "Indiana-Starke",
            winIndex: 13,
            link: 261
        }, {
            id: "US/Michigan",
            title: "Michigan",
            winIndex: 14,
            link: 245
        }, {
            id: "US/Mountain",
            title: "Mountain",
            winIndex: 15,
            link: 244
        }, {
            id: "US/Pacific",
            title: "Pacific",
            winIndex: 11,
            link: 276
        }, {
            id: "US/Samoa",
            title: "Samoa",
            winIndex: 49,
            link: 530
        }, {
            id: "W-SU",
            title: "W-SU",
            winIndex: 58,
            link: 482
        }, {
            id: "GMT",
            title: "GMT",
            winIndex: 41,
            link: 150
        }, {
            id: "Etc/Greenwich",
            title: "Greenwich",
            winIndex: 41,
            link: 150
        }, {
            id: "Etc/GMT-0",
            title: "GMT-0",
            winIndex: 41,
            link: 150
        }, {
            id: "Etc/GMT+0",
            title: "GMT+0",
            winIndex: 41,
            offsets: [0],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT0",
            title: "GMT0",
            winIndex: 41,
            link: 150
        }, {
            id: "Europe/Jersey",
            title: "Jersey",
            winIndex: 26,
            link: 476
        }, {
            id: "Europe/Guernsey",
            title: "Guernsey",
            winIndex: 26,
            link: 476
        }, {
            id: "Europe/Isle_of_Man",
            title: "Isle of Man",
            winIndex: 26,
            link: 476
        }, {
            id: "Europe/Mariehamn",
            title: "Mariehamn",
            winIndex: 59,
            link: 471
        }, {
            id: "Europe/Busingen",
            title: "Busingen",
            winIndex: 27,
            link: 500
        }, {
            id: "Europe/Vatican",
            title: "Vatican",
            winIndex: 27,
            link: 487
        }, {
            id: "Europe/San_Marino",
            title: "San Marino",
            winIndex: 27,
            link: 487
        }, {
            id: "Europe/Vaduz",
            title: "Vaduz",
            winIndex: 27,
            link: 500
        }, {
            id: "Arctic/Longyearbyen",
            title: "Longyearbyen",
            winIndex: 27,
            link: 483
        }, {
            id: "Europe/Ljubljana",
            title: "Ljubljana",
            winIndex: 60,
            link: 462
        }, {
            id: "Europe/Podgorica",
            title: "Podgorica",
            winIndex: 60,
            link: 462
        }, {
            id: "Europe/Sarajevo",
            title: "Sarajevo",
            winIndex: 60,
            link: 462
        }, {
            id: "Europe/Skopje",
            title: "Skopje",
            winIndex: 60,
            link: 462
        }, {
            id: "Europe/Zagreb",
            title: "Zagreb",
            winIndex: 60,
            link: 462
        }, {
            id: "Europe/Bratislava",
            title: "Bratislava",
            winIndex: 60,
            link: 485
        }, {
            id: "Asia/Istanbul",
            title: "Istanbul",
            winIndex: 54,
            link: 472
        }, {
            id: "Pacific/Johnston",
            title: "Johnston",
            winIndex: 57,
            link: 521
        }, {
            id: "US/Pacific-New",
            title: "Pacific-New",
            winIndex: 11,
            link: 276
        }, {
            id: "America/Aruba",
            title: "Aruba",
            winIndex: 16,
            link: 240
        }, {
            id: "America/Lower_Princes",
            title: "Lower Princes",
            winIndex: 16,
            link: 240
        }, {
            id: "America/Kralendijk",
            title: "Kralendijk",
            winIndex: 16,
            link: 240
        }, {
            id: "America/Anguilla",
            title: "Anguilla",
            winIndex: 16,
            link: 303
        }, {
            id: "America/Dominica",
            title: "Dominica",
            winIndex: 16,
            link: 303
        }, {
            id: "America/Grenada",
            title: "Grenada",
            winIndex: 16,
            link: 303
        }, {
            id: "America/Guadeloupe",
            title: "Guadeloupe",
            winIndex: 16,
            link: 303
        }, {
            id: "America/Marigot",
            title: "Marigot",
            winIndex: 16,
            link: 303
        }, {
            id: "America/Montserrat",
            title: "Montserrat",
            winIndex: 16,
            link: 303
        }, {
            id: "America/St_Barthelemy",
            title: "St Barthelemy",
            winIndex: 16,
            link: 303
        }, {
            id: "America/St_Kitts",
            title: "St Kitts",
            winIndex: 16,
            link: 303
        }, {
            id: "America/St_Lucia",
            title: "St Lucia",
            winIndex: 16,
            link: 303
        }, {
            id: "America/St_Thomas",
            title: "St Thomas",
            winIndex: 16,
            link: 303
        }, {
            id: "America/St_Vincent",
            title: "St Vincent",
            winIndex: 16,
            link: 303
        }, {
            id: "America/Tortola",
            title: "Tortola",
            winIndex: 16,
            link: 303
        }, {
            id: "Africa/Abidjan",
            title: "Abidjan",
            winIndex: 0,
            offsets: [-.2688888888888889, 0],
            offsetIndices: "01",
            untils: "-u9rgl4|Infinity"
        }, {
            id: "Africa/Accra",
            title: "Accra",
            winIndex: 0,
            offsets: [-.014444444444444446, 0, .3333333333333333],
            offsetIndices: "012121212121212121212121212121212121212121212121",
            untils: "-r507yk|1e3pak|681qo|cjvlc|681qo|cjvlc|681qo|cjvlc|681qo|clq9c|681qo|cjvlc|681qo|cjvlc|681qo|cjvlc|681qo|clq9c|681qo|cjvlc|681qo|cjvlc|681qo|cjvlc|681qo|clq9c|681qo|cjvlc|681qo|cjvlc|681qo|cjvlc|681qo|clq9c|681qo|cjvlc|681qo|cjvlc|681qo|cjvlc|681qo|clq9c|681qo|cjvlc|681qo|cjvlc|681qo|Infinity"
        }, {
            id: "Africa/Algiers",
            title: "Algiers",
            winIndex: 3,
            offsets: [.15583333333333332, 0, 1, 2],
            offsetIndices: "0121212121212121232321212122321212",
            untils: "-uozn3l|2qx1nl|5luo0|8y800|a4tc0|7vc00|auqo0|7idc0|b7pc0|6sg00|cyo00|7ayo0|53c00|9idxc0|3i040|51mw0|253uk0|9o2k0|92040|8l3s0|jutc0|4uy840|3rdzw0|46xc00|7x6o0|2xco40|8n180|7x9g0|9d440|kiqg0|9d440|9q2s0|9cyk0|Infinity"
        }, {
            id: "Africa/Bissau",
            title: "Bissau",
            winIndex: 0,
            offsets: [-1.038888888888889, -1, 0],
            offsetIndices: "012",
            untils: "-u9reg4|wvoyk4|Infinity"
        }, {
            id: "Africa/Cairo",
            title: "Cairo",
            winIndex: 40,
            offsets: [2, 3],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-fdls80|40d80|a31g0|7x3w0|a4w40|aqyk0|80ys0|b07w0|7tk40|b07w0|8jhg0|a8fw0|60go40|7el80|awo40|7v980|awqw0|7tk40|b07w0|7tk40|ayd80|7tk40|ayd80|7tk40|ayd80|7tk40|b07w0|7tk40|ayd80|7tk40|ayd80|7ves0|awik0|7ves0|ayd80|7ves0|awik0|7ves0|awik0|7ves0|awik0|7ves0|ayd80|7ves0|awik0|7ves0|awik0|7ves0|awik0|7ves0|ayd80|7ves0|awik0|7ves0|awik0|7ves0|awik0|7ves0|ayd80|7ves0|awik0|7ves0|f9x80|3i040|eluk0|462s0|ayd80|7ves0|awik0|7ves0|awik0|7ves0|awik0|7ves0|ayd80|7ves0|b5rw0|7m5g0|awik0|7ves0|awik0|7ves0|ayd80|7ves0|awik0|7ves0|awik0|7ves0|aqvs0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7k580|b5xg0|6u7w0|bvus0|6h980|c8tg0|64ak0|cyqs0|5anw0|1jms0|12t80|1w22s0|25p80|1sw40|2vmk0|Infinity"
        }, {
            id: "Africa/Casablanca",
            title: "Casablanca",
            winIndex: 61,
            offsets: [-.5055555555555555, 0, 1],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-tblt9g|di7nxg|3huk0|51k40|2znuk0|2dp9g0|776k0|8nt2s0|657w0|3ifxg0|3jp80|va040|4qak0|e1ms0|7pp80|cnms0|3afw0|2xi840|xqqk0|bp56s0|4qak0|e1ms0|45x80|d2g40|51ek0|c8tg0|64ak0|e1sc0|47uo0|1leo0|23xc0|asw00|3lmo0|1qyo0|40g00|7x6o0|4mo00|1stc0|4deo0|7x6o0|3ylc0|1stc0|51hc0|7x6o0|3lmo0|1stc0|5reo0|7k800|2vpc0|25s00|64dc0|7k800|2iqo0|1stc0|6uao0|7x6o0|1stc0|1stc0|779c0|7x6o0|12w00|1stc0|7x6o0|7x6o0|pxc0|1stc0|8n400|9q000|902o0|902o0|9q000|8n400|a2yo0|8a5c0|afxc0|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|afxc0|8a5c0|9q000|Infinity"
        }, {
            id: "Africa/Ceuta",
            title: "Ceuta",
            winIndex: 62,
            offsets: [0, 1, 2],
            offsetIndices: "010101010101010101010121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-qyiys0|7x3w0|2vt440|8so00|st1c0|8n400|9q000|902o0|a2yo0|902o0|k69g40|657w0|3ifxg0|3jp80|va040|4qak0|e1ms0|7pp80|cnms0|3afw0|2xi840|129us0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Africa/El_Aaiun",
            title: "El Aaiun",
            winIndex: 61,
            offsets: [-.88, -1, 0, 1],
            offsetIndices: "01232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-isdxk0|m2g0c0|vek0|4qak0|e1ms0|7pp80|cnms0|3afw0|fke5g0|4qak0|e1ms0|45x80|d2g40|51ek0|c8tg0|64ak0|e1sc0|47uo0|1leo0|23xc0|asw00|3lmo0|1qyo0|40g00|7x6o0|4mo00|1stc0|4deo0|7x6o0|3ylc0|1stc0|51hc0|7x6o0|3lmo0|1stc0|5reo0|7k800|2vpc0|25s00|64dc0|7k800|2iqo0|1stc0|6uao0|7x6o0|1stc0|1stc0|779c0|7x6o0|12w00|1stc0|7x6o0|7x6o0|pxc0|1stc0|8n400|9q000|902o0|902o0|9q000|8n400|a2yo0|8a5c0|afxc0|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|afxc0|8a5c0|9q000|Infinity"
        }, {
            id: "Africa/Johannesburg",
            title: "Johannesburg",
            winIndex: 2,
            offsets: [1.5, 2, 3],
            offsetIndices: "012121",
            untils: "-yvtdi0|kn7o60|9cyk0|9d440|9cyk0|Infinity"
        }, {
            id: "Africa/Khartoum",
            title: "Khartoum",
            winIndex: 1,
            offsets: [2.1688888888888886, 2, 3],
            offsetIndices: "01212121212121212121212121212121212",
            untils: "-kcrsow|kixv4w|8l6k0|a4w40|8n180|a6qs0|8n180|a31g0|8ovw0|a16s0|8qqk0|9zc40|8sl80|9xhg0|8wak0|9ts40|8y580|a4w40|8n180|a31g0|8ovw0|a16s0|8sl80|9xhg0|8ufw0|9vms0|8wak0|9ts40|8y580|a4w40|8ovw0|a16s0|8qqk0|7frw40|Infinity"
        }, {
            id: "Africa/Lagos",
            title: "Lagos",
            winIndex: 3,
            offsets: [.22666666666666666, 1],
            offsetIndices: "01",
            untils: "-q9qbao|Infinity"
        }, {
            id: "Africa/Maputo",
            title: "Maputo",
            winIndex: 2,
            offsets: [2.1722222222222225, 2],
            offsetIndices: "01",
            untils: "-yvtfd8|Infinity"
        }, {
            id: "Africa/Monrovia",
            title: "Monrovia",
            winIndex: 0,
            offsets: [-.7188888888888889, -.7416666666666667, 0],
            offsetIndices: "012",
            untils: "-qj6zc4|rqyyqa|Infinity"
        }, {
            id: "Africa/Nairobi",
            title: "Nairobi",
            winIndex: 1,
            offsets: [2.454444444444445, 3, 2.5, 2.75],
            offsetIndices: "01231",
            untils: "-lnsetg|s8mhg|57v020|afrrb0|Infinity"
        }, {
            id: "Africa/Ndjamena",
            title: "Ndjamena",
            winIndex: 3,
            offsets: [1.0033333333333334, 1, 2],
            offsetIndices: "0121",
            untils: "-u9rk4c|zdk5cc|7iak0|Infinity"
        }, {
            id: "Africa/Tripoli",
            title: "Tripoli",
            winIndex: 45,
            offsets: [.8788888888888889, 1, 2],
            offsetIndices: "012121212121212121212121212122122",
            untils: "-q3gfrw|gl6ajw|422c0|xado0|4bbo0|wrpg0|4s580|1kdpg0|c05bw0|4mqs0|9et80|9d440|9et80|9eys0|9et80|9mdg0|95jw0|9io40|9cyk0|99es0|9et80|9eys0|9et80|9d440|9et80|b2840|3cf3w0|9kis0|9et80|7vqyw0|75eo0|asw00|Infinity"
        }, {
            id: "Africa/Tunis",
            title: "Tunis",
            winIndex: 3,
            offsets: [.15583333333333332, 1, 2],
            offsetIndices: "0121212121212121212121212121212121",
            untils: "-uozn3l|enxevl|b5uo0|53c00|u8w00|7x9g0|c8w80|7k800|z3w0|ew40|8bx80|9d440|9nx00|925o0|8l100|gi3440|7k800|b9k00|7vc00|51mw00|5ytc0|9d1c0|9d1c0|b9k00|7thc0|7m0tc0|7tk40|93us0|b5uo0|7k800|b5uo0|7x6o0|asw00|Infinity"
        }, {
            id: "Africa/Windhoek",
            title: "Windhoek",
            winIndex: 63,
            offsets: [1.5, 2, 3, 1],
            offsetIndices: "012113131313131313131313131313131313131313131313131313131313131313131313131313131313131313131",
            untils: "-yvtdi0|kn7o60|9cyk0|oj2nw0|23tmo0|7xf00|ast80|7x9g0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7x9g0|ast80|7x9g0|Infinity"
        }, {
            id: "America/Anchorage",
            title: "Anchorage",
            winIndex: 55,
            offsets: [-10, -9, -8],
            offsetIndices: "011001010101010101010101010101010111212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-ek1qo0|1tyx80|2e400|b7yik0|12y080|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|1l940|7rs80|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Antigua",
            title: "Antigua",
            winIndex: 16,
            link: 303
        }, {
            id: "America/Araguaina",
            title: "Araguaina",
            winIndex: 64,
            offsets: [-3.2133333333333334, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212121212121",
            untils: "-t85j2o|99k8mo|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|2yl440|64ak0|c8tg0|6u7w0|bxpg0|7iak0|biw40|6u7w0|biw40|7k580|biw40|6u7w0|c8tg0|6h980|dbpg0|5ed80|51udg0|64ak0|Infinity"
        }, {
            id: "America/Argentina/Buenos_Aires",
            title: "Buenos Aires",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212323232323232223232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6u7w0|bvus0|6u7w0|bvus0|776k0|3fidg0|7thc0|430lc0|3yik0|b5xg0|7k580|Infinity"
        }, {
            id: "America/Argentina/Catamarca",
            title: "Catamarca",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212323232313232221232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6u7w0|bvxk0|6u540|bvus0|776k0|3fidg0|7thc0|27s800|z9g0|1u93w0|3yik0|Infinity"
        }, {
            id: "America/Argentina/Cordoba",
            title: "Cordoba",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212323232313232223232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6u7w0|bvxk0|6u540|bvus0|776k0|3fidg0|7thc0|430lc0|3yik0|b5xg0|7k580|Infinity"
        }, {
            id: "America/Argentina/Jujuy",
            title: "Jujuy",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "01212121212121212121212121212121212121212123232312132322232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|c8w80|776k0|ag040|7k2g0|bvus0|776k0|3fidg0|7thc0|430lc0|3yik0|Infinity"
        }, {
            id: "America/Argentina/La_Rioja",
            title: "La Rioja",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "01212121212121212121212121212121212121212123232323123232221232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6qik0|3g880|8jbw0|6u7w0|bvus0|776k0|3fidg0|7thc0|27s800|z9g0|1u93w0|3yik0|Infinity"
        }, {
            id: "America/Argentina/Mendoza",
            title: "Mendoza",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212323231212132221232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bktk0|71mk0|bqas0|73h80|bvus0|773s0|3fidg0|7thc0|27bk00|6hes0|1p7mk0|3yik0|Infinity"
        }, {
            id: "America/Argentina/Rio_Gallegos",
            title: "Rio Gallegos",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212323232323232221232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6u7w0|bvus0|6u7w0|bvus0|776k0|3fidg0|7thc0|27s800|z9g0|1u93w0|3yik0|Infinity"
        }, {
            id: "America/Argentina/Salta",
            title: "Salta",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "01212121212121212121212121212121212121212123232323132322232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6u7w0|bvxk0|6u540|bvus0|776k0|3fidg0|7thc0|430lc0|3yik0|Infinity"
        }, {
            id: "America/Argentina/San_Juan",
            title: "San Juan",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "01212121212121212121212121212121212121212123232323123232221232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6qik0|3g880|8jbw0|6u7w0|bvus0|776k0|3fidg0|7thc0|27qdc0|2txg0|1sgak0|3yik0|Infinity"
        }, {
            id: "America/Argentina/San_Luis",
            title: "San Luis",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "01212121212121212121212121212121212121212123232312122212321212",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|7pp80|b2aw0|71mk0|4qg40|4conw0|7thc0|27qdc0|2txg0|1sgak0|14nw0|2gys0|b5xg0|7k580|b5xg0|Infinity"
        }, {
            id: "America/Argentina/Tucuman",
            title: "Tucuman",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "012121212121212121212121212121212121212121232323231323222123232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6u7w0|bvxk0|6u540|bvus0|776k0|3fidg0|7thc0|27s800|mas0|1um2k0|3yik0|b5xg0|7k580|Infinity"
        }, {
            id: "America/Argentina/Ushuaia",
            title: "Ushuaia",
            winIndex: 9,
            offsets: [-4.28, -4, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212323232323232221232",
            untils: "-px7ys0|5iv8k0|67zw0|a4w40|73h80|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|cls40|66580|cls40|66580|cls40|66580|cls40|67zw0|6a040|hy7w0|6a040|xovw0|3uys0|18nbw0|b0dg0|8ve2k0|3uys0|3yik0|bqas0|71mk0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|7m2qs0|4tzw0|biw40|776k0|bvus0|6u7w0|bvus0|6u7w0|bvus0|776k0|3fidg0|7thc0|27oio0|12ys0|1u93w0|3yik0|Infinity"
        }, {
            id: "America/Asuncion",
            title: "Asuncion",
            winIndex: 65,
            offsets: [-3.844444444444444, -4, -3],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212",
            untils: "-jy93zk|ldwofk|s4vw0|s6w40|7tek0|b0dg0|7rjw0|b0dg0|7rjw0|b0dg0|9cyk0|9eys0|9et80|9eys0|9cyk0|9eys0|9cyk0|9eys0|9cyk0|9eys0|9et80|9eys0|9cyk0|9eys0|9cyk0|9eys0|9cyk0|9eys0|9et80|9eys0|9cyk0|ahus0|8a2k0|9eys0|9cyk0|9o840|7k580|b7s40|93p80|9gtg0|7nuk0|b42s0|7lzw0|b5xg0|7tek0|b9ms0|776k0|biw40|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|9cyk0|7kas0|b5rw0|7x9g0|ast80|a31g0|7k580|b5xg0|7k580|b5xg0|7k580|biw40|776k0|biw40|776k0|biw40|8zzw0|905g0|9px80|905g0|9px80|9d440|8n180|a31g0|8n180|a31g0|8n180|a31g0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|a31g0|8n180|a31g0|8n180|a31g0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|a31g0|8n180|a31g0|8n180|a31g0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|a31g0|8n180|a31g0|8n180|a31g0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|a31g0|8n180|a31g0|8n180|a31g0|Infinity"
        }, {
            id: "America/Atikokan",
            title: "Atikokan",
            winIndex: 10,
            offsets: [-6, -5],
            offsetIndices: "0101111",
            untils: "-qzov40|a2vw0|bfxjw0|pmdk0|1tz8c0|2dsw0|Infinity"
        }, {
            id: "America/Bahia",
            title: "Bahia",
            winIndex: 66,
            offsets: [-2.5677777777777777, -3, -2],
            offsetIndices: "01212121212121212121212121212121212121212121212121212121212121",
            untils: "-t85kv8|99kaf8|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|cyqs0|64ak0|cls40|5rbw0|dbpg0|51ek0|dbpg0|6h980|c8tg0|6h980|c8tg0|64ak0|c8tg0|6u7w0|bxpg0|7iak0|biw40|6u7w0|biw40|7k580|biw40|6u7w0|c8tg0|6h980|dbpg0|5ed80|4irc40|6u7w0|Infinity"
        }, {
            id: "America/Bahia_Banderas",
            title: "Bahia Banderas",
            winIndex: 47,
            offsets: [-7.016666666666667, -7, -6, -8, -5],
            offsetIndices: "0121212131212121212121212121212121212142424242424242424242424242424242424242424242424242424242",
            untils: "-p1u4k0|2u7jw0|1sgdc0|8n400|7thc0|9eys0|591h80|3ie2s0|axvpg0|dpgw40|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|asqg0|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|Infinity"
        }, {
            id: "America/Barbados",
            title: "Barbados",
            winIndex: 16,
            offsets: [-3.974722222222222, -4, -3],
            offsetIndices: "00121212121",
            untils: "-o0aiaj|46b400|npv1mj|5rbw0|a31g0|8n180|a31g0|8n180|ag040|84ik0|Infinity"
        }, {
            id: "America/Belem",
            title: "Belem",
            winIndex: 64,
            offsets: [-3.232222222222222, -3, -2],
            offsetIndices: "012121212121212121212121212121",
            untils: "-t85j0s|99k8ks|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|Infinity"
        }, {
            id: "America/Belize",
            title: "Belize",
            winIndex: 67,
            offsets: [-5.88, -6, -5.5, -5],
            offsetIndices: "01212121212121212121212121212121212121212121212121213131",
            untils: "-u52ic0|3edkc0|6ham0|c8s20|6u9a0|bvte0|6u9a0|bvte0|6u9a0|c8s20|6ham0|c8s20|6ham0|c8s20|6u9a0|bvte0|6u9a0|bvte0|6u9a0|bvte0|6u9a0|c8s20|6ham0|c8s20|6ham0|c8s20|6u9a0|bvte0|6u9a0|bvte0|6u9a0|c8s20|6ham0|c8s20|6ham0|c8s20|6ham0|c8s20|6u9a0|bvte0|6u9a0|bvte0|6u9a0|c8s20|6ham0|c8s20|6ham0|c8s20|6u9a0|bvte0|6u9a0|g2t2q0|3e580|4mcys0|2vmk0|Infinity"
        }, {
            id: "America/Blanc-Sablon",
            title: "Blanc-Sablon",
            winIndex: 16,
            offsets: [-4, -3],
            offsetIndices: "010110",
            untils: "-qzp0o0|a2vw0|c5jxg0|1tzdw0|2dnc0|Infinity"
        }, {
            id: "America/Boa_Vista",
            title: "Boa Vista",
            winIndex: 16,
            offsets: [-4.044444444444444, -4, -3],
            offsetIndices: "0121212121212121212121212121212121",
            untils: "-t85grk|99k93k|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|62xk40|7k580|biw40|cvw0|Infinity"
        }, {
            id: "America/Bogota",
            title: "Bogota",
            winIndex: 10,
            offsets: [-4.937777777777778, -5, -4],
            offsetIndices: "0121",
            untils: "-srdoy8|14f1hi8|ha580|Infinity"
        }, {
            id: "America/Boise",
            title: "Boise",
            winIndex: 15,
            offsets: [-8, -7, -6],
            offsetIndices: "0101012212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0emw0|ast80|7x9g0|ast80|1um840|9s7jw0|1tz5k0|2dvo0|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|51k40|doik0|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Cambridge_Bay",
            title: "Cambridge Bay",
            winIndex: 15,
            offsets: [0, -7, -6, -5],
            offsetIndices: "0122131212121212121212121212121212121212121212233221212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-q3gdc0|bjeec0|1tz5k0|2dvo0|a7n3w0|9q000|7k85k0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x6o0|ast80|ct40|7kj40|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Campo_Grande",
            title: "Campo Grande",
            winIndex: 68,
            offsets: [-3.641111111111111, -4, -3],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212",
            untils: "-t85hvw|99ka7w|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|cyqs0|64ak0|cls40|5rbw0|dbpg0|51ek0|dbpg0|6h980|c8tg0|6h980|c8tg0|64ak0|c8tg0|6u7w0|bxpg0|7iak0|biw40|6u7w0|biw40|7k580|biw40|6u7w0|c8tg0|6h980|dbpg0|5ed80|cls40|64ak0|dfes0|5nmk0|c8tg0|6h980|dbpg0|5rbw0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6u7w0|c8tg0|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6h980|c8tg0|6h980|cls40|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6u7w0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6h980|c8tg0|6h980|cls40|64ak0|cls40|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6u7w0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|Infinity"
        }, {
            id: "America/Cancun",
            title: "Cancun",
            winIndex: 47,
            offsets: [-5.7844444444444445, -6, -5, -4],
            offsetIndices: "0123232321212121212121212121212121212121212",
            untils: "-p1u7c0|vauo00|7ggw40|afuk0|8a840|afuk0|8a840|64ak0|4bms0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|51k40|Infinity"
        }, {
            id: "America/Caracas",
            title: "Caracas",
            winIndex: 69,
            offsets: [-4.461111111111111, -4.5, -4],
            offsetIndices: "01212",
            untils: "-u7lcxw|rlo83w|meoxm0|4dps00|Infinity"
        }, {
            id: "America/Cayenne",
            title: "Cayenne",
            winIndex: 64,
            offsets: [-3.488888888888889, -4, -3],
            offsetIndices: "012",
            untils: "-uj7yb4|tcw6r4|Infinity"
        }, {
            id: "America/Cayman",
            title: "Cayman",
            winIndex: 10,
            link: 299
        }, {
            id: "America/Chicago",
            title: "Chicago",
            winIndex: 13,
            offsets: [-6, -5],
            offsetIndices: "01010101010101010101010101010101010101010101010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0esg0|ast80|7x9g0|ast80|bvus0|776k0|7kas0|b5rw0|9d440|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|7x9g0|dbjw0|8a840|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|6w840|1tz8c0|2dsw0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Chihuahua",
            title: "Chihuahua",
            winIndex: 46,
            offsets: [-7.072222222222222, -7, -6, -5],
            offsetIndices: "0121212323221212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-p1u4k0|2u7jw0|1sgdc0|8n400|7thc0|9eys0|xes2s0|afuk0|8a840|afuk0|8aaw0|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|Infinity"
        }, {
            id: "America/Costa_Rica",
            title: "Costa Rica",
            winIndex: 67,
            offsets: [-5.60361111111111, -6, -5],
            offsetIndices: "0121212121",
            untils: "-pjw8fn|ubtl3n|51ek0|doo40|51ek0|5jso40|8drw0|acas0|2xh80|Infinity"
        }, {
            id: "America/Creston",
            title: "Creston",
            winIndex: 56,
            offsets: [-7, -8],
            offsetIndices: "010",
            untils: "-rshz80|vbus0|Infinity"
        }, {
            id: "America/Cuiaba",
            title: "Cuiaba",
            winIndex: 68,
            offsets: [-3.738888888888889, -4, -3],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212",
            untils: "-t85hm4|99k9y4|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|cyqs0|64ak0|cls40|5rbw0|dbpg0|51ek0|dbpg0|6h980|c8tg0|6h980|c8tg0|64ak0|c8tg0|6u7w0|bxpg0|7iak0|biw40|6u7w0|biw40|7k580|biw40|6u7w0|c8tg0|6h980|dbpg0|5ed80|w5hg0|5nmk0|c8tg0|6h980|dbpg0|5rbw0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6u7w0|c8tg0|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6h980|c8tg0|6h980|cls40|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6u7w0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6h980|c8tg0|6h980|cls40|64ak0|cls40|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6u7w0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|Infinity"
        }, {
            id: "America/Curacao",
            title: "Curacao",
            winIndex: 16,
            offsets: [-4.59638888888889, -4.5, -4],
            offsetIndices: "012",
            untils: "-u7lckd|rlo7qd|Infinity"
        }, {
            id: "America/Danmarkshavn",
            title: "Danmarkshavn",
            winIndex: 41,
            offsets: [-1.2444444444444445, -3, -2, 0],
            offsetIndices: "01212121212121212121212121212121213",
            untils: "-rvusjk|x8nx3k|8zrk0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|53hk0|Infinity"
        }, {
            id: "America/Dawson",
            title: "Dawson",
            winIndex: 11,
            offsets: [-9, -8, -7],
            offsetIndices: "0101011020121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-qzoms0|a2vw0|asys0|882c0|bmiwc0|1tz000|2e180|a7n3w0|9q000|465k00|3e2is0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Dawson_Creek",
            title: "Dawson Creek",
            winIndex: 56,
            offsets: [-8, -7],
            offsetIndices: "0101101010101010101010101010101010101010101010101010101011",
            untils: "-qzopk0|a2vw0|c5jxg0|1tz2s0|2dyg0|tj1g0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|69uk0|Infinity"
        }, {
            id: "America/Denver",
            title: "Denver",
            winIndex: 15,
            offsets: [-7, -6],
            offsetIndices: "01010101011010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0epo0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|2vmk0|ataw40|1tz5k0|2dvo0|a7n9g0|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Detroit",
            title: "Detroit",
            winIndex: 14,
            offsets: [-5.536388888888889, -6, -5, -4],
            offsetIndices: "01233232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-xx8dyd|5eraud|dyeyk0|1tzb40|2dq40|1c9440|7x3w0|9rlhg0|71mk0|2vcg40|9cyk0|3lpg0|f4d80|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Edmonton",
            title: "Edmonton",
            winIndex: 15,
            offsets: [-7.564444444444445, -7, -6],
            offsetIndices: "01212121212121221212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-x1yazk|629ink|a2vw0|8n6s0|29ek0|h6lg0|9px80|905g0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|9l0g40|1tz5k0|2dvo0|tj1g0|7x3w0|a80840|9cyk0|s36s0|9cyk0|1b6840|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Eirunepe",
            title: "Eirunepe",
            winIndex: 10,
            offsets: [-4.657777777777778, -5, -4],
            offsetIndices: "0121212121212121212121212121212121",
            untils: "-t85f28|99ka68|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|2yy2s0|6h980|7hg2s0|2t2t80|Infinity"
        }, {
            id: "America/El_Salvador",
            title: "El Salvador",
            winIndex: 67,
            offsets: [-5.946666666666667, -6, -5],
            offsetIndices: "012121",
            untils: "-pkm4tc|ymao5c|7k580|b5xg0|7k580|Infinity"
        }, {
            id: "America/Fortaleza",
            title: "Fortaleza",
            winIndex: 64,
            offsets: [-2.566666666666667, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121",
            untils: "-t85kvc|99kafc|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|514g40|7k580|biw40|puk0|id6s0|6h980|Infinity"
        }, {
            id: "America/Glace_Bay",
            title: "Glace Bay",
            winIndex: 36,
            offsets: [-3.996666666666667, -4, -3],
            offsetIndices: "012122121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-z94kwc|89fk8c|a2vw0|c5jxg0|1tzdw0|2dnc0|3y8g40|7x3w0|9pa5g0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Godthab",
            title: "Godthab",
            winIndex: 70,
            offsets: [-3.448888888888889, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-rvumf4|x8nqz4|8zrk0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "America/Goose_Bay",
            title: "Goose Bay",
            winIndex: 36,
            offsets: [-3.5144444444444445, -2.5144444444444445, -3.5, -2.5, -4, -3, -2],
            offsetIndices: "010232323232323233232323232323232323232323232323232323232324545454545454545454545454545454545454545454546454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454",
            untils: "-qzp20k|a2vw0|8kjbw0|kzjyk|7k580|b5xg0|7k580|b5xg0|7k580|biw40|776k0|biw40|7k580|b5xg0|7k580|b5xg0|1pb260|2dly0|biw40|7k580|b5xg0|7k580|b5xg0|7k580|b5xg0|7k580|biw40|7k580|ag040|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|6y2s0|22420|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a2lo|afuk0|8a840|asqg0|7xc80|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8tec|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Grand_Turk",
            title: "Grand Turk",
            winIndex: 16,
            offsets: [-5.119722222222222, -5, -4],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212122",
            untils: "-u85og1|z3brw1|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Guatemala",
            title: "Guatemala",
            winIndex: 67,
            offsets: [-6.0344444444444445, -6, -5],
            offsetIndices: "0121212121",
            untils: "-qqqskk|ss0akk|4ofw0|4tidg0|6djw0|3wwas0|8n180|7n5ms0|7x3w0|Infinity"
        }, {
            id: "America/Guayaquil",
            title: "Guayaquil",
            winIndex: 10,
            offsets: [-5.233333333333333, -5],
            offsetIndices: "01",
            untils: "-kcr84o|Infinity"
        }, {
            id: "America/Guyana",
            title: "Guyana",
            winIndex: 16,
            offsets: [-3.8777777777777778, -3.75, -3, -4],
            offsetIndices: "01123",
            untils: "-smcak8|qqnjn8|4sh9c0|81rf90|Infinity"
        }, {
            id: "America/Halifax",
            title: "Halifax",
            winIndex: 36,
            offsets: [-4.24, -4, -3],
            offsetIndices: "0121212121212121212121212121212121212121212121212122121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-z94k80|777go0|9et80|st9o0|a2vw0|ssyk0|5rbw0|cv1g0|69uk0|c6ys0|6kyk0|ci2s0|67zw0|ci2s0|6w2k0|bu040|7lzw0|bu040|66580|bu040|7lzw0|bu040|64ak0|cls40|5v180|cv1g0|6j3w0|c6ys0|79180|b42s0|7lzw0|b42s0|7yyk0|bu040|64ak0|dbpg0|66580|cls40|5ed80|bu040|7lzw0|b42s0|7lzw0|cjxg0|66580|bh1g0|7lzw0|b42s0|7lzw0|6uj00|1tzdw0|2dnc0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|tw040|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|tw040|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|1cm2s0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Havana",
            title: "Havana",
            winIndex: 14,
            offsets: [-5.493333333333334, -5, -4],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-n7762o|1icfyo|69uk0|62s040|4ofw0|e1ms0|51ek0|e1ms0|4ofw0|1fhs40|4ofw0|e1ms0|4ofw0|9s9k40|67zw0|cedg0|6h980|9o840|7yyk0|b5xg0|7k580|bvus0|9cyk0|9d440|9cyk0|9d440|9px80|9d440|8a2k0|ag040|8bx80|ae5g0|8drw0|acas0|9cyk0|9d440|9px80|905g0|9px80|9q2s0|7x3w0|8a840|ast80|7x9g0|ast80|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|8a2k0|ag040|8a2k0|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|905g0|a2vw0|905g0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9d1c0|9d1c0|9q000|8n400|asw00|7x6o0|b5uo0|7x6o0|asw00|7x6o0|asw00|8a5c0|afxc0|8a5c0|afxc0|7x6o0|1cm000|6uao0|bvs00|779c0|bitc0|6uao0|bvs00|779c0|bvs00|779c0|c8qo0|779c0|b5uo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|Infinity"
        }, {
            id: "America/Hermosillo",
            title: "Hermosillo",
            winIndex: 56,
            offsets: [-7.397777777777778, -7, -6, -8],
            offsetIndices: "0121212131212121",
            untils: "-p1u4k0|2u7jw0|1sgdc0|8n400|7thc0|9eys0|591h80|3ie2s0|axvpg0|dpgw40|afuk0|8a840|afuk0|8a840|afuk0|Infinity"
        }, {
            id: "America/Indiana/Indianapolis",
            title: "Indianapolis",
            winIndex: 12
        }, {
            id: "America/Indiana/Knox",
            title: "Knox",
            winIndex: 13,
            offsets: [-6, -5],
            offsetIndices: "0101011010101010101010101010101010101010101010101010101010101010101010101010101010101010111010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|tj1g0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|9cyk0|9d440|7x3w0|asys0|7x3w0|asys0|9cyk0|9d440|9px80|9d440|9cyk0|9d440|s3180|1twas0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|7j5400|asw00|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Indiana/Marengo",
            title: "Marengo",
            winIndex: 12,
            offsets: [-6, -5, -4],
            offsetIndices: "0101011010101010101010101212121212111212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|2wsas0|7x3w0|1c9440|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|465h80|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4g00|64dc0|clmk0|fvt9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Indiana/Petersburg",
            title: "Petersburg",
            winIndex: 14,
            offsets: [-6, -5, -4],
            offsetIndices: "01010110101010101010101010101010101010101010101010111011212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|501ek0|7kas0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|sfzw0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|eu02o0|asw00|6udg0|c8nw0|6hc00|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Indiana/Tell_City",
            title: "Tell City",
            winIndex: 13,
            offsets: [-6, -5, -4],
            offsetIndices: "01010110101010101010101010101010121211010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|asys0|7x3w0|3fidg0|7x3w0|asys0|7x3w0|b5rw0|7kas0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|7k580|b5xg0|9cyk0|9d440|9cyk0|9d440|2lz980|9cyk0|9d440|9cyk0|ihslg0|asw00|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Indiana/Vevay",
            title: "Vevay",
            winIndex: 12,
            offsets: [-6, -5, -4],
            offsetIndices: "010101101212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|4gyis0|7txx80|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|hfzhg0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Indiana/Vincennes",
            title: "Vincennes",
            winIndex: 14,
            offsets: [-6, -5, -4],
            offsetIndices: "01010110101010101010101010101010121211011212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|asys0|7x3w0|3fidg0|7x3w0|asys0|7x3w0|b5rw0|7kas0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|7k580|b5xg0|9cyk0|9d440|9cyk0|9d440|2lz980|9cyk0|9d440|9cyk0|ihslg0|asw00|6udg0|c8nw0|6hc00|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Indiana/Winamac",
            title: "Winamac",
            winIndex: 14,
            offsets: [-6, -5, -4],
            offsetIndices: "01010110101010101010101010101010101010121211021212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|9cyk0|9d440|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|465h80|9cyk0|9d440|9cyk0|ihslg0|asw00|6udg0|c8l40|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Inuvik",
            title: "Inuvik",
            winIndex: 15,
            offsets: [0, -8, -6, -7],
            offsetIndices: "0121323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323",
            untils: "-8ve5c0|6fce80|9q000|71i2w0|ipzw0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Iqaluit",
            title: "Iqaluit",
            winIndex: 14,
            offsets: [0, -4, -5, -3, -6],
            offsetIndices: "01123212121212121212121212121212121212121212142212121212121212121212121212121212121212121212121212121212121212121212121212",
            untils: "-eb6ao0|1l3h80|2dq40|a7n3w0|9q000|7k85k0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7xc80|ast80|7x6o0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Jamaica",
            title: "Jamaica",
            winIndex: 10,
            offsets: [-5.119722222222222, -5, -4],
            offsetIndices: "0121212121212121212121",
            untils: "-u85og1|wbl181|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|Infinity"
        }, {
            id: "America/Juneau",
            title: "Juneau",
            winIndex: 55,
            offsets: [-8, -7, -9],
            offsetIndices: "01101010101010101010101010001010122020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202",
            untils: "-ek1w80|1tz2s0|2dyg0|cawis0|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9d1c0|9d1c0|9cyk0|9d440|9px80|905g0|9px80|1leo0|7rs80|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Kentucky/Louisville",
            title: "Louisville",
            winIndex: 14,
            offsets: [-6, -5, -4],
            offsetIndices: "0101010101101010101010101010101010101121212121212111212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0esg0|ast80|7x9g0|ast80|sg5g0|6bp80|a98o40|7x3w0|6w840|1tz8c0|2dsw0|4s580|7tk40|gxc40|1s3bw0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|4bh80|3j3xc0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4g00|64dc0|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Kentucky/Monticello",
            title: "Monticello",
            winIndex: 14,
            offsets: [-6, -5, -4],
            offsetIndices: "0101011010101010101010101010101010101010101010101010101010101010101010101121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|bs6g40|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x6o0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/La_Paz",
            title: "La Paz",
            winIndex: 16,
            offsets: [-4.543333333333334, -3.5433333333333334, -4],
            offsetIndices: "012",
            untils: "-jxzspo|84ik0|Infinity"
        }, {
            id: "America/Lima",
            title: "Lima",
            winIndex: 10,
            offsets: [-5.1433333333333335, -5, -4],
            offsetIndices: "0121212121212121",
            untils: "-w25lpo|fcxjlo|4ml80|93us0|9cyk0|9d440|9cyk0|nw16s0|4ml80|e5c40|4ml80|1fr1g0|4ml80|1yiys0|4ml80|Infinity"
        }, {
            id: "America/Los_Angeles",
            title: "Los Angeles",
            winIndex: 11,
            offsets: [-8, -7],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0emw0|ast80|7x9g0|ast80|bmtus0|1tz2s0|2dyg0|1a3c40|f2ik0|owdg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Maceio",
            title: "Maceio",
            winIndex: 64,
            offsets: [-2.381111111111111, -3, -2],
            offsetIndices: "012121212121212121212121212121212121212121",
            untils: "-t85ldw|99kaxw|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|2yl440|64ak0|1wf1g0|7k580|biw40|puk0|id6s0|6h980|Infinity"
        }, {
            id: "America/Managua",
            title: "Managua",
            winIndex: 67,
            offsets: [-5.753333333333333, -6, -5],
            offsetIndices: "0121212121212121",
            untils: "-ijh6oo|ka1i0o|xqqk0|24p6s0|53980|dmtg0|53980|60itw0|dq240|53es0|235h80|4beis0|8zzw0|at4c0|7x140|Infinity"
        }, {
            id: "America/Manaus",
            title: "Manaus",
            winIndex: 16,
            offsets: [-4.001111111111111, -4, -3],
            offsetIndices: "01212121212121212121212121212121",
            untils: "-t85gvw|99k97w|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|2yy2s0|6h980|Infinity"
        }, {
            id: "America/Martinique",
            title: "Martinique",
            winIndex: 16,
            offsets: [-4.072222222222222, -4, -3],
            offsetIndices: "0121",
            untils: "-umcvcs|zz5x4s|8zzw0|Infinity"
        }, {
            id: "America/Matamoros",
            title: "Matamoros",
            winIndex: 13,
            offsets: [-6.666666666666667, -6, -5],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-p1u7c0|ykt480|ast80|3vppg0|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|77c40|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Mazatlan",
            title: "Mazatlan",
            winIndex: 46,
            offsets: [-7.094444444444445, -7, -6, -8],
            offsetIndices: "0121212131212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-p1u4k0|2u7jw0|1sgdc0|8n400|7thc0|9eys0|591h80|3ie2s0|axvpg0|dpgw40|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|Infinity"
        }, {
            id: "America/Menominee",
            title: "Menominee",
            winIndex: 13,
            offsets: [-6, -5],
            offsetIndices: "01010110101011010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|asys0|7x3w0|a7n9g0|9px80|1at9g0|2396k0|9d1c0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Merida",
            title: "Merida",
            winIndex: 47,
            offsets: [-5.974444444444444, -6, -5],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-p1u7c0|vauo00|hoyk0|6ys0c0|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|Infinity"
        }, {
            id: "America/Mexico_City",
            title: "Mexico City",
            winIndex: 47,
            offsets: [-6.61, -7, -6, -5],
            offsetIndices: "012121232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-p1u4k0|2u7jw0|1sgdc0|8n400|7thc0|9eys0|3knek0|776k0|rf440|5t6k0|1evk40|71mk0|30p1g0|8n180|nufxo0|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|Infinity"
        }, {
            id: "America/Moncton",
            title: "Moncton",
            winIndex: 36,
            offsets: [-5, -4, -3],
            offsetIndices: "012121212121212121212122121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-z94i40|89fhg0|a2vw0|7mqqo0|4ofw0|e1ms0|4ofw0|e1ms0|4ofw0|e1ms0|4ofw0|e1ms0|4ofw0|e1ms0|4ofw0|dmtg0|64ak0|cao40|6fek0|bkqs0|7iak0|6y5k0|1tzdw0|2dnc0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|s36s0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a2lo|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6uiyc|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Monterrey",
            title: "Monterrey",
            winIndex: 47,
            offsets: [-6.687777777777778, -6, -5],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-p1u7c0|ykt480|ast80|3vppg0|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|Infinity"
        }, {
            id: "America/Montevideo",
            title: "Montevideo",
            winIndex: 71,
            offsets: [-3.7455555555555553, -3.5, -3, -2, -2.5],
            offsetIndices: "012121212121212121212121213232323232324242423243232323232323232323232323232323232323232",
            untils: "-px809g|1s8xzg|9czy0|9exe0|9czy0|9exe0|9czy0|3ydyq0|7x5a0|asxe0|7x5a0|asxe0|7x5a0|b5w20|7k6m0|b5w20|7k6m0|b5w20|7k6m0|b5w20|7x5a0|asxe0|7x5a0|6do20|7vam0|humq0|4mju0|8g9s40|8zzw0|38qs0|2inw0|2nf9g0|8zzw0|9q2s0|aunw0|7ves0|awik0|ar440|9pym0|91yq0|9pym0|91yq0|9pym0|q6mq0|5t6k0|tfc40|erfy0|xdta0|m2is0|62fw0|s6w40|ayd80|3z5s40|4ofw0|dzs40|4ofw0|bvus0|6h980|bvus0|6u7w0|c8tg0|6h980|bvus0|6u7w0|614qs0|9q2s0|a31g0|7x3w0|ag040|8a2k0|asys0|7x3w0|asys0|7x3w0|asys0|8a2k0|ag040|8a2k0|ag040|8a2k0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|Infinity"
        }, {
            id: "America/Montreal",
            title: "Montreal",
            winIndex: 14,
            link: 326
        }, {
            id: "America/Nassau",
            title: "Nassau",
            winIndex: 14,
            offsets: [-5.158333333333333, -5, -4],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-u6m4c6|r7u7s6|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/New_York",
            title: "New York",
            winIndex: 14,
            offsets: [-5, -4],
            offsetIndices: "01010101010101010101010101010101010101010101010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0ev80|ast80|7x9g0|ast80|7x9g0|b5rw0|905g0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|6w840|1tzb40|2dq40|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Nipigon",
            title: "Nipigon",
            winIndex: 14,
            offsets: [-5, -4],
            offsetIndices: "010111010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-qzoxw0|a2vw0|bfxjw0|pmdk0|1tzb40|2dq40|ewvus0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Nome",
            title: "Nome",
            winIndex: 55,
            offsets: [-11, -10, -9, -8],
            offsetIndices: "011001010101010101010101010101010122323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-ek1nw0|1tyug0|2e6s0|b7yik0|12y080|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|1l6c0|7rs80|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Noronha",
            title: "Noronha",
            winIndex: 34,
            offsets: [-2.161111111111111, -2, -1],
            offsetIndices: "0121212121212121212121212121212121212121",
            untils: "-t85lzw|99k8rw|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|514g40|7k580|biw40|cvw0|iq5g0|6h980|Infinity"
        }, {
            id: "America/North_Dakota/Beulah",
            title: "Beulah",
            winIndex: 13,
            offsets: [-7, -6, -5],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101011212121212121212121212121212121212121212121212121212121",
            untils: "-r0epo0|ast80|7x9g0|ast80|bmtus0|1tz5k0|2dvo0|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hc00|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/North_Dakota/Center",
            title: "Center",
            winIndex: 13,
            offsets: [-7, -6, -5],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101011212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0epo0|ast80|7x9g0|ast80|bmtus0|1tz5k0|2dvo0|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a5c0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/North_Dakota/New_Salem",
            title: "New Salem",
            winIndex: 13,
            offsets: [-7, -6, -5],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101010101010101010101010101121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r0epo0|ast80|7x9g0|ast80|bmtus0|1tz5k0|2dvo0|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a5c0|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Ojinaga",
            title: "Ojinaga",
            winIndex: 15,
            offsets: [-6.961111111111111, -7, -6, -5],
            offsetIndices: "0121212323221212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-p1u4k0|2u7jw0|1sgdc0|8n400|7thc0|9eys0|xes2s0|afuk0|8a840|afuk0|8aaw0|afuk0|8a840|ast80|7x9g0|ast80|9q2s0|7k580|9q2s0|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|77c40|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Panama",
            title: "Panama",
            winIndex: 10,
            offsets: [-5.326666666666667, -5],
            offsetIndices: "01",
            untils: "-w757vc|Infinity"
        }, {
            id: "America/Pangnirtung",
            title: "Pangnirtung",
            winIndex: 14,
            offsets: [0, -4, -3, -2, -5, -6],
            offsetIndices: "012213121212121212121212121212121212114141414154414141414141414141414141414141414141414141414141414141414141414141414141414",
            untils: "-pkmlc0|b0ke00|1tzdw0|2dnc0|a7n3w0|9q000|7k85k0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|asw00|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7xc80|ast80|7x6o0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Paramaribo",
            title: "Paramaribo",
            winIndex: 64,
            offsets: [-3.6777777777777776, -3.6811111111111114, -3.6766666666666667, -3.5, -3],
            offsetIndices: "012334",
            untils: "-usj4g8|cixc0c|5lydbk|fq7bic|4mkao0|Infinity"
        }, {
            id: "America/Phoenix",
            title: "Phoenix",
            winIndex: 56,
            offsets: [-7, -6],
            offsetIndices: "01010101010",
            untils: "-r0epo0|ast80|7x9g0|ast80|bmtus0|zjedo|4olg0|9et80|bs6lmc|9cyk0|Infinity"
        }, {
            id: "America/Port_of_Spain",
            title: "Port of Spain",
            winIndex: 16,
            offsets: [-4.101111111111111, -4],
            offsetIndices: "01",
            untils: "-u6m79w|Infinity"
        }, {
            id: "America/Port-au-Prince",
            title: "Port-au-Prince",
            winIndex: 14,
            offsets: [-4.816666666666666, -5, -4],
            offsetIndices: "01212121212121212121212121212121212121212121",
            untils: "-rmk9ac|ylcf6c|8zzw0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8aaw0|asw00|7x6o0|asw00|7x6o0|asw00|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|7x6o0|asw00|7x6o0|asw00|8a5c0|afxc0|8a5c0|afxc0|3vpjw0|ast80|7x9g0|ast80|2stv00|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Porto_Velho",
            title: "Porto Velho",
            winIndex: 16,
            offsets: [-4.26, -4, -3],
            offsetIndices: "012121212121212121212121212121",
            untils: "-t85g60|99k8i0|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|Infinity"
        }, {
            id: "America/Puerto_Rico",
            title: "Puerto Rico",
            winIndex: 16,
            offsets: [-4, -3],
            offsetIndices: "0110",
            untils: "-efsnk0|1ppu40|2dnc0|Infinity"
        }, {
            id: "America/Rainy_River",
            title: "Rainy River",
            winIndex: 13,
            offsets: [-6, -5],
            offsetIndices: "010111010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-qzov40|a2vw0|bfxjw0|pmdk0|1tz8c0|2dsw0|ewvus0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Rankin_Inlet",
            title: "Rankin Inlet",
            winIndex: 13,
            offsets: [0, -6, -4, -5],
            offsetIndices: "012131313131313131313131313131313131313131313331313131313131313131313131313131313131313131313131313131313131313131313131",
            untils: "-6s8lc0|4c6oo0|9q000|7k85k0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Recife",
            title: "Recife",
            winIndex: 64,
            offsets: [-2.3266666666666667, -3, -2],
            offsetIndices: "0121212121212121212121212121212121212121",
            untils: "-t85ljc|99kb3c|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|514g40|7k580|biw40|cvw0|iq5g0|6h980|Infinity"
        }, {
            id: "America/Regina",
            title: "Regina",
            winIndex: 37,
            offsets: [-6.9766666666666675, -7, -6],
            offsetIndices: "012121212121212121212121221212121212121212121212121212",
            untils: "-xkq9yc|6l1hmc|a2vw0|60enw0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|1b6840|9cyk0|9d440|8zzw0|9q2s0|9cyk0|9q2s0|9cyk0|9d440|9cyk0|66gc0|1tz5k0|2dvo0|a31g0|9cyk0|a31g0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|tj1g0|9cyk0|9d440|Infinity"
        }, {
            id: "America/Resolute",
            title: "Resolute",
            winIndex: 13,
            offsets: [0, -6, -4, -5],
            offsetIndices: "012131313131313131313131313131313131313131313331313131313331313131313131313131313131313131313131313131313131313131313131",
            untils: "-bnp9c0|97nco0|9q000|7k85k0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Rio_Branco",
            title: "Rio Branco",
            winIndex: 10,
            offsets: [-4.52, -5, -4],
            offsetIndices: "01212121212121212121212121212121",
            untils: "-t85fg0|99kak0|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|amves0|2t2t80|Infinity"
        }, {
            id: "America/Santa_Isabel",
            title: "Santa Isabel",
            winIndex: 72,
            link: 325
        }, {
            id: "America/Santarem",
            title: "Santarem",
            winIndex: 64,
            offsets: [-3.646666666666667, -4, -3],
            offsetIndices: "0121212121212121212121212121212",
            untils: "-t85hvc|99ka7c|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5mf440|49mk0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|amves0|Infinity"
        }, {
            id: "America/Santiago",
            title: "Santiago",
            winIndex: 39,
            offsets: [-4.712777777777777, -5, -4, -3],
            offsetIndices: "010202121212121212321232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323",
            untils: "-vauawq|3dlssq|157b7a|f4e0q|49hzba|aye0q|7ves0|awik0|7ves0|awik0|7ves0|awik0|7ves0|ayd80|7ves0|534ik0|351g0|229zw0|2gt80|awo40|2mg00|b73400|7k580|c8tg0|6h980|a31g0|7x3w0|asys0|7x3w0|b5xg0|7k580|ag040|8a2k0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7k580|b5xg0|9cyk0|9d440|7x3w0|asys0|7x3w0|b5xg0|7k580|9q2s0|8zzw0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|8n180|a31g0|7x3w0|a31g0|9px80|9q2s0|7x3w0|b5xg0|7k580|b5xg0|7k580|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|8n180|a31g0|7x3w0|asys0|8zzw0|9q2s0|ast80|5eis0|cyl80|6hes0|c8nw0|6udg0|bvp80|6udg0|vonw0|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|51k40|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|51k40|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|51k40|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|Infinity"
        }, {
            id: "America/Santo_Domingo",
            title: "Santo Domingo",
            winIndex: 16,
            offsets: [-4.666666666666667, -5, -4, -4.5],
            offsetIndices: "01213131313131212",
            untils: "-j6hz1c|hiw29c|67zw0|1dy840|62ha0|cnle0|4h2m0|elyq0|47ta0|ei9e0|4bim0|eek20|4dda0|ecpe0|dkmtg0|1stc0|Infinity"
        }, {
            id: "America/Sao_Paulo",
            title: "Sao Paulo",
            winIndex: 35,
            offsets: [-3.1077777777777778, -3, -2],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212",
            untils: "-t85jd8|99k8x8|9a9c0|9io40|99980|8p65g0|6zuo0|bs2o0|67zw0|cjxg0|69uk0|cjxg0|4ml80|5k02s0|6onw0|haas0|316k0|cls40|4ml80|cls40|66580|cls40|67zw0|981s40|6u7w0|biw40|5rbw0|d0lg0|5ed80|cyqs0|5ed80|dbpg0|64ak0|cyqs0|64ak0|cls40|5rbw0|dbpg0|51ek0|dbpg0|6h980|c8tg0|6h980|c8tg0|64ak0|c8tg0|6u7w0|bxpg0|7iak0|biw40|6u7w0|biw40|7k580|biw40|6u7w0|c8tg0|6h980|dbpg0|5ed80|cls40|64ak0|dfes0|5nmk0|c8tg0|6h980|dbpg0|5rbw0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6u7w0|c8tg0|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6h980|c8tg0|6h980|cls40|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6u7w0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|6h980|c8tg0|6h980|c8tg0|6h980|cls40|64ak0|cls40|64ak0|cls40|64ak0|cls40|6h980|c8tg0|6u7w0|bvus0|6h980|cls40|64ak0|cls40|6h980|c8tg0|Infinity"
        }, {
            id: "America/Scoresbysund",
            title: "Scoresbysund",
            winIndex: 73,
            offsets: [-1.4644444444444444, -2, -1, 0],
            offsetIndices: "0121323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-rvurxk|x8ntpk|902o0|9cvs0|9cyk0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "America/Sitka",
            title: "Sitka",
            winIndex: 55,
            offsets: [-8, -7, -9],
            offsetIndices: "01101010101010101010101010101010122020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202",
            untils: "-ek1w80|1tz2s0|2dyg0|cawis0|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|1leo0|7rs80|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/St_Johns",
            title: "St Johns",
            winIndex: 38,
            offsets: [-3.5144444444444445, -2.5144444444444445, -3.5, -2.5, -1.5],
            offsetIndices: "01010101010101010101010101010101010102323232323232323323232323232323232323232323232323232323232323232323232323232323232323232323232323232324232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-ris3ck|8bx80|ar440|a2vw0|9tjs0|53980|dkys0|9cyk0|9d440|9cyk0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|9cyk0|9d440|9cyk0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|9cyk0|9q2s0|8zzw0|9q2s0|8zzw0|7tmw0|1wfuk|8zzw0|a3480|7k580|b5xg0|7k580|b5xg0|7k580|biw40|776k0|biw40|7k580|b5xg0|7k580|b5xg0|1pb260|2dly0|biw40|7k580|b5xg0|7k580|b5xg0|7k580|b5xg0|7k580|biw40|7k580|ag040|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a2lo|afuk0|8a840|asqg0|7xc80|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8tec|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Swift_Current",
            title: "Swift Current",
            winIndex: 37,
            offsets: [-7.188888888888888, -7, -6],
            offsetIndices: "012122121212121212121212",
            untils: "-xkq9d4|6l1h14|a2vw0|c5jxg0|1tz5k0|2dvo0|asys0|8n180|a31g0|7x3w0|asys0|7x3w0|asys0|7x3w0|3yles0|9cyk0|s36s0|9cyk0|9d440|7x3w0|b5xg0|7k580|5j4lg0|Infinity"
        }, {
            id: "America/Tegucigalpa",
            title: "Tegucigalpa",
            winIndex: 67,
            offsets: [-5.814444444444445, -6, -5],
            offsetIndices: "01212121",
            untils: "-pfzh6k|yho0ik|7k580|b5xg0|7k580|96x1g0|4qak0|Infinity"
        }, {
            id: "America/Thule",
            title: "Thule",
            winIndex: 36,
            offsets: [-4.585555555555556, -4, -3],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-rvuj9g|12yzilg|9cyk0|9d440|9cyk0|9q2s0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Thunder_Bay",
            title: "Thunder Bay",
            winIndex: 14,
            offsets: [-6, -5, -4],
            offsetIndices: "0122121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-vbavc0|gr8qs0|1tzb40|2dq40|ctmlg0|9cyk0|9d440|9px80|9d440|9cyk0|s36s0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Tijuana",
            title: "Tijuana",
            winIndex: 11,
            offsets: [-7.801111111111111, -7, -8],
            offsetIndices: "012121211212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212",
            untils: "-p1u1s0|11jrw0|1sns00|1sgdc0|71s40|9cyk0|5iidg0|1q6700|4lfk0|190g40|eluk0|2r4r00|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|84qys0|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|77c40|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Toronto",
            title: "Toronto",
            winIndex: 14,
            offsets: [-5, -4],
            offsetIndices: "01010101010101010101010101010101010101010101011101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-qzoxw0|a2vw0|7yx60|aqzy0|9q8c0|7jzo0|bw0c0|6bp80|cedg0|6h980|c8tg0|6h980|bvus0|776k0|biw40|776k0|biw40|776k0|biw40|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|xjeo0|1tzb40|2dq40|asys0|7x3w0|ast80|7x3w0|asys0|7x3w0|asys0|b5rw0|7xf00|ast80|7x9g0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Vancouver",
            title: "Vancouver",
            winIndex: 11,
            offsets: [-8, -7],
            offsetIndices: "0101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-qzopk0|a2vw0|c5jxg0|1tz2s0|2dyg0|asys0|8n180|a31g0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Whitehorse",
            title: "Whitehorse",
            winIndex: 11,
            offsets: [-9, -8, -7],
            offsetIndices: "0101011020121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-qzoms0|a2vw0|asys0|882c0|bmiwc0|1tz000|2e180|a7n3w0|9q000|tiyo0|6qp440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Winnipeg",
            title: "Winnipeg",
            winIndex: 13,
            offsets: [-6, -5],
            offsetIndices: "010101011010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-s0s7c0|7k580|tj700|a2vw0|9ok840|6u7w0|2a5hg0|1tz8c0|2dsw0|biw40|7x3w0|a31g0|7x3w0|asys0|7x3w0|asys0|7x3w0|b7s40|7tek0|autg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|9cyk0|9d440|7x3w0|1cm2s0|7k580|1cm2s0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|902o0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|902o0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|8a5c0|afxc0|8a5c0|asw00|7x6o0|asw00|7x6o0|asw00|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|7x6o0|asw00|7x6o0|asw00|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|7x6o0|asw00|7x6o0|asw00|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|7x6o0|asw00|7x6o0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Yakutat",
            title: "Yakutat",
            winIndex: 55,
            offsets: [-9, -8],
            offsetIndices: "01101010101010101010101010101010100101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-ek1tg0|1tz000|2e180|cawis0|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|1lbw0|7rs80|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "America/Yellowknife",
            title: "Yellowknife",
            winIndex: 15,
            offsets: [0, -7, -6, -5],
            offsetIndices: "012213121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-i9m2o0|3pk3o0|1tz5k0|2dvo0|a7n3w0|9q000|7k85k0|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "Antarctica/Casey",
            title: "Casey",
            winIndex: 33,
            offsets: [0, 8, 11],
            offsetIndices: "012121",
            untils: "-irxc0|lag4o0|73bo0|uz1o0|60l80|Infinity"
        }, {
            id: "Antarctica/Davis",
            title: "Davis",
            winIndex: 6,
            offsets: [0, 7, 5],
            offsetIndices: "01012121",
            untils: "-6rmdc0|42jdw0|27wgs0|l8uss0|7eqs0|unmk0|60qs0|Infinity"
        }, {
            id: "Antarctica/DumontDUrville",
            title: "DumontDUrville",
            winIndex: 50,
            offsets: [0, 10],
            offsetIndices: "0101",
            untils: "-c05eo0|2mks80|2i72g0|Infinity"
        }, {
            id: "Antarctica/Macquarie",
            title: "Macquarie",
            winIndex: 48,
            offsets: [10, 11, 0],
            offsetIndices: "0102010101010101010101010101010101010101010101010101010101010101010101010101010101010101011",
            untils: "-rsj4w0|8zzw0|11wqk0|f4kh40|a6p8g0|9d1c0|asw00|6uao0|bvs00|6uao0|bvs00|779c0|bvs00|64dc0|clpc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|7x6o0|b5uo0|7k800|b5uo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|bvs00|7k800|bitc0|7k800|bitc0|779c0|bitc0|779c0|bitc0|7x6o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|7x6o0|asw00|a2yo0|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9d1c0|902o0|a2yo0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|Infinity"
        }, {
            id: "Antarctica/Mawson",
            title: "Mawson",
            winIndex: 17,
            offsets: [0, 6, 5],
            offsetIndices: "012",
            untils: "-8aelc0|t22y80|Infinity"
        }, {
            id: "Antarctica/Palmer",
            title: "Palmer",
            winIndex: 39,
            offsets: [0, -3, -4, -2],
            offsetIndices: "0121212121213121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-2lxhc0|31ho0|bqas0|71mk0|bqas0|8ovw0|9d440|9px80|9d440|9cyk0|9d440|28t6k0|51ek0|46b6s0|8c2s0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|7k580|b5xg0|9cyk0|9d440|7x3w0|asys0|7x3w0|b5xg0|7k580|9q2s0|8zzw0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|8n180|a31g0|7x3w0|a31g0|9px80|9q2s0|7x3w0|b5xg0|7k580|b5xg0|7k580|b5xg0|7k580|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7k580|b5xg0|8n180|a31g0|7x3w0|asys0|8zzw0|9q2s0|ast80|5eis0|cyl80|6hes0|c8nw0|6udg0|bvp80|6udg0|vonw0|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|51k40|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|51k40|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|51k40|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|e1h80|4olg0|Infinity"
        }, {
            id: "Antarctica/Rothera",
            title: "Rothera",
            winIndex: 64,
            offsets: [0, -3],
            offsetIndices: "01",
            untils: "3lxs00|Infinity"
        }, {
            id: "Antarctica/Syowa",
            title: "Syowa",
            winIndex: 1,
            offsets: [0, 3],
            offsetIndices: "01",
            untils: "-6qsqo0|Infinity"
        }, {
            id: "Antarctica/Vostok",
            title: "Vostok",
            winIndex: 21,
            offsets: [0, 6],
            offsetIndices: "01",
            untils: "-6aaao0|Infinity"
        }, {
            id: "Asia/Almaty",
            title: "Almaty",
            winIndex: 21,
            offsets: [5.13, 5, 6, 7],
            offsetIndices: "012323232323232323232321232323232323232323232323232",
            untils: "-nu1a90|37a0d0|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|iq5g0|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|Infinity"
        }, {
            id: "Asia/Amman",
            title: "Amman",
            winIndex: 74,
            offsets: [2.395555555555555, 2, 3],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-kcrtbk|m566fk|60l80|awo40|7v980|awo40|7v980|ayis0|9gnw0|9b9g0|7v980|autg0|7v980|3e6840|9et80|9io40|9cyk0|9d440|9cyk0|9d440|9px80|ayis0|7rjw0|ag040|8a2k0|9zc40|8drw0|a31g0|8zzw0|9d440|9cyk0|9d440|8n180|ag040|8a5c0|afxc0|8n400|a2yo0|8n400|a2yo0|8n400|epmo0|4deo0|9o5c0|9ew00|9b6o0|9ew00|9d1c0|9d1c0|9d1c0|asw00|7x6o0|afxc0|8n400|9d1c0|9d1c0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|wel80|51k40|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|Infinity"
        }, {
            id: "Asia/Anadyr",
            title: "Anadyr",
            winIndex: 75,
            offsets: [11.83222222222222, 12, 13, 14, 11],
            offsetIndices: "01232212121212121212121141212121212121212121212121212121212121141",
            untils: "-nu1sv8|379zj8|qi27w0|9et80|9d440|9ew00|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5xg0|7k800|Infinity"
        }, {
            id: "Asia/Aqtau",
            title: "Aqtau",
            winIndex: 17,
            offsets: [3.351111111111111, 4, 5, 6],
            offsetIndices: "012323232323232323232123232312121212121212121212",
            untils: "-nu15b4|379y74|qrh3w0|iruk0|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|iq5g0|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|Infinity"
        }, {
            id: "Asia/Aqtobe",
            title: "Aqtobe",
            winIndex: 17,
            offsets: [3.811111111111111, 4, 5, 6],
            offsetIndices: "0123232323232323232321232323232323232323232323232",
            untils: "-nu16l4|379zh4|qi27w0|s6qk0|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|iq5g0|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|Infinity"
        }, {
            id: "Asia/Ashgabat",
            title: "Ashgabat",
            winIndex: 17,
            offsets: [3.8922222222222222, 4, 5, 6],
            offsetIndices: "012323232323232323232322112",
            untils: "-nu16t8|379zp8|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|1fp40|4bpk0|Infinity"
        }, {
            id: "Asia/Baghdad",
            title: "Baghdad",
            winIndex: 76,
            offsets: [2.96, 3, 4],
            offsetIndices: "012121212121212121212121212121212121212121212121212121",
            untils: "-r50g80|xkn3w0|7v980|9b9g0|9gnw0|9eys0|9et80|9d440|9b9g0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9f1k0|9ew00|9ew00|9ew00|9d1c0|9ew00|9d1c0|9ew00|9d1c0|9ew00|9ew00|9ew00|9d1c0|9ew00|9d1c0|9ew00|9d1c0|9ew00|9ew00|9ew00|9d1c0|9ew00|9d1c0|9ew00|9d1c0|9ew00|9ew00|9ew00|9d1c0|9ew00|9d1c0|9ew00|9d1c0|9ew00|Infinity"
        }, {
            id: "Asia/Baku",
            title: "Baku",
            winIndex: 77,
            offsets: [3.3233333333333333, 3, 4, 5],
            offsetIndices: "01232323232323232323232221223232323232323232323232323232323232323232",
            untils: "-nu158c|h4tkwc|ckinw0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|7tbs0|1jsc0|9d1c0|9cq80|1twoo0|asw00|7x3w0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Asia/Bangkok",
            title: "Bangkok",
            winIndex: 6,
            offsets: [6.7011111111111115, 7],
            offsetIndices: "01",
            untils: "-pysda4|Infinity"
        }, {
            id: "Asia/Beirut",
            title: "Beirut",
            winIndex: 78,
            offsets: [2, 3],
            offsetIndices: "010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-pyzew0|aunw0|88dg0|9et80|8yas0|a2vw0|a31g0|7k580|hjqo40|7v980|awo40|7v980|awo40|7v980|ayis0|7v980|awo40|7v980|5lhs40|56yk0|awo40|7v980|awo40|7v980|awo40|7v980|ayis0|7v980|awo40|7v980|autg0|7v980|2wxus0|8n180|a4w40|8n180|a4w40|8n180|a4w40|8n180|bs5g0|71mk0|alk40|86d80|a4w40|8n180|a4w40|8n180|a6qs0|80t80|905g0|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|Infinity"
        }, {
            id: "Asia/Bishkek",
            title: "Bishkek",
            winIndex: 21,
            offsets: [4.973333333333333, 5, 6, 7],
            offsetIndices: "01232323232323232323232212121212121212121212121212122",
            untils: "-nu19tc|379zxc|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|7vc00|bkl80|8n180|a31g0|8n180|a31g0|8n180|a31g0|8n180|a31g0|8zzw0|9db20|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|73aa0|Infinity"
        }, {
            id: "Asia/Brunei",
            title: "Brunei",
            winIndex: 24,
            offsets: [7.661111111111111, 7.5, 8],
            offsetIndices: "012",
            untils: "-mvofy4|3khxs4|Infinity"
        }, {
            id: "Asia/Chita",
            title: "Chita",
            winIndex: 79,
            offsets: [7.564444444444445, 8, 9, 10],
            offsetIndices: "0123232323232323232323221232323232323232323232323232323232323232312",
            untils: "-q4cfog|5hkxgg|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|qnew0|Infinity"
        }, {
            id: "Asia/Choibalsan",
            title: "Choibalsan",
            winIndex: 25,
            offsets: [7.633333333333334, 7, 8, 10, 9],
            offsetIndices: "0123434343434343434343434343434343434343434343424242424242424242424242424242424242424242424242",
            untils: "-xmct7c|11sndrc|2qk2k0|9eqg0|9eys0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|9cyk0|9d440|9cyk0|9d440|9cyk0|1ckdo0|7x3w0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|s6qk0|3nc0c0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|Infinity"
        }, {
            id: "Asia/Colombo",
            title: "Colombo",
            winIndex: 80,
            offsets: [5.325555555555556, 5.5, 6, 6.5],
            offsetIndices: "01231321",
            untils: "-xehask|isle6k|cajy0|1mp2u0|qetjw0|7x5a0|4xvqq0|Infinity"
        }, {
            id: "Asia/Damascus",
            title: "Damascus",
            winIndex: 81,
            offsets: [2.42, 2, 3],
            offsetIndices: "01212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-q3gk20|5k6q0|8n180|a31g0|8n180|a31g0|8n180|a31g0|8zzw0|k4hk40|7yyk0|awo40|7tek0|b0dg0|7v980|awo40|7tek0|alk40|887w0|awo40|7v980|ayis0|7v980|awo40|7v980|awo40|7v980|awo40|7v980|ayis0|7v980|awo40|7v980|awo40|7v980|awo40|7v980|ayis0|7v980|awo40|6bp80|cg840|6bp80|2eh1g0|8zzw0|9ts40|8zzw0|pvk40|c33w0|7cw40|cjrw0|6zxg0|btuk0|7rpg0|9gnw0|9d440|9cyk0|9et80|9et80|9rxg0|91uk0|92040|9et80|9o840|9et80|9d440|9et80|9eys0|9et80|9b9g0|9gnw0|99es0|9iik0|9d440|9et80|9eys0|9et80|9d440|9et80|9d440|9et80|9d440|9et80|9eys0|9et80|9d440|9et80|9d440|8y580|9q2s0|b5rw0|7x9g0|aunw0|7ig40|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|Infinity"
        }, {
            id: "Asia/Dhaka",
            title: "Dhaka",
            winIndex: 20,
            offsets: [5.888888888888888, 6.5, 5.5, 6, 7],
            offsetIndices: "01213343",
            untils: "-eqtpow|bmgyw|5lxg0|4qknw0|a63o20|jyevw0|a1400|Infinity"
        }, {
            id: "Asia/Dili",
            title: "Dili",
            winIndex: 43,
            offsets: [8.372222222222222, 8, 9],
            offsetIndices: "012212",
            untils: "-u9s4l8|fqcu98|1vc2o0|fz3pc0|cpz440|Infinity"
        }, {
            id: "Asia/Dubai",
            title: "Dubai",
            winIndex: 7,
            offsets: [3.6866666666666665, 4],
            offsetIndices: "01",
            untils: "-q3gnko|Infinity"
        }, {
            id: "Asia/Dushanbe",
            title: "Dushanbe",
            winIndex: 17,
            offsets: [4.586666666666667, 5, 6, 7],
            offsetIndices: "0123232323232323232323221",
            untils: "-nu18qo|379yuo|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|8c2s0|Infinity"
        }, {
            id: "Asia/Ho_Chi_Minh",
            title: "Ho Chi Minh",
            winIndex: 6,
            offsets: [7.111111111111112, 7.108333333333333, 7, 8, 9],
            offsetIndices: "0123423232",
            untils: "-x56934|2isioa|gj25iu|15ct80|8so00|tmtk0|4azjw0|2cmao0|8285c0|Infinity"
        }, {
            id: "Asia/Hong_Kong",
            title: "Hong Kong",
            winIndex: 19,
            offsets: [7.611666666666666, 8, 9],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-y0i2h6|j09kn6|9cyk0|4f2e0|1xyfw0|b6760|bkl80|6udg0|df980|6dpg0|9cyk0|7x9g0|ast80|7x9g0|ast80|7x9g0|ast80|8a840|adzw0|8c2s0|ast80|77c40|biqk0|77c40|bvp80|6udg0|bvp80|77c40|biqk0|77c40|biqk0|77c40|biqk0|77c40|bvp80|6udg0|bvp80|6udg0|bvp80|77c40|biqk0|77c40|biqk0|8n6s0|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|3lpg0|f4d80|9d440|9cyk0|9d440|9cyk0|1c9440|8a2k0|Infinity"
        }, {
            id: "Asia/Hovd",
            title: "Hovd",
            winIndex: 6,
            offsets: [6.11, 6, 7, 8],
            offsetIndices: "012323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-xmcoz0|11sncb0|2qk2k0|9et80|9eys0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|9cyk0|9d440|9cyk0|9d440|9cyk0|1ckdo0|7x3w0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|4fio40|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|Infinity"
        }, {
            id: "Asia/Irkutsk",
            title: "Irkutsk",
            winIndex: 82,
            offsets: [6.951388888888888, 7, 8, 9],
            offsetIndices: "012323232323232323232322123232323232323232323232323232323232323232",
            untils: "-q28gn5|5fh175|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Jakarta",
            title: "Jakarta",
            winIndex: 6,
            offsets: [7.12, 7.333333333333333, 7.5, 9, 8, 7],
            offsetIndices: "01232425",
            untils: "-o0bdpc|4lzxc0|4wdzjc|1tu960|1cx860|11jta0|74uc20|Infinity"
        }, {
            id: "Asia/Jayapura",
            title: "Jayapura",
            winIndex: 43,
            offsets: [9.379999999999999, 9, 9.5],
            offsetIndices: "0121",
            untils: "-jebm20|66bqe0|a37vy0|Infinity"
        }, {
            id: "Asia/Jerusalem",
            title: "Jerusalem",
            winIndex: 23,
            offsets: [2.344444444444444, 2, 3, 4],
            offsetIndices: "01212121212132121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-r50eig|bp54yg|19f3w0|7rv00|b02c0|7tk40|b07w0|8jhg0|a8lg0|8jhg0|a8ac0|t9s40|56vs0|35700|9b3w0|9gtg0|8jbw0|7tmw0|a6ig0|biyw0|8a5c0|9d1c0|902o0|7x6o0|e1eg0|4ofw0|dzxo0|4q500|doo40|64iw0|auqo0|7i500|8rfms0|51ek0|9q2s0|6u7w0|50rhg0|7x3w0|cls40|5rbw0|bbhg0|7rjw0|asys0|7k580|c8tg0|6h980|ag040|7x3w0|asys0|8a2k0|asys0|8a2k0|ap9g0|80t80|ap9g0|7nuk0|b2840|80t80|9zc40|9iik0|9kis0|93p80|9mdg0|8qqk0|apf00|7x3w0|biw40|8zx40|9io40|8n180|9kis0|9vh80|8ulg0|9px80|9mdg0|8n180|9tuw0|9tmk0|8wg40|9gnw0|99es0|8qqk0|9zc40|9tmk0|8wg40|9gnw0|99es0|8qqk0|acas0|9gnw0|99es0|93p80|9mdg0|awik0|7tk40|awik0|7tk40|awik0|7tk40|b9h80|7glg0|b9h80|7glg0|b9h80|7tk40|awik0|7tk40|awik0|7tk40|b9h80|7glg0|b9h80|7glg0|b9h80|7tk40|awik0|7tk40|awik0|7tk40|awik0|7tk40|b9h80|7glg0|b9h80|7glg0|b9h80|7tk40|awik0|7tk40|awik0|7tk40|b9h80|7glg0|b9h80|7glg0|b9h80|7glg0|b9h80|7tk40|awik0|7tk40|awik0|Infinity"
        }, {
            id: "Asia/Kabul",
            title: "Kabul",
            winIndex: 83,
            offsets: [4, 4.5],
            offsetIndices: "01",
            untils: "-d1pkg0|Infinity"
        }, {
            id: "Asia/Kamchatka",
            title: "Kamchatka",
            winIndex: 75,
            offsets: [10.576666666666666, 11, 12, 13],
            offsetIndices: "01232323232323232323232212323232323232323232323232323232323232212",
            untils: "-olrupo|3z045o|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5xg0|7k800|Infinity"
        }, {
            id: "Asia/Karachi",
            title: "Karachi",
            winIndex: 84,
            offsets: [4.47, 5.5, 6.5, 5, 6],
            offsetIndices: "012133434343",
            untils: "-wvpb30|im3zt0|1mn180|33xpg0|a63o20|g72qo0|9cyk0|2y85g0|7v980|8hms0|aaak0|Infinity"
        }, {
            id: "Asia/Kathmandu",
            title: "Kathmandu",
            winIndex: 22,
            offsets: [5.687777777777778, 5.5, 5.75],
            offsetIndices: "012",
            untils: "-q3gt4s|yg2lus|Infinity"
        }, {
            id: "Asia/Khandyga",
            title: "Khandyga",
            winIndex: 79,
            offsets: [9.036944444444446, 8, 9, 10, 11],
            offsetIndices: "01232323232323232323232212323232323232323232323232343434343434343432",
            untils: "-q4cjrp|5hl1jp|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|3fx40|4h6s0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|8ql00|1mlho0|Infinity"
        }, {
            id: "Asia/Kolkata",
            title: "Kolkata",
            winIndex: 18,
            offsets: [5.888888888888888, 6.5, 5.5],
            offsetIndices: "01212",
            untils: "-eqtpow|bmgyw|5lxg0|1mn180|Infinity"
        }, {
            id: "Asia/Krasnoyarsk",
            title: "Krasnoyarsk",
            winIndex: 85,
            offsets: [6.190555555555556, 6, 7, 8],
            offsetIndices: "012323232323232323232322123232323232323232323232323232323232323232",
            untils: "-q37l72|5gg8j2|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Kuala_Lumpur",
            title: "Kuala Lumpur",
            winIndex: 24,
            offsets: [6.923611111111112, 7, 7.333333333333333, 7.5, 9, 8],
            offsetIndices: "01223435",
            untils: "-xphpwd|eeb94d|1kbr2o|2yhc00|8n3jc|1v2p60|iy3o60|Infinity"
        }, {
            id: "Asia/Kuching",
            title: "Kuching",
            winIndex: 24,
            offsets: [7.355555555555555, 7.5, 8, 8.333333333333334, 9],
            offsetIndices: "01232323232323232422",
            untils: "-mvof3k|3khwxk|1epvy0|4ohqo|e5a9c|4ohqo|e3flc|4ohqo|e3flc|4ohqo|e3flc|4ohqo|e5a9c|4ohqo|e3flc|4ohqo|3ajlc|1v2qk0|iy3ms0|Infinity"
        }, {
            id: "Asia/Macau",
            title: "Macau",
            winIndex: 19,
            offsets: [7.572222222222222, 8, 9],
            offsetIndices: "0121212121212121212121212121212121212121211",
            untils: "-u9s2d8|pon9v8|bvp80|6udg0|bvp80|6u3q0|bvyy0|77c40|biqk0|772e0|biqk0|8ngi0|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9cue0|9cyk0|9d440|9px80|9d440|9d8a0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9cue0|9cyk0|9d440|9px80|9d440|9cyk0|a04w40|Infinity"
        }, {
            id: "Asia/Magadan",
            title: "Magadan",
            winIndex: 75,
            offsets: [10.053333333333335, 10, 11, 12],
            offsetIndices: "0123232323232323232323221232323232323232323232323232323232323232312",
            untils: "-nu1nxc|37a05c|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|s39k0|Infinity"
        }, {
            id: "Asia/Makassar",
            title: "Makassar",
            winIndex: 24,
            offsets: [7.96, 8, 9],
            offsetIndices: "00121",
            untils: "-q3gzg0|6p5hc0|4u87w0|1w02k0|Infinity"
        }, {
            id: "Asia/Manila",
            title: "Manila",
            winIndex: 24,
            offsets: [8, 9],
            offsetIndices: "010101010",
            untils: "-hb5y80|4qak0|2qidg0|1b2d80|4xf440|442k0|cdqdg0|9et80|Infinity"
        }, {
            id: "Asia/Nicosia",
            title: "Nicosia",
            winIndex: 4,
            offsets: [2.2244444444444444, 2, 3],
            offsetIndices: "01212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-p4bq6g|rvhxyg|9cyk0|b42s0|7nuk0|8yas0|8zzw0|9q2s0|9et80|9b9g0|9cyk0|9q2s0|8zzw0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|9cyk0|9d440|9cyk0|9d440|at4c0|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Asia/Novokuznetsk",
            title: "Novokuznetsk",
            winIndex: 86,
            offsets: [5.8133333333333335, 6, 7, 8],
            offsetIndices: "012323232323232323232322123232323232323232323232323232323232322122",
            untils: "-nu36tc|37bu5c|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5xg0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Novosibirsk",
            title: "Novosibirsk",
            winIndex: 86,
            offsets: [5.527777777777778, 6, 7, 8],
            offsetIndices: "0123232323232323232323221232321212121212121212121212121212121212121",
            untils: "-q4do0s|5hmbcs|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|2vh00|6hn40|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Omsk",
            title: "Omsk",
            winIndex: 86,
            offsets: [4.891666666666667, 5, 6, 7],
            offsetIndices: "012323232323232323232322123232323232323232323232323232323232323232",
            untils: "-q5xmx6|5j6d16|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Oral",
            title: "Oral",
            winIndex: 17,
            offsets: [3.4233333333333333, 4, 5, 6],
            offsetIndices: "01232323232323232121212121212121212121212121212",
            untils: "-nu15ic|379yec|qi27w0|s6qk0|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|iq5g0|9d1c0|9q000|9d1c0|9d1c0|5reo0|cyo00|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|Infinity"
        }, {
            id: "Asia/Pontianak",
            title: "Pontianak",
            winIndex: 6,
            offsets: [7.288888888888889, 7.5, 9, 8, 7],
            offsetIndices: "001213134",
            untils: "-w6piww|cse2o0|4tnu2w|1wkei0|1cx860|11jta0|74uc20|cixam0|Infinity"
        }, {
            id: "Asia/Pyongyang",
            title: "Pyongyang",
            winIndex: 53,
            offsets: [8.383333333333333, 8.5, 9],
            offsetIndices: "012221",
            untils: "-w895yc|1yh10c|dfsmm0|44cqo0|10ipmo0|Infinity"
        }, {
            id: "Asia/Qatar",
            title: "Qatar",
            winIndex: 5,
            offsets: [3.4355555555555553, 4, 3],
            offsetIndices: "012",
            untils: "-q3gmvk|rctnrk|Infinity"
        }, {
            id: "Asia/Qyzylorda",
            title: "Qyzylorda",
            winIndex: 21,
            offsets: [4.364444444444445, 4, 5, 6],
            offsetIndices: "0123232323232323232323232323232323232323232323",
            untils: "-nu184g|37a10g|qi27w0|s6qk0|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|ohhc0|cyo00|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|Infinity"
        }, {
            id: "Asia/Rangoon",
            title: "Rangoon",
            winIndex: 87,
            offsets: [6.411111111111111, 6.5, 9],
            offsetIndices: "0121",
            untils: "-q3gv54|bnjp34|1kh520|Infinity"
        }, {
            id: "Asia/Riyadh",
            title: "Riyadh",
            winIndex: 5,
            offsets: [3.1144444444444446, 3],
            offsetIndices: "01",
            untils: "-bwgbbg|Infinity"
        }, {
            id: "Asia/Sakhalin",
            title: "Sakhalin",
            winIndex: 88,
            offsets: [9.513333333333332, 9, 11, 12, 10],
            offsetIndices: "01123232323232323232323224232323232322424242424242424242424242424242",
            untils: "-xl87rc|gr8pfc|44elc0|ikvh40|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asys0|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|qnc40|Infinity"
        }, {
            id: "Asia/Samarkand",
            title: "Samarkand",
            winIndex: 17,
            offsets: [4.464722222222222, 4, 5, 6],
            offsetIndices: "01233323232323232323232332",
            untils: "-nu18eh|37a1ah|qi27w0|9et80|9d1c0|9ew00|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|7wyc0|1g300|Infinity"
        }, {
            id: "Asia/Seoul",
            title: "Seoul",
            winIndex: 53,
            offsets: [8.464444444444444, 8.5, 9, 9.5, 10],
            offsetIndices: "01222131313131313124242",
            untils: "-w8966g|1yh18g|dfsmm0|454io0|4gadc0|l3aq0|6j3w0|d2g40|6u7w0|b5xg0|776k0|biw40|776k0|biw40|776k0|biw40|776k0|grs40|dfqxi0|7x6o0|asw00|7x6o0|Infinity"
        }, {
            id: "Asia/Shanghai",
            title: "Shanghai",
            winIndex: 19,
            offsets: [8, 9],
            offsetIndices: "01010101010101010",
            untils: "-ffs0w0|66580|8jhg0|a8fw0|n9rc40|6u7w0|asys0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|asys0|7x3w0|asys0|7x3w0|Infinity"
        }, {
            id: "Asia/Singapore",
            title: "Singapore",
            winIndex: 24,
            offsets: [6.923611111111112, 7, 7.333333333333333, 7.5, 9, 8],
            offsetIndices: "012234335",
            untils: "-xphpwd|eeb94d|1kbr2o|2yhc00|8n3jc|1v2p60|ae0xi0|8k2qo0|Infinity"
        }, {
            id: "Asia/Srednekolymsk",
            title: "Srednekolymsk",
            winIndex: 75,
            offsets: [10.247777777777777, 10, 11, 12],
            offsetIndices: "012323232323232323232322123232323232323232323232323232323232323232",
            untils: "-nu1ogs|37a0os|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Taipei",
            title: "Taipei",
            winIndex: 52,
            offsets: [8, 9],
            offsetIndices: "01010101010101010101010101010101010101010",
            untils: "-gtzfk0|45slc0|c51c0|75bw0|a31g0|aaak0|9d440|7v980|awo40|7v980|awo40|7v980|awo40|7v980|7tk40|clmk0|7rpg0|b07w0|7rpg0|b07w0|7rpg0|9et80|9eys0|9et80|9d440|9et80|9d440|9et80|9d440|9et80|cjxg0|69uk0|ci2s0|69uk0|6its40|9et80|9d440|9et80|1yf9g0|4qak0|Infinity"
        }, {
            id: "Asia/Tashkent",
            title: "Tashkent",
            winIndex: 17,
            offsets: [4.619722222222222, 5, 6, 7],
            offsetIndices: "01232323232323232323232221",
            untils: "-nu18tz|379yxz|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|7x140|1g300|Infinity"
        }, {
            id: "Asia/Tbilisi",
            title: "Tbilisi",
            winIndex: 89,
            offsets: [2.986388888888889, 3, 4, 5],
            offsetIndices: "0123232323232323232323222121212232323232323232323212",
            untils: "-nu14an|h4tjyn|ckinw0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|gig0|8wlo0|9cvs0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d1c0|9cyk0|9q2s0|tivw0|7x9g0|ast80|7x9g0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7x9g0|ast80|7x9g0|ast80|7x9g0|4ofw0|6hn40|7k800|Infinity"
        }, {
            id: "Asia/Tehran",
            title: "Tehran",
            winIndex: 42,
            offsets: [3.428888888888889, 3.5, 4, 5, 4.5],
            offsetIndices: "00123214141414141414141414141414141414141414141414141414141414141414141414141414141414141414141414141",
            untils: "-s6m6uw|fnolc0|gm3h4w|777y0|b07w0|3pes0|42c20|9cyk0|9gtg0|9kd80|5ja5g0|7avw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|1av440|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9d440|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|9b9g0|9gnw0|Infinity"
        }, {
            id: "Asia/Thimphu",
            title: "Thimphu",
            winIndex: 20,
            offsets: [5.9766666666666675, 5.5, 6],
            offsetIndices: "012",
            untils: "-bojclo|kxymno|Infinity"
        }, {
            id: "Asia/Tokyo",
            title: "Tokyo",
            winIndex: 43,
            offsets: [9, 10],
            offsetIndices: "0010101010",
            untils: "-gtzic0|5ivew0|6sd80|ahus0|887w0|cao40|6fek0|cao40|6fek0|Infinity"
        }, {
            id: "Asia/Ulaanbaatar",
            title: "Ulaanbaatar",
            winIndex: 25,
            offsets: [7.125555555555556, 7, 8, 9],
            offsetIndices: "012323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-xmcrsk|11sncck|2qk2k0|9et80|9eys0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|9cyk0|9d440|9cyk0|9d440|9cyk0|1ckdo0|7x3w0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|4fio40|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9pro0|9d9o0|9ct00|9d9o0|9ct00|9d9o0|9ct00|Infinity"
        }, {
            id: "Asia/Urumqi",
            title: "Urumqi",
            winIndex: 21,
            offsets: [5.838888888888889, 6],
            offsetIndices: "01",
            untils: "-lx5pjw|Infinity"
        }, {
            id: "Asia/Ust-Nera",
            title: "Ust-Nera",
            winIndex: 88,
            offsets: [9.548333333333334, 8, 9, 12, 11, 10],
            offsetIndices: "0123434343434343434343445434343434343434343434343434343434343434345",
            untils: "-q4cl6u|5hl2yu|qi27w0|9eno0|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|8ql00|1mlho0|Infinity"
        }, {
            id: "Asia/Vladivostok",
            title: "Vladivostok",
            winIndex: 88,
            offsets: [8.791944444444445, 9, 10, 11],
            offsetIndices: "012323232323232323232322123232323232323232323232323232323232323232",
            untils: "-oligf7|3yqvf7|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Yakutsk",
            title: "Yakutsk",
            winIndex: 79,
            offsets: [8.649444444444445, 8, 9, 10],
            offsetIndices: "012323232323232323232322123232323232323232323232323232323232323232",
            untils: "-q4cioy|5hl0gy|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Yekaterinburg",
            title: "Yekaterinburg",
            winIndex: 90,
            offsets: [4.0425, 3.751388888888889, 4, 5, 6],
            offsetIndices: "0123434343434343434343433234343434343434343434343434343434343434343",
            untils: "-rx5hw9|1kybx4|5pfyv5|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Asia/Yerevan",
            title: "Yerevan",
            winIndex: 91,
            offsets: [2.966666666666667, 3, 4, 5],
            offsetIndices: "0123232323232323232323222121212122323232323232323232323232323232",
            untils: "-nu148o|h4tjwo|ckinw0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|91rs0|bcc0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|sfzw0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|Infinity"
        }, {
            id: "Atlantic/Azores",
            title: "Azores",
            winIndex: 73,
            offsets: [-1.9088888888888889, -2, -1, 0],
            offsetIndices: "01212121212121212121212121212121212121212121232123212321232121212121212121212121212121212121212121232323232323232323232323232323233323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-u9rc14|2bug54|6zxg0|66580|bq800|73k00|bodc0|71pc0|bq800|73k00|bq800|71pc0|bq800|1b2g00|9b6o0|saio0|8n400|9q000|902o0|a2yo0|902o0|a2yo0|8n400|st1c0|8n400|9d1c0|9d1c0|sg2o0|9d1c0|902o0|9q000|a2yo0|8n400|9d1c0|9d1c0|902o0|9q000|a2yo0|b5uo0|51hc0|bitc0|9d1c0|9ew00|88ao0|25p80|5reo0|3lpg0|779c0|1sqk0|6uao0|38qs0|6uao0|25p80|6hc00|38qs0|6uao0|25p80|6hc00|38qs0|8a5c0|9d1c0|9d9o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|s3400|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|5qbjo0|9d1c0|9q000|9d1c0|9d1c0|9d440|9cyk0|9d440|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9cyk0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9cyk0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Atlantic/Bermuda",
            title: "Bermuda",
            winIndex: 36,
            offsets: [-4.321666666666667, -4, -3],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-kvj2fu|n4pr3u|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "Atlantic/Canary",
            title: "Canary",
            winIndex: 26,
            offsets: [-1.0266666666666666, -1, 0, 1],
            offsetIndices: "01232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-oytbtc|ctvupc|hhq7s0|905g0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Atlantic/Cape_Verde",
            title: "Cape Verde",
            winIndex: 92,
            offsets: [-1.5677777777777777, -2, -1],
            offsetIndices: "01212",
            untils: "-wvoub8|im43v8|1mn180|fpqwc0|Infinity"
        }, {
            id: "Atlantic/Faroe",
            title: "Faroe",
            winIndex: 26,
            offsets: [-.45111111111111113, 0, 1],
            offsetIndices: "01212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-wcehew|127keuw|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Atlantic/Madeira",
            title: "Madeira",
            winIndex: 26,
            offsets: [-1.1266666666666665, -1, 0, 1],
            offsetIndices: "01212121212121212121212121212121212121212121232123212321232121212121212121212121212121212121212121232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-u9re7c|2bufjc|6zxg0|66580|bq800|73k00|bodc0|71pc0|bq800|73k00|bq800|71pc0|bq800|1b2g00|9b6o0|saio0|8n400|9q000|902o0|a2yo0|902o0|a2yo0|8n400|st1c0|8n400|9d1c0|9d1c0|sg2o0|9d1c0|902o0|9q000|a2yo0|8n400|9d1c0|9d1c0|902o0|9q000|a2yo0|b5uo0|51hc0|bitc0|9d1c0|9ew00|88ao0|25p80|5reo0|3lpg0|779c0|1sqk0|6uao0|38qs0|6uao0|25p80|6hc00|38qs0|6uao0|25p80|6hc00|38qs0|8a5c0|9d1c0|9d9o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|s3400|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|5qbjo0|9d1c0|9q000|9d1c0|9d1c0|9d440|9cyk0|9d440|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9cyk0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Atlantic/Reykjavik",
            title: "Reykjavik",
            winIndex: 0,
            offsets: [-1.4666666666666666, -1, 0],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212",
            untils: "-wcwx9c|4rpd9c|ci2s0|69uk0|du840|4xp80|du840|p7bw0|4w040|9bdzw0|9d6w0|64g40|cyl80|64dc0|clpc0|6hc00|bvs00|6uao0|bvs00|6uao0|bvs00|6uao0|c8qo0|6hc00|c8qo0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|7x6o0|afxc0|8a5c0|asw00|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|asw00|8a5c0|Infinity"
        }, {
            id: "Atlantic/South_Georgia",
            title: "South Georgia",
            winIndex: 34,
            offsets: [-2],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Atlantic/Stanley",
            title: "Stanley",
            winIndex: 64,
            offsets: [-3.856666666666667, -4, -3, -2],
            offsetIndices: "0121212121212123232212121212121212121212121212121212121212121212121212",
            untils: "-u63pac|dbvxqc|8zzw0|9q2s0|8zzw0|a31g0|8zzw0|9q2s0|8zzw0|9q2s0|8zzw0|9q2s0|4xp80|l1pus0|7k580|b5rw0|77c40|biqk0|77c40|b5uo0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7kas0|biqk0|77c40|biqk0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7kas0|biqk0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5rw0|7kas0|b5xg0|77c40|bvp80|6udg0|bvp80|77c40|biqk0|77c40|biqk0|77c40|biqk0|77c40|biqk0|77c40|bvp80|77c40|biqk0|77c40|biqk0|77c40|Infinity"
        }, {
            id: "Australia/Adelaide",
            title: "Adelaide",
            winIndex: 31,
            offsets: [9.5, 10.5],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101",
            untils: "-rnsvoc|49s2c|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|eeiqs0|64dc0|clpc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|779c0|b5uo0|7k800|bitc0|7k800|bitc0|779c0|bitc0|779c0|bitc0|6hc00|c8qo0|7k800|b5uo0|6uao0|c8qo0|779c0|bitc0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7k800|b5uo0|8a5c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|Infinity"
        }, {
            id: "Australia/Brisbane",
            title: "Brisbane",
            winIndex: 30,
            offsets: [10, 11],
            offsetIndices: "01010101010101010",
            untils: "-rnsx2c|49s2c|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|eeiqs0|64dc0|97zuo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|Infinity"
        }, {
            id: "Australia/Broken_Hill",
            title: "Broken Hill",
            winIndex: 31,
            offsets: [9.5, 10.5],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101",
            untils: "-rnsvoc|49s2c|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|eeiqs0|64dc0|clpc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|8a5c0|asw00|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|779c0|b5uo0|7k800|bitc0|7k800|bitc0|779c0|bitc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7k800|b5uo0|8a5c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|Infinity"
        }, {
            id: "Australia/Currie",
            title: "Currie",
            winIndex: 32,
            offsets: [10, 11],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101",
            untils: "-rsj4w0|8zzw0|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|eeiqs0|64dc0|clpc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|7x6o0|b5uo0|7k800|b5uo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|bvs00|7k800|bitc0|7k800|bitc0|779c0|bitc0|779c0|bitc0|7x6o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|7x6o0|asw00|a2yo0|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9d1c0|902o0|a2yo0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|Infinity"
        }, {
            id: "Australia/Darwin",
            title: "Darwin",
            winIndex: 29,
            offsets: [9.5, 10.5],
            offsetIndices: "010101010",
            untils: "-rnsvoc|49s2c|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|Infinity"
        }, {
            id: "Australia/Hobart",
            title: "Hobart",
            winIndex: 32,
            offsets: [10, 11],
            offsetIndices: "010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101",
            untils: "-rsj4w0|8zzw0|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|c9tms0|9d1c0|asw00|6uao0|bvs00|6uao0|bvs00|779c0|bvs00|64dc0|clpc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|7x6o0|b5uo0|7k800|b5uo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|bvs00|7k800|bitc0|7k800|bitc0|779c0|bitc0|779c0|bitc0|7x6o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|7x6o0|asw00|a2yo0|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9d1c0|902o0|a2yo0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|Infinity"
        }, {
            id: "Australia/Lindeman",
            title: "Lindeman",
            winIndex: 30,
            offsets: [10, 11],
            offsetIndices: "010101010101010101010",
            untils: "-rnsx2c|49s2c|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|eeiqs0|64dc0|97zuo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|Infinity"
        }, {
            id: "Australia/Melbourne",
            title: "Melbourne",
            winIndex: 28,
            offsets: [10, 11],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101",
            untils: "-rnsx2c|49s2c|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|eeiqs0|64dc0|clpc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|779c0|b5uo0|7k800|b5uo0|7x6o0|bitc0|779c0|bitc0|779c0|bitc0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|7x6o0|asw00|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7k800|b5uo0|8a5c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|Infinity"
        }, {
            id: "Australia/Perth",
            title: "Perth",
            winIndex: 33,
            offsets: [8, 9],
            offsetIndices: "0101010101010101010",
            untils: "-rnsric|49s2c|cxfms0|4h180|9d440|9cyk0|ghf1g0|6hc00|4ir9c0|6hc00|40r400|5eg00|7p9hc0|5reo0|b5uo0|7x6o0|asw00|7x6o0|Infinity"
        }, {
            id: "Australia/Sydney",
            title: "Sydney",
            winIndex: 28,
            offsets: [10, 11],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101",
            untils: "-rnsx2c|49s2c|cxfms0|4h180|9d440|9cyk0|9q2s0|8zzw0|eeiqs0|64dc0|clpc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|8a5c0|asw00|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|779c0|b5uo0|7k800|bitc0|7k800|bitc0|779c0|bitc0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|7x6o0|asw00|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7k800|b5uo0|8a5c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|Infinity"
        }, {
            id: "CST6CDT",
            title: "CST6CDT",
            winIndex: 13,
            offsets: [-6, -5],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0esg0|ast80|7x9g0|ast80|bmtus0|1tz8c0|2dsw0|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "EST5EDT",
            title: "EST5EDT",
            winIndex: 14,
            offsets: [-5, -4],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0ev80|ast80|7x9g0|ast80|bmtus0|1tzb40|2dq40|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "Etc/GMT",
            title: "GMT",
            winIndex: 41,
            link: 150
        }, {
            id: "Etc/GMT+1",
            title: "GMT+1",
            winIndex: 92,
            offsets: [-1],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+10",
            title: "GMT+10",
            winIndex: 57,
            offsets: [-10],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+11",
            title: "GMT+11",
            winIndex: 49,
            offsets: [-11],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+12",
            title: "GMT+12",
            winIndex: 93,
            offsets: [-12],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+2",
            title: "GMT+2",
            winIndex: 34,
            offsets: [-2],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+3",
            title: "GMT+3",
            winIndex: 64,
            offsets: [-3],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+4",
            title: "GMT+4",
            winIndex: 16,
            offsets: [-4],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+5",
            title: "GMT+5",
            winIndex: 10,
            offsets: [-5],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+6",
            title: "GMT+6",
            winIndex: 67,
            offsets: [-6],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT+7",
            title: "GMT+7",
            winIndex: 56,
            offsets: [-7],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-1",
            title: "GMT-1",
            winIndex: 3,
            offsets: [1],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-10",
            title: "GMT-10",
            winIndex: 50,
            offsets: [10],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-11",
            title: "GMT-11",
            winIndex: 48,
            offsets: [11],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-12",
            title: "GMT-12",
            winIndex: 44,
            offsets: [12],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-13",
            title: "GMT-13",
            winIndex: 94,
            offsets: [13],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-14",
            title: "GMT-14",
            winIndex: 95,
            offsets: [14],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-2",
            title: "GMT-2",
            winIndex: 2,
            offsets: [2],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-3",
            title: "GMT-3",
            winIndex: 1,
            offsets: [3],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-4",
            title: "GMT-4",
            winIndex: 7,
            offsets: [4],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-5",
            title: "GMT-5",
            winIndex: 17,
            offsets: [5],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-6",
            title: "GMT-6",
            winIndex: 21,
            offsets: [6],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-7",
            title: "GMT-7",
            winIndex: 6,
            offsets: [7],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-8",
            title: "GMT-8",
            winIndex: 24,
            offsets: [8],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/GMT-9",
            title: "GMT-9",
            winIndex: 43,
            offsets: [9],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/UCT",
            title: "UCT",
            winIndex: 41,
            offsets: [0],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Etc/UTC",
            title: "UTC",
            winIndex: 41,
            offsets: [0],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Europe/Amsterdam",
            title: "Amsterdam",
            winIndex: 27,
            offsets: [.3255555555555556, 1.3255555555555556, 1.3333333333333333, .3333333333333333, 2, 1],
            offsetIndices: "010101010101010101010101010101010101010101012323234545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545454545",
            untils: "-s0dvkk|7v980|a51o0|7x6o0|a2yo0|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9b6o0|a2yo0|c51c0|6l1c0|902o0|9q000|ci000|682o0|bgyo0|79400|bitc0|779c0|bmio0|7gio0|bbeo0|7eo00|bd9c0|7ctc0|bf400|7ayo0|bvs00|6uao0|bko00|7idc0|b9k00|7gio0|bbeo0|7eo00|bf400|7ayo0|btxc0|21uc0|4uaz8|bitc0|779c0|bko00|7idc0|bd3s0|1aarpc|7k800|9q000|9d1c0|9d1c0|9d1c0|8l9c0|ggp1c0|902o0|9q000|9d1c0|9d1c0|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Andorra",
            title: "Andorra",
            winIndex: 27,
            offsets: [0, 1, 2],
            offsetIndices: "012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-c4xmo0|k3ctg0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Athens",
            title: "Athens",
            winIndex: 4,
            offsets: [1.581111111111111, 2, 3, 1],
            offsetIndices: "012121313121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-rvv0cg|8bjasg|2vmk0|4hiw40|16ik0|scog0|7lx40|9o2k0|9eys0|4atzw0|6djw0|bplus0|bq800|71uw0|9d1c0|902o0|91xc0|9o5c0|905g0|9qgo0|9akg0|9iik0|99980|9dcg0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Belgrade",
            title: "Belgrade",
            winIndex: 60,
            offsets: [1, 2],
            offsetIndices: "01010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-ezayw0|swz00|7k800|9q000|9d1c0|9d1c0|b7pc0|6qlc0|jl1hc0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Berlin",
            title: "Berlin",
            winIndex: 27,
            offsets: [1, 2, 3],
            offsetIndices: "01010101010101210101210101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-s0e080|7ves0|a4yw0|7x6o0|asw00|7x6o0|b8qdc0|1cm000|7k800|9q000|9d1c0|9d1c0|9d1c0|2o7w0|6bs00|2txg0|7k800|91xc0|9b9g0|1sqk0|2inw0|51k40|a2yo0|8n400|9q000|902o0|fx91c0|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Brussels",
            title: "Brussels",
            winIndex: 62,
            offsets: [0, 1, 2],
            offsetIndices: "0121212101010101010101010101010101010101010101010101212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-ss5uo0|rrx80|7vc00|a4yw0|7x6o0|asw00|7x6o0|2wh40|5omo0|b5uo0|6uao0|cyo00|7ayo0|bko00|7rmo0|a2yo0|a2yo0|8n400|902o0|9q000|9d1c0|9d1c0|a2yo0|8n400|9q000|902o0|a2yo0|90b00|a2yo0|8n400|9q000|902o0|a2yo0|8n400|9d1c0|9d1c0|902o0|a2yo0|9d1c0|9d1c0|902o0|9q000|a2yo0|8n400|9d1c0|9d1c0|902o0|9q000|a2yo0|b5uo0|51hc0|4deo0|1a36k0|7k800|9q000|9d1c0|8l9c0|a4tc0|8l9c0|clpc0|79400|fwu800|902o0|9q000|9d1c0|9d1c0|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Bucharest",
            title: "Bucharest",
            winIndex: 4,
            offsets: [1.74, 2, 3],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-k29zi0|fj8m0|6w5c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|kp0dc0|6h980|9q000|905g0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9cvs0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9cyk0|9d440|9cyk0|9q2s0|ast80|7xhs0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Budapest",
            title: "Budapest",
            winIndex: 60,
            offsets: [1, 2],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-s0e080|7ves0|a4yw0|7x6o0|a31g0|8n180|autg0|bgvw0|b5jeg0|th9k0|7k800|9q000|9d1c0|9d1c0|awd00|9ew00|7q0c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9q000|902o0|a4tc0|9q000|1va2g0|6u7w0|bxpg0|6u7w0|cjxg0|64ak0|cluw0|64g40|br3ek0|905g0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Chisinau",
            title: "Chisinau",
            winIndex: 4,
            offsets: [1.9166666666666667, 1.74, 2, 3, 1, 4],
            offsetIndices: "012323232323232323232424235353535353535353535323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-r2p1bo|70f1to|fj8m0|6w5c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|geqo0|ha580|oc8g0|7k800|9q000|9d1c0|7cl00|j3pbw0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|25p80|7kdk0|9d1c0|9d1c0|9cvs0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|ast80|7xf00|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Copenhagen",
            title: "Copenhagen",
            winIndex: 62,
            offsets: [1, 2],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-rzo2w0|75bw0|cbs2w0|1aco80|7k800|9q000|9d1c0|9d1c0|9d1c0|6y000|dbmo0|6bs00|clpc0|51hc0|e1k00|4oio0|giutc0|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Dublin",
            title: "Dublin",
            winIndex: 26,
            offsets: [-.42250000000000004, .5775, 0, 1],
            offsetIndices: "01232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-rzcmlr|6uao0|9pytr|8c000|9o5c0|9ruo0|9b6o0|9ew00|9b6o0|auqo0|88ao0|9ew00|8y800|a2yo0|a2yo0|7k800|asw00|8a5c0|asw00|8n400|a2yo0|8n400|9q000|902o0|afxc0|8n400|a2yo0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|9d1c0|a2yo0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|902o0|a2yo0|b5uo0|51hc0|3g8580|8a840|bvp80|8n6s0|a2yo0|7x6o0|asw00|8n400|9q000|902o0|9q000|9d1c0|9q000|902o0|8n400|9q000|902o0|a2yo0|8n400|afxc0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|902o0|902o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|bitc0|5reo0|1xhuo0|779c0|bitc0|779c0|bitc0|779c0|bitc0|779c0|bitc0|7k800|b5uo0|7k800|b5uo0|7k800|bitc0|779c0|bitc0|779c0|bitc0|7x3w0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|8a5c0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Gibraltar",
            title: "Gibraltar",
            winIndex: 27,
            offsets: [0, 1, 2],
            offsetIndices: "010101010101010101010101010101010101010101010101012121212121010121010101010101010101012121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-rzcns0|6uao0|9q000|8c000|9o5c0|9ruo0|9b6o0|9ew00|9b6o0|auqo0|88ao0|9ew00|8y800|a2yo0|a2yo0|7k800|asw00|8a5c0|asw00|8n400|a2yo0|8n400|9q000|902o0|afxc0|8n400|a2yo0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|9d1c0|a2yo0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|902o0|a2yo0|b5uo0|51hc0|mbmk0|51hc0|c8qo0|6hc00|c8qo0|6uao0|bvs00|8n400|a4tc0|5clc0|4bms0|9q000|902o0|8a5c0|1frw0|64dc0|4bms0|6uao0|bvs00|7x6o0|asw00|8n400|9q000|902o0|9q000|9d1c0|9q000|902o0|8n400|9q000|902o0|a2yo0|8n400|afxc0|8n400|9q000|d0tp80|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Helsinki",
            title: "Helsinki",
            winIndex: 59,
            offsets: [1.6636111111111112, 2, 3],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-peghyd|ax3tqd|9gqo0|k31s80|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Istanbul",
            title: "Istanbul",
            winIndex: 54,
            offsets: [1.948888888888889, 2, 3, 4],
            offsetIndices: "012121212121212121212121212121212121212121212121212121232323232322121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-ux9xew|2wvx6w|7v980|1tjc40|aunw0|88dg0|9et80|8yas0|a2vw0|tzpg0|79180|awo40|7v980|7p25g0|4zjw0|2xms0|f4d80|9vms0|b07w0|19f9g0|9px80|c5440|69uk0|acas0|8n180|a31g0|8n180|9q2s0|8zzw0|a8lg0|8ufw0|a31g0|8ovw0|5mbes0|4dbw0|u3es0|75bw0|2wxus0|7x3w0|asys0|7x3w0|b5xg0|7x3w0|c8w80|7x9g0|7k800|b6080|7jww0|ast80|b9ms0|7tek0|7x9g0|a2vw0|8n6s0|a2vw0|iruk0|8yj40|9rjk0|8lkg0|a4i80|8lkg0|a4i80|f2o40|38l80|t4840|8a5c0|9f4c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9cyk0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7kdk0|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7m2o0|b4000|7k800|b5uo0|7x6o0|asw00|7z1c0|ar1c0|7x6o0|bitc0|779c0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Kaliningrad",
            title: "Kaliningrad",
            winIndex: 96,
            offsets: [1, 2, 3, 4],
            offsetIndices: "0101010101010121232323232323232322121212121212121212121212121212121212121212121",
            untils: "-s0e080|7ves0|a4yw0|7x6o0|asw00|7x6o0|b8qdc0|1cm000|7k800|9q000|9d1c0|9d1c0|4od40|62fw0|9kd80|351g0|ie8nw0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Europe/Kiev",
            title: "Kiev",
            winIndex: 59,
            offsets: [2.0344444444444445, 2, 3, 1, 4],
            offsetIndices: "0121313242424242424242424242121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-nu11ng|37a03g|5vd6k0|kzv40|7k800|9q000|1oyg0|jipzs0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|51ek0|neqw0|9cvs0|9cyk0|9d440|9cyk0|9d440|9cyk0|9dcg0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Lisbon",
            title: "Lisbon",
            winIndex: 26,
            offsets: [-.6125, 0, 1, 2],
            offsetIndices: "012121212121212121212121212121212121212121212321232123212321212121212121212121212121212121212121212121212121212121212121212121212122323232212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-u9rfmr|2bue6r|6zxg0|66580|bq800|73k00|bodc0|71pc0|bq800|73k00|bq800|71pc0|bq800|1b2g00|9b6o0|saio0|8n400|9q000|902o0|a2yo0|902o0|a2yo0|8n400|st1c0|8n400|9d1c0|9d1c0|sg2o0|9d1c0|902o0|9q000|a2yo0|8n400|9d1c0|9d1c0|902o0|9q000|a2yo0|b5uo0|51hc0|bitc0|9d1c0|9ew00|88ao0|25p80|5reo0|3lpg0|779c0|1sqk0|6uao0|38qs0|6uao0|25p80|6hc00|38qs0|6uao0|25p80|6hc00|38qs0|8a5c0|9d1c0|9d9o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|s3400|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|5gyl40|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d440|9cyk0|9d440|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9cyk0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/London",
            title: "London",
            winIndex: 26,
            offsets: [0, 1, 2],
            offsetIndices: "0101010101010101010101010101010101010101010101010121212121210101210101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-rzcns0|6uao0|9q000|8c000|9o5c0|9ruo0|9b6o0|9ew00|9b6o0|auqo0|88ao0|9ew00|8y800|a2yo0|a2yo0|7k800|asw00|8a5c0|asw00|8n400|a2yo0|8n400|9q000|902o0|afxc0|8n400|a2yo0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|9d1c0|a2yo0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|902o0|a2yo0|b5uo0|51hc0|mbmk0|51hc0|c8qo0|6hc00|c8qo0|6uao0|bvs00|8n400|a4tc0|5clc0|4bms0|9q000|902o0|8a5c0|1frw0|64dc0|4bms0|6uao0|bvs00|7x6o0|asw00|8n400|9q000|902o0|9q000|9d1c0|9q000|902o0|8n400|9q000|902o0|a2yo0|8n400|afxc0|8n400|9q000|902o0|a2yo0|8n400|a2yo0|8n400|9q000|902o0|902o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|bitc0|5reo0|1xhuo0|779c0|bitc0|779c0|bitc0|779c0|bitc0|779c0|bitc0|7k800|b5uo0|7k800|b5uo0|7k800|bitc0|779c0|bitc0|779c0|bitc0|7x3w0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|8a5c0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Luxembourg",
            title: "Luxembourg",
            winIndex: 27,
            offsets: [.41000000000000003, 1, 2, 0],
            offsetIndices: "0121212131313131313131313131313131313131313131313131212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-y89550|68l290|75hg0|ast80|796s0|at1k0|7x6o0|3lh40|4zmo0|b6300|6u2c0|cytk0|7at40|bktk0|7rh40|a31g0|a2vw0|8n9k0|8zx40|9q2s0|9et80|9b9g0|a2vw0|8n6s0|9px80|905g0|a2vw0|905g0|a2vw0|8ncc0|9q000|902o0|a2yo0|8n400|9d1c0|9d1c0|902o0|a2yo0|9d1c0|9d1c0|902o0|9q000|a2yo0|8n400|9d1c0|9d1c0|902o0|9q000|a2yo0|b5uo0|51hc0|42ao0|1aeak0|7k800|9q000|9d1c0|8n400|a2yo0|8l9c0|clpc0|79400|fwu800|902o0|9q000|9d1c0|9d1c0|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Madrid",
            title: "Madrid",
            winIndex: 62,
            offsets: [0, 1, 2],
            offsetIndices: "01010101010101010101010121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-rhcqs0|7x6o0|9tpc0|8y800|9b6o0|9gqo0|2d2yo0|8so00|st1c0|8n400|9q000|902o0|a2yo0|902o0|a2yo0|8n400|3zb9c0|6uao0|8so00|9xeo0|a2yo0|902o0|8a5c0|13yt80|69xc0|bq800|8oyo0|a1400|95mo0|9kg00|8n6s0|a2vw0|8oyo0|1ck5c0|7tk40|ct07w0|905g0|a2vw0|8n6s0|8zzw0|9d440|9px80|905g0|9rrw0|9b9g0|9d6w0|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Malta",
            title: "Malta",
            winIndex: 27,
            offsets: [1, 2],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-ryotg0|66800|9d1c0|9d1c0|8a5c0|asw00|7k800|b5uo0|8n400|9d1c0|aau000|18r9k0|7k800|9q000|9d1c0|9d1c0|9d1c0|8j940|9f1k0|afxc0|89zs0|afxc0|7kdk0|b5uo0|979rs0|6h980|cls40|64ak0|cls40|64ak0|cyqs0|64ak0|cls40|64ak0|c8tg0|6hc00|clpc0|6h980|9b9g0|9d1c0|ahs00|7m2o0|b45k0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|asys0|7x3w0|a4w40|8y580|9q2s0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Minsk",
            title: "Minsk",
            winIndex: 96,
            offsets: [1.8333333333333333, 2, 3, 1, 4],
            offsetIndices: "012131312424242424242424242212121212121212121212121212121212121212122",
            untils: "-nu113c|379zjc|5r1mk0|pbf40|7k800|9q000|9d1c0|4oac0|j6dmk0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|sg2o0|9d440|9cvs0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbx40|Infinity"
        }, {
            id: "Europe/Monaco",
            title: "Monaco",
            winIndex: 27,
            offsets: [.15583333333333332, 0, 1, 2],
            offsetIndices: "01212121212121212121212121212121212121212121212121232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-uozn3l|2qx1nl|5luo0|8y800|a4tc0|7vc00|auqo0|7idc0|b7pc0|6sg00|cyo00|7ayo0|bko00|7rmo0|a2yo0|bvs00|6uao0|902o0|9q000|9d1c0|9d1c0|a2yo0|8n400|9q000|902o0|a2yo0|902o0|a2yo0|8n400|9q000|902o0|a2yo0|8n400|9d1c0|9d1c0|902o0|a2yo0|9d1c0|9d1c0|902o0|9q000|a2yo0|8n400|9d1c0|9d1c0|902o0|9q000|a2yo0|b5uo0|51po0|mdbo0|7x3w0|7x9g0|c8w80|7k800|9q000|9d1c0|9nzs0|922w0|8l9c0|fxlx80|9cyk0|9q5k0|902o0|9q000|9d1c0|9d1c0|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Moscow",
            title: "Moscow",
            winIndex: 58,
            offsets: [2.504722222222222, 2.5219444444444443, 3.5219444444444443, 4.521944444444444, 4, 3, 5, 2],
            offsetIndices: "012132345464575454545454545454545455754545454545454545454545454545454545454545",
            untils: "-rx5dmh|ipzua|97hc0|7yyk0|5i840|d9p80|1jpk0|2d2k7|s8o00|1qvw0|8fpc0|1jms0|is040|412as0|qi27w0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|5reo0|3ljw0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Europe/Oslo",
            title: "Oslo",
            winIndex: 27,
            offsets: [1, 2],
            offsetIndices: "010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-rzayo0|6qfs0|cgcqo0|15tsc0|7k800|9q000|9d1c0|9d1c0|9d1c0|9d1c0|70q5c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|b5uo0|7k800|7law00|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Paris",
            title: "Paris",
            winIndex: 62,
            offsets: [.15583333333333332, 0, 1, 2],
            offsetIndices: "0121212121212121212121212121212121212121212121212123232332323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-uozn1x|2qx1lx|5luo0|8y800|a4tc0|7vc00|auqo0|7idc0|b7pc0|6sg00|cyo00|7ayo0|bko00|7rmo0|a2yo0|bvs00|6uao0|902o0|9q000|9d1c0|9d1c0|a2yo0|8n400|9q000|902o0|a2yo0|902o0|a2yo0|8n400|9q000|902o0|a2yo0|8n400|9d1c0|9d1c0|902o0|a2yo0|9d1c0|9d1c0|902o0|9q000|a2yo0|8n400|9d1c0|9d1c0|902o0|9q000|a2yo0|b5uo0|51po0|5p8w0|18rcc0|7k800|9q000|9d1c0|7efo0|29k40|922w0|8l9c0|fxlx80|9cyk0|9q5k0|902o0|9q000|9d1c0|9d1c0|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Prague",
            title: "Prague",
            winIndex: 60,
            offsets: [1, 2],
            offsetIndices: "010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-s0e080|7ves0|a4yw0|7x6o0|asw00|7x6o0|b8qdc0|1cm000|7k800|9q000|9d1c0|8l9c0|afxc0|bitc0|8oyo0|7vc00|a2yo0|8n400|a2yo0|8n400|9o5c0|91xc0|fe6000|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Riga",
            title: "Riga",
            winIndex: 59,
            offsets: [1.6094444444444445, 2.6094444444444442, 2, 3, 1, 4],
            offsetIndices: "010102324242435353535353535353323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-qznlky|7x6o0|a4tc0|2mg00|3myns0|7fhlky|gz180|p5v40|7k800|9q000|9d1c0|9d1c0|k7s0|j14ns0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d440|asw00|7x6o0|asw00|7x6o0|b5uo0|qaao0|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Rome",
            title: "Rome",
            winIndex: 27,
            offsets: [1, 2],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-ryotg0|66800|9d1c0|9d1c0|8a5c0|asw00|7k800|b5uo0|8n400|9d1c0|aau000|18r9k0|7k800|9q000|9d1c0|8l3s0|a4yw0|8j940|9f1k0|afxc0|89zs0|afxc0|7kdk0|b5uo0|979rs0|6h980|cls40|64ak0|cls40|64ak0|cyqs0|64ak0|cls40|64ak0|c8tg0|6hc00|clpc0|6h980|cls40|64ak0|c8tg0|6h980|cls40|64dc0|clpc0|64dc0|c8qo0|6hc00|clpc0|6hc00|c8qo0|6hc00|9q5k0|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Samara",
            title: "Samara",
            winIndex: 58,
            offsets: [3.338888888888889, 3, 4, 5],
            offsetIndices: "012232323232323232322121112323232323232323232323232323232323232212",
            untils: "-qcx7pw|5q63dw|2egvw0|o3lc00|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9q000|9d1c0|9d440|12w00|89zs0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5xg0|7k800|Infinity"
        }, {
            id: "Europe/Simferopol",
            title: "Simferopol",
            winIndex: 58,
            offsets: [2.2666666666666666, 2, 3, 1, 4],
            offsetIndices: "012131312424242424242424242121212424242212121212121212121212121212121212142",
            untils: "-nu12ao|37a0qo|5xiyk0|iu340|7k800|9q000|9d1c0|iac0|jajmk0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|eeio0|wrjw0|9cyk0|9d440|9cyk0|9d440|1sqk0|7k580|9d440|9cyk0|9q2s0|at4c0|7x9g0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x3w0|asqg0|Infinity"
        }, {
            id: "Europe/Sofia",
            title: "Sofia",
            winIndex: 59,
            offsets: [2, 1, 3],
            offsetIndices: "01010102020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020",
            untils: "-e6dzw0|7k800|9q000|9d1c0|9d1c0|9d440|hqq240|9eys0|9o2k0|92040|9o2k0|90880|9pug0|90b00|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9cvs0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|ast80|7xhs0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Stockholm",
            title: "Stockholm",
            winIndex: 27,
            offsets: [1, 2],
            offsetIndices: "01010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-rzo2w0|75hg0|x5bew0|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Tallinn",
            title: "Tallinn",
            winIndex: 59,
            offsets: [1.65, 1, 2, 3, 4],
            offsetIndices: "012102321212343434343434343433232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232",
            untils: "-r3exx0|3re10|7x6o0|et6g0|ygov0|a1zgd0|ktx80|l94g0|7k800|9q000|9d1c0|8uac0|j27mk0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asys0|7x6o0|b5uo0|19dc00|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Tirane",
            title: "Tirane",
            winIndex: 60,
            offsets: [1.3222222222222222, 1, 2],
            offsetIndices: "01212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-t85vo8|dt2gw8|18pew0|7k800|m800|g7ot40|7rjw0|autg0|7x3w0|ayis0|7x3w0|b5xg0|7k580|b42s0|7lzw0|b42s0|7lzw0|b42s0|7x3w0|ahus0|7x3w0|b5xg0|7x3w0|a4w40|8jbw0|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Uzhgorod",
            title: "Uzhgorod",
            winIndex: 59,
            offsets: [1, 2, 3, 4],
            offsetIndices: "010101023232323232323232320121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-fizzw0|1cm000|7k800|9q000|9d1c0|al900|cnms0|int140|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|eeio0|e1sc0|iprk0|9cyk0|9d440|9cyk0|9d440|9cyk0|9dcg0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Vienna",
            title: "Vienna",
            winIndex: 27,
            offsets: [1, 2],
            offsetIndices: "0101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-s0e080|7ves0|a4yw0|7x6o0|asw00|7x6o0|t6000|8a5c0|a7a800|1cm000|7k800|9q000|9d1c0|9d1c0|9d1c0|iio0|ivmo0|902o0|9d1c0|9d1c0|a2yo0|8n400|gfyyg0|8zzw0|9d9o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Vilnius",
            title: "Vilnius",
            winIndex: 59,
            offsets: [1.4, 1.5933333333333333, 1, 2, 3, 4],
            offsetIndices: "012324323234545454545454545443434343434343434332334343434343434343434343434343434343434343434343434343434343434343434343",
            untils: "-rns980|1g224o|e75nc|4kqk0|acbs40|gpp40|pits0|7k800|9q000|9d1c0|65zo0|j4vx80|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x9g0|asw00|7x6o0|b5uo0|1s3eo0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Volgograd",
            title: "Volgograd",
            winIndex: 58,
            offsets: [2.961111111111111, 3, 4, 5],
            offsetIndices: "011223232323232323221212122121212121212121212121212121212121212121",
            untils: "-q3cw84|2qrjw4|2pu800|gdt980|a48yo0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9d1c0|9d1c0|9q000|9d1c0|ipzw0|9d440|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|1vbzw0|Infinity"
        }, {
            id: "Europe/Warsaw",
            title: "Warsaw",
            winIndex: 51,
            offsets: [1.4, 1, 2, 3],
            offsetIndices: "012121223212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-se9yk0|dvyc0|7ves0|a4yw0|7x6o0|asw00|7x6o0|aunw0|7x6o0|1evbs0|9fcwc0|18cao0|7k800|9q000|9d1c0|9gnw0|an980|9kd80|8fs40|922w0|ar1c0|7x6o0|a2yo0|8n400|9q000|902o0|4013w0|64dc0|9d1c0|9d1c0|clpc0|6hc00|9d1c0|9d1c0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|clpc0|64dc0|6j4tc0|902o0|9q000|9d1c0|9d1c0|9d1c0|9q000|902o0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d440|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Zaporozhye",
            title: "Zaporozhye",
            winIndex: 59,
            offsets: [2.3333333333333335, 2, 3, 1, 4],
            offsetIndices: "01213132424242424242424242422121212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121",
            untils: "-nu12hc|37a0xc|5u1180|mc0g0|7k800|9q000|12qg0|jjc7s0|9et80|9d440|9et80|9d440|9et80|9eys0|9d6w0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9cvs0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9dcg0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Europe/Zurich",
            title: "Zurich",
            winIndex: 27,
            offsets: [1, 2],
            offsetIndices: "01010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-eyh6o0|7x6o0|asw00|7x6o0|k2zus0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9d1c0|9q000|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|7x6o0|b5uo0|7k800|b5uo0|7k800|b5uo0|7k800|b5uo0|7x6o0|asw00|7x6o0|asw00|Infinity"
        }, {
            id: "Indian/Chagos",
            title: "Chagos",
            winIndex: 21,
            offsets: [4.827777777777778, 5, 6],
            offsetIndices: "012",
            untils: "-wvpc2s|1ag64us|Infinity"
        }, {
            id: "Indian/Christmas",
            title: "Christmas",
            winIndex: 6,
            offsets: [7],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Indian/Cocos",
            title: "Cocos",
            winIndex: 87,
            offsets: [6.5],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Indian/Kerguelen",
            title: "Kerguelen",
            winIndex: 17,
            offsets: [0, 5],
            offsetIndices: "01",
            untils: "-afrs00|Infinity"
        }, {
            id: "Indian/Mahe",
            title: "Mahe",
            winIndex: 97,
            offsets: [3.6966666666666668, 4],
            offsetIndices: "01",
            untils: "-x6pjlo|Infinity"
        }, {
            id: "Indian/Maldives",
            title: "Maldives",
            winIndex: 17,
            offsets: [4.9, 5],
            offsetIndices: "01",
            untils: "-57x6y0|Infinity"
        }, {
            id: "Indian/Mauritius",
            title: "Mauritius",
            winIndex: 97,
            offsets: [3.8333333333333335, 4, 5],
            offsetIndices: "012121",
            untils: "-wvp9bc|13jnu7c|8bx80|dd0wc0|7x3w0|Infinity"
        }, {
            id: "Indian/Reunion",
            title: "Reunion",
            winIndex: 97,
            offsets: [3.697777777777778, 4],
            offsetIndices: "01",
            untils: "-uks29s|Infinity"
        }, {
            id: "MST7MDT",
            title: "MST7MDT",
            winIndex: 15,
            offsets: [-7, -6],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0epo0|ast80|7x9g0|ast80|bmtus0|1tz5k0|2dvo0|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }, {
            id: "Pacific/Apia",
            title: "Apia",
            winIndex: 98,
            offsets: [-11.448888888888888, -11.5, -11, -10, 14, 13],
            offsetIndices: "01232345454545454545454545454545454545454545454545454545454",
            untils: "-usiiv4|kcrmt4|vp3la0|9odo0|902o0|4zbk0|4qog0|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|a2yo0|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|Infinity"
        }, {
            id: "Pacific/Auckland",
            title: "Auckland",
            winIndex: 8,
            offsets: [11.5, 12.5, 12, 13],
            offsetIndices: "01020202020202020202020202023232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323232323",
            untils: "-m01p20|64ak0|biw40|7x5a0|asxe0|7x5a0|asxe0|7x5a0|asxe0|8a3y0|afyq0|8a3y0|afyq0|afvy0|7x820|asum0|7x820|asum0|7x820|asum0|7x820|asum0|7x820|b5ta0|7k9e0|b5ta0|7x820|hsl2m0|5reo0|clpc0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6hc00|c8qo0|6uao0|c8qo0|6hc00|b5uo0|8a5c0|afxc0|8a5c0|afxc0|8a5c0|afxc0|8n400|a2yo0|8n400|a2yo0|8n400|a2yo0|8n400|afxc0|8a5c0|afxc0|8a5c0|afxc0|8n400|a2yo0|8n400|a2yo0|8n400|afxc0|8a5c0|afxc0|8a5c0|afxc0|8n400|a2yo0|8n400|a2yo0|8n400|a2yo0|8n400|a2yo0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|a2yo0|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|902o0|9q000|9d1c0|9q000|902o0|9q000|902o0|Infinity"
        }, {
            id: "Pacific/Chuuk",
            title: "Chuuk",
            winIndex: 50,
            offsets: [10],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Pacific/Efate",
            title: "Efate",
            winIndex: 48,
            offsets: [11.22111111111111, 11, 12],
            offsetIndices: "0121212121212121212121",
            untils: "-u964i4|11f4ba4|9cyk0|awo40|7tek0|9q2s0|8zzw0|9q2s0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9q2s0|64ak0|e1ms0|4ofw0|Infinity"
        }, {
            id: "Pacific/Enderbury",
            title: "Enderbury",
            winIndex: 94,
            offsets: [-12, -11, 13],
            offsetIndices: "012",
            untils: "535io0|7ykl80|Infinity"
        }, {
            id: "Pacific/Fakaofo",
            title: "Fakaofo",
            winIndex: 94,
            offsets: [-11, 13],
            offsetIndices: "01",
            untils: "lx0jw0|Infinity"
        }, {
            id: "Pacific/Fiji",
            title: "Fiji",
            winIndex: 99,
            offsets: [11.928888888888888, 12, 13],
            offsetIndices: "0121212121212121212121212121212121212121212121212121212121212121",
            untils: "-sa2x4w|17bs00w|64dc0|cyo00|5reo0|53a5c0|64dc0|asw00|6uao0|bvs00|4oio0|e1k00|4oio0|eeio0|4bh80|erk40|3ylc0|erhc0|3ylc0|f4g00|3lmo0|f4g00|3ylc0|erhc0|3ylc0|erhc0|3ylc0|erhc0|3ylc0|f4g00|3lmo0|f4g00|3lmo0|f4g00|3ylc0|erhc0|3ylc0|erhc0|3ylc0|erhc0|3ylc0|f4g00|3lmo0|f4g00|3ylc0|erhc0|3ylc0|erhc0|3ylc0|erhc0|3ylc0|f4g00|3lmo0|f4g00|3lmo0|f4g00|3ylc0|erhc0|3ylc0|erhc0|3ylc0|erhc0|3ylc0|Infinity"
        }, {
            id: "Pacific/Funafuti",
            title: "Funafuti",
            winIndex: 44,
            offsets: [12],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Pacific/Galapagos",
            title: "Galapagos",
            winIndex: 67,
            offsets: [-5.973333333333333, -5, -6],
            offsetIndices: "012",
            untils: "-kcr62o|spdryo|Infinity"
        }, {
            id: "Pacific/Guadalcanal",
            title: "Guadalcanal",
            winIndex: 48,
            offsets: [10.663333333333332, 11],
            offsetIndices: "01",
            untils: "-tvowac|Infinity"
        }, {
            id: "Pacific/Guam",
            title: "Guam",
            winIndex: 50,
            offsets: [10],
            offsetIndices: "00",
            untils: "g5z2w0|Infinity"
        }, {
            id: "Pacific/Honolulu",
            title: "Honolulu",
            winIndex: 57,
            offsets: [-10.5, -9.5, -10],
            offsetIndices: "010102",
            untils: "-j50la0|13l00|4jvb00|1wd180|votg0|Infinity"
        }, {
            id: "Pacific/Kiritimati",
            title: "Kiritimati",
            winIndex: 95,
            offsets: [-10.666666666666666, -10, 14],
            offsetIndices: "012",
            untils: "535eyo|7ykm5c|Infinity"
        }, {
            id: "Pacific/Kosrae",
            title: "Kosrae",
            winIndex: 48,
            offsets: [11, 12],
            offsetIndices: "010",
            untils: "-4r7w0|f9l3w0|Infinity"
        }, {
            id: "Pacific/Kwajalein",
            title: "Kwajalein",
            winIndex: 44,
            offsets: [11, -12, 12],
            offsetIndices: "012",
            untils: "-4r7w0|cgtbw0|Infinity"
        }, {
            id: "Pacific/Majuro",
            title: "Majuro",
            winIndex: 44,
            offsets: [11, 12],
            offsetIndices: "01",
            untils: "-4r7w0|Infinity"
        }, {
            id: "Pacific/Midway",
            title: "Midway",
            winIndex: 49,
            link: 530
        }, {
            id: "Pacific/Nauru",
            title: "Nauru",
            winIndex: 44,
            offsets: [11.127777777777776, 11.5, 9, 12],
            offsetIndices: "01213",
            untils: "-pjxiws|b1kxms|19h8a0|i43qe0|Infinity"
        }, {
            id: "Pacific/Niue",
            title: "Niue",
            winIndex: 49,
            offsets: [-11.333333333333334, -11.5, -11],
            offsetIndices: "012",
            untils: "-9wyz6o|ehcj4o|Infinity"
        }, {
            id: "Pacific/Noumea",
            title: "Noumea",
            winIndex: 48,
            offsets: [11.096666666666666, 11, 12],
            offsetIndices: "01212121",
            untils: "-u9645o|ye0ixo|4dbw0|ecqs0|4f6k0|99p700|4oio0|Infinity"
        }, {
            id: "Pacific/Pago_Pago",
            title: "Pago Pago",
            winIndex: 49,
            offsets: [-11.379999999999999, -11],
            offsetIndices: "0111",
            untils: "-usij20|tcsey0|8p4800|Infinity"
        }, {
            id: "Pacific/Palau",
            title: "Palau",
            winIndex: 43,
            offsets: [9],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Pacific/Pohnpei",
            title: "Pohnpei",
            winIndex: 48,
            offsets: [11],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Pacific/Port_Moresby",
            title: "Port Moresby",
            winIndex: 50,
            offsets: [10],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Pacific/Rarotonga",
            title: "Rarotonga",
            winIndex: 57,
            offsets: [-10.5, -9.5, -10],
            offsetIndices: "012121212121212121212121212",
            untils: "4mj960|5rbw0|c8s20|6ham0|c8s20|6ham0|c8s20|6u9a0|c8s20|6ham0|c8s20|6ham0|c8s20|6ham0|c8s20|6ham0|c8s20|6ham0|c8s20|6u9a0|c8s20|6ham0|c8s20|6ham0|c8s20|6ham0|Infinity"
        }, {
            id: "Pacific/Saipan",
            title: "Saipan",
            winIndex: 50,
            link: 520
        }, {
            id: "Pacific/Tahiti",
            title: "Tahiti",
            winIndex: 57,
            offsets: [-9.97111111111111, -10],
            offsetIndices: "01",
            untils: "-tvnayw|Infinity"
        }, {
            id: "Pacific/Tarawa",
            title: "Tarawa",
            winIndex: 44,
            offsets: [12],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Pacific/Tongatapu",
            title: "Tongatapu",
            winIndex: 94,
            offsets: [12.333333333333334, 13, 14],
            offsetIndices: "01212121",
            untils: "-f4vrlc|uo2edc|8fpc0|bvs00|4bh80|eelg0|4bh80|Infinity"
        }, {
            id: "Pacific/Wake",
            title: "Wake",
            winIndex: 44,
            offsets: [12],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "Pacific/Wallis",
            title: "Wallis",
            winIndex: 44,
            offsets: [12],
            offsetIndices: "0",
            untils: "Infinity"
        }, {
            id: "PST8PDT",
            title: "PST8PDT",
            winIndex: 11,
            offsets: [-8, -7],
            offsetIndices: "010101101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010",
            untils: "-r0emw0|ast80|7x9g0|ast80|bmtus0|1tz2s0|2dyg0|b9gdg0|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|9d440|9cyk0|9d440|9cyk0|3lpg0|f4d80|64g40|clmk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|9d440|9px80|905g0|9px80|9d440|9cyk0|9d440|9cyk0|9d440|9cyk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|8a840|afuk0|8a840|afuk0|8a840|ast80|7x9g0|ast80|7x9g0|ast80|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6udg0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|6hes0|c8nw0|Infinity"
        }];
        module.exports = {
            displayNames: displayNames,
            timezones: timezones
        }
    },
    /*!******************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointment_tooltip.js ***!
      \******************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Tooltip = __webpack_require__( /*! ../tooltip */ 303),
            tooltip = __webpack_require__( /*! ../tooltip/ui.tooltip */ 305),
            Button = __webpack_require__( /*! ../button */ 196),
            FunctionTemplate = __webpack_require__( /*! ../widget/ui.template.function */ 97),
            DynamicTemplate = __webpack_require__( /*! ../widget/ui.template.dynamic */ 91),
            MoveTemplate = __webpack_require__( /*! ../widget/ui.template.move */ 93),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52);
        var APPOINTMENT_TOOLTIP_CLASS = "dx-scheduler-appointment-tooltip",
            APPOINTMENT_TOOLTIP_TITLE_CLASS = "dx-scheduler-appointment-tooltip-title",
            APPOINTMENT_TOOLTIP_DATE_CLASS = "dx-scheduler-appointment-tooltip-date",
            APPOINTMENT_TOOLTIP_BUTTONS_CLASS = "dx-scheduler-appointment-tooltip-buttons";
        var appointmentTooltip = {
            show: function(appointmentData, singleAppointmentData, $appointment, instance) {
                if (this._tooltip) {
                    if (this._tooltip.option("visible") && this._tooltip.option("target").get(0) === $appointment.get(0)) {
                        return
                    }
                }
                this.instance = instance;
                var isAllDay = instance.appointmentTakesAllDay(appointmentData);
                this._initDynamicTemplate(appointmentData, singleAppointmentData);
                var template = instance._getTemplateByOption("appointmentTooltipTemplate");
                this.hide();
                this._$tooltip = $("<div>").appendTo(instance.element());
                this._tooltip = instance._createComponent(this._$tooltip, Tooltip, {
                    visible: true,
                    target: $appointment,
                    rtlEnabled: instance.option("rtlEnabled"),
                    contentTemplate: new DynamicTemplate(function(options) {
                        return new MoveTemplate(template.render({
                            model: appointmentData,
                            container: options.container
                        }))
                    }),
                    position: {
                        my: "bottom",
                        at: "top",
                        of: $appointment,
                        boundary: isAllDay ? instance.element() : instance.getWorkSpaceScrollableContainer(),
                        collision: "fit flipfit"
                    }
                })
            },
            hide: function() {
                if (!this._$tooltip) {
                    return
                }
                this._$tooltip.remove();
                delete this._$tooltip;
                delete this._tooltip;
                tooltip.hide()
            },
            _initDynamicTemplate: function(appointmentData, singleAppointmentData) {
                var that = this;
                this.instance._dynamicTemplates.appointmentTooltip = new FunctionTemplate(function(data, index, $container) {
                    var $tooltip = that._tooltipContent(appointmentData, singleAppointmentData);
                    $tooltip.addClass($container.attr("class"));
                    $container.replaceWith($tooltip);
                    return $container
                })
            },
            _tooltipContent: function(appointmentData, singleAppointmentData) {
                var $tooltip = $("<div>").addClass(APPOINTMENT_TOOLTIP_CLASS);
                var isAllDay = this.instance.fire("getField", "allDay", appointmentData),
                    startDate = this.instance.fire("getField", "startDate", singleAppointmentData),
                    endDate = this.instance.fire("getField", "endDate", singleAppointmentData),
                    text = this.instance.fire("getField", "text", appointmentData),
                    startDateTimeZone = this.instance.fire("getField", "startDateTimeZone", appointmentData),
                    endDateTimeZone = this.instance.fire("getField", "endDateTimeZone", appointmentData);
                startDate = this.instance.fire("convertDateByTimezone", startDate, startDateTimeZone);
                endDate = this.instance.fire("convertDateByTimezone", endDate, endDateTimeZone);
                $("<div>").text(text).addClass(APPOINTMENT_TOOLTIP_TITLE_CLASS).appendTo($tooltip);
                $("<div>").addClass(APPOINTMENT_TOOLTIP_DATE_CLASS).text(this._formatTooltipDate(startDate, endDate, isAllDay)).appendTo($tooltip);
                var $buttons = $("<div>").addClass(APPOINTMENT_TOOLTIP_BUTTONS_CLASS).appendTo($tooltip);
                if (this.instance._editing.allowDeleting) {
                    this._getDeleteButton(appointmentData, singleAppointmentData).appendTo($buttons)
                }
                this._getOpenButton(appointmentData, singleAppointmentData).appendTo($buttons);
                return $tooltip
            },
            _formatTooltipDate: function(startDate, endDate, isAllDay) {
                var formatType = "month" !== this.instance.option("currentView") && dateUtils.sameDate(startDate, endDate) ? "TIME" : "DATETIME",
                    formattedString = "";
                if (isAllDay) {
                    formatType = "DATE"
                }
                this.instance.fire("formatDates", {
                    startDate: startDate,
                    endDate: endDate,
                    formatType: formatType,
                    callback: function(result) {
                        formattedString = result
                    }
                });
                return formattedString
            },
            _getDeleteButton: function(appointmentData, singleAppointmentData) {
                var that = this;
                return new Button($("<div>"), {
                    icon: "trash",
                    onClick: function() {
                        var startDate = that.instance.fire("getField", "startDate", singleAppointmentData);
                        that.instance._checkRecurringAppointment(appointmentData, singleAppointmentData, startDate, function() {
                            that.instance.deleteAppointment(appointmentData)
                        }, true);
                        that.hide()
                    }
                }).element()
            },
            _getOpenButton: function(appointmentData, singleAppointmentData) {
                var that = this,
                    allowUpdating = that.instance._editing.allowUpdating;
                return new Button($("<div>"), {
                    icon: allowUpdating ? "edit" : "",
                    text: messageLocalization.format("dxScheduler-openAppointment"),
                    onClick: function() {
                        that.instance.showAppointmentPopup(appointmentData, false, singleAppointmentData);
                        that.hide()
                    }
                }).element()
            }
        };
        module.exports = appointmentTooltip
    },
    /*!*****************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.header.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            camelize = __webpack_require__( /*! ../../core/utils/inflector */ 49).camelize,
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            publisherMixin = __webpack_require__( /*! ./ui.scheduler.publisher_mixin */ 410),
            SchedulerNavigator = __webpack_require__( /*! ./ui.scheduler.navigator */ 411),
            DropDownMenu = __webpack_require__( /*! ../drop_down_menu */ 272),
            Tabs = __webpack_require__( /*! ../tabs */ 284),
            errors = __webpack_require__( /*! ../../core/errors */ 17),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80);
        var COMPONENT_CLASS = "dx-scheduler-header",
            VIEW_SWITCHER_CLASS = "dx-scheduler-view-switcher",
            VIEW_SWITCHER_LABEL_CLASS = "dx-scheduler-view-switcher-label";
        var STEP_MAP = {
            day: "day",
            week: "week",
            workWeek: "workWeek",
            month: "month",
            timelineDay: "day",
            timelineWeek: "week",
            timelineWorkWeek: "workWeek",
            timelineMonth: "month",
            agenda: "agenda"
        };
        var VIEWS = ["day", "week", "workWeek", "month", "timelineDay", "timelineWeek", "timelineWorkWeek", "timelineMonth", "agenda"];
        var SchedulerHeader = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    views: [],
                    currentView: "day",
                    firstDayOfWeek: void 0,
                    currentDate: new Date,
                    min: void 0,
                    max: void 0,
                    useDropDownViewSwitcher: false
                })
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "views":
                        var currentView = this.option("currentView");
                        this._viewSwitcher.option({
                            items: value,
                            selectedItem: currentView
                        });
                        break;
                    case "currentView":
                        this._viewSwitcher.option("selectedItem", value);
                        this._navigator.option("step", STEP_MAP[value]);
                        this._changeViewSwitcherLabelText();
                        break;
                    case "currentDate":
                        this._navigator.option("date", value);
                        break;
                    case "min":
                    case "max":
                    case "firstDayOfWeek":
                        this._navigator.option(args.name, value);
                        break;
                    case "tabIndex":
                    case "focusStateEnabled":
                        this._viewSwitcher.option(args.name, value);
                        this._navigator.option(args.name, value);
                        this.callBase(args);
                        break;
                    case "useDropDownViewSwitcher":
                        this._refreshViewSwitcher();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _init: function() {
                this.callBase();
                this.element().addClass(COMPONENT_CLASS)
            },
            _render: function() {
                this.callBase();
                this._renderNavigator();
                this._renderViewSwitcher()
            },
            _renderNavigator: function() {
                this._navigator = this._createComponent("<div>", SchedulerNavigator, {
                    min: this.option("min"),
                    max: this.option("max"),
                    date: this.option("currentDate"),
                    step: STEP_MAP[this.option("currentView")],
                    firstDayOfWeek: this.option("firstDayOfWeek"),
                    tabIndex: this.option("tabIndex"),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    observer: this.option("observer")
                });
                this._navigator.element().appendTo(this.element())
            },
            _renderViewSwitcher: function() {
                this._validateViews();
                var $viewSwitcher = $("<div>").addClass(VIEW_SWITCHER_CLASS).appendTo(this.element());
                if (!this.option("useDropDownViewSwitcher")) {
                    this._renderViewSwitcherTabs($viewSwitcher)
                } else {
                    this._renderViewSwitcherDropDownMenu($viewSwitcher)
                }
            },
            _validateViews: function() {
                var views = this.option("views");
                $.each(views, function(_, viewName) {
                    if ($.inArray(viewName, VIEWS) === -1) {
                        errors.log("W0008", viewName)
                    }
                })
            },
            _renderViewSwitcherTabs: function($element) {
                this._viewSwitcher = this._createComponent($element, Tabs, {
                    selectionRequired: true,
                    scrollingEnabled: true,
                    onSelectionChanged: $.proxy(this._updateCurrentView, this),
                    items: this.option("views"),
                    itemTemplate: function(item) {
                        return $("<span>").addClass("dx-tab-text").text(messageLocalization.format("dxScheduler-switcher" + camelize(item, true)))
                    },
                    selectedItem: this.option("currentView"),
                    tabIndex: this.option("tabIndex"),
                    focusStateEnabled: this.option("focusStateEnabled")
                })
            },
            _refreshViewSwitcher: function() {
                this._viewSwitcher._dispose();
                this._viewSwitcher.element().remove();
                delete this._viewSwitcher;
                this._removeViewSwitcherLabel();
                this._renderViewSwitcher()
            },
            _removeViewSwitcherLabel: function() {
                if (commonUtils.isDefined(this._$viewSwitcherLabel)) {
                    this._$viewSwitcherLabel.detach();
                    this._$viewSwitcherLabel.remove();
                    delete this._$viewSwitcherLabel
                }
            },
            _renderViewSwitcherDropDownMenu: function($element) {
                this._$viewSwitcherLabel = $("<div>").addClass(VIEW_SWITCHER_LABEL_CLASS).appendTo(this.element());
                this._changeViewSwitcherLabelText();
                this._viewSwitcher = this._createComponent($element, DropDownMenu, {
                    onItemClick: $.proxy(this._updateCurrentView, this),
                    items: this.option("views"),
                    itemTemplate: function(item) {
                        return $("<span>").addClass("dx-dropdownmenu-item-text").text(messageLocalization.format("dxScheduler-switcher" + camelize(item, true)))
                    }
                })
            },
            _changeViewSwitcherLabelText: function() {
                if (!commonUtils.isDefined(this._$viewSwitcherLabel)) {
                    return
                }
                var currentViewText = messageLocalization.format("dxScheduler-switcher" + camelize(this.option("currentView"), true));
                this._$viewSwitcherLabel.text(currentViewText)
            },
            _updateCurrentView: function(e) {
                var selectedItem = e.itemData || e.component.option("selectedItem");
                this.notifyObserver("currentViewUpdated", selectedItem)
            },
            _renderFocusTarget: $.noop
        }).include(publisherMixin);
        registerComponent("dxSchedulerHeader", SchedulerHeader);
        module.exports = SchedulerHeader
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.publisher_mixin.js ***!
      \**************************************************************/
    function(module, exports) {
        var publisherMixin = {
            notifyObserver: function(subject, args) {
                var observer = this.option("observer");
                if (observer) {
                    observer.fire(subject, args)
                }
            },
            invoke: function() {
                var observer = this.option("observer");
                if (observer) {
                    return observer.fire.apply(observer, arguments)
                }
            }
        };
        module.exports = publisherMixin
    },
    /*!********************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.navigator.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            Button = __webpack_require__( /*! ../button */ 196),
            Calendar = __webpack_require__( /*! ../calendar */ 246),
            Popover = __webpack_require__( /*! ../popover */ 202),
            Popup = __webpack_require__( /*! ../popup */ 195),
            publisherMixin = __webpack_require__( /*! ./ui.scheduler.publisher_mixin */ 410),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var ELEMENT_CLASS = "dx-scheduler-navigator",
            CALENDAR_CLASS = "dx-scheduler-navigator-calendar",
            NEXT_BUTTON_CLASS = "dx-scheduler-navigator-next",
            CAPTION_BUTTON_CLASS = "dx-scheduler-navigator-caption",
            PREVIOUS_BUTTON_CLASS = "dx-scheduler-navigator-previous",
            MONDAY_INDEX = 1;
        var getDefaultFirstDayOfWeekIndex = function(shift) {
            return shift ? MONDAY_INDEX : dateLocalization.firstDayOfWeekIndex()
        };
        var getCaptionFormat = function(short) {
            return function(date) {
                var monthName = dateLocalization.getMonthNames(short ? "abbreviated" : "wide")[[date.getMonth()]];
                return [dateLocalization.format(date, "day"), monthName, dateLocalization.format(date, "year")].join(" ")
            }
        };
        var getWeekCaption = function(date, shift, rejectWeekend) {
            var firstWeekDate = dateUtils.getFirstWeekDate(date, this.option("firstDayOfWeek") || getDefaultFirstDayOfWeekIndex(shift)),
                format = getCaptionFormat(this.option("_useShortDateFormat")),
                weekendDuration = 2;
            if (rejectWeekend) {
                firstWeekDate = dateUtils.normalizeDateByWeek(firstWeekDate, date)
            }
            if (this.option("firstDayOfWeek") >= 6 && rejectWeekend) {
                firstWeekDate.setDate(firstWeekDate.getDate() + (7 - this.option("firstDayOfWeek") + 1))
            }
            var lastWeekDate = new Date(firstWeekDate);
            shift = shift || 6;
            lastWeekDate = new Date(lastWeekDate.setDate(lastWeekDate.getDate() + shift));
            if (lastWeekDate.getDay() % 6 === 0 && rejectWeekend) {
                lastWeekDate.setDate(lastWeekDate.getDate() + weekendDuration)
            }
            return dateLocalization.format(firstWeekDate, "d") + "-" + dateLocalization.format(lastWeekDate, format)
        };
        var dateGetter = function(date, offset) {
            return new Date(date[this.setter](date[this.getter]() + offset))
        };
        var CONFIG = {
            day: {
                duration: 1,
                setter: "setDate",
                getter: "getDate",
                getDate: dateGetter,
                getCaption: getCaptionFormat()
            },
            week: {
                duration: 7,
                setter: "setDate",
                getter: "getDate",
                getDate: dateGetter,
                getCaption: getWeekCaption
            },
            workWeek: {
                duration: 7,
                setter: "setDate",
                getter: "getDate",
                getDate: dateGetter,
                getCaption: function(date) {
                    return getWeekCaption.call(this, date, 4, true)
                }
            },
            month: {
                duration: 1,
                setter: "setMonth",
                getter: "getMonth",
                getDate: function(date, offset) {
                    var currentDate = date.getDate();
                    date.setDate(1);
                    date = dateGetter.call(this, date, offset);
                    var lastDate = dateUtils.getLastMonthDay(date);
                    date.setDate(currentDate < lastDate ? currentDate : lastDate);
                    return date
                },
                getCaption: function(date) {
                    return dateLocalization.format(date, "monthandyear")
                }
            },
            agenda: {
                duration: 7,
                setter: "setDate",
                getter: "getDate",
                getDate: dateGetter,
                getCaption: function(date) {
                    var lastDate = new Date(date),
                        format = getCaptionFormat(this.option("_useShortDateFormat"));
                    lastDate.setDate(lastDate.getDate() + 7);
                    return dateLocalization.format(date, "d") + "-" + dateLocalization.format(lastDate, format)
                }
            }
        };
        var SchedulerNavigator = Widget.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    date: new Date,
                    step: "day",
                    min: void 0,
                    max: void 0,
                    firstDayOfWeek: void 0,
                    _useShortDateFormat: false
                })
            },
            _defaultOptionsRules: function() {
                return this.callBase().concat([{
                    device: function(device) {
                        return !devices.real().generic || devices.isSimulator()
                    },
                    options: {
                        _useShortDateFormat: true
                    }
                }])
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "step":
                    case "date":
                        this._updateButtonsState();
                        this._renderCaption();
                        this._setCalendarOption("value", this.option("date"));
                        break;
                    case "min":
                    case "max":
                        this._updateButtonsState();
                        this._setCalendarOption(args.name, args.value);
                        break;
                    case "firstDayOfWeek":
                        this._setCalendarOption(args.name, args.value);
                        break;
                    case "tabIndex":
                    case "focusStateEnabled":
                        this._next.option(args.name, args.value);
                        this._caption.option(args.name, args.value);
                        this._prev.option(args.name, args.value);
                        this._setCalendarOption(args.name, args.value);
                        this.callBase(args);
                        break;
                    case "_useShortDateFormat":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _init: function() {
                this.callBase();
                this.element().addClass(ELEMENT_CLASS);
                this._initButtons()
            },
            _initButtons: function() {
                var $next = $("<div>").addClass(NEXT_BUTTON_CLASS);
                this._next = this._createComponent($next, Button, {
                    icon: "chevronnext",
                    onClick: $.proxy(this._updateCurrentDate, this, 1),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    tabIndex: this.option("tabIndex"),
                    _templates: {}
                });
                var $caption = $("<div>").addClass(CAPTION_BUTTON_CLASS);
                this._caption = this._createComponent($caption, Button, {
                    focusStateEnabled: this.option("focusStateEnabled"),
                    tabIndex: this.option("tabIndex"),
                    _templates: {}
                });
                var $prev = $("<div>").addClass(PREVIOUS_BUTTON_CLASS);
                this._prev = this._createComponent($prev, Button, {
                    icon: "chevronprev",
                    onClick: $.proxy(this._updateCurrentDate, this, -1),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    tabIndex: this.option("tabIndex"),
                    _templates: {}
                });
                this.setAria("label", "Next period", $next);
                this.setAria("label", "Previous period", $prev);
                this._updateButtonsState();
                this.element().append($prev, $caption, $next)
            },
            _updateButtonsState: function() {
                var stepConfig = this._getConfig(),
                    date = this.option("date"),
                    min = this.option("min"),
                    max = this.option("max");
                this._prev.option("disabled", min && date[stepConfig.getter]() === min[stepConfig.getter]());
                this._next.option("disabled", max && date[stepConfig.getter]() === max[stepConfig.getter]())
            },
            _updateCurrentDate: function(direction) {
                var stepConfig = this._getConfig(),
                    offset = stepConfig.duration * direction,
                    date = stepConfig.getDate(new Date(this.option("date")), offset);
                date = dateUtils.normalizeDate(date, this.option("min"), this.option("max"));
                this.notifyObserver("currentDateUpdated", date)
            },
            _renderFocusTarget: $.noop,
            _render: function() {
                this.callBase();
                this._renderPopover();
                this._renderCaption();
                this._renderCaptionKeys()
            },
            _renderPopover: function() {
                var overlayType = !devices.current().generic ? Popup : Popover;
                this._popover = this._createComponent("<div>", overlayType, {
                    onContentReady: $.proxy(this._popoverContentReadyHandler, this),
                    defaultOptionsRules: [{
                        device: function(device) {
                            return !devices.current().generic
                        },
                        options: {
                            fullScreen: true,
                            showCloseButton: false,
                            toolbarItems: [{
                                shortcut: "cancel"
                            }]
                        }
                    }, {
                        device: function(device) {
                            return devices.current().generic
                        },
                        options: {
                            target: this._caption.element()
                        }
                    }]
                });
                this._popover.element().appendTo(this.element())
            },
            _popoverContentReadyHandler: function() {
                this._calendar = this._createComponent($("<div>"), Calendar, this._calendarOptions());
                this._calendar.element().addClass(CALENDAR_CLASS);
                this._popover.content().append(this._calendar.element())
            },
            _calendarOptions: function() {
                return {
                    min: this.option("min"),
                    max: this.option("max"),
                    firstDayOfWeek: this.option("firstDayOfWeek"),
                    value: this.option("date"),
                    focusStateEnabled: this.option("focusStateEnabled"),
                    onValueChanged: $.proxy(function(e) {
                        if (!this.option("visible")) {
                            return
                        }
                        this.notifyObserver("currentDateUpdated", e.value);
                        this._popover.hide()
                    }, this),
                    hasFocus: function() {
                        return true
                    },
                    tabIndex: null,
                    _keyboardProcessor: this._calendarKeyboardProcessor
                }
            },
            _renderCaption: function() {
                var date = this.option("date"),
                    caption = this._getConfig().getCaption.call(this, date);
                this._caption.option({
                    text: caption,
                    onClick: $.proxy(function() {
                        this._popover.toggle()
                    }, this)
                })
            },
            _renderCaptionKeys: function() {
                if (!this.option("focusStateEnabled") || this.option("disabled")) {
                    return
                }
                this._calendarKeyboardProcessor = this._caption._keyboardProcessor.attachChildProcessor();
                this._setCalendarOption("_keyboardProcessor", this._calendarKeyboardProcessor);
                var that = this,
                    executeHandler = function() {
                        if (that._popover.content().is(":hidden")) {
                            that._popover.show()
                        } else {
                            return true
                        }
                    },
                    tabHandler = function() {
                        that._popover.hide()
                    };
                this._caption.registerKeyHandler("enter", executeHandler);
                this._caption.registerKeyHandler("space", executeHandler);
                this._caption.registerKeyHandler("tab", tabHandler)
            },
            _setCalendarOption: function(name, value) {
                if (this._calendar) {
                    this._calendar.option(name, value)
                }
            },
            _getConfig: function() {
                var step = this.option("step"),
                    config = CONFIG[step];
                if (!config) {
                    throw errors.Error("E1033", step)
                }
                return config
            }
        }).include(publisherMixin);
        registerComponent("dxSchedulerNavigator", SchedulerNavigator);
        module.exports = SchedulerNavigator
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.work_space_day.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerWorkSpace = __webpack_require__( /*! ./ui.scheduler.work_space */ 413);
        var DAY_CLASS = "dx-scheduler-work-space-day";
        var SchedulerWorkSpaceDay = SchedulerWorkSpace.inherit({
            _getElementClass: function() {
                return DAY_CLASS
            },
            _getRowCount: function() {
                return this._getCellCountInDay()
            },
            _getCellCount: function() {
                return 1
            },
            _setFirstViewDate: function() {
                this._firstViewDate = this.option("currentDate");
                this._setStartDayHour(this._firstViewDate)
            },
            _getDateByIndex: function() {
                return this._firstViewDate
            },
            _getFormat: function() {
                return "longdate"
            },
            _renderDateHeader: $.noop,
            _getRightCell: function(isMultiSelection) {
                if (!isMultiSelection) {
                    return this.callBase(isMultiSelection)
                }
                return this._$focusedCell
            },
            _getLeftCell: function(isMultiSelection) {
                if (!isMultiSelection) {
                    return this.callBase(isMultiSelection)
                }
                return this._$focusedCell
            }
        });
        registerComponent("dxSchedulerWorkSpaceDay", SchedulerWorkSpaceDay);
        module.exports = SchedulerWorkSpaceDay
    },
    /*!*********************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.work_space.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            toMs = dateUtils.dateToMilliseconds,
            Widget = __webpack_require__( /*! ../widget/ui.widget */ 89),
            abstract = Widget.abstract,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            publisherMixin = __webpack_require__( /*! ./ui.scheduler.publisher_mixin */ 410),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            dragEvents = __webpack_require__( /*! ../../events/drag */ 110),
            Scrollable = __webpack_require__( /*! ../scroll_view/ui.scrollable */ 237).default,
            tableCreator = __webpack_require__( /*! ./ui.scheduler.table_creator */ 414);
        var COMPONENT_CLASS = "dx-scheduler-work-space",
            GROUPED_WORKSPACE_CLASS = "dx-scheduler-work-space-grouped",
            WORKSPACE_WITH_BOTH_SCROLLS_CLASS = "dx-scheduler-work-space-both-scrollbar",
            TIME_PANEL_CLASS = "dx-scheduler-time-panel",
            TIME_PANEL_CELL_CLASS = "dx-scheduler-time-panel-cell",
            TIME_PANEL_ROW_CLASS = "dx-scheduler-time-panel-row",
            ALL_DAY_PANEL_CLASS = "dx-scheduler-all-day-panel",
            ALL_DAY_TABLE_CLASS = "dx-scheduler-all-day-table",
            FIXED_CONTAINER_CLASS = "dx-scheduler-fixed-appointments",
            ALL_DAY_CONTAINER_CLASS = "dx-scheduler-all-day-appointments",
            ALL_DAY_TITLE_CLASS = "dx-scheduler-all-day-title",
            ALL_DAY_TITLE_HIDDEN_CLASS = "dx-scheduler-all-day-title-hidden",
            ALL_DAY_TABLE_CELL_CLASS = "dx-scheduler-all-day-table-cell",
            ALL_DAY_TABLE_ROW_CLASS = "dx-scheduler-all-day-table-row",
            WORKSPACE_WITH_ALL_DAY_CLASS = "dx-scheduler-work-space-all-day",
            WORKSPACE_WITH_COLLAPSED_ALL_DAY_CLASS = "dx-scheduler-work-space-all-day-collapsed",
            WORKSPACE_WITH_MOUSE_SELECTION_CLASS = "dx-scheduler-work-space-mouse-selection",
            HEADER_PANEL_CLASS = "dx-scheduler-header-panel",
            HEADER_PANEL_CELL_CLASS = "dx-scheduler-header-panel-cell",
            HEADER_ROW_CLASS = "dx-scheduler-header-row",
            GROUP_ROW_CLASS = "dx-scheduler-group-row",
            GROUP_HEADER_CLASS = "dx-scheduler-group-header",
            GROUP_HEADER_CONTENT_CLASS = "dx-scheduler-group-header-content",
            DATE_TABLE_CLASS = "dx-scheduler-date-table",
            DATE_TABLE_CELL_CLASS = "dx-scheduler-date-table-cell",
            DATE_TABLE_ROW_CLASS = "dx-scheduler-date-table-row",
            DATE_TABLE_FOCUSED_CELL_CLASS = "dx-scheduler-focused-cell",
            DATE_TABLE_DROPPABLE_CELL_CLASS = "dx-scheduler-date-table-droppable-cell",
            SCHEDULER_HEADER_SCROLLABLE_CLASS = "dx-scheduler-header-scrollable",
            SCHEDULER_SIDEBAR_SCROLLABLE_CLASS = "dx-scheduler-sidebar-scrollable",
            SCHEDULER_DATE_TABLE_SCROLLABLE_CLASS = "dx-scheduler-date-table-scrollable",
            SCHEDULER_WORKSPACE_DXPOINTERDOWN_EVENT_NAME = eventUtils.addNamespace(pointerEvents.down, "dxSchedulerWorkSpace"),
            SCHEDULER_CELL_DXDRAGENTER_EVENT_NAME = eventUtils.addNamespace(dragEvents.enter, "dxSchedulerDateTable"),
            SCHEDULER_CELL_DXDROP_EVENT_NAME = eventUtils.addNamespace(dragEvents.drop, "dxSchedulerDateTable"),
            SCHEDULER_CELL_DXCLICK_EVENT_NAME = eventUtils.addNamespace(clickEvent.name, "dxSchedulerDateTable"),
            SCHEDULER_CELL_DXPOINTERDOWN_EVENT_NAME = eventUtils.addNamespace(pointerEvents.down, "dxSchedulerDateTable"),
            SCHEDULER_CELL_DXPOINTERUP_EVENT_NAME = eventUtils.addNamespace(pointerEvents.up, "dxSchedulerDateTable"),
            SCHEDULER_CELL_DXPOINTERMOVE_EVENT_NAME = eventUtils.addNamespace(pointerEvents.move, "dxSchedulerDateTable"),
            CELL_DATA = "dxCellData",
            DATE_TABLE_CELL_WIDTH = 75,
            DAY_MS = toMs("day"),
            HOUR_MS = toMs("hour");
        var SchedulerWorkSpace = Widget.inherit({
            _supportedKeys: function() {
                var clickHandler = function(e) {
                        e.preventDefault();
                        e.stopPropagation();
                        if (this._focusedCells && this._focusedCells.length) {
                            this._showAddAppointmentPopup($(this._focusedCells))
                        }
                    },
                    arrowPressHandler = function(e, cell) {
                        e.preventDefault();
                        e.stopPropagation();
                        this._moveToCell(cell, e.shiftKey)
                    };
                return $.extend(this.callBase(), {
                    enter: clickHandler,
                    space: clickHandler,
                    downArrow: function(e) {
                        var $cell = this._getCellFromNextRow("next", e.shiftKey);
                        arrowPressHandler.call(this, e, $cell)
                    },
                    upArrow: function(e) {
                        var $cell = this._getCellFromNextRow("prev", e.shiftKey);
                        arrowPressHandler.call(this, e, $cell)
                    },
                    rightArrow: function(e) {
                        var $rightCell = this._getRightCell(e.shiftKey);
                        arrowPressHandler.call(this, e, $rightCell)
                    },
                    leftArrow: function(e) {
                        var $leftCell = this._getLeftCell(e.shiftKey);
                        arrowPressHandler.call(this, e, $leftCell)
                    }
                })
            },
            _isRTL: function() {
                return this.option("rtlEnabled")
            },
            _getFocusedCell: function() {
                return this._$focusedCell || this._$dateTable.find("." + this._getDateTableCellClass()).eq(0)
            },
            _getCellFromNextRow: function(direction, isMultiSelection) {
                var $currentCell = this._$focusedCell,
                    cellIndex = $currentCell.index(),
                    $row = $currentCell.parent(),
                    $cell = $row[direction]().children().eq(cellIndex);
                $cell = this._checkForViewBounds($cell);
                return $cell
            },
            _checkForViewBounds: function($item) {
                if (!$item.length) {
                    $item = this._$focusedCell
                }
                return $item
            },
            _getRightCell: function(isMultiSelection) {
                var $rightCell, $focusedCell = this._$focusedCell,
                    groupCount = this._getGroupCount(),
                    rowCellCount = isMultiSelection ? this._getCellCount() : this._getTotalCellCount(groupCount),
                    lastIndexInRow = rowCellCount - 1,
                    edgeCellIndex = this._isRTL() ? 0 : lastIndexInRow,
                    currentIndex = $focusedCell.index(),
                    direction = this._isRTL() ? "prev" : "next";
                if (currentIndex === edgeCellIndex || isMultiSelection && this._isGroupEndCell($focusedCell)) {
                    var $row = $focusedCell.parent(),
                        sign = this._isRTL() ? 1 : -1;
                    $rightCell = $row[direction]().children().eq(currentIndex + sign * lastIndexInRow);
                    $rightCell = this._checkForViewBounds($rightCell)
                } else {
                    $rightCell = $focusedCell[direction]()
                }
                return $rightCell
            },
            _isGroupEndCell: function($cell) {
                var cellsInRow = this._getCellCount(),
                    currentCellIndex = $cell.index(),
                    result = currentCellIndex % cellsInRow;
                return this._isRTL() ? 0 === result : result === cellsInRow - 1
            },
            _getLeftCell: function(isMultiSelection) {
                var $leftCell, $focusedCell = this._$focusedCell,
                    groupCount = this._getGroupCount(),
                    rowCellCount = isMultiSelection ? this._getCellCount() : this._getTotalCellCount(groupCount),
                    lastIndexInRow = rowCellCount - 1,
                    edgeCellIndex = this._isRTL() ? lastIndexInRow : 0,
                    currentIndex = $focusedCell.index(),
                    direction = this._isRTL() ? "next" : "prev";
                if (currentIndex === edgeCellIndex || isMultiSelection && this._isGroupStartCell($focusedCell)) {
                    var $row = $focusedCell.parent(),
                        sign = this._isRTL() ? -1 : 1;
                    $leftCell = $row[direction]().children().eq(currentIndex + sign * lastIndexInRow);
                    $leftCell = this._checkForViewBounds($leftCell)
                } else {
                    $leftCell = $focusedCell[direction]()
                }
                return $leftCell
            },
            _isGroupStartCell: function($cell) {
                var cellsInRow = this._getCellCount(),
                    currentCellIndex = $cell.index(),
                    result = currentCellIndex % cellsInRow;
                return this._isRTL() ? result === cellsInRow - 1 : 0 === result
            },
            _moveToCell: function($cell, isMultiSelection) {
                isMultiSelection = isMultiSelection && this.option("allowMultipleCellSelection");
                this._setFocusedCell($cell, isMultiSelection);
                this._dateTableScrollable.scrollToElement($cell)
            },
            _setFocusedCell: function($cell, isMultiSelection) {
                if (!$cell.length) {
                    return
                }
                this._releaseFocusedCell();
                this._focusedCells = [];
                if (isMultiSelection) {
                    $cell = this._correctCellForGroup($cell);
                    var $targetCells = this._getCellsBetween($cell, this._$prevCell);
                    this._focusedCells = $targetCells.toArray()
                } else {
                    this._focusedCells = [$cell.get(0)];
                    this._$prevCell = $cell
                }
                var $focusedCells = $(this._focusedCells);
                this._toggleFocusClass(true, $focusedCells);
                this.setAria("label", "Add appointment", $focusedCells);
                this._toggleFocusedCellClass(true, $cell);
                this._$focusedCell = $cell
            },
            _correctCellForGroup: function($cell) {
                var $focusedCell = this._$focusedCell,
                    cellGroupIndex = this._getGroupIndexByCell($cell),
                    focusedCellGroupIndex = this._getGroupIndexByCell($focusedCell),
                    isDifferentTables = this._hasAllDayClass($cell) !== this._hasAllDayClass($focusedCell);
                return focusedCellGroupIndex !== cellGroupIndex || isDifferentTables ? $focusedCell : $cell
            },
            _getCellsBetween: function($first, $last) {
                var isAllDayTable = this._hasAllDayClass($last),
                    $cells = this._getCells(isAllDayTable),
                    firstIndex = $cells.index($first),
                    lastIndex = $cells.index($last);
                if (firstIndex > lastIndex) {
                    var buffer = firstIndex;
                    firstIndex = lastIndex;
                    lastIndex = buffer
                }
                $cells = $cells.slice(firstIndex, lastIndex + 1);
                if (this._getGroupCount() > 1) {
                    var result = [],
                        focusedGroupIndex = this._getGroupIndexByCell($first);
                    $.each($cells, $.proxy(function(_, cell) {
                        var groupIndex = this._getGroupIndexByCell($(cell));
                        if (focusedGroupIndex === groupIndex) {
                            result.push(cell)
                        }
                    }, this));
                    $cells = $(result)
                }
                return $cells
            },
            _hasAllDayClass: function($cell) {
                return $cell.hasClass(ALL_DAY_TABLE_CELL_CLASS)
            },
            _getGroupIndexByCell: function($cell) {
                var cellsInRow = this._getCellCount(),
                    currentCellIndex = $cell.index() + 1,
                    groupIndex = Math.ceil(currentCellIndex / cellsInRow);
                return groupIndex
            },
            _toggleFocusedCellClass: function(isFocused, $element) {
                var $focusTarget = $element && $element.length ? $element : this._focusTarget();
                $focusTarget.toggleClass(DATE_TABLE_FOCUSED_CELL_CLASS, isFocused)
            },
            _releaseFocusedCell: function($cell) {
                $cell = $cell || $(this._focusedCells);
                if (commonUtils.isDefined($cell)) {
                    this._toggleFocusClass(false, $cell);
                    this._toggleFocusedCellClass(false, $cell);
                    this.setAria("label", void 0, $cell)
                }
            },
            _focusInHandler: function(e) {
                if ($(e.target).is(this._focusTarget()) && false !== this._isCellClick) {
                    delete this._isCellClick;
                    this.callBase.apply(this, arguments);
                    var $cell = this._getFocusedCell();
                    this._setFocusedCell($cell)
                }
            },
            _focusOutHandler: function(e) {
                this.callBase.apply(this, arguments);
                this._releaseFocusedCell()
            },
            _focusTarget: function() {
                return this.element()
            },
            _activeStateUnit: "." + DATE_TABLE_CELL_CLASS + ", ." + ALL_DAY_TABLE_CELL_CLASS,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    currentDate: new Date,
                    firstDayOfWeek: void 0,
                    startDayHour: 0,
                    endDayHour: 24,
                    hoursInterval: .5,
                    activeStateEnabled: true,
                    hoverStateEnabled: true,
                    groups: [],
                    showAllDayPanel: true,
                    allDayExpanded: false,
                    onCellClick: null,
                    crossScrollingEnabled: false,
                    allowMultipleCellSelection: true
                })
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "startDayHour":
                    case "endDayHour":
                    case "hoursInterval":
                    case "firstDayOfWeek":
                    case "currentDate":
                    case "groups":
                        this._cleanView();
                        this._toggleGroupedClass();
                        this._renderView();
                        break;
                    case "showAllDayPanel":
                        this._toggleAllDayVisibility();
                        break;
                    case "allDayExpanded":
                        this._changeAllDayVisibility();
                        this.notifyObserver("allDayPanelToggled");
                        this._attachTablesEvents();
                        break;
                    case "onCellClick":
                        this._createCellClickAction();
                        break;
                    case "crossScrollingEnabled":
                        this._toggleHorizontalScrollClass();
                        this._dateTableScrollable.option(this._dateTableScrollableConfig());
                        break;
                    case "width":
                        this.callBase(args);
                        this._dimensionChanged();
                        break;
                    case "allowMultipleCellSelection":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _init: function() {
                this.callBase();
                this._toggleHorizontalScrollClass();
                this.element().addClass(COMPONENT_CLASS).addClass(this._getElementClass());
                this._initWorkSpaceUnits();
                this._initDateTableScrollable();
                this._createWorkSpaceElements()
            },
            _toggleHorizontalScrollClass: function() {
                this.element().toggleClass(WORKSPACE_WITH_BOTH_SCROLLS_CLASS, this.option("crossScrollingEnabled"))
            },
            _getTimePanelClass: function() {
                return TIME_PANEL_CLASS
            },
            _getDateTableClass: function() {
                return DATE_TABLE_CLASS
            },
            _getDateTableRowClass: function() {
                return DATE_TABLE_ROW_CLASS
            },
            _getDateTableCellClass: function() {
                return DATE_TABLE_CELL_CLASS
            },
            _getGroupRowClass: function() {
                return GROUP_ROW_CLASS
            },
            _getGroupHeaderClass: function() {
                return GROUP_HEADER_CLASS
            },
            _getGroupHeaderContentClass: function() {
                return GROUP_HEADER_CONTENT_CLASS
            },
            _initWorkSpaceUnits: function() {
                this._$headerPanel = $("<table>").addClass(HEADER_PANEL_CLASS);
                this._$thead = $("<thead>").appendTo(this._$headerPanel);
                this._$fixedContainer = $("<div>").addClass(FIXED_CONTAINER_CLASS);
                this._$allDayContainer = $("<div>").addClass(ALL_DAY_CONTAINER_CLASS);
                this._$allDayTitle = $("<div>").addClass(ALL_DAY_TITLE_CLASS).text(messageLocalization.format("dxScheduler-allDay")).appendTo(this.element());
                this._$allDayTable = $("<table>").addClass(ALL_DAY_TABLE_CLASS);
                this._$allDayPanel = $("<div>").addClass(ALL_DAY_PANEL_CLASS).append(this._$allDayTable);
                this._$timePanel = $("<table>").addClass(this._getTimePanelClass());
                this._$dateTable = $("<table>").addClass(this._getDateTableClass())
            },
            _initDateTableScrollable: function() {
                var $dateTableScrollable = $("<div>").addClass(SCHEDULER_DATE_TABLE_SCROLLABLE_CLASS);
                this._dateTableScrollable = this._createComponent($dateTableScrollable, Scrollable, this._dateTableScrollableConfig())
            },
            _dateTableScrollableConfig: function() {
                var config = {
                    useKeyboard: false,
                    useNative: false,
                    bounceEnabled: false,
                    updateManually: true,
                    pushBackValue: 0
                };
                if (this.option("crossScrollingEnabled")) {
                    config = $.extend(config, this._createCrossScrollingConfig())
                }
                return config
            },
            _createCrossScrollingConfig: function() {
                var config = {};
                config.direction = "both";
                config.onScroll = $.proxy(function(e) {
                    this._sidebarScrollable.scrollTo({
                        top: e.scrollOffset.top
                    });
                    this._headerScrollable.scrollTo({
                        left: e.scrollOffset.left
                    })
                }, this);
                config.onEnd = $.proxy(function(e) {
                    this.notifyObserver("updateResizableArea", {})
                }, this);
                return config
            },
            _createWorkSpaceElements: function() {
                if (this.option("crossScrollingEnabled")) {
                    this._createWorkSpaceScrollableElements()
                } else {
                    this._createWorkSpaceStaticElements()
                }
            },
            _createWorkSpaceStaticElements: function() {
                this._dateTableScrollable.content().append(this._$timePanel, this._$dateTable);
                this.element().append(this._$fixedContainer, this._$headerPanel, this._$allDayContainer, this._$allDayPanel, this._dateTableScrollable.element())
            },
            _createWorkSpaceScrollableElements: function() {
                this.element().append(this._$fixedContainer);
                this._createHeaderScrollable();
                this._createSidebarScrollable();
                this.element().append(this._dateTableScrollable.element());
                this._headerScrollable.content().append(this._$headerPanel, this._$allDayContainer, this._$allDayPanel);
                this._dateTableScrollable.content().append(this._$dateTable);
                this._sidebarScrollable.content().append(this._$timePanel)
            },
            _createHeaderScrollable: function() {
                var $headerScrollable = $("<div>").addClass(SCHEDULER_HEADER_SCROLLABLE_CLASS).appendTo(this.element());
                this._headerScrollable = this._createComponent($headerScrollable, Scrollable, {
                    useKeyboard: false,
                    showScrollbar: false,
                    direction: "horizontal",
                    useNative: false,
                    updateManually: true,
                    bounceEnabled: false,
                    pushBackValue: 0,
                    onScroll: $.proxy(function(e) {
                        this._dateTableScrollable.scrollTo({
                            left: e.scrollOffset.left
                        })
                    }, this)
                })
            },
            _createSidebarScrollable: function() {
                var $timePanelScrollable = $("<div>").addClass(SCHEDULER_SIDEBAR_SCROLLABLE_CLASS).appendTo(this.element());
                this._sidebarScrollable = this._createComponent($timePanelScrollable, Scrollable, {
                    useKeyboard: false,
                    showScrollbar: false,
                    direction: "vertical",
                    useNative: false,
                    updateManually: true,
                    bounceEnabled: false,
                    pushBackValue: 0,
                    onScroll: $.proxy(function(e) {
                        this._dateTableScrollable.scrollTo({
                            top: e.scrollOffset.top
                        })
                    }, this)
                })
            },
            _visibilityChanged: function(visible) {
                if (visible && this.option("crossScrollingEnabled")) {
                    this._setTableSizes()
                }
            },
            _setTableSizes: function() {
                var cellWidth = DATE_TABLE_CELL_WIDTH,
                    minWidth = this._getWorkSpaceMinWidth(),
                    $headerCells = this._$headerPanel.find("tr").last().find("th");
                var width = cellWidth * $headerCells.length;
                if (width < minWidth) {
                    width = minWidth
                }
                this._$headerPanel.width(width);
                this._$dateTable.width(width);
                this._$allDayTable.width(width)
            },
            _getWorkSpaceMinWidth: function() {
                var minWidth = this._getWorkSpaceWidth(),
                    workspaceContainerWidth = this.element().outerWidth() - this.getTimePanelWidth();
                if (minWidth < workspaceContainerWidth) {
                    minWidth = workspaceContainerWidth
                }
                return minWidth
            },
            _dimensionChanged: function(e) {
                if (this.option("crossScrollingEnabled")) {
                    this._setTableSizes()
                }
                this._cleanCellDataCache()
            },
            _getElementClass: $.noop,
            _getRowCount: $.noop,
            _getCellCount: $.noop,
            _render: function() {
                this.callBase();
                this._toggleGroupedClass();
                this._renderView();
                this._attachEvents()
            },
            _toggleGroupedClass: function() {
                this.element().toggleClass(GROUPED_WORKSPACE_CLASS, this._getGroupCount() > 0)
            },
            _renderView: function() {
                this._setFirstViewDate();
                this._renderGroupHeader();
                this._renderDateHeader();
                this._renderAllDayPanel();
                this._renderTimePanel();
                this._renderDateTable()
            },
            _setFirstViewDate: function() {
                this._firstViewDate = dateUtils.getFirstWeekDate(this.option("currentDate"), this._firstDayOfWeek() || dateLocalization.firstDayOfWeekIndex());
                this._setStartDayHour(this._firstViewDate)
            },
            _setStartDayHour: function(date) {
                if (commonUtils.isDefined(this.option("startDayHour"))) {
                    date.setHours(this.option("startDayHour"), 0, 0, 0)
                }
            },
            _firstDayOfWeek: function() {
                return this.option("firstDayOfWeek")
            },
            _attachEvents: function() {
                var that = this,
                    pointerDownAction = this._createAction(function(e) {
                        that._pointerDownHandler(e.jQueryEvent)
                    });
                this._createCellClickAction();
                var cellSelector = "." + this._getDateTableCellClass() + ",." + ALL_DAY_TABLE_CELL_CLASS;
                this.element().off(SCHEDULER_WORKSPACE_DXPOINTERDOWN_EVENT_NAME).off(SCHEDULER_CELL_DXCLICK_EVENT_NAME).on(SCHEDULER_WORKSPACE_DXPOINTERDOWN_EVENT_NAME, function(e) {
                    if (eventUtils.isMouseEvent(e) && e.which > 1) {
                        e.preventDefault();
                        return
                    }
                    pointerDownAction({
                        jQueryEvent: e
                    })
                }).on(SCHEDULER_CELL_DXCLICK_EVENT_NAME, cellSelector, function(e) {
                    var $cell = $(e.target);
                    that._cellClickAction({
                        jQueryEvent: e,
                        cellElement: $cell,
                        cellData: that.getCellData($cell)
                    })
                })
            },
            _createCellClickAction: function() {
                var that = this;
                this._cellClickAction = this._createActionByOption("onCellClick", {
                    afterExecute: function(e) {
                        that._clickHandler(e.args[0].jQueryEvent)
                    }
                })
            },
            _clickHandler: function(e) {
                var $target = $(e.target);
                if (this._showPopup && this._hasFocusClass($target)) {
                    delete this._showPopup;
                    this._showAddAppointmentPopup($target)
                }
            },
            _pointerDownHandler: function(e) {
                var $target = $(e.target);
                if (!$target.hasClass(this._getDateTableCellClass()) && !$target.hasClass(ALL_DAY_TABLE_CELL_CLASS)) {
                    this._isCellClick = false;
                    return
                }
                this._isCellClick = true;
                if ($target.hasClass(DATE_TABLE_FOCUSED_CELL_CLASS)) {
                    this._showPopup = true
                } else {
                    this._setFocusedCell($target)
                }
            },
            _showAddAppointmentPopup: function($cell) {
                var firstCellData = this.getCellData($cell.first()),
                    lastCellData = this.getCellData($cell.last());
                var args = {
                    startDate: firstCellData.startDate,
                    endDate: lastCellData.endDate
                };
                if (commonUtils.isDefined(lastCellData.allDay)) {
                    args.allDay = lastCellData.allDay
                }
                $.extend(args, lastCellData.groups);
                this.notifyObserver("showAddAppointmentPopup", args)
            },
            _getGroupHeaderContainer: function() {
                return this._$thead
            },
            _getDateHeaderContainer: function() {
                return this._$thead
            },
            _renderGroupHeader: function() {
                var $container = this._getGroupHeaderContainer();
                var groupCount = this._getGroupCount();
                if (groupCount) {
                    var groupRows = this._makeGroupRows(this.option("groups"));
                    this._attachGroupCountAttr(groupRows.length);
                    $container.append(groupRows)
                }
            },
            _attachGroupCountAttr: function(groupRowCount) {
                this.element().attr("dx-group-row-count", groupRowCount)
            },
            _makeGroupRows: function(groups) {
                return tableCreator.makeGroupedTable(tableCreator.HORIZONTAL, groups, {
                    groupRowClass: this._getGroupRowClass(),
                    groupHeaderClass: this._getGroupHeaderClass(),
                    groupHeaderContentClass: this._getGroupHeaderContentClass()
                }, this._getCellCount() || 1)
            },
            _renderDateHeader: function() {
                var $container = this._getDateHeaderContainer(),
                    $headerRow = $("<tr>").addClass(HEADER_ROW_CLASS),
                    count = this._getCellCount(),
                    repeatCount = this._calculateHeaderCellRepeatCount();
                for (var j = 0; j < repeatCount; j++) {
                    for (var i = 0; i < count; i++) {
                        var text = this._getHeaderText(i),
                            $cell = $("<th>").text(text).addClass(HEADER_PANEL_CELL_CLASS).attr("title", text);
                        $headerRow.append($cell)
                    }
                }
                $container.append($headerRow);
                return $headerRow
            },
            _calculateHeaderCellRepeatCount: function() {
                return this._getGroupCount() || 1
            },
            _renderAllDayPanel: function() {
                var cellCount = this._getCellCount() * (this._getGroupCount() || 1);
                this._renderTableBody({
                    container: this._$allDayTable,
                    rowCount: 1,
                    cellCount: cellCount,
                    cellClass: ALL_DAY_TABLE_CELL_CLASS,
                    rowClass: ALL_DAY_TABLE_ROW_CLASS,
                    dataGenerator: $.proxy(this._setAllDayCellData, this)
                });
                this._toggleAllDayVisibility()
            },
            _setAllDayCellData: function(cell, rowIndex, cellIndex) {
                var startDate = this._getDateByCellIndexes(rowIndex, cellIndex);
                startDate = dateUtils.trimTime(startDate);
                var data = {
                    startDate: startDate,
                    endDate: new Date(startDate.getTime() + DAY_MS),
                    allDay: true
                };
                var groups = this._getCellGroups(this._getGroupIndex(rowIndex, cellIndex));
                if (groups.length) {
                    data.groups = {}
                }
                for (var i = 0; i < groups.length; i++) {
                    data.groups[groups[i].name] = groups[i].id
                }
                $.data(cell, CELL_DATA, data)
            },
            _toggleAllDayVisibility: function() {
                var showAllDayPanel = this.option("showAllDayPanel");
                this._$allDayPanel.toggle(showAllDayPanel);
                this._$allDayTitle.toggleClass(ALL_DAY_TITLE_HIDDEN_CLASS, !showAllDayPanel);
                this.element().toggleClass(WORKSPACE_WITH_ALL_DAY_CLASS, showAllDayPanel);
                this._changeAllDayVisibility()
            },
            _changeAllDayVisibility: function() {
                this.element().toggleClass(WORKSPACE_WITH_COLLAPSED_ALL_DAY_CLASS, !this.option("allDayExpanded") && this.option("showAllDayPanel"))
            },
            _renderTimePanel: function() {
                this._renderTableBody({
                    container: this._$timePanel,
                    rowCount: this._getTimePanelRowCount(),
                    cellCount: 1,
                    cellClass: TIME_PANEL_CELL_CLASS,
                    rowClass: TIME_PANEL_ROW_CLASS,
                    dataGenerator: $.proxy(this._setTimePanelText, this)
                })
            },
            _getTimePanelRowCount: function() {
                return .5 * this._getCellCountInDay()
            },
            _getCellCountInDay: function() {
                return Math.floor(this._calculateDayDuration() / this.option("hoursInterval"))
            },
            _calculateDayDuration: function() {
                return this.option("endDayHour") - this.option("startDayHour")
            },
            _setTimePanelText: function(td, i) {
                td.innerHTML = this._getTimeText(i)
            },
            _getTimeText: function(i) {
                var startViewDate = new Date(this.getStartViewDate()),
                    timeCellDuration = 2 * this.getCellDuration();
                var date = new Date(startViewDate.getTime() + timeCellDuration * i);
                return dateLocalization.format(date, "shorttime")
            },
            _renderDateTable: function() {
                var groupCount = this._getGroupCount();
                this._renderTableBody({
                    container: this._$dateTable,
                    rowCount: this._getTotalRowCount(groupCount),
                    cellCount: this._getTotalCellCount(groupCount),
                    cellClass: this._getDateTableCellClass(),
                    rowClass: this._getDateTableRowClass(),
                    dataGenerator: $.proxy(this._setCellData, this)
                });
                this._attachTablesEvents()
            },
            _getTotalCellCount: function(groupCount) {
                groupCount = groupCount || 1;
                return this._getCellCount() * groupCount
            },
            _getTotalRowCount: function(groupCount) {
                return this._getRowCount()
            },
            _setCellData: function(cell, rowIndex, cellIndex) {
                var data = this._prepareCellData(cell, rowIndex, cellIndex);
                $.data(cell, CELL_DATA, data)
            },
            _prepareCellData: function(cell, rowIndex, cellIndex) {
                var startDate = this._getDateByCellIndexes(rowIndex, cellIndex),
                    endDate = this.calculateEndDate(startDate),
                    data = {
                        startDate: startDate,
                        endDate: endDate,
                        allDay: this._getTableAllDay()
                    },
                    groups = this._getCellGroups(this._getGroupIndex(rowIndex, cellIndex));
                if (groups.length) {
                    data.groups = {}
                }
                for (var i = 0; i < groups.length; i++) {
                    data.groups[groups[i].name] = groups[i].id
                }
                return data
            },
            _getGroupIndex: function(rowIndex, cellIndex) {
                return Math.floor(cellIndex / this._getCellCount())
            },
            _getTableAllDay: function() {
                return false
            },
            calculateEndDate: function(startDate) {
                return new Date(startDate.getTime() + this._getInterval())
            },
            _getGroupCount: function() {
                var groups = this.option("groups"),
                    result = 0;
                for (var i = 0, len = groups.length; i < len; i++) {
                    if (!i) {
                        result = groups[i].items.length
                    } else {
                        result *= groups[i].items.length
                    }
                }
                return result
            },
            _getPathToLeaf: function(leafIndex) {
                var tree = this.invoke("createResourcesTree", this.option("groups"));

                function findLeafByIndex(data, index) {
                    for (var i = 0; i < data.length; i++) {
                        if (data[i].leafIndex === index) {
                            return data[i]
                        } else {
                            var leaf = findLeafByIndex(data[i].children, index);
                            if (leaf) {
                                return leaf
                            }
                        }
                    }
                }

                function makeBranch(leaf, result) {
                    result = result || [];
                    result.push(leaf.value);
                    if (leaf.parent) {
                        makeBranch(leaf.parent, result)
                    }
                    return result
                }
                var leaf = findLeafByIndex(tree, leafIndex);
                return makeBranch(leaf).reverse()
            },
            _getCellGroups: function(groupIndex) {
                var result = [];
                if (this._getGroupCount()) {
                    var groups = this.option("groups");
                    if (groupIndex < 0) {
                        return
                    }
                    var path = this._getPathToLeaf(groupIndex);
                    for (var i = 0; i < groups.length; i++) {
                        result.push({
                            name: groups[i].name,
                            id: path[i]
                        })
                    }
                }
                return result
            },
            _attachTablesEvents: function() {
                this._attachTableEvents(this._getDateTable());
                this._attachTableEvents(this._getAllDayTable())
            },
            _attachTableEvents: function($table) {
                var cellHeight, cellWidth, that = this,
                    isPointerDown = false;
                $table.off(SCHEDULER_CELL_DXDRAGENTER_EVENT_NAME).off(SCHEDULER_CELL_DXDROP_EVENT_NAME).off(SCHEDULER_CELL_DXPOINTERMOVE_EVENT_NAME).off(SCHEDULER_CELL_DXPOINTERDOWN_EVENT_NAME).on(SCHEDULER_CELL_DXDRAGENTER_EVENT_NAME, "td", {
                    itemSizeFunc: function($element) {
                        if (!cellHeight) {
                            cellHeight = $element.height()
                        }
                        if (!cellWidth) {
                            cellWidth = $element.width()
                        }
                        return {
                            width: cellWidth,
                            height: cellHeight
                        }
                    }
                }, function(e) {
                    if (that._$currentTableTarget) {
                        that._$currentTableTarget.removeClass(DATE_TABLE_DROPPABLE_CELL_CLASS)
                    }
                    that._$currentTableTarget = $(e.target);
                    that._$currentTableTarget.addClass(DATE_TABLE_DROPPABLE_CELL_CLASS)
                }).on(SCHEDULER_CELL_DXDROP_EVENT_NAME, "td", function(e) {
                    $(e.target).removeClass(DATE_TABLE_DROPPABLE_CELL_CLASS);
                    cellHeight = 0;
                    cellWidth = 0
                }).on(SCHEDULER_CELL_DXPOINTERDOWN_EVENT_NAME, "td", function(e) {
                    if (eventUtils.isMouseEvent(e) && 1 === e.which) {
                        isPointerDown = true;
                        that.element().addClass(WORKSPACE_WITH_MOUSE_SELECTION_CLASS);
                        $(document).off(SCHEDULER_CELL_DXPOINTERUP_EVENT_NAME).on(SCHEDULER_CELL_DXPOINTERUP_EVENT_NAME, function() {
                            isPointerDown = false;
                            that.element().removeClass(WORKSPACE_WITH_MOUSE_SELECTION_CLASS)
                        })
                    }
                }).on(SCHEDULER_CELL_DXPOINTERMOVE_EVENT_NAME, "td", function(e) {
                    if (isPointerDown) {
                        e.preventDefault();
                        e.stopPropagation();
                        that._moveToCell($(e.target), true)
                    }
                })
            },
            _getDateTables: function() {
                return this._$dateTable.add(this._$allDayTable)
            },
            _getDateTable: function() {
                return this._$dateTable
            },
            _getAllDayTable: function() {
                return this._$allDayTable
            },
            _getInterval: function() {
                if (void 0 === this._interval) {
                    this._interval = this.option("hoursInterval") * HOUR_MS
                }
                return this._interval
            },
            _getHeaderText: function(headerIndex) {
                return dateLocalization.format(this._getDateByIndex(headerIndex), this._getFormat())
            },
            _getDateByIndex: abstract,
            _getFormat: abstract,
            _calculateCellIndex: function(rowIndex, cellIndex) {
                cellIndex %= this._getCellCount();
                return this._getRowCount() * cellIndex + rowIndex
            },
            _renderTableBody: function(options) {
                options.container.append(tableCreator.makeTable(options))
            },
            _cleanView: function() {
                this._cleanCellDataCache();
                this._$thead.empty();
                this._$dateTable.empty();
                this._$timePanel.empty();
                this._$allDayTable.empty();
                delete this._hiddenInterval;
                delete this._interval
            },
            getWorkArea: function() {
                return this._dateTableScrollable.content()
            },
            getScrollable: function() {
                return this._dateTableScrollable
            },
            getScrollableScrollTop: function() {
                return this._dateTableScrollable.scrollTop()
            },
            getScrollableScrollLeft: function() {
                return this._dateTableScrollable.scrollLeft()
            },
            getScrollableOuterWidth: function() {
                return this._dateTableScrollable.scrollWidth()
            },
            getScrollableContainer: function() {
                return this._dateTableScrollable._container()
            },
            getHeaderPanelHeight: function() {
                return this._$headerPanel.outerHeight(true)
            },
            getTimePanelWidth: function() {
                return this._$timePanel.outerWidth()
            },
            _getCellCoordinatesByIndex: function(index) {
                var cellIndex = Math.floor(index / this._getRowCount()),
                    rowIndex = index - this._getRowCount() * cellIndex;
                return {
                    cellIndex: cellIndex,
                    rowIndex: rowIndex
                }
            },
            _getDateByCellIndexes: function(rowIndex, cellIndex) {
                var firstViewDate = this.getStartViewDate(),
                    currentDate = new Date(firstViewDate.getTime() + this._getMillisecondsOffset(rowIndex, cellIndex));
                currentDate.setTime(currentDate.getTime() + dateUtils.getTimezonesDifference(firstViewDate, currentDate));
                return currentDate
            },
            _getMillisecondsOffset: function(rowIndex, cellIndex) {
                return this._getInterval() * this._calculateCellIndex(rowIndex, cellIndex) + this._calculateHiddenInterval(rowIndex, cellIndex)
            },
            _calculateHiddenInterval: function(rowIndex, cellIndex) {
                var dayCount = cellIndex % this._getCellCount();
                return dayCount * this._getHiddenInterval()
            },
            _getHiddenInterval: function() {
                if (void 0 === this._hiddenInterval) {
                    this._hiddenInterval = DAY_MS - this.option("hoursInterval") * this._getCellCountInDay() * HOUR_MS
                }
                return this._hiddenInterval
            },
            _getIntervalBetween: function(currentDate, allDay) {
                var startDayTime = this.option("startDayHour") * HOUR_MS,
                    firstViewDate = this.getStartViewDate(),
                    timeZoneOffset = dateUtils.getTimezonesDifference(firstViewDate, currentDate),
                    fullInterval = currentDate.getTime() - firstViewDate.getTime() - timeZoneOffset,
                    days = Math.floor((fullInterval + startDayTime) / DAY_MS),
                    result = days * DAY_MS;
                if (!allDay) {
                    result = fullInterval - days * this._getHiddenInterval()
                }
                return result
            },
            _getGroupIndexes: function(appointmentResources) {
                var result = [];
                if (appointmentResources && this.option("groups").length) {
                    var tree = this.invoke("createResourcesTree", this.option("groups"));
                    result = this.invoke("getResourceTreeLeaves", tree, appointmentResources)
                }
                return result
            },
            _updateIndex: function(index) {
                return index * this._getRowCount()
            },
            _getDroppableCell: function() {
                return this._getDateTables().find("." + DATE_TABLE_DROPPABLE_CELL_CLASS)
            },
            _getWorkSpaceWidth: function() {
                if (this.option("crossScrollingEnabled")) {
                    return this._$dateTable.outerWidth()
                }
                return this.element().outerWidth() - this.getTimePanelWidth()
            },
            _getCellPositionByIndex: function(index, groupIndex) {
                var cellCoordinates = this._getCellCoordinatesByIndex(index),
                    $cell = this._getCellByCoordinates(cellCoordinates, groupIndex),
                    result = this._getCellPosition($cell);
                this.setCellDataCache(cellCoordinates, groupIndex, $cell);
                if (result) {
                    result.rowIndex = cellCoordinates.rowIndex;
                    result.cellIndex = cellCoordinates.cellIndex
                }
                return result
            },
            _getCellPosition: function($cell) {
                var isRtl = this.option("rtlEnabled"),
                    position = $cell.position();
                if (isRtl) {
                    position.left += $cell.outerWidth()
                }
                return position
            },
            _getCellByCoordinates: function(cellCoordinates, groupIndex) {
                return this._$dateTable.find("tr").eq(cellCoordinates.rowIndex).find("td").eq(cellCoordinates.cellIndex + groupIndex * this._getCellCount())
            },
            _getCells: function(allDay) {
                var cellClass = allDay ? ALL_DAY_TABLE_CELL_CLASS : this._getDateTableCellClass();
                return this.element().find("." + cellClass)
            },
            _getGroupHeaderCellsContent: function() {
                return this.element().find("." + GROUP_HEADER_CONTENT_CLASS)
            },
            _getGroupHeaderCells: function() {
                return this.element().find("." + GROUP_HEADER_CLASS)
            },
            _getScrollCoordinates: function(hours, minutes, date) {
                var currentDate = date || new Date(this.option("currentDate")),
                    startDayHour = this.option("startDayHour"),
                    endDayHour = this.option("endDayHour");
                if (hours < startDayHour) {
                    hours = startDayHour
                }
                if (hours >= endDayHour) {
                    hours = endDayHour - 1
                }
                currentDate.setHours(hours);
                currentDate.setMinutes(minutes);
                return this.getCoordinatesByDate(currentDate)
            },
            setCellDataCache: function(cellCoordinates, groupIndex, $cell) {
                var cache = this.getCellDataCache(),
                    data = this.getCellData($cell);
                var key = JSON.stringify({
                    rowIndex: cellCoordinates.rowIndex,
                    cellIndex: cellCoordinates.cellIndex,
                    groupIndex: groupIndex
                });
                cache[key] = data
            },
            setCellDataCacheAlias: function(appointment, geometry) {
                var key = JSON.stringify({
                        rowIndex: appointment.rowIndex,
                        cellIndex: appointment.cellIndex,
                        groupIndex: appointment.groupIndex
                    }),
                    aliasKey = JSON.stringify({
                        top: geometry.top,
                        left: geometry.left
                    }),
                    cache = this.getCellDataCache();
                if (cache[key]) {
                    cache[aliasKey] = cache[key]
                }
            },
            getCellDataCache: function(key) {
                if (!this._cache) {
                    this._cache = {}
                }
                return key ? this._cache[key] : this._cache
            },
            _cleanCellDataCache: function() {
                delete this._cache
            },
            supportAllDayRow: function() {
                return true
            },
            getCellData: function($cell) {
                var data = $cell[0] ? $.data($cell[0], CELL_DATA) : void 0;
                return $.extend(true, {}, data)
            },
            getCoordinatesByDate: function(date, groupIndex, inAllDayRow) {
                groupIndex = groupIndex || 0;
                var index = this.getCellIndexByDate(date, inAllDayRow),
                    position = this._getCellPositionByIndex(index, groupIndex),
                    shift = this.getPositionShift(inAllDayRow ? 0 : this.getTimeShift(date));
                if (!position) {
                    throw errors.Error("E0139")
                }
                return {
                    top: position.top + shift.top,
                    left: position.left + shift.left,
                    rowIndex: position.rowIndex,
                    cellIndex: position.cellIndex,
                    max: this.getMaxAllowedPosition()[groupIndex],
                    groupIndex: groupIndex
                }
            },
            getCellIndexByDate: function(date, inAllDayRow) {
                var timeInterval = inAllDayRow ? 864e5 : this._getInterval(),
                    dateTimeStamp = this._getIntervalBetween(date, inAllDayRow);
                var index = Math.floor(dateTimeStamp / timeInterval);
                if (inAllDayRow) {
                    index = this._updateIndex(index)
                }
                if (index < 0) {
                    index = 0
                }
                return index
            },
            getPositionShift: function(timeShift) {
                return {
                    top: timeShift * this.getCellHeight(),
                    left: 0
                }
            },
            getTimeShift: function(date) {
                var cellDuration = this.getCellDuration(),
                    currentDayStart = new Date(date);
                currentDayStart.setMinutes(0);
                currentDayStart.setHours(this.option("startDayHour"));
                return (date.getTime() - currentDayStart.getTime()) % cellDuration / cellDuration
            },
            getCoordinatesByDateInGroup: function(date, appointmentResources, inAllDayRow) {
                var indexes = this._getGroupIndexes(appointmentResources),
                    result = [];
                if (indexes.length) {
                    for (var i = 0; i < indexes.length; i++) {
                        result.push(this.getCoordinatesByDate(date, indexes[i], inAllDayRow))
                    }
                } else {
                    result.push(this.getCoordinatesByDate(date, 0, inAllDayRow))
                }
                return result
            },
            getDroppableCellIndex: function() {
                var $droppableCell = this._getDroppableCell(),
                    $row = $droppableCell.parent(),
                    rowIndex = $row.index();
                return rowIndex * $row.find("td").length + $droppableCell.index()
            },
            getDataByDroppableCell: function() {
                var cellData = this.getCellData(this._getDroppableCell());
                return {
                    date: cellData.startDate,
                    allDay: cellData.allDay,
                    groups: cellData.groups
                }
            },
            getDateRange: function() {
                return [this.getStartViewDate(), this.getEndViewDate()]
            },
            getCellWidth: function() {
                return this._getCells().first().outerWidth()
            },
            getCellHeight: function() {
                return this._getCells().first().outerHeight()
            },
            getAllDayHeight: function() {
                return this.option("showAllDayPanel") ? this._getCells(true).first().outerHeight() : 0
            },
            getMaxAllowedPosition: function() {
                var result = [],
                    isRtl = this.option("rtlEnabled");
                this._$dateTable.find("tr").first().find("td:nth-child(" + this._getCellCount() + "n)").each(function(_, cell) {
                    var maxPosition = $(cell).position().left;
                    if (!isRtl) {
                        maxPosition += $(cell).outerWidth()
                    }
                    result.push(Math.floor(maxPosition))
                });
                return result
            },
            getFixedContainer: function() {
                return this._$fixedContainer
            },
            getAllDayContainer: function() {
                return this._$allDayContainer
            },
            getCellIndexByCoordinates: function(coordinates, allDay) {
                var cellCount = this._getTotalCellCount(this._getGroupCount()),
                    timePanelWidth = this.getTimePanelWidth(),
                    cellWidth = Math.floor(this._getWorkSpaceWidth() / cellCount),
                    leftOffset = this._isRTL() || this.option("crossScrollingEnabled") ? 0 : timePanelWidth,
                    topIndex = Math.floor(coordinates.top / (allDay ? this.getAllDayHeight() : this.getCellHeight())),
                    leftIndex = Math.floor((coordinates.left + 5 - leftOffset) / cellWidth);
                if (this._isRTL()) {
                    leftIndex = cellCount - leftIndex - 1
                }
                return cellCount * topIndex + leftIndex
            },
            getStartViewDate: function() {
                return this._firstViewDate
            },
            getEndViewDate: function() {
                var dateOfLastViewCell = this._getDateByCellIndexes(this._getRowCount() - 1, this._getCellCount() - 1);
                return new Date(dateOfLastViewCell.getTime() + this.getCellDuration() - 6e4)
            },
            getCellDuration: function() {
                return 36e5 * this.option("hoursInterval")
            },
            getGroupBounds: function(coordinates) {
                var cellIndex = this.getCellIndexByCoordinates(coordinates),
                    cellCount = this._getCellCount(),
                    groupIndex = Math.floor(cellIndex / cellCount),
                    $cells = this._getCells(),
                    cellWidth = this.getCellWidth(),
                    startCellIndex = groupIndex * cellCount,
                    startOffset = $cells.eq(startCellIndex).offset().left - cellWidth / 2,
                    endOffset = $cells.eq(startCellIndex + cellCount - 1).offset().left + cellWidth + cellWidth / 2;
                var result = {
                    left: startOffset,
                    right: endOffset
                };
                if (this._isRTL()) {
                    result.left = endOffset - 2 * cellWidth;
                    result.right = startOffset + 2 * cellWidth
                }
                return result
            },
            getCellDataByCoordinates: function(coordinates, allDay) {
                var key = JSON.stringify({
                        top: coordinates.top,
                        left: coordinates.left
                    }),
                    data = this.getCellDataCache(key);
                if (data) {
                    return data
                }
                var $cells = this._getCells(allDay),
                    cellIndex = this.getCellIndexByCoordinates(coordinates, allDay),
                    $cell = $cells.eq(cellIndex);
                return this.getCellData($cell)
            },
            getVisibleBounds: function() {
                var result = {},
                    $scrollable = this.getScrollable().element(),
                    cellHeight = this.getCellHeight(),
                    scrolledCellCount = this.getScrollableScrollTop() / cellHeight,
                    totalCellCount = scrolledCellCount + $scrollable.height() / cellHeight;
                result.top = {
                    hours: Math.floor(scrolledCellCount * this.option("hoursInterval")) + this.option("startDayHour"),
                    minutes: scrolledCellCount % 2 ? 30 : 0
                };
                result.bottom = {
                    hours: Math.floor(totalCellCount * this.option("hoursInterval")) + this.option("startDayHour"),
                    minutes: Math.floor(totalCellCount) % 2 ? 30 : 0
                };
                return result
            },
            updateScrollPosition: function(date) {
                date = this.invoke("convertDateByTimezone", date);
                var bounds = this.getVisibleBounds(),
                    startDateHour = date.getHours(),
                    startDateMinutes = date.getMinutes();
                if (this.needUpdateScrollPosition(startDateHour, startDateMinutes, bounds, date)) {
                    this.scrollToTime(startDateHour, startDateMinutes, date)
                }
            },
            needUpdateScrollPosition: function(hours, minutes, bounds) {
                var isUpdateNeeded = false;
                if (hours < bounds.top.hours || hours > bounds.bottom.hours) {
                    isUpdateNeeded = true
                }
                if (hours === bounds.top.hours && minutes < bounds.top.minutes) {
                    isUpdateNeeded = true
                }
                if (hours === bounds.bottom.hours && minutes > bounds.top.minutes) {
                    isUpdateNeeded = true
                }
                return isUpdateNeeded
            },
            getGroupWidth: function(groupIndex) {
                var result = this._getCellCount() * this.getCellWidth(),
                    position = this.getMaxAllowedPosition(),
                    currentPosition = position[groupIndex];
                if (position.length && currentPosition) {
                    if (this._isRTL()) {
                        result = currentPosition - position[groupIndex + 1]
                    } else {
                        if (0 === groupIndex) {
                            result = currentPosition
                        } else {
                            result = currentPosition - position[groupIndex - 1]
                        }
                    }
                }
                return result
            },
            restoreScrollTop: function() {
                this.element().scrollTop(0)
            },
            scrollToTime: function(hours, minutes, date) {
                var coordinates = this._getScrollCoordinates(hours, minutes, date),
                    scrollable = this.getScrollable();
                scrollable.scrollBy(coordinates.top - scrollable.scrollTop())
            },
            getDistanceBetweenCells: function(startIndex, endIndex) {
                var result = 0;
                this.element().find("." + this._getDateTableRowClass()).first().find("." + this._getDateTableCellClass()).each(function(index) {
                    if (index < startIndex || index > endIndex) {
                        return true
                    }
                    result += $(this).outerWidth()
                });
                return result
            }
        }).include(publisherMixin);
        registerComponent("dxSchedulerWorkSpace", SchedulerWorkSpace);
        module.exports = SchedulerWorkSpace
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.table_creator.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var SchedulerTableCreator = {
            VERTICAL: "vertical",
            HORIZONTAL: "horizontal",
            makeTable: function(options) {
                var tableBody = document.createElement("tbody");
                for (var i = 0; i < options.rowCount; i++) {
                    var row = document.createElement("tr");
                    if (options.rowClass) {
                        row.className = options.rowClass
                    }
                    for (var j = 0; j < options.cellCount; j++) {
                        var td = document.createElement("td");
                        if (options.getCellText) {
                            td.innerHTML = options.getCellText(i, j)
                        }
                        if (options.cellClass) {
                            td.className = options.cellClass
                        }
                        if (options.dataGenerator) {
                            options.dataGenerator(td, i, j)
                        }
                        row.appendChild(td)
                    }
                    tableBody.appendChild(row)
                }
                return tableBody
            },
            makeGroupedTable: function(type, groups, cssClasses, cellCount) {
                var rows = [];
                if (type === this.VERTICAL) {
                    rows = this._makeVerticalGroupedRows(groups, cssClasses)
                } else {
                    rows = this._makeHorizontalGroupedRows(groups, cssClasses, cellCount)
                }
                return rows
            },
            makeGroupedTableFromJSON: function(type, data, config) {
                var table, cellStorage = [],
                    rowIndex = 0;
                config = config || {};
                var cellTag = config.cellTag || "td",
                    childrenField = config.childrenField || "children",
                    titleField = config.titleField || "title",
                    groupTableClass = config.groupTableClass,
                    groupRowClass = config.groupRowClass,
                    groupCellClass = config.groupCellClass,
                    groupCellCustomContent = config.groupCellCustomContent;

                function createTable() {
                    table = document.createElement("table");
                    if (groupTableClass) {
                        table.className = groupTableClass
                    }
                }

                function getChildCount(item) {
                    if (item[childrenField]) {
                        return item[childrenField].length
                    }
                    return 0
                }

                function createCell(text, childCount) {
                    var cell = {
                        element: document.createElement(cellTag),
                        childCount: childCount
                    };
                    if (groupCellClass) {
                        cell.element.className = groupCellClass
                    }
                    var cellText = document.createTextNode(text);
                    if ("function" === typeof groupCellCustomContent) {
                        groupCellCustomContent(cell.element, cellText)
                    } else {
                        cell.element.appendChild(cellText)
                    }
                    return cell
                }

                function generateCells(data) {
                    for (var i = 0; i < data.length; i++) {
                        var childCount = getChildCount(data[i]),
                            cell = createCell(data[i][titleField], childCount);
                        if (!cellStorage[rowIndex]) {
                            cellStorage[rowIndex] = []
                        }
                        cellStorage[rowIndex].push(cell);
                        if (childCount) {
                            generateCells(data[i][childrenField])
                        } else {
                            rowIndex++
                        }
                    }
                }

                function putCellsToRows() {
                    cellStorage.forEach(function(cells) {
                        var row = document.createElement("tr");
                        if (groupRowClass) {
                            row.className = groupRowClass
                        }
                        var rowspans = [];
                        for (var i = cells.length - 1; i >= 0; i--) {
                            var prev = cells[i + 1],
                                rowspan = cells[i].childCount;
                            if (prev && prev.childCount) {
                                rowspan *= prev.childCount
                            }
                            rowspans.push(rowspan)
                        }
                        rowspans.reverse();
                        cells.forEach(function(cell, index) {
                            if (rowspans[index]) {
                                cell.element.setAttribute("rowspan", rowspans[index])
                            }
                            row.appendChild(cell.element)
                        });
                        table.appendChild(row)
                    })
                }
                createTable();
                generateCells(data);
                putCellsToRows();
                return table
            },
            _makeVerticalGroupedRows: function(groups, cssClasses) {
                var i, repeatCount = 1,
                    arr = [];
                for (i = 0; i < groups.length; i++) {
                    if (i > 0) {
                        repeatCount = groups[i - 1].items.length * repeatCount
                    }
                    var cells = this._makeGroupedRowCells(groups[i].items, repeatCount, cssClasses);
                    arr.push(cells)
                }
                var rows = [],
                    groupCount = arr.length,
                    maxCellCount = arr[groupCount - 1].length;
                for (i = 0; i < maxCellCount; i++) {
                    rows.push($("<tr>").addClass(cssClasses.groupHeaderRowClass))
                }
                for (i = groupCount - 1; i >= 0; i--) {
                    var currentColumnLength = arr[i].length,
                        rowspan = maxCellCount / currentColumnLength;
                    for (var j = 0; j < currentColumnLength; j++) {
                        var currentRowIndex = j * rowspan,
                            row = rows[currentRowIndex];
                        row.prepend(arr[i][j].attr("rowspan", rowspan))
                    }
                }
                return rows
            },
            _makeHorizontalGroupedRows: function(groups, cssClasses, cellCount) {
                var repeatCount = 1,
                    groupCount = groups.length,
                    rows = [];
                for (var i = 0; i < groupCount; i++) {
                    if (i > 0) {
                        repeatCount = groups[i - 1].items.length * repeatCount
                    }
                    var cells = this._makeGroupedRowCells(groups[i].items, repeatCount, cssClasses);
                    rows.push($("<tr>").addClass(cssClasses.groupRowClass).append(cells))
                }
                var maxCellCount = rows[groupCount - 1].find("th").length;
                for (var j = 0; j < groupCount; j++) {
                    var $cell = rows[j].find("th"),
                        colspan = maxCellCount / $cell.length * cellCount;
                    if (colspan > 1) {
                        $cell.attr("colspan", colspan)
                    }
                }
                return rows
            },
            _makeGroupedRowCells: function(items, repeatCount, cssClasses) {
                var cells = [],
                    itemCount = items.length;
                for (var i = 0; i < repeatCount; i++) {
                    for (var j = 0; j < itemCount; j++) {
                        cells.push($("<th>").addClass(cssClasses.groupHeaderClass).html("<div class='" + cssClasses.groupHeaderContentClass + "'><div>" + items[j].text + "</div></div>"))
                    }
                }
                return cells
            }
        };
        module.exports = SchedulerTableCreator
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.work_space_week.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerWorkSpace = __webpack_require__( /*! ./ui.scheduler.work_space */ 413);
        var WEEK_CLASS = "dx-scheduler-work-space-week";
        var SchedulerWorkSpaceWeek = SchedulerWorkSpace.inherit({
            _getElementClass: function() {
                return WEEK_CLASS
            },
            _getRowCount: function() {
                return this._getCellCountInDay()
            },
            _getCellCount: function() {
                return 7
            },
            _getDateByIndex: function(headerIndex) {
                var resultDate = new Date(this._firstViewDate);
                resultDate.setDate(this._firstViewDate.getDate() + headerIndex);
                return resultDate
            },
            _getFormat: function() {
                return "E d"
            },
            _getCellsBetween: function($first, $last) {
                if (this._hasAllDayClass($last)) {
                    return this.callBase($first, $last)
                }
                var $cells = this._getCells(),
                    firstColumn = $first.index(),
                    firstRow = $first.parent().index(),
                    lastColumn = $last.index(),
                    lastRow = $last.parent().index(),
                    groupCount = this._getGroupCount(),
                    cellCount = groupCount > 0 ? this._getTotalCellCount(groupCount) : this._getCellCount(),
                    rowCount = this._getTotalRowCount(groupCount),
                    result = [];
                for (var i = 0; i < cellCount; i++) {
                    for (var j = 0; j < rowCount; j++) {
                        var cell = $cells.get(cellCount * j + i);
                        result.push(cell)
                    }
                }
                var newFirstIndex = rowCount * firstColumn + firstRow,
                    newLastIndex = rowCount * lastColumn + lastRow;
                if (newFirstIndex > newLastIndex) {
                    var buffer = newFirstIndex;
                    newFirstIndex = newLastIndex;
                    newLastIndex = buffer
                }
                $cells = $(result).slice(newFirstIndex, newLastIndex + 1);
                if (!!this._getGroupCount()) {
                    var arr = [],
                        focusedGroupIndex = this._getGroupIndexByCell($first);
                    $.each($cells, $.proxy(function(_, cell) {
                        var groupIndex = this._getGroupIndexByCell($(cell));
                        if (focusedGroupIndex === groupIndex) {
                            arr.push(cell)
                        }
                    }, this));
                    $cells = $(arr)
                }
                return $cells
            },
            _getRightCell: function(isMultiSelection) {
                if (!isMultiSelection) {
                    return this.callBase(isMultiSelection)
                }
                var $rightCell, $focusedCell = this._$focusedCell,
                    groupCount = this._getGroupCount(),
                    rowCellCount = isMultiSelection ? this._getCellCount() : this._getTotalCellCount(groupCount),
                    edgeCellIndex = this._isRTL() ? 0 : rowCellCount - 1,
                    direction = this._isRTL() ? "prev" : "next";
                if ($focusedCell.index() === edgeCellIndex || this._isGroupEndCell($focusedCell)) {
                    $rightCell = $focusedCell
                } else {
                    $rightCell = $focusedCell[direction]();
                    $rightCell = this._checkForViewBounds($rightCell)
                }
                return $rightCell
            },
            _getLeftCell: function(isMultiSelection) {
                if (!isMultiSelection) {
                    return this.callBase(isMultiSelection)
                }
                var $leftCell, $focusedCell = this._$focusedCell,
                    groupCount = this._getGroupCount(),
                    rowCellCount = isMultiSelection ? this._getCellCount() : this._getTotalCellCount(groupCount),
                    edgeCellIndex = this._isRTL() ? rowCellCount - 1 : 0,
                    direction = this._isRTL() ? "next" : "prev";
                if ($focusedCell.index() === edgeCellIndex || this._isGroupStartCell($focusedCell)) {
                    $leftCell = $focusedCell
                } else {
                    $leftCell = $focusedCell[direction]();
                    $leftCell = this._checkForViewBounds($leftCell)
                }
                return $leftCell
            }
        });
        registerComponent("dxSchedulerWorkSpaceWeek", SchedulerWorkSpaceWeek);
        module.exports = SchedulerWorkSpaceWeek
    },
    /*!*******************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.work_space_work_week.js ***!
      \*******************************************************************/
    function(module, exports, __webpack_require__) {
        var registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerWorkSpaceWeek = __webpack_require__( /*! ./ui.scheduler.work_space_week */ 415),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var WORK_WEEK_CLASS = "dx-scheduler-work-space-work-week";
        var weekendCounter = 0;
        var SchedulerWorkSpaceWorkWeek = SchedulerWorkSpaceWeek.inherit({
            _getElementClass: function() {
                return WORK_WEEK_CLASS
            },
            _getCellCount: function() {
                return 5
            },
            _firstDayOfWeek: function() {
                return this.option("firstDayOfWeek") || 1
            },
            _getDateByIndex: function(headerIndex) {
                var resultDate = new Date(this._firstViewDate);
                resultDate.setDate(this._firstViewDate.getDate() + headerIndex + weekendCounter);
                var day = resultDate.getDay();
                if (day % 6 === 0) {
                    weekendCounter = Math.floor(day / 6 + 1);
                    resultDate.setDate(resultDate.getDate() + weekendCounter)
                }
                return resultDate
            },
            _renderView: function() {
                weekendCounter = 0;
                this.callBase()
            },
            _setFirstViewDate: function() {
                this._firstViewDate = dateUtils.getFirstWeekDate(this.option("currentDate"), this._firstDayOfWeek() || dateLocalization.firstDayOfWeekIndex());
                this._firstViewDate = dateUtils.normalizeDateByWeek(this._firstViewDate, this.option("currentDate"));
                this._setStartDayHour(this._firstViewDate)
            }
        });
        registerComponent("dxSchedulerWorkSpaceWorkWeek", SchedulerWorkSpaceWorkWeek);
        module.exports = SchedulerWorkSpaceWorkWeek
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.work_space_month.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerWorkSpace = __webpack_require__( /*! ./ui.scheduler.work_space */ 413),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var MONTH_CLASS = "dx-scheduler-work-space-month",
            DATE_TABLE_CURRENT_DATE_CLASS = "dx-scheduler-date-table-current-date",
            DATE_TABLE_OTHER_MONTH_DATE_CLASS = "dx-scheduler-date-table-other-month";
        var DAYS_IN_WEEK = 7,
            DAY_IN_MILLISECONDS = 864e5;
        var SchedulerWorkSpaceMonth = SchedulerWorkSpace.inherit({
            _getElementClass: function() {
                return MONTH_CLASS
            },
            _getRowCount: function() {
                return 6
            },
            _getCellCount: function() {
                return DAYS_IN_WEEK
            },
            _getDateByIndex: function(headerIndex) {
                var resultDate = new Date(this._firstViewDate);
                resultDate.setDate(this._firstViewDate.getDate() + headerIndex);
                return resultDate
            },
            _getFormat: function() {
                return "E"
            },
            _calculateCellIndex: function(rowIndex, cellIndex) {
                cellIndex %= this._getCellCount();
                return rowIndex * this._getCellCount() + cellIndex
            },
            _getInterval: function() {
                return DAY_IN_MILLISECONDS
            },
            _getIntervalBetween: function(currentDate) {
                var firstViewDate = this.getStartViewDate(),
                    timeZoneOffset = dateUtils.getTimezonesDifference(firstViewDate, currentDate);
                return currentDate.getTime() - (firstViewDate.getTime() - 36e5 * this.option("startDayHour")) - timeZoneOffset
            },
            _getDateByCellIndexes: function(rowIndex, cellIndex) {
                var date = this.callBase(rowIndex, cellIndex);
                this._setStartDayHour(date);
                return date
            },
            _calculateHiddenInterval: function() {
                return 0
            },
            _getCellCoordinatesByIndex: function(index) {
                var rowIndex = Math.floor(index / this._getCellCount()),
                    cellIndex = index - this._getCellCount() * rowIndex;
                return {
                    rowIndex: rowIndex,
                    cellIndex: cellIndex
                }
            },
            _renderTimePanel: $.noop,
            _renderAllDayPanel: $.noop,
            _getTableAllDay: $.noop,
            _toggleAllDayVisibility: $.noop,
            _changeAllDayVisibility: $.noop,
            _setFirstViewDate: function() {
                var firstMonthDate = dateUtils.getFirstMonthDate(this.option("currentDate"));
                this._firstViewDate = dateUtils.getFirstWeekDate(firstMonthDate, this.option("firstDayOfWeek") || dateLocalization.firstDayOfWeekIndex());
                this._setStartDayHour(this._firstViewDate)
            },
            _renderTableBody: function(options) {
                options.getCellText = $.proxy(this._getCellText, this);
                this.callBase(options)
            },
            _getCellText: function(rowIndex, cellIndex) {
                cellIndex %= this._getCellCount();
                var date = this._getDate(rowIndex, cellIndex);
                return dateLocalization.format(date, "dd")
            },
            _getDate: function(week, day) {
                var result = new Date(this._firstViewDate);
                result.setDate(result.getDate() + week * DAYS_IN_WEEK + day);
                return result
            },
            _updateIndex: function(index) {
                return index
            },
            _prepareCellData: function(cell, rowIndex, cellIndex) {
                var data = this.callBase(cell, rowIndex, cellIndex),
                    $cell = $(cell);
                $cell.toggleClass(DATE_TABLE_CURRENT_DATE_CLASS, this._isCurrentDate(data.startDate)).toggleClass(DATE_TABLE_OTHER_MONTH_DATE_CLASS, this._isOtherMonth(data.startDate));
                return data
            },
            _isCurrentDate: function(cellDate) {
                var today = new Date;
                return dateUtils.sameDate(cellDate, today)
            },
            _isOtherMonth: function(cellDate) {
                return cellDate.getMonth() !== this.option("currentDate").getMonth()
            },
            getCellDuration: function() {
                return 36e5 * this._calculateDayDuration()
            },
            getTimePanelWidth: function() {
                return 0
            },
            getPositionShift: function() {
                return {
                    top: 0,
                    left: 0
                }
            },
            getCoordinatesByDates: function(startDate, endDate) {
                var result = [],
                    date = new Date(startDate);
                while (date <= endDate) {
                    result.push(this.getCoordinatesByDate(date));
                    date.setDate(date.getDate() + 7);
                    date = dateUtils.getFirstWeekDate(date, this.option("firstDayOfWeek") || dateLocalization.firstDayOfWeekIndex())
                }
                return result
            },
            getCellCountToLastViewDate: function(date) {
                var firstDateTime = dateUtils.makeDate(date).getTime(),
                    lastDateTime = this.getEndViewDate().getTime(),
                    dayDurationInMs = this.getCellDuration();
                return Math.ceil((lastDateTime - firstDateTime) / dayDurationInMs)
            },
            supportAllDayRow: function() {
                return false
            },
            calculateEndDate: function(startDate) {
                var startDateCopy = new Date(startDate);
                return new Date(startDateCopy.setHours(this.option("endDayHour")))
            },
            _getCellPositionByIndex: function(index, groupIndex) {
                var position = this.callBase(index, groupIndex),
                    rowIndex = this._getCellCoordinatesByIndex(index).rowIndex,
                    calculatedTopOffset = this.getCellHeight() * rowIndex;
                if (calculatedTopOffset) {
                    position.top = calculatedTopOffset
                }
                return position
            },
            scrollToTime: $.noop
        });
        registerComponent("dxSchedulerWorkSpaceMonth", SchedulerWorkSpaceMonth);
        module.exports = SchedulerWorkSpaceMonth
    },
    /*!***********************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timeline_day.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerTimeline = __webpack_require__( /*! ./ui.scheduler.timeline */ 419);
        var TIMELINE_CLASS = "dx-scheduler-timeline-day";
        var SchedulerTimelineDay = SchedulerTimeline.inherit({
            _getElementClass: function() {
                return TIMELINE_CLASS
            },
            _setFirstViewDate: function() {
                this._firstViewDate = this.option("currentDate");
                this._setStartDayHour(this._firstViewDate)
            }
        });
        registerComponent("dxSchedulerTimelineDay", SchedulerTimelineDay);
        module.exports = SchedulerTimelineDay
    },
    /*!*******************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timeline.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerWorkSpace = __webpack_require__( /*! ./ui.scheduler.work_space */ 413),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            tableCreator = __webpack_require__( /*! ./ui.scheduler.table_creator */ 414);
        var TIMELINE_CLASS = "dx-scheduler-timeline",
            GROUP_TABLE_CLASS = "dx-scheduler-group-table";
        var HORIZONTAL = "horizontal",
            DATE_TABLE_CELL_HEIGHT = 75,
            toMs = dateUtils.dateToMilliseconds;
        var SchedulerTimeline = SchedulerWorkSpace.inherit({
            _init: function() {
                this.callBase();
                this.element().addClass(TIMELINE_CLASS);
                this._$sidebarTable = $("<table>").addClass(GROUP_TABLE_CLASS)
            },
            _getCellFromNextRow: function(direction, isMultiSelection) {
                if (!isMultiSelection) {
                    return this.callBase(direction, isMultiSelection)
                }
                return this._$focusedCell
            },
            _getRightCell: function(isMultiSelection) {
                var $rightCell, $focusedCell = this._$focusedCell,
                    rowCellCount = this._getCellCount(),
                    edgeCellIndex = this._isRTL() ? 0 : rowCellCount - 1,
                    direction = this._isRTL() ? "prev" : "next";
                if ($focusedCell.index() === edgeCellIndex) {
                    $rightCell = $focusedCell
                } else {
                    $rightCell = $focusedCell[direction]();
                    $rightCell = this._checkForViewBounds($rightCell)
                }
                return $rightCell
            },
            _getLeftCell: function(isMultiSelection) {
                var $leftCell, $focusedCell = this._$focusedCell,
                    rowCellCount = this._getCellCount(),
                    edgeCellIndex = this._isRTL() ? rowCellCount - 1 : 0,
                    direction = this._isRTL() ? "next" : "prev";
                if ($focusedCell.index() === edgeCellIndex) {
                    $leftCell = $focusedCell
                } else {
                    $leftCell = $focusedCell[direction]();
                    $leftCell = this._checkForViewBounds($leftCell)
                }
                return $leftCell
            },
            _getRowCount: function() {
                return 1
            },
            _getCellCount: function() {
                return this._getCellCountInDay()
            },
            _getTotalCellCount: function(groupCount) {
                return this._getCellCount()
            },
            _getTotalRowCount: function(groupCount) {
                groupCount = groupCount || 1;
                return this._getRowCount() * groupCount
            },
            _getDateByIndex: function(index) {
                var resultDate = new Date(this._firstViewDate),
                    dayIndex = Math.floor(index / this._getCellCountInDay());
                resultDate.setTime(this._firstViewDate.getTime() + this._calculateCellIndex(0, index) * this._getInterval() + dayIndex * this._getHiddenInterval());
                return resultDate
            },
            _getFormat: function() {
                return "shorttime"
            },
            _calculateHiddenInterval: function(rowIndex, cellIndex) {
                var dayIndex = Math.floor(cellIndex / this._getCellCountInDay());
                return dayIndex * this._getHiddenInterval()
            },
            _createWorkSpaceElements: function() {
                this._createWorkSpaceScrollableElements()
            },
            _getWorkSpaceHeight: function() {
                if (this.option("crossScrollingEnabled")) {
                    return this._$dateTable.outerHeight()
                }
                return this.element().outerHeight()
            },
            _dateTableScrollableConfig: function() {
                var that = this,
                    config = this.callBase(),
                    timelineConfig = {
                        direction: HORIZONTAL,
                        onScroll: function(e) {
                            that._headerScrollable.scrollTo({
                                left: e.scrollOffset.left
                            })
                        }
                    };
                return this.option("crossScrollingEnabled") ? config : $.extend(config, timelineConfig)
            },
            _renderTimePanel: $.noop,
            _renderAllDayPanel: $.noop,
            _getTableAllDay: function() {
                return false
            },
            _toggleAllDayVisibility: $.noop,
            _changeAllDayVisibility: $.noop,
            supportAllDayRow: function() {
                return false
            },
            _getGroupHeaderContainer: function() {
                return this._$sidebarTable
            },
            _renderView: function() {
                this.callBase();
                this._$sidebarTable.appendTo(this._sidebarScrollable.content());
                this._setGroupHeaderCellsHeight()
            },
            _cleanView: function() {
                this.callBase();
                this._$sidebarTable.empty()
            },
            _visibilityChanged: function(visible) {
                this._setGroupHeaderCellsHeight();
                this.callBase(visible)
            },
            _setTableSizes: function() {
                this.callBase();
                var cellHeight = DATE_TABLE_CELL_HEIGHT,
                    minHeight = this._getWorkSpaceMinHeight(),
                    $groupCells = this._$sidebarTable.find("tr");
                var height = cellHeight * $groupCells.length;
                if (height < minHeight) {
                    height = minHeight
                }
                this._$sidebarTable.height(height);
                this._$dateTable.height(height)
            },
            _getWorkSpaceMinHeight: function() {
                var minHeight = this._getWorkSpaceHeight(),
                    workspaceContainerHeight = this.element().outerHeight(true) - this.getHeaderPanelHeight();
                if (minHeight < workspaceContainerHeight) {
                    minHeight = workspaceContainerHeight
                }
                return minHeight
            },
            _makeGroupRows: function(groups) {
                return tableCreator.makeGroupedTable(tableCreator.VERTICAL, groups, {
                    groupHeaderRowClass: this._getGroupRowClass(),
                    groupHeaderClass: this._getGroupHeaderClass(),
                    groupHeaderContentClass: this._getGroupHeaderContentClass()
                })
            },
            _setGroupHeaderCellsHeight: function() {
                var cellHeight = this.getCellHeight() - 1;
                cellHeight = this._ensureGroupHeaderCellsHeight(cellHeight);
                this._getGroupHeaderCellsContent().css("height", cellHeight)
            },
            _ensureGroupHeaderCellsHeight: function(cellHeight) {
                var minCellHeight = this._calculateMinCellHeight();
                if (cellHeight < minCellHeight) {
                    return minCellHeight
                }
                return cellHeight
            },
            _calculateMinCellHeight: function() {
                var dateTable = this._getDateTable(),
                    dateTableRowSelector = "." + this._getDateTableRowClass();
                return dateTable.outerHeight() / dateTable.find(dateTableRowSelector).length - 1
            },
            _attachGroupCountAttr: function() {
                this.element().attr("dx-group-column-count", this.option("groups").length)
            },
            _getCellCoordinatesByIndex: function(index) {
                return {
                    cellIndex: index % this._getCellCount(),
                    rowIndex: 0
                }
            },
            _getCellByCoordinates: function(cellCoordinates, groupIndex) {
                return this._$dateTable.find("tr").eq(cellCoordinates.rowIndex + groupIndex).find("td").eq(cellCoordinates.cellIndex)
            },
            _calculateCellIndex: function(rowIndex, cellIndex) {
                return cellIndex
            },
            _getGroupIndex: function(rowIndex, cellIndex) {
                return rowIndex
            },
            _getWorkSpaceWidth: function() {
                return this._$dateTable.outerWidth(true)
            },
            _calculateHeaderCellRepeatCount: function() {
                return 1
            },
            _getGroupIndexByCell: function($cell) {
                return $cell.parent().index()
            },
            _getIntervalBetween: function(currentDate, allDay) {
                var startDayHour = this.option("startDayHour"),
                    endDayHour = this.option("endDayHour"),
                    firstViewDate = this.getStartViewDate(),
                    firstViewDateTime = firstViewDate.getTime(),
                    hiddenInterval = (24 - endDayHour + startDayHour) * toMs("hour"),
                    timeZoneOffset = dateUtils.getTimezonesDifference(firstViewDate, currentDate),
                    apptStart = currentDate.getTime(),
                    fullInterval = apptStart - firstViewDateTime - timeZoneOffset,
                    fullDays = Math.floor(fullInterval / toMs("day")),
                    tailDuration = fullInterval - fullDays * toMs("day"),
                    tailDelta = 0,
                    cellCount = this._getCellCountInDay() * fullDays,
                    gapBeforeAppt = apptStart - dateUtils.trimTime(new Date(currentDate)).getTime(),
                    result = cellCount * this.option("hoursInterval") * toMs("hour");
                if (!allDay) {
                    if (currentDate.getHours() < startDayHour) {
                        tailDelta = tailDuration - hiddenInterval + gapBeforeAppt
                    } else {
                        if (currentDate.getHours() >= startDayHour && currentDate.getHours() < endDayHour) {
                            tailDelta = tailDuration
                        } else {
                            if (currentDate.getHours() >= startDayHour && currentDate.getHours() >= endDayHour) {
                                tailDelta = tailDuration - (gapBeforeAppt - endDayHour * toMs("hour"))
                            } else {
                                if (!fullDays) {
                                    result = fullInterval
                                }
                            }
                        }
                    }
                    result += tailDelta
                }
                return result
            },
            getAllDayContainer: function() {
                return null
            },
            getTimePanelWidth: function() {
                return 0
            },
            getPositionShift: function(timeShift) {
                var positionShift = this.callBase(timeShift),
                    left = this.getCellWidth() * timeShift;
                if (this.option("rtlEnabled")) {
                    left *= -1
                }
                left += positionShift.left;
                return {
                    top: 0,
                    left: left
                }
            },
            getVisibleBounds: function() {
                var isRtl = this.option("rtlEnabled");
                var result = {},
                    $scrollable = this.getScrollable().element(),
                    cellWidth = this.getCellWidth(),
                    scrollableOffset = isRtl ? this.getScrollableOuterWidth() - this.getScrollableScrollLeft() : this.getScrollableScrollLeft(),
                    scrolledCellCount = scrollableOffset / cellWidth,
                    visibleCellCount = $scrollable.width() / cellWidth,
                    totalCellCount = isRtl ? scrolledCellCount - visibleCellCount : scrolledCellCount + visibleCellCount,
                    leftDate = this._getDateByIndex(scrolledCellCount),
                    rightDate = this._getDateByIndex(totalCellCount);
                if (isRtl) {
                    leftDate = this._getDateByIndex(totalCellCount);
                    rightDate = this._getDateByIndex(scrolledCellCount)
                }
                result.left = {
                    hours: leftDate.getHours(),
                    minutes: leftDate.getMinutes() >= 30 ? 30 : 0,
                    date: dateUtils.trimTime(leftDate)
                };
                result.right = {
                    hours: rightDate.getHours(),
                    minutes: rightDate.getMinutes() >= 30 ? 30 : 0,
                    date: dateUtils.trimTime(rightDate)
                };
                return result
            },
            needUpdateScrollPosition: function(hours, minutes, bounds, date) {
                var isUpdateNeeded = false;
                isUpdateNeeded = this._dateWithinBounds(bounds, date);
                if (hours < bounds.left.hours || hours > bounds.right.hours) {
                    isUpdateNeeded = true
                }
                if (hours === bounds.left.hours && minutes < bounds.left.minutes) {
                    isUpdateNeeded = true
                }
                if (hours === bounds.right.hours && minutes > bounds.right.minutes) {
                    isUpdateNeeded = true
                }
                return isUpdateNeeded
            },
            _dateWithinBounds: function(bounds, date) {
                var trimmedDate = dateUtils.trimTime(new Date(date)),
                    isUpdateNeeded = false;
                if (trimmedDate.getTime() < bounds.left.date.getTime() || trimmedDate.getTime() > bounds.right.date.getTime()) {
                    isUpdateNeeded = true
                }
                return isUpdateNeeded
            },
            scrollToTime: function(hours, minutes, date) {
                var coordinates = this._getScrollCoordinates(hours, minutes, date),
                    scrollable = this.getScrollable(),
                    offset = this.option("rtlEnabled") ? this.getScrollableContainer().outerWidth() : 0;
                scrollable.scrollBy({
                    left: coordinates.left - scrollable.scrollLeft() - offset,
                    top: 0
                })
            }
        });
        registerComponent("dxSchedulerTimeline", SchedulerTimeline);
        module.exports = SchedulerTimeline
    },
    /*!************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timeline_week.js ***!
      \************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerTimeline = __webpack_require__( /*! ./ui.scheduler.timeline */ 419),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var TIMELINE_CLASS = "dx-scheduler-timeline-week",
            HEADER_PANEL_CELL_CLASS = "dx-scheduler-header-panel-cell",
            HEADER_ROW_CLASS = "dx-scheduler-header-row",
            CELL_WIDTH = 200;
        var SchedulerTimelineWeek = SchedulerTimeline.inherit({
            _getElementClass: function() {
                return TIMELINE_CLASS
            },
            _getCellCount: function() {
                return this.callBase() * this._getWeekDuration()
            },
            _renderDateHeader: function() {
                var $headerRow = this.callBase(),
                    firstViewDate = new Date(this._firstViewDate),
                    $cells = [],
                    colspan = this._getCellCountInDay(),
                    headerCellWidth = colspan * CELL_WIDTH;
                for (var i = 0; i < this._getWeekDuration(); i++) {
                    $cells.push($("<th>").addClass(HEADER_PANEL_CELL_CLASS).text(dateLocalization.format(firstViewDate, "E d")).attr("colspan", colspan).width(headerCellWidth));
                    firstViewDate.setDate(firstViewDate.getDate() + 1)
                }
                var $row = $("<tr>").addClass(HEADER_ROW_CLASS).append($cells);
                $headerRow.before($row)
            },
            _getWeekDuration: function() {
                return 7
            }
        });
        registerComponent("dxSchedulerTimelineWeek", SchedulerTimelineWeek);
        module.exports = SchedulerTimelineWeek
    },
    /*!*****************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timeline_work_week.js ***!
      \*****************************************************************/
    function(module, exports, __webpack_require__) {
        var registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerTimelineWeek = __webpack_require__( /*! ./ui.scheduler.timeline_week */ 420),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52);
        var TIMELINE_CLASS = "dx-scheduler-timeline-work-week",
            MONDAY_INDEX = 1;
        var SchedulerTimelineWorkWeek = SchedulerTimelineWeek.inherit({
            _getElementClass: function() {
                return TIMELINE_CLASS
            },
            _getWeekDuration: function() {
                return 5
            },
            _firstDayOfWeek: function() {
                return this.option("firstDayOfWeek") || MONDAY_INDEX
            },
            _setFirstViewDate: function() {
                this._firstViewDate = dateUtils.getFirstWeekDate(this.option("currentDate"), this._firstDayOfWeek());
                this._firstViewDate = dateUtils.normalizeDateByWeek(this._firstViewDate, this.option("currentDate"));
                this._setStartDayHour(this._firstViewDate)
            }
        });
        registerComponent("dxSchedulerTimelineWorkWeek", SchedulerTimelineWorkWeek);
        module.exports = SchedulerTimelineWorkWeek
    },
    /*!*************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timeline_month.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerTimeline = __webpack_require__( /*! ./ui.scheduler.timeline */ 419),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52);
        var TIMELINE_CLASS = "dx-scheduler-timeline-month",
            DAY_IN_MILLISECONDS = 864e5;
        var SchedulerTimelineMonth = SchedulerTimeline.inherit({
            _getElementClass: function() {
                return TIMELINE_CLASS
            },
            _getCellCount: function() {
                var currentDate = this.option("currentDate");
                return new Date(currentDate.getFullYear(), currentDate.getMonth() + 1, 0).getDate()
            },
            _setFirstViewDate: function() {
                this._firstViewDate = dateUtils.getFirstMonthDate(this.option("currentDate"));
                this._setStartDayHour(this._firstViewDate)
            },
            _getFormat: function() {
                return "E d"
            },
            _getDateByIndex: function(headerIndex) {
                var resultDate = new Date(this._firstViewDate);
                resultDate.setDate(this._firstViewDate.getDate() + headerIndex);
                return resultDate
            },
            _getInterval: function() {
                return DAY_IN_MILLISECONDS
            },
            _getIntervalBetween: function(currentDate) {
                var firstViewDate = this.getStartViewDate(),
                    timeZoneOffset = dateUtils.getTimezonesDifference(firstViewDate, currentDate);
                return currentDate.getTime() - (firstViewDate.getTime() - 36e5 * this.option("startDayHour")) - timeZoneOffset
            },
            calculateEndDate: function(startDate) {
                var startDateCopy = new Date(startDate);
                return new Date(startDateCopy.setHours(this.option("endDayHour")))
            },
            _calculateHiddenInterval: function() {
                return 0
            },
            _getDateByCellIndexes: function(rowIndex, cellIndex) {
                var date = this.callBase(rowIndex, cellIndex);
                this._setStartDayHour(date);
                return date
            },
            needUpdateScrollPosition: function(hours, minutes, bounds, date) {
                return this._dateWithinBounds(bounds, date)
            },
            getPositionShift: function() {
                return {
                    top: 0,
                    left: 0
                }
            }
        });
        registerComponent("dxSchedulerTimelineMonth", SchedulerTimelineMonth);
        module.exports = SchedulerTimelineMonth
    },
    /*!*****************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.agenda.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            SchedulerWorkSpace = __webpack_require__( /*! ./ui.scheduler.work_space */ 413),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            tableCreator = __webpack_require__( /*! ./ui.scheduler.table_creator */ 414);
        var AGENDA_CLASS = "dx-scheduler-agenda",
            AGENDA_DATE_CLASS = "dx-scheduler-agenda-date",
            AGENDA_WEEK_DAY_CLASS = "dx-scheduler-agenda-week-day",
            GROUP_TABLE_CLASS = "dx-scheduler-group-table",
            NODATA_CONTAINER_CLASS = "dx-scheduler-agenda-nodata",
            LAST_ROW_CLASS = "dx-scheduler-date-table-last-row",
            INNER_CELL_MARGIN = 5,
            OUTER_CELL_MARGIN = 20;
        var SchedulerAgenda = SchedulerWorkSpace.inherit({
            _activeStateUnit: void 0,
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    agendaDuration: 7,
                    rowHeight: 60,
                    noDataText: ""
                })
            },
            _optionChanged: function(args) {
                var name = args.name,
                    value = args.value;
                switch (name) {
                    case "agendaDuration":
                        break;
                    case "noDataText":
                    case "rowHeight":
                        this._cleanView();
                        this._renderView();
                        break;
                    case "groups":
                        if (!value || !value.length) {
                            if (this._$groupTable) {
                                this._$groupTable.remove();
                                this._$groupTable = null
                            }
                        } else {
                            if (!this._$groupTable) {
                                this._initGroupTable();
                                this._dateTableScrollable.content().prepend(this._$groupTable)
                            }
                        }
                        this.callBase(args);
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _renderFocusState: $.noop,
            _cleanFocusState: $.noop,
            _getElementClass: function() {
                return AGENDA_CLASS
            },
            _setFirstViewDate: function() {
                this._firstViewDate = dateUtils.makeDate(this.option("currentDate"));
                this._setStartDayHour(this._firstViewDate)
            },
            _getRowCount: function() {
                return this.option("agendaDuration")
            },
            _getCellCount: function() {
                return 1
            },
            _getTimePanelRowCount: function() {
                return this.option("agendaDuration")
            },
            _getDateByIndex: $.noop,
            _getFormat: function() {
                return "d ddd"
            },
            _renderAllDayPanel: $.noop,
            _toggleAllDayVisibility: $.noop,
            _initWorkSpaceUnits: function() {
                this._initGroupTable();
                this._$timePanel = $("<table>").addClass(this._getTimePanelClass());
                this._$dateTable = $("<table>").addClass(this._getDateTableClass())
            },
            _initGroupTable: function() {
                var groups = this.option("groups");
                if (groups && groups.length) {
                    this._$groupTable = $("<table>").addClass(GROUP_TABLE_CLASS)
                }
            },
            _renderView: function() {
                this._setFirstViewDate();
                this._rows = [];
                this.invoke("getAgendaRows", {
                    agendaDuration: this.option("agendaDuration"),
                    currentDate: dateUtils.makeDate(this.option("currentDate"))
                }).done($.proxy(function(rows) {
                    this._cleanView();
                    if (!rows[0].length || this._rowsIsEmpty(rows)) {
                        this._renderNoData();
                        return
                    }
                    this._rows = rows;
                    if (this._$groupTable) {
                        this._renderGroupHeader();
                        this._setGroupHeaderCellsHeight()
                    }
                    this._renderTimePanel();
                    this._renderDateTable();
                    this.invoke("agendaIsReady", rows, INNER_CELL_MARGIN, OUTER_CELL_MARGIN);
                    this._dateTableScrollable.update()
                }, this))
            },
            _renderNoData: function() {
                this._$noDataContainer = $("<div>").addClass(NODATA_CONTAINER_CLASS).html(this.option("noDataText"));
                this._dateTableScrollable.content().append(this._$noDataContainer)
            },
            _setTableSizes: $.noop,
            _toggleHorizontalScrollClass: $.noop,
            _createCrossScrollingConfig: $.noop,
            _setGroupHeaderCellsHeight: function() {
                var $cells = this._getGroupHeaderCells().filter(function(_, element) {
                        return !element.getAttribute("rowspan")
                    }),
                    rows = this._removeEmptyRows(this._rows);
                if (!rows.length) {
                    return
                }
                for (var i = 0; i < $cells.length; i++) {
                    var $cellContent = $cells.eq(i).find(".dx-scheduler-group-header-content");
                    $cellContent.outerHeight(this._getGroupRowHeight(rows[i]))
                }
            },
            _rowsIsEmpty: function(rows) {
                var result = true;
                for (var i = 0; i < rows.length; i++) {
                    var groupRow = rows[i];
                    for (var j = 0; j < groupRow.length; j++) {
                        if (groupRow[j]) {
                            result = false;
                            break
                        }
                    }
                }
                return result
            },
            _attachGroupCountAttr: function() {
                this.element().attr("dx-group-column-count", this.option("groups").length)
            },
            _removeEmptyRows: function(rows) {
                var result = [];
                for (var i = 0; i < rows.length; i++) {
                    if (rows[i].length) {
                        result.push(rows[i])
                    }
                }
                return result
            },
            _getGroupHeaderContainer: function() {
                return this._$groupTable
            },
            _makeGroupRows: function(groups) {
                var tree = this.invoke("createReducedResourcesTree"),
                    getGroupHeaderContentClass = this._getGroupHeaderContentClass();
                var table = tableCreator.makeGroupedTableFromJSON(tableCreator.VERTICAL, tree, {
                    cellTag: "th",
                    groupTableClass: GROUP_TABLE_CLASS,
                    groupRowClass: this._getGroupRowClass(),
                    groupCellClass: this._getGroupHeaderClass(),
                    groupCellCustomContent: function(cell, cellText) {
                        var container = document.createElement("div"),
                            contentWrapper = document.createElement("div");
                        container.className = getGroupHeaderContentClass;
                        contentWrapper.appendChild(cellText);
                        container.appendChild(contentWrapper);
                        cell.appendChild(container)
                    }
                });
                return $(table).find("." + this._getGroupRowClass())
            },
            _cleanView: function() {
                this._$dateTable.empty();
                this._$timePanel.empty();
                if (this._$groupTable) {
                    this._$groupTable.empty()
                }
                if (this._$noDataContainer) {
                    this._$noDataContainer.empty();
                    this._$noDataContainer.remove();
                    delete this._$noDataContainer
                }
            },
            _createWorkSpaceElements: function() {
                this._createWorkSpaceStaticElements()
            },
            _createWorkSpaceStaticElements: function() {
                if (this._$groupTable) {
                    this._dateTableScrollable.content().prepend(this._$groupTable)
                }
                this._dateTableScrollable.content().append(this._$timePanel, this._$dateTable);
                this.element().append(this._dateTableScrollable.element())
            },
            _renderDateTable: function() {
                this._renderTableBody({
                    container: this._$dateTable,
                    rowClass: this._getDateTableRowClass(),
                    cellClass: this._getDateTableCellClass()
                })
            },
            _attachTablesEvents: $.noop,
            _attachEvents: $.noop,
            _cleanCellDataCache: $.noop,
            _renderTableBody: function(options) {
                this._$rows = [];
                var fillTableBody = $.proxy(function(rowIndex, rowSize) {
                    if (rowSize) {
                        var $row = $("<tr>");
                        if (options.rowClass) {
                            $row.addClass(options.rowClass)
                        }
                        var $td = $("<td>").height(this._getRowHeight(rowSize));
                        if (options.cellClass) {
                            $td.addClass(options.cellClass)
                        }
                        if ($.isFunction(options.dataGenerator)) {
                            options.dataGenerator($td[0], rowIndex)
                        }
                        $row.append($td);
                        this._$rows.push($row)
                    }
                }, this);
                for (var i = 0; i < this._rows.length; i++) {
                    $.each(this._rows[i], fillTableBody);
                    this._setLastRowClass()
                }
                options.container.append($("<tbody>").append(this._$rows))
            },
            _setLastRowClass: function() {
                if (this._rows.length > 1 && this._$rows.length) {
                    var $lastRow = this._$rows[this._$rows.length - 1];
                    $lastRow.addClass(LAST_ROW_CLASS)
                }
            },
            _setTimePanelText: function(cell, rowIndex) {
                var current = dateUtils.makeDate(this.option("currentDate")),
                    cellDate = new Date(current.setDate(current.getDate() + rowIndex)),
                    cellDateNumber = dateLocalization.format(cellDate, "d"),
                    cellDayName = dateLocalization.format(cellDate, "E");
                $(cell).append([$("<span />").addClass(AGENDA_DATE_CLASS).text(cellDateNumber), $("<span />").addClass(AGENDA_WEEK_DAY_CLASS).text(cellDayName)])
            },
            _getRowHeight: function(rowSize) {
                var baseHeight = this.option("rowHeight"),
                    innerOffset = (rowSize - 1) * INNER_CELL_MARGIN;
                return rowSize ? baseHeight * rowSize + innerOffset + OUTER_CELL_MARGIN : 0
            },
            _getGroupRowHeight: function(groupRows) {
                if (!groupRows) {
                    return
                }
                var result = 0;
                for (var i = 0; i < groupRows.length; i++) {
                    result += this._getRowHeight(groupRows[i])
                }
                return result
            },
            getAgendaVerticalStepHeight: function() {
                return this.option("rowHeight")
            },
            getEndViewDate: function() {
                var currentDate = dateUtils.makeDate(this.option("currentDate")),
                    agendaDuration = this.option("agendaDuration");
                currentDate.setHours(this.option("endDayHour"));
                var result = currentDate.setDate(currentDate.getDate() + agendaDuration - 1) - 6e4;
                return new Date(result)
            },
            getCoordinatesByDate: function() {
                return {
                    top: 0,
                    left: 0,
                    max: 0,
                    groupIndex: 0
                }
            },
            getCellDataByCoordinates: function() {
                return {
                    startDate: null,
                    endDate: null
                }
            }
        });
        registerComponent("dxSchedulerAgenda", SchedulerAgenda);
        module.exports = SchedulerAgenda
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.resource_manager.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            arrayUtils = __webpack_require__( /*! ../../core/utils/array */ 111),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            query = __webpack_require__( /*! ../../data/query */ 158),
            dataCoreUtils = __webpack_require__( /*! ../../core/utils/data */ 36),
            DataSourceModule = __webpack_require__( /*! ../../data/data_source/data_source */ 155);
        var getValueExpr = function(resource) {
                return resource.valueExpr || "id"
            },
            getDisplayExpr = function(resource) {
                return resource.displayExpr || "text"
            };
        var ResourceManager = Class.inherit({
            _wrapDataSource: function(dataSource) {
                if (dataSource instanceof DataSourceModule.DataSource) {
                    return dataSource
                } else {
                    return new DataSourceModule.DataSource({
                        store: DataSourceModule.normalizeDataSourceOptions(dataSource).store,
                        pageSize: 0
                    })
                }
            },
            _mapResourceData: function(resource, data) {
                var valueGetter = dataCoreUtils.compileGetter(getValueExpr(resource)),
                    displayGetter = dataCoreUtils.compileGetter(getDisplayExpr(resource));
                return $.map(data, function(item) {
                    var result = {
                        id: valueGetter(item),
                        text: displayGetter(item)
                    };
                    if (item.color) {
                        result.color = item.color
                    }
                    return result
                })
            },
            _isMultipleResource: function(resourceField) {
                var result = false;
                $.each(this.getResources(), $.proxy(function(_, resource) {
                    var field = this.getField(resource);
                    if (field === resourceField) {
                        result = resource.allowMultiple;
                        return false
                    }
                }, this));
                return result
            },
            ctor: function(resources) {
                this.setResources(resources)
            },
            getDataAccessors: function(field, type) {
                var result = null;
                $.each(this._dataAccessors[type], function(accessorName, accessors) {
                    if (field === accessorName) {
                        result = accessors;
                        return false
                    }
                });
                return result
            },
            getField: function(resource) {
                return resource.fieldExpr || resource.field
            },
            setResources: function(resources) {
                this._resources = resources;
                this._dataAccessors = {
                    getter: {},
                    setter: {}
                };
                this._resourceFields = $.map(resources || [], $.proxy(function(resource, index) {
                    var field = this.getField(resource);
                    this._dataAccessors.getter[field] = dataCoreUtils.compileGetter(field);
                    this._dataAccessors.setter[field] = dataCoreUtils.compileSetter(field);
                    return field
                }, this))
            },
            getResources: function() {
                return this._resources || []
            },
            getResourcesData: function() {
                return this._resourcesData || []
            },
            getEditors: function() {
                var result = [],
                    that = this;
                $.each(this.getResources(), function(i, resource) {
                    var field = that.getField(resource),
                        currentResourceItems = that._getResourceDataByField(field);
                    result.push({
                        editorOptions: {
                            dataSource: currentResourceItems.length ? currentResourceItems : that._wrapDataSource(resource.dataSource),
                            displayExpr: getDisplayExpr(resource),
                            valueExpr: getValueExpr(resource)
                        },
                        dataField: field,
                        editorType: resource.allowMultiple ? "dxTagBox" : "dxSelectBox",
                        label: {
                            text: resource.label || field
                        }
                    })
                });
                return result
            },
            getResourceDataByValue: function(field, value) {
                var result = $.Deferred(),
                    that = this;
                $.each(this.getResources(), function(_, resource) {
                    var resourceField = that.getField(resource);
                    if (resourceField === field) {
                        var dataSource = that._wrapDataSource(resource.dataSource),
                            valueExpr = getValueExpr(resource);
                        dataSource.load().done(function(data) {
                            var filteredData = query(data).filter(valueExpr, value).toArray();
                            result.resolve(filteredData[0])
                        }).fail(function() {
                            result.reject()
                        });
                        return false
                    }
                });
                return result.promise()
            },
            getResourcesFromItem: function(itemData, wrapOnlyMultipleResources) {
                var that = this,
                    result = null;
                if (!commonUtils.isDefined(wrapOnlyMultipleResources)) {
                    wrapOnlyMultipleResources = false
                }
                $.each(that._resourceFields, function(index, field) {
                    $.each(itemData, function(fieldName, fieldValue) {
                        var tmp = {};
                        tmp[fieldName] = fieldValue;
                        var resourceData = that.getDataAccessors(field, "getter")(tmp);
                        if (resourceData) {
                            if (!result) {
                                result = {}
                            }
                            if (!wrapOnlyMultipleResources || wrapOnlyMultipleResources && that._isMultipleResource(field)) {
                                that.getDataAccessors(field, "setter")(tmp, arrayUtils.wrapToArray(resourceData))
                            } else {
                                that.getDataAccessors(field, "setter")(tmp, resourceData)
                            }
                            $.extend(result, tmp);
                            return true
                        }
                    })
                });
                return result
            },
            loadResources: function(groups) {
                var result = $.Deferred(),
                    that = this,
                    deferreds = [];
                $.each(this.getResourcesByFields(groups), function(i, resource) {
                    var deferred = $.Deferred(),
                        field = that.getField(resource);
                    deferreds.push(deferred);
                    that._wrapDataSource(resource.dataSource).load().done(function(data) {
                        deferred.resolve({
                            name: field,
                            items: that._mapResourceData(resource, data),
                            data: data
                        })
                    }).fail(function() {
                        deferred.reject()
                    })
                });
                $.when.apply(null, deferreds).done(function() {
                    var data = Array.prototype.slice.call(arguments),
                        mapFunction = function(obj) {
                            return {
                                name: obj.name,
                                items: obj.items
                            }
                        };
                    that._resourcesData = data;
                    result.resolve(data.map(mapFunction))
                }).fail(function() {
                    result.reject()
                });
                return result.promise()
            },
            getResourcesByFields: function(fields) {
                return $.grep(this.getResources(), $.proxy(function(resource) {
                    var field = this.getField(resource);
                    return $.inArray(field, fields) > -1
                }, this))
            },
            getResourceColor: function(field, value) {
                var color, result = $.Deferred(),
                    resourceData = this._getResourceDataByField(field),
                    resourceDataLength = resourceData.length;
                if (resourceDataLength) {
                    for (var i = 0; i < resourceDataLength; i++) {
                        if (resourceData[i].id === value) {
                            color = resourceData[i].color;
                            break
                        }
                    }
                    result.resolve(color)
                } else {
                    this.getResourceDataByValue(field, value).done(function(resourceData) {
                        if (resourceData) {
                            color = resourceData.color
                        }
                        result.resolve(color)
                    }).fail(function() {
                        result.reject()
                    })
                }
                return result.promise()
            },
            getResourceForPainting: function(groups) {
                var result, resources = this.getResources();
                $.each(resources, function(index, resource) {
                    if (resource.useColorAsDefault || resource.mainColor) {
                        result = resource;
                        return false
                    }
                });
                if (!result) {
                    if ($.isArray(groups) && groups.length) {
                        resources = this.getResourcesByFields(groups)
                    }
                    result = resources[resources.length - 1]
                }
                return result
            },
            createResourcesTree: function(groups) {
                var leafIndex = 0,
                    groupIndex = groupIndex || 0;

                function make(group, groupIndex, result, parent) {
                    result = result || [];
                    for (var i = 0; i < group.items.length; i++) {
                        var currentGroupItem = group.items[i];
                        var resultItem = {
                            name: group.name,
                            value: currentGroupItem.id,
                            title: currentGroupItem.text,
                            children: [],
                            parent: parent ? parent : null
                        };
                        result.push(resultItem);
                        var nextGroupIndex = groupIndex + 1;
                        if (groups[nextGroupIndex]) {
                            make.call(this, groups[nextGroupIndex], nextGroupIndex, resultItem.children, resultItem)
                        }
                        if (!resultItem.children.length) {
                            resultItem.leafIndex = leafIndex;
                            leafIndex++
                        }
                    }
                    return result
                }
                return make.call(this, groups[0], 0)
            },
            _hasGroupItem: function(appointmentResources, groupName, itemValue) {
                var group = this.getDataAccessors(groupName, "getter")(appointmentResources);
                if (group) {
                    if ($.inArray(itemValue, group) > -1) {
                        return true
                    }
                }
                return false
            },
            _getResourceDataByField: function(fieldName) {
                var loadedResources = this.getResourcesData(),
                    currentResourceData = [];
                for (var i = 0, resourceCount = loadedResources.length; i < resourceCount; i++) {
                    if (loadedResources[i].name === fieldName) {
                        currentResourceData = loadedResources[i].data;
                        break
                    }
                }
                return currentResourceData
            },
            getResourceTreeLeaves: function(tree, appointmentResources, result) {
                result = result || [];
                for (var i = 0; i < tree.length; i++) {
                    if (!this._hasGroupItem(appointmentResources, tree[i].name, tree[i].value)) {
                        continue
                    }
                    if (commonUtils.isDefined(tree[i].leafIndex)) {
                        result.push(tree[i].leafIndex)
                    }
                    if (tree[i].children) {
                        this.getResourceTreeLeaves(tree[i].children, appointmentResources, result)
                    }
                }
                return result
            },
            groupAppointmentsByResources: function(appointments, resources) {
                var tree = this.createResourcesTree(resources),
                    result = {};
                $.each(appointments, $.proxy(function(_, appointment) {
                    var appointmentResources = this.getResourcesFromItem(appointment),
                        treeLeaves = this.getResourceTreeLeaves(tree, appointmentResources);
                    for (var i = 0; i < treeLeaves.length; i++) {
                        if (!result[treeLeaves[i]]) {
                            result[treeLeaves[i]] = []
                        }
                        result[treeLeaves[i]].push(appointment)
                    }
                }, this));
                return result
            },
            reduceResourcesTree: function(tree, existingAppointments, _result) {
                _result = _result ? _result.children : [];
                var that = this;
                tree.forEach(function(node, index) {
                    var ok = false,
                        resourceName = node.name,
                        resourceValue = node.value,
                        resourceTitle = node.title,
                        resourceGetter = that.getDataAccessors(resourceName, "getter");
                    existingAppointments.forEach(function(appointment) {
                        if (!ok) {
                            var resourceFromAppointment = resourceGetter(appointment);
                            if (commonUtils.isArray(resourceFromAppointment)) {
                                if (resourceFromAppointment.indexOf(resourceValue) > -1) {
                                    _result.push({
                                        name: resourceName,
                                        value: resourceValue,
                                        title: resourceTitle,
                                        children: []
                                    });
                                    ok = true
                                }
                            } else {
                                if (resourceFromAppointment === resourceValue) {
                                    _result.push({
                                        name: resourceName,
                                        value: resourceValue,
                                        title: resourceTitle,
                                        children: []
                                    });
                                    ok = true
                                }
                            }
                        }
                    });
                    if (ok && node.children && node.children.length) {
                        that.reduceResourcesTree(node.children, existingAppointments, _result[index])
                    }
                });
                return _result
            }
        });
        module.exports = ResourceManager
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointment_model.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            recurrenceUtils = __webpack_require__( /*! ./utils.recurrence */ 404),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            arrayUtils = __webpack_require__( /*! ../../core/utils/array */ 111),
            query = __webpack_require__( /*! ../../data/query */ 158);
        var FilterMaker = Class.inherit({
            ctor: function(dataExpressions) {
                this._filterRegistry = null;
                this._dataExpressions = dataExpressions
            },
            isRegistered: function() {
                return !!this._filterRegistry
            },
            make: function(type, args) {
                if (!this._filterRegistry) {
                    this._filterRegistry = {}
                }
                this._make[type].apply(this, args)
            },
            _make: {
                date: function(min, max) {
                    var startDate = this._dataExpressions.startDateExpr,
                        endDate = this._dataExpressions.endDateExpr,
                        recurrenceRule = this._dataExpressions.recurrenceRuleExpr;
                    this._filterRegistry.date = [
                        [
                            [endDate, ">", min],
                            [startDate, "<", max]
                        ], "or", [recurrenceRule, "startswith", "freq"]
                    ];
                    if (!recurrenceRule) {
                        this._filterRegistry.date.splice(1, 2)
                    }
                },
                user: function(userFilter) {
                    this._filterRegistry.user = userFilter
                }
            },
            combine: function() {
                var filter = [];
                this._filterRegistry.date && filter.push(this._filterRegistry.date);
                this._filterRegistry.user && filter.push(this._filterRegistry.user);
                return filter
            }
        });
        var AppointmentModel = Class.inherit({
            _createFilter: function(min, max, remoteFiltering) {
                this._filterMaker.make("date", [min, max]);
                this._filterMaker.make("user", [this._dataSource.filter()]);
                if (remoteFiltering) {
                    this._dataSource.filter(this._filterMaker.combine())
                }
            },
            _getStoreKey: function(target) {
                var store = this._dataSource.store();
                return store.keyOf(target)
            },
            _filterAppointmentByResources: function(appointment, resources) {
                var result = false;

                function checkAppointmentResourceValues() {
                    var resource, resourceGetter = this._dataAccessors.getter.resources[resourceName];
                    if ($.isFunction(resourceGetter)) {
                        resource = resourceGetter(appointment)
                    }
                    var appointmentResourceValues = arrayUtils.wrapToArray(resource),
                        resourceData = $.map(resources[i].items, function(item) {
                            return item.id
                        });
                    for (var j = 0, itemDataCount = appointmentResourceValues.length; j < itemDataCount; j++) {
                        if ($.inArray(appointmentResourceValues[j], resourceData) > -1) {
                            return true
                        }
                    }
                    return false
                }
                for (var i = 0, len = resources.length; i < len; i++) {
                    var resourceName = resources[i].name;
                    result = checkAppointmentResourceValues.call(this);
                    if (!result) {
                        return false
                    }
                }
                return result
            },
            _filterAppointmentByRRule: function(appointment, min, max, startDayHour, endDayHour) {
                var rrule = appointment.rrule,
                    recurrenceException = appointment.recurrenceException,
                    allDay = appointment.allDay,
                    result = true,
                    appointmentStartDate = appointment.startDate,
                    appointmentEndDate = appointment.endDate;
                if (allDay || this._appointmentPartInInterval(appointmentStartDate, appointmentEndDate, startDayHour, endDayHour)) {
                    var trimmedDates = this._trimDates(min, max);
                    min = trimmedDates.min, max = new Date(trimmedDates.max.getTime() - 6e4)
                }
                if (rrule && !recurrenceUtils.getRecurrenceRule(rrule).isValid) {
                    result = appointmentEndDate > min && appointmentStartDate <= max
                }
                if (result && recurrenceUtils.getRecurrenceRule(rrule).isValid) {
                    result = recurrenceUtils.dateInRecurrenceRange(rrule, appointmentStartDate, min, max, recurrenceException)
                }
                return result
            },
            _appointmentPartInInterval: function(startDate, endDate, startDayHour, endDayHour) {
                var apptStartDayHour = startDate.getHours(),
                    apptEndDayHour = endDate.getHours();
                return apptStartDayHour <= startDayHour && apptEndDayHour <= endDayHour && apptEndDayHour >= startDayHour || apptEndDayHour >= endDayHour && apptStartDayHour <= endDayHour && apptStartDayHour >= startDayHour
            },
            _createCombinedFilter: function(filterOptions, timeZoneProcessor) {
                var dataAccessors = this._dataAccessors,
                    startDayHour = filterOptions.startDayHour,
                    endDayHour = filterOptions.endDayHour,
                    min = dateUtils.makeDate(filterOptions.min),
                    max = dateUtils.makeDate(filterOptions.max),
                    resources = filterOptions.resources,
                    that = this;
                return [
                    [function(appointment) {
                        var rrule, result = true,
                            startDate = dateUtils.makeDate(dataAccessors.getter.startDate(appointment)),
                            endDate = dateUtils.makeDate(dataAccessors.getter.endDate(appointment)),
                            appointmentTakesAllDay = that.appointmentTakesAllDay(appointment, startDayHour, endDayHour),
                            isAllDay = dataAccessors.getter.allDay(appointment),
                            apptStartHour = startDate.getHours(),
                            hiddenInterval = 36e5 * (24 - endDayHour + startDayHour),
                            apptDuration = endDate.getTime() - startDate.getTime(),
                            delta = (hiddenInterval - apptDuration) / 36e5,
                            useRecurrence = commonUtils.isDefined(dataAccessors.getter.recurrenceRule);
                        if (useRecurrence) {
                            rrule = dataAccessors.getter.recurrenceRule(appointment)
                        }
                        if (resources && resources.length) {
                            result = that._filterAppointmentByResources(appointment, resources)
                        }
                        if (appointmentTakesAllDay && false === filterOptions.allDay) {
                            result = false
                        }
                        if (result && useRecurrence) {
                            result = that._filterAppointmentByRRule({
                                startDate: startDate,
                                endDate: endDate,
                                rrule: rrule,
                                recurrenceException: dataAccessors.getter.recurrenceException(appointment),
                                allDay: appointmentTakesAllDay
                            }, min, max, startDayHour, endDayHour)
                        }
                        var startDateTimeZone = dataAccessors.getter.startDateTimeZone(appointment),
                            endDateTimeZone = dataAccessors.getter.endDateTimeZone(appointment),
                            comparableStartDate = timeZoneProcessor(startDate, startDateTimeZone),
                            comparableEndDate = timeZoneProcessor(endDate, endDateTimeZone);
                        if (result && void 0 !== startDayHour) {
                            result = comparableStartDate.getHours() >= startDayHour || comparableEndDate.getHours() >= startDayHour || appointmentTakesAllDay
                        }
                        if (result && void 0 !== endDayHour) {
                            result = comparableStartDate.getHours() < endDayHour || appointmentTakesAllDay && comparableStartDate <= max;
                            if (apptDuration < hiddenInterval) {
                                if (apptStartHour > endDayHour && delta <= apptStartHour - endDayHour) {
                                    result = false
                                }
                            }
                        }
                        if (result && useRecurrence && !rrule) {
                            if (comparableEndDate.getTime() < min.getTime() && !isAllDay) {
                                result = false
                            }
                        }
                        return result
                    }]
                ]
            },
            ctor: function(dataSource, dataExpressions, dataAccessors) {
                this.setDataSource(dataSource);
                this._filterMaker = new FilterMaker(dataExpressions);
                this.setDataAccessors(dataAccessors)
            },
            setDataSource: function(dataSource) {
                this._dataSource = dataSource
            },
            setDataAccessors: function(dataAccessors) {
                this._dataAccessors = dataAccessors
            },
            filterByDate: function(min, max, remoteFiltering) {
                if (!this._dataSource) {
                    return
                }
                var trimmedDates = this._trimDates(min, max);
                if (!this._filterMaker.isRegistered()) {
                    this._createFilter(trimmedDates.min, trimmedDates.max, remoteFiltering)
                } else {
                    this._filterMaker.make("date", [trimmedDates.min, trimmedDates.max]);
                    if (this._dataSource.filter() && this._dataSource.filter().length > 1) {
                        this._filterMaker.make("user", [this._dataSource.filter()[1]])
                    }
                    if (remoteFiltering) {
                        this._dataSource.filter(this._filterMaker.combine())
                    }
                }
            },
            filterLoadedAppointments: function(filterOptions, timeZoneProcessor) {
                if (!$.isFunction(timeZoneProcessor)) {
                    timeZoneProcessor = function(date) {
                        return date
                    }
                }
                var combinedFilter = this._createCombinedFilter(filterOptions, timeZoneProcessor);
                if (this._filterMaker.isRegistered()) {
                    var trimmedDates = this._trimDates(filterOptions.min, filterOptions.max);
                    this._filterMaker.make("date", [trimmedDates.min, trimmedDates.max]);
                    var dateFilter = this.customizeDateFilter(this._filterMaker.combine(), timeZoneProcessor);
                    combinedFilter.push([dateFilter])
                }
                return query(this._dataSource.items()).filter(combinedFilter).toArray()
            },
            _trimDates: function(min, max) {
                var minCopy = dateUtils.trimTime(new Date(min)),
                    maxCopy = dateUtils.trimTime(new Date(max));
                maxCopy.setDate(maxCopy.getDate() + 1);
                return {
                    min: minCopy,
                    max: maxCopy
                }
            },
            hasAllDayAppointments: function(items, startDayHour, endDayHour) {
                if (!items) {
                    return false
                }
                var that = this;
                var result = false;
                $.each(items, function(index, item) {
                    if (that.appointmentTakesAllDay(item, startDayHour, endDayHour)) {
                        result = true;
                        return false
                    }
                });
                return result
            },
            appointmentTakesAllDay: function(appointment, startDayHour, endDayHour) {
                var dataAccessors = this._dataAccessors,
                    startDate = dataAccessors.getter.startDate(appointment),
                    endDate = dataAccessors.getter.endDate(appointment),
                    allDay = dataAccessors.getter.allDay(appointment);
                return allDay || this._appointmentHasAllDayDuration(startDate, endDate, startDayHour, endDayHour)
            },
            _appointmentHasAllDayDuration: function(startDate, endDate, startDayHour, endDayHour) {
                startDate = new Date(startDate);
                endDate = new Date(endDate);
                var etalonDayDurationInHours = endDayHour - startDayHour,
                    appointmentDurationInHours = (endDate.getTime() - startDate.getTime()) / 36e5;
                return appointmentDurationInHours >= etalonDayDurationInHours
            },
            appointmentTakesSeveralDays: function(appointment) {
                var dataAccessors = this._dataAccessors,
                    startDate = dataAccessors.getter.startDate(appointment),
                    endDate = dataAccessors.getter.endDate(appointment);
                var startDateCopy = dateUtils.trimTime(new Date(startDate)),
                    endDateCopy = dateUtils.trimTime(new Date(endDate));
                return startDateCopy.getTime() !== endDateCopy.getTime()
            },
            _mapDateFieldsDependOnTZ: function(appointment, tz) {
                function convert(date) {
                    date = dateUtils.makeDate(date);
                    var tzDiff = 36e5 * tz.value + tz.clientOffset;
                    return new Date(date.getTime() - tzDiff)
                }
                var startDate = this._dataAccessors.getter.startDate(appointment),
                    endDate = this._dataAccessors.getter.endDate(appointment);
                this._dataAccessors.setter.startDate(appointment, convert(startDate));
                this._dataAccessors.setter.endDate(appointment, convert(endDate))
            },
            customizeDateFilter: function(dateFilter, timeZoneProcessor) {
                var currentFilter = $.extend(true, [], dateFilter);
                return $.proxy(function(appointment) {
                    appointment = $.extend(true, {}, appointment);
                    var startDate = this._dataAccessors.getter.startDate(appointment),
                        endDate = this._dataAccessors.getter.endDate(appointment),
                        startDateTimeZone = this._dataAccessors.getter.startDateTimeZone(appointment),
                        endDateTimeZone = this._dataAccessors.getter.endDateTimeZone(appointment);
                    var comparableStartDate = timeZoneProcessor(startDate, startDateTimeZone),
                        comparableEndDate = timeZoneProcessor(endDate, endDateTimeZone);
                    this._dataAccessors.setter.startDate(appointment, comparableStartDate);
                    this._dataAccessors.setter.endDate(appointment, comparableEndDate);
                    return query([appointment]).filter(currentFilter).toArray().length > 0
                }, this)
            },
            add: function(data, tz) {
                if (tz && void 0 !== tz.value) {
                    this._mapDateFieldsDependOnTZ(data, tz)
                }
                return this._dataSource.store().insert(data).done($.proxy(function() {
                    this._dataSource.load()
                }, this))
            },
            update: function(target, data) {
                var key = this._getStoreKey(target);
                return this._dataSource.store().update(key, data).done($.proxy(function() {
                    this._dataSource.load()
                }, this))
            },
            remove: function(target) {
                var key = this._getStoreKey(target);
                return this._dataSource.store().remove(key).done($.proxy(function() {
                    this._dataSource.load()
                }, this))
            }
        });
        module.exports = AppointmentModel
    },
    /*!***********************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            recurrenceUtils = __webpack_require__( /*! ./utils.recurrence */ 404),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            publisherMixin = __webpack_require__( /*! ./ui.scheduler.publisher_mixin */ 410),
            Appointment = __webpack_require__( /*! ./ui.scheduler.appointment */ 427),
            VerticalAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.vertical */ 428),
            HorizontalAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.horizontal */ 430),
            HorizontalMonthLineAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.horizontal_month_line */ 431),
            HorizontalMonthAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.horizontal_month */ 432),
            AgendaAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.agenda */ 433),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            FunctionTemplate = __webpack_require__( /*! ../widget/ui.template.function */ 97),
            dblclickEvent = __webpack_require__( /*! ../../events/dblclick */ 177),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            CollectionWidget = __webpack_require__( /*! ../collection/ui.collection_widget.edit */ 151),
            Draggable = __webpack_require__( /*! ../draggable */ 258);
        var COMPONENT_CLASS = "dx-scheduler-scrollable-appointments",
            APPOINTMENT_ITEM_CLASS = "dx-scheduler-appointment",
            DBLCLICK_EVENT_NAME = eventUtils.addNamespace(dblclickEvent.name, "dxSchedulerAppointment");
        var RENDERING_STRATEGIES = {
            horizontal: HorizontalAppointmentsStrategy,
            horizontalMonth: HorizontalMonthAppointmentsStrategy,
            horizontalMonthLine: HorizontalMonthLineAppointmentsStrategy,
            vertical: VerticalAppointmentsStrategy,
            agenda: AgendaAppointmentsStrategy
        };
        var SchedulerAppointments = CollectionWidget.inherit({
            _supportedKeys: function(e) {
                var parent = this.callBase();
                var tabHandler = function(e) {
                    var appointments = this._getAccessAppointments(),
                        focusedAppointment = appointments.filter(".dx-state-focused"),
                        index = focusedAppointment.attr("sortedIndex"),
                        lastIndex = appointments.length - 1;
                    if (index > 0 && e.shiftKey || index < lastIndex && !e.shiftKey) {
                        e.preventDefault();
                        e.shiftKey ? index-- : index++;
                        var $nextAppointment = this._getAppointmentByIndex(index);
                        this._resetTabIndex($nextAppointment);
                        $nextAppointment.focus()
                    }
                };
                return $.extend(parent, {
                    escape: $.proxy(function() {
                        this.moveAppointmentBack();
                        this._escPressed = true
                    }, this),
                    del: $.proxy(function(e) {
                        if (this.option("allowDelete")) {
                            e.preventDefault();
                            var data = this._getItemData(e.target);
                            this.notifyObserver("deleteAppointment", {
                                data: data,
                                target: e.target
                            });
                            this.notifyObserver("hideAppointmentTooltip")
                        }
                    }),
                    tab: tabHandler
                })
            },
            _getAppointmentByIndex: function(index) {
                var appointments = this._getAccessAppointments();
                return appointments.filter("[sortedIndex =" + index + "]").eq(0)
            },
            _getAccessAppointments: function() {
                return this._itemElements().filter(":visible").not(".dx-state-disabled")
            },
            _resetTabIndex: function($appointment) {
                this._focusTarget().attr("tabindex", -1);
                $appointment.attr("tabindex", this.option("tabIndex"))
            },
            _moveFocus: $.noop,
            _focusTarget: function() {
                return this._itemElements()
            },
            _renderFocusTarget: function() {
                var $appointment = this._getAppointmentByIndex(0);
                this._resetTabIndex($appointment)
            },
            _focusInHandler: function(e) {
                if (this._targetIsDisabled(e)) {
                    e.stopPropagation();
                    return
                }
                this.callBase.apply(this, arguments);
                this._$currentAppointment = $(e.target);
                this.option("focusedElement", $(e.target));
                var that = this;
                setTimeout(function() {
                    that.notifyObserver("appointmentFocused")
                })
            },
            _targetIsDisabled: function(e) {
                return $(e.currentTarget).is(".dx-state-disabled, .dx-state-disabled *")
            },
            _focusOutHandler: function(e) {
                var $appointment = this._getAppointmentByIndex(0);
                this.option("focusedElement", $appointment);
                this.callBase.apply(this, arguments)
            },
            _eventBindingTarget: function() {
                return this._itemContainer()
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    noDataText: null,
                    activeStateEnabled: true,
                    hoverStateEnabled: true,
                    tabIndex: 0,
                    appointmentDurationInMinutes: 30,
                    fixedContainer: null,
                    allDayContainer: null,
                    renderingStrategy: "vertical",
                    allowDrag: true,
                    allowResize: true,
                    allowAllDayResize: true,
                    onAppointmentDblClick: null,
                    dayDuration: 24
                })
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "renderingStrategy":
                        this._initRenderingStrategy();
                        break;
                    case "fixedContainer":
                    case "allDayContainer":
                    case "onAppointmentDblClick":
                        break;
                    case "allowDrag":
                    case "allowResize":
                    case "allowAllDayResize":
                    case "dayDuration":
                    case "appointmentDurationInMinutes":
                        this.repaint();
                        break;
                    case "focusedElement":
                        this._resetTabIndex($(args.value));
                        this.callBase(args);
                        break;
                    case "allowDelete":
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _itemClass: function() {
                return APPOINTMENT_ITEM_CLASS
            },
            _itemContainer: function() {
                var $container = this.callBase(),
                    $result = $container,
                    $allDayContainer = this.option("allDayContainer");
                if ($allDayContainer) {
                    $result = $container.add($allDayContainer)
                }
                return $result
            },
            _cleanItemContainer: function() {
                this.callBase();
                var $allDayContainer = this.option("allDayContainer");
                if ($allDayContainer) {
                    $allDayContainer.empty()
                }
                this._virtualAppointments = {}
            },
            _clean: function() {
                this.callBase();
                delete this._$currentAppointment;
                delete this._initialSize;
                delete this._initialCoordinates
            },
            _init: function() {
                this.callBase();
                this._initRenderingStrategy();
                this.element().addClass(COMPONENT_CLASS);
                this._preventSingleAppointmentClick = false;
                this._initDynamicTemplates()
            },
            _initRenderingStrategy: function() {
                var Strategy = RENDERING_STRATEGIES[this.option("renderingStrategy")];
                this._renderingStrategy = new Strategy(this)
            },
            _initDynamicTemplates: function() {
                this._dynamicTemplates.item = new FunctionTemplate($.proxy(function(itemData) {
                    var text = this.invoke("getField", "text", itemData),
                        startDate = dateUtils.makeDate(this.invoke("getField", "startDate", itemData)),
                        endDate = dateUtils.makeDate(this.invoke("getField", "endDate", itemData)),
                        rrule = this.invoke("getField", "recurrenceRule", itemData),
                        $text = $("<div>").text(text),
                        $contentDetails = $("<div>").addClass("dx-scheduler-appointment-content-details"),
                        result = [];
                    var apptStartTz = this.invoke("getField", "startDateTimeZone", itemData),
                        apptEndTz = this.invoke("getField", "endDateTimeZone", itemData);
                    startDate = this.invoke("convertDateByTimezone", startDate, apptStartTz);
                    endDate = this.invoke("convertDateByTimezone", endDate, apptEndTz);
                    $("<div>").addClass("dx-scheduler-appointment-content-date").text(dateLocalization.format(startDate, "shorttime")).appendTo($contentDetails);
                    $("<div>").addClass("dx-scheduler-appointment-content-date").text(" - ").appendTo($contentDetails);
                    $("<div>").addClass("dx-scheduler-appointment-content-date").text(dateLocalization.format(endDate, "shorttime")).appendTo($contentDetails);
                    result.push($text, $contentDetails);
                    if (rrule) {
                        result.push($("<span>").addClass("dx-scheduler-appointment-recurrence-icon dx-icon-repeat"))
                    }
                    return result
                }, this))
            },
            _executeItemRenderAction: function(index, itemData, itemElement) {
                var action = this._getItemRenderAction();
                if (action) {
                    action({
                        appointmentElement: itemElement,
                        appointmentData: itemData,
                        targetedAppointmentData: this.invoke("getTargetedAppointmentData", itemData, itemElement, index)
                    })
                }
                delete this._currentAppointmentSettings
            },
            _getStartDate: function(appointment, skipNormalize) {
                var startDate = this.invoke("getField", "startDate", appointment),
                    startDateTimeZone = this.invoke("getField", "startDateTimeZone", appointment);
                startDate = dateUtils.makeDate(startDate);
                startDate = this.invoke("convertDateByTimezone", startDate, startDateTimeZone);
                !skipNormalize && this.notifyObserver("updateAppointmentStartDate", {
                    startDate: startDate,
                    appointment: appointment,
                    callback: function(result) {
                        startDate = result
                    }
                });
                return startDate
            },
            _getEndDate: function(appointment) {
                var endDate = this.invoke("getField", "endDate", appointment);
                if (endDate) {
                    var endDateTimeZone = this.invoke("getField", "endDateTimeZone", appointment);
                    endDate = dateUtils.makeDate(endDate);
                    endDate = this.invoke("convertDateByTimezone", endDate, endDateTimeZone);
                    this.notifyObserver("updateAppointmentEndDate", {
                        endDate: endDate,
                        callback: function(result) {
                            endDate = result
                        }
                    })
                }
                return endDate
            },
            _itemClickHandler: function(e) {
                this.callBase(e, {}, {
                    afterExecute: $.proxy(function(e) {
                        this._processItemClick(e.args[0].jQueryEvent)
                    }, this)
                })
            },
            _processItemClick: function(e) {
                var $target = $(e.currentTarget),
                    data = this._getItemData($target);
                if (this._targetIsDisabled(e)) {
                    e.stopPropagation();
                    return
                }
                this._normalizeAppointmentDates(data);
                if ("keydown" === e.type || eventUtils.isFakeClickEvent(e)) {
                    this.notifyObserver("showEditAppointmentPopup", {
                        data: data,
                        target: $target
                    });
                    return
                }
                this._appointmentClickTimeout = setTimeout($.proxy(function() {
                    if (!this._preventSingleAppointmentClick) {
                        this.notifyObserver("showAppointmentTooltip", {
                            data: data,
                            target: $target
                        })
                    }
                    this._preventSingleAppointmentClick = false
                }, this), 300)
            },
            _normalizeAppointmentDates: function(appointmentData) {
                var startDate = dateUtils.makeDate(this.invoke("getField", "startDate", appointmentData)),
                    endDate = dateUtils.makeDate(this.invoke("getField", "endDate", appointmentData));
                this.invoke("setField", "startDate", appointmentData, startDate);
                this.invoke("setField", "endDate", appointmentData, endDate)
            },
            _extendActionArgs: function() {
                var args = this.callBase.apply(this, arguments);
                return this._mapAppointmentFields(args)
            },
            _mapAppointmentFields: function(args) {
                var result = {
                    appointmentData: args.itemData,
                    appointmentElement: args.itemElement
                };
                if (args.itemData) {
                    result.targetedAppointmentData = this.invoke("getTargetedAppointmentData", args.itemData, args.itemElement, args.itemIndex)
                }
                return result
            },
            _render: function() {
                this.callBase.apply(this, arguments);
                this._attachAppointmentDblClick()
            },
            _attachAppointmentDblClick: function() {
                var that = this,
                    itemSelector = that._itemSelector();
                this._itemContainer().off(DBLCLICK_EVENT_NAME, itemSelector).on(DBLCLICK_EVENT_NAME, itemSelector, function(e) {
                    that._itemJQueryEventHandler(e, "onAppointmentDblClick", {}, {
                        afterExecute: function(e) {
                            that._dblClickHandler(e.args[0].jQueryEvent)
                        }
                    })
                })
            },
            _dblClickHandler: function(e) {
                var $targetAppointment = $(e.currentTarget),
                    appointmentData = this._getItemData($targetAppointment);
                clearTimeout(this._appointmentClickTimeout);
                this._preventSingleAppointmentClick = true;
                this.notifyObserver("showEditAppointmentPopup", {
                    data: appointmentData,
                    target: $targetAppointment
                })
            },
            _renderItems: function(items) {
                if (this._isContainerInvisible()) {
                    return
                }
                this.notifyObserver("getCellDimensions", {
                    callback: $.proxy(function(width, height, allDayHeight) {
                        this._cellWidth = width;
                        this._cellHeight = height;
                        this._allDayCellHeight = allDayHeight
                    }, this)
                });
                this._positionMap = this._renderingStrategy.createTaskPositionMap(items);
                this.callBase(items)
            },
            _isContainerInvisible: function() {
                var isContainerInvisible = false;
                this.notifyObserver("checkContainerVisibility", {
                    callback: function(result) {
                        isContainerInvisible = result
                    }
                });
                return isContainerInvisible
            },
            _renderItem: function(index, itemData) {
                var allDay = this._renderingStrategy.isAllDay(itemData),
                    $container = this._getAppointmentContainer(allDay),
                    appointmentSettings = this._positionMap[index],
                    coordinateCount = appointmentSettings.length;
                for (var i = 0; i < coordinateCount; i++) {
                    this._currentAppointmentSettings = appointmentSettings[i];
                    this.callBase(index, itemData, $container)
                }
            },
            _getAppointmentContainer: function(allDay) {
                var $allDayContainer = this.option("allDayContainer"),
                    $container = this.itemsContainer().not($allDayContainer);
                if (allDay && $allDayContainer) {
                    $container = $allDayContainer
                }
                return $container
            },
            _postprocessRenderItem: function(args) {
                this._renderAppointment(args.itemElement, this._currentAppointmentSettings)
            },
            _renderAppointment: function($appointment, settings) {
                this._applyResourceDataAttr($appointment);
                var appointmentData = this._getItemData($appointment),
                    geometry = this._renderingStrategy.getAppointmentGeometry(settings),
                    allowResize = !settings.isCompact && this.option("allowResize") && (!commonUtils.isDefined(settings.skipResizing) || commonUtils.isString(settings.skipResizing)),
                    allowDrag = this.option("allowDrag"),
                    allDay = this._renderingStrategy.isAllDay(appointmentData),
                    direction = "vertical" === this.option("renderingStrategy") && !allDay ? "vertical" : "horizontal";
                this.invoke("setCellDataCacheAlias", this._currentAppointmentSettings, geometry);
                this._createComponent($appointment, Appointment, {
                    observer: this.option("observer"),
                    data: appointmentData,
                    geometry: geometry,
                    direction: direction,
                    allowResize: allowResize,
                    allowDrag: allowDrag,
                    allDay: allDay,
                    reduced: settings.appointmentReduced,
                    isCompact: settings.isCompact,
                    sortedIndex: settings.sortedIndex,
                    cellWidth: this._cellWidth,
                    cellHeight: this._cellHeight,
                    resizableConfig: this._resizableConfig(appointmentData, settings)
                });
                var deferredColor = this._paintAppointment($appointment, settings.groupIndex);
                if (settings.virtual) {
                    deferredColor.done($.proxy(function(color) {
                        this._processVirtualAppointment(settings, $appointment, appointmentData, color)
                    }, this))
                }
                this._renderDraggable($appointment)
            },
            _applyResourceDataAttr: function($appointment) {
                this.notifyObserver("getResourcesFromItem", {
                    itemData: this._getItemData($appointment),
                    callback: function(resources) {
                        if (resources) {
                            $.each(resources, function(name, values) {
                                var attr = "data-" + name.toLowerCase() + "-";
                                for (var i = 0; i < values.length; i++) {
                                    $appointment.attr(attr + commonUtils.normalizeKey(values[i]), true)
                                }
                            })
                        }
                    }
                })
            },
            _resizableConfig: function(appointmentData, itemSetting) {
                return {
                    area: this._calculateResizableArea(itemSetting, appointmentData),
                    onResizeStart: $.proxy(function(e) {
                        this._$currentAppointment = $(e.element);
                        this._initialSize = {
                            width: e.width,
                            height: e.height
                        };
                        this._initialCoordinates = translator.locate(e.element)
                    }, this),
                    onResizeEnd: $.proxy(function(e) {
                        if (this._escPressed) {
                            e.jQueryEvent.cancel = true;
                            return
                        }
                        this._resizeEndHandler(e)
                    }, this)
                }
            },
            _calculateResizableArea: function(itemSetting, appointmentData) {
                var area = this.element().closest(".dx-scrollable-content"),
                    allDay = this._renderingStrategy.isAllDay(appointmentData);
                this.notifyObserver("getResizableAppointmentArea", {
                    coordinates: {
                        left: itemSetting.left,
                        top: 0
                    },
                    allDay: allDay,
                    callback: function(result) {
                        if (result) {
                            area = result
                        }
                    }
                });
                return area
            },
            _resizeEndHandler: function(e) {
                var itemData = this._getItemData(e.element),
                    startDate = this._getStartDate(itemData),
                    endDate = this._getEndDate(itemData);
                var dateRange = this._getDateRange(e, startDate, endDate);
                var updatedDates = {};
                this.invoke("setField", "startDate", updatedDates, new Date(dateRange[0]));
                this.invoke("setField", "endDate", updatedDates, new Date(dateRange[1]));
                var data = $.extend({}, itemData, updatedDates);
                this.notifyObserver("updateAppointmentAfterResize", {
                    target: itemData,
                    data: data,
                    $appointment: e.element
                })
            },
            _getDateRange: function(e, startDate, endDate) {
                var itemData = this._getItemData(e.element),
                    deltaTime = this._renderingStrategy.getDeltaTime(e, this._initialSize, itemData),
                    renderingStrategy = this.option("renderingStrategy"),
                    cond = false;
                if ("vertical" !== renderingStrategy || this._renderingStrategy.isAllDay(itemData)) {
                    cond = this.option("rtlEnabled") ? e.handles.right : e.handles.left
                } else {
                    cond = e.handles.top
                }
                var startTime = cond ? startDate.getTime() - deltaTime : startDate.getTime(),
                    endTime = cond ? endDate.getTime() : endDate.getTime() + deltaTime;
                return [startTime, endTime]
            },
            _paintAppointment: function($appointment, groupIndex) {
                var res = $.Deferred();
                this.notifyObserver("getAppointmentColor", {
                    itemData: this._getItemData($appointment),
                    groupIndex: groupIndex,
                    callback: function(d) {
                        d.done(function(color) {
                            if (color) {
                                $appointment.css("background-color", color)
                            }
                            res.resolve(color)
                        })
                    }
                });
                return res.promise()
            },
            _renderDraggable: function($appointment) {
                if (!this.option("allowDrag")) {
                    return
                }
                var draggableArea, that = this,
                    appointmentData = that._getItemData($appointment),
                    isAllDay = this._renderingStrategy.isAllDay(appointmentData),
                    $fixedContainer = this.option("fixedContainer"),
                    correctCoordinates = function($element, isFixedContainer) {
                        var coordinates = translator.locate($element);
                        that.notifyObserver("correctAppointmentCoordinates", {
                            coordinates: coordinates,
                            allDay: isAllDay,
                            isFixedContainer: isFixedContainer,
                            callback: function(result) {
                                if (result) {
                                    coordinates = result
                                }
                            }
                        });
                        translator.move($appointment, coordinates)
                    };
                this.notifyObserver("getDraggableAppointmentArea", {
                    callback: function(result) {
                        if (result) {
                            draggableArea = result
                        }
                    }
                });
                this._createComponent($appointment, Draggable, {
                    area: draggableArea,
                    boundOffset: that._calculateBoundOffset(),
                    onDragStart: function(args) {
                        var e = args.jQueryEvent;
                        that._skipDraggableRestriction(e);
                        that.notifyObserver("hideAppointmentTooltip");
                        that.notifyObserver("getDragEventTargetElements", {
                            callback: function(result) {
                                if (result) {
                                    e.targetElements = result
                                }
                            }
                        });
                        $fixedContainer.append($appointment);
                        that._$currentAppointment = $(args.element);
                        that._initialSize = {
                            width: args.width,
                            height: args.height
                        };
                        that._initialCoordinates = translator.locate(args.element)
                    },
                    onDrag: function(args) {
                        correctCoordinates(args.element)
                    },
                    onDragEnd: function(args) {
                        correctCoordinates(args.element, true);
                        var $container = that._getAppointmentContainer(isAllDay);
                        $container.append($appointment);
                        if (this._escPressed) {
                            args.jQueryEvent.cancel = true;
                            return
                        }
                        that._dragEndHandler(args)
                    }
                })
            },
            _calculateBoundOffset: function() {
                var result = {
                    top: 0
                };
                this.notifyObserver("getBoundOffset", {
                    callback: function(offset) {
                        result = offset
                    }
                });
                return result
            },
            _skipDraggableRestriction: function(e) {
                if (this.option("rtlEnabled")) {
                    e.maxLeftOffset = null
                } else {
                    e.maxRightOffset = null
                }
                e.maxBottomOffset = null
            },
            _dragEndHandler: function(e) {
                var itemData = this._getItemData(e.element),
                    coordinates = this._initialCoordinates;
                this._normalizeAppointmentDates(itemData);
                this.notifyObserver("updateAppointmentAfterDrag", {
                    data: itemData,
                    $appointment: e.element,
                    coordinates: coordinates
                })
            },
            _virtualAppointments: {},
            _processVirtualAppointment: function(appointmentSetting, $appointment, appointmentData, color) {
                var virtualAppointment = appointmentSetting.virtual,
                    virtualGroupIndex = virtualAppointment.index;
                if (!commonUtils.isDefined(this._virtualAppointments[virtualGroupIndex])) {
                    this._virtualAppointments[virtualGroupIndex] = {
                        coordinates: {
                            top: virtualAppointment.top,
                            left: virtualAppointment.left
                        },
                        items: {
                            data: [],
                            colors: []
                        },
                        isAllDay: virtualAppointment.isAllDay,
                        buttonColor: color
                    }
                }
                this._virtualAppointments[virtualGroupIndex].items.data.push(appointmentData);
                this._virtualAppointments[virtualGroupIndex].items.colors.push(color);
                $appointment.remove()
            },
            _renderContentImpl: function() {
                this.callBase();
                this._renderDropDownAppointments()
            },
            _renderDropDownAppointments: function() {
                var buttonWidth = this._renderingStrategy.getCompactAppointmentGroupMaxWidth(),
                    rtlOffset = 0,
                    that = this;
                if (this.option("rtlEnabled")) {
                    rtlOffset = buttonWidth
                }
                $.each(this._virtualAppointments, $.proxy(function(groupIndex, appointment) {
                    var virtualGroup = this._virtualAppointments[groupIndex],
                        virtualItems = virtualGroup.items,
                        virtualCoordinates = virtualGroup.coordinates,
                        $container = virtualGroup.isAllDay ? this.option("allDayContainer") : this.element(),
                        left = virtualCoordinates.left;
                    this.notifyObserver("renderDropDownAppointments", {
                        $container: $container,
                        coordinates: {
                            top: virtualCoordinates.top,
                            left: left + rtlOffset
                        },
                        items: virtualItems,
                        buttonColor: virtualGroup.buttonColor,
                        itemTemplate: this.option("itemTemplate"),
                        buttonWidth: buttonWidth,
                        onAppointmentClick: function(args) {
                            var mappedAppointmentFields = that._mapAppointmentFields(args);
                            that._itemJQueryEventHandler(args.jQueryEvent, "onItemClick", mappedAppointmentFields)
                        }
                    })
                }, this))
            },
            _sortAppointmentsByStartDate: function(appointments) {
                appointments.sort($.proxy(function(a, b) {
                    var result = 0,
                        firstDate = dateUtils.makeDate(this.invoke("getField", "startDate", a)).getTime(),
                        secondDate = dateUtils.makeDate(this.invoke("getField", "startDate", b)).getTime();
                    if (firstDate < secondDate) {
                        result = -1
                    }
                    if (firstDate > secondDate) {
                        result = 1
                    }
                    return result
                }, this))
            },
            _processRecurrenceAppointment: function(appointment, index, skipLongAppointments) {
                var recurrenceRule = this.invoke("getField", "recurrenceRule", appointment),
                    result = {
                        parts: [],
                        indexes: []
                    };
                if (recurrenceRule) {
                    var startDate = dateUtils.makeDate(this.invoke("getField", "startDate", appointment)),
                        endDate = dateUtils.makeDate(this.invoke("getField", "endDate", appointment)),
                        appointmentDuration = endDate.getTime() - startDate.getTime(),
                        recurrenceException = this.invoke("getField", "recurrenceException", appointment),
                        startViewDate = this.invoke("getStartViewDate"),
                        endViewDate = this.invoke("getEndViewDate"),
                        recurrentDates = recurrenceUtils.getDatesByRecurrence(recurrenceRule, startDate, startViewDate, endViewDate, recurrenceException),
                        recurrentDateCount = recurrentDates.length;
                    for (var i = 0; i < recurrentDateCount; i++) {
                        var appointmentPart = this._applyStartDateToObj(recurrentDates[i], {
                            appointmentData: appointment
                        });
                        result.parts.push(appointmentPart);
                        this._applyEndDateToObj(new Date(recurrentDates[i].getTime() + appointmentDuration), appointmentPart);
                        if (!skipLongAppointments) {
                            this._processLongAppointment(appointmentPart, result)
                        }
                    }
                    result.indexes.push(index)
                }
                return result
            },
            _processLongAppointment: function(appointment, result) {
                var parts = this.splitAppointmentByDay(appointment),
                    partCount = parts.length,
                    endViewDate = this.invoke("getEndViewDate").getTime(),
                    startViewDate = this.invoke("getStartViewDate").getTime(),
                    startDateTimeZone = this.invoke("getField", "startDateTimeZone", appointment);
                result = result || {
                    parts: []
                };
                if (partCount > 1) {
                    for (var i = 1; i < partCount; i++) {
                        var startDate = this.invoke("getField", "startDate", parts[i]).getTime();
                        startDate = this.invoke("convertDateByTimezone", startDate, startDateTimeZone);
                        if (startDate < endViewDate && startDate > startViewDate) {
                            result.parts.push(parts[i])
                        }
                    }
                }
                return result
            },
            _reduceRecurrenceAppointments: function(recurrenceIndexes, appointments) {
                $.each(recurrenceIndexes, function(i, index) {
                    appointments.splice(index - i, 1)
                })
            },
            _combineAppointments: function(appointments, additionalAppointments) {
                if (additionalAppointments.length) {
                    $.merge(appointments, additionalAppointments)
                }
                this._sortAppointmentsByStartDate(appointments);
                $.each(appointments, function(i, appointment) {
                    if (appointment.appointmentData) {
                        appointments[i] = appointment.appointmentData
                    }
                })
            },
            _applyStartDateToObj: function(startDate, obj) {
                if (obj.appointmentData.appointmentData) {
                    obj = obj.appointmentData
                }
                this.invoke("setField", "startDate", obj, startDate);
                return obj
            },
            _applyEndDateToObj: function(endDate, obj) {
                if (obj.appointmentData.appointmentData) {
                    obj = obj.appointmentData
                }
                this.invoke("setField", "endDate", obj, endDate);
                return obj
            },
            updateDraggablesBoundOffsets: function() {
                if (this.option("allowDrag")) {
                    this.element().find("." + APPOINTMENT_ITEM_CLASS).each($.proxy(function(_, appointmentElement) {
                        var $appointment = $(appointmentElement),
                            appointmentData = this._getItemData($appointment);
                        if (!this._renderingStrategy.isAllDay(appointmentData)) {
                            Draggable.getInstance($appointment).option("boundOffset", this._calculateBoundOffset())
                        }
                    }, this))
                }
            },
            moveAppointmentBack: function() {
                var $appointment = this._$currentAppointment,
                    size = this._initialSize,
                    coords = this._initialCoordinates;
                if ($appointment) {
                    if (coords) {
                        translator.move($appointment, coords);
                        delete this._initialSize
                    }
                    if (size) {
                        $appointment.outerWidth(size.width);
                        $appointment.outerHeight(size.height);
                        delete this._initialCoordinates
                    }
                }
            },
            focus: function() {
                var $appointment = this._$currentAppointment;
                if ($appointment) {
                    this.option("focusedElement", $appointment);
                    this.option("focusedElement").focus()
                }
            },
            splitAppointmentByDay: function(appointment) {
                var startDate = dateUtils.makeDate(this.invoke("getField", "startDate", appointment)),
                    endDate = dateUtils.makeDate(this.invoke("getField", "endDate", appointment)),
                    startDateTimeZone = this.invoke("getField", "startDateTimeZone", appointment);
                startDate = this.invoke("convertDateByTimezone", startDate, startDateTimeZone);
                var result = [this._applyStartDateToObj(new Date(startDate), {
                    appointmentData: appointment
                })];
                var currentDate = startDate.getDate();
                startDate.setHours(startDate.getHours() + 1);
                while (startDate.getTime() < endDate.getTime() - 1) {
                    if (currentDate !== startDate.getDate()) {
                        result.push(this._applyStartDateToObj(new Date(startDate), {
                            appointmentData: appointment
                        }))
                    }
                    currentDate = startDate.getDate();
                    startDate.setHours(startDate.getHours() + 1)
                }
                return result
            }
        }).include(publisherMixin);
        registerComponent("dxSchedulerAppointments", SchedulerAppointments);
        module.exports = SchedulerAppointments
    },
    /*!**********************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointment.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            recurrenceUtils = __webpack_require__( /*! ./utils.recurrence */ 404),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            tooltip = __webpack_require__( /*! ../tooltip/ui.tooltip */ 305),
            publisherMixin = __webpack_require__( /*! ./ui.scheduler.publisher_mixin */ 410),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            DOMComponent = __webpack_require__( /*! ../../core/dom_component */ 29),
            Resizable = __webpack_require__( /*! ../resizable */ 112),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56);
        var REDUCED_APPOINTMENT_POINTERENTER_EVENT_NAME = eventUtils.addNamespace(pointerEvents.enter, "dxSchedulerAppointment"),
            REDUCED_APPOINTMENT_POINTERLEAVE_EVENT_NAME = eventUtils.addNamespace(pointerEvents.leave, "dxSchedulerAppointment");
        var EMPTY_APPOINTMENT_CLASS = "dx-scheduler-appointment-empty",
            EMPTY_APPOINTMENT_MAX_WIDTH = 40,
            EMPTY_APPOINTMENT_MAX_HEIGHT = 15,
            APPOINTMENT_ALL_DAY_ITEM_CLASS = "dx-scheduler-all-day-appointment",
            DIRECTION_APPOINTMENT_CLASSES = {
                horizontal: "dx-scheduler-appointment-horizontal",
                vertical: "dx-scheduler-appointment-vertical"
            },
            RECURRENCE_APPOINTMENT_CLASS = "dx-scheduler-appointment-recurrence",
            COMPACT_APPOINTMENT_CLASS = "dx-scheduler-appointment-compact",
            REDUCED_APPOINTMENT_CLASS = "dx-scheduler-appointment-reduced",
            REDUCED_APPOINTMENT_ICON = "dx-scheduler-appointment-reduced-icon",
            REDUCED_APPOINTMENT_PARTS_CLASSES = {
                head: "dx-scheduler-appointment-head",
                body: "dx-scheduler-appointment-body",
                tail: "dx-scheduler-appointment-tail"
            };
        var Appointment = DOMComponent.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    data: {},
                    geometry: {
                        top: 0,
                        left: 0,
                        width: 0,
                        height: 0
                    },
                    allowDrag: true,
                    allowResize: true,
                    reduced: null,
                    isCompact: false,
                    sortedIndex: void 0,
                    direction: "vertical",
                    resizableConfig: {},
                    cellHeight: 0,
                    cellWidth: 0
                })
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "data":
                    case "geometry":
                    case "allowDrag":
                    case "allowResize":
                    case "reduced":
                    case "sortedIndex":
                    case "isCompact":
                    case "direction":
                    case "resizableConfig":
                    case "cellHeight":
                    case "cellWidth":
                        this._invalidate();
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _resizingRules: {
                horizontal: function() {
                    var width = this.option("cellWidth"),
                        isRTL = this.option("rtlEnabled"),
                        reducedHandles = {
                            head: isRTL ? "right" : "left",
                            body: "",
                            tail: isRTL ? "left" : "right"
                        },
                        handles = "left right",
                        reducedPart = this.option("reduced");
                    if (reducedPart) {
                        handles = reducedHandles[reducedPart]
                    }
                    return {
                        handles: handles,
                        minHeight: 0,
                        minWidth: width,
                        step: width
                    }
                },
                vertical: function() {
                    var height = this.option("cellHeight");
                    return {
                        handles: "top bottom",
                        minWidth: 0,
                        minHeight: height,
                        step: height
                    }
                }
            },
            _render: function() {
                this.callBase();
                this._renderAppointmentGeometry();
                this._renderEmptyClass();
                this._renderCompactClass();
                this._renderReducedAppointment();
                this._renderAllDayClass();
                this._renderDirection();
                this.element().attr("title", this.invoke("getField", "text", this.option("data")));
                this.element().attr("role", "button");
                this._renderRecurrenceClass();
                this._renderSortedTabIndex();
                this._renderResizable()
            },
            _renderAppointmentGeometry: function() {
                var geometry = this.option("geometry"),
                    $element = this.element();
                translator.move($element, {
                    top: geometry.top,
                    left: geometry.left
                });
                $element.css({
                    width: geometry.width,
                    height: geometry.height
                })
            },
            _renderEmptyClass: function() {
                var geometry = this.option("geometry");
                if (geometry.width < EMPTY_APPOINTMENT_MAX_WIDTH || geometry.height < EMPTY_APPOINTMENT_MAX_HEIGHT) {
                    this.element().addClass(EMPTY_APPOINTMENT_CLASS)
                }
            },
            _renderReducedAppointment: function() {
                var reducedPart = this.option("reduced");
                if (!reducedPart) {
                    return
                }
                this.element().toggleClass(REDUCED_APPOINTMENT_CLASS, true).toggleClass(REDUCED_APPOINTMENT_PARTS_CLASSES[reducedPart], true);
                this._renderAppointmentReducedIcon()
            },
            _renderAppointmentReducedIcon: function() {
                var $icon = $("<div>").addClass(REDUCED_APPOINTMENT_ICON).appendTo(this.element()),
                    endDate = this._getEndDate();
                $icon.off(REDUCED_APPOINTMENT_POINTERENTER_EVENT_NAME).on(REDUCED_APPOINTMENT_POINTERENTER_EVENT_NAME, function() {
                    tooltip.show({
                        target: $icon,
                        content: messageLocalization.format("dxScheduler-editorLabelEndDate") + ": " + dateLocalization.format(endDate, "d MMMM yyyy")
                    })
                }).off(REDUCED_APPOINTMENT_POINTERLEAVE_EVENT_NAME).on(REDUCED_APPOINTMENT_POINTERLEAVE_EVENT_NAME, function() {
                    tooltip.hide()
                })
            },
            _getEndDate: function() {
                var result = this.invoke("getField", "endDate", this.option("data"));
                if (result) {
                    return dateUtils.makeDate(result)
                }
                return result
            },
            _renderAllDayClass: function() {
                this.element().toggleClass(APPOINTMENT_ALL_DAY_ITEM_CLASS, !!this.option("allDay"))
            },
            _renderRecurrenceClass: function() {
                var rule = this.invoke("getField", "recurrenceRule", this.option("data"));
                if (recurrenceUtils.getRecurrenceRule(rule).isValid) {
                    this.element().addClass(RECURRENCE_APPOINTMENT_CLASS)
                }
            },
            _renderSortedTabIndex: function() {
                var sortedIndex = this.option("sortedIndex");
                this.element().attr("sortedIndex", sortedIndex);
                this.element().attr("tabIndex", 0 === sortedIndex ? 0 : -1)
            },
            _renderCompactClass: function() {
                this.element().toggleClass(COMPACT_APPOINTMENT_CLASS, !!this.option("isCompact"))
            },
            _renderDirection: function() {
                this.element().addClass(DIRECTION_APPOINTMENT_CLASSES[this.option("direction")])
            },
            _renderResizable: function() {
                if (!this.option("allowResize") || this.option("isCompact")) {
                    return
                }
                var config = this._resizingRules[this.option("direction")].apply(this);
                config.stepPrecision = "strict";
                this._createComponent(this.element(), Resizable, $.extend(config, this.option("resizableConfig")))
            }
        }).include(publisherMixin);
        registerComponent("dxSchedulerAppointment", Appointment);
        module.exports = Appointment
    },
    /*!*****************************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.strategy.vertical.js ***!
      \*****************************************************************************/
    function(module, exports, __webpack_require__) {
        var BaseAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.base */ 429),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52);
        var WEEK_APPOINTMENT_DEFAULT_OFFSET = 15;
        var VerticalRenderingStrategy = BaseAppointmentsStrategy.inherit({
            getDeltaTime: function(args, initialSize, appointment) {
                var deltaTime = 0;
                if (this.isAllDay(appointment)) {
                    deltaTime = 24 * this._getDeltaWidth(args, initialSize) * 60 * 6e4
                } else {
                    var deltaHeight = args.height - initialSize.height;
                    if (deltaHeight < 0) {
                        deltaHeight = this._correctOnePxGap(deltaHeight)
                    }
                    deltaTime = 6e4 * Math.round(deltaHeight / this._defaultHeight * this.instance.option("appointmentDurationInMinutes"))
                }
                return deltaTime
            },
            getAppointmentGeometry: function(coordinates) {
                var result, allDay = coordinates.allDay;
                if (allDay) {
                    result = this._getAllDayAppointmentGeometry(coordinates)
                } else {
                    result = this._getSimpleAppointmentGeometry(coordinates)
                }
                return this.callBase(result)
            },
            _correctOnePxGap: function(deltaHeight) {
                if (Math.abs(deltaHeight) % this._defaultHeight) {
                    deltaHeight--
                }
                return deltaHeight
            },
            _getMinuteHeight: function() {
                return this._defaultHeight / this.instance.option("appointmentDurationInMinutes")
            },
            _getCompactLeftCoordinate: function(itemLeft, index) {
                var cellBorderSize = 1,
                    cellWidth = this._defaultWidth || this.getAppointmentMinSize();
                return itemLeft + (cellBorderSize + cellWidth) * index
            },
            _checkLongCompactAppointment: function(item, result) {
                if (item.allDay) {
                    this._splitLongCompactAppointment(item, result)
                }
                return result
            },
            _getAllDayAppointmentGeometry: function(coordinates) {
                var maxHeight = this._allDayHeight || this.getAppointmentMinSize(),
                    index = coordinates.index,
                    count = coordinates.count,
                    height = maxHeight / (count > 3 ? 3 : count),
                    width = coordinates.width,
                    top = coordinates.top + index * height,
                    left = coordinates.left,
                    compactAppointmentDefaultSize = this.getCompactAppointmentDefaultSize(),
                    compactAppointmentDefaultOffset = this.getCompactAppointmentDefaultOffset();
                if (!this.instance.option("allowResize") || !this.instance.option("allowAllDayResize")) {
                    coordinates.skipResizing = true
                }
                if (count > 2) {
                    if (coordinates.isCompact) {
                        top = coordinates.top + compactAppointmentDefaultOffset;
                        left = coordinates.left + (index - 2) * (compactAppointmentDefaultSize + compactAppointmentDefaultOffset) + compactAppointmentDefaultOffset;
                        height = compactAppointmentDefaultSize, width = compactAppointmentDefaultSize;
                        this._markAppointmentAsVirtual(coordinates, true)
                    } else {
                        top += height
                    }
                }
                return {
                    height: height,
                    width: width,
                    top: top,
                    left: left
                }
            },
            _getSimpleAppointmentGeometry: function(coordinates) {
                var width = this._getAppointmentMaxWidth() / coordinates.count,
                    height = coordinates.height,
                    top = coordinates.top,
                    left = coordinates.left + coordinates.index * width;
                return {
                    height: height,
                    width: width,
                    top: top,
                    left: left
                }
            },
            isAllDay: function(appointmentData) {
                var appointmentTakesAllDay = false,
                    startDate = this.instance.invoke("getField", "startDate", appointmentData),
                    endDate = this.instance.invoke("getField", "endDate", appointmentData),
                    allDay = this.instance.invoke("getField", "allDay", appointmentData);
                this.instance.notifyObserver("appointmentTakesAllDay", {
                    startDate: startDate,
                    endDate: endDate,
                    callback: function(result) {
                        appointmentTakesAllDay = result
                    }
                });
                return allDay || appointmentTakesAllDay
            },
            _getAppointmentMaxWidth: function() {
                return this._defaultWidth - WEEK_APPOINTMENT_DEFAULT_OFFSET || this.getAppointmentMinSize()
            },
            calculateAppointmentWidth: function(appointment) {
                if (!this.isAllDay(appointment)) {
                    return 0
                }
                var startDate = new Date(this._startDate(appointment)),
                    endDate = this._endDate(appointment),
                    cellWidth = this._defaultWidth || this.getAppointmentMinSize();
                startDate = dateUtils.trimTime(startDate);
                var durationInHours = (endDate.getTime() - startDate.getTime()) / 36e5;
                var width = Math.ceil(durationInHours / 24) * cellWidth;
                return width
            },
            calculateAppointmentHeight: function(appointment) {
                if (this.isAllDay(appointment)) {
                    return 0
                }
                var startDate = this._startDate(appointment),
                    endDate = this._endDate(appointment);
                var durationInMinutes = (endDate.getTime() - startDate.getTime()) / 6e4,
                    minHeight = this.getAppointmentMinSize();
                var height = Math.round(durationInMinutes * this._getMinuteHeight());
                if (height < minHeight) {
                    height = minHeight
                }
                return height
            },
            _sortCondition: function(a, b) {
                var allDayCondition = a.allDay - b.allDay,
                    result = allDayCondition ? allDayCondition : this._rowCondition(a, b);
                return this._fixUnstableSorting(result, a, b)
            }
        });
        module.exports = VerticalRenderingStrategy
    },
    /*!*************************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.strategy.base.js ***!
      \*************************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            errors = __webpack_require__( /*! ../widget/ui.errors */ 10);
        var abstract = Class.abstract;
        var APPOINTMENT_MIN_SIZE = 2,
            COMPACT_APPOINTMENT_DEFAULT_SIZE = 15,
            COMPACT_APPOINTMENT_DEFAULT_OFFSET = 3;
        var BaseRenderingStrategy = Class.inherit({
            ctor: function(instance) {
                this.instance = instance
            },
            getAppointmentMinSize: function() {
                return APPOINTMENT_MIN_SIZE
            },
            getDeltaTime: abstract,
            getAppointmentGeometry: function(coordinates) {
                return coordinates
            },
            createTaskPositionMap: function(items) {
                var length = items.length;
                if (!length) {
                    return
                }
                this._defaultWidth = this.instance._cellWidth;
                this._defaultHeight = this.instance._cellHeight;
                this._allDayHeight = this.instance._allDayCellHeight;
                var map = [];
                for (var i = 0; i < length; i++) {
                    var coordinates = this._getItemPosition(items[i]);
                    if (this._isRtl()) {
                        coordinates = this._correctRtlCoordinates(coordinates)
                    }
                    map.push(coordinates)
                }
                var positionArray = this._getSortedPositions(map),
                    resultPositions = this._getResultPositions(positionArray);
                return this._getExtendedPositionMap(map, resultPositions)
            },
            _getDeltaWidth: function(args, initialSize) {
                var cellWidth = this._defaultWidth || this.getAppointmentMinSize(),
                    initialWidth = initialSize.width;
                return Math.round((args.width - initialWidth) / cellWidth)
            },
            _correctRtlCoordinates: function(coordinates) {
                var width = coordinates[0].width || this._getAppointmentMaxWidth();
                if (!coordinates[0].appointmentReduced) {
                    coordinates[0].left -= width
                }
                this._correctRtlCoordinatesParts(coordinates, width);
                return coordinates
            },
            _correctRtlCoordinatesParts: $.noop,
            _getAppointmentMaxWidth: function() {
                return this._defaultWidth
            },
            _getItemPosition: function(item) {
                var height = this.calculateAppointmentHeight(item),
                    width = this.calculateAppointmentWidth(item),
                    position = this._getAppointmentCoordinates(item),
                    allDay = this.isAllDay(item),
                    result = [],
                    startDate = this.instance.invoke("getField", "startDate", item);
                for (var j = 0; j < position.length; j++) {
                    var resultWidth = width,
                        appointmentReduced = null,
                        multiWeekAppointmentParts = [];
                    if (this._needVerifyItemSize() || allDay) {
                        var currentMaxAllowedPosition = position[j].max;
                        if (this.isAppointmentGreaterThan(currentMaxAllowedPosition, {
                                left: position[j].left,
                                width: width
                            })) {
                            appointmentReduced = "head";
                            resultWidth = this._reduceMultiWeekAppointment(width, {
                                left: position[j].left,
                                right: currentMaxAllowedPosition
                            });
                            multiWeekAppointmentParts = this._getMultiWeekAppointmentParts({
                                sourceAppointmentWidth: width,
                                reducedWidth: resultWidth,
                                height: height
                            }, position[j], startDate, j);
                            if (this._isRtl()) {
                                position[j].left = currentMaxAllowedPosition
                            }
                        }
                    }
                    $.extend(position[j], {
                        height: height,
                        width: resultWidth,
                        allDay: allDay,
                        appointmentReduced: appointmentReduced
                    });
                    if (multiWeekAppointmentParts.length) {
                        multiWeekAppointmentParts.unshift(position[j]);
                        result = result.concat(multiWeekAppointmentParts)
                    } else {
                        result.push(position[j])
                    }
                }
                return result
            },
            _getAppointmentCoordinates: function(itemData) {
                var coordinates = [{
                    top: 0,
                    left: 0
                }];
                this.instance.notifyObserver("needCoordinates", {
                    startDate: this._startDate(itemData),
                    originalStartDate: this._startDate(itemData, true),
                    appointmentData: itemData,
                    callback: function(value) {
                        coordinates = value
                    }
                });
                return coordinates
            },
            _needVerifyItemSize: function() {
                return false
            },
            _isRtl: function() {
                return this.instance.option("rtlEnabled")
            },
            _getMultiWeekAppointmentParts: function() {
                return []
            },
            _getCompactAppointmentParts: function(appointmentWidth) {
                var cellWidth = this._defaultWidth || this.getAppointmentMinSize();
                return Math.round(appointmentWidth / cellWidth)
            },
            _reduceMultiWeekAppointment: function(sourceAppointmentWidth, bound) {
                if (this._isRtl()) {
                    sourceAppointmentWidth = Math.floor(bound.left - bound.right)
                } else {
                    sourceAppointmentWidth = bound.right - Math.floor(bound.left)
                }
                return sourceAppointmentWidth
            },
            calculateAppointmentHeight: function() {
                return 0
            },
            calculateAppointmentWidth: function() {
                return 0
            },
            isAppointmentGreaterThan: function(etalon, comparisonParameters) {
                var result = comparisonParameters.left + comparisonParameters.width - etalon;
                if (this._isRtl()) {
                    result = etalon + comparisonParameters.width - comparisonParameters.left
                }
                return result > this._defaultWidth / 2
            },
            isAllDay: function() {
                return false
            },
            _getSortedPositions: function(arr) {
                var result = [],
                    __tmpIndex = 0;
                for (var i = 0, arrLength = arr.length; i < arrLength; i++) {
                    for (var j = 0, itemLength = arr[i].length; j < itemLength; j++) {
                        var item = arr[i][j];
                        var start = {
                            i: i,
                            j: j,
                            top: item.top,
                            left: item.left,
                            isStart: true,
                            allDay: item.allDay,
                            __tmpIndex: __tmpIndex
                        };
                        __tmpIndex++;
                        var end = {
                            i: i,
                            j: j,
                            top: item.top + item.height,
                            left: item.left + item.width,
                            isStart: false,
                            allDay: item.allDay,
                            __tmpIndex: __tmpIndex
                        };
                        result.push(start, end);
                        __tmpIndex++
                    }
                }
                result.sort($.proxy(function(a, b) {
                    return this._sortCondition(a, b)
                }, this));
                return result
            },
            _fixUnstableSorting: function(comparisonResult, a, b) {
                if (0 === comparisonResult) {
                    if (a.__tmpIndex < b.__tmpIndex) {
                        return -1
                    }
                    if (a.__tmpIndex > b.__tmpIndex) {
                        return 1
                    }
                }
                return comparisonResult
            },
            _sortCondition: abstract,
            _rowCondition: function(a, b) {
                var columnCondition = this._normalizeCondition(a.left, b.left),
                    rowCondition = this._normalizeCondition(a.top, b.top);
                return columnCondition ? columnCondition : rowCondition ? rowCondition : a.isStart - b.isStart
            },
            _columnCondition: function(a, b) {
                var columnCondition = this._normalizeCondition(a.left, b.left),
                    rowCondition = this._normalizeCondition(a.top, b.top);
                return rowCondition ? rowCondition : columnCondition ? columnCondition : a.isStart - b.isStart
            },
            _normalizeCondition: function(first, second) {
                var result = first - second;
                return Math.abs(result) > 1.001 ? result : 0
            },
            _getResultPositions: function(sortedArray) {
                var position, stack = [],
                    indexes = [],
                    result = [],
                    intersectPositions = [],
                    intersectPositionCount = 0,
                    sortedIndex = 0;
                for (var i = 0; i < sortedArray.length; i++) {
                    var j, current = sortedArray[i];
                    if (current.isStart) {
                        position = void 0;
                        for (j = 0; j < indexes.length; j++) {
                            if (!indexes[j]) {
                                position = j;
                                indexes[j] = true;
                                break
                            }
                        }
                        if (void 0 === position) {
                            position = indexes.length;
                            indexes.push(true);
                            for (j = 0; j < stack.length; j++) {
                                stack[j].count++
                            }
                        }
                        stack.push({
                            index: position,
                            count: indexes.length,
                            i: current.i,
                            j: current.j,
                            sortedIndex: sortedIndex++
                        });
                        if (intersectPositionCount < indexes.length) {
                            intersectPositionCount = indexes.length
                        }
                    } else {
                        var removeIndex = this._findIndexByKey(stack, "i", "j", current.i, current.j),
                            resultItem = stack[removeIndex];
                        stack.splice(removeIndex, 1);
                        indexes[resultItem.index] = false;
                        intersectPositions.push(resultItem);
                        if (!stack.length) {
                            indexes = [];
                            for (var k = 0; k < intersectPositions.length; k++) {
                                intersectPositions[k].count = intersectPositionCount
                            }
                            intersectPositions = [];
                            intersectPositionCount = 0
                        }
                        result.push(resultItem)
                    }
                }
                return result.sort(function(a, b) {
                    var columnCondition = a.j - b.j,
                        rowCondition = a.i - b.i;
                    return rowCondition ? rowCondition : columnCondition
                })
            },
            _findIndexByKey: function(arr, ikey, jkey, ivalue, jvalue) {
                var result = 0;
                for (var i = 0, len = arr.length; i < len; i++) {
                    if (arr[i][ikey] === ivalue && arr[i][jkey] === jvalue) {
                        result = i;
                        break
                    }
                }
                return result
            },
            _getExtendedPositionMap: function(map, positions) {
                var positionCounter = 0,
                    result = [];
                for (var i = 0, mapLength = map.length; i < mapLength; i++) {
                    var resultString = [];
                    for (var j = 0, itemLength = map[i].length; j < itemLength; j++) {
                        map[i][j].index = positions[positionCounter].index;
                        map[i][j].sortedIndex = positions[positionCounter].sortedIndex;
                        map[i][j].count = positions[positionCounter++].count;
                        resultString.push(map[i][j]);
                        this._checkLongCompactAppointment(map[i][j], resultString)
                    }
                    result.push(resultString)
                }
                return result
            },
            _checkLongCompactAppointment: $.noop,
            _splitLongCompactAppointment: function(item, result) {
                var compactCount = 0;
                if (item.index > 1) {
                    item.isCompact = true;
                    compactCount = this._getCompactAppointmentParts(item.width);
                    for (var k = 1; k < compactCount; k++) {
                        var compactPart = $.extend(true, {}, item);
                        compactPart.left = this._getCompactLeftCoordinate(item.left, k);
                        compactPart.sortedIndex = null;
                        result.push(compactPart)
                    }
                }
                return result
            },
            _startDate: function(appointment, skipNormalize) {
                var startDate = this.instance._getStartDate(appointment, skipNormalize),
                    text = this.instance.invoke("getField", "text", appointment);
                if (isNaN(startDate.getTime())) {
                    throw errors.Error("E1032", text)
                }
                return startDate
            },
            _endDate: function(appointment) {
                var endDate = this.instance._getEndDate(appointment),
                    realStartDate = this._startDate(appointment, true),
                    viewStartDate = this._startDate(appointment);
                if (!endDate || realStartDate.getTime() >= endDate.getTime()) {
                    endDate = new Date(realStartDate.getTime() + 6e4 * this.instance.option("appointmentDurationInMinutes"));
                    this.instance.invoke("setField", "endDate", appointment, endDate)
                }
                if (viewStartDate >= endDate) {
                    var duration = endDate.getTime() - realStartDate.getTime();
                    endDate = new Date(viewStartDate.getTime() + duration)
                }
                return endDate
            },
            _getMaxNeighborAppointmentCount: function() {
                var outerAppointmentWidth = this.getCompactAppointmentDefaultSize() + this.getCompactAppointmentDefaultOffset();
                return Math.floor(this.getCompactAppointmentGroupMaxWidth() / outerAppointmentWidth)
            },
            _markAppointmentAsVirtual: function(coordinates, isAllDay) {
                var countFullWidthAppointmentInCell = 2;
                if (coordinates.count - countFullWidthAppointmentInCell > this._getMaxNeighborAppointmentCount()) {
                    coordinates.virtual = {
                        top: coordinates.top,
                        left: coordinates.left,
                        index: coordinates.top + "-" + coordinates.left,
                        isAllDay: isAllDay
                    }
                }
            },
            getCompactAppointmentGroupMaxWidth: function() {
                var widthInPercents = 75;
                return widthInPercents * this.getDefaultCellWidth() / 100
            },
            getDefaultCellWidth: function() {
                return this._defaultWidth
            },
            getCompactAppointmentDefaultSize: function() {
                return COMPACT_APPOINTMENT_DEFAULT_SIZE
            },
            getCompactAppointmentDefaultOffset: function() {
                return COMPACT_APPOINTMENT_DEFAULT_OFFSET
            },
            getAppointmentDataCalculator: $.noop
        });
        module.exports = BaseRenderingStrategy
    },
    /*!*******************************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.strategy.horizontal.js ***!
      \*******************************************************************************/
    function(module, exports, __webpack_require__) {
        var BaseAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.base */ 429),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52);
        var MAX_APPOINTMENT_HEIGHT = 100,
            BOTTOM_CELL_GAP = 20,
            toMs = dateUtils.dateToMilliseconds;
        var HorizontalRenderingStrategy = BaseAppointmentsStrategy.inherit({
            _needVerifyItemSize: function() {
                return true
            },
            calculateAppointmentWidth: function(appointment) {
                var width, cellWidth = this._defaultWidth || this.getAppointmentMinSize(),
                    allDay = this.instance.invoke("getField", "allDay", appointment),
                    minWidth = this.getAppointmentMinSize(),
                    durationInCells = 0;
                var dayDuration = toMs("day"),
                    startDate = this._startDate(appointment),
                    endDate = this._endDate(appointment),
                    appointmentDuration = endDate.getTime() - startDate.getTime();
                if (allDay) {
                    var ceilQuantityOfDays = Math.ceil(appointmentDuration / dayDuration);
                    durationInCells = ceilQuantityOfDays * (60 * this.instance.option("dayDuration") / this.instance.option("appointmentDurationInMinutes"))
                } else {
                    var floorQuantityOfDays = Math.floor(appointmentDuration / dayDuration),
                        tailDuration = appointmentDuration % dayDuration,
                        visibleDayDuration = this.instance.option("dayDuration") * toMs("hour");
                    if (tailDuration > visibleDayDuration) {
                        tailDuration = visibleDayDuration
                    }
                    var cellDuration = this.instance.option("appointmentDurationInMinutes") * toMs("minute");
                    durationInCells = (floorQuantityOfDays * visibleDayDuration + tailDuration) / cellDuration
                }
                width = durationInCells * cellWidth;
                if (width < minWidth) {
                    width = minWidth
                }
                return width
            },
            getAppointmentGeometry: function(coordinates) {
                var result = this._customizeAppointmentGeometry(coordinates);
                return this.callBase(result)
            },
            _customizeAppointmentGeometry: function(coordinates) {
                var cellHeight = (this._defaultHeight || this.getAppointmentMinSize()) - BOTTOM_CELL_GAP,
                    height = cellHeight / coordinates.count;
                if (height > MAX_APPOINTMENT_HEIGHT) {
                    height = MAX_APPOINTMENT_HEIGHT
                }
                var top = coordinates.top + coordinates.index * height;
                return {
                    height: height,
                    width: coordinates.width,
                    top: top,
                    left: coordinates.left
                }
            },
            _correctRtlCoordinatesParts: function(coordinates, width) {
                for (var i = 1; i < coordinates.length; i++) {
                    coordinates[i].left -= width
                }
                return coordinates
            },
            _sortCondition: function(a, b) {
                var result = this._columnCondition(a, b);
                return this._fixUnstableSorting(result, a, b)
            },
            _getMaxAppointmentWidth: function(startDate) {
                var result;
                this.instance.notifyObserver("getMaxAppointmentWidth", {
                    date: startDate,
                    callback: function(width) {
                        result = width
                    }
                });
                return result
            },
            getDeltaTime: function(args, initialSize) {
                var deltaTime = 0,
                    deltaWidth = args.width - initialSize.width;
                deltaTime = 6e4 * Math.round(deltaWidth / this._defaultWidth * this.instance.option("appointmentDurationInMinutes"));
                return deltaTime
            },
            isAllDay: function(appointmentData) {
                return this.instance.invoke("getField", "allDay", appointmentData)
            }
        });
        module.exports = HorizontalRenderingStrategy
    },
    /*!******************************************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.strategy.horizontal_month_line.js ***!
      \******************************************************************************************/
    function(module, exports, __webpack_require__) {
        var HorizontalAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.horizontal */ 430),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            query = __webpack_require__( /*! ../../data/query */ 158);
        var HorizontalMonthLineRenderingStrategy = HorizontalAppointmentsStrategy.inherit({
            calculateAppointmentWidth: function(appointment) {
                var startDate = new Date(this._startDate(appointment)),
                    endDate = new Date(this._endDate(appointment)),
                    cellWidth = this._defaultWidth || this.getAppointmentMinSize();
                startDate = dateUtils.trimTime(startDate);
                var durationInHours = (endDate.getTime() - startDate.getTime()) / 36e5;
                return Math.ceil(durationInHours / 24) * cellWidth
            },
            getDeltaTime: function(args, initialSize) {
                var deltaWidth = this._getDeltaWidth(args, initialSize);
                return 864e5 * deltaWidth
            },
            isAllDay: function() {
                return false
            },
            createTaskPositionMap: function(items, skipSorting) {
                if (!skipSorting) {
                    this.instance._sortAppointmentsByStartDate(items)
                }
                return this.callBase(items)
            },
            _getSortedPositions: function(map, skipSorting) {
                var result = this.callBase(map);
                if (!skipSorting) {
                    result = query(result).sortBy("top").thenBy("left").thenBy("i").toArray()
                }
                return result
            }
        });
        module.exports = HorizontalMonthLineRenderingStrategy
    },
    /*!*************************************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.strategy.horizontal_month.js ***!
      \*************************************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            HorizontalMonthLineAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.horizontal_month_line */ 431);
        var MONTH_APPOINTMENT_HEIGHT_RATIO = .6;
        var HorizontalMonthRenderingStrategy = HorizontalMonthLineAppointmentsStrategy.inherit({
            _getMultiWeekAppointmentParts: function(appointmentGeometry, appointmentSettings, startDate, groupIndex) {
                var deltaWidth = appointmentGeometry.sourceAppointmentWidth - appointmentGeometry.reducedWidth,
                    height = appointmentGeometry.height,
                    fullWeekAppointmentWidth = this._getFullWeekAppointmentWidth(groupIndex),
                    maxAppointmentWidth = this._getMaxAppointmentWidth(startDate),
                    longPartCount = Math.floor(deltaWidth / fullWeekAppointmentWidth),
                    tailWidth = deltaWidth % fullWeekAppointmentWidth,
                    result = [],
                    totalWidth = appointmentGeometry.reducedWidth + tailWidth,
                    currentPartTop = appointmentSettings.top + this._defaultHeight,
                    left = this._calculateMultiWeekAppointmentLeftOffset(appointmentSettings.max, fullWeekAppointmentWidth);
                for (var i = 0; i < longPartCount; i++) {
                    if (totalWidth > maxAppointmentWidth) {
                        break
                    }
                    result.push($.extend(true, {}, appointmentSettings, {
                        top: currentPartTop,
                        left: left,
                        height: height,
                        width: fullWeekAppointmentWidth,
                        appointmentReduced: "body"
                    }));
                    currentPartTop += this._defaultHeight;
                    totalWidth += fullWeekAppointmentWidth
                }
                if (tailWidth) {
                    if (this._isRtl()) {
                        left += fullWeekAppointmentWidth - tailWidth
                    }
                    result.push($.extend(true, {}, appointmentSettings, {
                        top: currentPartTop,
                        left: left,
                        height: height,
                        width: tailWidth,
                        appointmentReduced: "tail"
                    }))
                }
                return result
            },
            _calculateMultiWeekAppointmentLeftOffset: function(max, width) {
                return this._isRtl() ? max : max - width
            },
            _correctRtlCoordinatesParts: $.noop,
            _getFullWeekAppointmentWidth: function(groupIndex) {
                this.instance.notifyObserver("getFullWeekAppointmentWidth", {
                    groupIndex: groupIndex,
                    callback: $.proxy(function(width) {
                        this._maxFullWeekAppointmentWidth = width
                    }, this)
                });
                return this._maxFullWeekAppointmentWidth
            },
            _getCompactLeftCoordinate: function(itemLeft, index) {
                var cellWidth = this._defaultWidth || this.getAppointmentMinSize();
                return itemLeft + cellWidth * index
            },
            _checkLongCompactAppointment: function(item, result) {
                this._splitLongCompactAppointment(item, result);
                return result
            },
            _customizeAppointmentGeometry: function(coordinates) {
                var compactAppointmentDefaultSize, compactAppointmentDefaultOffset, maxHeight = this._defaultHeight || this.getAppointmentMinSize(),
                    index = coordinates.index,
                    height = MONTH_APPOINTMENT_HEIGHT_RATIO * maxHeight / 2,
                    top = (1 - MONTH_APPOINTMENT_HEIGHT_RATIO) * maxHeight + coordinates.top + index * height,
                    width = coordinates.width,
                    left = coordinates.left;
                if (coordinates.isCompact) {
                    compactAppointmentDefaultSize = this.getCompactAppointmentDefaultSize();
                    compactAppointmentDefaultOffset = this.getCompactAppointmentDefaultOffset();
                    top = coordinates.top + compactAppointmentDefaultOffset;
                    left = coordinates.left + (index - 2) * (compactAppointmentDefaultSize + compactAppointmentDefaultOffset) + compactAppointmentDefaultOffset;
                    height = compactAppointmentDefaultSize, width = compactAppointmentDefaultSize;
                    this._markAppointmentAsVirtual(coordinates)
                }
                return {
                    height: height,
                    width: width,
                    top: top,
                    left: left
                }
            },
            createTaskPositionMap: function(items) {
                return this.callBase(items, true)
            },
            _getSortedPositions: function(map) {
                return this.callBase(map, true)
            }
        });
        module.exports = HorizontalMonthRenderingStrategy
    },
    /*!***************************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.strategy.agenda.js ***!
      \***************************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            BaseAppointmentsStrategy = __webpack_require__( /*! ./ui.scheduler.appointments.strategy.base */ 429);
        var AgendaRenderingStrategy = BaseAppointmentsStrategy.inherit({
            ctor: function(instance) {
                this.instance = instance
            },
            getAppointmentMinSize: $.noop,
            getDeltaTime: $.noop,
            getAppointmentGeometry: function(geometry) {
                return geometry
            },
            createTaskPositionMap: function(appointments) {
                if (appointments.length) {
                    var height = this.instance.invoke("getAgendaVerticalStepHeight"),
                        appointmentsByResources = this.instance.invoke("groupAppointmentsByResources", appointments),
                        groupedAppts = [];
                    $.each(appointmentsByResources, function(i, appts) {
                        var additionalAppointments = [],
                            recurrentIndexes = [];
                        $.each(appts, function(index, appointment) {
                            var recurrenceBatch = this.instance._processRecurrenceAppointment(appointment, index),
                                appointmentBatch = null;
                            if (!recurrenceBatch.indexes.length) {
                                appointmentBatch = {
                                    parts: []
                                };
                                appointmentBatch = this.instance._processLongAppointment(appointment);
                                additionalAppointments = additionalAppointments.concat(appointmentBatch.parts)
                            }
                            additionalAppointments = additionalAppointments.concat(recurrenceBatch.parts);
                            recurrentIndexes = recurrentIndexes.concat(recurrenceBatch.indexes)
                        }.bind(this));
                        this.instance._reduceRecurrenceAppointments(recurrentIndexes, appts);
                        this.instance._combineAppointments(appts, additionalAppointments);
                        groupedAppts = groupedAppts.concat(appts)
                    }.bind(this));
                    Array.prototype.splice.apply(appointments, [0, appointments.length].concat(groupedAppts))
                }
                var result = [],
                    sortedIndex = 0;
                appointments.forEach(function(appt, index, all) {
                    result.push([{
                        height: height,
                        width: "100%",
                        sortedIndex: sortedIndex++,
                        groupIndex: this._calculateGroupIndex(index, appointmentsByResources),
                        appointmentReduced: this._calculateIfApptReduced(appt)
                    }])
                }.bind(this));
                return result
            },
            _calculateIfApptReduced: function(appointment) {
                var isRecurrence = !!this.instance.invoke("getField", "recurrenceRule", appointment),
                    result = false;
                if (this.instance.invoke("appointmentTakesSeveralDays", appointment) && !isRecurrence) {
                    result = "head"
                }
                return result
            },
            _calculateGroupIndex: function(apptIndex, appointmentsByResources) {
                var resultInd, counter = 0;
                for (var i in appointmentsByResources) {
                    var countApptInGroup = appointmentsByResources[i].length;
                    if (apptIndex >= counter && apptIndex < counter + countApptInGroup) {
                        resultInd = Number(i);
                        break
                    }
                    counter += countApptInGroup
                }
                return resultInd
            },
            _getDeltaWidth: $.noop,
            _correctRtlCoordinatesParts: $.noop,
            _getAppointmentMaxWidth: function() {
                return this._defaultWidth
            },
            _needVerifyItemSize: function() {
                return false
            },
            _isRtl: function() {
                return this.instance.option("rtlEnabled")
            },
            _getMultiWeekAppointmentParts: $.noop,
            _reduceMultiWeekAppointment: $.noop,
            calculateAppointmentHeight: function() {
                return 0
            },
            calculateAppointmentWidth: function() {
                return 0
            },
            isAppointmentGreaterThan: $.noop,
            isAllDay: function() {
                return false
            },
            _sortCondition: $.noop,
            _rowCondition: $.noop,
            _columnCondition: $.noop,
            _findIndexByKey: $.noop,
            _getMaxNeighborAppointmentCount: $.noop,
            _markAppointmentAsVirtual: $.noop,
            getCompactAppointmentGroupMaxWidth: $.noop,
            getDefaultCellWidth: function() {
                return this._defaultWidth
            },
            getCompactAppointmentDefaultSize: $.noop,
            getCompactAppointmentDefaultOffset: $.noop,
            calculateRows: function(appointments, agendaDuration, currentDate) {
                this._rows = [];
                var appts = {
                    indexes: [],
                    parts: []
                };
                var groupedAppointments = this.instance.invoke("groupAppointmentsByResources", appointments);
                currentDate = dateUtils.trimTime(dateUtils.makeDate(currentDate));
                $.each(groupedAppointments, function(groupIndex, currentAppointments) {
                    var groupResult = [];
                    if (!currentAppointments.length) {
                        this._rows.push([]);
                        return true
                    }
                    $.each(currentAppointments, function(index, appointment) {
                        var result = this.instance._processRecurrenceAppointment(appointment, index, true);
                        appts.parts = appts.parts.concat(result.parts);
                        appts.indexes = appts.indexes.concat(result.indexes)
                    }.bind(this));
                    this.instance._reduceRecurrenceAppointments(appts.indexes, currentAppointments);
                    $.merge(currentAppointments, appts.parts);
                    var appointmentCount = currentAppointments.length;
                    for (var i = 0; i < agendaDuration; i++) {
                        var day = new Date(currentDate.getTime() + 864e5 * i);
                        if (void 0 === groupResult[i]) {
                            groupResult[i] = 0
                        }
                        for (var j = 0; j < appointmentCount; j++) {
                            if (this.instance.invoke("dayHasAppointment", day, currentAppointments[j], true)) {
                                groupResult[i] += 1
                            }
                        }
                    }
                    this._rows.push(groupResult)
                }.bind(this));
                return this._rows
            },
            _iterateRow: function(row, obj, index) {
                for (var i = 0; i < row.length; i++) {
                    obj.counter = obj.counter + row[i];
                    if (obj.counter >= index) {
                        obj.indexInRow = i;
                        break
                    }
                }
            },
            getDateByIndex: function(index, rows, startViewDate) {
                var obj = {
                    counter: 0,
                    indexInRow: 0
                };
                index++;
                for (var i = 0; i < rows.length; i++) {
                    this._iterateRow(rows[i], obj, index);
                    if (obj.indexInRow) {
                        break
                    }
                }
                return new Date(new Date(startViewDate).setDate(startViewDate.getDate() + obj.indexInRow))
            },
            getAppointmentDataCalculator: function() {
                return function($appointment, originalStartDate) {
                    var apptIndex = $appointment.index(),
                        startViewDate = this.instance.invoke("getStartViewDate"),
                        calculatedStartDate = this.getDateByIndex(apptIndex, this._rows, startViewDate),
                        wrappedOriginalStartDate = new Date(originalStartDate);
                    return {
                        startDate: new Date(calculatedStartDate.setHours(wrappedOriginalStartDate.getHours(), wrappedOriginalStartDate.getMinutes(), wrappedOriginalStartDate.getSeconds(), wrappedOriginalStartDate.getMilliseconds()))
                    }
                }.bind(this)
            }
        });
        module.exports = AgendaRenderingStrategy
    },
    /*!*********************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointments.drop_down.js ***!
      \*********************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            translator = __webpack_require__( /*! ../../animation/translator */ 60),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Button = __webpack_require__( /*! ../button */ 196),
            DropDownMenu = __webpack_require__( /*! ../drop_down_menu */ 272);
        var DROPDOWN_APPOINTMENTS_CLASS = "dx-scheduler-dropdown-appointments",
            DROPDOWN_APPOINTMENTS_CONTENT_CLASS = "dx-scheduler-dropdown-appointments-content",
            DROPDOWN_APPOINTMENT_CLASS = "dx-scheduler-dropdown-appointment",
            DROPDOWN_APPOINTMENT_TITLE_CLASS = "dx-scheduler-dropdown-appointment-title",
            DROPDOWN_APPOINTMENT_DATE_CLASS = "dx-scheduler-dropdown-appointment-date",
            DROPDOWN_APPOINTMENT_REMOVE_BUTTON_CLASS = "dx-scheduler-dropdown-appointment-remove-button",
            DROPDOWN_APPOINTMENT_EDIT_BUTTON_CLASS = "dx-scheduler-dropdown-appointment-edit-button",
            DROPDOWN_APPOINTMENT_INFO_BLOCK_CLASS = "dx-scheduler-dropdown-appointment-info-block",
            DROPDOWN_APPOINTMENT_BUTTONS_BLOCK_CLASS = "dx-scheduler-dropdown-appointment-buttons-block";
        var dropDownAppointments = Class.inherit({
            render: function(options, instance) {
                var coordinates = options.coordinates,
                    items = options.items;
                this.instance = instance;
                var $menu = $("<div>").addClass(DROPDOWN_APPOINTMENTS_CLASS).appendTo(options.$container);
                this._createDropDownMenu({
                    $element: $menu,
                    items: items,
                    itemTemplate: options.itemTemplate,
                    buttonWidth: options.buttonWidth,
                    onAppointmentClick: options.onAppointmentClick
                });
                this._paintMenuButton($menu, options.buttonColor, items);
                this._applyInnerShadow($menu, options.buttonWidth);
                translator.move($menu, {
                    top: coordinates.top,
                    left: coordinates.left
                });
                return $menu
            },
            repaintExisting: function($container) {
                var appointmentsSelector = ["", DROPDOWN_APPOINTMENTS_CLASS, "dx-dropdownmenu"].join(".");
                $container.find(appointmentsSelector).each(function() {
                    DropDownMenu.getInstance(this).repaint()
                })
            },
            _paintMenuButton: function($menu, color, menuItems) {
                var currentItemColor, paintButton = true,
                    itemsColors = menuItems.colors,
                    itemColorCount = itemsColors.length;
                if (itemColorCount) {
                    currentItemColor = itemsColors[0];
                    for (var i = 1; i < itemColorCount; i++) {
                        if (currentItemColor !== itemsColors[i]) {
                            paintButton = false;
                            break
                        }
                        currentItemColor = itemsColors[i]
                    }
                }
                if (color && paintButton) {
                    $menu.css("background-color", color)
                }
            },
            _createButtonTemplate: function(appointmentCount) {
                return $("<div />").html([$("<span />").text(appointmentCount), $("<span />").text("...")]).addClass(DROPDOWN_APPOINTMENTS_CONTENT_CLASS)
            },
            _applyInnerShadow: function($element) {
                $element.css("box-shadow", "inset " + $element.outerWidth() + "px 0 0 0 rgba(0, 0, 0, 0.3)")
            },
            _createDropDownMenu: function(config) {
                var itemTemplate, $element = config.$element,
                    items = config.items,
                    onAppointmentClick = config.onAppointmentClick;
                if (!DropDownMenu.getInstance($element)) {
                    itemTemplate = $.proxy(function(appointmentData, index, appointmentElement) {
                        this._createDropDownAppointmentTemplate(appointmentData, appointmentElement, items.colors[index])
                    }, this);
                    var instance = this.instance;
                    this.instance._createComponent($element, DropDownMenu, {
                        buttonIcon: null,
                        usePopover: true,
                        popupHeight: 200,
                        items: items.data,
                        buttonTemplate: this._createButtonTemplate(items.data.length),
                        buttonWidth: config.buttonWidth,
                        onItemClick: function(args) {
                            args.component.open();
                            if ($.isFunction(onAppointmentClick)) {
                                onAppointmentClick.call(instance._appointments, args)
                            }
                        },
                        activeStateEnabled: false,
                        focusStateEnabled: false,
                        itemTemplate: itemTemplate
                    })
                }
            },
            _createDropDownAppointmentTemplate: function(appointmentData, appointmentElement, color) {
                var $title, $date, $infoBlock, dateString = "",
                    appointmentMarkup = [],
                    borderSide = "left",
                    text = this.instance.fire("getField", "text", appointmentData);
                appointmentElement.addClass(DROPDOWN_APPOINTMENT_CLASS);
                if (this.instance.option("rtlEnabled")) {
                    borderSide = "right"
                }
                if (color) {
                    appointmentElement.css("border-" + borderSide + "-color", color)
                }
                this.instance.fire("normalizeAppointmentDates", {
                    appointmentData: appointmentData,
                    callback: function(result) {
                        appointmentData = result
                    }
                });
                var startDate = this.instance.fire("getField", "startDate", appointmentData),
                    endDate = this.instance.fire("getField", "endDate", appointmentData);
                this.instance.fire("formatDates", {
                    startDate: startDate,
                    endDate: endDate,
                    formatType: "DATETIME",
                    callback: function(result) {
                        dateString = result
                    }
                });
                $infoBlock = $("<div />").addClass(DROPDOWN_APPOINTMENT_INFO_BLOCK_CLASS);
                $title = $("<div>").addClass(DROPDOWN_APPOINTMENT_TITLE_CLASS).text(text);
                $date = $("<div>").addClass(DROPDOWN_APPOINTMENT_DATE_CLASS).text(dateString);
                $infoBlock.append([$title, $date]);
                appointmentMarkup.push($infoBlock);
                appointmentMarkup.push(this._createButtons(appointmentData));
                appointmentElement.append(appointmentMarkup)
            },
            _createButtons: function(appointmentData) {
                var editing = this.instance.option("editing"),
                    allowDeleting = false,
                    allowUpdating = false;
                if (!editing) {
                    return ""
                }
                if (true === editing) {
                    allowDeleting = true;
                    allowUpdating = true
                }
                if (commonUtils.isObject(editing)) {
                    allowDeleting = editing.allowDeleting;
                    allowUpdating = editing.allowUpdating
                }
                var $container = $("<div />").addClass(DROPDOWN_APPOINTMENT_BUTTONS_BLOCK_CLASS),
                    $removeButton = $("<div>").addClass(DROPDOWN_APPOINTMENT_REMOVE_BUTTON_CLASS),
                    $editButton = $("<div>").addClass(DROPDOWN_APPOINTMENT_EDIT_BUTTON_CLASS);
                if (allowDeleting) {
                    $container.append($removeButton);
                    this.instance._createComponent($removeButton, Button, {
                        icon: "trash",
                        height: 25,
                        width: 25,
                        onClick: $.proxy(function(e) {
                            e.jQueryEvent.stopPropagation();
                            this.instance.deleteAppointment(appointmentData)
                        }, this)
                    })
                }
                if (allowUpdating) {
                    $container.append($editButton);
                    this.instance._createComponent($editButton, Button, {
                        icon: "edit",
                        height: 25,
                        width: 25,
                        onClick: $.proxy(function(e) {
                            e.jQueryEvent.stopPropagation();
                            this.instance.fire("showEditAppointmentPopup", {
                                data: appointmentData
                            })
                        }, this)
                    })
                }
                return $container
            }
        });
        module.exports = dropDownAppointments
    },
    /*!********************************************!*\
      !*** ./Scripts/ui/scheduler/ui.loading.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            viewPortUtils = __webpack_require__( /*! ../../core/utils/view_port */ 42),
            LoadPanel = __webpack_require__( /*! ../load_panel */ 239);
        var loading = null;
        var createLoadPanel = function(options) {
            return new LoadPanel($("<div>").appendTo(options && options.container || viewPortUtils.value()), options)
        };
        var removeLoadPanel = function() {
            if (!loading) {
                return
            }
            loading.element().remove();
            loading = null
        };
        exports.show = function(options) {
            removeLoadPanel();
            loading = createLoadPanel(options);
            return loading.show()
        };
        exports.hide = function() {
            if (!loading) {
                return $.when()
            }
            return loading.hide().done(removeLoadPanel).promise()
        }
    },
    /*!***************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.appointment_form.js ***!
      \***************************************************************/
    function(module, exports, __webpack_require__) {
        var Form = __webpack_require__( /*! ../form */ 276),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        __webpack_require__( /*! ./ui.scheduler.recurrence_editor */ 437);
        __webpack_require__( /*! ./ui.scheduler.timezone_editor */ 438);
        var RECURRENCE_EDITOR_ITEM_CLASS = "dx-scheduler-recurrence-rule-item";
        var SchedulerAppointmentForm = {
            _appointmentForm: {},
            _validateAppointmentFormDate: function(editor, value, previousValue) {
                var isCorrectDate = !!value;
                if (!isCorrectDate) {
                    editor.option("value", previousValue)
                }
            },
            _getAllDayStartDate: function(startDate) {
                startDate.setHours(0);
                startDate.setMinutes(0);
                return startDate
            },
            _getAllDayEndDate: function(startDate) {
                var endDate = new Date(startDate);
                endDate.setDate(startDate.getDate() + 1);
                return endDate
            },
            create: function(componentCreator, $container, isReadOnly, formData) {
                this._appointmentForm = componentCreator($container, Form, {
                    items: this._editors,
                    readOnly: isReadOnly,
                    showValidationSummary: true,
                    scrollingEnabled: true,
                    formData: formData
                });
                return this._appointmentForm
            },
            prepareAppointmentFormEditors: function(allDay, dataExprs, schedulerInst) {
                var that = this;
                this._editors = [{
                    dataField: dataExprs.textExpr,
                    editorType: "dxTextBox",
                    label: {
                        text: messageLocalization.format("dxScheduler-editorLabelTitle")
                    }
                }, {
                    itemType: "empty"
                }, {
                    dataField: dataExprs.allDayExpr,
                    editorType: "dxSwitch",
                    label: {
                        text: messageLocalization.format("dxScheduler-allDay")
                    },
                    editorOptions: {
                        onValueChanged: function(args) {
                            var startDate, value = args.value,
                                startDateEditor = that._appointmentForm.getEditor(dataExprs.startDateExpr),
                                endDateEditor = that._appointmentForm.getEditor(dataExprs.endDateExpr);
                            if (startDateEditor && endDateEditor) {
                                startDateEditor.option("type", value ? "date" : "datetime");
                                endDateEditor.option("type", value ? "date" : "datetime");
                                startDate = new Date(startDateEditor.option("value"));
                                if (value) {
                                    startDateEditor.option("value", that._getAllDayStartDate(startDate));
                                    endDateEditor.option("value", that._getAllDayEndDate(startDate))
                                } else {
                                    if (startDateEditor.option("value")) {
                                        startDate.setHours(schedulerInst.option("startDayHour"));
                                        startDateEditor.option("value", startDate);
                                        endDateEditor.option("value", schedulerInst._workSpace.calculateEndDate(startDateEditor.option("value")))
                                    }
                                }
                            }
                        }
                    }
                }, {
                    dataField: dataExprs.startDateExpr,
                    editorType: "dxDateBox",
                    label: {
                        text: messageLocalization.format("dxScheduler-editorLabelStartDate")
                    },
                    editorOptions: {
                        type: allDay ? "date" : "datetime",
                        width: "100%",
                        onValueChanged: function(args) {
                            var value = args.value,
                                previousValue = args.previousValue,
                                endDateEditor = that._appointmentForm.getEditor(dataExprs.endDateExpr),
                                endValue = endDateEditor.option("value");
                            that._validateAppointmentFormDate(args.component, value, previousValue);
                            if (endValue <= value) {
                                var duration = endValue.getTime() - previousValue.getTime();
                                endDateEditor.option("value", new Date(value.getTime() + duration))
                            }
                        }
                    }
                }, {
                    dataField: dataExprs.startDateTimeZoneExpr,
                    editorType: "dxSchedulerTimezoneEditor",
                    label: {
                        text: " ",
                        showColon: false
                    },
                    editorOptions: {
                        observer: schedulerInst
                    },
                    visible: false
                }, {
                    dataField: dataExprs.endDateExpr,
                    editorType: "dxDateBox",
                    label: {
                        text: messageLocalization.format("dxScheduler-editorLabelEndDate")
                    },
                    editorOptions: {
                        type: allDay ? "date" : "datetime",
                        width: "100%",
                        onValueChanged: function(args) {
                            var value = args.value,
                                previousValue = args.previousValue,
                                startDateEditor = that._appointmentForm.getEditor(dataExprs.startDateExpr),
                                startValue = startDateEditor.option("value");
                            that._validateAppointmentFormDate(args.component, value, previousValue);
                            if (value && startValue >= value) {
                                var duration = previousValue.getTime() - startValue.getTime();
                                startDateEditor.option("value", new Date(value.getTime() - duration))
                            }
                        }
                    }
                }, {
                    dataField: dataExprs.endDateTimeZoneExpr,
                    editorType: "dxSchedulerTimezoneEditor",
                    label: {
                        text: " ",
                        showColon: false
                    },
                    editorOptions: {
                        observer: schedulerInst
                    },
                    visible: false
                }, {
                    itemType: "empty"
                }, {
                    dataField: dataExprs.descriptionExpr,
                    editorType: "dxTextArea",
                    label: {
                        text: messageLocalization.format("dxScheduler-editorLabelDescription")
                    }
                }, {
                    dataField: dataExprs.recurrenceRuleExpr,
                    editorType: "dxSchedulerRecurrenceEditor",
                    editorOptions: {
                        observer: schedulerInst,
                        onContentReady: function(args) {
                            var $editorField = args.element.closest(".dx-field-item"),
                                $editorLabel = $editorField.find(".dx-field-item-label");
                            $editorLabel.off(clickEvent.name).on(clickEvent.name, function() {
                                args.component.toggle()
                            })
                        }
                    },
                    cssClass: RECURRENCE_EDITOR_ITEM_CLASS,
                    label: {
                        text: messageLocalization.format("dxScheduler-editorLabelRecurrence")
                    }
                }];
                if (!dataExprs.recurrenceRuleExpr) {
                    this._editors.splice(9, 1)
                }
                return this._editors
            },
            concatResources: function(resources) {
                this._editors = this._editors.concat(resources)
            }
        };
        module.exports = SchedulerAppointmentForm
    },
    /*!****************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.recurrence_editor.js ***!
      \****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            Guid = __webpack_require__( /*! ../../core/guid */ 153),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            recurrenceUtils = __webpack_require__( /*! ./utils.recurrence */ 404),
            domUtils = __webpack_require__( /*! ../../core/utils/dom */ 50),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            CheckBox = __webpack_require__( /*! ../check_box */ 241),
            RadioGroup = __webpack_require__( /*! ../radio_group */ 297),
            Switch = __webpack_require__( /*! ../switch */ 308),
            NumberBox = __webpack_require__( /*! ../number_box */ 255),
            SelectBox = __webpack_require__( /*! ../select_box */ 307),
            DateBox = __webpack_require__( /*! ../date_box */ 259),
            publisherMixin = __webpack_require__( /*! ./ui.scheduler.publisher_mixin */ 410),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            dateLocalization = __webpack_require__( /*! ../../localization/date */ 56),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52);
        var clickEvent = __webpack_require__( /*! ../../events/click */ 64);
        var RECURRENCE_EDITOR = "dx-recurrence-editor",
            LABEL_POSTFIX = "-label",
            RECURRENCE_EDITOR_CONTAINER = "dx-recurrence-editor-container",
            SWITCH_EDITOR = "dx-recurrence-switch",
            SWITCH_REPEAT_END_EDITOR = "dx-recurrence-switch-repeat-end",
            FREQUENCY_EDITOR = "dx-recurrence-radiogroup-freq",
            INTERVAL_EDITOR = "dx-recurrence-numberbox-interval",
            INTERVAL_EDITOR_FIELD = "dx-recurrence-interval-field",
            REPEAT_END_EDITOR = "dx-recurrence-repeat-end",
            REPEAT_END_EDITOR_FIELD = "dx-recurrence-repeat-end-field",
            REPEAT_END_EDITOR_CONTAINER = "dx-recurrence-repeat-end-container",
            REPEAT_TYPE_EDITOR = "dx-recurrence-radiogroup-repeat-type",
            REPEAT_COUNT_EDITOR = "dx-recurrence-numberbox-repeat-count",
            REPEAT_UNTIL_DATE_EDITOR = "dx-recurrence-datebox-until-date",
            REPEAT_ON_EDITOR = "dx-recurrence-repeat-on",
            REPEAT_ON_WEEK_EDITOR = "dx-recurrence-repeat-on-week",
            DAY_OF_WEEK = "dx-recurrence-checkbox-day-of-week",
            REPEAT_ON_MONTH_EDITOR = "dx-recurrence-repeat-on-month",
            DAY_OF_MONTH = "dx-recurrence-numberbox-day-of-month",
            REPEAT_ON_YEAR_EDITOR = "dx-recurrence-repeat-on-year",
            MONTH_OF_YEAR = "dx-recurrence-selectbox-month-of-year",
            FIELD_CLASS = "dx-field",
            FIELD_LABEL_CLASS = "dx-field-label",
            FIELD_VALUE_CLASS = "dx-field-value",
            frequencies = [{
                text: function() {
                    return messageLocalization.format("dxScheduler-recurrenceDaily")
                },
                value: "DAILY"
            }, {
                text: function() {
                    return messageLocalization.format("dxScheduler-recurrenceWeekly")
                },
                value: "WEEKLY"
            }, {
                text: function() {
                    return messageLocalization.format("dxScheduler-recurrenceMonthly")
                },
                value: "MONTHLY"
            }, {
                text: function() {
                    return messageLocalization.format("dxScheduler-recurrenceYearly")
                },
                value: "YEARLY"
            }],
            repeatEndTypes = [{
                text: function() {
                    return messageLocalization.format("dxScheduler-recurrenceRepeatCount")
                },
                value: "count"
            }, {
                text: function() {
                    return messageLocalization.format("dxScheduler-recurrenceRepeatOnDate")
                },
                value: "until"
            }],
            days = ["SU", "MO", "TU", "WE", "TH", "FR", "SA"];
        var RecurrenceRule = Class.inherit({
            ctor: function(recurrence) {
                this._recurrenceRule = recurrenceUtils.getRecurrenceRule(recurrence).rule
            },
            makeRules: function(string) {
                var that = this;
                that._recurrenceRule = recurrenceUtils.getRecurrenceRule(string).rule
            },
            makeRule: function(field, value) {
                if (!value) {
                    delete this._recurrenceRule[field];
                    return
                }
                if (commonUtils.isDefined(field)) {
                    if ("until" === field) {
                        delete this._recurrenceRule.count
                    }
                    if ("count" === field) {
                        delete this._recurrenceRule.until
                    }
                    this._recurrenceRule[field] = value
                }
            },
            repeatableRule: function() {
                var rules = this._recurrenceRule;
                if ("count" in rules) {
                    return "count"
                }
                if ("until" in rules) {
                    return "until"
                }
                return null
            },
            recurrenceString: function() {
                return recurrenceUtils.getRecurrenceString(this._recurrenceRule)
            },
            rules: function() {
                return this._recurrenceRule
            },
            daysFromByDayRule: function() {
                return recurrenceUtils.daysFromByDayRule(this._recurrenceRule)
            }
        });
        var SchedulerRecurrenceEditor = Editor.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: null,
                    onValueChanged: null,
                    startDate: new Date
                })
            },
            _createComponent: function(element, name, config) {
                config = config || {};
                this._extendConfig(config, {
                    readOnly: this.option("readOnly")
                });
                return this.callBase(element, name, config)
            },
            _init: function() {
                this.callBase();
                this._recurrenceRule = new RecurrenceRule(this.option("value"))
            },
            _render: function() {
                this.callBase();
                this.element().addClass(RECURRENCE_EDITOR);
                this._renderSwitch();
                this._$container = $("<div>").addClass(RECURRENCE_EDITOR_CONTAINER).appendTo(this.element());
                this._renderEditors();
                this._renderContainerVisibility(!!this.option("value"))
            },
            _renderSwitch: function() {
                var $switchEditor = $("<div>").addClass(SWITCH_EDITOR);
                this._switchEditor = this._createComponent($switchEditor, Switch, {
                    value: !!this.option("value"),
                    onValueChanged: $.proxy(this._switchValueChangeHandler, this)
                });
                this.element().append($switchEditor)
            },
            _switchValueChangeHandler: function(args) {
                var value = args.value;
                this._renderContainerVisibility(value);
                if (!this.option("value") && value) {
                    this._handleDefaults()
                } else {
                    if (!value) {
                        this._recurrenceRule.makeRules("");
                        this.option("value", "")
                    }
                }
            },
            _renderContainerVisibility: function(value) {
                if (value) {
                    this._$container.show();
                    this.notifyObserver("recurrenceEditorVisibilityChanged", {
                        visible: true
                    });
                    domUtils.triggerShownEvent(this._$container)
                } else {
                    this._$container.hide();
                    this.notifyObserver("recurrenceEditorVisibilityChanged", {
                        visible: false
                    })
                }
            },
            _handleDefaults: function() {
                this._recurrenceRule.makeRule("freq", "DAILY");
                this._changeEditorValue()
            },
            _changeEditorValue: function() {
                this.option("value", this._recurrenceRule.recurrenceString() || "")
            },
            _renderEditors: function() {
                this._renderFreqEditor();
                this._renderIntervalEditor();
                this._renderRepeatOnEditor();
                this._renderRepeatEndSwitch();
                this._renderRepeatEndEditor();
                this._renderRepeatEndVisibility(!!this._recurrenceRule.repeatableRule())
            },
            _renderFreqEditor: function() {
                var freq = this._recurrenceRule.rules().freq || "DAILY";
                var $freqEditor = $("<div>").addClass(FREQUENCY_EDITOR).addClass(FIELD_VALUE_CLASS);
                this._freqEditor = this._createComponent($freqEditor, RadioGroup, {
                    field: "freq",
                    items: frequencies,
                    value: freq,
                    valueExpr: "value",
                    displayExpr: "text",
                    layout: "horizontal",
                    onValueChanged: $.proxy(this._valueChangedHandler, this)
                });
                var $field = $("<div>").addClass(FIELD_CLASS).append($freqEditor);
                this._$container.append($field)
            },
            _renderIntervalEditor: function() {
                var freq = this._recurrenceRule.rules().freq || "DAILY";
                var $intervalEditor = $("<div>").addClass(INTERVAL_EDITOR).addClass(FIELD_VALUE_CLASS);
                var $intervalEditorLabel = $("<div>").text(messageLocalization.format("dxScheduler-recurrenceEvery") + ":").addClass(INTERVAL_EDITOR + LABEL_POSTFIX).addClass(FIELD_LABEL_CLASS);
                this._$intervalTypeLabel = $("<div>").text(messageLocalization.format("dxScheduler-recurrenceRepeat" + freq.charAt(0).toUpperCase() + freq.substr(1).toLowerCase())).addClass(REPEAT_TYPE_EDITOR + LABEL_POSTFIX);
                var interval = this._recurrenceRule.rules().interval || 1;
                this._intervalEditor = this._createComponent($intervalEditor, NumberBox, {
                    field: "interval",
                    min: 1,
                    value: interval,
                    showSpinButtons: true,
                    useTouchSpinButtons: false,
                    onValueChanged: $.proxy(this._valueChangedHandler, this)
                });
                var $field = $("<div>").addClass(FIELD_CLASS).addClass(INTERVAL_EDITOR_FIELD).append($intervalEditorLabel, $intervalEditor, this._$intervalTypeLabel);
                this._$container.append($field);
                this._setAriaDescribedBy(this._intervalEditor, $intervalEditorLabel)
            },
            _renderRepeatOnEditor: function() {
                var freq = this._recurrenceRule.rules().freq;
                if (!commonUtils.isDefined(this._$repeatOnEditor)) {
                    this._$repeatOnEditor = $("<div>").addClass(REPEAT_ON_EDITOR).addClass(FIELD_CLASS).appendTo(this._$container)
                }
                if (!freq || "DAILY" === freq) {
                    this._clearRepeatOnEditor();
                    this._clearRepeatOnLabel();
                    return
                }
                if (!commonUtils.isDefined(this._$repeatOnLabel)) {
                    this._renderRepeatOnLabel(this._$repeatOnEditor)
                }
                if ("WEEKLY" === freq && !this._$repeatOnWeek) {
                    this._renderRepeatOnWeekEditor();
                    return
                }
                if ("MONTHLY" === freq && !this._$repeatOnMonth) {
                    this._renderRepeatOnMonthEditor();
                    return
                }
                if ("YEARLY" === freq && !this._$repeatOnYear) {
                    this._renderRepeatOnYearEditor();
                    return
                }
            },
            _renderRepeatOnLabel: function($element) {
                this._$repeatOnLabel = $("<div>").text(messageLocalization.format("dxScheduler-recurrenceOn") + ":").addClass(REPEAT_ON_EDITOR + LABEL_POSTFIX).addClass(FIELD_LABEL_CLASS);
                $element.append(this._$repeatOnLabel)
            },
            _clearRepeatOnEditor: function() {
                if (commonUtils.isDefined(this._$repeatOnWeek)) {
                    this._$repeatOnWeek.detach();
                    this._$repeatOnWeek.remove();
                    delete this._$repeatOnWeek
                }
                if (commonUtils.isDefined(this._$repeatOnMonth)) {
                    this._$repeatOnMonth.detach();
                    this._$repeatOnMonth.remove();
                    delete this._$repeatOnMonth
                }
                if (commonUtils.isDefined(this._$repeatOnYear)) {
                    this._$repeatOnYear.detach();
                    this._$repeatOnYear.remove();
                    delete this._$repeatOnYear
                }
            },
            _clearRepeatOnEditorValues: function() {
                this._recurrenceRule.makeRule("bymonth", "");
                this._recurrenceRule.makeRule("bymonthday", "");
                this._recurrenceRule.makeRule("byday", "")
            },
            _clearRepeatOnLabel: function() {
                if (commonUtils.isDefined(this._$repeatOnLabel)) {
                    this._$repeatOnLabel.detach();
                    this._$repeatOnLabel.remove();
                    delete this._$repeatOnLabel
                }
            },
            _renderRepeatOnWeekEditor: function() {
                this._clearRepeatOnEditor();
                this._$repeatOnWeek = $("<div>").addClass(REPEAT_ON_WEEK_EDITOR).addClass(FIELD_VALUE_CLASS).appendTo(this._$repeatOnEditor);
                var localDaysNames = dateLocalization.getDayNames("short"),
                    daysFromRules = this._daysOfWeekByRules();
                this._daysOfWeek = [];
                for (var i = 0; i < 7; i++) {
                    var checkBoxText = localDaysNames[i].toUpperCase(),
                        dayName = days[i];
                    var $day = $("<div>").addClass(DAY_OF_WEEK),
                        day = this._createComponent($day, CheckBox, {
                            text: checkBoxText,
                            value: $.inArray(dayName, daysFromRules) > -1 ? true : false,
                            onValueChanged: $.proxy(this._repeatByDayValueChangeHandler, this)
                        });
                    this._daysOfWeek[i] = day;
                    this._$repeatOnWeek.append($day)
                }
            },
            _daysOfWeekByRules: function() {
                var daysByRule = this._recurrenceRule.daysFromByDayRule();
                if (!daysByRule.length) {
                    daysByRule = [days[this.option("startDate").getDay()]]
                }
                return daysByRule
            },
            _repeatByDayValueChangeHandler: function() {
                var byDayRule = "";
                $.each(this._daysOfWeek, function(index, day) {
                    if (day.option("value")) {
                        var dayName = days[index];
                        if (!byDayRule) {
                            byDayRule = dayName
                        } else {
                            byDayRule = byDayRule + "," + dayName
                        }
                    }
                });
                this._recurrenceRule.makeRule("byday", byDayRule);
                this._changeEditorValue()
            },
            _renderRepeatOnMonthEditor: function() {
                this._clearRepeatOnEditor();
                this._$repeatOnMonth = $("<div>").addClass(REPEAT_ON_MONTH_EDITOR).addClass(FIELD_VALUE_CLASS).appendTo(this._$repeatOnEditor);
                this._renderDayOfMonthEditor(this._$repeatOnMonth)
            },
            _renderRepeatOnYearEditor: function() {
                this._clearRepeatOnEditor();
                this._$repeatOnYear = $("<div>").addClass(REPEAT_ON_YEAR_EDITOR).addClass(FIELD_VALUE_CLASS).appendTo(this._$repeatOnEditor);
                var months = [],
                    monthsNames = dateLocalization.getMonthNames("wide");
                for (var i = 0; i < 12; i++) {
                    months[i] = {
                        value: String(i + 1),
                        text: monthsNames[i]
                    }
                }
                var bymonth = this._monthOfYearByRules();
                var $monthOfYear = $("<div>").addClass(MONTH_OF_YEAR).appendTo(this._$repeatOnYear);
                var monthChanged = function(args) {
                    this._valueChangedHandler.call(this, args);
                    var monthValue = parseInt(args.component.option("value"));
                    if (this._dayEditor && monthValue) {
                        var maxAllowedDay = new Date((new Date).getFullYear(), parseInt(monthValue), 0).getDate();
                        if (2 === monthValue) {
                            maxAllowedDay = 29
                        }
                        this._dayEditor.option("max", maxAllowedDay)
                    }
                };
                this._monthEditor = this._createComponent($monthOfYear, SelectBox, {
                    field: "bymonth",
                    items: months,
                    value: bymonth,
                    displayExpr: "text",
                    valueExpr: "value",
                    onValueChanged: $.proxy(monthChanged, this)
                });
                this._renderDayOfMonthEditor(this._$repeatOnYear)
            },
            _monthOfYearByRules: function() {
                var monthByRule = this._recurrenceRule.rules().bymonth;
                if (!monthByRule) {
                    monthByRule = this.option("startDate").getMonth() + 1
                }
                return monthByRule
            },
            _renderDayOfMonthEditor: function($element) {
                var bymonthday = this._dayOfMonthByRules();
                var $dayEditor = $("<div>").addClass(DAY_OF_MONTH);
                this._dayEditor = this._createComponent($dayEditor, NumberBox, {
                    field: "bymonthday",
                    min: 1,
                    max: 31,
                    showSpinButtons: true,
                    useTouchSpinButtons: false,
                    value: bymonthday,
                    onValueChanged: $.proxy(this._valueChangedHandler, this)
                });
                $element.append($dayEditor)
            },
            _dayOfMonthByRules: function() {
                var dayByRule = this._recurrenceRule.rules().bymonthday;
                if (!dayByRule) {
                    dayByRule = this.option("startDate").getDate()
                }
                return dayByRule
            },
            _setAriaDescribedBy: function(editor, $label) {
                var labelId = "label-" + new Guid;
                editor.setAria("describedby", labelId);
                editor.setAria("id", labelId, $label)
            },
            _renderRepeatEndSwitch: function() {
                var that = this;
                var $switchEndEditor = $("<div>").addClass(SWITCH_REPEAT_END_EDITOR).addClass(FIELD_VALUE_CLASS),
                    $switchEndLabel = $("<div>").text(messageLocalization.format("dxScheduler-recurrenceEnd") + ":").addClass(INTERVAL_EDITOR + LABEL_POSTFIX).addClass(FIELD_LABEL_CLASS);
                this._switchEndEditor = this._createComponent($switchEndEditor, Switch, {
                    value: that._recurrenceRule.repeatableRule() ? true : false,
                    onValueChanged: $.proxy(this._repeatEndSwitchValueChangeHandler, this)
                });
                $("<div>").addClass(FIELD_CLASS).addClass(REPEAT_END_EDITOR_FIELD).append($switchEndLabel, $switchEndEditor).appendTo(this._$container);
                this._setAriaDescribedBy(this._switchEndEditor, $switchEndLabel)
            },
            _repeatEndSwitchValueChangeHandler: function(args) {
                var value = args.value;
                this._renderRepeatEndVisibility(value);
                if (!this._recurrenceRule.rules().count && !this._recurrenceRule.rules().until && value) {
                    this._handleRepeatEndDefaults()
                } else {
                    if (!value) {
                        this._recurrenceRule.makeRule("count", "");
                        this._recurrenceRule.makeRule("until", "");
                        this._changeEditorValue()
                    }
                }
            },
            _renderRepeatEndVisibility: function(value) {
                if (!value) {
                    this._$repeatEndEditor.hide()
                } else {
                    this._$repeatEndEditor.show()
                }
            },
            _handleRepeatEndDefaults: function() {
                this._recurrenceRule.makeRule("count", 1);
                this._changeEditorValue()
            },
            _renderRepeatEndEditor: function(rule) {
                rule = commonUtils.isDefined(rule) ? rule : this._recurrenceRule.repeatableRule();
                if (!rule) {
                    rule = "count"
                }
                if (!commonUtils.isDefined(this._$repeatEndEditor)) {
                    this._$repeatEndEditor = $("<div>").addClass(REPEAT_END_EDITOR_CONTAINER).addClass(FIELD_CLASS).appendTo(this._$container);
                    this._renderRepeatEndTypeEditor()
                }
            },
            _renderRepeatEndTypeEditor: function() {
                var repeatType = this._recurrenceRule.repeatableRule() || "count",
                    that = this;
                this._$repeatTypeEditor = $("<div>").addClass(REPEAT_TYPE_EDITOR).addClass(FIELD_VALUE_CLASS).appendTo(this._$repeatEndEditor);
                this._repeatTypeEditor = this._createComponent(this._$repeatTypeEditor, RadioGroup, {
                    items: repeatEndTypes,
                    value: repeatType,
                    displayExpr: "text",
                    valueExpr: "value",
                    itemTemplate: function(itemData) {
                        if ("count" === itemData.value) {
                            return that._renderRepeatCountEditor()
                        } else {
                            return that._renderRepeatUntilEditor()
                        }
                    },
                    layout: "vertical",
                    onValueChanged: $.proxy(this._repeatTypeValueChangedHandler, this)
                });
                this._disableRepeatEndParts(repeatType)
            },
            _repeatTypeValueChangedHandler: function(args) {
                var value = args.value;
                this._disableRepeatEndParts(value);
                if ("until" === value) {
                    this._recurrenceRule.makeRule(value, this._getUntilValue())
                } else {
                    if ("count" === value) {
                        this._recurrenceRule.makeRule(value, this._repeatCountEditor.option("value"))
                    }
                }
                this._changeEditorValue()
            },
            _disableRepeatEndParts: function(value) {
                if ("until" === value) {
                    this._repeatCountEditor.option("disabled", true);
                    this._repeatUntilDate.option("disabled", false)
                } else {
                    if ("count" === value) {
                        this._repeatCountEditor.option("disabled", false);
                        this._repeatUntilDate.option("disabled", true)
                    }
                }
            },
            _renderRepeatCountEditor: function() {
                var repeatCount = this._recurrenceRule.rules().count || 1,
                    $editorTemplate = $("<div>");
                $("<div>").text(messageLocalization.format("dxScheduler-recurrenceAfter") + ":").addClass(REPEAT_END_EDITOR + LABEL_POSTFIX).appendTo($editorTemplate);
                this._$repeatCountEditor = $("<div>").addClass(REPEAT_COUNT_EDITOR).addClass(FIELD_VALUE_CLASS).appendTo($editorTemplate);
                $("<div>").text(messageLocalization.format("dxScheduler-recurrenceRepeatCount")).addClass(REPEAT_END_EDITOR + LABEL_POSTFIX).appendTo($editorTemplate);
                this._repeatCountEditor = this._createComponent(this._$repeatCountEditor, NumberBox, {
                    field: "count",
                    min: 1,
                    showSpinButtons: true,
                    useTouchSpinButtons: false,
                    value: repeatCount,
                    onValueChanged: $.proxy(this._repeatCountValueChangeHandler, this)
                });
                return $editorTemplate
            },
            _repeatCountValueChangeHandler: function(args) {
                if ("count" !== this._recurrenceRule.repeatableRule()) {
                    return
                }
                var value = args.value;
                this._recurrenceRule.makeRule("count", value);
                this._changeEditorValue()
            },
            _formatUntilDate: function(date) {
                var result = dateUtils.trimTime(date);
                result.setDate(result.getDate() + 1);
                return new Date(result.getTime() - 1)
            },
            _renderRepeatUntilEditor: function() {
                var repeatUntil = this._recurrenceRule.rules().until || this._formatUntilDate(new Date),
                    $editorTemplate = $("<div>");
                $("<div>").text(messageLocalization.format("dxScheduler-recurrenceOn") + ":").addClass(REPEAT_END_EDITOR + LABEL_POSTFIX).appendTo($editorTemplate);
                this._$repeatDateEditor = $("<div>").addClass(REPEAT_UNTIL_DATE_EDITOR).addClass(FIELD_VALUE_CLASS).appendTo($editorTemplate);
                this._repeatUntilDate = this._createComponent(this._$repeatDateEditor, DateBox, {
                    field: "until",
                    value: repeatUntil,
                    type: "date",
                    onValueChanged: $.proxy(this._repeatUntilValueChangeHandler, this)
                });
                return $editorTemplate
            },
            _repeatUntilValueChangeHandler: function(args) {
                if ("until" !== this._recurrenceRule.repeatableRule()) {
                    return
                }
                var untilDate = this._formatUntilDate(new Date(args.value));
                this._repeatUntilDate.option("value", untilDate);
                this._recurrenceRule.makeRule("until", untilDate);
                this._changeEditorValue()
            },
            _valueChangedHandler: function(args) {
                var value = args.component.option("value"),
                    field = args.component.option("field");
                if ("freq" === field) {
                    this._clearRepeatOnEditorValues()
                }
                this._recurrenceRule.makeRule(field, value);
                this._makeRepeatOnRule(field, value);
                this._changeEditorValue()
            },
            _makeRepeatOnRule: function(field, value) {
                if ("freq" !== field || "DAILY" === value) {
                    return
                }
                if ("WEEKLY" === value) {
                    this._recurrenceRule.makeRule("byday", this._daysOfWeekByRules())
                }
                if ("MONTHLY" === value) {
                    this._recurrenceRule.makeRule("bymonthday", this._dayOfMonthByRules())
                }
                if ("YEARLY" === value) {
                    this._recurrenceRule.makeRule("bymonthday", this._dayOfMonthByRules());
                    this._recurrenceRule.makeRule("bymonth", this._monthOfYearByRules())
                }
            },
            _optionChanged: function(args) {
                switch (args.name) {
                    case "value":
                        this._recurrenceRule.makeRules(args.value);
                        this._switchEditor.option("value", !!args.value);
                        this._switchEndEditor.option("value", !!this._recurrenceRule.repeatableRule());
                        this._repeatTypeEditor.option("value", this._recurrenceRule.repeatableRule() || "count");
                        this._renderRepeatEndEditor();
                        this._renderRepeatOnEditor();
                        this._changeEditorsValues(this._recurrenceRule.rules());
                        this.callBase(args);
                        break;
                    case "startDate":
                        this._clearRepeatOnEditor();
                        this._renderRepeatOnEditor();
                        this._makeRepeatOnRule("freq", this._recurrenceRule.rules().freq);
                        if (commonUtils.isDefined(this._recurrenceRule.recurrenceString())) {
                            this._changeEditorValue()
                        }
                        break;
                    default:
                        this.callBase(args)
                }
            },
            _changeEditorsValues: function(rules) {
                this._freqEditor.option("value", rules.freq);
                this._changeRepeatTypeLabel();
                this._intervalEditor.option("value", rules.interval);
                this._changeRepeatCountValue();
                this._changeRepeatUntilValue();
                this._changeCheckBoxesValue();
                this._changeDayOfMonthValue();
                this._changeMonthOfYearValue()
            },
            _changeRepeatTypeLabel: function() {
                var $labels = this.element().find("." + REPEAT_TYPE_EDITOR + LABEL_POSTFIX);
                if (!$labels.length) {
                    return
                }
                var freq = this._recurrenceRule.rules().freq || "DAILY";
                $.each($labels, function(_, $label) {
                    $($label).text(messageLocalization.format("dxScheduler-recurrenceRepeat" + freq.charAt(0).toUpperCase() + freq.substr(1).toLowerCase()))
                })
            },
            _changeRepeatCountValue: function() {
                if (!this._$repeatCountEditor) {
                    return
                }
                var count = this._recurrenceRule.rules().count || 1;
                this._repeatCountEditor.option("value", count)
            },
            _changeRepeatUntilValue: function() {
                if (!this._$repeatDateEditor) {
                    return
                }
                this._repeatUntilDate.option("value", this._getUntilValue())
            },
            _getUntilValue: function() {
                return this._recurrenceRule.rules().until || this._formatUntilDate(new Date)
            },
            _changeCheckBoxesValue: function() {
                if (!this._$repeatOnWeek) {
                    return
                }
                var daysByRule = this._daysOfWeekByRules();
                $.each(this._daysOfWeek, function(index, day) {
                    var dayName = days[index];
                    day.option("value", $.inArray(dayName, daysByRule) > -1)
                })
            },
            _changeDayOfMonthValue: function() {
                if (!this._$repeatOnMonth && !this._$repeatOnYear) {
                    return
                }
                var day = this._dayOfMonthByRules() || 1;
                this._dayEditor.option("value", day)
            },
            _changeMonthOfYearValue: function() {
                if (!this._$repeatOnYear) {
                    return
                }
                var month = this._monthOfYearByRules() || 1;
                this._monthEditor.option("value", month)
            },
            toggle: function() {
                this._switchEditor.element().trigger(clickEvent.name)
            },
            setAria: function() {
                if (this._switchEditor) {
                    this._switchEditor.setAria(arguments[0], arguments[1])
                }
            }
        }).include(publisherMixin);
        registerComponent("dxSchedulerRecurrenceEditor", SchedulerRecurrenceEditor);
        module.exports = SchedulerRecurrenceEditor
    },
    /*!**************************************************************!*\
      !*** ./Scripts/ui/scheduler/ui.scheduler.timezone_editor.js ***!
      \**************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            publisherMixin = __webpack_require__( /*! ./ui.scheduler.publisher_mixin */ 410),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            Editor = __webpack_require__( /*! ../editor/editor */ 107),
            SelectBox = __webpack_require__( /*! ../select_box */ 307);
        var TIMEZONE_EDITOR_CLASS = "dx-timezone-editor",
            TIMEZONE_DISPLAY_NAME_SELECTBOX_CLASS = "dx-timezone-display-name",
            TIMEZONE_IANA_ID_SELECTBOX_CLASS = "dx-timezone-iana-id";
        var SchedulerTimezoneEditor = Editor.inherit({
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    value: null
                })
            },
            _createComponent: function(element, name, config) {
                config = config || {};
                this._extendConfig(config, {
                    readOnly: this.option("readOnly")
                });
                return this.callBase(element, name, config)
            },
            _init: function() {
                this.callBase();
                this.element().addClass(TIMEZONE_EDITOR_CLASS)
            },
            _render: function() {
                this._renderDisplayNameEditor();
                this._renderIanaIdEditor();
                this.callBase()
            },
            _renderDisplayNameEditor: function() {
                var noTzTitle = messageLocalization.format("dxScheduler-noTimezoneTitle"),
                    value = this.invoke("getTimezoneDisplayNameById", this.option("value")) || noTzTitle;
                this._displayNameEditor = this._renderSelectBox(TIMEZONE_DISPLAY_NAME_SELECTBOX_CLASS, {
                    items: [noTzTitle].concat(this.invoke("getTimezonesDisplayName")),
                    value: value,
                    onOptionChanged: function(e) {
                        if ("value" === e.name) {
                            this._processDisplayNameChanging(e.value)
                        }
                    }.bind(this)
                })
            },
            _renderIanaIdEditor: function() {
                this._ianaIdEditor = this._renderSelectBox(TIMEZONE_IANA_ID_SELECTBOX_CLASS, {
                    items: this._idsDataSource(),
                    value: this.option("value"),
                    onOptionChanged: function(e) {
                        if ("value" === e.name) {
                            this.option("value", e.value)
                        }
                    }.bind(this),
                    valueExpr: "id",
                    displayExpr: "displayName",
                    disabled: this._calculateIanaIdEditorDisabledState()
                })
            },
            _renderSelectBox: function(cssClass, options) {
                options = options || {};
                var $element = $("<div />").addClass(cssClass),
                    selectBox = this._createComponent($element, SelectBox, options);
                this.element().append($element);
                return selectBox
            },
            _idsDataSource: function(data) {
                return this.invoke("getSimilarTimezones", this.option("value"))
            },
            _calculateIanaIdEditorDisabledState: function() {
                return !this.option("value")
            },
            _processDisplayNameChanging: function(displayName) {
                var tzIds = this.invoke("getTimezonesIdsByDisplayName", displayName),
                    tzId = tzIds.length ? tzIds[0].id : null;
                this.option("value", tzId);
                this._ianaIdEditor.option({
                    value: tzId,
                    items: this._idsDataSource(tzIds),
                    disabled: this._calculateIanaIdEditorDisabledState()
                })
            },
            _optionChanged: function(args) {
                var value = args.value;
                switch (args.name) {
                    case "value":
                        this._ianaIdEditor.option({
                            value: value,
                            items: this._idsDataSource()
                        });
                        if (value) {
                            this._displayNameEditor.option("value", this.invoke("getTimezoneDisplayNameById", value))
                        } else {
                            this._displayNameEditor.option("value", messageLocalization.format("dxScheduler-noTimezoneTitle"))
                        }
                        this.callBase(args);
                        break;
                    case "readOnly":
                        this._displayNameEditor && this._displayNameEditor.option("readOnly", value);
                        this._ianaIdEditor && this._ianaIdEditor.option("readOnly", value);
                        break;
                    default:
                        this.callBase(args)
                }
            }
        }).include(publisherMixin);
        registerComponent("dxSchedulerTimezoneEditor", {}, SchedulerTimezoneEditor);
        module.exports = SchedulerTimezoneEditor
    },
    /*!**********************************************!*\
      !*** ./Scripts/bundles/modules/parts/viz.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var DevExpress = __webpack_require__( /*! ./core */ 5);
        __webpack_require__( /*! ./data */ 180);
        var viz = DevExpress.viz = __webpack_require__( /*! ../../../bundles/modules/viz */ 440);
        viz.currentTheme = __webpack_require__( /*! ../../../viz/themes */ 441).currentTheme;
        viz.registerTheme = __webpack_require__( /*! ../../../viz/themes */ 441).registerTheme;
        viz.exportFromMarkup = __webpack_require__( /*! ../../../viz/export */ 443).exportFromMarkup;
        viz.currentPalette = __webpack_require__( /*! ../../../viz/palette */ 445).currentPalette;
        viz.getPalette = __webpack_require__( /*! ../../../viz/palette */ 445).getPalette;
        viz.registerPalette = __webpack_require__( /*! ../../../viz/palette */ 445).registerPalette;
        viz.dxChart = __webpack_require__( /*! ../../../viz/chart */ 446);
        viz.dxPieChart = __webpack_require__( /*! ../../../viz/pie_chart */ 518);
        viz.dxPolarChart = __webpack_require__( /*! ../../../viz/polar_chart */ 520);
        viz.dxLinearGauge = __webpack_require__( /*! ../../../viz/linear_gauge */ 522);
        viz.dxCircularGauge = __webpack_require__( /*! ../../../viz/circular_gauge */ 532);
        viz.dxBarGauge = __webpack_require__( /*! ../../../viz/bar_gauge */ 536);
        viz.dxRangeSelector = __webpack_require__( /*! ../../../viz/range_selector */ 538);
        viz.dxVectorMap = __webpack_require__( /*! ../../../viz/vector_map */ 548);
        viz.map = {};
        viz.map.sources = {};
        viz.map.projection = __webpack_require__( /*! ../../../viz/vector_map/projection */ 561).projection;
        viz.dxSparkline = __webpack_require__( /*! ../../../viz/sparkline */ 562);
        viz.dxBullet = __webpack_require__( /*! ../../../viz/bullet */ 565);
        viz.dxTreeMap = __webpack_require__( /*! ../../../viz/tree_map */ 567);
        var core = {};
        viz.core = core;
        core.currentTheme = __webpack_require__( /*! ../../../viz/themes */ 441).currentTheme;
        core.registerTheme = __webpack_require__( /*! ../../../viz/themes */ 441).registerTheme;
        core.currentPalette = __webpack_require__( /*! ../../../viz/palette */ 445).currentPalette;
        core.getPalette = __webpack_require__( /*! ../../../viz/palette */ 445).getPalette;
        core.registerPalette = __webpack_require__( /*! ../../../viz/palette */ 445).registerPalette;
        viz.BaseWidget = __webpack_require__( /*! ../../../viz/core/base_widget */ 448);
        viz.findTheme = __webpack_require__( /*! ../../../viz/themes */ 441).findTheme;
        viz.refreshAll = __webpack_require__( /*! ../../../viz/themes */ 441).refreshAll;
        viz.gauges = {
            __internals: {}
        };
        viz._dashboard = {};
        viz._dashboard.Renderer = __webpack_require__( /*! ../../../viz/core/renderers/renderer */ 451).Renderer;
        viz._dashboard.SvgElement = __webpack_require__( /*! ../../../viz/core/renderers/svg_renderer */ 453).SvgElement;
        viz._dashboard.isSvg = __webpack_require__( /*! ../../../viz/core/renderers/renderer */ 451).isSvg;
        viz._dashboard.patchFontOptions = __webpack_require__( /*! ../../../viz/core/utils */ 442).patchFontOptions;
        module.exports = viz
    },
    /*!****************************************!*\
      !*** ./Scripts/bundles/modules/viz.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        __webpack_require__( /*! ./core */ 6);
        module.exports = DevExpress.viz = DevExpress.viz || {}
    },
    /*!*******************************!*\
      !*** ./Scripts/viz/themes.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ./core/utils */ 442),
            themes = {},
            themesMapping = {},
            themesSchemeMapping = {},
            _extend = $.extend,
            _each = $.each,
            _normalizeEnum = vizUtils.normalizeEnum,
            currentThemeName = null,
            nextCacheUid = 0,
            widgetsCache = {};

        function findTheme(themeName) {
            var name = _normalizeEnum(themeName);
            return themes[name] || themes[themesMapping[name] || currentThemeName]
        }

        function findThemeNameByName(name, scheme) {
            return themesMapping[name + "." + scheme] || themesSchemeMapping[name + "." + scheme] || themesMapping[name]
        }

        function findThemeNameByPlatform(platform, version, scheme) {
            return findThemeNameByName(platform + version, scheme) || findThemeNameByName(platform, scheme)
        }

        function currentTheme(themeName, colorScheme) {
            if (!arguments.length) {
                return currentThemeName
            }
            var scheme = _normalizeEnum(colorScheme);
            currentThemeName = (themeName && themeName.platform ? findThemeNameByPlatform(_normalizeEnum(themeName.platform), themeName.version, scheme) : findThemeNameByName(_normalizeEnum(themeName), scheme)) || currentThemeName;
            return this
        }

        function getThemeInfo(themeName, splitter) {
            var k = themeName.indexOf(splitter);
            return k > 0 ? {
                name: themeName.substring(0, k),
                scheme: themeName.substring(k + 1)
            } : null
        }

        function registerThemeName(themeName, targetThemeName) {
            var themeInfo = getThemeInfo(themeName, ".") || getThemeInfo(themeName, "-") || {
                    name: themeName
                },
                name = themeInfo.name,
                scheme = themeInfo.scheme;
            if (scheme) {
                themesMapping[name] = themesMapping[name] || targetThemeName;
                themesMapping[name + "." + scheme] = themesMapping[name + "-" + scheme] = targetThemeName
            } else {
                themesMapping[name] = targetThemeName
            }
        }

        function registerTheme(theme, baseThemeName) {
            var themeName = _normalizeEnum(theme && theme.name);
            if (themeName) {
                registerThemeName(themeName, themeName);
                themes[themeName] = _extend(true, {}, findTheme(baseThemeName), patchTheme(theme))
            }
        }

        function registerThemeAlias(alias, theme) {
            registerThemeName(_normalizeEnum(alias), _normalizeEnum(theme))
        }

        function registerThemeSchemeAlias(from, to) {
            themesSchemeMapping[from] = to
        }

        function mergeScalar(target, field, source, sourceValue) {
            var _value = source ? source[field] : sourceValue;
            if (void 0 !== _value && void 0 === target[field]) {
                target[field] = _value
            }
        }

        function mergeObject(target, field, source, sourceValue) {
            var _value = source ? source[field] : sourceValue;
            if (void 0 !== _value) {
                target[field] = _extend(true, {}, _value, target[field])
            }
        }

        function patchTheme(theme) {
            theme = _extend(true, {
                loadingIndicator: {
                    font: {}
                },
                "export": {
                    font: {}
                },
                legend: {
                    font: {},
                    border: {}
                },
                title: {
                    font: {}
                },
                tooltip: {
                    font: {}
                },
                "chart:common": {},
                "chart:common:axis": {
                    grid: {},
                    minorGrid: {},
                    tick: {},
                    minorTick: {},
                    title: {
                        font: {}
                    },
                    label: {
                        font: {}
                    }
                },
                chart: {
                    commonSeriesSettings: {
                        candlestick: {}
                    }
                },
                pie: {},
                polar: {},
                gauge: {
                    scale: {
                        tick: {},
                        minorTick: {},
                        label: {
                            font: {}
                        }
                    }
                },
                barGauge: {},
                map: {
                    background: {}
                },
                treeMap: {
                    tile: {
                        selectionStyle: {
                            border: {}
                        }
                    },
                    group: {
                        border: {},
                        selectionStyle: {
                            border: {}
                        },
                        label: {
                            font: {}
                        }
                    }
                },
                rangeSelector: {
                    scale: {
                        tick: {},
                        minorTick: {},
                        label: {
                            font: {}
                        }
                    },
                    chart: {}
                },
                sparkline: {},
                bullet: {}
            }, theme);
            mergeScalar(theme.loadingIndicator, "backgroundColor", theme);
            mergeScalar(theme.chart.commonSeriesSettings.candlestick, "innerColor", null, theme.backgroundColor);
            mergeScalar(theme.map.background, "color", null, theme.backgroundColor);
            mergeScalar(theme.title.font, "color", null, theme.primaryTitleColor);
            mergeObject(theme.title, "subtitle", null, theme.title);
            mergeScalar(theme.legend.font, "color", null, theme.secondaryTitleColor);
            mergeScalar(theme.legend.border, "color", null, theme.axisColor);
            patchAxes(theme);
            _each(["chart", "pie", "polar", "gauge", "barGauge", "map", "treeMap", "rangeSelector", "sparkline", "bullet"], function(_, section) {
                mergeScalar(theme[section], "redrawOnResize", theme);
                mergeScalar(theme[section], "containerBackgroundColor", null, theme.backgroundColor);
                mergeObject(theme[section], "tooltip", theme)
            });
            _each(["chart", "pie", "polar", "gauge", "barGauge", "map", "treeMap", "rangeSelector"], function(_, section) {
                mergeObject(theme[section], "loadingIndicator", theme);
                mergeObject(theme[section], "export", theme);
                mergeObject(theme[section], "legend", theme);
                mergeObject(theme[section], "title", theme)
            });
            _each(["chart", "pie", "polar"], function(_, section) {
                mergeObject(theme, section, null, theme["chart:common"])
            });
            _each(["chart", "polar"], function(_, section) {
                theme[section] = theme[section] || {};
                mergeObject(theme[section], "commonAxisSettings", null, theme["chart:common:axis"])
            });
            mergeObject(theme.rangeSelector.chart, "commonSeriesSettings", theme.chart);
            mergeObject(theme.rangeSelector.chart, "dataPrepareSettings", theme.chart);
            mergeScalar(theme.treeMap.group.border, "color", null, theme.axisColor);
            mergeScalar(theme.treeMap.tile.selectionStyle.border, "color", null, theme.primaryTitleColor);
            mergeScalar(theme.treeMap.group.selectionStyle.border, "color", null, theme.primaryTitleColor);
            mergeScalar(theme.treeMap.group.label.font, "color", null, theme.secondaryTitleColor);
            mergeScalar(theme.map.legend, "backgroundColor", theme);
            patchMapLayers(theme);
            return theme
        }

        function patchAxes(theme) {
            var commonAxisSettings = theme["chart:common:axis"],
                colorFieldName = "color";
            _each([commonAxisSettings, commonAxisSettings.grid, commonAxisSettings.minorGrid, commonAxisSettings.tick, commonAxisSettings.minorTick], function(_, obj) {
                mergeScalar(obj, colorFieldName, null, theme.axisColor)
            });
            mergeScalar(commonAxisSettings.title.font, colorFieldName, null, theme.secondaryTitleColor);
            mergeScalar(commonAxisSettings.label.font, colorFieldName, null, theme.axisLabelColor);
            mergeScalar(theme.gauge.scale.label.font, colorFieldName, null, theme.axisLabelColor);
            mergeScalar(theme.gauge.scale.tick, colorFieldName, null, theme.backgroundColor);
            mergeScalar(theme.gauge.scale.minorTick, colorFieldName, null, theme.backgroundColor);
            mergeScalar(theme.rangeSelector.scale.tick, colorFieldName, null, theme.axisColor);
            mergeScalar(theme.rangeSelector.scale.minorTick, colorFieldName, null, theme.axisColor);
            mergeScalar(theme.rangeSelector.scale.label.font, colorFieldName, null, theme.axisLabelColor)
        }

        function patchMapLayers(theme) {
            var map = theme.map;
            _each(["area", "line", "marker"], function(_, section) {
                mergeObject(map, "layer:" + section, null, map.layer)
            });
            _each(["dot", "bubble", "pie", "image"], function(_, section) {
                mergeObject(map, "layer:marker:" + section, null, map["layer:marker"])
            })
        }

        function addCacheItem(target) {
            var cacheUid = ++nextCacheUid;
            target._cache = cacheUid;
            widgetsCache[cacheUid] = target
        }

        function removeCacheItem(target) {
            delete widgetsCache[target._cache]
        }

        function refreshAll() {
            _each(widgetsCache, function() {
                this.refresh()
            });
            return this
        }
        _extend(exports, {
            currentTheme: currentTheme,
            registerTheme: registerTheme,
            findTheme: findTheme,
            registerThemeAlias: registerThemeAlias,
            registerThemeSchemeAlias: registerThemeSchemeAlias,
            refreshAll: refreshAll,
            addCacheItem: addCacheItem,
            removeCacheItem: removeCacheItem
        });
        _extend(exports, {
            themes: themes,
            themesMapping: themesMapping,
            themesSchemeMapping: themesSchemeMapping,
            widgetsCache: widgetsCache,
            resetCurrentTheme: function() {
                currentThemeName = null
            }
        })
    },
    /*!***********************************!*\
      !*** ./Scripts/viz/core/utils.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _inArray = $.inArray,
            _each = $.each,
            _math = Math,
            _round = _math.round,
            _sqrt = Math.sqrt,
            _extend = $.extend;
        var PI = Math.PI,
            MAX_PIXEL_COUNT = 1e10,
            PI_DIV_180 = PI / 180,
            LN10 = Math.LN10;
        var cosFunc = Math.cos,
            sinFunc = Math.sin,
            abs = Math.abs,
            log = Math.log,
            floor = Math.floor,
            ceil = Math.ceil,
            max = Math.max,
            isNaN = window.isNaN,
            Number = window.Number,
            NaN = window.NaN;
        var isNumber = commonUtils.isNumber,
            isExponential = commonUtils.isExponential;
        var getPrecision = function(value) {
            var stringFraction, startIndex, precision, stringValue = value.toString(),
                pointIndex = stringValue.indexOf(".");
            if (isExponential(value)) {
                precision = getDecimalOrder(value);
                if (precision < 0) {
                    return Math.abs(precision)
                } else {
                    return 0
                }
            }
            if (pointIndex !== -1) {
                startIndex = pointIndex + 1;
                stringFraction = stringValue.substring(startIndex, startIndex + 20);
                return stringFraction.length
            }
            return 0
        };
        var getLog = function(value, base) {
            if (!value) {
                return NaN
            }
            return Math.log(value) / Math.log(base)
        };
        var raiseTo = function(power, base) {
            return Math.pow(base, power)
        };
        var normalizeAngle = function(angle) {
            return (angle % 360 + 360) % 360
        };
        var convertAngleToRendererSpace = function(angle) {
            return 90 - angle
        };
        var degreesToRadians = function(value) {
            return PI * value / 180
        };
        var getCosAndSin = function(angle) {
            var angleInRadians = degreesToRadians(angle);
            return {
                cos: cosFunc(angleInRadians),
                sin: sinFunc(angleInRadians)
            }
        };
        var DECIMAL_ORDER_THRESHOLD = 1e-14;
        var getDistance = function(x1, y1, x2, y2) {
            var diffX = x2 - x1,
                diffY = y2 - y1;
            return Math.sqrt(diffY * diffY + diffX * diffX)
        };
        var getDecimalOrder = function(number) {
            var cn, n = abs(number);
            if (!isNaN(n)) {
                if (n > 0) {
                    n = log(n) / LN10;
                    cn = ceil(n);
                    return cn - n < DECIMAL_ORDER_THRESHOLD ? cn : floor(n)
                }
                return 0
            }
            return NaN
        };
        var getAppropriateFormat = function(start, end, count) {
            var format, order = max(getDecimalOrder(start), getDecimalOrder(end)),
                precision = -getDecimalOrder(abs(end - start) / count);
            if (!isNaN(order) && !isNaN(precision)) {
                if (abs(order) <= 4) {
                    format = "fixedPoint";
                    precision < 0 && (precision = 0);
                    precision > 4 && (precision = 4)
                } else {
                    format = "exponential";
                    precision += order - 1;
                    precision > 3 && (precision = 3)
                }
                return {
                    type: format,
                    precision: precision
                }
            }
            return null
        };
        var getFraction = function(value) {
            var valueString, dotIndex;
            if (isNumber(value)) {
                valueString = value.toString();
                dotIndex = valueString.indexOf(".");
                if (dotIndex >= 0) {
                    if (isExponential(value)) {
                        return valueString.substr(dotIndex + 1, valueString.indexOf("e") - dotIndex - 1)
                    } else {
                        valueString = value.toFixed(20);
                        return valueString.substr(dotIndex + 1, valueString.length - dotIndex + 1)
                    }
                }
            }
            return ""
        };
        var getSignificantDigitPosition = function(value) {
            var i, fraction = getFraction(value);
            if (fraction) {
                for (i = 0; i < fraction.length; i++) {
                    if ("0" !== fraction.charAt(i)) {
                        return i + 1
                    }
                }
            }
            return 0
        };
        var adjustValue = function(value) {
            var nextValue, i, fraction = getFraction(value);
            if (fraction) {
                for (i = 1; i <= fraction.length; i++) {
                    nextValue = roundValue(value, i);
                    if (0 !== nextValue && fraction[i - 2] && fraction[i - 1] && fraction[i - 2] === fraction[i - 1]) {
                        return nextValue
                    }
                }
            }
            return value
        };
        var roundValue = function(value, precision) {
            if (precision > 20) {
                precision = 20
            }
            if (isNumber(value)) {
                if (isExponential(value)) {
                    return Number(value.toExponential(precision))
                } else {
                    return Number(value.toFixed(precision))
                }
            }
        };
        var applyPrecisionByMinDelta = function(min, delta, value) {
            var minPrecision = getPrecision(min),
                deltaPrecision = getPrecision(delta);
            return roundValue(value, minPrecision < deltaPrecision ? deltaPrecision : minPrecision)
        };
        var getPower = function(value) {
            return value.toExponential().split("e")[1]
        };

        function map(array, callback) {
            var value, i = 0,
                len = array.length,
                ret = [];
            while (i < len) {
                value = callback(array[i], i);
                if (null !== value) {
                    ret.push(value)
                }
                i++
            }
            return ret
        }

        function selectByKeys(object, keys) {
            return map(keys, function(key) {
                return object[key] ? object[key] : null
            })
        }

        function decreaseFields(object, keys, eachDecrease, decrease) {
            var dec = decrease;
            _each(keys, function(_, key) {
                if (object[key]) {
                    object[key] -= eachDecrease;
                    dec -= eachDecrease
                }
            });
            return dec
        }

        function normalizeEnum(value) {
            return String(value).toLowerCase()
        }

        function setCanvasValues(canvas) {
            if (canvas) {
                canvas.originalTop = canvas.top;
                canvas.originalBottom = canvas.bottom;
                canvas.originalLeft = canvas.left;
                canvas.originalRight = canvas.right
            }
        }

        function normalizeBBoxField(value) {
            return -MAX_PIXEL_COUNT < value && value < +MAX_PIXEL_COUNT ? value : 0
        }

        function normalizeBBox(bbox) {
            var rxl = normalizeBBoxField(floor(bbox.x)),
                ryt = normalizeBBoxField(floor(bbox.y)),
                rxr = normalizeBBoxField(ceil(bbox.width + bbox.x)),
                ryb = normalizeBBoxField(ceil(bbox.height + bbox.y)),
                result = {
                    x: rxl,
                    y: ryt,
                    width: rxr - rxl,
                    height: ryb - ryt
                };
            result.isEmpty = !result.x && !result.y && !result.width && !result.height;
            return result
        }

        function rotateBBox(bbox, center, angle) {
            var cos = Number(cosFunc(angle * PI_DIV_180).toFixed(3)),
                sin = Number(sinFunc(angle * PI_DIV_180).toFixed(3)),
                w2 = bbox.width / 2,
                h2 = bbox.height / 2,
                xc = bbox.x + w2,
                yc = bbox.y + h2,
                w2_ = abs(w2 * cos) + abs(h2 * sin),
                h2_ = abs(w2 * sin) + abs(h2 * cos),
                xc_ = center[0] + (xc - center[0]) * cos + (yc - center[1]) * sin,
                yc_ = center[1] - (xc - center[0]) * sin + (yc - center[1]) * cos;
            return normalizeBBox({
                x: xc_ - w2_,
                y: yc_ - h2_,
                width: 2 * w2_,
                height: 2 * h2_
            })
        }
        $.extend(exports, {
            decreaseGaps: function(object, keys, decrease) {
                var arrayGaps;
                do {
                    arrayGaps = selectByKeys(object, keys);
                    arrayGaps.push(_math.ceil(decrease / arrayGaps.length));
                    decrease = decreaseFields(object, keys, _math.min.apply(null, arrayGaps), decrease)
                } while (decrease > 0 && arrayGaps.length > 1);
                return decrease
            },
            normalizeEnum: normalizeEnum,
            parseScalar: function(value, defaultValue) {
                return void 0 !== value ? value : defaultValue
            },
            enumParser: function(values) {
                var i, ii, stored = {};
                for (i = 0, ii = values.length; i < ii; ++i) {
                    stored[normalizeEnum(values[i])] = 1
                }
                return function(value, defaultValue) {
                    var _value = normalizeEnum(value);
                    return stored[_value] ? _value : defaultValue
                }
            },
            patchFontOptions: function(options) {
                var fontOptions = {};
                _each(options || {}, function(key, value) {
                    if (/^(cursor|opacity)$/i.test(key)) {} else {
                        if ("color" === key) {
                            key = "fill"
                        } else {
                            key = "font-" + key
                        }
                    }
                    fontOptions[key] = value
                });
                return fontOptions
            },
            convertPolarToXY: function(centerCoords, startAngle, angle, radius) {
                var cossin, shiftAngle = 90;
                angle = _isDefined(angle) ? angle + startAngle - shiftAngle : 0;
                cossin = getCosAndSin(angle);
                return {
                    x: _round(centerCoords.x + radius * cossin.cos),
                    y: _round(centerCoords.y + radius * cossin.sin)
                }
            },
            convertXYToPolar: function(centerCoords, x, y) {
                var radius = getDistance(centerCoords.x, centerCoords.y, x, y),
                    angle = _math.atan2(y - centerCoords.y, x - centerCoords.x);
                return {
                    phi: _round(normalizeAngle(180 * angle / _math.PI)),
                    r: _round(radius)
                }
            },
            processSeriesTemplate: function(seriesTemplate, items) {
                var series, length, data, customizeSeries = commonUtils.isFunction(seriesTemplate.customizeSeries) ? seriesTemplate.customizeSeries : $.noop,
                    nameField = seriesTemplate.nameField || "series",
                    generatedSeries = {},
                    seriesOrder = [],
                    i = 0;
                for (length = items.length; i < length; i++) {
                    data = items[i];
                    if (nameField in data) {
                        series = generatedSeries[data[nameField]];
                        if (!series) {
                            series = generatedSeries[data[nameField]] = {
                                name: data[nameField],
                                data: []
                            };
                            seriesOrder.push(series.name)
                        }
                        series.data.push(data)
                    }
                }
                return map(seriesOrder, function(orderedName) {
                    var group = generatedSeries[orderedName];
                    return $.extend(group, customizeSeries.call(null, group.name))
                })
            },
            getCategoriesInfo: function(categories, startValue, endValue) {
                if (!(categories && categories.length > 0)) {
                    return {}
                }
                startValue = _isDefined(startValue) ? startValue : categories[0];
                endValue = _isDefined(endValue) ? endValue : categories[categories.length - 1];
                var visibleCategories, swapBuf, hasVisibleCategories, visibleCategoriesLen, categoriesValue = map(categories, function(category) {
                        return _isDefined(category) ? category.valueOf() : null
                    }),
                    indexStartValue = _isDefined(startValue) ? _inArray(startValue.valueOf(), categoriesValue) : 0,
                    indexEndValue = _isDefined(endValue) ? _inArray(endValue.valueOf(), categoriesValue) : categories.length - 1,
                    inverted = false;
                indexStartValue < 0 && (indexStartValue = 0);
                indexEndValue < 0 && (indexEndValue = categories.length - 1);
                if (indexEndValue < indexStartValue) {
                    swapBuf = indexEndValue;
                    indexEndValue = indexStartValue;
                    indexStartValue = swapBuf;
                    inverted = true
                }
                visibleCategories = categories.slice(indexStartValue, indexEndValue + 1);
                visibleCategoriesLen = visibleCategories.length;
                hasVisibleCategories = visibleCategoriesLen > 0;
                return {
                    categories: hasVisibleCategories ? visibleCategories : null,
                    start: hasVisibleCategories ? visibleCategories[inverted ? visibleCategoriesLen - 1 : 0] : null,
                    end: hasVisibleCategories ? visibleCategories[inverted ? 0 : visibleCategoriesLen - 1] : null,
                    inverted: inverted
                }
            },
            setCanvasValues: setCanvasValues,
            updatePanesCanvases: function(panes, canvas, rotated) {
                var weightSum = 0;
                _each(panes, function(_, pane) {
                    pane.weight = pane.weight || 1;
                    weightSum += pane.weight
                });
                var distributedSpace = 0,
                    padding = panes.padding || 10,
                    paneSpace = rotated ? canvas.width - canvas.left - canvas.right : canvas.height - canvas.top - canvas.bottom,
                    oneWeight = (paneSpace - padding * (panes.length - 1)) / weightSum,
                    startName = rotated ? "left" : "top",
                    endName = rotated ? "right" : "bottom";
                _each(panes, function(_, pane) {
                    var calcLength = _round(pane.weight * oneWeight);
                    pane.canvas = pane.canvas || {};
                    _extend(pane.canvas, {
                        deltaLeft: 0,
                        deltaRight: 0,
                        deltaTop: 0,
                        deltaBottom: 0
                    }, canvas);
                    pane.canvas[startName] = canvas[startName] + distributedSpace;
                    pane.canvas[endName] = canvas[endName] + (paneSpace - calcLength - distributedSpace);
                    distributedSpace = distributedSpace + calcLength + padding;
                    setCanvasValues(pane.canvas)
                })
            },
            unique: function(array) {
                var values = {};
                return map(array, function(item) {
                    var result = !values[item] ? item : null;
                    values[item] = true;
                    return result
                })
            },
            map: map,
            getVerticallyShiftedAngularCoords: function(bbox, dy, center) {
                var isPositive = bbox.x + bbox.width / 2 >= center.x,
                    dx1 = (isPositive ? bbox.x : bbox.x + bbox.width) - center.x,
                    dy1 = bbox.y - center.y,
                    dy2 = dy1 + dy,
                    dx2 = _round(_sqrt(dx1 * dx1 + dy1 * dy1 - dy2 * dy2)),
                    dx = (isPositive ? +dx2 : -dx2) || dx1;
                return {
                    x: center.x + (isPositive ? dx : dx - bbox.width),
                    y: bbox.y + dy
                }
            }
        });
        exports.getPrecision = getPrecision;
        exports.getLog = getLog;
        exports.raiseTo = raiseTo;
        exports.normalizeAngle = normalizeAngle;
        exports.convertAngleToRendererSpace = convertAngleToRendererSpace;
        exports.degreesToRadians = degreesToRadians;
        exports.getCosAndSin = getCosAndSin;
        exports.getDecimalOrder = getDecimalOrder;
        exports.getAppropriateFormat = getAppropriateFormat;
        exports.getDistance = getDistance;
        exports.getFraction = getFraction;
        exports.adjustValue = adjustValue;
        exports.roundValue = roundValue;
        exports.applyPrecisionByMinDelta = applyPrecisionByMinDelta;
        exports.getSignificantDigitPosition = getSignificantDigitPosition;
        exports.getPower = getPower;
        exports.rotateBBox = rotateBBox;
        exports.normalizeBBox = normalizeBBox
    },
    /*!*******************************!*\
      !*** ./Scripts/viz/export.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./core/export */ 444)
    },
    /*!************************************!*\
      !*** ./Scripts/viz/core/export.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _extend = $.extend,
            _each = $.each,
            clientExporter = __webpack_require__( /*! ../../client_exporter */ 7),
            messageLocalization = __webpack_require__( /*! ../../localization/message */ 80),
            config = __webpack_require__( /*! ../../core/config */ 15),
            imageExporter = clientExporter.image,
            svgExporter = clientExporter.svg,
            pdfExporter = clientExporter.pdf,
            hoverEvent = __webpack_require__( /*! ../../events/hover */ 102),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            pointerActions = [pointerEvents.down, pointerEvents.move].join(" "),
            BUTTON_SIZE = 35,
            ICON_COORDS = [
                [9, 12, 26, 12, 26, 14, 9, 14],
                [9, 17, 26, 17, 26, 19, 9, 19],
                [9, 22, 26, 22, 26, 24, 9, 24]
            ],
            LIST_PADDING_TOP = 4,
            LIST_WIDTH = 120,
            VERTICAL_TEXT_MARGIN = 8,
            HORIZONTAL_TEXT_MARGIN = 15,
            MENU_ITEM_HEIGHT = 30,
            LIST_STROKE_WIDTH = 1,
            MARGIN = 10,
            SHADOW_OFFSET = 2,
            SHADOW_BLUR = 3,
            ALLOWED_EXPORT_FORMATS = ["PNG", "PDF", "JPEG", "SVG", "GIF"],
            EXPORT_CSS_CLASS = "dx-export-menu",
            EXPORT_DATA_KEY = "export-element-type",
            FORMAT_DATA_KEY = "export-element-format";

        function validateFormat(format) {
            var validatedFormat = String(format).toUpperCase();
            if ($.inArray(validatedFormat, ALLOWED_EXPORT_FORMATS) !== -1) {
                return validatedFormat
            }
        }

        function getCreatorFunc(format) {
            if ("SVG" === format) {
                return svgExporter.getData
            } else {
                if ("PDF" === format) {
                    return pdfExporter.getData
                } else {
                    return imageExporter.getData
                }
            }
        }

        function print(data) {
            var vizWindow = window.open();
            if (!vizWindow) {
                return
            }
            vizWindow.document.open();
            vizWindow.document.write(data);
            vizWindow.document.close();
            vizWindow.print();
            vizWindow.close()
        }
        exports.exportFromMarkup = function(markup, options) {
            options.format = validateFormat(options.format) || "PNG";
            options.fileName = options.fileName || "file";
            clientExporter.export(markup, options, getCreatorFunc(options.format))
        };
        exports.ExportMenu = function(renderer, svgMethod) {
            var that = this;
            that._renderer = renderer;
            that._svgMethod = svgMethod;
            that._shadow = renderer.shadowFilter("-50%", "-50%", "200%", "200%", SHADOW_OFFSET, 6, SHADOW_BLUR);
            that._shadow.attr({
                opacity: .8
            });
            that._group = renderer.g().attr({
                "class": EXPORT_CSS_CLASS
            }).linkOn(renderer.root, {
                name: "export-menu",
                after: "peripheral"
            });
            that._buttonGroup = renderer.g().attr({
                "class": EXPORT_CSS_CLASS + "-button"
            }).append(that._group);
            that._listGroup = renderer.g().attr({
                "class": EXPORT_CSS_CLASS + "-list"
            }).append(that._group);
            that._subscribeEvents()
        };
        _extend(exports.ExportMenu.prototype, {
            getLayoutOptions: function() {
                var bbox = this._buttonGroup.getBBox();
                bbox.cutSide = "vertical";
                bbox.cutLayoutSide = "top";
                bbox.height += 2 * MARGIN;
                bbox.position = {
                    vertical: "top",
                    horizontal: "right"
                };
                bbox.verticalAlignment = "top";
                bbox.horizontalAlignment = "right";
                return bbox
            },
            probeDraw: $.noop,
            shift: function(_, y) {
                this._group.attr({
                    translateY: this._group.attr("translateY") + y
                })
            },
            draw: function(_, height, canvas) {
                this._options.exportOptions.width = canvas.width;
                this._options.exportOptions.height = canvas.height;
                this._group.move(canvas.width - BUTTON_SIZE - SHADOW_OFFSET - SHADOW_BLUR, height - BUTTON_SIZE - MARGIN)
            },
            show: function() {
                this._group.linkAppend()
            },
            hide: function() {
                this._group.linkRemove()
            },
            setOptions: function(options) {
                this._options = options;
                options.formats = options.formats || ALLOWED_EXPORT_FORMATS;
                options.printingEnabled = void 0 === options.printingEnabled ? true : options.printingEnabled;
                if (options.enabled && (options.formats.length || options.printingEnabled)) {
                    this.show();
                    this._updateButton();
                    this._updateList();
                    this._hideList()
                } else {
                    this.hide()
                }
            },
            dispose: function() {
                var that = this;
                that._unsubscribeEvents();
                that._group.linkRemove().linkOff();
                that._group.dispose();
                that._shadow.dispose();
                that._shadow = that._group = that._listGroup = that._buttonGroup = that._button = null;
                that._options = null
            },
            layoutOptions: function() {
                var options = this._options;
                return options.enabled && {
                    horizontalAlignment: "right",
                    verticalAlignment: "top",
                    weak: true
                }
            },
            measure: function() {
                return [BUTTON_SIZE + SHADOW_OFFSET, BUTTON_SIZE]
            },
            move: function(rect) {
                this._group.attr({
                    translateX: Math.round(rect[0]),
                    translateY: Math.round(rect[1])
                })
            },
            _hideList: function() {
                this._listGroup.remove();
                this._listShown = false;
                this._setButtonState("default")
            },
            _showList: function() {
                this._listGroup.append(this._group);
                this._listShown = true
            },
            _setButtonState: function(state) {
                var that = this,
                    style = that._options.button[state];
                this._button.attr({
                    stroke: style.borderColor,
                    fill: style.backgroundColor
                });
                this._icon.attr({
                    fill: style.color
                })
            },
            _subscribeEvents: function() {
                var that = this;
                that._renderer.root.on(pointerEvents.up + ".export", function(e) {
                    var exportOptions, elementType = e.target[EXPORT_DATA_KEY],
                        options = that._options;
                    if (!elementType) {
                        if (that._button) {
                            that._hideList()
                        }
                        return
                    }
                    if ("button" === elementType) {
                        if (that._listShown) {
                            that._setButtonState("default");
                            that._hideList()
                        } else {
                            that._setButtonState("focus");
                            that._showList()
                        }
                    } else {
                        if ("printing" === elementType) {
                            that.hide();
                            print(that._svgMethod());
                            that.show();
                            that._hideList()
                        } else {
                            if ("exporting" === elementType) {
                                that.hide();
                                exportOptions = _extend({}, options.exportOptions, {
                                    format: e.target[FORMAT_DATA_KEY],
                                    backgroundColor: options.backgroundColor
                                });
                                clientExporter.export(that._svgMethod(), exportOptions, getCreatorFunc(exportOptions.format));
                                that.show();
                                that._hideList()
                            }
                        }
                    }
                });
                that._listGroup.on(pointerActions, function(e) {
                    e.stopPropagation()
                });
                that._buttonGroup.on(pointerEvents.enter, function() {
                    that._setButtonState("hover")
                });
                that._buttonGroup.on(pointerEvents.leave, function() {
                    that._setButtonState(that._listShown ? "focus" : "default")
                });
                that._buttonGroup.on(pointerEvents.down + ".export", function(e) {
                    that._setButtonState("active")
                })
            },
            _unsubscribeEvents: function() {
                this._renderer.root.off(".export");
                this._listGroup.off();
                this._buttonGroup.off()
            },
            _updateButton: function() {
                var that = this,
                    renderer = that._renderer,
                    options = that._options,
                    iconAttr = {
                        fill: options.button.default.color,
                        cursor: "pointer"
                    },
                    exportData = {
                        "export-element-type": "button"
                    };
                if (!that._button) {
                    that._button = renderer.rect(0, 0, BUTTON_SIZE, BUTTON_SIZE).append(that._buttonGroup);
                    that._button.attr({
                        rx: 4,
                        ry: 4,
                        fill: options.button.default.backgroundColor,
                        stroke: options.button.default.borderColor,
                        "stroke-width": 1,
                        cursor: "pointer"
                    });
                    that._button.data(exportData);
                    that._icon = renderer.path(ICON_COORDS).append(that._buttonGroup);
                    that._icon.attr(iconAttr);
                    that._icon.data(exportData);
                    that._buttonGroup.setTitle(messageLocalization.format("vizExport-titleMenuText"))
                }
            },
            _getItemStyle: function(options) {
                var font = options.font,
                    style = {
                        rect: {
                            cursor: "pointer",
                            "pointer-events": "all"
                        },
                        text: {
                            "pointer-events": "none"
                        }
                    };
                style.text["font-size"] = font.size;
                style.text["font-family"] = font.family;
                style.text.fill = font.color;
                style.text["font-weight"] = font.weight;
                return style
            },
            _getItemAttributes: function(options, items) {
                var path, attr = {},
                    x = BUTTON_SIZE - LIST_WIDTH,
                    y = BUTTON_SIZE + LIST_PADDING_TOP + (items.length + 1) * MENU_ITEM_HEIGHT;
                attr.rect = {
                    width: LIST_WIDTH - 2 * LIST_STROKE_WIDTH,
                    height: MENU_ITEM_HEIGHT,
                    x: x + LIST_STROKE_WIDTH,
                    y: y - MENU_ITEM_HEIGHT
                };
                attr.text = config().rtlEnabled ? {
                    x: x + LIST_WIDTH - 2 * LIST_STROKE_WIDTH - HORIZONTAL_TEXT_MARGIN
                } : {
                    x: x + HORIZONTAL_TEXT_MARGIN
                };
                attr.text.y = y - VERTICAL_TEXT_MARGIN;
                if ("printing" === options.type) {
                    path = "M " + x + " " + (y - LIST_STROKE_WIDTH) + " L " + (x + LIST_WIDTH) + " " + (y - LIST_STROKE_WIDTH);
                    attr.separator = {
                        stroke: options.stroke,
                        "stroke-width": LIST_STROKE_WIDTH,
                        cursor: "pointer",
                        sharp: "v",
                        d: path
                    }
                }
                return attr
            },
            _addMenuItem: function(renderer, options, items) {
                var menuItem, that = this,
                    itemData = {},
                    hoverFill = options.hoverFill,
                    fill = options.fill,
                    type = options.type,
                    format = options.format,
                    style = that._getItemStyle(options),
                    attr = that._getItemAttributes(options, items);
                menuItem = renderer.g().attr({
                    "class": EXPORT_CSS_CLASS + "-list-item"
                });
                itemData[EXPORT_DATA_KEY] = type;
                if (format) {
                    itemData[FORMAT_DATA_KEY] = format
                }
                var rect = renderer.rect(),
                    text = renderer.text(options.text);
                rect.attr(attr.rect).css(style.rect).data(itemData);
                rect.on(hoverEvent.start + ".export", function(e) {
                    rect.attr({
                        fill: hoverFill
                    })
                }).on(hoverEvent.end + ".export", function(e) {
                    rect.attr({
                        fill: fill
                    })
                });
                rect.append(menuItem);
                text.css(style.text).attr(attr.text).append(menuItem);
                if ("printing" === type) {
                    renderer.path(null, "line").attr(attr.separator).append(menuItem)
                }
                items.push({
                    g: menuItem,
                    rect: rect
                })
            },
            _getMenuItems: function(options) {
                var that = this,
                    buttonDefault = options.button.default,
                    buttonHover = options.button.hover,
                    formats = options.formats,
                    renderer = that._renderer,
                    items = [];
                if (options.printingEnabled) {
                    that._addMenuItem(renderer, {
                        font: options.font,
                        type: "printing",
                        fill: buttonDefault.backgroundColor,
                        stroke: buttonDefault.borderColor,
                        hoverFill: buttonHover.backgroundColor,
                        text: messageLocalization.format("vizExport-printingButtonText")
                    }, items)
                }
                _each(formats, function(_, format) {
                    format = validateFormat(format);
                    if (format) {
                        that._addMenuItem(renderer, {
                            font: options.font,
                            fill: buttonDefault.backgroundColor,
                            stroke: buttonDefault.borderColor,
                            hoverFill: buttonHover.backgroundColor,
                            type: "exporting",
                            text: messageLocalization.getFormatter("vizExport-exportButtonText")(format),
                            format: format
                        }, items)
                    }
                });
                items && that._setСornerRadius(items);
                return items
            },
            _getMenuOverlay: function(options, items) {
                var rect, listHeight, that = this,
                    listPadding = BUTTON_SIZE + LIST_PADDING_TOP,
                    renderer = that._renderer,
                    xCoord = -LIST_WIDTH + BUTTON_SIZE;
                listHeight = items.length * MENU_ITEM_HEIGHT;
                rect = renderer.rect(xCoord, listPadding, LIST_WIDTH, listHeight);
                that._shadow.attr({
                    color: options.shadowColor
                });
                rect.attr({
                    fill: options.button.default.backgroundColor,
                    stroke: options.button.default.borderColor,
                    "stroke-width": LIST_STROKE_WIDTH,
                    cursor: "pointer",
                    rx: 4,
                    ry: 4,
                    filter: that._shadow.ref
                });
                rect.data({
                    "export-element-type": "list"
                });
                return rect
            },
            "_setСornerRadius": function(items) {
                var firstRect = items[0].rect,
                    lastRect = items[items.length - 1].rect;
                firstRect.attr({
                    y: parseInt(firstRect.attr("y")) + 2 * LIST_STROKE_WIDTH,
                    height: parseInt(firstRect.attr("height")) - 2 * LIST_STROKE_WIDTH
                });
                lastRect.attr({
                    height: parseInt(lastRect.attr("height")) - 2 * LIST_STROKE_WIDTH
                })
            },
            _updateList: function() {
                var that = this,
                    options = that._options,
                    listGroup = that._listGroup,
                    items = that._getMenuItems(options),
                    menuOverlay = that._getMenuOverlay(options, items);
                listGroup.clear();
                menuOverlay.append(listGroup);
                _each(items, function(_, item) {
                    item.g.append(listGroup)
                })
            }
        });

        function getExportOptions(widget, fileName, format, backgroundColor) {
            var validatedFormat = String(format).toUpperCase();
            if ($.inArray(validatedFormat, ["PNG", "PDF", "JPEG", "SVG", "GIF"]) === -1) {
                validatedFormat = "PNG"
            }
            return {
                format: validatedFormat,
                fileName: fileName || "file",
                proxyUrl: widget.option("export.proxyUrl"),
                width: widget._canvas.width,
                height: widget._canvas.height,
                exportingAction: widget._createActionByOption("onExporting"),
                exportedAction: widget._createActionByOption("onExported"),
                fileSavingAction: widget._createActionByOption("onFileSaving")
            }
        }
        exports.plugin = {
            name: "export",
            init: function() {
                var that = this;
                that._exportMenu = new exports.ExportMenu(that._renderer, function() {
                    return that.svg()
                });
                that._layout.add(that._exportMenu)
            },
            dispose: function() {
                this._exportMenu.dispose();
                this._exportMenu = null
            },
            members: {
                _getExportMenuOptions: function() {
                    var that = this,
                        userOptions = that._getOption("export") || {},
                        options = getExportOptions(that, userOptions.fileName, userOptions.format, userOptions.color);
                    return $.extend({}, userOptions, {
                        exportOptions: options
                    })
                },
                exportTo: function(fileName, format) {
                    var creatorFunc, exportOptions = getExportOptions(this, fileName, format),
                        exportMenu = this._exportMenu;
                    if ("SVG" === exportOptions.format) {
                        creatorFunc = clientExporter.svg.getData
                    } else {
                        if ("PDF" === exportOptions.format) {
                            creatorFunc = clientExporter.pdf.getData
                        } else {
                            creatorFunc = clientExporter.image.getData
                        }
                    }
                    exportMenu && exportMenu.hide();
                    clientExporter.export(this.svg(), exportOptions, creatorFunc);
                    exportMenu && exportMenu.show()
                },
                print: function() {
                    var vizWindow = window.open();
                    if (!vizWindow) {
                        return
                    }
                    vizWindow.document.open();
                    vizWindow.document.write(this.svg());
                    vizWindow.document.close();
                    vizWindow.print();
                    vizWindow.close()
                }
            },
            customize: function(constructor) {
                var proto = constructor.prototype;
                constructor.addChange({
                    code: "EXPORT",
                    handler: function() {
                        this._exportMenu.setOptions(this._getExportMenuOptions());
                        this._change(["LAYOUT"])
                    },
                    isThemeDependent: true,
                    isOptionChange: true,
                    option: "export"
                });
                proto._optionChangesMap.onExporting = "EXPORT";
                proto._optionChangesMap.onExported = "EXPORT";
                proto._optionChangesMap.onFileSaving = "EXPORT"
            }
        }
    },
    /*!********************************!*\
      !*** ./Scripts/viz/palette.js ***!
      \********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ./core/utils */ 442),
            _floor = Math.floor,
            _ceil = Math.ceil,
            _Color = __webpack_require__( /*! ../color */ 26),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            _isArray = commonUtils.isArray,
            _isString = commonUtils.isString,
            _extend = $.extend,
            _normalizeEnum = vizUtils.normalizeEnum,
            HIGHLIGHTING_STEP = 50,
            DEFAULT = "default",
            currentPaletteName = DEFAULT;
        var palettes = {
            "default": {
                simpleSet: ["#5f8b95", "#ba4d51", "#af8a53", "#955f71", "#859666", "#7e688c"],
                indicatingSet: ["#a3b97c", "#e1b676", "#ec7f83"],
                gradientSet: ["#5f8b95", "#ba4d51"]
            },
            "harmony light": {
                simpleSet: ["#fcb65e", "#679ec5", "#ad79ce", "#7abd5c", "#e18e92", "#b6d623", "#b7abea", "#85dbd5"],
                indicatingSet: ["#b6d623", "#fcb65e", "#e18e92"],
                gradientSet: ["#7abd5c", "#fcb65e"]
            },
            "soft pastel": {
                simpleSet: ["#60a69f", "#78b6d9", "#6682bb", "#a37182", "#eeba69", "#90ba58", "#456c68", "#7565a4"],
                indicatingSet: ["#90ba58", "#eeba69", "#a37182"],
                gradientSet: ["#78b6d9", "#eeba69"]
            },
            pastel: {
                simpleSet: ["#bb7862", "#70b3a1", "#bb626a", "#057d85", "#ab394b", "#dac599", "#153459", "#b1d2c6"],
                indicatingSet: ["#70b3a1", "#dac599", "#bb626a"],
                gradientSet: ["#bb7862", "#70b3a1"]
            },
            bright: {
                simpleSet: ["#70c92f", "#f8ca00", "#bd1550", "#e97f02", "#9d419c", "#7e4452", "#9ab57e", "#36a3a6"],
                indicatingSet: ["#70c92f", "#f8ca00", "#bd1550"],
                gradientSet: ["#e97f02", "#f8ca00"]
            },
            soft: {
                simpleSet: ["#cbc87b", "#9ab57e", "#e55253", "#7e4452", "#e8c267", "#565077", "#6babac", "#ad6082"],
                indicatingSet: ["#9ab57e", "#e8c267", "#e55253"],
                gradientSet: ["#9ab57e", "#e8c267"]
            },
            ocean: {
                simpleSet: ["#75c099", "#acc371", "#378a8a", "#5fa26a", "#064970", "#38c5d2", "#00a7c6", "#6f84bb"],
                indicatingSet: ["#c8e394", "#7bc59d", "#397c8b"],
                gradientSet: ["#acc371", "#38c5d2"]
            },
            vintage: {
                simpleSet: ["#dea484", "#efc59c", "#cb715e", "#eb9692", "#a85c4c", "#f2c0b5", "#c96374", "#dd956c"],
                indicatingSet: ["#ffe5c6", "#f4bb9d", "#e57660"],
                gradientSet: ["#efc59c", "#cb715e"]
            },
            violet: {
                simpleSet: ["#d1a1d1", "#eeacc5", "#7b5685", "#7e7cad", "#a13d73", "#5b41ab", "#e287e2", "#689cc1"],
                indicatingSet: ["#d8e2f6", "#d0b2da", "#d56a8a"],
                gradientSet: ["#eeacc5", "#7b5685"]
            }
        };

        function currentPalette(name) {
            if (void 0 === name) {
                return currentPaletteName
            } else {
                name = _normalizeEnum(name);
                currentPaletteName = name in palettes ? name : DEFAULT
            }
        }

        function getPalette(palette, parameters) {
            var result, type = parameters && parameters.type;
            if (_isArray(palette)) {
                return palette.slice(0)
            } else {
                if (_isString(palette)) {
                    result = palettes[_normalizeEnum(palette)]
                }
                if (!result) {
                    result = palettes[currentPaletteName]
                }
            }
            result = result || null;
            return type ? result ? result[type].slice(0) : result : result
        }

        function registerPalette(name, palette) {
            var paletteName, item = {};
            if (_isArray(palette)) {
                item.simpleSet = palette.slice(0)
            } else {
                if (palette) {
                    item.simpleSet = _isArray(palette.simpleSet) ? palette.simpleSet.slice(0) : void 0;
                    item.indicatingSet = _isArray(palette.indicatingSet) ? palette.indicatingSet.slice(0) : void 0;
                    item.gradientSet = _isArray(palette.gradientSet) ? palette.gradientSet.slice(0) : void 0
                }
            }
            if (item.simpleSet || item.indicatingSet || item.gradientSet) {
                paletteName = _normalizeEnum(name);
                _extend(palettes[paletteName] = palettes[paletteName] || {}, item)
            }
        }

        function RingBuf(buf) {
            var ind = 0;
            this.next = function() {
                var res = buf[ind++];
                if (ind === buf.length) {
                    this.reset()
                }
                return res
            };
            this.reset = function() {
                ind = 0
            }
        }

        function Palette(palette, parameters) {
            parameters = parameters || {};
            var stepHighlight = parameters.useHighlight ? HIGHLIGHTING_STEP : 0;
            this._originalPalette = getPalette(palette, {
                type: parameters.type || "simpleSet"
            });
            this._paletteSteps = new RingBuf([0, stepHighlight, -stepHighlight]);
            this._resetPalette()
        }
        Palette.prototype = {
            constructor: Palette,
            dispose: function() {
                this._originalPalette = this._palette = this._paletteSteps = null
            },
            getNextColor: function() {
                var that = this;
                if (that._currentColor >= that._palette.length) {
                    that._resetPalette()
                }
                return that._palette[that._currentColor++]
            },
            _resetPalette: function() {
                var that = this,
                    step = that._paletteSteps.next();
                that._palette = step ? getAlteredPalette(that._originalPalette, step) : that._originalPalette.slice(0);
                that._currentColor = 0
            },
            reset: function() {
                this._paletteSteps.reset();
                this._resetPalette();
                return this
            }
        };

        function getAlteredPalette(originalPalette, step) {
            var i, palette = [],
                ii = originalPalette.length;
            for (i = 0; i < ii; ++i) {
                palette.push(getNewColor(originalPalette[i], step))
            }
            return palette
        }

        function getNewColor(currentColor, step) {
            var newColor = new _Color(currentColor).alter(step),
                lightness = getLightness(newColor);
            if (lightness > 200 || lightness < 55) {
                newColor = new _Color(currentColor).alter(-step / 2)
            }
            return newColor.toHex()
        }

        function getLightness(color) {
            return .3 * color.r + .59 * color.g + .11 * color.b
        }

        function DiscretePalette(source, size) {
            var palette = size > 0 ? createDiscreteColors(getPalette(source, {
                type: "gradientSet"
            }), size) : [];
            this.getColor = function(index) {
                return palette[index] || null
            }
        }

        function createDiscreteColors(source, count) {
            var i, ncolors = count - 1,
                nsource = source.length - 1,
                colors = [],
                gradient = [];

            function addColor(pos) {
                var k = nsource * pos,
                    kl = _floor(k),
                    kr = _ceil(k);
                gradient.push(colors[kl].blend(colors[kr], k - kl).toHex())
            }
            for (i = 0; i <= nsource; ++i) {
                colors.push(new _Color(source[i]))
            }
            if (ncolors > 0) {
                for (i = 0; i <= ncolors; ++i) {
                    addColor(i / ncolors)
                }
            } else {
                addColor(.5)
            }
            return gradient
        }

        function GradientPalette(source) {
            var palette = getPalette(source, {
                    type: "gradientSet"
                }),
                color1 = new _Color(palette[0]),
                color2 = new _Color(palette[1]);
            this.getColor = function(ratio) {
                return 0 <= ratio && ratio <= 1 ? color1.blend(color2, ratio).toHex() : null
            }
        }
        _extend(exports, {
            Palette: Palette,
            DiscretePalette: DiscretePalette,
            GradientPalette: GradientPalette,
            registerPalette: registerPalette,
            getPalette: getPalette,
            currentPalette: currentPalette
        });
        exports._DEBUG_palettes = palettes
    },
    /*!******************************!*\
      !*** ./Scripts/viz/chart.js ***!
      \******************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            vizUtils = __webpack_require__( /*! ./core/utils */ 442),
            overlapping = __webpack_require__( /*! ./chart_components/base_chart */ 447).overlapping,
            translatorsModule = __webpack_require__( /*! ./translators/translator2d */ 497),
            rangeModule = __webpack_require__( /*! ./translators/range */ 503),
            LayoutManagerModule = __webpack_require__( /*! ./chart_components/layout_manager */ 490),
            multiAxesSynchronizer = __webpack_require__( /*! ./chart_components/multi_axes_synchronizer */ 504),
            AdvancedChart = __webpack_require__( /*! ./chart_components/advanced_chart */ 505).AdvancedChart,
            scrollBarModule = __webpack_require__( /*! ./chart_components/scroll_bar */ 516),
            crosshairModule = __webpack_require__( /*! ./chart_components/crosshair */ 517),
            MAX_ADJUSTMENT_ATTEMPTS = 5,
            DEFAULT_PANE_NAME = "default",
            DEFAULT_PANES = [{
                name: DEFAULT_PANE_NAME,
                border: {}
            }],
            _map = vizUtils.map,
            _each = $.each,
            _extend = $.extend,
            _isArray = commonUtils.isArray,
            _isDefined = commonUtils.isDefined;

        function getFirstAxisNameForPane(axes, paneName) {
            var result;
            for (var i = 0; i < axes.length; i++) {
                if (axes[i].pane === paneName) {
                    result = axes[i].name;
                    break
                }
            }
            if (!result) {
                result = axes[0].name
            }
            return result
        }

        function hideGridsOnNonFirstValueAxisForPane(valAxes, paneName, synchronizeMultiAxes) {
            var firstShownAxis, axesForPane = [];
            _each(valAxes, function(_, axis) {
                if (axis.pane === paneName) {
                    axesForPane.push(axis)
                }
            });
            if (axesForPane.length > 1 && synchronizeMultiAxes) {
                _each(axesForPane, function(_, axis) {
                    var gridOpt = axis.getOptions().grid,
                        minorGridOpt = axis.getOptions().minorGrid;
                    if (firstShownAxis && gridOpt && gridOpt.visible) {
                        gridOpt.visible = false;
                        minorGridOpt && (minorGridOpt.visible = false)
                    } else {
                        firstShownAxis = firstShownAxis ? firstShownAxis : gridOpt && gridOpt.visible
                    }
                })
            }
        }

        function getPaneForAxis(paneAxis, axisNameWithoutPane) {
            var result;
            _each(paneAxis, function(paneName, pane) {
                _each(pane, function(axisName) {
                    if (axisNameWithoutPane === axisName) {
                        result = paneName;
                        return false
                    }
                })
            });
            return result
        }

        function findAxisOptions(valueAxes, valueAxesOptions, axisName) {
            var result, axInd;
            for (axInd = 0; axInd < valueAxesOptions.length; axInd++) {
                if (valueAxesOptions[axInd].name === axisName) {
                    result = valueAxesOptions[axInd];
                    result.priority = axInd;
                    break
                }
            }
            if (!result) {
                for (axInd = 0; axInd < valueAxes.length; axInd++) {
                    if (valueAxes[axInd].name === axisName) {
                        result = valueAxes[axInd].getOptions();
                        result.priority = valueAxes[axInd].priority;
                        break
                    }
                }
            }
            return result
        }

        function findAxis(paneName, axisName, axes) {
            var axis, i;
            for (i = 0; i < axes.length; i++) {
                axis = axes[i];
                if (axis.name === axisName && axis.pane === paneName) {
                    return axis
                }
            }
        }

        function prepareSegmentRectPoints(left, top, width, height, borderOptions) {
            var maxSW = ~~((width < height ? width : height) / 2),
                sw = borderOptions.width || 0,
                newSW = sw < maxSW ? sw : maxSW;
            left += newSW / 2;
            top += newSW / 2;
            width -= newSW;
            height -= newSW;
            var segmentSequence, right = left + width,
                bottom = top + height,
                points = [],
                segments = [],
                visiblyOpt = 0,
                prevSegmentVisibility = 0;
            var allSegment = {
                top: [
                    [left, top],
                    [right, top]
                ],
                right: [
                    [right, top],
                    [right, bottom]
                ],
                bottom: [
                    [right, bottom],
                    [left, bottom]
                ],
                left: [
                    [left, bottom],
                    [left, top]
                ]
            };
            _each(allSegment, function(seg) {
                var visibility = !!borderOptions[seg];
                visiblyOpt = 2 * visiblyOpt + ~~visibility
            });
            switch (visiblyOpt) {
                case 13:
                case 9:
                    segmentSequence = ["left", "top", "right", "bottom"];
                    break;
                case 11:
                    segmentSequence = ["bottom", "left", "top", "right"];
                    break;
                default:
                    segmentSequence = ["top", "right", "bottom", "left"]
            }
            _each(segmentSequence, function(_, seg) {
                var segmentVisibility = !!borderOptions[seg];
                if (!prevSegmentVisibility && segments.length) {
                    points.push(segments);
                    segments = []
                }
                if (segmentVisibility) {
                    _each(allSegment[seg].slice(prevSegmentVisibility), function(_, segment) {
                        segments = segments.concat(segment)
                    })
                }
                prevSegmentVisibility = ~~segmentVisibility
            });
            segments.length && points.push(segments);
            1 === points.length && (points = points[0]);
            return {
                points: points,
                pathType: 15 === visiblyOpt ? "area" : "line"
            }
        }

        function applyClipSettings(clipRects, settings) {
            _each(clipRects || [], function(_, c) {
                c && c.attr(settings)
            })
        }

        function reinitTranslators(translators) {
            _each(translators, function(_, axisTrans) {
                _each(axisTrans, function(_, translator) {
                    translator.arg.reinit();
                    translator.val.reinit()
                })
            })
        }

        function compareAxes(a, b) {
            return a.priority - b.priority
        }

        function doesPaneExist(panes, paneName) {
            var found = false;
            _each(panes, function(_, pane) {
                if (pane.name === paneName) {
                    found = true;
                    return false
                }
            });
            return found
        }
        var dxChart = AdvancedChart.inherit({
            _chartType: "chart",
            _initCore: function() {
                this.paneAxis = {};
                this._panesClipRects = {};
                this.callBase()
            },
            _disposeCore: function() {
                var that = this,
                    disposeObjectsInArray = this._disposeObjectsInArray,
                    panesClipRects = that._panesClipRects;
                that.callBase();
                disposeObjectsInArray.call(panesClipRects, "fixed");
                disposeObjectsInArray.call(panesClipRects, "base");
                disposeObjectsInArray.call(panesClipRects, "wide");
                that._panesClipRects = null
            },
            _correctAxes: function() {
                this._correctValueAxes()
            },
            _getExtraOptions: $.noop,
            _processSingleSeries: $.noop,
            _groupSeries: function() {
                var that = this,
                    panes = that.panes,
                    valAxes = that._valueAxes,
                    paneList = _map(panes, function(pane) {
                        return pane.name
                    }),
                    series = that.series,
                    paneAxis = that.paneAxis,
                    synchronizeMultiAxes = that._themeManager.getOptions("synchronizeMultiAxes"),
                    groupedSeries = that._groupsData = {
                        groups: []
                    };
                _each(series, function(i, particularSeries) {
                    particularSeries.axis = particularSeries.axis || getFirstAxisNameForPane(valAxes, particularSeries.pane);
                    if (particularSeries.axis) {
                        paneAxis[particularSeries.pane] = paneAxis[particularSeries.pane] || {};
                        paneAxis[particularSeries.pane][particularSeries.axis] = true
                    }
                });
                _each(valAxes, function(_, axis) {
                    if (axis.name && axis.pane && $.inArray(axis.pane, paneList) !== -1) {
                        paneAxis[axis.pane] = paneAxis[axis.pane] || {};
                        paneAxis[axis.pane][axis.name] = true
                    }
                });
                that._correctValueAxes();
                _each(paneAxis, function(paneName, pane) {
                    hideGridsOnNonFirstValueAxisForPane(valAxes, paneName, synchronizeMultiAxes);
                    _each(pane, function(axisName) {
                        var group = {
                            series: []
                        };
                        _each(series, function(_, particularSeries) {
                            if (particularSeries.pane === paneName && particularSeries.axis === axisName) {
                                group.series.push(particularSeries)
                            }
                        });
                        groupedSeries.groups.push(group);
                        group.valueAxis = findAxis(paneName, axisName, valAxes);
                        group.valueOptions = group.valueAxis.getOptions()
                    })
                });
                groupedSeries.argumentAxes = that._argumentAxes;
                groupedSeries.argumentOptions = groupedSeries.argumentAxes[0].getOptions()
            },
            _cleanPanesClipRects: function(clipArrayName) {
                var that = this,
                    clipArray = that._panesClipRects[clipArrayName];
                _each(clipArray || [], function(_, clipRect) {
                    clipRect && clipRect.dispose()
                });
                that._panesClipRects[clipArrayName] = []
            },
            _createPanes: function() {
                var defaultPane, that = this,
                    panes = that.option("panes"),
                    panesNameCounter = 0;
                if (!panes || _isArray(panes) && !panes.length) {
                    panes = DEFAULT_PANES
                }
                that._cleanPanesClipRects("fixed");
                that._cleanPanesClipRects("base");
                that._cleanPanesClipRects("wide");
                defaultPane = that.option("defaultPane");
                panes = _extend(true, [], _isArray(panes) ? panes : [panes]);
                _each(panes, function(_, pane) {
                    pane.name = !_isDefined(pane.name) ? DEFAULT_PANE_NAME + panesNameCounter++ : pane.name
                });
                if (_isDefined(defaultPane)) {
                    if (!doesPaneExist(panes, defaultPane)) {
                        that._incidentOccurred("W2101", [defaultPane]);
                        defaultPane = panes[panes.length - 1].name
                    }
                } else {
                    defaultPane = panes[panes.length - 1].name
                }
                that.defaultPane = defaultPane;
                panes = that._isRotated() ? panes.reverse() : panes;
                return panes
            },
            _getAxisRenderingOptions: function() {
                return {
                    axisType: "xyAxes",
                    drawingType: "linear"
                }
            },
            _prepareAxisOptions: function(typeSelector, userOptions, rotated) {
                return {
                    isHorizontal: "argumentAxis" === typeSelector !== rotated
                }
            },
            _checkPaneName: function(seriesTheme) {
                var paneList = _map(this.panes, function(pane) {
                    return pane.name
                });
                seriesTheme.pane = seriesTheme.pane || this.defaultPane;
                return $.inArray(seriesTheme.pane, paneList) !== -1
            },
            _correctValueAxes: function() {
                var that = this,
                    rotated = that._isRotated(),
                    valueAxisOptions = that.option("valueAxis") || {},
                    valueAxesOptions = _isArray(valueAxisOptions) ? valueAxisOptions : [valueAxisOptions],
                    valueAxes = that._valueAxes || [],
                    defaultAxisName = valueAxes[0].name,
                    paneAxis = that.paneAxis,
                    neededAxis = {};
                _each(valueAxes, function(_, axis) {
                    var pane;
                    if (!axis.pane) {
                        pane = getPaneForAxis(paneAxis, axis.name);
                        if (!pane) {
                            pane = that.defaultPane;
                            (paneAxis[pane] = paneAxis[pane] || {})[axis.name] = true
                        }
                        axis.setPane(pane)
                    }
                });
                _each(that.panes, function(_, pane) {
                    var name = pane.name;
                    if (!paneAxis[name]) {
                        paneAxis[name] = {};
                        paneAxis[name][defaultAxisName] = true
                    }
                });
                _each(paneAxis, function(paneName, axisNames) {
                    _each(axisNames, function(axisName) {
                        var axisOptions;
                        neededAxis[axisName + "-" + paneName] = true;
                        if (!findAxis(paneName, axisName, valueAxes)) {
                            axisOptions = findAxisOptions(valueAxes, valueAxesOptions, axisName);
                            if (!axisOptions) {
                                that._incidentOccurred("W2102", [axisName]);
                                axisOptions = {
                                    name: axisName,
                                    priority: valueAxes.length
                                }
                            }
                            valueAxes.push(that._createAxis("valueAxis", axisOptions, {
                                pane: paneName,
                                name: axisName
                            }, rotated))
                        }
                    })
                });
                that._valueAxes = $.grep(valueAxes, function(elem) {
                    return !!neededAxis[elem.name + "-" + elem.pane]
                }).sort(compareAxes)
            },
            _getSeriesForPane: function(paneName) {
                var paneSeries = [];
                _each(this.series, function(_, oneSeries) {
                    if (oneSeries.pane === paneName) {
                        paneSeries.push(oneSeries)
                    }
                });
                return paneSeries
            },
            _createTranslator: function(range, canvas, options) {
                return new translatorsModule.Translator2D(range, canvas, options)
            },
            _createPanesBorderOptions: function() {
                var commonBorderOptions = this._themeManager.getOptions("commonPaneSettings").border,
                    panesBorderOptions = {};
                _each(this.panes, function(_, pane) {
                    panesBorderOptions[pane.name] = _extend(true, {}, commonBorderOptions, pane.border)
                });
                return panesBorderOptions
            },
            _createScrollBar: function() {
                var that = this,
                    scrollBarOptions = that._themeManager.getOptions("scrollBar") || {},
                    scrollBarGroup = that._scrollBarGroup;
                if (scrollBarOptions.visible) {
                    scrollBarOptions.rotated = that._isRotated();
                    that._scrollBar = (that._scrollBar || new scrollBarModule.ScrollBar(that._renderer, scrollBarGroup)).update(scrollBarOptions)
                } else {
                    scrollBarGroup.linkRemove();
                    that._scrollBar && that._scrollBar.dispose();
                    that._scrollBar = null
                }
            },
            _prepareToRender: function(drawOptions) {
                var that = this,
                    panesBorderOptions = that._createPanesBorderOptions(),
                    useAggregation = that._options.useAggregation;
                that._createPanesBackground();
                that._appendAxesGroups();
                that._transformed && that._resetTransform();
                that._createTranslators(drawOptions);
                if (useAggregation) {
                    _each(that.series, function(_, series) {
                        series.resamplePoints(that._getTranslator(series.pane, series.axis).arg, that._zoomMinArg, that._zoomMaxArg)
                    })
                }
                if (useAggregation || _isDefined(that._zoomMinArg) || _isDefined(that._zoomMaxArg)) {
                    that._populateBusinessRange({
                        adjustOnZoom: that._themeManager.getOptions("adjustOnZoom"),
                        minArg: that._zoomMinArg,
                        maxArg: that._zoomMaxArg,
                        notApplyMargins: that._notApplyMargins
                    });
                    that._updateTranslators()
                }
                return panesBorderOptions
            },
            _isLegendInside: function() {
                return this._legend && "inside" === this._legend.getPosition()
            },
            _renderAxes: function(drawOptions, panesBorderOptions, rotated, adjustUnits) {
                if (drawOptions && drawOptions.recreateCanvas) {
                    vizUtils.updatePanesCanvases(this.panes, this._canvas, rotated)
                }
                this._drawAxes(panesBorderOptions, drawOptions, adjustUnits)
            },
            _isRotated: function() {
                return this._themeManager.getOptions("rotated")
            },
            _getLayoutTargets: function() {
                return this.panes
            },
            _applyClipRects: function(panesBorderOptions) {
                var i, that = this,
                    canvasClipRectID = that._getCanvasClipRectID();
                that._drawPanesBorders(panesBorderOptions);
                that._createClipRectsForPanes();
                for (i = 0; i < that._argumentAxes.length; i++) {
                    that._argumentAxes[i].applyClipRects(that._getElementsClipRectID(that._argumentAxes[i].pane), canvasClipRectID)
                }
                for (i = 0; i < that._valueAxes.length; i++) {
                    that._valueAxes[i].applyClipRects(that._getElementsClipRectID(that._valueAxes[i].pane), canvasClipRectID)
                }
                that._fillPanesBackground()
            },
            _updateLegendPosition: function(drawOptions, legendHasInsidePosition) {
                var that = this;
                if (drawOptions.drawLegend && that._legend && legendHasInsidePosition) {
                    var panes = that.panes,
                        newCanvas = _extend({}, panes[0].canvas),
                        layoutManager = new LayoutManagerModule.LayoutManager;
                    newCanvas.right = panes[panes.length - 1].canvas.right;
                    newCanvas.bottom = panes[panes.length - 1].canvas.bottom;
                    layoutManager.setOptions({
                        width: 0,
                        height: 0
                    });
                    layoutManager.layoutElements([that._legend], newCanvas, $.noop, [{
                        canvas: newCanvas
                    }], void 0, {
                        horizontalAxes: [],
                        verticalAxes: []
                    })
                }
            },
            _prepareTranslators: function(series, _, rotated) {
                var tr = this._getTranslator(series.pane, series.axis),
                    translators = {};
                translators[rotated ? "x" : "y"] = tr.val;
                translators[rotated ? "y" : "x"] = tr.arg;
                return translators
            },
            _applyExtraSettings: function(series, drawOptions) {
                var that = this,
                    paneIndex = that._getPaneIndex(series.pane),
                    panesClipRects = that._panesClipRects,
                    wideClipRect = panesClipRects.wide[paneIndex];
                series.setClippingParams(panesClipRects.base[paneIndex].id, wideClipRect && wideClipRect.id, that._getPaneBorderVisibility(paneIndex))
            },
            _createTranslators: function(drawOptions) {
                var translators, that = this,
                    rotated = that._isRotated();
                if (!drawOptions.recreateCanvas) {
                    return
                }
                that.translators = translators = {};
                vizUtils.updatePanesCanvases(that.panes, that._canvas, rotated);
                _each(that.paneAxis, function(paneName, pane) {
                    translators[paneName] = translators[paneName] || {};
                    _each(pane, function(axisName) {
                        var translator = that._createTranslator(new rangeModule.Range(that._getBusinessRange(paneName, axisName).val), that._getCanvasForPane(paneName), {
                            isHorizontal: !!rotated
                        });
                        translator.pane = paneName;
                        translator.axis = axisName;
                        translators[paneName][axisName] = {
                            val: translator
                        }
                    })
                });
                _each(that._argumentAxes, function(_, axis) {
                    var translator = that._createTranslator(new rangeModule.Range(that._getBusinessRange(axis.pane).arg), that._getCanvasForPane(axis.pane), {
                        isHorizontal: !rotated
                    });
                    _each(translators[axis.pane], function(valAxis, paneAxisTran) {
                        paneAxisTran.arg = translator
                    })
                })
            },
            _updateTranslators: function() {
                var that = this;
                _each(that.translators, function(pane, axisTrans) {
                    _each(axisTrans, function(axis, translator) {
                        translator.arg.updateBusinessRange(new rangeModule.Range(that._getBusinessRange(pane).arg));
                        delete translator.arg._originalBusinessRange;
                        translator.val.updateBusinessRange(new rangeModule.Range(that._getBusinessRange(pane, axis).val));
                        delete translator.val._originalBusinessRange
                    })
                })
            },
            _getAxesForTransform: function(rotated) {
                return {
                    verticalAxes: !rotated ? this._getValueAxes() : this._getArgumentAxes(),
                    horizontalAxes: !rotated ? this._getArgumentAxes() : this._getValueAxes()
                }
            },
            _getAxisDrawingMethods: function(drawOptions, preparedOptions, isRotated) {
                var that = this;
                return function(adjustUnits) {
                    that._renderAxes(drawOptions, preparedOptions, isRotated, adjustUnits)
                }
            },
            _reinitTranslators: function() {
                var that = this;
                _each(that._argumentAxes, function(_, axis) {
                    var translator = that._getTranslator(axis.pane);
                    if (translator) {
                        translator.arg.reinit();
                        axis.setTranslator(translator.arg, translator.val)
                    }
                });
                _each(that._valueAxes, function(_, axis) {
                    var translator = that._getTranslator(axis.pane, axis.name);
                    if (translator) {
                        translator.val.reinit();
                        axis.setTranslator(translator.val, translator.arg)
                    }
                })
            },
            _saveBusinessRange: function() {
                var savedBusinessRange = this._savedBusinessRange;
                $.each(this.translators, function(name, pane) {
                    savedBusinessRange[name] = {};
                    $.each(pane, function(axisName, translator) {
                        savedBusinessRange[name][axisName] = {};
                        savedBusinessRange[name][axisName].arg = $.extend(true, {}, translator.arg.getBusinessRange());
                        savedBusinessRange[name][axisName].val = $.extend(true, {}, translator.val.getBusinessRange())
                    })
                })
            },
            _restoreOriginalBusinessRange: function() {
                var savedBusinessRange = this._savedBusinessRange;
                $.each(this.translators, function(name, pane) {
                    $.each(pane, function(axisName, translator) {
                        translator.arg.updateBusinessRange($.extend(true, {}, savedBusinessRange[name][axisName].arg));
                        translator.val.updateBusinessRange($.extend(true, {}, savedBusinessRange[name][axisName].val))
                    })
                })
            },
            _prepareAxesAndDraw: function(drawAxes, drawStaticAxisElements, drawOptions) {
                var that = this,
                    i = 0,
                    layoutManager = that.layoutManager,
                    rotated = that._isRotated(),
                    adjustmentCounter = 0,
                    synchronizeMultiAxes = that._themeManager.getOptions("synchronizeMultiAxes"),
                    layoutTargets = that._getLayoutTargets(),
                    verticalAxes = rotated ? that._argumentAxes : that._valueAxes,
                    horizontalAxes = rotated ? that._valueAxes : that._argumentAxes,
                    hElements = horizontalAxes,
                    vElements = verticalAxes;
                if (that._scrollBar) {
                    that._scrollBar.setPane(layoutTargets);
                    if (rotated) {
                        vElements = [that._scrollBar].concat(vElements)
                    } else {
                        hElements = hElements.concat([that._scrollBar])
                    }
                }
                do {
                    for (i = 0; i < that._argumentAxes.length; i++) {
                        that._argumentAxes[i].resetTicks()
                    }
                    for (i = 0; i < that._valueAxes.length; i++) {
                        that._valueAxes[i].resetTicks()
                    }
                    if (synchronizeMultiAxes) {
                        multiAxesSynchronizer.synchronize(that._valueAxes)
                    }
                    drawAxes(horizontalAxes);
                    layoutManager.requireAxesRedraw = false;
                    if (drawOptions.adjustAxes) {
                        layoutManager.applyHorizontalAxesLayout(hElements, layoutTargets, rotated);
                        !layoutManager.stopDrawAxes && reinitTranslators(that.translators)
                    }
                    drawAxes(verticalAxes);
                    if (drawOptions.adjustAxes && !layoutManager.stopDrawAxes) {
                        layoutManager.applyVerticalAxesLayout(vElements, layoutTargets, rotated);
                        !layoutManager.stopDrawAxes && reinitTranslators(that.translators)
                    }
                    adjustmentCounter += 1
                } while (!layoutManager.stopDrawAxes && layoutManager.requireAxesRedraw && adjustmentCounter < MAX_ADJUSTMENT_ATTEMPTS);
                drawStaticAxisElements(verticalAxes);
                drawStaticAxisElements(horizontalAxes);
                that._scrollBar && that._scrollBar.applyLayout();
                that.__axisAdjustmentsCount = adjustmentCounter
            },
            _getPanesParameters: function() {
                var i, that = this,
                    panes = that.panes,
                    params = [];
                for (i = 0; i < panes.length; i++) {
                    if (that._getPaneBorderVisibility(i)) {
                        params.push({
                            coords: panes[i].borderCoords,
                            clipRect: that._panesClipRects.fixed[i]
                        })
                    }
                }
                return params
            },
            _createCrosshairCursor: function() {
                var that = this,
                    options = that._themeManager.getOptions("crosshair") || {},
                    index = that._displayedArgumentAxisIndex,
                    axes = !that._isRotated() ? [
                        [that._argumentAxes[index]], that._valueAxes
                    ] : [that._valueAxes, [that._argumentAxes[index]]],
                    parameters = {
                        canvas: that._getCommonCanvas(),
                        panes: that._getPanesParameters(),
                        axes: axes
                    };
                if (!options || !options.enabled) {
                    return
                }
                if (!that._crosshair) {
                    that._crosshair = new crosshairModule.Crosshair(that._renderer, options, parameters, that._crosshairCursorGroup)
                } else {
                    that._crosshair.update(options, parameters)
                }
                that._crosshair.render()
            },
            _getCommonCanvas: function() {
                var i, canvas, commonCanvas, panes = this.panes;
                for (i = 0; i < panes.length; i++) {
                    canvas = panes[i].canvas;
                    if (!commonCanvas) {
                        commonCanvas = _extend({}, canvas)
                    } else {
                        commonCanvas.right = canvas.right;
                        commonCanvas.bottom = canvas.bottom
                    }
                }
                return commonCanvas
            },
            _createPanesBackground: function() {
                var backgroundColor, rect, i, that = this,
                    defaultBackgroundColor = that._themeManager.getOptions("commonPaneSettings").backgroundColor,
                    renderer = that._renderer,
                    rects = [];
                that._panesBackgroundGroup.clear();
                for (i = 0; i < that.panes.length; i++) {
                    backgroundColor = that.panes[i].backgroundColor || defaultBackgroundColor;
                    if (!backgroundColor || "none" === backgroundColor) {
                        rects.push(null);
                        continue
                    }
                    rect = renderer.rect(0, 0, 0, 0).attr({
                        fill: backgroundColor,
                        "stroke-width": 0
                    }).append(that._panesBackgroundGroup);
                    rects.push(rect)
                }
                that.panesBackground = rects
            },
            _fillPanesBackground: function() {
                var bc, that = this;
                _each(that.panes, function(i, pane) {
                    bc = pane.borderCoords;
                    if (null !== that.panesBackground[i]) {
                        that.panesBackground[i].attr({
                            x: bc.left,
                            y: bc.top,
                            width: bc.width,
                            height: bc.height
                        })
                    }
                })
            },
            _calcPaneBorderCoords: function(pane) {
                var canvas = pane.canvas,
                    bc = pane.borderCoords = pane.borderCoords || {};
                bc.left = canvas.left;
                bc.top = canvas.top;
                bc.right = canvas.width - canvas.right;
                bc.bottom = canvas.height - canvas.bottom;
                bc.width = Math.max(bc.right - bc.left, 0);
                bc.height = Math.max(bc.bottom - bc.top, 0)
            },
            _drawPanesBorders: function(panesBorderOptions) {
                var that = this,
                    rotated = that._isRotated();
                that._panesBorderGroup.linkRemove().clear();
                _each(that.panes, function(i, pane) {
                    var bc, segmentRectParams, borderOptions = panesBorderOptions[pane.name],
                        attr = {
                            fill: "none",
                            stroke: borderOptions.color,
                            "stroke-opacity": borderOptions.opacity,
                            "stroke-width": borderOptions.width,
                            dashStyle: borderOptions.dashStyle,
                            "stroke-linecap": "square"
                        };
                    that._calcPaneBorderCoords(pane, rotated);
                    if (!borderOptions.visible) {
                        return
                    }
                    bc = pane.borderCoords;
                    segmentRectParams = prepareSegmentRectPoints(bc.left, bc.top, bc.width, bc.height, borderOptions);
                    that._renderer.path(segmentRectParams.points, segmentRectParams.pathType).attr(attr).append(that._panesBorderGroup)
                });
                that._panesBorderGroup.linkAppend()
            },
            _createClipRect: function(clipArray, index, left, top, width, height) {
                var that = this,
                    clipRect = clipArray[index];
                if (!clipRect) {
                    clipRect = that._renderer.clipRect(left, top, width, height);
                    clipArray[index] = clipRect
                } else {
                    clipRect.attr({
                        x: left,
                        y: top,
                        width: width,
                        height: height
                    })
                }
            },
            _createClipRectsForPanes: function() {
                var that = this,
                    canvas = that._canvas;
                _each(that.panes, function(i, pane) {
                    var needWideClipRect = false,
                        bc = pane.borderCoords,
                        left = bc.left,
                        top = bc.top,
                        width = bc.width,
                        height = bc.height,
                        panesClipRects = that._panesClipRects;
                    that._createClipRect(panesClipRects.fixed, i, left, top, width, height);
                    that._createClipRect(panesClipRects.base, i, left, top, width, height);
                    _each(that.series, function(_, series) {
                        if (series.pane === pane.name && (series.isFinancialSeries() || series.areErrorBarsVisible())) {
                            needWideClipRect = true
                        }
                    });
                    if (needWideClipRect) {
                        if (that._isRotated()) {
                            top = 0;
                            height = canvas.height
                        } else {
                            left = 0;
                            width = canvas.width
                        }
                        that._createClipRect(panesClipRects.wide, i, left, top, width, height)
                    } else {
                        panesClipRects.wide.push(null)
                    }
                })
            },
            _getPaneIndex: function(paneName) {
                var paneIndex;
                _each(this.panes, function(index, pane) {
                    if (pane.name === paneName) {
                        paneIndex = index;
                        return false
                    }
                });
                return paneIndex
            },
            _getPaneBorderVisibility: function(paneIndex) {
                var commonPaneBorderVisible = this._themeManager.getOptions("commonPaneSettings").border.visible,
                    pane = this.panes[paneIndex] || {},
                    paneBorder = pane.border || {};
                return "visible" in paneBorder ? paneBorder.visible : commonPaneBorderVisible
            },
            _getElementsClipRectID: function(paneName) {
                return this._panesClipRects.fixed[this._getPaneIndex(paneName)].id
            },
            _getTranslator: function(paneName, axisName) {
                var paneTrans = this.translators[paneName],
                    foundTranslator = null;
                if (!paneTrans) {
                    return foundTranslator
                }
                foundTranslator = paneTrans[axisName];
                if (!foundTranslator) {
                    _each(paneTrans, function(axis, trans) {
                        foundTranslator = trans;
                        return false
                    });
                    foundTranslator = _extend({
                        axesTrans: paneTrans
                    }, foundTranslator)
                }
                return foundTranslator
            },
            _getCanvasForPane: function(paneName) {
                var i, panes = this.panes,
                    panesNumber = panes.length;
                for (i = 0; i < panesNumber; i++) {
                    if (panes[i].name === paneName) {
                        return panes[i].canvas
                    }
                }
            },
            _getBusinessRange: function(paneName, axisName) {
                var foundRange, i, ranges = this.businessRanges || [],
                    rangesNumber = ranges.length;
                for (i = 0; i < rangesNumber; i++) {
                    if (ranges[i].val.pane === paneName && ranges[i].val.axis === axisName) {
                        foundRange = ranges[i];
                        break
                    }
                }
                if (!foundRange) {
                    for (i = 0; i < rangesNumber; i++) {
                        if (ranges[i].val.pane === paneName) {
                            foundRange = ranges[i];
                            break
                        }
                    }
                }
                return foundRange
            },
            _transformArgument: function(translate, scale) {
                var settings, clipSettings, that = this,
                    rotated = that._isRotated(),
                    panesClipRects = that._panesClipRects;
                if (!that._transformed) {
                    that._transformed = true;
                    that._labelsGroup.remove();
                    that._resetIsReady();
                    _each(that.series || [], function(i, s) {
                        s.applyClip()
                    })
                }
                if (rotated) {
                    settings = {
                        translateY: translate,
                        scaleY: scale
                    };
                    clipSettings = {
                        translateY: -translate / scale,
                        scaleY: 1 / scale
                    }
                } else {
                    settings = {
                        translateX: translate,
                        scaleX: scale
                    };
                    clipSettings = {
                        translateX: -translate / scale,
                        scaleX: 1 / scale
                    }
                }
                applyClipSettings(panesClipRects.base, clipSettings);
                applyClipSettings(panesClipRects.wide, clipSettings);
                that._seriesGroup.attr(settings);
                that._scrollBar && that._scrollBar.transform(-translate, scale)
            },
            _resetTransform: function() {
                var that = this,
                    settings = {
                        translateX: 0,
                        translateY: 0,
                        scaleX: null,
                        scaleY: null
                    },
                    panesClipRects = that._panesClipRects;
                applyClipSettings(panesClipRects.base, settings);
                applyClipSettings(panesClipRects.wide, settings);
                that._seriesGroup.attr(settings);
                _each(that.series || [], function(i, s) {
                    s.resetClip()
                });
                that._transformed = false
            },
            _getTrackerSettings: function() {
                var that = this,
                    themeManager = that._themeManager;
                return _extend(this.callBase(), {
                    chart: that,
                    zoomingMode: themeManager.getOptions("zoomingMode"),
                    scrollingMode: themeManager.getOptions("scrollingMode"),
                    rotated: that._isRotated(),
                    crosshair: that._getCrosshairOptions().enabled ? that._crosshair : null
                })
            },
            _resolveLabelOverlappingStack: function() {
                var that = this,
                    isRotated = that._isRotated(),
                    shiftDirection = isRotated ? function(box, length) {
                        return {
                            x: box.x - length,
                            y: box.y
                        }
                    } : function(box, length) {
                        return {
                            x: box.x,
                            y: box.y - length
                        }
                    };
                _each(that._getStackPoints(), function(_, stacks) {
                    _each(stacks, function(_, points) {
                        overlapping.resolveLabelOverlappingInOneDirection(points, that._getCommonCanvas(), isRotated, shiftDirection)
                    })
                })
            },
            _getStackPoints: function() {
                var stackPoints = {},
                    visibleSeries = this._getVisibleSeries();
                _each(visibleSeries, function(_, singleSeries) {
                    var points = singleSeries.getPoints(),
                        stackName = singleSeries.getStackName() || null;
                    _each(points, function(_, point) {
                        var argument = point.argument;
                        if (!stackPoints[argument]) {
                            stackPoints[argument] = {}
                        }
                        if (!stackPoints[argument][stackName]) {
                            stackPoints[argument][stackName] = []
                        }
                        stackPoints[argument][stackName].push(point)
                    })
                });
                return stackPoints
            },
            _getCrosshairOptions: function() {
                return this._getOption("crosshair")
            },
            zoomArgument: function(min, max, gesturesUsed) {
                var bounds, zoomArg, that = this;
                if (!_isDefined(min) && !_isDefined(max)) {
                    return
                }
                if (!gesturesUsed) {
                    that._eventTrigger("zoomStart")
                }
                zoomArg = that._argumentAxes[0].zoom(min, max, gesturesUsed);
                that._zoomMinArg = zoomArg.min;
                that._zoomMaxArg = zoomArg.max;
                that._notApplyMargins = gesturesUsed;
                that._doRender({
                    force: true,
                    drawTitle: false,
                    drawLegend: false,
                    adjustAxes: false,
                    animate: false
                });
                bounds = that.getVisibleArgumentBounds();
                that._eventTrigger("zoomEnd", {
                    rangeStart: bounds.minVisible,
                    rangeEnd: bounds.maxVisible
                })
            },
            _resetZoom: function() {
                var that = this;
                that._zoomMinArg = that._zoomMaxArg = void 0;
                that._argumentAxes[0] && that._argumentAxes[0].resetZoom()
            },
            getVisibleArgumentBounds: function() {
                var range = this._argumentAxes[0].getTranslator().getBusinessRange(),
                    isDiscrete = "discrete" === range.axisType,
                    categories = range.categories;
                return {
                    minVisible: isDiscrete ? range.minVisible || categories[0] : range.minVisible,
                    maxVisible: isDiscrete ? range.maxVisible || categories[categories.length - 1] : range.maxVisible
                }
            }
        });
        registerComponent("dxChart", dxChart);
        module.exports = dxChart;
        module.exports._test_prepareSegmentRectPoints = function() {
            var original = prepareSegmentRectPoints.original || prepareSegmentRectPoints;
            if (arguments[0]) {
                prepareSegmentRectPoints = arguments[0]
            }
            prepareSegmentRectPoints.original = original;
            prepareSegmentRectPoints.restore = function() {
                prepareSegmentRectPoints = original
            };
            return prepareSegmentRectPoints
        }
    },
    /*!****************************************************!*\
      !*** ./Scripts/viz/chart_components/base_chart.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            BaseWidget = __webpack_require__( /*! ../core/base_widget */ 448),
            legendModule = __webpack_require__( /*! ../components/legend */ 456),
            dataValidatorModule = __webpack_require__( /*! ../components/data_validator */ 458),
            seriesModule = __webpack_require__( /*! ../series/base_series */ 460),
            chartThemeManagerModule = __webpack_require__( /*! ../components/chart_theme_manager */ 484),
            LayoutManagerModule = __webpack_require__( /*! ./layout_manager */ 490),
            trackerModule = __webpack_require__( /*! ./tracker */ 491),
            headerBlockModule = __webpack_require__( /*! ./header_block */ 492),
            REINIT_REFRESH_ACTION = "_reinit",
            REINIT_DATA_SOURCE_REFRESH_ACTION = "_updateDataSource",
            DATA_INIT_REFRESH_ACTION = "_dataInit",
            FORCE_RENDER_REFRESH_ACTION = "_forceRender",
            RESIZE_REFRESH_ACTION = "_resize",
            ACTIONS_BY_PRIORITY = [REINIT_REFRESH_ACTION, REINIT_DATA_SOURCE_REFRESH_ACTION, DATA_INIT_REFRESH_ACTION, FORCE_RENDER_REFRESH_ACTION, RESIZE_REFRESH_ACTION],
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _noop = $.noop,
            _map = vizUtils.map,
            _each = $.each,
            _extend = $.extend,
            _isArray = commonUtils.isArray,
            _isDefined = commonUtils.isDefined,
            _setCanvasValues = vizUtils.setCanvasValues,
            DEFAULT_OPACITY = .3,
            REINIT_REFRESH_ACTION_OPTIONS = ["adaptiveLayout", "crosshair", "equalBarWidth", "minBubbleSize", "maxBubbleSize", "barWidth", "negativesAsZeroes", "negativesAsZeros", "resolveLabelOverlapping", "seriesSelectionMode", "pointSelectionMode", "adjustOnZoom", "synchronizeMultiAxes", "zoomingMode", "scrollingMode", "useAggregation"];

        function checkHeightLabelsInCanvas(points, canvas, isRotated) {
            var label, bbox, commonLabelSize = 0,
                canvasSize = canvas.end - canvas.start;
            for (var i = 0; i < points.length; i++) {
                label = points[i].getLabel();
                if (label.isVisible()) {
                    bbox = label.getBoundingRect();
                    commonLabelSize += isRotated ? bbox.width : bbox.height
                } else {
                    points[i] = null
                }
            }
            if (canvasSize > 0) {
                while (commonLabelSize > canvasSize) {
                    commonLabelSize -= killSmallValues(points, isRotated)
                }
            }
        }

        function killSmallValues(points, isRotated) {
            var label, bbox, indexOfPoint, smallestValuePoint = {
                originalValue: 1 / 0
            };
            _each(points, function(index, point) {
                if (point && smallestValuePoint.originalValue >= point.originalValue) {
                    smallestValuePoint = point;
                    indexOfPoint = index
                }
            });
            if (null !== indexOfPoint) {
                label = points[indexOfPoint].getLabel();
                bbox = label.getBoundingRect();
                label.hide();
                points[indexOfPoint] = null;
                return isRotated ? bbox.width : bbox.height
            }
            return 0
        }

        function resolveLabelOverlappingInOneDirection(points, canvas, isRotated, shiftFunction) {
            var rollingStocks, stubCanvas = {
                start: isRotated ? canvas.left : canvas.top,
                end: isRotated ? canvas.width - canvas.right : canvas.height - canvas.bottom
            };
            checkHeightLabelsInCanvas(points, stubCanvas, isRotated);
            rollingStocks = _map(points, function(p) {
                return p ? new RollingStock(p, isRotated, shiftFunction) : null
            });
            rollingStocks.sort(function(a, b) {
                return a.getPointPosition() - b.getPointPosition()
            });
            if (!checkStackOverlap(rollingStocks)) {
                return
            }
            rollingStocks.reverse();
            moveRollingStock(rollingStocks, stubCanvas)
        }

        function overlapRollingStock(firstRolling, secondRolling) {
            if (!firstRolling || !secondRolling) {
                return
            }
            return firstRolling.getBoundingRect().end > secondRolling.getBoundingRect().start
        }

        function checkStackOverlap(rollingStocks) {
            var i, j, currentRollingStock, nextRollingStock, overlap;
            for (i = 0; i < rollingStocks.length; i++) {
                currentRollingStock = rollingStocks[i];
                for (j = i + 1; j < rollingStocks.length; j++) {
                    nextRollingStock = rollingStocks[j];
                    if (overlapRollingStock(currentRollingStock, nextRollingStock)) {
                        currentRollingStock.toChain(nextRollingStock);
                        overlap = true;
                        rollingStocks[j] = null
                    }
                }
            }
            return overlap
        }

        function moveRollingStock(rollingStocks, canvas) {
            var i, j, currentRollingStock, nextRollingStock, currentBBox, nextBBox;
            for (i = 0; i < rollingStocks.length; i++) {
                currentRollingStock = rollingStocks[i];
                if (rollingStocksIsOut(currentRollingStock, canvas)) {
                    currentBBox = currentRollingStock.getBoundingRect();
                    for (j = i + 1; j < rollingStocks.length; j++) {
                        nextRollingStock = rollingStocks[j];
                        if (!nextRollingStock) {
                            continue
                        }
                        nextBBox = nextRollingStock.getBoundingRect();
                        if (nextBBox.end > currentBBox.start - (currentBBox.end - canvas.end)) {
                            nextRollingStock.toChain(currentRollingStock);
                            rollingStocks[i] = currentRollingStock = null;
                            break
                        }
                    }
                }
                currentRollingStock && currentRollingStock.setRollingStockInCanvas(canvas)
            }
        }

        function rollingStocksIsOut(rollingStock, canvas) {
            return rollingStock && rollingStock.getBoundingRect().end > canvas.end
        }

        function RollingStock(point, isRotated, shiftFunction) {
            var label = point.getLabel(),
                bbox = label.getBoundingRect();
            this.labels = [label];
            this.points = [point];
            this.shiftFunction = shiftFunction;
            this._bbox = {
                start: isRotated ? bbox.x : bbox.y,
                width: isRotated ? bbox.width : bbox.height,
                end: isRotated ? bbox.x + bbox.width : bbox.y + bbox.height
            };
            this._pointPositionInitialize = isRotated ? point.getBoundaryCoords().x : point.getBoundaryCoords().y;
            return this
        }
        RollingStock.prototype = {
            toChain: function(nextRollingStock) {
                var nextRollingStockBBox = nextRollingStock.getBoundingRect();
                nextRollingStock.shift(nextRollingStockBBox.start - this._bbox.end);
                this._changeBoxWidth(nextRollingStockBBox.width);
                this.labels = this.labels.concat(nextRollingStock.labels);
                this.points = this.points.concat(nextRollingStock.points)
            },
            getBoundingRect: function() {
                return this._bbox
            },
            shift: function(shiftLength) {
                var shiftFunction = this.shiftFunction;
                _each(this.labels, function(index, label) {
                    var bbox = label.getBoundingRect(),
                        coords = shiftFunction(bbox, shiftLength, label);
                    label.shift(coords.x, coords.y)
                });
                this._bbox.end -= shiftLength;
                this._bbox.start -= shiftLength
            },
            setRollingStockInCanvas: function(canvas) {
                if (this._bbox.end > canvas.end) {
                    this.shift(this._bbox.end - canvas.end)
                }
            },
            getPointPosition: function() {
                return this._pointPositionInitialize
            },
            _changeBoxWidth: function(width) {
                this._bbox.end += width;
                this._bbox.width += width
            }
        };

        function getLegendFields(name) {
            return {
                nameField: name + "Name",
                colorField: name + "Color",
                indexField: name + "Index"
            }
        }

        function getLegendSettings(legendDataField) {
            var formatObjectFields = getLegendFields(legendDataField);
            return {
                getFormatObject: function(data) {
                    var res = {};
                    res[formatObjectFields.indexField] = data.id;
                    res[formatObjectFields.colorField] = data.states.normal.fill;
                    res[formatObjectFields.nameField] = data.text;
                    return res
                },
                textField: formatObjectFields.nameField
            }
        }

        function setTemplateFields(data, templateData, series) {
            _each(data, function(_, data) {
                _each(series.getTemplateFields(), function(_, field) {
                    data[field.templateField] = data[field.originalField]
                });
                templateData.push(data)
            });
            series.updateTemplateFieldNames()
        }

        function checkOverlapping(firstRect, secondRect) {
            return (firstRect.x <= secondRect.x && secondRect.x <= firstRect.x + firstRect.width || firstRect.x >= secondRect.x && firstRect.x <= secondRect.x + secondRect.width) && (firstRect.y <= secondRect.y && secondRect.y <= firstRect.y + firstRect.height || firstRect.y >= secondRect.y && firstRect.y <= secondRect.y + secondRect.height)
        }
        var overlapping = {
            resolveLabelOverlappingInOneDirection: resolveLabelOverlappingInOneDirection
        };

        function suppressCommonLayout(layout) {
            layout.forward = function(rect) {
                return rect
            };
            layout.backward = _noop
        }
        var BaseChart = BaseWidget.inherit({
            _eventsMap: {
                onSeriesClick: {
                    name: "seriesClick"
                },
                onPointClick: {
                    name: "pointClick"
                },
                onArgumentAxisClick: {
                    name: "argumentAxisClick"
                },
                onLegendClick: {
                    name: "legendClick"
                },
                onSeriesSelectionChanged: {
                    name: "seriesSelectionChanged"
                },
                onPointSelectionChanged: {
                    name: "pointSelectionChanged"
                },
                onSeriesHoverChanged: {
                    name: "seriesHoverChanged"
                },
                onPointHoverChanged: {
                    name: "pointHoverChanged"
                },
                onDone: {
                    name: "done"
                },
                onZoomStart: {
                    name: "zoomStart"
                },
                onZoomEnd: {
                    name: "zoomEnd"
                }
            },
            _rootClassPrefix: "dxc",
            _rootClass: "dxc-chart",
            _init: function() {
                this._savedBusinessRange = {};
                this.callBase.apply(this, arguments)
            },
            _initialChanges: ["REINIT"],
            _themeDependentChanges: ["REFRESH_SERIES_REINIT"],
            _createThemeManager: function() {
                var option = this.option(),
                    themeManager = new chartThemeManagerModule.ThemeManager(option, this._chartType);
                themeManager.setTheme(option.theme, option.rtlEnabled);
                return themeManager
            },
            _initCore: function() {
                var that = this;
                suppressCommonLayout(that._layout);
                that._canvasClipRect = that._renderer.clipRect();
                that._createHtmlStructure();
                that._headerBlock = new headerBlockModule.HeaderBlock;
                that._createLegend();
                that._createTracker();
                that._needHandleRenderComplete = true;
                that.layoutManager = new LayoutManagerModule.LayoutManager;
                that._createScrollBar();
                that._$element.on("contextmenu", function(event) {
                    that.eventType = "contextmenu";
                    if (eventUtils.isTouchEvent(event) || eventUtils.isPointerEvent(event)) {
                        event.preventDefault()
                    }
                }).on("MSHoldVisual", function(event) {
                    that.eventType = "MSHoldVisual";
                    event.preventDefault()
                })
            },
            _getLayoutItems: $.noop,
            _layoutManagerOptions: function() {
                return this._themeManager.getOptions("adaptiveLayout")
            },
            _reinit: function() {
                var that = this;
                _setCanvasValues(that._canvas);
                that._reinitAxes();
                that._skipRender = true;
                that._updateDataSource();
                if (!that.series) {
                    that._dataSpecificInit(false)
                }
                that._skipRender = false;
                that._correctAxes();
                that._forceRender()
            },
            _correctAxes: _noop,
            _createHtmlStructure: function() {
                var that = this,
                    renderer = that._renderer,
                    root = renderer.root;
                that._backgroundRect = renderer.rect().attr({
                    fill: "gray",
                    opacity: 1e-4
                }).append(root);
                that._panesBackgroundGroup = renderer.g().attr({
                    "class": "dxc-background"
                }).append(root);
                that._stripsGroup = renderer.g().attr({
                    "class": "dxc-strips-group"
                }).linkOn(root, "strips");
                that._gridGroup = renderer.g().attr({
                    "class": "dxc-grids-group"
                }).linkOn(root, "grids");
                that._axesGroup = renderer.g().attr({
                    "class": "dxc-axes-group"
                }).linkOn(root, "axes");
                that._constantLinesGroup = renderer.g().attr({
                    "class": "dxc-constant-lines-group"
                }).linkOn(root, "constant-lines");
                that._labelAxesGroup = renderer.g().attr({
                    "class": "dxc-strips-labels-group"
                }).linkOn(root, "strips-labels");
                that._panesBorderGroup = renderer.g().attr({
                    "class": "dxc-border"
                }).linkOn(root, "border");
                that._seriesGroup = renderer.g().attr({
                    "class": "dxc-series-group"
                }).linkOn(root, "series");
                that._labelsGroup = renderer.g().attr({
                    "class": "dxc-labels-group"
                }).linkOn(root, "labels");
                that._crosshairCursorGroup = renderer.g().attr({
                    "class": "dxc-crosshair-cursor"
                }).linkOn(root, "crosshair");
                that._legendGroup = renderer.g().attr({
                    "class": "dxc-legend",
                    clipId: that._getCanvasClipRectID()
                }).linkOn(root, "legend");
                that._scrollBarGroup = renderer.g().attr({
                    "class": "dxc-scroll-bar"
                }).linkOn(root, "scroll-bar")
            },
            _disposeObjectsInArray: function(propName, fieldNames) {
                _each(this[propName] || [], function(_, item) {
                    if (fieldNames && item) {
                        _each(fieldNames, function(_, field) {
                            item[field] && item[field].dispose()
                        })
                    } else {
                        item && item.dispose()
                    }
                });
                this[propName] = null
            },
            _disposeCore: function() {
                var that = this,
                    disposeObject = function(propName) {
                        if (that[propName]) {
                            that[propName].dispose();
                            that[propName] = null
                        }
                    },
                    unlinkGroup = function(name) {
                        that[name].linkOff()
                    },
                    disposeObjectsInArray = this._disposeObjectsInArray;
                clearTimeout(that._delayedRedraw);
                that._renderer.stopAllAnimations();
                that.businessRanges = that.translators = null;
                disposeObjectsInArray.call(that, "series");
                disposeObject("_headerBlock");
                disposeObject("_tracker");
                disposeObject("_crosshair");
                that.layoutManager = null;
                that.paneAxis = null;
                that._userOptions = null;
                that._canvas = null;
                unlinkGroup("_stripsGroup");
                unlinkGroup("_gridGroup");
                unlinkGroup("_axesGroup");
                unlinkGroup("_constantLinesGroup");
                unlinkGroup("_labelAxesGroup");
                unlinkGroup("_panesBorderGroup");
                unlinkGroup("_seriesGroup");
                unlinkGroup("_labelsGroup");
                unlinkGroup("_crosshairCursorGroup");
                unlinkGroup("_legendGroup");
                unlinkGroup("_scrollBarGroup");
                disposeObject("_canvasClipRect");
                disposeObject("_panesBackgroundGroup");
                disposeObject("_stripsGroup");
                disposeObject("_gridGroup");
                disposeObject("_axesGroup");
                disposeObject("_constantLinesGroup");
                disposeObject("_labelAxesGroup");
                disposeObject("_panesBorderGroup");
                disposeObject("_seriesGroup");
                disposeObject("_labelsGroup");
                disposeObject("_crosshairCursorGroup");
                disposeObject("_legendGroup");
                disposeObject("_scrollBarGroup")
            },
            _getAnimationOptions: function() {
                return this._themeManager.getOptions("animation")
            },
            _getDefaultSize: function() {
                return {
                    width: 400,
                    height: 400
                }
            },
            _getOption: function(name) {
                return this._themeManager.getOptions(name)
            },
            _applySize: function() {
                this._processRefreshData(RESIZE_REFRESH_ACTION)
            },
            _resize: function() {
                this._doRender(this.__renderOptions || {
                    animate: false,
                    isResize: true
                })
            },
            _trackerType: "ChartTracker",
            _createTracker: function() {
                var that = this;
                that._tracker = new trackerModule[that._trackerType]({
                    seriesGroup: that._seriesGroup,
                    renderer: that._renderer,
                    tooltip: that._tooltip,
                    legend: that._legend,
                    eventTrigger: that._eventTrigger
                })
            },
            _getTrackerSettings: function() {
                return {
                    seriesSelectionMode: this._themeManager.getOptions("seriesSelectionMode"),
                    pointSelectionMode: this._themeManager.getOptions("pointSelectionMode")
                }
            },
            _updateTracker: function(trackerCanvases) {
                var that = this;
                that._tracker.update(that._getTrackerSettings());
                that._tracker.setCanvases({
                    left: 0,
                    right: that._canvas.width,
                    top: 0,
                    bottom: that._canvas.height
                }, trackerCanvases)
            },
            _doRender: function(_options) {
                var drawOptions, recreateCanvas, that = this;
                if ( /*!that._initialized || */ that._skipRender) {
                    return
                }
                if (0 === that._canvas.width && 0 === that._canvas.height) {
                    return
                }
                that._resetIsReady();
                drawOptions = that._prepareDrawOptions(_options);
                recreateCanvas = drawOptions.recreateCanvas;
                clearTimeout(that._delayedRedraw);
                that.__originalCanvas = that._canvas;
                that._canvas = $.extend({}, that._canvas);
                if (recreateCanvas) {
                    that.__currentCanvas = that._canvas
                } else {
                    that._canvas = that.__currentCanvas
                }
                that.DEBUG_canvas = that._canvas;
                recreateCanvas && that._updateCanvasClipRect(that._canvas);
                that._renderer.stopAllAnimations(true);
                _setCanvasValues(that._canvas);
                that._cleanGroups(drawOptions);
                that._renderElements(drawOptions)
            },
            _saveBusinessRange: _noop,
            _renderElements: function(drawOptions) {
                var argBusinessRange, zoomMinArg, zoomMaxArg, that = this,
                    preparedOptions = that._prepareToRender(drawOptions),
                    isRotated = that._isRotated(),
                    isLegendInside = that._isLegendInside(),
                    trackerCanvases = [],
                    layoutTargets = that._getLayoutTargets(),
                    dirtyCanvas = $.extend({}, that._canvas),
                    drawElements = [],
                    layoutCanvas = drawOptions.drawTitle && drawOptions.drawLegend && drawOptions.adjustAxes;
                that.DEBUG_dirtyCanvas = dirtyCanvas;
                if (layoutCanvas) {
                    drawElements = that._getDrawElements(drawOptions, isLegendInside)
                }
                that._renderer.lock();
                that._saveBusinessRange();
                that.layoutManager.setOptions(that._layoutManagerOptions());
                that.layoutManager.layoutElements(drawElements, that._canvas, that._getAxisDrawingMethods(drawOptions, preparedOptions, isRotated), layoutTargets, isRotated, that._getAxesForTransform(isRotated));
                layoutCanvas && that._updateCanvasClipRect(dirtyCanvas);
                that._applyClipRects(preparedOptions);
                that._appendSeriesGroups();
                that._createCrosshairCursor();
                _each(layoutTargets, function() {
                    var canvas = this.canvas;
                    trackerCanvases.push({
                        left: canvas.left,
                        right: canvas.width - canvas.right,
                        top: canvas.top,
                        bottom: canvas.height - canvas.bottom
                    })
                });
                if (that._scrollBar) {
                    argBusinessRange = that.businessRanges[0].arg;
                    if ("discrete" === argBusinessRange.axisType && argBusinessRange.categories && argBusinessRange.categories.length <= 1) {
                        zoomMinArg = zoomMaxArg = void 0
                    } else {
                        zoomMinArg = argBusinessRange.minVisible;
                        zoomMaxArg = argBusinessRange.maxVisible
                    }
                    that._scrollBar.init(argBusinessRange, layoutTargets[0].canvas).setPosition(zoomMinArg, zoomMaxArg)
                }
                that._updateTracker(trackerCanvases);
                that._updateLegendPosition(drawOptions, isLegendInside);
                that._renderSeries(drawOptions, isRotated, isLegendInside);
                that._renderer.unlock()
            },
            _createCrosshairCursor: _noop,
            _appendSeriesGroups: function() {
                this._seriesGroup.linkAppend();
                this._labelsGroup.linkAppend();
                this._appendAdditionalSeriesGroups()
            },
            _renderSeries: function(drawOptions, isRotated, isLegendInside) {
                var that = this,
                    themeManager = that._themeManager,
                    resolveLabelOverlapping = themeManager.getOptions("resolveLabelOverlapping");
                drawOptions.hideLayoutLabels = that.layoutManager.needMoreSpaceForPanesCanvas(that._getLayoutTargets(), isRotated) && !themeManager.getOptions("adaptiveLayout").keepLabels;
                that._drawSeries(drawOptions, isRotated);
                "none" !== resolveLabelOverlapping && that._resolveLabelOverlapping(resolveLabelOverlapping);
                that._adjustSeries();
                that._renderTrackers(isLegendInside);
                that._tracker.repairTooltip();
                that._canvas = that.__originalCanvas;
                that._drawn();
                that._renderCompleteHandler()
            },
            _drawSeries: function(drawOptions, isRotated) {
                var i, singleSeries, that = this,
                    series = that.series,
                    seriesLength = series.length;
                that._updateSeriesDimensions(drawOptions);
                for (i = 0; i < seriesLength; i++) {
                    singleSeries = series[i];
                    that._applyExtraSettings(singleSeries, drawOptions);
                    singleSeries.draw(that._prepareTranslators(singleSeries, i, isRotated), drawOptions.animate && singleSeries.getPoints().length <= drawOptions.animationPointsLimit && that._renderer.animationEnabled(), drawOptions.hideLayoutLabels, that._getLegendCallBack(singleSeries))
                }
            },
            _resolveLabelOverlapping: function(resolveLabelOverlapping) {
                var func;
                switch (resolveLabelOverlapping) {
                    case "stack":
                        func = this._resolveLabelOverlappingStack;
                        break;
                    case "hide":
                        func = this._resolveLabelOverlappingHide;
                        break;
                    case "shift":
                        func = this._resolveLabelOverlappingShift
                }
                $.isFunction(func) && func.call(this)
            },
            _getVisibleSeries: function() {
                return $.grep(this.getAllSeries(), function(series) {
                    return series.isVisible()
                })
            },
            _resolveLabelOverlappingHide: function() {
                var currentLabel, nextLabel, currentLabelRect, nextLabelRect, i, j, points, labels = [],
                    series = this._getVisibleSeries();
                for (i = 0; i < series.length; i++) {
                    points = series[i].getVisiblePoints();
                    for (j = 0; j < points.length; j++) {
                        labels.push(points[j].getLabel())
                    }
                }
                labels = [].concat.apply([], labels);
                for (i = 0; i < labels.length; i++) {
                    currentLabel = labels[i];
                    currentLabelRect = currentLabel.getBoundingRect();
                    if (!currentLabel.isVisible()) {
                        continue
                    }
                    for (j = i + 1; j < labels.length; j++) {
                        nextLabel = labels[j];
                        nextLabelRect = nextLabel.getBoundingRect();
                        if (checkOverlapping(currentLabelRect, nextLabelRect)) {
                            nextLabel.hide()
                        }
                    }
                }
            },
            _cleanGroups: function(drawOptions) {
                var that = this;
                that._stripsGroup.linkRemove().clear();
                that._gridGroup.linkRemove().clear();
                that._axesGroup.linkRemove().clear();
                that._constantLinesGroup.linkRemove().clear();
                that._labelAxesGroup.linkRemove().clear();
                that._labelsGroup.linkRemove().clear();
                that._crosshairCursorGroup.linkRemove().clear()
            },
            _createLegend: function() {
                var that = this,
                    legendSettings = getLegendSettings(that._legendDataField);
                that._legend = new legendModule.Legend({
                    renderer: that._renderer,
                    group: that._legendGroup,
                    backgroundClass: "dxc-border",
                    itemGroupClass: "dxc-item",
                    textField: legendSettings.textField,
                    getFormatObject: legendSettings.getFormatObject
                })
            },
            _updateLegend: function() {
                var that = this,
                    themeManager = that._themeManager,
                    legendOptions = themeManager.getOptions("legend"),
                    legendData = that._getLegendData();
                legendOptions.containerBackgroundColor = themeManager.getOptions("containerBackgroundColor");
                legendOptions._incidentOccurred = that._incidentOccurred;
                that._legend.update(legendData, legendOptions)
            },
            _prepareDrawOptions: function(drawOptions) {
                var options, animationOptions = this._getAnimationOptions();
                options = $.extend({}, {
                    force: false,
                    adjustAxes: true,
                    drawLegend: true,
                    drawTitle: true,
                    animate: animationOptions.enabled,
                    animationPointsLimit: animationOptions.maxPointCountSupported
                }, drawOptions, this.__renderOptions);
                if (!_isDefined(options.recreateCanvas)) {
                    options.recreateCanvas = options.adjustAxes && options.drawLegend && options.drawTitle
                }
                return options
            },
            _processRefreshData: function(newRefreshAction) {
                var currentRefreshActionPosition = $.inArray(this._currentRefreshData, ACTIONS_BY_PRIORITY),
                    newRefreshActionPosition = $.inArray(newRefreshAction, ACTIONS_BY_PRIORITY);
                if (!this._currentRefreshData || currentRefreshActionPosition >= 0 && newRefreshActionPosition < currentRefreshActionPosition) {
                    this._currentRefreshData = newRefreshAction
                }
            },
            _getLegendData: function() {
                return _map(this._getLegendTargets(), function(item) {
                    var legendData = item.legendData,
                        style = item.getLegendStyles,
                        opacity = style.normal.opacity;
                    if (!item.visible) {
                        if (!_isDefined(opacity) || opacity > DEFAULT_OPACITY) {
                            opacity = DEFAULT_OPACITY
                        }
                        legendData.textOpacity = DEFAULT_OPACITY
                    }
                    legendData.states = {
                        hover: style.hover,
                        selection: style.selection,
                        normal: _extend({}, style.normal, {
                            opacity: opacity
                        })
                    };
                    return legendData
                })
            },
            _getLegendOptions: function(item) {
                return {
                    legendData: {
                        text: item[this._legendItemTextField],
                        argument: item.argument,
                        id: item.index
                    },
                    getLegendStyles: item.getLegendStyles(),
                    visible: item.isVisible()
                }
            },
            _disposeSeries: function() {
                var that = this;
                _each(that.series || [], function(_, series) {
                    series.dispose()
                });
                that.series = null;
                _each(that.seriesFamilies || [], function(_, family) {
                    family.dispose()
                });
                that.seriesFamilies = null;
                that._needHandleRenderComplete = true
            },
            _optionChanged: function(arg) {
                this._themeManager.resetOptions(arg.name);
                this.callBase.apply(this, arguments)
            },
            _applyChanges: function() {
                var that = this;
                that._themeManager.update(that._options);
                that.callBase.apply(that, arguments);
                that._doRefresh()
            },
            _optionChangesMap: {
                animation: "ANIMATION",
                dataSource: "DATA_SOURCE",
                palette: "PALETTE",
                series: "REFRESH_SERIES_DATA_INIT",
                commonSeriesSettings: "REFRESH_SERIES_DATA_INIT",
                containerBackgroundColor: "REFRESH_SERIES_DATA_INIT",
                dataPrepareSettings: "REFRESH_SERIES_DATA_INIT",
                legend: "DATA_INIT",
                seriesTemplate: "DATA_INIT",
                "export": "FORCE_RENDER",
                valueAxis: "AXES_AND_PANES",
                argumentAxis: "AXES_AND_PANES",
                commonAxisSettings: "AXES_AND_PANES",
                panes: "AXES_AND_PANES",
                defaultPane: "AXES_AND_PANES",
                rotated: "ROTATED",
                customizePoint: "REFRESH_SERIES_REINIT",
                customizeLabel: "REFRESH_SERIES_REINIT",
                scrollBar: "SCROLL_BAR"
            },
            _customChangesOrder: ["ANIMATION", "DATA_SOURCE", "PALETTE", "REFRESH_SERIES_DATA_INIT", "DATA_INIT", "FORCE_RENDER", "AXES_AND_PANES", "ROTATED", "REFRESH_SERIES_REINIT", "SCROLL_BAR", "CHART_TOOLTIP", "REINIT"],
            _change_ANIMATION: function() {
                this._renderer.updateAnimationOptions(this._getAnimationOptions())
            },
            _change_DATA_SOURCE: function() {
                this._needHandleRenderComplete = true;
                this._processRefreshData(REINIT_DATA_SOURCE_REFRESH_ACTION)
            },
            _change_PALETTE: function() {
                this._themeManager.updatePalette(this.option("palette"));
                this._refreshSeries(DATA_INIT_REFRESH_ACTION)
            },
            _change_REFRESH_SERIES_DATA_INIT: function() {
                this._refreshSeries(DATA_INIT_REFRESH_ACTION)
            },
            _change_DATA_INIT: function() {
                this._processRefreshData(DATA_INIT_REFRESH_ACTION)
            },
            _change_FORCE_RENDER: function() {
                this._processRefreshData(FORCE_RENDER_REFRESH_ACTION)
            },
            _change_AXES_AND_PANES: function() {
                this._refreshSeries(REINIT_REFRESH_ACTION);
                this.paneAxis = {}
            },
            _change_ROTATED: function() {
                this._createScrollBar();
                this._refreshSeries(REINIT_REFRESH_ACTION)
            },
            _change_REFRESH_SERIES_REINIT: function() {
                this._refreshSeries(REINIT_REFRESH_ACTION)
            },
            _change_SCROLL_BAR: function() {
                this._createScrollBar();
                this._processRefreshData(FORCE_RENDER_REFRESH_ACTION)
            },
            _change_CHART_TOOLTIP: function() {
                this._organizeStackPoints()
            },
            _change_REINIT: function() {
                this._processRefreshData(REINIT_REFRESH_ACTION)
            },
            _refreshSeries: function(actionName) {
                this._disposeSeries();
                this._processRefreshData(actionName)
            },
            _doRefresh: function() {
                var methodName = this._currentRefreshData;
                if (methodName) {
                    this._currentRefreshData = null;
                    this._renderer.stopAllAnimations(true);
                    this[methodName]()
                }
            },
            _updateCanvasClipRect: function(canvas) {
                var width, height, that = this;
                width = Math.max(canvas.width - canvas.left - canvas.right, 0);
                height = Math.max(canvas.height - canvas.top - canvas.bottom, 0);
                that._canvasClipRect.attr({
                    x: canvas.left,
                    y: canvas.top,
                    width: width,
                    height: height
                });
                that._backgroundRect.attr({
                    x: canvas.left,
                    y: canvas.top,
                    width: width,
                    height: height
                })
            },
            _getCanvasClipRectID: function() {
                return this._canvasClipRect.id
            },
            _dataSourceChangedHandler: function() {
                this._resetZoom();
                this._dataInit()
            },
            _dataInit: function() {
                clearTimeout(this._delayedRedraw);
                this._dataSpecificInit(true)
            },
            _dataSpecificInit: function(needRedraw) {
                var that = this;
                that.series = that.series || that._populateSeries();
                that._repopulateSeries();
                that._seriesPopulatedHandlerCore();
                that._populateBusinessRange();
                that._collectPointsByArg();
                that._tracker.updateSeries(that._getStoredSeries());
                that._updateLegend();
                needRedraw && that._forceRender()
            },
            _forceRender: function() {
                this._doRender({
                    force: true
                })
            },
            _repopulateSeries: function() {
                var parsedData, that = this,
                    themeManager = that._themeManager,
                    data = that._dataSource.items(),
                    dataValidatorOptions = themeManager.getOptions("dataPrepareSettings"),
                    seriesTemplate = themeManager.getOptions("seriesTemplate");
                if (seriesTemplate) {
                    that._templatedSeries = vizUtils.processSeriesTemplate(seriesTemplate, data);
                    that._populateSeries();
                    delete that._templatedSeries;
                    data = that.templateData || data
                }
                that._groupSeries();
                parsedData = dataValidatorModule.validateData(data, that._groupsData, that._incidentOccurred, dataValidatorOptions);
                themeManager.resetPalette();
                _each(that.series, function(_, singleSeries) {
                    singleSeries.updateData(parsedData[singleSeries.getArgumentField()]);
                    that._processSingleSeries(singleSeries)
                });
                that._organizeStackPoints()
            },
            _organizeStackPoints: function() {
                var that = this,
                    themeManager = that._themeManager,
                    sharedTooltip = themeManager.getOptions("tooltip").shared,
                    stackPoints = {};
                _each(that.series || [], function(_, singleSeries) {
                    that._resetStackPoints(singleSeries);
                    sharedTooltip && that._prepareStackPoints(singleSeries, stackPoints)
                })
            },
            _renderCompleteHandler: function() {
                var that = this,
                    allSeriesInited = true;
                if (that._needHandleRenderComplete) {
                    _each(that.series, function(_, s) {
                        allSeriesInited = allSeriesInited && s.canRenderCompleteHandle()
                    });
                    if (allSeriesInited) {
                        that._needHandleRenderComplete = false;
                        that._eventTrigger("done", {
                            target: that
                        })
                    }
                }
            },
            _getDrawElements: function(drawOptions, legendHasInsidePosition) {
                var that = this,
                    drawElements = [],
                    exportOptions = that._themeManager.getOptions("export"),
                    titleOptions = that._title.getLayoutOptions() || {},
                    headerElements = [];
                that._exportMenu && exportOptions.enabled && headerElements.push(that._exportMenu);
                if (drawOptions.drawTitle) {
                    "bottom" !== titleOptions.verticalAlignment && headerElements.length ? headerElements.push(that._title) : drawElements.push(that._title)
                }
                if (headerElements.length) {
                    that._headerBlock.update(headerElements, that._canvas);
                    drawElements.push(that._headerBlock)
                }
                if (drawOptions.drawLegend && that._legend) {
                    that._legendGroup.linkAppend();
                    !legendHasInsidePosition && drawElements.push(that._legend)
                }
                return drawElements
            },
            _resetZoom: _noop,
            _dataIsReady: function() {
                return _isDefined(this.option("dataSource")) && this._dataSource.isLoaded()
            },
            _populateSeries: function() {
                var particularSeriesOptions, particularSeries, seriesTheme, data, i, that = this,
                    themeManager = that._themeManager,
                    hasSeriesTemplate = !!themeManager.getOptions("seriesTemplate"),
                    seriesOptions = hasSeriesTemplate ? that._templatedSeries : that.option("series"),
                    allSeriesOptions = _isArray(seriesOptions) ? seriesOptions : seriesOptions ? [seriesOptions] : [],
                    extraOptions = that._getExtraOptions(),
                    seriesVisibilityChanged = function() {
                        that._specialProcessSeries();
                        that._populateBusinessRange();
                        that._renderer.stopAllAnimations(true);
                        that._updateLegend();
                        that._doRender({
                            force: true
                        })
                    };
                that._disposeSeries();
                that.series = [];
                that.templateData = [];
                themeManager.resetPalette();
                for (i = 0; i < allSeriesOptions.length; i++) {
                    particularSeriesOptions = _extend(true, {}, allSeriesOptions[i], extraOptions);
                    if (!particularSeriesOptions.name) {
                        particularSeriesOptions.name = "Series " + (i + 1).toString()
                    }
                    data = particularSeriesOptions.data;
                    particularSeriesOptions.data = null;
                    particularSeriesOptions.rotated = that._isRotated();
                    particularSeriesOptions.customizePoint = themeManager.getOptions("customizePoint");
                    particularSeriesOptions.customizeLabel = themeManager.getOptions("customizeLabel");
                    particularSeriesOptions.visibilityChanged = seriesVisibilityChanged;
                    particularSeriesOptions.incidentOccurred = that._incidentOccurred;
                    seriesTheme = themeManager.getOptions("series", particularSeriesOptions);
                    if (!that._checkPaneName(seriesTheme)) {
                        continue
                    }
                    particularSeries = new seriesModule.Series({
                        renderer: that._renderer,
                        seriesGroup: that._seriesGroup,
                        labelsGroup: that._labelsGroup
                    }, seriesTheme);
                    if (!particularSeries.isUpdated) {
                        that._incidentOccurred("E2101", [seriesTheme.type])
                    } else {
                        particularSeries.index = that.series.length;
                        that._processSingleSeries(particularSeries);
                        that.series.push(particularSeries);
                        if (hasSeriesTemplate) {
                            setTemplateFields(data, that.templateData, particularSeries)
                        }
                    }
                }
                return that.series
            },
            getAllSeries: function() {
                return this.series.slice()
            },
            getSeriesByName: function(name) {
                var found = null;
                _each(this.series, function(i, singleSeries) {
                    if (singleSeries.name === name) {
                        found = singleSeries;
                        return false
                    }
                });
                return found
            },
            getSeriesByPos: function(pos) {
                return this.series[pos]
            },
            clearSelection: function() {
                this._tracker.clearSelection()
            },
            hideTooltip: function() {
                this._tracker._hideTooltip()
            },
            render: function(renderOptions) {
                var that = this;
                that.__renderOptions = renderOptions;
                that.__forceRender = renderOptions && renderOptions.force;
                that.callBase.apply(that, arguments);
                that.__renderOptions = that.__forceRender = null;
                return that
            },
            getSize: function() {
                var canvas = this._canvas || {};
                return {
                    width: canvas.width,
                    height: canvas.height
                }
            }
        });
        _each(REINIT_REFRESH_ACTION_OPTIONS, function(_, name) {
            BaseChart.prototype._optionChangesMap[name] = "REINIT"
        });
        exports.overlapping = overlapping;
        exports.BaseChart = BaseChart;
        BaseChart.addPlugin(__webpack_require__( /*! ../core/data_source */ 493).plugin);
        BaseChart.addPlugin(__webpack_require__( /*! ../core/export */ 444).plugin);
        BaseChart.addPlugin(__webpack_require__( /*! ../core/title */ 494).plugin);
        BaseChart.addPlugin(__webpack_require__( /*! ../core/tooltip */ 495).plugin);
        BaseChart.addPlugin(__webpack_require__( /*! ../core/loading_indicator */ 496).plugin);
        var _change_TITLE = BaseChart.prototype._change_TITLE;
        BaseChart.prototype._change_TITLE = function() {
            _change_TITLE.apply(this, arguments);
            this._change(["FORCE_RENDER"])
        };
        var _change_TOOLTIP = BaseChart.prototype._change_TOOLTIP;
        BaseChart.prototype._change_TOOLTIP = function() {
            _change_TOOLTIP.apply(this, arguments);
            this._change(["CHART_TOOLTIP"])
        }
    },
    /*!*****************************************!*\
      !*** ./Scripts/viz/core/base_widget.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            version = __webpack_require__( /*! ../../core/version */ 16),
            _windowResizeCallbacks = __webpack_require__( /*! ../../core/utils/window */ 30).resizeCallbacks,
            _stringFormat = __webpack_require__( /*! ../../core/utils/string */ 13).format,
            _isObject = __webpack_require__( /*! ../../core/utils/common */ 14).isObject,
            _Number = Number,
            DOMComponent = __webpack_require__( /*! ../../core/dom_component */ 29),
            helpers = __webpack_require__( /*! ./helpers */ 449),
            _parseScalar = __webpack_require__( /*! ./utils */ 442).parseScalar,
            errors = __webpack_require__( /*! ./errors_warnings */ 450),
            _log = errors.log,
            rendererModule = __webpack_require__( /*! ./renderers/renderer */ 451),
            _Layout = __webpack_require__( /*! ./layout */ 455),
            OPTION_RTL_ENABLED = "rtlEnabled",
            _option = DOMComponent.prototype.option;

        function getTrue() {
            return true
        }

        function getFalse() {
            return false
        }

        function areCanvasesDifferent(canvas1, canvas2) {
            return !(canvas1.width === canvas2.width && canvas1.height === canvas2.height && canvas1.left === canvas2.left && canvas1.top === canvas2.top && canvas1.right === canvas2.right && canvas1.bottom === canvas2.bottom)
        }

        function createResizeHandler(callback) {
            var timeout, handler = function() {
                clearTimeout(timeout);
                timeout = setTimeout(callback, 100)
            };
            handler.dispose = function() {
                clearTimeout(timeout);
                return this
            };
            return handler
        }

        function defaultOnIncidentOccurred(e) {
            _log.apply(null, [e.target.id].concat(e.target.args || []))
        }
        var createIncidentOccurred = function(widgetName, eventTrigger) {
            return incidentOccurred;

            function incidentOccurred(id, args) {
                eventTrigger("incidentOccurred", {
                    target: {
                        id: id,
                        type: "E" === id[0] ? "error" : "warning",
                        args: args,
                        text: _stringFormat.apply(null, [errors.ERROR_MESSAGES[id]].concat(args || [])),
                        widget: widgetName,
                        version: version
                    }
                })
            }
        };

        function pickPositiveValue(value, defaultValue) {
            return _Number(value > 0 ? value : defaultValue || 0)
        }
        module.exports = DOMComponent.inherit({
            _eventsMap: {
                onIncidentOccurred: {
                    name: "incidentOccurred"
                },
                onDrawn: {
                    name: "drawn"
                }
            },
            _getDefaultOptions: function() {
                return $.extend(this.callBase(), {
                    onIncidentOccurred: defaultOnIncidentOccurred
                })
            },
            _useLinks: true,
            _init: function() {
                var linkTarget, that = this;
                that.callBase.apply(that, arguments);
                that._changesLocker = 0;
                that._changes = helpers.changes();
                that._suspendChanges();
                that._themeManager = that._createThemeManager();
                that._themeManager.setCallback(function() {
                    that._requestChange(that._themeDependentChanges)
                });
                that._initRenderer();
                linkTarget = that._useLinks && that._renderer.root;
                linkTarget && linkTarget.enableLinks().virtualLink("core").virtualLink("peripheral");
                that._renderVisibilityChange();
                that._initEventTrigger();
                that._incidentOccurred = createIncidentOccurred(that.NAME, that._eventTrigger);
                that._layout = new _Layout;
                linkTarget && linkTarget.linkAfter("core");
                that._initPlugins();
                that._initCore();
                linkTarget && linkTarget.linkAfter();
                that._change(that._initialChanges);
                that._resumeChanges()
            },
            _initialChanges: ["LAYOUT", "RESIZE_HANDLER", "THEME"],
            _initPlugins: function() {
                var that = this;
                $.each(that._plugins, function(_, plugin) {
                    plugin.init.call(that)
                })
            },
            _disposePlugins: function() {
                var that = this;
                $.each(that._plugins.slice().reverse(), function(_, plugin) {
                    plugin.dispose.call(that)
                })
            },
            _change: function(codes) {
                this._changes.add(codes)
            },
            _suspendChanges: function() {
                ++this._changesLocker
            },
            _resumeChanges: function() {
                var that = this;
                if (0 === --that._changesLocker && that._changes.count() > 0) {
                    that._renderer.lock();
                    that._applyingChanges = true;
                    that._applyChanges();
                    that._changes.reset();
                    that._applyingChanges = false;
                    that._renderer.unlock();
                    if (that._optionsQueue) {
                        that._applyQueuedOptions()
                    }
                }
            },
            _applyQueuedOptions: function() {
                var that = this,
                    queue = that._optionsQueue;
                that._optionsQueue = null;
                that.beginUpdate();
                $.each(queue, function(_, args) {
                    _option.apply(that, args)
                });
                that.endUpdate()
            },
            _requestChange: function(codes) {
                var applyingChanges = this._applyingChanges;
                if (!applyingChanges) {
                    this._suspendChanges()
                }
                this._change(codes);
                if (!applyingChanges) {
                    this._resumeChanges()
                }
            },
            _applyChanges: function() {
                var i, that = this,
                    changes = that._changes,
                    order = that._totalChangesOrder,
                    ii = order.length;
                for (i = 0; i < ii; ++i) {
                    if (changes.has(order[i])) {
                        that["_change_" + order[i]]()
                    }
                }
            },
            _optionChangesOrder: ["EVENTS", "THEME", "RENDERER", "RESIZE_HANDLER"],
            _layoutChangesOrder: ["CONTAINER_SIZE", "LAYOUT"],
            _customChangesOrder: [],
            _change_EVENTS: function() {
                this._eventTrigger.applyChanges()
            },
            _change_THEME: function() {
                this._setThemeAndRtl()
            },
            _change_RENDERER: function() {
                this._setRendererOptions()
            },
            _change_RESIZE_HANDLER: function() {
                this._setupResizeHandler()
            },
            _change_CONTAINER_SIZE: function() {
                this._updateSize()
            },
            _change_LAYOUT: function() {
                this._setContentSize()
            },
            _themeDependentChanges: ["RENDERER"],
            _initRenderer: function() {
                var that = this;
                that._canvas = that._calculateCanvas();
                that._renderer = new rendererModule.Renderer({
                    cssClass: that._rootClassPrefix + " " + that._rootClass,
                    pathModified: that.option("pathModified"),
                    container: that._$element[0]
                });
                that._renderer.resize(that._canvas.width, that._canvas.height)
            },
            _disposeRenderer: function() {
                this._useLinks && this._renderer.root.checkLinks();
                this._renderer.dispose()
            },
            _getAnimationOptions: $.noop,
            render: function() {
                this._requestChange(["CONTAINER_SIZE"]);
                this._onRender()
            },
            _onRender: $.noop,
            _dispose: function() {
                var that = this;
                that.callBase.apply(that, arguments);
                that._removeResizeHandler();
                that._layout.dispose();
                that._eventTrigger.dispose();
                that._disposeCore();
                that._disposePlugins();
                that._disposeRenderer();
                that._themeManager.dispose();
                that._themeManager = that._renderer = that._eventTrigger = null
            },
            _initEventTrigger: function() {
                var that = this;
                that._eventTrigger = createEventTrigger(that._eventsMap, function(name) {
                    return that._createActionByOption(name)
                })
            },
            _calculateCanvas: function() {
                var that = this,
                    size = that.option("size") || {},
                    margin = that.option("margin") || {},
                    defaultCanvas = that._getDefaultSize() || {},
                    canvas = {
                        width: size.width <= 0 ? 0 : pickPositiveValue(size.width, that._$element.width() || defaultCanvas.width),
                        height: size.height <= 0 ? 0 : pickPositiveValue(size.height, that._$element.height() || defaultCanvas.height),
                        left: pickPositiveValue(margin.left, defaultCanvas.left || 0),
                        top: pickPositiveValue(margin.top, defaultCanvas.top || 0),
                        right: pickPositiveValue(margin.right, defaultCanvas.right || 0),
                        bottom: pickPositiveValue(margin.bottom, defaultCanvas.bottom || 0)
                    };
                if (canvas.width - canvas.left - canvas.right <= 0 || canvas.height - canvas.top - canvas.bottom <= 0) {
                    canvas = {
                        width: 0,
                        height: 0
                    }
                }
                return canvas
            },
            _updateSize: function() {
                var that = this,
                    canvas = that._calculateCanvas();
                if (areCanvasesDifferent(that._canvas, canvas) || that.__forceRender) {
                    that._canvas = canvas;
                    that._renderer.resize(canvas.width, canvas.height);
                    that._change(["LAYOUT"])
                }
            },
            _setContentSize: function() {
                var nextRect, canvas = this._canvas,
                    layout = this._layout,
                    rect = canvas.width > 0 && canvas.height > 0 ? [canvas.left, canvas.top, canvas.width - canvas.right, canvas.height - canvas.bottom] : [0, 0, 0, 0];
                rect = layout.forward(rect);
                nextRect = this._applySize(rect) || rect;
                layout.backward(nextRect)
            },
            DEBUG_getCanvas: function() {
                return this._canvas
            },
            DEBUG_getEventTrigger: function() {
                return this._eventTrigger
            },
            _getOption: function(name, isScalar) {
                var theme = this._themeManager.theme(name),
                    option = this.option(name);
                return isScalar ? void 0 !== option ? option : theme : $.extend(true, {}, theme, option)
            },
            _setupResizeHandler: function() {
                if (_parseScalar(this._getOption("redrawOnResize", true), true)) {
                    this._addResizeHandler()
                } else {
                    this._removeResizeHandler()
                }
            },
            _addResizeHandler: function() {
                var that = this;
                if (!that._resizeHandler) {
                    that._resizeHandler = createResizeHandler(function() {
                        that._requestChange(["CONTAINER_SIZE"])
                    });
                    _windowResizeCallbacks.add(that._resizeHandler)
                }
            },
            _removeResizeHandler: function() {
                if (this._resizeHandler) {
                    _windowResizeCallbacks.remove(this._resizeHandler);
                    this._resizeHandler.dispose();
                    this._resizeHandler = null
                }
            },
            _onBeginUpdate: $.noop,
            beginUpdate: function() {
                var that = this;
                if (that._initialized && 0 === that._updateLockCount) {
                    that._onBeginUpdate();
                    that._suspendChanges()
                }
                that.callBase.apply(that, arguments);
                return that
            },
            endUpdate: function() {
                var that = this,
                    initialized = that._initialized;
                that.callBase.apply(that, arguments);
                if (initialized && 0 === that._updateLockCount) {
                    that._resumeChanges()
                }
                return that
            },
            option: function(name) {
                var that = this;
                if (that._initialized && that._applyingChanges && (arguments.length > 1 || _isObject(name))) {
                    that._optionsQueue = that._optionsQueue || [];
                    that._optionsQueue.push(arguments)
                } else {
                    return _option.apply(that, arguments)
                }
            },
            _clean: $.noop,
            _render: $.noop,
            _optionChanged: function(arg) {
                var that = this;
                if (that._eventTrigger.change(arg.name)) {
                    that._change(["EVENTS"])
                } else {
                    if (that._optionChangesMap[arg.name]) {
                        that._change([that._optionChangesMap[arg.name]])
                    } else {
                        that.callBase.apply(that, arguments)
                    }
                }
            },
            _optionChangesMap: {
                size: "CONTAINER_SIZE",
                margin: "CONTAINER_SIZE",
                redrawOnResize: "RESIZE_HANDLER",
                theme: "THEME",
                rtlEnabled: "THEME",
                encodeHtml: "THEME"
            },
            _visibilityChanged: function() {
                this.render()
            },
            _setThemeAndRtl: function() {
                this._themeManager.setTheme(this.option("theme"), this.option(OPTION_RTL_ENABLED))
            },
            _getRendererOptions: function() {
                return {
                    rtl: this.option(OPTION_RTL_ENABLED),
                    encodeHtml: this.option("encodeHtml"),
                    animation: this._getAnimationOptions()
                }
            },
            _setRendererOptions: function() {
                this._renderer.setOptions(this._getRendererOptions())
            },
            _normalizeHtml: function(html) {
                var re = /xmlns="[\s\S]*?"/gi,
                    first = true;
                html = html.replace(re, function(match) {
                    if (!first) {
                        return ""
                    }
                    first = false;
                    return match
                });
                return html.replace(/xmlns:NS1="[\s\S]*?"/gi, "").replace(/NS1:xmlns:xlink="([\s\S]*?)"/gi, 'xmlns:xlink="$1"')
            },
            svg: function() {
                return this._normalizeHtml(this._renderer.svg())
            },
            isReady: getFalse,
            _dataIsReady: getTrue,
            _resetIsReady: function() {
                this.isReady = getFalse
            },
            _drawn: function() {
                var that = this;
                that.isReady = getFalse;
                if (that._dataIsReady()) {
                    that._renderer.onEndAnimation(function() {
                        that.isReady = getTrue
                    })
                }
                that._eventTrigger("drawn", {})
            }
        });
        helpers.replaceInherit(module.exports);

        function createEventTrigger(eventsMap, callbackGetter) {
            var triggers = {};
            $.each(eventsMap, function(name, info) {
                if (info.name) {
                    createEvent(name)
                }
            });
            var changes;
            triggerEvent.change = function(name) {
                var eventInfo = eventsMap[name];
                if (eventInfo) {
                    (changes = changes || {})[name] = eventInfo
                }
                return !!eventInfo
            };
            triggerEvent.applyChanges = function() {
                if (changes) {
                    $.each(changes, function(name, eventInfo) {
                        createEvent(eventInfo.newName || name)
                    });
                    changes = null
                }
            };
            triggerEvent.dispose = function() {
                eventsMap = callbackGetter = triggers = null
            };
            return triggerEvent;

            function createEvent(name) {
                var eventInfo = eventsMap[name];
                triggers[eventInfo.name] = callbackGetter(name)
            }

            function triggerEvent(name, arg, complete) {
                triggers[name](arg);
                complete && complete()
            }
        }
        module.exports.DEBUG_createEventTrigger = createEventTrigger;
        module.exports.DEBUG_createIncidentOccurred = createIncidentOccurred;
        module.exports.DEBUG_stub_createIncidentOccurred = function(stub) {
            createIncidentOccurred = stub
        };
        module.exports.DEBUG_restore_createIncidentOccurred = function() {
            createIncidentOccurred = module.exports.DEBUG_createIncidentOccurred
        };
        module.exports.DEBUG_createResizeHandler = createResizeHandler
    },
    /*!*************************************!*\
      !*** ./Scripts/viz/core/helpers.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var _extend = __webpack_require__( /*! jquery */ 9).extend;

        function Flags() {
            this.reset()
        }
        Flags.prototype = {
            constructor: Flags,
            add: function(codes) {
                var i, ii = codes.length,
                    flags = this._flags;
                for (i = 0; i < ii; ++i) {
                    flags[codes[i]] = 1
                }
                this._k += ii
            },
            has: function(code) {
                return this._flags[code] > 0
            },
            count: function() {
                return this._k
            },
            reset: function() {
                this._flags = {};
                this._k = 0
            }
        };

        function combineMaps(baseMap, thisMap) {
            return baseMap !== thisMap ? _extend({}, baseMap, thisMap) : _extend({}, baseMap)
        }

        function combineLists(baseList, thisList) {
            return baseList !== thisList ? baseList.concat(thisList) : baseList.slice()
        }

        function buildTotalChanges(proto) {
            proto._totalChangesOrder = proto._optionChangesOrder.concat(proto._layoutChangesOrder, proto._customChangesOrder)
        }

        function addChange(settings) {
            var proto = this.prototype,
                code = settings.code;
            proto["_change_" + code] = settings.handler;
            if (settings.isThemeDependent) {
                proto._themeDependentChanges.push(code)
            }
            if (settings.option) {
                proto._optionChangesMap[settings.option] = code
            }(settings.isOptionChange ? proto._optionChangesOrder : proto._customChangesOrder).push(code);
            buildTotalChanges(proto)
        }

        function addPlugin(plugin) {
            this.prototype._plugins.push(plugin);
            if (plugin.members) {
                _extend(this.prototype, plugin.members)
            }
            if (plugin.customize) {
                plugin.customize(this)
            }
        }
        exports.replaceInherit = function(widget) {
            var _inherit = widget.inherit;
            widget.inherit = function(members) {
                var proto = this.prototype,
                    plugins = proto._plugins,
                    eventsMap = proto._eventsMap,
                    initialChanges = proto._initialChanges,
                    themeDependentChanges = proto._themeDependentChanges,
                    optionChangesMap = proto._optionChangesMap,
                    optionChangesOrder = proto._optionChangesOrder,
                    layoutChangesOrder = proto._layoutChangesOrder,
                    customChangesOrder = proto._customChangesOrder,
                    ret = _inherit.apply(this, arguments);
                proto = ret.prototype;
                proto._plugins = combineLists(plugins, proto._plugins);
                proto._eventsMap = combineMaps(eventsMap, proto._eventsMap);
                proto._initialChanges = combineLists(initialChanges, proto._initialChanges);
                proto._themeDependentChanges = combineLists(themeDependentChanges, proto._themeDependentChanges);
                proto._optionChangesMap = combineMaps(optionChangesMap, proto._optionChangesMap);
                proto._optionChangesOrder = combineLists(optionChangesOrder, proto._optionChangesOrder);
                proto._layoutChangesOrder = combineLists(layoutChangesOrder, proto._layoutChangesOrder);
                proto._customChangesOrder = combineLists(customChangesOrder, proto._customChangesOrder);
                buildTotalChanges(proto);
                ret.addPlugin = addPlugin;
                return ret
            };
            widget.prototype._plugins = [];
            widget.addChange = addChange;
            widget.addPlugin = addPlugin
        };
        exports.changes = function() {
            return new Flags
        }
    },
    /*!*********************************************!*\
      !*** ./Scripts/viz/core/errors_warnings.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var errorUtils = __webpack_require__( /*! ../../core/utils/error */ 11),
            errors = __webpack_require__( /*! ../../core/errors */ 17);
        /**
         * @docid
         * @name Errors and Warnings
         * @publicName Errors and Warnings
         * @description Errors and Warnings
         */
        module.exports = errorUtils(errors.ERROR_MESSAGES, {
            E2001: "Invalid data source",
            E2002: "Axis type and data type are incompatible",
            E2003: '"{0}" data source field contains data of unsupported type',
            E2004: '"{0}" data source field is inconsistent',
            E2101: "Unknown series type was specified: {0}",
            E2102: "Ambiguity occurred between two value axes with the same name",
            E2103: '"{0}" option must be a function',
            E2104: "Invalid logarithm base",
            E2105: 'Invalid value of a "{0}"',
            E2106: "Invalid visible range",
            E2202: "Invalid scale {0} value",
            E2203: 'The "{0}" field of the "selectedRange" configuration object is not valid',
            W2002: "The {0} data field is absent",
            W2003: "Tick interval is too small",
            W2101: 'The "{0}" pane does not exist; the last pane is used by default',
            W2102: 'Value axis with the "{0}" name was created automatically',
            W2103: "Chart title was hidden due to container size",
            W2104: "Legend was hidden due to container size",
            W2105: 'Title of "{0}" axis was hidden due to container size',
            W2106: 'Labels of "{0}" axis were hidden due to container size',
            W2301: "Invalid value range"
        })
    },
    /*!************************************************!*\
      !*** ./Scripts/viz/core/renderers/renderer.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var browser = __webpack_require__( /*! ../../../core/utils/browser */ 18);

        function isSvg() {
            return !(browser.msie && browser.version < 9) || !!document.createElementNS && !!document.createElementNS("http://www.w3.org/2000/svg", "svg").createSVGRect
        }
        if (!isSvg()) {
            if (document.namespaces && !document.namespaces.vml) {
                document.namespaces.add("vml", "urn:schemas-microsoft-com:vml");
                document.createStyleSheet().cssText = "vml\\:* { behavior:url(#default#VML); display: inline-block; } "
            }
            exports.Renderer = __webpack_require__( /*! ./vml_renderer */ 452).VmlRenderer
        } else {
            exports.Renderer = __webpack_require__( /*! ./svg_renderer */ 453).SvgRenderer
        }
        exports.isSvg = isSvg
    },
    /*!****************************************************!*\
      !*** ./Scripts/viz/core/renderers/vml_renderer.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            svgRendererModule = __webpack_require__( /*! ./svg_renderer */ 453),
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            doc = document,
            math = Math,
            mathMin = math.min,
            mathMax = math.max,
            mathFloor = math.floor,
            mathSin = math.sin,
            mathCos = math.cos,
            isDefined = commonUtils.isDefined,
            _each = $.each,
            _normalizeEnum = __webpack_require__( /*! ../utils */ 442).normalizeEnum,
            baseElementPrototype = svgRendererModule.SvgElement.prototype,
            documentFragment = doc.createDocumentFragment(),
            STROKEWIDTH = "stroke-width",
            XMLNS = "urn:schemas-microsoft-com:vml",
            DEFAULT_STYLE = {
                behavior: "url(#default#VML)",
                display: "inline-block",
                position: "absolute"
            },
            DEFAULT_ATTRS = {
                xmlns: XMLNS
            },
            INHERITABLE_PROPERTIES = {
                stroke: true,
                fill: true,
                opacity: true,
                "stroke-width": true,
                align: true,
                dashStyle: true,
                "stroke-opacity": true,
                "fill-opacity": true,
                rotate: true,
                rotateX: true,
                rotateY: true
            },
            stub = function() {},
            stubReturnedThis = function() {
                return this
            },
            svgToVmlConv = {
                circle: "oval",
                g: "div",
                path: "shape",
                text: "span"
            },
            FONT_HEIGHT_OFFSET_K = .775,
            DEFAULTS = {
                scaleX: 1,
                scaleY: 1
            },
            pathAttr = svgRendererModule._createPathAttr(vmlAttr),
            arcAttr = svgRendererModule._createArcAttr(vmlAttr, buildArcPath),
            rectAttr = svgRendererModule._createRectAttr(vmlAttr),
            applyEllipsis = svgRendererModule._getEllipsis(prepareLines, setNewText, removeTextSpan);

        function extend(a, b) {
            for (var key in b) {
                a[key] = b[key]
            }
            return a
        }

        function inArray(array, elem) {
            var i = 0;
            for (; i < array.length; i++) {
                if (elem === array[i]) {
                    return i
                }
            }
            return -1
        }

        function buildArcPath(x, y, innerR, outerR, startAngleCos, startAngleSin, endAngleCos, endAngleSin, isCircle, longFlag, noArc) {
            var xOuterStart = x + outerR * startAngleCos,
                yOuterStart = y - outerR * startAngleSin,
                xOuterEnd = x + outerR * endAngleCos,
                yOuterEnd = y - outerR * endAngleSin,
                xInnerStart = x + innerR * endAngleCos,
                yInnerStart = y - innerR * endAngleSin,
                xInnerEnd = x + innerR * startAngleCos,
                yInnerEnd = y - innerR * startAngleSin;
            return !noArc ? ["wr", mathFloor(x - innerR), mathFloor(y - innerR), mathFloor(x + innerR), mathFloor(y + innerR), mathFloor(xInnerStart), mathFloor(yInnerStart), mathFloor(xInnerEnd), mathFloor(yInnerEnd), isCircle ? "wr " : "at ", mathFloor(x - outerR), mathFloor(y - outerR), mathFloor(x + outerR), mathFloor(y + outerR), mathFloor(xOuterStart), mathFloor(yOuterStart), mathFloor(xOuterEnd), mathFloor(yOuterEnd), "x e"].join(" ") : "m 0 0 x e"
        }

        function getInheritSettings(settings) {
            var prop, value, result = {};
            for (prop in INHERITABLE_PROPERTIES) {
                value = settings[prop];
                void 0 !== value && (result[prop] = value)
            }
            return result
        }

        function correctBoundingRectWithStrokeWidth(rect, strokeWidth) {
            strokeWidth = Math.ceil(parseInt(strokeWidth) / 2);
            if (strokeWidth && strokeWidth > 1) {
                rect.left -= strokeWidth;
                rect.top -= strokeWidth;
                rect.right += strokeWidth;
                rect.bottom += strokeWidth
            }
            return rect
        }

        function shapeBBox() {
            var i, value, points = (this._settings.d || "").match(/[-0-9]+/g),
                resultRect = {};
            for (i = 0; i < points.length; i++) {
                value = parseInt(points[i]);
                if (i % 2) {
                    resultRect.top = void 0 === resultRect.top || value < resultRect.top ? value : resultRect.top;
                    resultRect.bottom = void 0 === resultRect.bottom || value > resultRect.bottom ? value : resultRect.bottom
                } else {
                    resultRect.left = void 0 === resultRect.left || value < resultRect.left ? value : resultRect.left;
                    resultRect.right = void 0 === resultRect.right || value > resultRect.right ? value : resultRect.right
                }
            }
            resultRect.left = resultRect.left || 0;
            resultRect.top = resultRect.top || 0;
            resultRect.right = resultRect.right || 0;
            resultRect.bottom = resultRect.bottom || 0;
            return correctBoundingRectWithStrokeWidth(resultRect, this._fullSettings[STROKEWIDTH])
        }

        function baseAttr(that, attrs, inh) {
            var value, key, appliedAttr, elem, element = that.element,
                settings = that._settings,
                fullSettings = that._fullSettings,
                params = {
                    style: {}
                };
            if ("string" === typeof attrs) {
                if (attrs in settings) {
                    return settings[attrs]
                }
                if (attrs in DEFAULTS) {
                    return DEFAULTS[attrs]
                }
                return 0
            }
            if (attrs && "transparent" === attrs.fill) {
                attrs.fill = "none"
            }
            for (key in attrs) {
                value = attrs[key];
                if (void 0 === value) {
                    continue
                }
                appliedAttr = fullSettings[key];
                !inh && (settings[key] = value);
                fullSettings[key] = value;
                if (INHERITABLE_PROPERTIES[key]) {
                    value = null === value ? that._parent && that._parent._fullSettings[key] || value : value
                }
                appliedAttr !== value && that.processAttr(element, key, value, params)
            }
            that._applyTransformation(params);
            that.css(params.style);
            for (var i = 0; i < that._children.length; i++) {
                elem = that._children[i];
                elem !== that._clipRect && elem.attr(extend(getInheritSettings(that._fullSettings), elem._settings), true);
                elem._applyStyleSheet()
            }!inh && that._applyStyleSheet();
            if (element) {
                if (element.strokecolor && "none" !== element.strokecolor.value && element.strokeweight) {
                    element.stroked = "t"
                } else {
                    element.stroked = "f"
                }
            }
            return that
        }

        function vmlAttr(that, attrs, inh) {
            var elem = that.element,
                result = baseAttr(that, attrs, inh);
            for (var i = 0; i < elem.childNodes.length; i++) {
                elem.childNodes[i].xmlns = XMLNS;
                elem.childNodes[i].style.behavior = "url(#default#VML)";
                elem.childNodes[i].style.display = "inline-block"
            }
            return result
        }

        function processVmlAttr(element, attr, value, params) {
            switch (attr) {
                case "stroke":
                    value = value || "none";
                    attr += "color";
                    break;
                case "fill":
                    value = value || "none";
                    element.filled = "none" === value ? "f" : "t";
                    attr += "color";
                    break;
                case STROKEWIDTH:
                    attr = "strokeweight";
                    value += "px";
                    break;
                case "stroke-linejoin":
                    element.stroke.joinstyle = value;
                    return;
                case "stroke-linecap":
                    element.stroke.endcap = "butt" === value ? "flat" : value;
                    return;
                case "opacity":
                    value = adjustOpacityValue(value);
                    element.fill.opacity = value;
                    element.stroke.opacity = value;
                    return;
                case "fill-opacity":
                    element.fill.opacity = adjustOpacityValue(value);
                    return;
                case "stroke-opacity":
                    element.stroke.opacity = adjustOpacityValue(value);
                    return;
                case "dashStyle":
                    if (null === value) {
                        element.stroke[attr] = ""
                    } else {
                        value = _normalizeEnum(value);
                        if ("solid" === value || "none" === value) {
                            value = ""
                        } else {
                            value = value.replace(/longdash/g, "8,3,").replace(/dash/g, "4,3,").replace(/dot/g, "1,3,").replace(/,$/, "")
                        }
                        element.stroke[attr] = value
                    }
                    return;
                case "d":
                    attr = "path";
                    value = _normalizeEnum(value).replace("z", "x e").replace(/([.]\d+)/g, "");
                    break;
                case "href":
                    attr = "src";
                    break;
                case "width":
                case "height":
                case "visibility":
                    params.style[attr] = value || "";
                    return;
                case "class":
                    attr += "Name";
                    break;
                case "translateX":
                case "translateY":
                case "rotate":
                case "rotateX":
                case "rotateY":
                case "scale":
                case "scaleX":
                case "scaleY":
                case "x":
                case "y":
                    return
            }
            element[attr] = value
        }

        function adjustOpacityValue(value) {
            return value >= .002 ? value : null === value ? 1 : .002
        }

        function createElement(tagName) {
            var element = document.createElement(tagName);
            return documentFragment.appendChild(element)
        }
        var VmlElement = function() {
            this.ctor.apply(this, arguments)
        };

        function processAttr(element, attr, value, params) {
            if (!INHERITABLE_PROPERTIES[attr]) {
                if ("visibility" === attr) {
                    params.style[attr] = value || ""
                } else {
                    if ("width" === attr || "height" === attr) {
                        params.style[attr] = value
                    } else {
                        if ("clipId" === attr) {
                            this.applyClipID(value)
                        } else {
                            if ("translateX" === attr || "translateY" === attr || "x" === attr || "y" === attr) {
                                return
                            } else {
                                if ("class" === attr) {
                                    element.className = value
                                } else {
                                    element[attr] = value
                                }
                            }
                        }
                    }
                }
            }
        }

        function prepareLines(element) {
            var lines = [{
                    commonLength: 0,
                    parts: []
                }],
                lineIndex = 0;
            _each(element.childNodes || [], function(i, text) {
                if ("BR" !== text.nodeName) {
                    var length = lines[lineIndex].commonLength,
                        textContent = $(text).text();
                    lines[lineIndex].parts.push({
                        span: text,
                        startIndex: length ? length + 1 : 0,
                        endIndex: length + textContent.length
                    });
                    lines[lineIndex].commonLength += textContent.length
                } else {
                    lines.push({
                        commonLength: 0,
                        parts: []
                    });
                    lineIndex++
                }
            });
            return lines
        }

        function setNewText(text, index) {
            var newText = $(text.span).text().substr(0, index) + "...";
            if ("#text" === text.span.nodeName) {
                text.span.data = newText
            } else {
                text.span.innerHTML = newText
            }
        }

        function removeTextSpan(text) {
            text.span.parentNode.removeChild(text.span)
        }
        var elementMixin = {
            div: {
                processAttr: processAttr,
                attr: function(attrs, inh) {
                    return baseAttr(this, attrs, inh)
                },
                _applyTransformation: function(params) {
                    var style = params.style,
                        settings = this._settings,
                        fullSettings = this._fullSettings;
                    if (fullSettings.rotate) {
                        fullSettings.rotateX = fullSettings.rotateX || 0;
                        fullSettings.rotateY = fullSettings.rotateY || 0
                    }
                    style.left = (settings.x || 0) + (settings.translateX || 0);
                    style.top = (settings.y || 0) + (settings.translateY || 0)
                },
                _getBBox: function() {
                    var child, translateX, translateY, childBBox, childSettings, left = 1 / 0,
                        top = 1 / 0,
                        right = -(1 / 0),
                        bottom = -(1 / 0),
                        i = 0,
                        children = this._children;
                    if (!children.length) {
                        left = top = bottom = right = 0
                    } else {
                        for (; i < children.length; i++) {
                            child = children[i];
                            if (child === this._clipRect) {
                                continue
                            }
                            translateX = child._fullSettings.translateX || 0;
                            translateY = child._fullSettings.translateY || 0;
                            childSettings = child._fullSettings;
                            childBBox = child._getBBox();
                            left = mathMin(left, childBBox.left + translateX);
                            right = mathMax(right, childBBox.right + translateX);
                            top = mathMin(top, childBBox.top + translateY);
                            bottom = mathMax(bottom, childBBox.bottom + translateY)
                        }
                    }
                    return {
                        left: left,
                        right: right,
                        top: top,
                        bottom: bottom
                    }
                },
                defaultAttrs: {},
                defaultStyle: {
                    position: "absolute"
                }
            },
            shape: {
                defaultAttrs: extend({
                    coordsize: "1,1",
                    "stroke-linejoin": "miter"
                }, DEFAULT_ATTRS),
                defaultStyle: extend({
                    width: 1,
                    height: 1
                }, DEFAULT_STYLE),
                _getBBox: shapeBBox
            },
            image: {
                processAttr: function(element, attr, value, params) {
                    if ("fill" === attr || "stroke" === attr) {
                        return
                    }
                    processVmlAttr(element, attr, value, params)
                }
            },
            oval: {
                processAttr: function(element, attr, value, params) {
                    if ("cx" === attr || "cy" === attr) {
                        attr = attr[1]
                    } else {
                        if ("r" === attr) {
                            value *= 2;
                            processVmlAttr(element, "width", value, params);
                            attr = "height"
                        } else {
                            if ("x" === attr || "y" === attr) {
                                return
                            }
                        }
                    }
                    processVmlAttr(element, attr, value, params)
                },
                _getBBox: function() {
                    var settings = this._fullSettings,
                        x = settings.cx || 0,
                        y = settings.cy || 0,
                        r = settings.r || 0;
                    return correctBoundingRectWithStrokeWidth({
                        left: x - r,
                        top: y - r,
                        right: x + r,
                        bottom: y + r
                    }, settings[STROKEWIDTH] || 1)
                }
            },
            span: {
                defaultAttrs: {},
                defaultStyle: {
                    position: "absolute",
                    whiteSpace: "nowrap"
                },
                processAttr: function(element, attr, value, params) {
                    if ("text" === attr) {
                        value = isDefined(value) ? value.toString().replace(/\r/g, "") : "";
                        if (this.renderer.encodeHtml) {
                            value = value.replace(/</g, "&lt;").replace(/>/g, "&gt;")
                        }
                        element.innerHTML = value.replace(/\n/g, "<br/>");
                        this.css({
                            filter: ""
                        });
                        this._bbox = null
                    } else {
                        processAttr(element, attr, value, params)
                    }
                },
                attr: function(attrs, inh) {
                    return baseAttr(this, attrs, inh)
                },
                applyEllipsis: applyEllipsis,
                _applyTransformation: function(params) {
                    this.element.offsetHeight;
                    var radianAngle, that = this,
                        style = params.style,
                        settings = that._fullSettings,
                        x = isDefined(settings.x) ? settings.x : 0,
                        y = isDefined(settings.y) ? settings.y : 0,
                        bbox = that._bbox || that.element.getBoundingClientRect(),
                        textHeight = bbox.bottom - bbox.top,
                        textWidth = bbox.right - bbox.left,
                        rotateAngle = settings.rotate,
                        cos = 1,
                        sin = 0,
                        rotateX = isDefined(settings.rotateX) ? settings.rotateX : x,
                        rotateY = isDefined(settings.rotateY) ? settings.rotateY : y,
                        marginLeft = 0,
                        marginTop = 0,
                        fontHeightOffset = textHeight * FONT_HEIGHT_OFFSET_K,
                        filter = "",
                        alignMultiplier = {
                            center: .5,
                            right: 1
                        }[settings.align],
                        opacity = this._styles.opacity || settings.opacity || settings["fill-opacity"];
                    if (textHeight && textWidth) {
                        if (rotateAngle) {
                            radianAngle = rotateAngle * Math.PI / 180;
                            cos = mathCos(radianAngle);
                            sin = mathSin(radianAngle);
                            marginLeft = (x - rotateX) * cos - (y - rotateY) * sin + rotateX - x;
                            marginTop = (x - rotateX) * sin + (y - rotateY) * cos + rotateY - y;
                            filter = "progid:DXImageTransform.Microsoft.Matrix(sizingMethod='auto expand', M11 = " + cos.toFixed(5) + ", M12 = " + (-sin).toFixed(5) + ", M21 = " + sin.toFixed(5) + ", M22 = " + cos.toFixed(5) + ")"
                        }
                        if (rotateAngle < 90) {
                            marginTop -= fontHeightOffset * cos;
                            marginLeft -= (textHeight - fontHeightOffset) * sin
                        } else {
                            if (rotateAngle < 180) {
                                marginTop += (textHeight - fontHeightOffset) * cos;
                                marginLeft += textWidth * cos - (textHeight - fontHeightOffset) * sin
                            } else {
                                if (rotateAngle < 270) {
                                    marginTop += (textHeight - fontHeightOffset) * cos + textWidth * sin;
                                    marginLeft += textWidth * cos + fontHeightOffset * sin
                                } else {
                                    marginTop += textWidth * sin - fontHeightOffset * cos;
                                    marginLeft += fontHeightOffset * sin
                                }
                            }
                        }
                        if (rotateAngle && this.renderer.rtl) {
                            marginLeft -= textWidth - (textHeight * Math.abs(sin) + textWidth * Math.abs(cos))
                        }
                        if (alignMultiplier) {
                            marginLeft -= textWidth * alignMultiplier * cos;
                            marginTop -= textWidth * alignMultiplier * sin
                        }
                        if (isDefined(opacity)) {
                            filter += " progid:DXImageTransform.Microsoft.Alpha(Opacity=" + 100 * opacity + ")"
                        }
                        x += marginLeft;
                        y += marginTop;
                        this._bbox = bbox;
                        style.filter = (style.filter || "") + filter;
                        style.left = x + (settings.translateX || 0);
                        style.top = y + (settings.translateY || 0)
                    }
                },
                _getBBox: function() {
                    var element = this.element,
                        settings = this._fullSettings,
                        parentRect = (element.parentNode && element.parentNode.getBoundingClientRect ? element.parentNode : this.renderer.root.element).getBoundingClientRect(),
                        boundingRect = element.getBoundingClientRect(),
                        left = boundingRect.left - (settings.translateX || 0) - parentRect.left,
                        top = boundingRect.top - (settings.translateY || 0) - parentRect.top;
                    return {
                        left: left,
                        top: top,
                        right: left + element.offsetWidth,
                        bottom: top + element.offsetHeight
                    }
                }
            }
        };
        extend(VmlElement.prototype, baseElementPrototype);
        extend(VmlElement.prototype, {
            defaultStyle: DEFAULT_STYLE,
            defaultAttrs: DEFAULT_ATTRS,
            ctor: function(renderer, tagName, type) {
                var that = this,
                    tagPrefix = "<";
                that.renderer = renderer;
                that.type = type || "line";
                that._children = [];
                that._settings = {};
                that._fullSettings = {};
                that._styles = {};
                if ("div" !== tagName && "span" !== tagName) {
                    tagPrefix = "<vml:"
                }
                if ("shape" === tagName) {
                    if ("arc" === that.type) {
                        that.attr = arcAttr
                    } else {
                        that.attr = pathAttr
                    }
                } else {
                    if ("rect" === tagName) {
                        that.attr = rectAttr
                    }
                }
                extend(that, elementMixin[tagName]);
                that.element = createElement(tagPrefix + tagName + "/>");
                that.css(that.defaultStyle).attr(that.defaultAttrs);
                that._$element = $(that.element)
            },
            dispose: function() {
                this.remove();
                this._$element.remove();
                return this
            },
            attr: function(attrs, inh) {
                return vmlAttr(this, attrs, inh)
            },
            processAttr: processVmlAttr,
            css: function(css) {
                var value, appliedValue, key, elem = this.element;
                for (key in css) {
                    appliedValue = this._styles[key];
                    value = css[key];
                    if (!isDefined(value)) {
                        continue
                    }
                    this._styles[key] = value;
                    if (appliedValue === value) {
                        continue
                    }
                    switch (key) {
                        case "fill":
                            key = "color";
                            break;
                        case "font-size":
                            key = "fontSize";
                            if ("number" === typeof value) {
                                value += "px"
                            }
                            break;
                        case "font-weight":
                            key = "fontWeight";
                            break;
                        case "z-index":
                            key = "zIndex";
                            break;
                        case "opacity":
                            continue
                    }
                    try {
                        elem.style[key] = value
                    } catch (_) {
                        continue
                    }
                }
                return this
            },
            applyClipID: function(id) {
                var clipRect, cssValue, renderer = this.renderer;
                clipRect = renderer.getClipRect(id);
                if (clipRect) {
                    cssValue = clipRect.getValue();
                    clipRect.addElement(this)
                } else {
                    cssValue = "rect(-9999px 9999px 9999px -9999px)"
                }
                this._clipRect = this._clipRect || renderer.rect(0, 0, 0, 0).attr({
                    "class": "dxc-vml-clip",
                    fill: "none",
                    opacity: .001
                });
                this._clipRect.attr({
                    width: renderer.root.attr("width"),
                    height: renderer.root.attr("height")
                });
                this.css({
                    clip: cssValue,
                    width: renderer.root.attr("width"),
                    height: renderer.root.attr("height")
                })
            },
            _onAppended: function(parent) {
                var that = this;
                if (parent._children) {
                    that._parent = parent;
                    if (inArray(parent._children, that) === -1) {
                        parent._children.push(that)
                    }
                    that.attr(extend(getInheritSettings(parent._fullSettings), that._settings), true)
                }
                that._applyStyleSheet();
                if (parent._clipRect && that !== parent._clipRect) {
                    parent._clipRect.append(parent)
                }
            },
            append: function(parent) {
                baseElementPrototype.append.apply(this, arguments);
                this._onAppended(parent || this.renderer.root);
                return this
            },
            _insert: function(parent) {
                baseElementPrototype._insert.apply(this, arguments);
                this._onAppended(parent)
            },
            _applyTransformation: function(params) {
                var that = this,
                    style = params.style,
                    element = that.element,
                    settings = that._fullSettings,
                    x = "arc" !== that.type ? settings.x || settings.cx - settings.r || 0 : 0,
                    y = "arc" !== that.type ? settings.y || settings.cy - settings.r || 0 : 0;
                if (settings.rotate) {
                    var radianAngle = settings.rotate * Math.PI / 180,
                        rotateX = isDefined(settings.rotateX) ? settings.rotateX : x,
                        rotateY = isDefined(settings.rotateY) ? settings.rotateY : y,
                        rx = x + (settings.width || 0 || parseInt(element.style.width || 0)) / 2,
                        ry = y + (settings.height || 0 || parseInt(element.style.height || 0)) / 2,
                        cos = mathCos(radianAngle),
                        sin = mathSin(radianAngle),
                        marginLeft = (rx - rotateX) * cos - (ry - rotateY) * sin + rotateX - rx,
                        marginTop = (rx - rotateX) * sin + (ry - rotateY) * cos + rotateY - ry;
                    x += marginLeft;
                    y += marginTop;
                    style.rotation = settings.rotate
                }
                style.left = x + (settings.translateX || 0);
                style.top = y + (settings.translateY || 0)
            },
            remove: function() {
                var parent = this._parent;
                parent && parent._children.splice(inArray(parent._children, this), 1);
                this._parent = null;
                return baseElementPrototype.remove.apply(this, arguments)
            },
            clear: function() {
                this._children = [];
                return baseElementPrototype.clear.apply(this, arguments)
            },
            getBBox: function() {
                var clientRect = this._getBBox(),
                    x = clientRect.left,
                    y = clientRect.top,
                    width = clientRect.right - x,
                    height = clientRect.bottom - y;
                return {
                    x: x,
                    y: y,
                    width: width,
                    height: height,
                    isEmpty: !x && !y && !width && !height
                }
            },
            _getBBox: function() {
                var element = this.element,
                    settings = this._fullSettings,
                    x = settings.x || 0,
                    y = settings.y || 0,
                    width = parseInt(element.style.width || 0),
                    height = parseInt(element.style.height || 0);
                return correctBoundingRectWithStrokeWidth({
                    left: x,
                    top: y,
                    right: x + width,
                    bottom: y + height
                }, settings[STROKEWIDTH] || 1)
            },
            _applyStyleSheet: function() {
                if (this._useCSSTheme) {
                    this.attr(getInheritSettings(this.element.currentStyle), true)
                }
            },
            setTitle: function(text) {
                this.element.setAttribute("title", text)
            }
        });
        var ClipRect = function() {
            this.ctor.apply(this, arguments)
        };
        extend(ClipRect.prototype, VmlElement.prototype);
        extend(ClipRect.prototype, {
            ctor: function(renderer, id) {
                this._settings = this._fullSettings = {};
                this.renderer = renderer;
                this._children = [];
                this._elements = [];
                this.id = id
            },
            attr: function(attrs, inh) {
                var element, i, result = baseAttr(this, attrs, inh),
                    elements = this._elements.slice();
                if (result === this) {
                    for (i = 0; i < elements.length; i++) {
                        element = elements[i];
                        if (element._fullSettings.clipId === this.id) {
                            elements[i].applyClipID(this.id)
                        } else {
                            this.removeElement(element)
                        }
                    }
                }
                return result
            },
            processAttr: stub,
            _applyTransformation: stub,
            append: stubReturnedThis,
            dispose: function() {
                this._elements = null;
                this.renderer.removeClipRect(this.id);
                return this
            },
            addElement: function(element) {
                var elements = this._elements;
                if (inArray(elements, element) === -1) {
                    elements.push(element)
                }
            },
            removeElement: function(element) {
                var index = inArray(this._elements, element);
                index > -1 && this._elements.splice(index, 1)
            },
            getValue: function() {
                var settings = this._settings,
                    left = (settings.x || 0) + (settings.translateX || 0),
                    top = (settings.y || 0) + (settings.translateY || 0);
                return "rect(" + top + "px, " + (left + (settings.width || 0)) + "px, " + (top + (settings.height || 0)) + "px, " + left + "px)"
            },
            css: stubReturnedThis,
            remove: stubReturnedThis
        });

        function VmlRenderer() {
            svgRendererModule.SvgRenderer.apply(this, arguments)
        }
        extend(VmlRenderer.prototype, svgRendererModule.SvgRenderer.prototype);
        extend(VmlRenderer.prototype, {
            constructor: VmlRenderer,
            _rootTag: "div",
            _rootAttr: {
                fill: "none",
                stroke: "none",
                "stroke-width": 0
            },
            _rootCss: {
                position: "relative",
                display: "inline-block",
                overflow: "hidden"
            },
            _init: function() {
                this._clipRects = [];
                this._animationController = {
                    dispose: stubReturnedThis
                };
                this._animation = {
                    enabled: false
                };
                this._defs = {
                    clear: stubReturnedThis,
                    remove: stubReturnedThis,
                    append: stubReturnedThis,
                    dispose: stubReturnedThis
                }
            },
            setOptions: function() {
                svgRendererModule.SvgRenderer.prototype.setOptions.apply(this, arguments);
                this.root.css({
                    direction: this.rtl ? "rtl" : "ltr"
                });
                return this
            },
            _createElement: function(tagName, attr, type) {
                tagName = svgToVmlConv[tagName] || tagName;
                var elem = new exports.VmlElement(this, tagName, type);
                attr && elem.attr(attr);
                return elem
            },
            shadowFilter: function() {
                return {
                    ref: null,
                    append: stubReturnedThis,
                    dispose: stubReturnedThis,
                    attr: stubReturnedThis,
                    css: stubReturnedThis
                }
            },
            clipRect: function(x, y, width, height) {
                var clipRects = this._clipRects,
                    id = clipRects.length,
                    clipRect = new ClipRect(this, id).attr({
                        x: x || 0,
                        y: y || 0,
                        width: width || 0,
                        height: height || 0
                    });
                clipRects.push(clipRect);
                return clipRect
            },
            getClipRect: function(id) {
                return this._clipRects[id]
            },
            removeClipRect: function(id) {
                delete this._clipRects[id]
            },
            pattern: function(color) {
                return {
                    id: color,
                    append: stubReturnedThis,
                    remove: stubReturnedThis,
                    dispose: stubReturnedThis
                }
            },
            image: function(x, y, w, h, href, location) {
                var image = this._createElement("image", {
                    x: x || 0,
                    y: y || 0,
                    width: w || 0,
                    height: h || 0,
                    location: location,
                    href: href
                });
                return image
            },
            rect: function(x, y, width, height) {
                return this._createElement("rect", {
                    x: x || 0,
                    y: y || 0,
                    width: width || 0,
                    height: height || 0
                })
            },
            path: function(points, type) {
                return this._createElement("path", {
                    points: points || []
                }, type)
            },
            arc: function(x, y, innerRadius, outerRadius, startAngle, endAngle) {
                return this._createElement("path", {
                    x: x || 0,
                    y: y || 0,
                    innerRadius: innerRadius || 0,
                    outerRadius: outerRadius || 0,
                    startAngle: startAngle || 0,
                    endAngle: endAngle || 0
                }, "arc")
            },
            text: function(text, x, y) {
                return this._createElement("text", {
                    text: text,
                    x: x || 0,
                    y: y || 0
                })
            },
            updateAnimationOptions: stubReturnedThis,
            stopAllAnimations: stubReturnedThis,
            svg: function() {
                return ""
            },
            onEndAnimation: function(callback) {
                callback()
            }
        });
        exports.VmlRenderer = VmlRenderer;
        exports.VmlElement = VmlElement;
        exports._VmlClipRect = ClipRect
    },
    /*!****************************************************!*\
      !*** ./Scripts/viz/core/renderers/svg_renderer.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            doc = document,
            animation = __webpack_require__( /*! ./animation */ 454),
            math = Math,
            mathMin = math.min,
            mathMax = math.max,
            mathFloor = math.floor,
            mathRound = math.round,
            mathSin = math.sin,
            mathCos = math.cos,
            mathAbs = math.abs,
            mathPI = math.PI,
            _isDefined = commonUtils.isDefined,
            vizUtils = __webpack_require__( /*! ../utils */ 442),
            _normalizeEnum = vizUtils.normalizeEnum,
            _normalizeBBox = vizUtils.normalizeBBox,
            _rotateBBox = vizUtils.rotateBBox,
            PI_DIV_180 = mathPI / 180,
            _parseInt = parseInt,
            SHARPING_CORRECTION = .5,
            ARC_COORD_PREC = 5;
        var pxAddingExceptions = {
            "column-count": true,
            "fill-opacity": true,
            "flex-grow": true,
            "flex-shrink": true,
            "font-weight": true,
            "line-height": true,
            opacity: true,
            order: true,
            orphans: true,
            widows: true,
            "z-index": true,
            zoom: true
        };
        var KEY_TEXT = "text",
            KEY_STROKE = "stroke",
            KEY_STROKE_WIDTH = "stroke-width",
            KEY_STROKE_OPACITY = "stroke-opacity",
            KEY_FONT_SIZE = "font-size",
            KEY_FONT_STYLE = "font-style",
            KEY_FONT_WEIGHT = "font-weight",
            KEY_TEXT_DECORATION = "text-decoration",
            NONE = "none";
        var objectCreate = function() {
            if (!Object.create) {
                return function(proto) {
                    var F = function() {};
                    F.prototype = proto;
                    return new F
                }
            } else {
                return function(proto) {
                    return Object.create(proto)
                }
            }
        }();
        var DEFAULTS = {
            scaleX: 1,
            scaleY: 1
        };
        var backupContainer = doc.createElement("div"),
            backupCounter = 0;
        backupContainer.style.left = "-9999px";
        backupContainer.style.position = "absolute";

        function backupRoot(root) {
            if (0 === backupCounter) {
                doc.body.appendChild(backupContainer)
            }++backupCounter;
            root.append({
                element: backupContainer
            })
        }

        function restoreRoot(root, container) {
            root.append({
                element: container
            });
            --backupCounter;
            if (0 === backupCounter) {
                doc.body.removeChild(backupContainer)
            }
        }
        var getNextDefsSvgId = function() {
            var numDefsSvgElements = 1;
            return function() {
                return "DevExpress_" + numDefsSvgElements++
            }
        }();

        function isObjectArgument(value) {
            return value && "string" !== typeof value
        }

        function createElement(tagName) {
            return doc.createElementNS("http://www.w3.org/2000/svg", tagName)
        }

        function getPatternUrl(id, pathModified) {
            return null !== id ? "url(" + (pathModified ? window.location.href : "") + "#" + id + ")" : ""
        }

        function extend(target, source) {
            var key;
            for (key in source) {
                target[key] = source[key]
            }
            return target
        }

        function roundValue(value, exp) {
            value = value.toString().split("e");
            value = mathRound(+(value[0] + "e" + (value[1] ? +value[1] + exp : exp)));
            value = value.toString().split("e");
            return +(value[0] + "e" + (value[1] ? +value[1] - exp : -exp))
        }
        var preserveAspectRatioMap = {
            full: NONE,
            lefttop: "xMinYMin",
            leftcenter: "xMinYMid",
            leftbottom: "xMinYMax",
            centertop: "xMidYMin",
            center: "xMidYMid",
            centerbottom: "xMidYMax",
            righttop: "xMaxYMin",
            rightcenter: "xMaxYMid",
            rightbottom: "xMaxYMax"
        };
        exports._normalizeArcParams = function(x, y, innerR, outerR, startAngle, endAngle) {
            var isCircle, noArc = true,
                angleDiff = roundValue(endAngle, 3) - roundValue(startAngle, 3);
            if (angleDiff) {
                if (mathAbs(angleDiff) % 360 === 0) {
                    startAngle = 0;
                    endAngle = 360;
                    isCircle = true;
                    endAngle -= .01
                }
                if (startAngle > 360) {
                    startAngle %= 360
                }
                if (endAngle > 360) {
                    endAngle %= 360
                }
                if (startAngle > endAngle) {
                    startAngle -= 360
                }
                noArc = false
            }
            startAngle *= PI_DIV_180;
            endAngle *= PI_DIV_180;
            return [x, y, mathMin(outerR, innerR), mathMax(outerR, innerR), mathCos(startAngle), mathSin(startAngle), mathCos(endAngle), mathSin(endAngle), isCircle, mathFloor(mathAbs(endAngle - startAngle) / mathPI) % 2 ? "1" : "0", noArc]
        };
        var applyEllipsis = getEllipsis(prepareLines, setNewText, removeTextSpan);
        var buildArcPath = function(x, y, innerR, outerR, startAngleCos, startAngleSin, endAngleCos, endAngleSin, isCircle, longFlag) {
            return ["M", (x + outerR * startAngleCos).toFixed(ARC_COORD_PREC), (y - outerR * startAngleSin).toFixed(ARC_COORD_PREC), "A", outerR.toFixed(ARC_COORD_PREC), outerR.toFixed(ARC_COORD_PREC), 0, longFlag, 0, (x + outerR * endAngleCos).toFixed(ARC_COORD_PREC), (y - outerR * endAngleSin).toFixed(ARC_COORD_PREC), isCircle ? "M" : "L", (x + innerR * endAngleCos).toFixed(5), (y - innerR * endAngleSin).toFixed(ARC_COORD_PREC), "A", innerR.toFixed(ARC_COORD_PREC), innerR.toFixed(ARC_COORD_PREC), 0, longFlag, 1, (x + innerR * startAngleCos).toFixed(ARC_COORD_PREC), (y - innerR * startAngleSin).toFixed(ARC_COORD_PREC), "Z"].join(" ")
        };

        function buildPathSegments(points, type) {
            var list = [
                ["M", 0, 0]
            ];
            switch (type) {
                case "line":
                    list = buildLineSegments(points);
                    break;
                case "area":
                    list = buildLineSegments(points, true);
                    break;
                case "bezier":
                    list = buildCurveSegments(points);
                    break;
                case "bezierarea":
                    list = buildCurveSegments(points, true)
            }
            return list
        }

        function buildLineSegments(points, close) {
            return buildSegments(points, buildSimpleLineSegment, close)
        }

        function buildCurveSegments(points, close) {
            return buildSegments(points, buildSimpleCurveSegment, close)
        }

        function buildSegments(points, buildSimpleSegment, close) {
            var i, ii, list = [];
            if (points[0] && points[0].length) {
                for (i = 0, ii = points.length; i < ii; ++i) {
                    buildSimpleSegment(points[i], close, list)
                }
            } else {
                buildSimpleSegment(points, close, list)
            }
            return list
        }

        function buildSimpleLineSegment(points, close, list) {
            var i = 0,
                k0 = list.length,
                k = k0,
                ii = (points || []).length;
            if (ii) {
                if (void 0 !== points[0].x) {
                    for (; i < ii;) {
                        list[k++] = ["L", points[i].x, points[i++].y]
                    }
                } else {
                    for (; i < ii;) {
                        list[k++] = ["L", points[i++], points[i++]]
                    }
                }
                list[k0][0] = "M"
            } else {
                list[k] = ["M", 0, 0]
            }
            close && list.push(["Z"]);
            return list
        }

        function buildSimpleCurveSegment(points, close, list) {
            var i, k = list.length,
                ii = (points || []).length;
            if (ii) {
                if (void 0 !== points[0].x) {
                    list[k++] = ["M", points[0].x, points[0].y];
                    for (i = 1; i < ii;) {
                        list[k++] = ["C", points[i].x, points[i++].y, points[i].x, points[i++].y, points[i].x, points[i++].y]
                    }
                } else {
                    list[k++] = ["M", points[0], points[1]];
                    for (i = 2; i < ii;) {
                        list[k++] = ["C", points[i++], points[i++], points[i++], points[i++], points[i++], points[i++]]
                    }
                }
            } else {
                list[k] = ["M", 0, 0]
            }
            close && list.push(["Z"]);
            return list
        }

        function combinePathParam(segments) {
            var i, segment, j, jj, d = [],
                k = 0,
                ii = segments.length;
            for (i = 0; i < ii; ++i) {
                segment = segments[i];
                for (j = 0, jj = segment.length; j < jj; ++j) {
                    d[k++] = segment[j]
                }
            }
            return d.join(" ")
        }

        function compensateSegments(oldSegments, newSegments, type) {
            var i, originalNewSegments, oldLength = oldSegments.length,
                newLength = newSegments.length,
                makeEqualSegments = type.indexOf("area") !== -1 ? makeEqualAreaSegments : makeEqualLineSegments;
            if (0 === oldLength) {
                for (i = 0; i < newLength; i++) {
                    oldSegments.push(newSegments[i].slice(0))
                }
            } else {
                if (oldLength < newLength) {
                    makeEqualSegments(oldSegments, newSegments, type)
                } else {
                    if (oldLength > newLength) {
                        originalNewSegments = newSegments.slice(0);
                        makeEqualSegments(newSegments, oldSegments, type)
                    }
                }
            }
            return originalNewSegments
        }

        function prepareConstSegment(constSeg, type) {
            var x = constSeg[constSeg.length - 2],
                y = constSeg[constSeg.length - 1];
            switch (type) {
                case "line":
                case "area":
                    constSeg[0] = "L";
                    break;
                case "bezier":
                case "bezierarea":
                    constSeg[0] = "C";
                    constSeg[1] = constSeg[3] = constSeg[5] = x;
                    constSeg[2] = constSeg[4] = constSeg[6] = y
            }
        }

        function makeEqualLineSegments(short, long, type) {
            var constSeg = short[short.length - 1].slice(),
                i = short.length;
            prepareConstSegment(constSeg, type);
            for (; i < long.length; i++) {
                short[i] = constSeg.slice(0)
            }
        }

        function makeEqualAreaSegments(short, long, type) {
            var i, head, constsSeg1, constsSeg2, shortLength = short.length,
                longLength = long.length;
            if ((shortLength - 1) % 2 === 0 && (longLength - 1) % 2 === 0) {
                i = (shortLength - 1) / 2 - 1;
                head = short.slice(0, i + 1);
                constsSeg1 = head[head.length - 1].slice(0);
                constsSeg2 = short.slice(i + 1)[0].slice(0);
                prepareConstSegment(constsSeg1, type);
                prepareConstSegment(constsSeg2, type);
                for (var j = i; j < (longLength - 1) / 2 - 1; j++) {
                    short.splice(j + 1, 0, constsSeg1);
                    short.splice(j + 3, 0, constsSeg2)
                }
            }
        }

        function baseCss(that, styles) {
            var key, value, elemStyles = that._styles,
                str = "";
            styles = styles || {};
            for (key in styles) {
                value = styles[key];
                if (_isDefined(value)) {
                    if ("number" === typeof value && !pxAddingExceptions[key]) {
                        value += "px"
                    }
                    elemStyles[key] = "" !== value ? value : null
                }
            }
            for (key in elemStyles) {
                value = elemStyles[key];
                if (value) {
                    str += key + ":" + value + ";"
                }
            }
            str && that.element.setAttribute("style", str);
            return that
        }

        function baseAttr(that, attrs, inh) {
            attrs = attrs || {};
            var key, value, hasTransformations, recalculateDashStyle, sw, i, settings = that._settings,
                attributes = {},
                elem = that.element,
                renderer = that.renderer,
                rtl = renderer.rtl;
            if (!isObjectArgument(attrs)) {
                if (attrs in settings) {
                    return settings[attrs]
                }
                if (attrs in DEFAULTS) {
                    return DEFAULTS[attrs]
                }
                return 0
            }
            extend(attributes, attrs);
            for (key in attributes) {
                value = attributes[key];
                if (void 0 === value) {
                    continue
                }
                settings[key] = value;
                if ("align" === key) {
                    key = "text-anchor";
                    value = {
                        left: rtl ? "end" : "start",
                        center: "middle",
                        right: rtl ? "start" : "end"
                    }[value] || ""
                } else {
                    if ("dashStyle" === key) {
                        recalculateDashStyle = true;
                        continue
                    } else {
                        if (key === KEY_STROKE_WIDTH) {
                            recalculateDashStyle = true
                        } else {
                            if ("clipId" === key) {
                                key = "clip-path";
                                value = getPatternUrl(value, renderer.pathModified)
                            } else {
                                if (/^(translate(X|Y)|rotate[XY]?|scale(X|Y)|sharp)$/i.test(key)) {
                                    hasTransformations = true;
                                    continue
                                } else {
                                    if (/^(x|y|d)$/i.test(key)) {
                                        hasTransformations = true
                                    }
                                }
                            }
                        }
                    }
                }
                if (null === value) {
                    elem.removeAttribute(key)
                } else {
                    elem.setAttribute(key, value)
                }
            }
            if (recalculateDashStyle && "dashStyle" in settings) {
                value = settings.dashStyle;
                sw = ("_originalSW" in that ? that._originalSW : settings[KEY_STROKE_WIDTH]) || 1;
                key = "stroke-dasharray";
                value = null === value ? "" : _normalizeEnum(value);
                if ("" === value || "solid" === value || value === NONE) {
                    that.element.removeAttribute(key)
                } else {
                    value = value.replace(/longdash/g, "8,3,").replace(/dash/g, "4,3,").replace(/dot/g, "1,3,").replace(/,$/, "").split(",");
                    i = value.length;
                    while (i--) {
                        value[i] = _parseInt(value[i]) * sw
                    }
                    that.element.setAttribute(key, value.join(","))
                }
            }
            if (hasTransformations) {
                that._applyTransformation()
            }
            return that
        }

        function createPathAttr(baseAttr) {
            return function(attrs, inh) {
                var segments, that = this;
                if (isObjectArgument(attrs)) {
                    attrs = extend({}, attrs);
                    segments = attrs.segments;
                    if ("points" in attrs) {
                        segments = buildPathSegments(attrs.points, that.type);
                        delete attrs.points
                    }
                    if (segments) {
                        attrs.d = combinePathParam(segments);
                        that.segments = segments;
                        delete attrs.segments
                    }
                }
                return baseAttr(that, attrs, inh)
            }
        }

        function createArcAttr(baseAttr, buildArcPath) {
            return function(attrs, inh) {
                var x, y, innerRadius, outerRadius, startAngle, endAngle, settings = this._settings;
                if (isObjectArgument(attrs)) {
                    attrs = extend({}, attrs);
                    if ("x" in attrs || "y" in attrs || "innerRadius" in attrs || "outerRadius" in attrs || "startAngle" in attrs || "endAngle" in attrs) {
                        settings.x = x = "x" in attrs ? attrs.x : settings.x;
                        delete attrs.x;
                        settings.y = y = "y" in attrs ? attrs.y : settings.y;
                        delete attrs.y;
                        settings.innerRadius = innerRadius = "innerRadius" in attrs ? attrs.innerRadius : settings.innerRadius;
                        delete attrs.innerRadius;
                        settings.outerRadius = outerRadius = "outerRadius" in attrs ? attrs.outerRadius : settings.outerRadius;
                        delete attrs.outerRadius;
                        settings.startAngle = startAngle = "startAngle" in attrs ? attrs.startAngle : settings.startAngle;
                        delete attrs.startAngle;
                        settings.endAngle = endAngle = "endAngle" in attrs ? attrs.endAngle : settings.endAngle;
                        delete attrs.endAngle;
                        attrs.d = buildArcPath.apply(null, exports._normalizeArcParams(x, y, innerRadius, outerRadius, startAngle, endAngle))
                    }
                }
                return baseAttr(this, attrs, inh)
            }
        }

        function createRectAttr(baseAttr) {
            return function(attrs, inh) {
                var x, y, width, height, sw, maxSW, newSW, that = this;
                if (isObjectArgument(attrs)) {
                    attrs = extend({}, attrs);
                    if (!inh && (void 0 !== attrs.x || void 0 !== attrs.y || void 0 !== attrs.width || void 0 !== attrs.height || void 0 !== attrs[KEY_STROKE_WIDTH])) {
                        void 0 !== attrs.x ? x = that._originalX = attrs.x : x = that._originalX || 0;
                        void 0 !== attrs.y ? y = that._originalY = attrs.y : y = that._originalY || 0;
                        void 0 !== attrs.width ? width = that._originalWidth = attrs.width : width = that._originalWidth || 0;
                        void 0 !== attrs.height ? height = that._originalHeight = attrs.height : height = that._originalHeight || 0;
                        void 0 !== attrs[KEY_STROKE_WIDTH] ? sw = that._originalSW = attrs[KEY_STROKE_WIDTH] : sw = that._originalSW;
                        maxSW = ~~((width < height ? width : height) / 2);
                        newSW = (sw || 0) < maxSW ? sw || 0 : maxSW;
                        attrs.x = x + newSW / 2;
                        attrs.y = y + newSW / 2;
                        attrs.width = width - newSW;
                        attrs.height = height - newSW;
                        ((sw || 0) !== newSW || !(0 === newSW && void 0 === sw)) && (attrs[KEY_STROKE_WIDTH] = newSW)
                    }
                    if ("sharp" in attrs) {
                        delete attrs.sharp
                    }
                }
                return baseAttr(that, attrs, inh)
            }
        }
        var pathAttr = createPathAttr(baseAttr),
            arcAttr = createArcAttr(baseAttr, buildArcPath),
            rectAttr = createRectAttr(baseAttr);

        function textAttr(attrs) {
            var settings, isResetRequired, wasStroked, isStroked, that = this;
            if (!isObjectArgument(attrs)) {
                return baseAttr(that, attrs)
            }
            attrs = extend({}, attrs);
            settings = that._settings;
            wasStroked = _isDefined(settings[KEY_STROKE]) && _isDefined(settings[KEY_STROKE_WIDTH]);
            if (void 0 !== attrs[KEY_TEXT]) {
                settings[KEY_TEXT] = attrs[KEY_TEXT];
                delete attrs[KEY_TEXT];
                isResetRequired = true
            }
            if (void 0 !== attrs[KEY_STROKE]) {
                settings[KEY_STROKE] = attrs[KEY_STROKE];
                delete attrs[KEY_STROKE]
            }
            if (void 0 !== attrs[KEY_STROKE_WIDTH]) {
                settings[KEY_STROKE_WIDTH] = attrs[KEY_STROKE_WIDTH];
                delete attrs[KEY_STROKE_WIDTH]
            }
            if (void 0 !== attrs[KEY_STROKE_OPACITY]) {
                settings[KEY_STROKE_OPACITY] = attrs[KEY_STROKE_OPACITY];
                delete attrs[KEY_STROKE_OPACITY]
            }
            isStroked = _isDefined(settings[KEY_STROKE]) && _isDefined(settings[KEY_STROKE_WIDTH]);
            baseAttr(that, attrs);
            isResetRequired = isResetRequired || isStroked !== wasStroked && settings[KEY_TEXT];
            if (isResetRequired) {
                createTextNodes(that, settings.text, isStroked)
            }
            if (isResetRequired || void 0 !== attrs.x || void 0 !== attrs.y) {
                locateTextNodes(that)
            }
            if (isStroked) {
                strokeTextNodes(that)
            }
            return that
        }

        function textCss(styles) {
            styles = styles || {};
            baseCss(this, styles);
            if (KEY_FONT_SIZE in styles) {
                locateTextNodes(this)
            }
            return this
        }

        function orderHtmlTree(list, line, node, parentStyle, parentClassName) {
            var style, realStyle, i, ii, nodes;
            if (void 0 !== node.wholeText) {
                list.push({
                    value: node.wholeText,
                    style: parentStyle,
                    className: parentClassName,
                    line: line,
                    height: parentStyle[KEY_FONT_SIZE] || 0
                })
            } else {
                if ("BR" === node.tagName) {
                    ++line
                } else {
                    extend(style = {}, parentStyle);
                    switch (node.tagName) {
                        case "B":
                        case "STRONG":
                            style[KEY_FONT_WEIGHT] = "bold";
                            break;
                        case "I":
                        case "EM":
                            style[KEY_FONT_STYLE] = "italic";
                            break;
                        case "U":
                            style[KEY_TEXT_DECORATION] = "underline"
                    }
                    realStyle = node.style;
                    realStyle.color && (style.fill = realStyle.color);
                    realStyle.fontSize && (style[KEY_FONT_SIZE] = _parseInt(realStyle.fontSize, 10));
                    realStyle.fontStyle && (style[KEY_FONT_STYLE] = realStyle.fontStyle);
                    realStyle.fontWeight && (style[KEY_FONT_WEIGHT] = realStyle.fontWeight);
                    realStyle.textDecoration && (style[KEY_TEXT_DECORATION] = realStyle.textDecoration);
                    for (i = 0, nodes = node.childNodes, ii = nodes.length; i < ii; ++i) {
                        line = orderHtmlTree(list, line, nodes[i], style, node.className || parentClassName)
                    }
                }
            }
            return line
        }

        function adjustLineHeights(items) {
            var i, ii, item, currentItem = items[0];
            for (i = 1, ii = items.length; i < ii; ++i) {
                item = items[i];
                if (item.line === currentItem.line) {
                    currentItem.height = mathMax(currentItem.height, item.height);
                    currentItem.inherits = currentItem.inherits || 0 === item.height;
                    item.height = NaN
                } else {
                    currentItem = item
                }
            }
        }

        function removeExtraAttrs(html) {
            var findTagAttrs = /(?:<[a-z0-9])+(?:[\s\S]*?>)/gi,
                findStyleAttrWithValue = /(\S*\s*)=\s*(["'])(?:(?!\2).)*\2\s?/gi;
            return html.replace(findTagAttrs, function(allTagAttrs) {
                return allTagAttrs.replace(findStyleAttrWithValue, function(currentAttr, attrName) {
                    return "style" === attrName.toLowerCase() ? currentAttr : ""
                })
            })
        }

        function parseHTML(text) {
            var items = [],
                div = doc.createElement("div");
            div.innerHTML = text.replace(/\r/g, "").replace(/\n/g, "<br/>");
            orderHtmlTree(items, 0, div, {}, "");
            adjustLineHeights(items);
            return items
        }

        function parseMultiline(text) {
            var texts = text.replace(/\r/g, "").split("\n"),
                i = 0,
                items = [];
            for (; i < texts.length; i++) {
                items.push({
                    value: texts[i],
                    height: 0
                })
            }
            return items
        }

        function createTspans(items, element, fieldName) {
            var i, ii, item;
            for (i = 0, ii = items.length; i < ii; ++i) {
                item = items[i];
                item[fieldName] = createElement("tspan");
                item[fieldName].appendChild(doc.createTextNode(item.value));
                item.style && baseCss({
                    element: item[fieldName],
                    _styles: {}
                }, item.style);
                item.className && item[fieldName].setAttribute("class", item.className);
                element.appendChild(item[fieldName])
            }
        }

        function getEllipsis(prepareLines, setNewText, removeTextSpan) {
            return function(maxWidth) {
                var lines, requiredLength, i, ii, lineParts, j, jj, text, element = this.element,
                    width = this.getBBox().width,
                    maxLength = 0,
                    hasEllipsis = false;
                if (maxWidth < 0) {
                    maxWidth = 0
                }
                if (width > maxWidth) {
                    lines = prepareLines(element, this._texts);
                    for (i = 0, ii = lines.length; i < ii; ++i) {
                        maxLength = mathMax(maxLength, lines[i].commonLength)
                    }
                    if (1 === maxLength) {
                        return false
                    }
                    requiredLength = mathFloor(maxLength * maxWidth / width);
                    for (i = 0; i < ii; ++i) {
                        lineParts = lines[i].parts;
                        for (j = 0, jj = lineParts.length; j < jj; ++j) {
                            text = lineParts[j];
                            if (text.startIndex <= requiredLength && text.endIndex > requiredLength) {
                                setNewText(text, requiredLength - text.startIndex - 4);
                                hasEllipsis = true
                            } else {
                                if (text.startIndex > requiredLength) {
                                    removeTextSpan(text)
                                }
                            }
                        }
                    }
                }
                return hasEllipsis
            }
        }

        function prepareLines(element, texts) {
            var i, ii, text, lines = [];
            if (texts) {
                for (i = 0, ii = texts.length; i < ii; ++i) {
                    text = texts[i];
                    if (!lines[text.line]) {
                        text.startIndex = 0;
                        text.endIndex = text.value.length;
                        lines.push({
                            commonLength: text.value.length,
                            parts: [text]
                        })
                    } else {
                        text.startIndex = lines[text.line].commonLength + 1;
                        text.endIndex = lines[text.line].commonLength + text.value.length;
                        lines[text.line].parts.push(text);
                        lines[text.line].commonLength += text.value.length
                    }
                }
            } else {
                lines = [{
                    commonLength: element.textContent.length,
                    parts: [{
                        value: element.textContent,
                        tspan: element,
                        startIndex: 0,
                        endIndex: element.textContent.length
                    }]
                }]
            }
            return lines
        }

        function setNewText(text, index) {
            var newText = text.value.substr(0, index) + "...";
            text.tspan.textContent = newText;
            text.stroke && (text.stroke.textContent = newText)
        }

        function removeTextSpan(text) {
            text.tspan.parentNode.removeChild(text.tspan);
            text.stroke && text.stroke.parentNode.removeChild(text.stroke)
        }

        function createTextNodes(wrapper, text, isStroked) {
            var items, parsedHtml;
            wrapper._texts = null;
            wrapper.clear();
            if (null === text) {
                return
            }
            text = "" + text;
            if (!wrapper.renderer.encodeHtml && (text.indexOf("<") !== -1 || text.indexOf("&") !== -1)) {
                parsedHtml = removeExtraAttrs(text);
                items = parseHTML(parsedHtml);
                wrapper.DEBUG_parsedHtml = parsedHtml
            } else {
                if (text.indexOf("\n") !== -1) {
                    items = parseMultiline(text)
                } else {
                    if (isStroked) {
                        items = [{
                            value: text,
                            height: 0
                        }]
                    }
                }
            }
            if (items) {
                if (items.length) {
                    wrapper._texts = items;
                    if (isStroked) {
                        createTspans(items, wrapper.element, KEY_STROKE)
                    }
                    createTspans(items, wrapper.element, "tspan")
                }
            } else {
                wrapper.element.appendChild(doc.createTextNode(text))
            }
        }

        function setTextNodeAttribute(item, name, value) {
            item.tspan.setAttribute(name, value);
            item.stroke && item.stroke.setAttribute(name, value)
        }

        function locateTextNodes(wrapper) {
            if (!wrapper._texts) {
                return
            }
            var i, ii, items = wrapper._texts,
                x = wrapper._settings.x,
                lineHeight = _parseInt(wrapper._styles[KEY_FONT_SIZE], 10) || 12,
                item = items[0];
            setTextNodeAttribute(item, "x", x);
            setTextNodeAttribute(item, "y", wrapper._settings.y);
            for (i = 1, ii = items.length; i < ii; ++i) {
                item = items[i];
                if (item.height >= 0) {
                    setTextNodeAttribute(item, "x", x);
                    setTextNodeAttribute(item, "dy", item.inherits ? mathMax(item.height, lineHeight) : item.height || lineHeight)
                }
            }
        }

        function strokeTextNodes(wrapper) {
            if (!wrapper._texts) {
                return
            }
            var tspan, i, ii, items = wrapper._texts,
                stroke = wrapper._settings[KEY_STROKE],
                strokeWidth = wrapper._settings[KEY_STROKE_WIDTH],
                strokeOpacity = wrapper._settings[KEY_STROKE_OPACITY] || 1;
            for (i = 0, ii = items.length; i < ii; ++i) {
                tspan = items[i].stroke;
                tspan.setAttribute(KEY_STROKE, stroke);
                tspan.setAttribute(KEY_STROKE_WIDTH, strokeWidth);
                tspan.setAttribute(KEY_STROKE_OPACITY, strokeOpacity);
                tspan.setAttribute("stroke-linejoin", "round")
            }
        }

        function baseAnimate(that, params, options, complete) {
            options = options || {};
            var key, value, renderer = that.renderer,
                settings = that._settings,
                animationParams = {};
            var defaults = {
                translateX: 0,
                translateY: 0,
                scaleX: 1,
                scaleY: 1,
                rotate: 0,
                rotateX: 0,
                rotateY: 0
            };
            if (complete) {
                options.complete = complete
            }
            if (renderer.animationEnabled()) {
                for (key in params) {
                    value = params[key];
                    if (/^(translate(X|Y)|rotate[XY]?|scale(X|Y))$/i.test(key)) {
                        animationParams.transform = animationParams.transform || {
                            from: {},
                            to: {}
                        };
                        animationParams.transform.from[key] = key in settings ? Number(settings[key].toFixed(3)) : defaults[key];
                        animationParams.transform.to[key] = value
                    } else {
                        if ("arc" === key || "segments" === key) {
                            animationParams[key] = value
                        } else {
                            animationParams[key] = {
                                from: key in settings ? settings[key] : parseFloat(that.element.getAttribute(key) || 0),
                                to: value
                            }
                        }
                    }
                }
                renderer.animateElement(that, animationParams, extend(extend({}, renderer._animation), options))
            } else {
                options.step && options.step.call(that, 1, 1);
                options.complete && options.complete.call(that);
                that.attr(params)
            }
            return that
        }

        function pathAnimate(params, options, complete) {
            var newSegments, endSegments, that = this,
                curSegments = that.segments || [];
            if (that.renderer.animationEnabled() && "points" in params) {
                newSegments = buildPathSegments(params.points, that.type);
                endSegments = compensateSegments(curSegments, newSegments, that.type);
                params.segments = {
                    from: curSegments,
                    to: newSegments,
                    end: endSegments
                };
                delete params.points
            }
            return baseAnimate(that, params, options, complete)
        }

        function arcAnimate(params, options, complete) {
            var that = this,
                settings = that._settings,
                arcParams = {
                    from: {},
                    to: {}
                };
            if (that.renderer.animationEnabled() && ("x" in params || "y" in params || "innerRadius" in params || "outerRadius" in params || "startAngle" in params || "endAngle" in params)) {
                arcParams.from.x = settings.x || 0;
                arcParams.from.y = settings.y || 0;
                arcParams.from.innerRadius = settings.innerRadius || 0;
                arcParams.from.outerRadius = settings.outerRadius || 0;
                arcParams.from.startAngle = settings.startAngle || 0;
                arcParams.from.endAngle = settings.endAngle || 0;
                arcParams.to.x = "x" in params ? params.x : settings.x;
                delete params.x;
                arcParams.to.y = "y" in params ? params.y : settings.y;
                delete params.y;
                arcParams.to.innerRadius = "innerRadius" in params ? params.innerRadius : settings.innerRadius;
                delete params.innerRadius;
                arcParams.to.outerRadius = "outerRadius" in params ? params.outerRadius : settings.outerRadius;
                delete params.outerRadius;
                arcParams.to.startAngle = "startAngle" in params ? params.startAngle : settings.startAngle;
                delete params.startAngle;
                arcParams.to.endAngle = "endAngle" in params ? params.endAngle : settings.endAngle;
                delete params.endAngle;
                params.arc = arcParams
            }
            return baseAnimate(that, params, options, complete)
        }
        exports.DEBUG_set_getNextDefsSvgId = function(newFunction) {
            getNextDefsSvgId = newFunction
        };
        exports.DEBUG_removeBackupContainer = function() {
            if (backupCounter) {
                backupCounter = 0;
                doc.body.removeChild(backupContainer)
            }
        };

        function buildLink(target, parameters) {
            var obj = {
                is: false,
                name: parameters.name || parameters,
                after: parameters.after
            };
            if (target) {
                obj.to = target
            } else {
                obj.virtual = true
            }
            return obj
        }

        function SvgElement(renderer, tagName, type) {
            var that = this;
            that.renderer = renderer;
            that.element = createElement(tagName);
            that._settings = {};
            that._styles = {};
            if ("path" === tagName) {
                that.type = type || "line"
            }
        }
        exports.SvgElement = SvgElement;
        SvgElement.prototype = {
            constructor: SvgElement,
            _getJQElement: function() {
                return this._$element || (this._$element = $(this.element))
            },
            dispose: function() {
                this._getJQElement().remove();
                return this
            },
            append: function(parent) {
                (parent || this.renderer.root).element.appendChild(this.element);
                return this
            },
            remove: function() {
                var element = this.element;
                element.parentNode && element.parentNode.removeChild(element);
                return this
            },
            enableLinks: function() {
                this._links = [];
                return this
            },
            checkLinks: function() {
                var i, count = 0,
                    links = this._links,
                    ii = links.length;
                for (i = 0; i < ii; ++i) {
                    if (!links[i]._link.virtual) {
                        ++count
                    }
                }
                if (count > 0) {
                    throw new Error("There are non disposed links!")
                }
            },
            virtualLink: function(parameters) {
                linkItem({
                    _link: buildLink(null, parameters)
                }, this);
                return this
            },
            linkAfter: function(name) {
                this._linkAfter = name;
                return this
            },
            linkOn: function(target, parameters) {
                this._link = buildLink(target, parameters);
                linkItem(this, target);
                return this
            },
            linkOff: function() {
                unlinkItem(this);
                this._link = null;
                return this
            },
            linkAppend: function() {
                var i, next, link = this._link,
                    items = link.to._links;
                for (i = link.i + 1;
                    (next = items[i]) && !next._link.is; ++i) {}
                this._insert(link.to, next);
                link.is = true;
                return this
            },
            _insert: function(parent, next) {
                parent.element.insertBefore(this.element, next ? next.element : null)
            },
            linkRemove: function() {
                this.remove();
                this._link.is = false;
                return this
            },
            clear: function() {
                this._getJQElement().empty();
                return this
            },
            toBackground: function() {
                var elem = this.element,
                    parent = elem.parentNode;
                parent && parent.insertBefore(elem, parent.firstChild);
                return this
            },
            toForeground: function() {
                var elem = this.element,
                    parent = elem.parentNode;
                parent && parent.appendChild(elem);
                return this
            },
            attr: function(attrs, inh) {
                return baseAttr(this, attrs, inh)
            },
            smartAttr: function(attrs) {
                var that = this;
                if (attrs.hatching) {
                    attrs.fill = that._hatching = that.renderer.lockHatching(attrs.fill, attrs.hatching, that._hatching);
                    attrs.hatching = null
                } else {
                    if (that._hatching) {
                        that.renderer.releaseHatching(that._hatching);
                        that._hatching = null
                    }
                }
                return baseAttr(that, attrs)
            },
            css: function(styles) {
                return baseCss(this, styles)
            },
            animate: function(params, options, complete) {
                return baseAnimate(this, params, options, complete)
            },
            sharp: function(pos) {
                return this.attr({
                    sharp: pos || true
                })
            },
            _applyTransformation: function() {
                var scaleXDefined, scaleYDefined, rotateX, rotateY, tr = this._settings,
                    transformations = [],
                    sharpMode = tr.sharp,
                    strokeOdd = tr[KEY_STROKE_WIDTH] % 2,
                    correctionX = strokeOdd && ("h" === sharpMode || true === sharpMode) ? SHARPING_CORRECTION : 0,
                    correctionY = strokeOdd && ("v" === sharpMode || true === sharpMode) ? SHARPING_CORRECTION : 0;
                transformations.push("translate(" + ((tr.translateX || 0) + correctionX) + "," + ((tr.translateY || 0) + correctionY) + ")");
                if (tr.rotate) {
                    if ("rotateX" in tr) {
                        rotateX = tr.rotateX
                    } else {
                        rotateX = tr.x
                    }
                    if ("rotateY" in tr) {
                        rotateY = tr.rotateY
                    } else {
                        rotateY = tr.y
                    }
                    transformations.push("rotate(" + tr.rotate + "," + (rotateX || 0) + "," + (rotateY || 0) + ")")
                }
                scaleXDefined = _isDefined(tr.scaleX);
                scaleYDefined = _isDefined(tr.scaleY);
                if (scaleXDefined || scaleYDefined) {
                    transformations.push("scale(" + (scaleXDefined ? tr.scaleX : 1) + "," + (scaleYDefined ? tr.scaleY : 1) + ")")
                }
                if (transformations.length) {
                    this.element.setAttribute("transform", transformations.join(" "))
                }
            },
            move: function(x, y, animate, animOptions) {
                var obj = {};
                _isDefined(x) && (obj.translateX = x);
                _isDefined(y) && (obj.translateY = y);
                if (!animate) {
                    this.attr(obj)
                } else {
                    this.animate(obj, animOptions)
                }
                return this
            },
            rotate: function(angle, x, y, animate, animOptions) {
                var obj = {
                    rotate: angle || 0
                };
                _isDefined(x) && (obj.rotateX = x);
                _isDefined(y) && (obj.rotateY = y);
                if (!animate) {
                    this.attr(obj)
                } else {
                    this.animate(obj, animOptions)
                }
                return this
            },
            getBBox: function() {
                var bBox, elem = this.element,
                    transformation = this._settings;
                try {
                    bBox = elem.getBBox && elem.getBBox()
                } catch (e) {}
                bBox = bBox || {
                    x: 0,
                    y: 0,
                    width: elem.offsetWidth || 0,
                    height: elem.offsetHeight || 0
                };
                if (transformation.rotate) {
                    bBox = _rotateBBox(bBox, [("rotateX" in transformation ? transformation.rotateX : transformation.x) || 0, ("rotateY" in transformation ? transformation.rotateY : transformation.y) || 0], -transformation.rotate)
                } else {
                    bBox = _normalizeBBox(bBox)
                }
                return bBox
            },
            markup: function() {
                var temp = doc.createElement("div"),
                    node = this.element.cloneNode(true);
                temp.appendChild(node);
                return temp.innerHTML
            },
            getOffset: function() {
                return this._getJQElement().offset()
            },
            stopAnimation: function(disableComplete) {
                var animation = this.animation;
                animation && animation.stop(disableComplete);
                return this
            },
            setTitle: function(text) {
                var titleElem = createElement("title");
                titleElem.textContent = text || "";
                this.element.appendChild(titleElem)
            },
            data: function(obj, val) {
                var key, elem = this.element;
                if (void 0 !== val) {
                    elem[obj] = val
                } else {
                    for (key in obj) {
                        elem[key] = obj[key]
                    }
                }
                return this
            },
            on: function() {
                $.fn.on.apply(this._getJQElement(), arguments);
                return this
            },
            off: function() {
                $.fn.off.apply(this._getJQElement(), arguments);
                return this
            },
            trigger: function() {
                $.fn.trigger.apply(this._getJQElement(), arguments);
                return this
            }
        };

        function PathSvgElement(renderer, type) {
            SvgElement.call(this, renderer, "path", type)
        }
        exports.PathSvgElement = PathSvgElement;
        PathSvgElement.prototype = objectCreate(SvgElement.prototype);
        extend(PathSvgElement.prototype, {
            constructor: PathSvgElement,
            attr: pathAttr,
            animate: pathAnimate
        });

        function ArcSvgElement(renderer) {
            SvgElement.call(this, renderer, "path", "arc")
        }
        exports.ArcSvgElement = ArcSvgElement;
        ArcSvgElement.prototype = objectCreate(SvgElement.prototype);
        extend(ArcSvgElement.prototype, {
            constructor: ArcSvgElement,
            attr: arcAttr,
            animate: arcAnimate
        });

        function RectSvgElement(renderer) {
            SvgElement.call(this, renderer, "rect")
        }
        exports.RectSvgElement = RectSvgElement;
        RectSvgElement.prototype = objectCreate(SvgElement.prototype);
        extend(RectSvgElement.prototype, {
            constructor: RectSvgElement,
            attr: rectAttr
        });

        function TextSvgElement(renderer) {
            SvgElement.call(this, renderer, "text")
        }
        exports.TextSvgElement = TextSvgElement;
        TextSvgElement.prototype = objectCreate(SvgElement.prototype);
        extend(TextSvgElement.prototype, {
            constructor: TextSvgElement,
            attr: textAttr,
            css: textCss,
            applyEllipsis: applyEllipsis
        });

        function updateIndexes(items, k) {
            var i, item;
            for (i = k; !!(item = items[i]); ++i) {
                item._link.i = i
            }
        }

        function linkItem(target, container) {
            var i, item, items = container._links,
                key = target._link.after = target._link.after || container._linkAfter;
            if (key) {
                for (i = 0;
                    (item = items[i]) && item._link.name !== key; ++i) {}
                if (item) {
                    for (++i;
                        (item = items[i]) && item._link.after === key; ++i) {}
                }
            } else {
                i = items.length
            }
            items.splice(i, 0, target);
            updateIndexes(items, i)
        }

        function unlinkItem(target) {
            var i, items = target._link.to._links;
            for (i = 0; items[i] !== target; ++i) {}
            items.splice(i, 1);
            updateIndexes(items, i)
        }

        function SvgRenderer(options) {
            var that = this;
            that.root = that._createElement(that._rootTag, that._rootAttr).attr({
                "class": options.cssClass
            }).css(that._rootCss);
            that._init();
            that.pathModified = !!options.pathModified;
            that._$container = $(options.container);
            that.root.append({
                element: options.container
            });
            that._locker = 0;
            that._backed = false
        }
        exports.SvgRenderer = SvgRenderer;
        SvgRenderer.prototype = {
            constructor: SvgRenderer,
            _rootTag: "svg",
            _rootAttr: {
                xmlns: "http://www.w3.org/2000/svg",
                "xmlns:xlink": "http://www.w3.org/1999/xlink",
                version: "1.1",
                fill: NONE,
                stroke: NONE,
                "stroke-width": 0
            },
            _rootCss: {
                "line-height": "normal",
                "-ms-user-select": NONE,
                "-moz-user-select": NONE,
                "-webkit-user-select": NONE,
                "-webkit-tap-highlight-color": "rgba(0, 0, 0, 0)",
                display: "block",
                overflow: "hidden"
            },
            _init: function() {
                var that = this;
                that._defs = that._createElement("defs").append(that.root);
                that._animationController = new animation.AnimationController(that.root.element);
                that._animation = {
                    enabled: true,
                    duration: 1e3,
                    easing: "easeOutCubic"
                }
            },
            setOptions: function(options) {
                var that = this;
                that.rtl = !!options.rtl;
                that.encodeHtml = !!options.encodeHtml;
                that.updateAnimationOptions(options.animation || {});
                that.root.attr({
                    direction: that.rtl ? "rtl" : "ltr"
                });
                return that
            },
            _createElement: function(tagName, attr, type) {
                var elem = new exports.SvgElement(this, tagName, type);
                attr && elem.attr(attr);
                return elem
            },
            lock: function() {
                var that = this;
                if (0 === that._locker) {
                    that._backed = !that._$container.is(":visible");
                    if (that._backed) {
                        backupRoot(that.root)
                    }
                }++that._locker;
                return that
            },
            unlock: function() {
                var that = this;
                --that._locker;
                if (0 === that._locker) {
                    if (that._backed) {
                        restoreRoot(that.root, that._$container[0])
                    }
                    that._backed = false
                }
                return that
            },
            resize: function(width, height) {
                if (width >= 0 && height >= 0) {
                    this.root.attr({
                        width: width,
                        height: height
                    })
                }
                return this
            },
            dispose: function() {
                var key, that = this;
                that.root.dispose();
                that._defs.dispose();
                that._animationController.dispose();
                for (key in that) {
                    that[key] = null
                }
                return that
            },
            animationEnabled: function() {
                return !!this._animation.enabled
            },
            updateAnimationOptions: function(newOptions) {
                extend(this._animation, newOptions);
                return this
            },
            stopAllAnimations: function(lock) {
                this._animationController[lock ? "lock" : "stop"]();
                return this
            },
            animateElement: function(element, params, options) {
                this._animationController.animateElement(element, params, options);
                return this
            },
            svg: function() {
                return this.root.markup()
            },
            getRootOffset: function() {
                return this.root.getOffset()
            },
            onEndAnimation: function(endAnimation) {
                this._animationController.onEndAnimation(endAnimation)
            },
            rect: function(x, y, width, height) {
                var elem = new exports.RectSvgElement(this);
                return elem.attr({
                    x: x || 0,
                    y: y || 0,
                    width: width || 0,
                    height: height || 0
                })
            },
            simpleRect: function() {
                return this._createElement("rect")
            },
            circle: function(x, y, r) {
                return this._createElement("circle", {
                    cx: x || 0,
                    cy: y || 0,
                    r: r || 0
                })
            },
            g: function() {
                return this._createElement("g")
            },
            image: function(x, y, w, h, href, location) {
                var image = this._createElement("image", {
                    x: x || 0,
                    y: y || 0,
                    width: w || 0,
                    height: h || 0,
                    preserveAspectRatio: preserveAspectRatioMap[_normalizeEnum(location)] || NONE
                });
                image.element.setAttributeNS("http://www.w3.org/1999/xlink", "href", href || "");
                return image
            },
            path: function(points, type) {
                var elem = new exports.PathSvgElement(this, type);
                return elem.attr({
                    points: points || []
                })
            },
            arc: function(x, y, innerRadius, outerRadius, startAngle, endAngle) {
                var elem = new exports.ArcSvgElement(this);
                return elem.attr({
                    x: x || 0,
                    y: y || 0,
                    innerRadius: innerRadius || 0,
                    outerRadius: outerRadius || 0,
                    startAngle: startAngle || 0,
                    endAngle: endAngle || 0
                })
            },
            text: function(text, x, y) {
                var elem = new exports.TextSvgElement(this);
                return elem.attr({
                    text: text,
                    x: x || 0,
                    y: y || 0
                })
            },
            pattern: function(color, hatching, _id) {
                hatching = hatching || {};
                var id, d, pattern, rect, path, that = this,
                    step = hatching.step || 6,
                    stepTo2 = step / 2,
                    stepBy15 = 1.5 * step,
                    direction = _normalizeEnum(hatching.direction);
                if ("right" !== direction && "left" !== direction) {
                    return {
                        id: color,
                        append: function() {
                            return this
                        },
                        clear: function() {},
                        dispose: function() {},
                        remove: function() {}
                    }
                }
                id = _id || getNextDefsSvgId();
                d = "right" === direction ? "M " + stepTo2 + " " + -stepTo2 + " L " + -stepTo2 + " " + stepTo2 + " M 0 " + step + " L " + step + " 0 M " + stepBy15 + " " + stepTo2 + " L " + stepTo2 + " " + stepBy15 : "M 0 0 L " + step + " " + step + " M " + -stepTo2 + " " + stepTo2 + " L " + stepTo2 + " " + stepBy15 + " M " + stepTo2 + " " + -stepTo2 + " L " + stepBy15 + " " + stepTo2;
                pattern = that._createElement("pattern", {
                    id: id,
                    width: step,
                    height: step,
                    patternUnits: "userSpaceOnUse"
                }).append(that._defs);
                pattern.id = getPatternUrl(id, that.pathModified);
                rect = that.rect(0, 0, step, step).attr({
                    fill: color,
                    opacity: hatching.opacity
                }).append(pattern);
                path = new exports.PathSvgElement(this).attr({
                    d: d,
                    "stroke-width": hatching.width || 1,
                    stroke: color
                }).append(pattern);
                pattern.rect = rect;
                pattern.path = path;
                return pattern
            },
            clipRect: function(x, y, width, height) {
                var that = this,
                    id = getNextDefsSvgId(),
                    clipPath = that._createElement("clipPath", {
                        id: id
                    }).append(that._defs),
                    rect = that.rect(x, y, width, height).append(clipPath);
                rect.id = id;
                rect.clipPath = clipPath;
                rect.remove = function() {
                    throw "Not implemented"
                };
                rect.dispose = function() {
                    clipPath.dispose();
                    clipPath = null;
                    return this
                };
                return rect
            },
            shadowFilter: function(x, y, width, height, offsetX, offsetY, blur, color, opacity) {
                var that = this,
                    id = getNextDefsSvgId(),
                    filter = that._createElement("filter", {
                        id: id,
                        x: x || 0,
                        y: y || 0,
                        width: width || 0,
                        height: height || 0
                    }).append(that._defs),
                    gaussianBlur = that._createElement("feGaussianBlur", {
                        "in": "SourceGraphic",
                        result: "gaussianBlurResult",
                        stdDeviation: blur || 0
                    }).append(filter),
                    offset = that._createElement("feOffset", {
                        "in": "gaussianBlurResult",
                        result: "offsetResult",
                        dx: offsetX || 0,
                        dy: offsetY || 0
                    }).append(filter),
                    flood = that._createElement("feFlood", {
                        result: "floodResult",
                        "flood-color": color || "",
                        "flood-opacity": opacity
                    }).append(filter),
                    composite = that._createElement("feComposite", {
                        "in": "floodResult",
                        in2: "offsetResult",
                        operator: "in",
                        result: "compositeResult"
                    }).append(filter),
                    finalComposite = that._createElement("feComposite", {
                        "in": "SourceGraphic",
                        in2: "compositeResult",
                        operator: "over"
                    }).append(filter);
                filter.ref = getPatternUrl(id, that.pathModified);
                filter.gaussianBlur = gaussianBlur;
                filter.offset = offset;
                filter.flood = flood;
                filter.composite = composite;
                filter.finalComposite = finalComposite;
                filter.attr = function(attrs) {
                    var that = this,
                        filterAttrs = {},
                        offsetAttrs = {},
                        floodAttrs = {};
                    "x" in attrs && (filterAttrs.x = attrs.x);
                    "y" in attrs && (filterAttrs.y = attrs.y);
                    "width" in attrs && (filterAttrs.width = attrs.width);
                    "height" in attrs && (filterAttrs.height = attrs.height);
                    baseAttr(that, filterAttrs);
                    "blur" in attrs && that.gaussianBlur.attr({
                        stdDeviation: attrs.blur
                    });
                    "offsetX" in attrs && (offsetAttrs.dx = attrs.offsetX);
                    "offsetY" in attrs && (offsetAttrs.dy = attrs.offsetY);
                    that.offset.attr(offsetAttrs);
                    "color" in attrs && (floodAttrs["flood-color"] = attrs.color);
                    "opacity" in attrs && (floodAttrs["flood-opacity"] = attrs.opacity);
                    that.flood.attr(floodAttrs);
                    return that
                };
                return filter
            },
            brightFilter: function(type, slope) {
                var that = this,
                    filterId = getNextDefsSvgId(),
                    filter = that._createElement("filter", {
                        id: filterId
                    }).append(that._defs),
                    feComponentTransfer = that._createElement("feComponentTransfer").append(filter),
                    attrs = {
                        type: type,
                        slope: slope
                    };
                filter.ref = getPatternUrl(filterId, that.pathModified);
                that._createElement("feFuncR", attrs).append(feComponentTransfer);
                that._createElement("feFuncG", attrs).append(feComponentTransfer);
                that._createElement("feFuncB", attrs).append(feComponentTransfer);
                return filter
            },
            initHatching: function() {
                var name, storage = this._hatchingStorage = this._hatchingStorage || {
                        byHash: {},
                        baseId: getNextDefsSvgId()
                    },
                    byHash = storage.byHash;
                for (name in byHash) {
                    byHash[name].pattern.dispose()
                }
                storage.byHash = {};
                storage.refToHash = {};
                storage.nextId = 0
            },
            lockHatching: function(color, hatching, ref) {
                var storageItem, pattern, storage = this._hatchingStorage,
                    hash = getHatchingHash(color, hatching);
                if (storage.refToHash[ref] !== hash) {
                    if (ref) {
                        this.releaseHatching(ref)
                    }
                    storageItem = storage.byHash[hash];
                    if (!storageItem) {
                        pattern = this.pattern(color, hatching, storage.baseId + "-hatching-" + storage.nextId++);
                        storageItem = storage.byHash[hash] = {
                            pattern: pattern,
                            count: 0
                        };
                        storage.refToHash[pattern.id] = hash
                    }++storageItem.count;
                    ref = storageItem.pattern.id
                }
                return ref
            },
            releaseHatching: function(ref) {
                var storage = this._hatchingStorage,
                    hash = storage.refToHash[ref],
                    storageItem = storage.byHash[hash];
                if (0 === --storageItem.count) {
                    storageItem.pattern.dispose();
                    delete storage.byHash[hash];
                    delete storage.refToHash[ref]
                }
            }
        };

        function getHatchingHash(color, hatching) {
            return "@" + color + "::" + hatching.step + ":" + hatching.width + ":" + hatching.opacity + ":" + hatching.direction
        }
        exports._getEllipsis = getEllipsis;
        exports._createArcAttr = createArcAttr;
        exports._createPathAttr = createPathAttr;
        exports._createRectAttr = createRectAttr
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/core/renderers/animation.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var animationFrame = __webpack_require__( /*! ../../../animation/frame */ 46),
            noop = function() {},
            easingFunctions = {
                easeOutCubic: function(pos, start, end) {
                    return 1 === pos ? end : (1 - Math.pow(1 - pos, 3)) * (end - start) + +start
                },
                linear: function(pos, start, end) {
                    return 1 === pos ? end : pos * (end - start) + +start
                }
            };
        exports.easingFunctions = easingFunctions;
        var animationSvgStep = {
            segments: function(elem, params, progress, easing, currentParams) {
                var curSeg, seg, i, j, from = params.from,
                    to = params.to,
                    segments = [];
                for (i = 0; i < from.length; i++) {
                    curSeg = from[i];
                    seg = [curSeg[0]];
                    if (curSeg.length > 1) {
                        for (j = 1; j < curSeg.length; j++) {
                            seg.push(easing(progress, curSeg[j], to[i][j]))
                        }
                    }
                    segments.push(seg)
                }
                currentParams.segments = params.end && 1 === progress ? params.end : segments;
                elem.attr({
                    segments: segments
                })
            },
            arc: function(elem, params, progress, easing) {
                var from = params.from,
                    to = params.to,
                    current = {};
                for (var i in from) {
                    current[i] = easing(progress, from[i], to[i])
                }
                elem.attr(current)
            },
            transform: function(elem, params, progress, easing, currentParams) {
                var from = params.from,
                    to = params.to,
                    current = {};
                for (var i in from) {
                    current[i] = currentParams[i] = easing(progress, from[i], to[i])
                }
                elem.attr(current)
            },
            base: function(elem, params, progress, easing, currentParams, attributeName) {
                var obj = {};
                obj[attributeName] = currentParams[attributeName] = easing(progress, params.from, params.to);
                elem.attr(obj)
            },
            _: noop,
            complete: function(element, currentSettings) {
                element.attr(currentSettings)
            }
        };

        function step(now) {
            var attrName, that = this,
                animateStep = that._animateStep;
            that._progress = that._calcProgress(now);
            for (attrName in that.params) {
                var anim = animateStep[attrName] || animateStep.base;
                anim(that.element, that.params[attrName], that._progress, that._easing, that._currentParams, attrName)
            }
            that.options.step && that.options.step(that._easing(that._progress, 0, 1), that._progress);
            if (1 === that._progress) {
                return that.stop()
            }
            return true
        }

        function start(now) {
            this._startTime = now;
            this.tick = step;
            return true
        }

        function Animation(element, params, options) {
            var that = this;
            that._progress = 0;
            that.element = element;
            that.params = params;
            that.options = options;
            that.duration = options.partitionDuration ? options.duration * options.partitionDuration : options.duration;
            that._animateStep = options.animateStep || animationSvgStep;
            that._easing = easingFunctions[options.easing] || easingFunctions.easeOutCubic;
            that._currentParams = {};
            that.tick = start
        }
        Animation.prototype = {
            _calcProgress: function(now) {
                return Math.min(1, (now - this._startTime) / this.duration)
            },
            stop: function(disableComplete) {
                var that = this,
                    options = that.options,
                    animateStep = that._animateStep;
                that.stop = that.tick = noop;
                animateStep.complete && animateStep.complete(that.element, that._currentParams);
                options.complete && !disableComplete && options.complete()
            }
        };

        function AnimationController(element) {
            var that = this;
            that._animationCount = 0;
            that._timerId = null;
            that._animations = {};
            that.element = element
        }
        exports.AnimationController = AnimationController;
        AnimationController.prototype = {
            _loop: function() {
                var an, that = this,
                    animations = that._animations,
                    activeAnimation = 0,
                    now = (new Date).getTime(),
                    endAnimation = that._endAnimation;
                for (an in animations) {
                    if (!animations[an].tick(now)) {
                        delete animations[an]
                    }
                    activeAnimation++
                }
                if (0 === activeAnimation) {
                    that.stop();
                    that._endAnimationTimer = endAnimation && setTimeout(function() {
                        if (0 === that._animationCount) {
                            endAnimation();
                            that._endAnimation = null
                        }
                    });
                    return
                }
                that._timerId = animationFrame.requestAnimationFrame.call(null, function() {
                    that._loop()
                }, that.element)
            },
            addAnimation: function(animation) {
                var that = this;
                that._animations[that._animationCount++] = animation;
                clearTimeout(that._endAnimationTimer);
                if (!that._timerId) {
                    clearTimeout(that._startDelay);
                    that._startDelay = setTimeout(function() {
                        that._timerId = 1;
                        that._loop()
                    }, 0)
                }
            },
            animateElement: function(elem, params, options) {
                if (elem && params && options) {
                    elem.animation && elem.animation.stop();
                    this.addAnimation(elem.animation = new Animation(elem, params, options))
                }
            },
            onEndAnimation: function(endAnimation) {
                this._animationCount ? this._endAnimation = endAnimation : endAnimation()
            },
            dispose: function() {
                this.stop();
                this.element = null
            },
            stop: function() {
                var that = this;
                that._animations = {};
                that._animationCount = 0;
                animationFrame.cancelAnimationFrame(that._timerId);
                clearTimeout(that._startDelay);
                clearTimeout(that._endAnimationTimer);
                that._timerId = null
            },
            lock: function() {
                var an, unstoppable, hasUnstoppableInAnimations, animations = this._animations;
                for (an in animations) {
                    unstoppable = animations[an].options.unstoppable;
                    hasUnstoppableInAnimations = hasUnstoppableInAnimations || unstoppable;
                    if (!unstoppable) {
                        animations[an].stop(true);
                        delete animations[an]
                    }
                }!hasUnstoppableInAnimations && this.stop()
            }
        };
        exports.animationSvgStep = animationSvgStep;
        exports.Animation = Animation;
        exports.noop = noop
    },
    /*!************************************!*\
      !*** ./Scripts/viz/core/layout.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var _normalizeEnum = __webpack_require__( /*! ./utils */ 442).normalizeEnum,
            _min = Math.min,
            _max = Math.max,
            ALIGN_START = 0,
            ALIGN_MIDDLE = 1,
            ALIGN_END = 2,
            horizontalAlignmentMap = {
                left: ALIGN_START,
                center: ALIGN_MIDDLE,
                right: ALIGN_END
            },
            verticalAlignmentMap = {
                top: ALIGN_START,
                center: ALIGN_MIDDLE,
                bottom: ALIGN_END
            },
            sideMap = {
                horizontal: 0,
                vertical: 1
            },
            slicersMap = {};
        slicersMap[ALIGN_START] = function(a, b, size) {
            return [a, _min(b, a + size)]
        };
        slicersMap[ALIGN_MIDDLE] = function(a, b, size) {
            return [_max(a, (a + b - size) / 2), _min(b, (a + b + size) / 2)]
        };
        slicersMap[ALIGN_END] = function(a, b, size) {
            return [_max(a, b - size), b]
        };

        function pickValue(value, map, defaultValue) {
            var val = _normalizeEnum(value);
            return val in map ? map[val] : defaultValue
        }

        function normalizeLayoutOptions(options) {
            var side = pickValue(options.side, sideMap, 1),
                alignment = [pickValue(options.horizontalAlignment, horizontalAlignmentMap, ALIGN_MIDDLE), pickValue(options.verticalAlignment, verticalAlignmentMap, ALIGN_START)];
            return {
                side: side,
                primary: bringToEdge(alignment[side]),
                secondary: alignment[1 - side],
                weak: options.weak
            }
        }

        function bringToEdge(primary) {
            return primary < 2 ? 0 : 2
        }

        function getConjugateSide(side) {
            return 1 - side
        }

        function getOppositeAlignment(alignment) {
            return 2 - alignment
        }

        function getSlice(alignment, a, b, size) {
            return slicersMap[alignment](a, b, size)
        }

        function getShrink(alignment, size) {
            return (alignment > 0 ? -1 : 1) * size
        }

        function processForward(item, rect) {
            var side = item.side,
                size = item.element.measure([rect[2] - rect[0], rect[3] - rect[1]]),
                isValid = size[side] < rect[2 + side] - rect[side];
            if (isValid) {
                rect[item.primary + side] += getShrink(item.primary, size[side]);
                item.size = size
            }
            return isValid
        }

        function processBackward(item, rect) {
            var primarySide = item.side,
                secondarySide = getConjugateSide(primarySide),
                itemRect = [],
                secondary = getSlice(item.secondary, rect[secondarySide], rect[2 + secondarySide], item.size[secondarySide]);
            itemRect[primarySide] = itemRect[2 + primarySide] = rect[item.primary + primarySide];
            itemRect[item.primary + primarySide] = rect[item.primary + primarySide] -= getShrink(item.primary, item.size[primarySide]);
            itemRect[secondarySide] = secondary[0];
            itemRect[2 + secondarySide] = secondary[1];
            item.element.move(itemRect)
        }

        function Layout() {
            this._targets = []
        }
        Layout.prototype = {
            constructor: Layout,
            dispose: function() {
                this._targets = null
            },
            add: function(target) {
                this._targets.push(target)
            },
            forward: function(targetRect) {
                var i, rect = targetRect.slice(),
                    targets = createTargets(this._targets),
                    ii = targets.length,
                    cache = [];
                for (i = 0; i < ii; ++i) {
                    if (processForward(targets[i], rect)) {
                        cache.push(targets[i])
                    }
                }
                this._cache = cache.reverse();
                return rect
            },
            backward: function(targetRect) {
                var i, rect = targetRect.slice(),
                    targets = this._cache,
                    ii = targets.length;
                for (i = 0; i < ii; ++i) {
                    processBackward(targets[i], rect)
                }
                this._cache = null
            }
        };

        function createTargets(targets) {
            var i, layout, ii = targets.length,
                collection = [];
            for (i = 0; i < ii; ++i) {
                layout = targets[i].layoutOptions();
                if (layout) {
                    layout = normalizeLayoutOptions(layout);
                    layout.element = targets[i];
                    collection.push(layout)
                }
            }
            processWeakItems(collection);
            return collection
        }

        function processWeakItems(collection) {
            var i, ii, j, weakItem, isProcessed = true;
            while (isProcessed) {
                isProcessed = false;
                ii = collection.length;
                for (i = 0; i < ii; ++i) {
                    if (collection[i].weak) {
                        weakItem = collection[i];
                        for (j = 0; j < ii; ++j) {
                            if (i !== j && weakItem.side === collection[j].side && weakItem.primary === collection[j].primary) {
                                collection[_min(i, j)] = makePair(collection[_min(i, j)], collection[_max(i, j)]);
                                collection.splice(_max(i, j), 1);
                                isProcessed = true;
                                break
                            }
                        }
                        if (isProcessed) {
                            break
                        }
                    }
                }
            }
        }

        function makePair(first, second) {
            return {
                side: first.side,
                primary: first.primary,
                secondary: first.secondary === second.secondary ? first.secondary : bringToEdge(first.secondary) || bringToEdge(second.secondary),
                element: new PairElement(first, second)
            }
        }

        function PairElement(first, second) {
            this._first = first;
            this._second = second
        }
        PairElement.prototype.measure = function(targetSize) {
            var secondSize, first = this._first,
                second = this._second,
                size = targetSize.slice(),
                primarySide = first.side,
                secondarySide = getConjugateSide(primarySide),
                firstSize = first.element.measure(size.slice());
            size[secondarySide] -= firstSize[secondarySide];
            secondSize = second.element.measure(size.slice());
            size[primarySide] = _max(firstSize[primarySide], secondSize[primarySide]);
            if (first.secondary === second.secondary) {
                size[secondarySide] = firstSize[secondarySide] + secondSize[secondarySide]
            } else {
                if (first.secondary === ALIGN_MIDDLE || second.secondary === ALIGN_MIDDLE) {
                    size[secondarySide] = targetSize[secondarySide] / 2 + (first.secondary === ALIGN_MIDDLE ? firstSize : secondSize)[secondarySide] / 2
                } else {
                    size[secondarySide] = targetSize[secondarySide]
                }
            }
            first.size = firstSize;
            second.size = secondSize;
            return size
        };
        PairElement.prototype.move = function(targetRect) {
            var primary, secondary, rect, first = this._first,
                second = this._second,
                primarySide = first.side,
                secondarySide = getConjugateSide(primarySide),
                alignment = first.secondary === second.secondary ? bringToEdge(first.secondary) : first.secondary === ALIGN_MIDDLE ? getOppositeAlignment(bringToEdge(second.secondary)) : bringToEdge(first.secondary);
            primary = getSlice(ALIGN_MIDDLE, targetRect[primarySide], targetRect[2 + primarySide], first.size[primarySide]);
            secondary = getSlice(alignment, targetRect[secondarySide], targetRect[2 + secondarySide], first.size[secondarySide]);
            rect = [];
            rect[primarySide] = primary[0];
            rect[2 + primarySide] = primary[1];
            rect[secondarySide] = secondary[0];
            rect[2 + secondarySide] = secondary[1];
            first.element.move(rect);
            primary = getSlice(ALIGN_MIDDLE, targetRect[primarySide], targetRect[2 + primarySide], second.size[primarySide]);
            secondary = getSlice(getOppositeAlignment(alignment), targetRect[secondarySide], targetRect[2 + secondarySide], targetRect[2 + secondarySide] - targetRect[secondarySide] - first.size[secondarySide]);
            secondary = getSlice(getOppositeAlignment(alignment), secondary[0], secondary[1], second.size[secondarySide]);
            rect = [];
            rect[primarySide] = primary[0];
            rect[2 + primarySide] = primary[1];
            rect[secondarySide] = secondary[0];
            rect[2 + secondarySide] = secondary[1];
            second.element.move(rect)
        };
        module.exports = Layout
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/components/legend.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            layoutElementModule = __webpack_require__( /*! ../core/layout_element */ 457),
            _Number = Number,
            _math = Math,
            _round = _math.round,
            _max = _math.max,
            _min = _math.min,
            _ceil = _math.ceil,
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _isFunction = commonUtils.isFunction,
            _enumParser = vizUtils.enumParser,
            _normalizeEnum = vizUtils.normalizeEnum,
            _extend = $.extend,
            _each = $.each,
            DEFAULT_MARGIN = 10,
            DEFAULT_MARKER_HATCHING_WIDTH = 2,
            DEFAULT_MARKER_HATCHING_STEP = 5,
            CENTER = "center",
            RIGHT = "right",
            LEFT = "left",
            TOP = "top",
            BOTTOM = "bottom",
            HORIZONTAL = "horizontal",
            VERTICAL = "vertical",
            INSIDE = "inside",
            OUTSIDE = "outside",
            NONE = "none",
            HEIGHT = "height",
            WIDTH = "width",
            parseHorizontalAlignment = _enumParser([LEFT, CENTER, RIGHT]),
            parseVerticalAlignment = _enumParser([TOP, BOTTOM]),
            parseOrientation = _enumParser([VERTICAL, HORIZONTAL]),
            parseItemTextPosition = _enumParser([LEFT, RIGHT, TOP, BOTTOM]),
            parsePosition = _enumParser([OUTSIDE, INSIDE]),
            parseItemsAlignment = _enumParser([LEFT, CENTER, RIGHT]);

        function getPattern(renderer, states, action, color) {
            if (!states || !states[action]) {
                return
            }
            var hatching, direction = states[action].hatching.direction,
                colorFromAction = states[action].fill;
            color = colorFromAction === NONE ? color : colorFromAction;
            direction = !direction || direction === NONE ? RIGHT : direction;
            hatching = _extend({}, states[action].hatching, {
                direction: direction,
                step: DEFAULT_MARKER_HATCHING_STEP,
                width: DEFAULT_MARKER_HATCHING_WIDTH
            });
            return renderer.pattern(color, hatching)
        }

        function parseMargins(options) {
            var margin = options.margin;
            if (margin >= 0) {
                margin = _Number(options.margin);
                margin = {
                    top: margin,
                    bottom: margin,
                    left: margin,
                    right: margin
                }
            } else {
                margin = {
                    top: margin.top >= 0 ? _Number(margin.top) : DEFAULT_MARGIN,
                    bottom: margin.bottom >= 0 ? _Number(margin.bottom) : DEFAULT_MARGIN,
                    left: margin.left >= 0 ? _Number(margin.left) : DEFAULT_MARGIN,
                    right: margin.right >= 0 ? _Number(margin.right) : DEFAULT_MARGIN
                }
            }
            options.margin = margin
        }

        function getSizeItem(options, markerSize, labelBBox) {
            var width, height, defaultXMargin = 7,
                defaultTopMargin = 4;
            switch (options.itemTextPosition) {
                case LEFT:
                case RIGHT:
                    width = markerSize + defaultXMargin + labelBBox.width;
                    height = _max(markerSize, labelBBox.height);
                    break;
                case TOP:
                case BOTTOM:
                    width = _max(markerSize, labelBBox.width);
                    height = markerSize + defaultTopMargin + labelBBox.height
            }
            return {
                width: width,
                height: height
            }
        }

        function calculateBboxLabelAndMarker(markerBBox, labelBBox) {
            var bbox = {};
            bbox.left = _min(markerBBox.x, labelBBox.x);
            bbox.top = _min(markerBBox.y, labelBBox.y);
            bbox.right = _max(markerBBox.x + markerBBox.width, labelBBox.x + labelBBox.width);
            bbox.bottom = _max(markerBBox.y + markerBBox.height, labelBBox.y + labelBBox.height);
            return bbox
        }

        function applyMarkerState(id, idToIndexMap, items, stateName) {
            var item = idToIndexMap && items[idToIndexMap[id]];
            if (item) {
                item.marker.attr(item.states[stateName])
            }
        }

        function parseOptions(options, textField) {
            if (!options) {
                return null
            }
            var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
            debug.assertParam(options.visible, "Visibility was not passed");
            debug.assertParam(options.markerSize, "markerSize was not passed");
            debug.assertParam(options.font.color, "fontColor was not passed");
            debug.assertParam(options.font.family, "fontFamily was not passed");
            debug.assertParam(options.font.size, "fontSize was not passed");
            debug.assertParam(options.paddingLeftRight, "paddingLeftRight was not passed");
            debug.assertParam(options.paddingTopBottom, "paddingTopBottom was not passed");
            debug.assertParam(options.columnItemSpacing, "columnItemSpacing was not passed");
            debug.assertParam(options.rowItemSpacing, "rowItemSpacing was not passed");
            parseMargins(options);
            options.horizontalAlignment = parseHorizontalAlignment(options.horizontalAlignment, RIGHT);
            options.verticalAlignment = parseVerticalAlignment(options.verticalAlignment, options.horizontalAlignment === CENTER ? BOTTOM : TOP);
            options.orientation = parseOrientation(options.orientation, options.horizontalAlignment === CENTER ? HORIZONTAL : VERTICAL);
            options.itemTextPosition = parseItemTextPosition(options.itemTextPosition, options.orientation === HORIZONTAL ? BOTTOM : RIGHT);
            options.position = parsePosition(options.position, OUTSIDE);
            options.itemsAlignment = parseItemsAlignment(options.itemsAlignment, null);
            options.hoverMode = _normalizeEnum(options.hoverMode);
            options.customizeText = _isFunction(options.customizeText) ? options.customizeText : function() {
                return this[textField]
            };
            options.customizeHint = _isFunction(options.customizeHint) ? options.customizeHint : $.noop;
            options._incidentOccurred = options._incidentOccurred || $.noop;
            return options
        }

        function createSquareMarker(renderer, size) {
            return renderer.rect(0, 0, size, size)
        }

        function createCircleMarker(renderer, size) {
            return renderer.circle(size / 2, size / 2, size / 2)
        }

        function isCircle(type) {
            return "circle" === _normalizeEnum(type)
        }

        function getMarkerCreator(type) {
            return isCircle(type) ? createCircleMarker : createSquareMarker
        }

        function inRect(rect, x, y) {
            return x >= rect.left && x <= rect.right && y >= rect.top && y <= rect.bottom
        }

        function checkLinesSize(lines, layoutOptions, countItems) {
            var position = {
                    x: 0,
                    y: 0
                },
                maxMeasureLength = 0,
                maxOrtMeasureLength = 0;
            _each(lines, function(i, line) {
                var firstItem = line[0];
                _each(line, function(_, item) {
                    var offset = item.offset || layoutOptions.spacing;
                    position[layoutOptions.direction] += item[layoutOptions.measure] + offset;
                    maxMeasureLength = _max(maxMeasureLength, position[layoutOptions.direction])
                });
                position[layoutOptions.direction] = 0;
                position[layoutOptions.ortDirection] += firstItem[layoutOptions.ortMeasure] + firstItem.ortOffset || layoutOptions.ortSpacing;
                maxOrtMeasureLength = _max(maxOrtMeasureLength, position[layoutOptions.ortDirection])
            });
            if (maxMeasureLength > layoutOptions.length) {
                layoutOptions.countItem = decreaseItemCount(layoutOptions, countItems);
                return true
            }
        }

        function decreaseItemCount(layoutOptions, countItems) {
            layoutOptions.ortCountItem++;
            return _ceil(countItems / layoutOptions.ortCountItem)
        }

        function getLineLength(line, layoutOptions) {
            var lineLength = 0;
            _each(line, function(_, item) {
                var offset = item.offset || layoutOptions.spacing;
                lineLength += item[layoutOptions.measure] + offset
            });
            return lineLength
        }

        function getMaxLineLength(lines, layoutOptions) {
            var maxLineLength = 0;
            _each(lines, function(_, line) {
                maxLineLength = _max(maxLineLength, getLineLength(line, layoutOptions))
            });
            return maxLineLength
        }

        function getInitPositionForDirection(line, layoutOptions, maxLineLength) {
            var initPosition, lineLength = getLineLength(line, layoutOptions);
            switch (layoutOptions.itemsAlignment) {
                case RIGHT:
                    initPosition = maxLineLength - lineLength;
                    break;
                case CENTER:
                    initPosition = (maxLineLength - lineLength) / 2;
                    break;
                default:
                    initPosition = 0
            }
            return initPosition
        }

        function getPos(layoutOptions) {
            switch (layoutOptions.itemTextPosition) {
                case BOTTOM:
                    return {
                        horizontal: CENTER,
                        vertical: TOP
                    };
                case TOP:
                    return {
                        horizontal: CENTER,
                        vertical: BOTTOM
                    };
                case LEFT:
                    return {
                        horizontal: RIGHT,
                        vertical: CENTER
                    };
                case RIGHT:
                    return {
                        horizontal: LEFT,
                        vertical: CENTER
                    }
            }
        }

        function getLines(lines, layoutOptions, itemIndex) {
            var tableLine = {};
            if (itemIndex % layoutOptions.countItem === 0) {
                if (layoutOptions.markerOffset) {
                    lines.push([], [])
                } else {
                    lines.push([])
                }
            }
            if (layoutOptions.markerOffset) {
                tableLine.firstLine = lines[lines.length - 1];
                tableLine.secondLine = lines[lines.length - 2]
            } else {
                tableLine.firstLine = tableLine.secondLine = lines[lines.length - 1]
            }
            return tableLine
        }

        function setMaxInLine(line, measure) {
            var maxLineSize = 0;
            _each(line, function(_, item) {
                if (!item) {
                    return
                }
                maxLineSize = _max(maxLineSize, item[measure])
            });
            _each(line, function(_, item) {
                if (!item) {
                    return
                }
                item[measure] = maxLineSize
            })
        }

        function transpose(array) {
            var i, j, width = array.length,
                height = array[0].length,
                transposeArray = [];
            for (i = 0; i < height; i++) {
                transposeArray[i] = [];
                for (j = 0; j < width; j++) {
                    transposeArray[i][j] = array[j][i]
                }
            }
            return transposeArray
        }

        function getAlign(position) {
            switch (position) {
                case TOP:
                case BOTTOM:
                    return CENTER;
                case LEFT:
                    return RIGHT;
                case RIGHT:
                    return LEFT
            }
        }
        var _Legend = exports.Legend = function(settings) {
            var that = this;
            that._renderer = settings.renderer;
            that._legendGroup = settings.group;
            that._backgroundClass = settings.backgroundClass;
            that._itemGroupClass = settings.itemGroupClass;
            that._textField = settings.textField;
            that._getCustomizeObject = settings.getFormatObject;
            that._patterns = []
        };
        var legendPrototype = _Legend.prototype = objectUtils.clone(layoutElementModule.LayoutElement.prototype);
        $.extend(legendPrototype, {
            constructor: _Legend,
            update: function(data, options) {
                var that = this;
                that._data = data;
                that._boundingRect = {
                    width: 0,
                    height: 0,
                    x: 0,
                    y: 0
                };
                that._options = parseOptions(options, that._textField);
                return that
            },
            draw: function(width, height) {
                var that = this,
                    options = that._options,
                    renderer = that._renderer,
                    items = that._data;
                this._size = {
                    width: width,
                    height: height
                };
                that.erase();
                if (!(options && options.visible && items && items.length)) {
                    return that
                }
                that._insideLegendGroup = renderer.g().append(that._legendGroup);
                that._createBackground();
                that._createItems(that._getItemData());
                that._locateElements(options);
                that._finalUpdate(options);
                if (that.getLayoutOptions().width > width || that.getLayoutOptions().height > height) {
                    that._options._incidentOccurred("W2104");
                    that.erase()
                }
                return that
            },
            probeDraw: function(width, height) {
                return this.draw(width, height)
            },
            _createItems: function(items) {
                var bbox, that = this,
                    options = that._options,
                    initMarkerSize = options.markerSize,
                    renderer = that._renderer,
                    i = 0,
                    maxBboxHeight = 0,
                    createMarker = getMarkerCreator(options.markerShape || options.markerType);
                that._markersId = {};
                for (; i < that._patterns.length; i++) {
                    that._patterns[i].dispose()
                }
                that._patterns = [];
                that._items = vizUtils.map(items, function(dataItem, i) {
                    var group = that._insideLegendGroup,
                        markerSize = _Number(dataItem.size > 0 ? dataItem.size : initMarkerSize),
                        stateOfDataItem = dataItem.states,
                        normalState = stateOfDataItem.normal,
                        normalStateFill = normalState.fill,
                        marker = createMarker(renderer, markerSize).attr({
                            fill: normalStateFill || options.markerColor,
                            opacity: normalState.opacity
                        }).append(group),
                        label = that._createLabel(dataItem, group),
                        hoverPattern = getPattern(renderer, stateOfDataItem, "hover", normalStateFill),
                        selectionPattern = getPattern(renderer, stateOfDataItem, "selection", normalStateFill),
                        states = {
                            normal: {
                                fill: normalStateFill
                            }
                        },
                        labelBBox = label.getBBox();
                    if (hoverPattern) {
                        states.hovered = {
                            fill: hoverPattern.id
                        };
                        that._patterns.push(hoverPattern)
                    }
                    if (selectionPattern) {
                        states.selected = {
                            fill: selectionPattern.id
                        };
                        that._patterns.push(selectionPattern)
                    }
                    if (void 0 !== dataItem.id) {
                        that._markersId[dataItem.id] = i
                    }
                    bbox = getSizeItem(options, markerSize, labelBBox);
                    maxBboxHeight = _max(maxBboxHeight, bbox.height);
                    that._createHint(dataItem, label);
                    return {
                        label: label,
                        labelBBox: labelBBox,
                        group: group,
                        bbox: bbox,
                        marker: marker,
                        markerSize: markerSize,
                        tracker: {
                            id: dataItem.id,
                            argument: dataItem.argument
                        },
                        states: states,
                        itemTextPosition: options.itemTextPosition,
                        markerOffset: 0,
                        bboxs: []
                    }
                });
                if (options.equalRowHeight) {
                    _each(that._items, function(_, item) {
                        item.bbox.height = maxBboxHeight
                    })
                }
            },
            _getItemData: function() {
                var items = this._data;
                if (this._options.inverted) {
                    items = items.slice().reverse()
                }
                return items
            },
            _finalUpdate: function(options) {
                this._adjustBackgroundSettings(options);
                this._setBoundingRect(options.margin)
            },
            erase: function() {
                var that = this,
                    insideLegendGroup = that._insideLegendGroup;
                insideLegendGroup && insideLegendGroup.dispose();
                that._insideLegendGroup = that._x1 = that._x2 = that._y2 = that._y2 = null;
                return that
            },
            _locateElements: function(locationOptions) {
                this._moveInInitialValues();
                this._locateRowsColumns(locationOptions)
            },
            _moveInInitialValues: function() {
                var that = this;
                that._legendGroup && that._legendGroup.move(0, 0);
                that._background && that._background.attr({
                    x: 0,
                    y: 0,
                    width: 0,
                    height: 0
                })
            },
            applySelected: function(id) {
                applyMarkerState(id, this._markersId, this._items, "selected");
                return this
            },
            applyHover: function(id) {
                applyMarkerState(id, this._markersId, this._items, "hovered");
                return this
            },
            resetItem: function(id) {
                applyMarkerState(id, this._markersId, this._items, "normal");
                return this
            },
            _createLabel: function(data, group) {
                var labelFormatObject = this._getCustomizeObject(data),
                    align = getAlign(this._options.itemTextPosition),
                    text = this._options.customizeText.call(labelFormatObject, labelFormatObject),
                    fontStyle = _isDefined(data.textOpacity) ? _extend({}, this._options.font, {
                        opacity: data.textOpacity
                    }) : this._options.font;
                return this._renderer.text(text, 0, 0).css(vizUtils.patchFontOptions(fontStyle)).attr({
                    align: align
                }).append(group)
            },
            _createHint: function(data, label) {
                var labelFormatObject = this._getCustomizeObject(data),
                    text = this._options.customizeHint.call(labelFormatObject, labelFormatObject);
                if (_isDefined(text) && "" !== text) {
                    label.setTitle(text)
                }
            },
            _createBackground: function() {
                var that = this,
                    isInside = that._options.position === INSIDE,
                    color = that._options.backgroundColor,
                    fill = color || (isInside ? that._options.containerBackgroundColor : NONE);
                if (that._options.border.visible || (isInside || color) && color !== NONE) {
                    that._background = that._renderer.rect(0, 0, 0, 0).attr({
                        fill: fill,
                        "class": that._backgroundClass
                    }).append(that._insideLegendGroup)
                }
            },
            _locateRowsColumns: function() {
                var lines, that = this,
                    iteration = 0,
                    layoutOptions = that._getItemsLayoutOptions(),
                    countItems = that._items.length;
                do {
                    lines = [];
                    that._createLines(lines, layoutOptions);
                    that._alignLines(lines, layoutOptions);
                    iteration++
                } while (checkLinesSize(lines, layoutOptions, countItems) && iteration < countItems);
                that._applyItemPosition(lines, layoutOptions)
            },
            _createLines: function(lines, layoutOptions) {
                _each(this._items, function(i, item) {
                    var firstItem, secondItem, tableLine = getLines(lines, layoutOptions, i),
                        labelBox = {
                            width: item.labelBBox.width,
                            height: item.labelBBox.height,
                            element: item.label,
                            bbox: item.labelBBox,
                            pos: getPos(layoutOptions),
                            itemIndex: i
                        },
                        markerBox = {
                            width: item.markerSize,
                            height: item.markerSize,
                            element: item.marker,
                            pos: {
                                horizontal: CENTER,
                                vertical: CENTER
                            },
                            bbox: {
                                width: item.markerSize,
                                height: item.markerSize,
                                x: 0,
                                y: 0
                            },
                            itemIndex: i
                        },
                        offsetDirection = layoutOptions.markerOffset ? "ortOffset" : "offset";
                    if (layoutOptions.inverseLabelPosition) {
                        firstItem = labelBox;
                        secondItem = markerBox
                    } else {
                        firstItem = markerBox;
                        secondItem = labelBox
                    }
                    firstItem[offsetDirection] = layoutOptions.labelOffset;
                    tableLine.secondLine.push(firstItem);
                    tableLine.firstLine.push(secondItem)
                })
            },
            _alignLines: function(lines, layoutOptions) {
                var i, measure = layoutOptions.ortMeasure;
                _each(lines, processLine);
                measure = layoutOptions.measure;
                if (layoutOptions.itemsAlignment) {
                    if (layoutOptions.markerOffset) {
                        for (i = 0; i < lines.length;) {
                            _each(transpose([lines[i++], lines[i++]]), processLine)
                        }
                    }
                } else {
                    _each(transpose(lines), processLine)
                }

                function processLine(_, line) {
                    setMaxInLine(line, measure)
                }
            },
            _applyItemPosition: function(lines, layoutOptions) {
                var that = this,
                    position = {
                        x: 0,
                        y: 0
                    },
                    maxLineLength = getMaxLineLength(lines, layoutOptions),
                    itemIndex = 0;
                _each(lines, function(i, line) {
                    var firstItem = line[0],
                        ortOffset = firstItem.ortOffset || layoutOptions.ortSpacing;
                    position[layoutOptions.direction] = getInitPositionForDirection(line, layoutOptions, maxLineLength);
                    _each(line, function(_, item) {
                        var offset = item.offset || layoutOptions.spacing,
                            wrap = new layoutElementModule.WrapperLayoutElement(item.element, item.bbox),
                            itemBBox = new layoutElementModule.WrapperLayoutElement(null, {
                                x: position.x,
                                y: position.y,
                                width: item.width,
                                height: item.height
                            }),
                            itemLegend = that._items[item.itemIndex];
                        wrap.position({
                            of: itemBBox,
                            my: item.pos,
                            at: item.pos
                        });
                        itemLegend.bboxs.push(itemBBox);
                        position[layoutOptions.direction] += item[layoutOptions.measure] + offset;
                        itemIndex++
                    });
                    position[layoutOptions.ortDirection] += firstItem[layoutOptions.ortMeasure] + ortOffset
                });
                _each(this._items, function(_, item) {
                    var itemBBox = calculateBboxLabelAndMarker(item.bboxs[0].getLayoutOptions(), item.bboxs[1].getLayoutOptions()),
                        horizontal = that._options.columnItemSpacing / 2,
                        vertical = that._options.rowItemSpacing / 2;
                    item.tracker.left = itemBBox.left - horizontal;
                    item.tracker.right = itemBBox.right + horizontal;
                    item.tracker.top = itemBBox.top - vertical;
                    item.tracker.bottom = itemBBox.bottom + vertical
                })
            },
            _getItemsLayoutOptions: function() {
                var that = this,
                    options = that._options,
                    orientation = options.orientation,
                    layoutOptions = {
                        itemsAlignment: options.itemsAlignment,
                        orientation: options.orientation
                    },
                    width = that._size.width - (that._background ? 2 * options.paddingLeftRight : 0),
                    height = that._size.height - (that._background ? 2 * options.paddingTopBottom : 0);
                if (orientation === HORIZONTAL) {
                    layoutOptions.length = width;
                    layoutOptions.spacing = options.columnItemSpacing;
                    layoutOptions.direction = "x";
                    layoutOptions.measure = WIDTH;
                    layoutOptions.ortMeasure = HEIGHT;
                    layoutOptions.ortDirection = "y";
                    layoutOptions.ortSpacing = options.rowItemSpacing;
                    layoutOptions.countItem = options.columnCount;
                    layoutOptions.ortCountItem = options.rowCount;
                    layoutOptions.marginTextLabel = 4;
                    layoutOptions.labelOffset = 7;
                    if (options.itemTextPosition === BOTTOM || options.itemTextPosition === TOP) {
                        layoutOptions.labelOffset = 4;
                        layoutOptions.markerOffset = true
                    }
                } else {
                    layoutOptions.length = height;
                    layoutOptions.spacing = options.rowItemSpacing;
                    layoutOptions.direction = "y";
                    layoutOptions.measure = HEIGHT;
                    layoutOptions.ortMeasure = WIDTH;
                    layoutOptions.ortDirection = "x";
                    layoutOptions.ortSpacing = options.columnItemSpacing;
                    layoutOptions.countItem = options.rowCount;
                    layoutOptions.ortCountItem = options.columnCount;
                    layoutOptions.marginTextLabel = 7;
                    layoutOptions.labelOffset = 4;
                    if (options.itemTextPosition === RIGHT || options.itemTextPosition === LEFT) {
                        layoutOptions.labelOffset = 7;
                        layoutOptions.markerOffset = true
                    }
                }
                if (!layoutOptions.countItem) {
                    if (layoutOptions.ortCountItem) {
                        layoutOptions.countItem = _ceil(that._items.length / layoutOptions.ortCountItem)
                    } else {
                        layoutOptions.countItem = that._items.length
                    }
                }
                if (options.itemTextPosition === TOP || options.itemTextPosition === LEFT) {
                    layoutOptions.inverseLabelPosition = true
                }
                layoutOptions.itemTextPosition = options.itemTextPosition;
                layoutOptions.ortCountItem = layoutOptions.ortCountItem || _ceil(that._items.length / layoutOptions.countItem);
                return layoutOptions
            },
            _adjustBackgroundSettings: function(locationOptions) {
                if (!this._background) {
                    return
                }
                var border = locationOptions.border,
                    legendBox = this._insideLegendGroup.getBBox(),
                    backgroundSettings = {
                        x: _round(legendBox.x - locationOptions.paddingLeftRight),
                        y: _round(legendBox.y - locationOptions.paddingTopBottom),
                        width: _round(legendBox.width) + 2 * locationOptions.paddingLeftRight,
                        height: _round(legendBox.height) + 2 * locationOptions.paddingTopBottom,
                        opacity: locationOptions.backgroundOpacity
                    };
                if (border.visible && border.width && border.color && border.color !== NONE) {
                    backgroundSettings["stroke-width"] = border.width;
                    backgroundSettings.stroke = border.color;
                    backgroundSettings["stroke-opacity"] = border.opacity;
                    backgroundSettings.dashStyle = border.dashStyle;
                    backgroundSettings.rx = border.cornerRadius || 0;
                    backgroundSettings.ry = border.cornerRadius || 0
                }
                this._background.attr(backgroundSettings)
            },
            _setBoundingRect: function(margin) {
                if (!this._insideLegendGroup) {
                    return
                }
                var box = this._insideLegendGroup.getBBox();
                box.height += margin.top + margin.bottom;
                box.width += margin.left + margin.right;
                box.x -= margin.left;
                box.y -= margin.top;
                this._boundingRect = box
            },
            getActionCallback: function(point) {
                var that = this;
                if (that._options.visible) {
                    return function(act) {
                        that[act](point.index)
                    }
                } else {
                    return $.noop
                }
            },
            getLayoutOptions: function() {
                var options = this._options,
                    boundingRect = this._insideLegendGroup ? this._boundingRect : {
                        width: 0,
                        height: 0,
                        x: 0,
                        y: 0
                    };
                if (options) {
                    boundingRect.verticalAlignment = options.verticalAlignment;
                    boundingRect.horizontalAlignment = options.horizontalAlignment;
                    if (options.orientation === HORIZONTAL) {
                        boundingRect.cutLayoutSide = options.verticalAlignment;
                        boundingRect.cutSide = "vertical"
                    } else {
                        if (options.horizontalAlignment === CENTER) {
                            boundingRect.cutLayoutSide = options.verticalAlignment;
                            boundingRect.cutSide = "vertical"
                        } else {
                            boundingRect.cutLayoutSide = options.horizontalAlignment;
                            boundingRect.cutSide = "horizontal"
                        }
                    }
                    boundingRect.position = {
                        horizontal: options.horizontalAlignment,
                        vertical: options.verticalAlignment
                    };
                    return boundingRect
                }
                return null
            },
            shift: function(x, y) {
                var that = this,
                    box = {};
                if (that._insideLegendGroup) {
                    that._insideLegendGroup.attr({
                        translateX: x - that._boundingRect.x,
                        translateY: y - that._boundingRect.y
                    });
                    box = that._legendGroup.getBBox()
                }
                that._x1 = box.x;
                that._y1 = box.y;
                that._x2 = box.x + box.width;
                that._y2 = box.y + box.height;
                return that
            },
            getPosition: function() {
                return this._options.position
            },
            coordsIn: function(x, y) {
                return x >= this._x1 && x <= this._x2 && y >= this._y1 && y <= this._y2
            },
            getItemByCoord: function(x, y) {
                var items = this._items,
                    legendGroup = this._insideLegendGroup;
                x -= legendGroup.attr("translateX");
                y -= legendGroup.attr("translateY");
                for (var i = 0; i < items.length; i++) {
                    if (inRect(items[i].tracker, x, y)) {
                        return items[i].tracker
                    }
                }
                return null
            },
            dispose: function() {
                var that = this;
                that._legendGroup = that._insideLegendGroup = that._renderer = that._options = that._data = that._items = null;
                return that
            }
        });
        var __getMarkerCreator = getMarkerCreator;
        exports._DEBUG_stubMarkerCreator = function(callback) {
            getMarkerCreator = function() {
                return callback
            }
        };
        exports._DEBUG_restoreMarkerCreator = function() {
            getMarkerCreator = __getMarkerCreator
        }
    },
    /*!********************************************!*\
      !*** ./Scripts/viz/core/layout_element.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _round = Math.round,
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            defaultOffset = {
                horizontal: 0,
                vertical: 0
            },
            alignFactors = {
                center: .5,
                right: 1,
                bottom: 1,
                left: 0,
                top: 0
            };

        function LayoutElement(options) {
            this._options = options
        }
        LayoutElement.prototype = {
            constructor: LayoutElement,
            position: function(options) {
                var that = this,
                    ofBBox = options.of.getLayoutOptions(),
                    myBBox = that.getLayoutOptions(),
                    at = options.at,
                    my = options.my,
                    offset = options.offset || defaultOffset,
                    shiftX = -alignFactors[my.horizontal] * myBBox.width + ofBBox.x + alignFactors[at.horizontal] * ofBBox.width + parseInt(offset.horizontal),
                    shiftY = -alignFactors[my.vertical] * myBBox.height + ofBBox.y + alignFactors[at.vertical] * ofBBox.height + parseInt(offset.vertical);
                that.shift(_round(shiftX), _round(shiftY))
            },
            getLayoutOptions: $.noop,
            getVerticalCuttedSize: function(canvas) {
                var that = this,
                    height = canvas.height,
                    top = canvas.top,
                    bottom = canvas.bottom,
                    layoutOptions = that.getLayoutOptions();
                if (layoutOptions) {
                    that.draw(canvas.width, canvas.height);
                    layoutOptions = that.getLayoutOptions();
                    if (layoutOptions) {
                        height -= layoutOptions.height;
                        if ("bottom" === layoutOptions.position.vertical) {
                            bottom += layoutOptions.height
                        } else {
                            top += layoutOptions.height
                        }
                    }
                }
                return {
                    left: canvas.left,
                    right: canvas.right,
                    top: top,
                    bottom: bottom,
                    width: canvas.width,
                    height: height
                }
            }
        };

        function WrapperLayoutElement(renderElement, bbox) {
            this._renderElement = renderElement;
            this._cacheBBox = bbox
        }
        var wrapperLayoutElementPrototype = WrapperLayoutElement.prototype = objectUtils.clone(LayoutElement.prototype);
        wrapperLayoutElementPrototype.constructor = WrapperLayoutElement;
        wrapperLayoutElementPrototype.getLayoutOptions = function() {
            return this._cacheBBox || this._renderElement.getBBox()
        };
        wrapperLayoutElementPrototype.shift = function(shiftX, shiftY) {
            var bbox = this.getLayoutOptions();
            this._renderElement.move(_round(shiftX - bbox.x), _round(shiftY - bbox.y))
        };
        exports.LayoutElement = LayoutElement;
        exports.WrapperLayoutElement = WrapperLayoutElement
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/components/data_validator.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            STRING = "string",
            NUMERIC = "numeric",
            DATETIME = "datetime",
            DISCRETE = "discrete",
            SEMIDISCRETE = "semidiscrete",
            CONTINUOUS = "continuous",
            LOGARITHMIC = "logarithmic",
            VALUE_TYPE = "valueType",
            ARGUMENT_TYPE = "argumentType",
            axisTypeParser = __webpack_require__( /*! ../core/utils */ 442).enumParser([STRING, NUMERIC, DATETIME]),
            _getParser = __webpack_require__( /*! ./parse_utils */ 459).getParser,
            _isDefined = commonUtils.isDefined,
            _isFunction = commonUtils.isFunction,
            _isArray = commonUtils.isArray,
            _isString = commonUtils.isString,
            _isDate = commonUtils.isDate,
            _isNumber = commonUtils.isNumber,
            _isObject = commonUtils.isObject,
            _each = $.each;

        function groupingValues(data, others, valueField, index) {
            if (index >= 0) {
                _each(data.slice(index), function(_, cell) {
                    if (_isDefined(cell[valueField])) {
                        others[valueField] += cell[valueField];
                        cell[valueField] = cell["original" + valueField] = void 0
                    }
                })
            }
        }

        function processGroup(_, group) {
            group.valueType = group.valueAxisType = null;
            _each(group.series, processSeries);
            group.valueAxis && group.valueAxis.resetTypes(VALUE_TYPE)
        }

        function parseCategories(categories, parser) {
            var newArray = [];
            _each(categories, function(_, category) {
                var parsedCategory = parser(category);
                void 0 !== parsedCategory && newArray.push(parsedCategory)
            });
            return newArray
        }

        function parseAxisCategories(groupsData, parsers) {
            var argumentCategories = groupsData.argumentOptions && groupsData.argumentOptions.categories,
                valueParser = parsers[1];
            _each(groupsData.groups, function(_, valueGroup) {
                var categories = valueGroup.valueOptions && valueGroup.valueOptions.categories;
                if (categories) {
                    valueGroup.valueOptions.categories = parseCategories(categories, valueParser)
                }
            });
            if (argumentCategories) {
                groupsData.argumentOptions.categories = parseCategories(argumentCategories, parsers[0])
            }
        }

        function processSeries(_, series) {
            series.updateDataType({})
        }

        function resetAxisTypes(_, axis) {
            axis.resetTypes(ARGUMENT_TYPE)
        }

        function filterForLogAxis(val, field, incidentOccurred) {
            if (val <= 0) {
                incidentOccurred("E2004", [field]);
                val = null
            }
            return val
        }

        function eigen(x) {
            return x
        }

        function getType(unit, type) {
            var result = type;
            if (type === STRING || _isString(unit)) {
                result = STRING
            } else {
                if (type === DATETIME || _isDate(unit)) {
                    result = DATETIME
                } else {
                    if (_isNumber(unit)) {
                        result = NUMERIC
                    }
                }
            }
            return result
        }

        function correctAxisType(type, axisType, hasCategories, incidentOccurred) {
            if (type === STRING && (axisType === CONTINUOUS || axisType === LOGARITHMIC || axisType === SEMIDISCRETE)) {
                incidentOccurred("E2002")
            }
            return axisType === LOGARITHMIC ? LOGARITHMIC : hasCategories || axisType === DISCRETE || type === STRING ? DISCRETE : axisType === SEMIDISCRETE ? SEMIDISCRETE : CONTINUOUS
        }

        function validUnit(unit, field, incidentOccurred) {
            if (unit) {
                incidentOccurred(!_isNumber(unit) && !_isDate(unit) && !_isString(unit) ? "E2003" : "E2004", [field])
            }
        }

        function createParserUnit(type, axisType, ignoreEmptyPoints, skipFields, incidentOccurred) {
            var parser = type ? _getParser(type) : eigen,
                filter = axisType === LOGARITHMIC ? filterForLogAxis : eigen;
            return function(unit, field) {
                var parseUnit = filter(parser(unit), field, incidentOccurred);
                null === parseUnit && ignoreEmptyPoints && (parseUnit = void 0);
                if (void 0 === parseUnit) {
                    skipFields[field] = (skipFields[field] || 0) + 1;
                    validUnit(unit, field, incidentOccurred)
                }
                return parseUnit
            }
        }

        function prepareParsers(groupsData, skipFields, incidentOccurred) {
            var sizeParser, valueParser, iep, argumentParser = createParserUnit(groupsData.argumentType, groupsData.argumentAxisType, false, skipFields, incidentOccurred),
                categoryParsers = [argumentParser],
                cache = {},
                list = [];
            _each(groupsData.groups, function(_, group) {
                _each(group.series, function(_, series) {
                    iep = series.getOptions().ignoreEmptyPoints;
                    valueParser = createParserUnit(group.valueType, group.valueAxisType, iep, skipFields, incidentOccurred);
                    sizeParser = createParserUnit(NUMERIC, CONTINUOUS, iep, skipFields, incidentOccurred);
                    cache[series.getArgumentField()] = argumentParser;
                    _each(series.getValueFields(), function(_, field) {
                        !categoryParsers[1] && (categoryParsers[1] = valueParser);
                        cache[field] = valueParser
                    });
                    if (series.getSizeField()) {
                        cache[series.getSizeField()] = sizeParser
                    }
                    if (series.getTagField()) {
                        cache[series.getTagField()] = eigen
                    }
                })
            });
            _each(cache, function(field, parser) {
                list.push([field, parser])
            });
            list.length && parseAxisCategories(groupsData, categoryParsers);
            return list
        }

        function getParsedCell(cell, parsers) {
            var i, field, value, ii = parsers.length,
                obj = {};
            for (i = 0; i < ii; ++i) {
                field = parsers[i][0];
                value = cell[field];
                obj[field] = parsers[i][1](value, field);
                obj["original" + field] = value
            }
            return obj
        }

        function parse(data, parsers) {
            var i, parsedData = [],
                ii = data.length;
            parsedData.length = ii;
            for (i = 0; i < ii; ++i) {
                parsedData[i] = getParsedCell(data[i], parsers)
            }
            return parsedData
        }

        function findIndexByThreshold(data, valueField, threshold) {
            var i, value, ii = data.length;
            for (i = 0; i < ii; ++i) {
                value = data[i][valueField];
                if (_isDefined(value) && threshold > value) {
                    break
                }
            }
            return i
        }

        function groupMinSlices(originalData, argumentField, valueField, smallValuesGrouping) {
            smallValuesGrouping = smallValuesGrouping || {};
            var data, mode = smallValuesGrouping.mode,
                others = {};
            if (!mode || "none" === mode) {
                return
            }
            others[argumentField] = String(smallValuesGrouping.groupName || "others");
            others[valueField] = 0;
            data = originalData.slice();
            data.sort(function(a, b) {
                var isA = _isDefined(a[valueField]) ? 1 : 0,
                    isB = _isDefined(b[valueField]) ? 1 : 0;
                return isA && isB ? b[valueField] - a[valueField] : isB - isA
            });
            groupingValues(data, others, valueField, "smallValueThreshold" === mode ? findIndexByThreshold(data, valueField, smallValuesGrouping.threshold) : smallValuesGrouping.topCount);
            others[valueField] && originalData.push(others)
        }

        function groupPieData(data, groupsData) {
            var firstSeries = groupsData.groups[0] && groupsData.groups[0].series[0],
                isPie = firstSeries && ("pie" === firstSeries.type || "doughnut" === firstSeries.type || "donut" === firstSeries.type);
            if (!isPie) {
                return
            }
            _each(groupsData.groups, function(_, group) {
                _each(group.series, function(_, series) {
                    groupMinSlices(data, series.getArgumentField(), series.getValueFields()[0], series.getOptions().smallValuesGrouping)
                })
            })
        }

        function addUniqueItemToCollection(item, collection, itemsHash) {
            if (!itemsHash[item]) {
                collection.push(item);
                itemsHash[item] = true
            }
        }

        function getUniqueArgumentFields(groupsData) {
            var uniqueArgumentFields = [],
                hash = {};
            _each(groupsData.groups, function(_, group) {
                _each(group.series, function(__, series) {
                    addUniqueItemToCollection(series.getArgumentField(), uniqueArgumentFields, hash)
                })
            });
            return uniqueArgumentFields
        }

        function discreteDataProcessing(data, groupsData, userArgumentCategories, uniqueArgumentFields) {
            var categories = groupsData.categories = $.extend([], userArgumentCategories),
                hash = {};
            categories.length && _each(categories, function(_, currentCategory) {
                hash[currentCategory] = true
            });
            _each(uniqueArgumentFields, function(_, field) {
                _each(data, function(_, item) {
                    _isDefined(item[field]) && addUniqueItemToCollection(item[field], categories, hash)
                })
            })
        }

        function compareWithoutHash(argumentField) {
            return function(a, b) {
                var cmpResult = a[argumentField] - b[argumentField];
                if (isNaN(cmpResult)) {
                    if (!a[argumentField]) {
                        return 1
                    }
                    if (!b[argumentField]) {
                        return -1
                    }
                    return 0
                }
                return cmpResult
            }
        }

        function sort(data, groupsData, sortingMethodOption, uniqueArgumentFields) {
            var getSortingMethod, itemsHash = {},
                dataByArguments = {},
                getSortMethodByType = function(sortingByHash, hash) {
                    return sortingByHash ? function(argumentField) {
                        return function(a, b) {
                            return hash[a[argumentField]] - hash[b[argumentField]]
                        }
                    } : compareWithoutHash
                };
            if (_isFunction(sortingMethodOption)) {
                data.sort(sortingMethodOption)
            } else {
                if (groupsData.categories) {
                    _each(groupsData.categories, function(index, value) {
                        itemsHash[value] = index
                    });
                    getSortingMethod = getSortMethodByType(true, itemsHash)
                } else {
                    if (true === sortingMethodOption && groupsData.argumentType !== STRING) {
                        getSortingMethod = getSortMethodByType(false, itemsHash)
                    }
                }
            }
            _each(uniqueArgumentFields, function(_, argumentField) {
                var sortMethod, currentDataItem;
                if (getSortingMethod) {
                    sortMethod = getSortingMethod(argumentField);
                    currentDataItem = data.slice().sort(sortMethod)
                } else {
                    currentDataItem = data
                }
                dataByArguments[argumentField] = currentDataItem
            });
            return dataByArguments
        }

        function checkValueTypeOfGroup(group, cell) {
            _each(group.series, function(_, series) {
                _each(series.getValueFields(), function(_, field) {
                    group.valueType = getType(cell[field], group.valueType)
                })
            });
            return group.valueType
        }

        function checkArgumentTypeOfGroup(series, cell, groupsData) {
            _each(series, function(_, currentCeries) {
                groupsData.argumentType = getType(cell[currentCeries.getArgumentField()], groupsData.argumentType)
            });
            return groupsData.argumentType
        }

        function checkType(data, groupsData, checkTypeForAllData) {
            var groupsIndexes, groupsWithUndefinedValueType = [],
                groupsWithUndefinedArgumentType = [],
                argumentTypeGroup = groupsData.argumentOptions && axisTypeParser(groupsData.argumentOptions.argumentType);
            _each(groupsData.groups, function(_, group) {
                if (!group.series.length) {
                    return null
                }
                var valueTypeGroup = group.valueOptions && axisTypeParser(group.valueOptions.valueType);
                group.valueType = valueTypeGroup;
                groupsData.argumentType = argumentTypeGroup;
                !valueTypeGroup && groupsWithUndefinedValueType.push(group);
                !argumentTypeGroup && groupsWithUndefinedArgumentType.push(group)
            });
            if (groupsWithUndefinedValueType.length || groupsWithUndefinedArgumentType.length) {
                groupsIndexes = groupsWithUndefinedValueType.map(function(_, index) {
                    return index
                });
                _each(data, function(_, cell) {
                    var defineArg;
                    _each(groupsWithUndefinedValueType, function(groupIndex, group) {
                        if (checkValueTypeOfGroup(group, cell) && groupsIndexes.indexOf(groupIndex) >= 0) {
                            groupsIndexes.splice(groupIndex, 1)
                        }
                    });
                    if (!defineArg) {
                        _each(groupsWithUndefinedArgumentType, function(_, group) {
                            defineArg = checkArgumentTypeOfGroup(group.series, cell, groupsData)
                        })
                    }
                    if (!checkTypeForAllData && defineArg && 0 === groupsIndexes.length) {
                        return false
                    }
                })
            }
        }

        function checkAxisType(groupsData, userArgumentCategories, incidentOccurred) {
            var argumentOptions = groupsData.argumentOptions || {},
                argumentAxisType = correctAxisType(groupsData.argumentType, argumentOptions.type, !!userArgumentCategories.length, incidentOccurred);
            _each(groupsData.groups, function(_, group) {
                var valueOptions = group.valueOptions || {},
                    valueCategories = valueOptions.categories || [],
                    valueAxisType = correctAxisType(group.valueType, valueOptions.type, !!valueCategories.length, incidentOccurred);
                _each(group.series, function(_, series) {
                    var optionsSeries = {};
                    optionsSeries.argumentAxisType = argumentAxisType;
                    optionsSeries.valueAxisType = valueAxisType;
                    groupsData.argumentAxisType = groupsData.argumentAxisType || optionsSeries.argumentAxisType;
                    group.valueAxisType = group.valueAxisType || optionsSeries.valueAxisType;
                    optionsSeries.argumentType = groupsData.argumentType;
                    optionsSeries.valueType = group.valueType;
                    optionsSeries.showZero = valueOptions.showZero;
                    series.updateDataType(optionsSeries)
                });
                group.valueAxisType = group.valueAxisType || valueAxisType;
                if (group.valueAxis) {
                    group.valueAxis.setTypes(group.valueAxisType, group.valueType, VALUE_TYPE);
                    group.valueAxis.validate(false)
                }
            });
            groupsData.argumentAxisType = groupsData.argumentAxisType || argumentAxisType;
            if (groupsData.argumentAxes) {
                _each(groupsData.argumentAxes, function(_, axis) {
                    axis.setTypes(groupsData.argumentAxisType, groupsData.argumentType, ARGUMENT_TYPE);
                    axis.validate(true)
                })
            }
        }

        function verifyData(source, incidentOccurred) {
            var i, ii, k, item, data = [],
                hasError = !_isArray(source);
            if (!hasError) {
                for (i = 0, ii = source.length, k = 0; i < ii; ++i) {
                    item = source[i];
                    if (_isObject(item)) {
                        data[k++] = item
                    } else {
                        if (item) {
                            hasError = true
                        }
                    }
                }
            }
            if (hasError) {
                incidentOccurred("E2001")
            }
            return data
        }

        function validateData(data, groupsData, incidentOccurred, options) {
            var parsers, dataLength, categoriesInAxisType, dataByArgumentFields, skipFields = {},
                argumentOptions = groupsData.argumentOptions,
                userArgumentCategories = argumentOptions && argumentOptions.categories || [],
                uniqueArgumentFields = getUniqueArgumentFields(groupsData);
            data = verifyData(data, incidentOccurred);
            groupsData.argumentType = groupsData.argumentAxisType = null;
            _each(groupsData.groups, processGroup);
            if (groupsData.argumentAxes) {
                _each(groupsData.argumentAxes, resetAxisTypes)
            }
            checkType(data, groupsData, options.checkTypeForAllData);
            checkAxisType(groupsData, userArgumentCategories, incidentOccurred);
            if (options.convertToAxisDataType) {
                parsers = prepareParsers(groupsData, skipFields, incidentOccurred);
                data = parse(data, parsers)
            }
            groupPieData(data, groupsData);
            categoriesInAxisType = argumentOptions && argumentOptions.categories || [];
            groupsData.argumentAxisType === DISCRETE && discreteDataProcessing(data, groupsData, categoriesInAxisType, uniqueArgumentFields);
            dataByArgumentFields = sort(data, groupsData, options.sortingMethod, uniqueArgumentFields);
            dataLength = data.length;
            _each(skipFields, function(field, fieldValue) {
                if (fieldValue === dataLength) {
                    incidentOccurred("W2002", [field])
                }
            });
            return dataByArgumentFields
        }
        exports.validateData = validateData;
        exports.DEBUG_validateData_sort = sort
    },
    /*!***********************************************!*\
      !*** ./Scripts/viz/components/parse_utils.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isDefined = commonUtils.isDefined,
            parsers = {
                string: function(val) {
                    return isDefined(val) ? "" + val : val
                },
                numeric: function(val) {
                    if (!isDefined(val)) {
                        return val
                    }
                    var parsedVal = Number(val);
                    if (isNaN(parsedVal)) {
                        parsedVal = void 0
                    }
                    return parsedVal
                },
                datetime: function(val) {
                    if (!isDefined(val)) {
                        return val
                    }
                    var parsedVal, numVal = Number(val);
                    if (!isNaN(numVal)) {
                        parsedVal = new Date(numVal)
                    } else {
                        parsedVal = new Date(val)
                    }
                    if (isNaN(Number(parsedVal))) {
                        parsedVal = void 0
                    }
                    return parsedVal
                }
            };

        function correctValueType(type) {
            return "numeric" === type || "datetime" === type || "string" === type ? type : ""
        }
        module.exports = {
            correctValueType: correctValueType,
            getParser: function(valueType) {
                return parsers[correctValueType(valueType)] || $.noop
            }
        };
        module.exports.parsers = parsers
    },
    /*!*******************************************!*\
      !*** ./Scripts/viz/series/base_series.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            seriesNS = {},
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            pointModule = __webpack_require__( /*! ./points/base_point */ 461),
            _isDefined = commonUtils.isDefined,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _map = vizUtils.map,
            _each = $.each,
            _extend = $.extend,
            _isEmptyObject = $.isEmptyObject,
            _normalizeEnum = vizUtils.normalizeEnum,
            _Event = $.Event,
            _noop = $.noop,
            _inArray = $.inArray,
            states = __webpack_require__( /*! ../components/consts */ 462).states,
            scatterSeries = __webpack_require__( /*! ./scatter_series */ 474),
            lineSeries = __webpack_require__( /*! ./line_series */ 476),
            areaSeries = __webpack_require__( /*! ./area_series */ 477),
            barSeries = __webpack_require__( /*! ./bar_series */ 478),
            rangeSeries = __webpack_require__( /*! ./range_series */ 479),
            bubbleSeries = __webpack_require__( /*! ./bubble_series */ 480),
            pieSeries = __webpack_require__( /*! ./pie_series */ 481),
            financialSeries = __webpack_require__( /*! ./financial_series */ 482),
            stackedSeries = __webpack_require__( /*! ./stacked_series */ 483),
            DISCRETE = "discrete",
            SELECTED_STATE = states.selectedMark,
            HOVER_STATE = states.hoverMark,
            HOVER = states.hover,
            NORMAL = states.normal,
            SELECTION = states.selection,
            APPLY_SELECTED = states.applySelected,
            APPLY_HOVER = states.applyHover,
            RESET_ITEM = states.resetItem,
            NONE_MODE = "none",
            INCLUDE_POINTS = "includepoints",
            EXLUDE_POINTS = "excludepoints",
            NEAREST_POINT = "nearestpoint",
            getEmptyBusinessRange = function() {
                return {
                    arg: {},
                    val: {}
                }
            };

        function triggerEvent(element, event, point) {
            element && element.trigger(event, point)
        }
        seriesNS.mixins = {
            chart: {},
            pie: {},
            polar: {}
        };
        seriesNS.mixins.chart.scatter = scatterSeries.chart;
        seriesNS.mixins.polar.scatter = scatterSeries.polar;
        $.extend(seriesNS.mixins.pie, pieSeries);
        $.extend(seriesNS.mixins.chart, lineSeries.chart, areaSeries.chart, barSeries.chart, rangeSeries.chart, bubbleSeries.chart, financialSeries, stackedSeries.chart);
        $.extend(seriesNS.mixins.polar, lineSeries.polar, areaSeries.polar, barSeries.polar, rangeSeries.polar, bubbleSeries.polar, stackedSeries.polar);

        function includePointsMode(mode) {
            return mode === INCLUDE_POINTS || "allseriespoints" === mode
        }

        function getLabelOptions(labelOptions, defaultColor) {
            var opt = labelOptions || {},
                labelFont = _extend({}, opt.font) || {},
                labelBorder = opt.border || {},
                labelConnector = opt.connector || {},
                backgroundAttr = {
                    fill: opt.backgroundColor || defaultColor,
                    "stroke-width": labelBorder.visible ? labelBorder.width || 0 : 0,
                    stroke: labelBorder.visible && labelBorder.width ? labelBorder.color : "none",
                    dashStyle: labelBorder.dashStyle
                },
                connectorAttr = {
                    stroke: labelConnector.visible && labelConnector.width ? labelConnector.color || defaultColor : "none",
                    "stroke-width": labelConnector.visible ? labelConnector.width || 0 : 0
                };
            labelFont.color = "none" === opt.backgroundColor && "#ffffff" === _normalizeEnum(labelFont.color) && "inside" !== opt.position ? defaultColor : labelFont.color;
            return {
                alignment: opt.alignment,
                format: opt.format,
                argumentFormat: opt.argumentFormat,
                precision: opt.precision,
                argumentPrecision: opt.argumentPrecision,
                percentPrecision: opt.percentPrecision,
                customizeText: $.isFunction(opt.customizeText) ? opt.customizeText : void 0,
                attributes: {
                    font: labelFont
                },
                visible: 0 !== labelFont.size ? opt.visible : false,
                showForZeroValues: opt.showForZeroValues,
                horizontalOffset: opt.horizontalOffset,
                verticalOffset: opt.verticalOffset,
                radialOffset: opt.radialOffset,
                background: backgroundAttr,
                position: opt.position,
                connector: connectorAttr,
                rotationAngle: opt.rotationAngle
            }
        }

        function applyPointStyle(point, styleName) {
            !point.isSelected() && !point.hasSelectedView && point.applyStyle(styleName)
        }

        function Series(renderSettings, options) {
            var that = this;
            that.fullState = 0;
            that._extGroups = renderSettings;
            that._renderer = renderSettings.renderer;
            that._group = renderSettings.renderer.g().attr({
                "class": "dxc-series"
            });
            that.updateOptions(options)
        }
        exports.Series = Series;
        exports.mixins = seriesNS.mixins;
        Series.prototype = {
            constructor: Series,
            _createLegendState: _noop,
            getLegendStyles: function() {
                return this._styles.legendStyles
            },
            _createStyles: function(options) {
                var that = this,
                    mainSeriesColor = options.mainSeriesColor,
                    specialMainColor = that._getSpecialColor(mainSeriesColor);
                that._styles = {
                    normal: that._parseStyle(options, mainSeriesColor, mainSeriesColor),
                    hover: that._parseStyle(options.hoverStyle || {}, specialMainColor, mainSeriesColor),
                    selection: that._parseStyle(options.selectionStyle || {}, specialMainColor, mainSeriesColor),
                    legendStyles: {
                        normal: that._createLegendState(options, mainSeriesColor),
                        hover: that._createLegendState(options.hoverStyle || {}, specialMainColor),
                        selection: that._createLegendState(options.selectionStyle || {}, specialMainColor)
                    }
                }
            },
            setClippingParams: function(baseId, wideId, forceClipping) {
                this._paneClipRectID = baseId;
                this._widePaneClipRectID = wideId;
                this._forceClipping = forceClipping
            },
            applyClip: function() {
                this._group.attr({
                    clipId: this._paneClipRectID
                })
            },
            resetClip: function() {
                this._group.attr({
                    clipId: null
                })
            },
            getTagField: function() {
                return this._options.tagField || "tag"
            },
            getValueFields: _noop,
            getSizeField: _noop,
            getArgumentField: _noop,
            getPoints: function() {
                return this._points
            },
            _createPoint: function(data, pointsArray, index) {
                data.index = index;
                var options, arg, pba, that = this,
                    point = pointsArray[index],
                    pointsByArgument = that.pointsByArgument;
                if (that._checkData(data)) {
                    options = that._customizePoint(data) || that._getCreatingPointOptions(data);
                    if (point) {
                        point.update(data, options)
                    } else {
                        point = new pointModule.Point(that, data, options);
                        pointsArray.push(point)
                    }
                    arg = point.argument.valueOf();
                    pba = pointsByArgument[arg];
                    if (pba) {
                        pba.push(point)
                    } else {
                        pointsByArgument[arg] = [point]
                    }
                    return true
                }
            },
            getRangeData: function(zoomArgs, calcIntervalFunction) {
                return this._visible ? _extend(true, {}, this._getRangeData(zoomArgs, calcIntervalFunction)) : getEmptyBusinessRange()
            },
            _deleteGroup: function(groupName) {
                var group = this[groupName];
                if (group) {
                    group.dispose();
                    this[groupName] = null
                }
            },
            _saveOldAnimationMethods: function() {
                var that = this;
                that._oldClearingAnimation = that._clearingAnimation;
                that._oldUpdateElement = that._updateElement;
                that._oldgetAffineCoordOptions = that._getAffineCoordOptions
            },
            _deleteOldAnimationMethods: function() {
                this._oldClearingAnimation = null;
                this._oldUpdateElement = null;
                this._oldgetAffineCoordOptions = null
            },
            updateOptions: function(newOptions) {
                var that = this,
                    widgetType = newOptions.widgetType,
                    oldType = that.type,
                    newType = newOptions.type;
                that.type = newType && _normalizeEnum(newType.toString());
                if (!that._checkType(widgetType) || that._checkPolarBarType(widgetType, newOptions)) {
                    that.dispose();
                    that.isUpdated = false;
                    return
                }
                if (oldType !== that.type) {
                    that._firstDrawing = true;
                    that._saveOldAnimationMethods();
                    that._resetType(oldType, widgetType);
                    that._setType(that.type, widgetType)
                }
                that._options = newOptions;
                that._pointOptions = null;
                that._deletePatterns();
                that.name = newOptions.name;
                that.pane = newOptions.pane;
                that.axis = newOptions.axis;
                that.tag = newOptions.tag;
                that._createStyles(newOptions);
                that._updateOptions(newOptions);
                that._visible = newOptions.visible;
                that.isUpdated = true;
                that._createGroups()
            },
            _disposePoints: function(points) {
                _each(points || [], function(_, p) {
                    p.dispose()
                })
            },
            _correctPointsLength: function(length, points) {
                this._disposePoints(this._oldPoints);
                this._oldPoints = points.splice(length, points.length)
            },
            getErrorBarRangeCorrector: _noop,
            updateDataType: function(settings) {
                var that = this;
                that.argumentType = settings.argumentType;
                that.valueType = settings.valueType;
                that.argumentAxisType = settings.argumentAxisType;
                that.valueAxisType = settings.valueAxisType;
                that.showZero = settings.showZero;
                return that
            },
            getOptions: function() {
                return this._options
            },
            _resetRangeData: function() {
                this._rangeData = getEmptyBusinessRange()
            },
            updateData: function(data) {
                var curPoint, that = this,
                    points = that._originalPoints || [],
                    lastPointIndex = 0,
                    options = that._options,
                    i = 0,
                    len = data.length,
                    lastPoint = null,
                    rangeCorrector = that.getErrorBarRangeCorrector();
                that.pointsByArgument = {};
                that._resetRangeData();
                if (data && data.length) {
                    that._canRenderCompleteHandle = true
                }
                that._beginUpdateData(data);
                while (i < len) {
                    if (that._createPoint(that._getPointData(data[i], options), points, lastPointIndex)) {
                        curPoint = points[lastPointIndex];
                        that._processRange(curPoint, lastPoint, rangeCorrector);
                        lastPoint = curPoint;
                        lastPointIndex++
                    }
                    i++
                }
                that._disposePoints(that._aggregatedPoints);
                that._aggregatedPoints = null;
                that._points = that._originalPoints = points;
                that._correctPointsLength(lastPointIndex, points);
                that._endUpdateData()
            },
            getTemplateFields: function() {
                return this.getValueFields().concat(this.getTagField(), this.getSizeField()).map(function(field) {
                    return {
                        templateField: field + this.name,
                        originalField: field
                    }
                }, this)
            },
            resamplePoints: function(argTranslator, min, max) {
                var categories, discreteMin, discreteMax, count, tickInterval, that = this,
                    sizePoint = that._getPointSize(),
                    pointsLength = that.getAllPoints().length,
                    isDiscrete = that.argumentAxisType === DISCRETE || that.valueAxisType === DISCRETE,
                    businessRange = argTranslator.getBusinessRange();
                if (pointsLength && pointsLength > 1) {
                    count = argTranslator.canvasLength / sizePoint;
                    count = count <= 1 ? 1 : count;
                    if (isDiscrete) {
                        if (that.argumentAxisType === DISCRETE) {
                            categories = businessRange.categories;
                            discreteMin = _inArray(min, categories);
                            discreteMax = _inArray(max, categories);
                            if (discreteMin !== -1 && discreteMax !== -1) {
                                categories = categories.slice(discreteMin, discreteMax + 1)
                            }
                            pointsLength = categories.length
                        }
                        tickInterval = Math.ceil(pointsLength / count)
                    } else {
                        tickInterval = (businessRange.maxVisible - businessRange.minVisible) / count
                    }
                    that._points = that._resample(tickInterval, min - tickInterval, max + tickInterval, _isDefined(min) && _isDefined(max))
                }
            },
            _removeOldSegments: function(startIndex) {
                var that = this;
                _each(that._graphics.splice(startIndex, that._graphics.length) || [], function(_, elem) {
                    that._removeElement(elem)
                });
                if (that._trackers) {
                    _each(that._trackers.splice(startIndex, that._trackers.length) || [], function(_, elem) {
                        elem.remove()
                    })
                }
            },
            draw: function(translators, animationEnabled, hideLayoutLabels, legendCallback) {
                var drawComplete, that = this;
                if (that._oldClearingAnimation && animationEnabled && that._firstDrawing) {
                    drawComplete = function() {
                        that._draw(translators, true, hideLayoutLabels)
                    };
                    that._oldClearingAnimation(translators, drawComplete)
                } else {
                    that._draw(translators, animationEnabled, hideLayoutLabels, legendCallback)
                }
            },
            _draw: function(translators, animationEnabled, hideLayoutLabels, legendCallback) {
                var groupForPoint, that = this,
                    points = that._points || [],
                    segment = [],
                    segmentCount = 0,
                    firstDrawing = that._firstDrawing,
                    closeSegment = points[0] && points[0].hasValue() && that._options.closed;
                that._graphics = that._graphics || [];
                that._prepareSeriesToDrawing();
                if (!that._visible) {
                    animationEnabled = false;
                    that._group.remove();
                    return
                }
                that._appendInGroup();
                that.translators = translators;
                that._applyVisibleArea();
                that._setGroupsSettings(animationEnabled, firstDrawing);
                that._segments = [];
                that._drawnPoints = [];
                that._firstDrawing = points.length ? false : true;
                groupForPoint = {
                    markers: that._markersGroup,
                    errorBars: that._errorBarGroup
                };
                _each(points, function(i, p) {
                    p.translate(translators);
                    if (p.hasValue()) {
                        that._drawPoint({
                            point: p,
                            groups: groupForPoint,
                            hasAnimation: animationEnabled,
                            firstDrawing: firstDrawing,
                            legendCallback: legendCallback
                        });
                        segment.push(p)
                    } else {
                        if (segment.length) {
                            that._drawSegment(segment, animationEnabled, segmentCount++);
                            segment = []
                        }
                    }
                });
                segment.length && that._drawSegment(segment, animationEnabled, segmentCount++, closeSegment);
                that._removeOldSegments(segmentCount);
                that._defaultSegments = that._generateDefaultSegments();
                hideLayoutLabels && that.hideLabels();
                animationEnabled && that._animate(firstDrawing);
                if (that.isSelected()) {
                    that._changeStyle(legendCallback, APPLY_SELECTED)
                } else {
                    if (that.isHovered()) {
                        that._changeStyle(legendCallback, APPLY_HOVER)
                    }
                }
            },
            _setLabelGroupSettings: function(animationEnabled) {
                var settings = {
                    "class": "dxc-labels"
                };
                this._applyElementsClipRect(settings);
                this._applyClearingSettings(settings);
                animationEnabled && (settings.opacity = .001);
                this._labelsGroup.attr(settings).append(this._extGroups.labelsGroup)
            },
            _checkType: function(widgetType) {
                return !!seriesNS.mixins[widgetType][this.type]
            },
            _checkPolarBarType: function(widgetType, options) {
                return "polar" === widgetType && options.spiderWidget && this.type.indexOf("bar") !== -1
            },
            _resetType: function(seriesType, widgetType) {
                var methodName, methods;
                if (seriesType) {
                    methods = seriesNS.mixins[widgetType][seriesType];
                    for (methodName in methods) {
                        delete this[methodName]
                    }
                }
            },
            _setType: function(seriesType, widgetType) {
                var methodName, methods = seriesNS.mixins[widgetType][seriesType];
                for (methodName in methods) {
                    this[methodName] = methods[methodName]
                }
            },
            setSelectedState: function(state, mode, legendCallback) {
                var that = this;
                that.lastSelectionMode = _normalizeEnum(mode || that._options.selectionMode);
                if (state && !that.isSelected()) {
                    that.fullState = that.fullState | SELECTED_STATE;
                    that._nearestPoint && applyPointStyle(that._nearestPoint, NORMAL);
                    that._nearestPoint = null;
                    that._changeStyle(legendCallback, APPLY_SELECTED)
                } else {
                    if (!state && that.isSelected()) {
                        that.fullState = that.fullState & ~SELECTED_STATE;
                        if (that.isHovered()) {
                            that._changeStyle(legendCallback, APPLY_HOVER, SELECTION)
                        } else {
                            that._changeStyle(legendCallback, RESET_ITEM)
                        }
                    }
                }
            },
            setHoverState: function(state, mode, legendCallback) {
                var that = this;
                that.lastHoverMode = _normalizeEnum(mode || that._options.hoverMode);
                if (state && !that.isHovered()) {
                    that.fullState = that.fullState | HOVER_STATE;
                    !that.isSelected() && that._changeStyle(legendCallback, APPLY_HOVER)
                } else {
                    if (!state && that.isHovered()) {
                        that._nearestPoint = null;
                        that.fullState = that.fullState & ~HOVER_STATE;
                        !that.isSelected() && that._changeStyle(legendCallback, RESET_ITEM)
                    }
                }
            },
            setHoverView: function() {
                if (this._canChangeView()) {
                    this._applyStyle(this._styles.hover);
                    return this
                }
                return null
            },
            releaseHoverView: function(legendCallback) {
                this._canChangeView() && this._applyStyle(this._styles.normal)
            },
            isFullStackedSeries: function() {
                return 0 === this.type.indexOf("fullstacked")
            },
            isStackedSeries: function() {
                return 0 === this.type.indexOf("stacked")
            },
            isFinancialSeries: function() {
                return "stock" === this.type || "candlestick" === this.type
            },
            _canChangeView: function() {
                return !this.isSelected() && _normalizeEnum(this._options.hoverMode) !== NONE_MODE
            },
            _changeStyle: function(legendCallBack, legendAction, prevStyle) {
                var pointStyle, that = this,
                    style = that._calcStyle(prevStyle);
                if (style.mode === NONE_MODE) {
                    return
                }
                legendCallBack(legendAction);
                if (includePointsMode(style.mode)) {
                    pointStyle = style.pointStyle;
                    _each(that._points || [], function(_, p) {
                        applyPointStyle(p, pointStyle)
                    })
                }
                that._applyStyle(style.series)
            },
            _calcStyle: function(prevStyle) {
                var result, that = this,
                    styles = that._styles,
                    pointNormalState = false;
                switch (that.fullState) {
                    case 0:
                        result = {
                            pointStyle: NORMAL,
                            mode: INCLUDE_POINTS,
                            series: styles.normal
                        };
                        break;
                    case 1:
                        pointNormalState = prevStyle && that.lastHoverMode === EXLUDE_POINTS || that.lastHoverMode === NEAREST_POINT && includePointsMode(that.lastSelectionMode);
                        result = {
                            pointStyle: pointNormalState ? NORMAL : HOVER,
                            mode: pointNormalState ? INCLUDE_POINTS : that.lastHoverMode,
                            series: styles.hover
                        };
                        break;
                    case 2:
                        result = {
                            pointStyle: SELECTION,
                            mode: that.lastSelectionMode,
                            series: styles.selection
                        };
                        break;
                    case 3:
                        pointNormalState = that.lastSelectionMode === EXLUDE_POINTS && includePointsMode(that.lastHoverMode);
                        result = {
                            pointStyle: pointNormalState ? NORMAL : SELECTION,
                            mode: pointNormalState ? INCLUDE_POINTS : that.lastSelectionMode,
                            series: styles.selection
                        }
                }
                return result
            },
            updateHover: function(x, y) {
                var that = this,
                    currentNearestPoint = that._nearestPoint,
                    point = that.isHovered() && that.lastHoverMode === NEAREST_POINT && that.getNeighborPoint(x, y);
                if (point !== currentNearestPoint && !that.isSelected()) {
                    currentNearestPoint && applyPointStyle(currentNearestPoint, NORMAL);
                    if (point) {
                        applyPointStyle(point, HOVER);
                        that._nearestPoint = point
                    }
                }
            },
            _getMainAxisName: function() {
                return this._options.rotated ? "X" : "Y"
            },
            areLabelsVisible: function() {
                return !_isDefined(this._options.maxLabelCount) || this._points.length <= this._options.maxLabelCount
            },
            getLabelVisibility: function() {
                return this.areLabelsVisible() && this._options.label && this._options.label.visible
            },
            _customizePoint: function(pointData) {
                var customizeObject, pointOptions, customLabelOptions, customOptions, useLabelCustomOptions, usePointCustomOptions, that = this,
                    options = that._options,
                    customizePoint = options.customizePoint,
                    customizeLabel = options.customizeLabel;
                if (customizeLabel && customizeLabel.call) {
                    customizeObject = _extend({
                        seriesName: that.name
                    }, pointData);
                    customizeObject.series = that;
                    customLabelOptions = customizeLabel.call(customizeObject, customizeObject);
                    useLabelCustomOptions = customLabelOptions && !_isEmptyObject(customLabelOptions);
                    customLabelOptions = useLabelCustomOptions ? _extend(true, {}, options.label, customLabelOptions) : null
                }
                if (customizePoint && customizePoint.call) {
                    customizeObject = customizeObject || _extend({
                        seriesName: that.name
                    }, pointData);
                    customizeObject.series = that;
                    customOptions = customizePoint.call(customizeObject, customizeObject);
                    usePointCustomOptions = customOptions && !_isEmptyObject(customOptions)
                }
                if (useLabelCustomOptions || usePointCustomOptions) {
                    pointOptions = that._parsePointOptions(that._preparePointOptions(customOptions), customLabelOptions || options.label, pointData);
                    pointOptions.styles.useLabelCustomOptions = useLabelCustomOptions;
                    pointOptions.styles.usePointCustomOptions = usePointCustomOptions
                }
                return pointOptions
            },
            show: function() {
                if (!this._visible) {
                    this._changeVisibility(true)
                }
            },
            hide: function() {
                if (this._visible) {
                    this._changeVisibility(false)
                }
            },
            _changeVisibility: function(visibility) {
                var that = this;
                that._visible = that._options.visible = visibility;
                that._updatePointsVisibility();
                that.hidePointTooltip();
                that._options.visibilityChanged()
            },
            _updatePointsVisibility: _noop,
            hideLabels: function() {
                _each(this._points, function(_, point) {
                    point._label.hide()
                })
            },
            _parsePointOptions: function(pointOptions, labelOptions, data) {
                var that = this,
                    options = that._options,
                    styles = that._createPointStyles(pointOptions, data),
                    parsedOptions = _extend(true, {}, pointOptions, {
                        type: options.type,
                        tag: that.tag,
                        rotated: options.rotated,
                        styles: styles,
                        widgetType: options.widgetType,
                        visibilityChanged: options.visibilityChanged
                    });
                parsedOptions.label = getLabelOptions(labelOptions, styles.normal.fill);
                if (that.areErrorBarsVisible()) {
                    parsedOptions.errorBars = options.valueErrorBar
                }
                return parsedOptions
            },
            _preparePointOptions: function(customOptions) {
                var point = this._getOptionsForPoint();
                return customOptions ? _extend(true, {}, point, customOptions) : point
            },
            _getMarkerGroupOptions: function() {
                return _extend(false, {}, this._getOptionsForPoint(), {
                    hoverStyle: {},
                    selectionStyle: {}
                })
            },
            _resample: function(ticksInterval, min, max, isDefinedMinMax) {
                var pointData, minTick, that = this,
                    fusPoints = [],
                    nowIndexTicks = 0,
                    lastPointIndex = 0,
                    state = 0,
                    originalPoints = that.getAllPoints();

                function addFirstFusPoint(point) {
                    fusPoints.push(point);
                    minTick = point.argument;
                    if (isDefinedMinMax) {
                        if (point.argument < min) {
                            state = 1
                        } else {
                            if (point.argument > max) {
                                state = 2
                            } else {
                                state = 0
                            }
                        }
                    }
                }
                if (that.argumentAxisType === DISCRETE || that.valueAxisType === DISCRETE) {
                    return _map(originalPoints, function(point, index) {
                        if (index % ticksInterval === 0) {
                            return point
                        }
                        point.setInvisibility();
                        return null
                    })
                }
                that._aggregatedPoints = that._aggregatedPoints || [];
                _each(originalPoints, function(_, point) {
                    point.setInvisibility();
                    if (!fusPoints.length) {
                        addFirstFusPoint(point)
                    } else {
                        if (!state && Math.abs(minTick - point.argument) < ticksInterval) {
                            fusPoints.push(point)
                        } else {
                            if (!(1 === state && point.argument < min) && !(2 === state && point.argument > max)) {
                                pointData = that._fusionPoints(fusPoints, minTick, nowIndexTicks);
                                nowIndexTicks++;
                                if (that._createPoint(pointData, that._aggregatedPoints, lastPointIndex)) {
                                    lastPointIndex++
                                }
                                fusPoints = [];
                                addFirstFusPoint(point)
                            }
                        }
                    }
                });
                if (fusPoints.length) {
                    pointData = that._fusionPoints(fusPoints, minTick, nowIndexTicks);
                    if (that._createPoint(pointData, that._aggregatedPoints, lastPointIndex)) {
                        lastPointIndex++
                    }
                }
                that._correctPointsLength(lastPointIndex, that._aggregatedPoints);
                that._endUpdateData();
                return that._aggregatedPoints
            },
            canRenderCompleteHandle: function() {
                var result = this._canRenderCompleteHandle;
                delete this._canRenderCompleteHandle;
                return !!result
            },
            isHovered: function() {
                return !!(1 & this.fullState)
            },
            isSelected: function() {
                return !!(2 & this.fullState)
            },
            isVisible: function() {
                return this._visible
            },
            getAllPoints: function() {
                return (this._originalPoints || []).slice()
            },
            getPointByPos: function(pos) {
                return (this._points || [])[pos]
            },
            getVisiblePoints: function() {
                return (this._drawnPoints || []).slice()
            },
            setPointHoverState: function(data) {
                var point = data.point;
                if (data.setState) {
                    point.fullState |= HOVER_STATE
                }
                if (!(this.isSelected() && includePointsMode(this.lastSelectionMode)) && !point.isSelected() && !point.hasSelectedView) {
                    point.applyStyle(HOVER)
                }
            },
            releasePointHoverState: function(data) {
                var that = this,
                    point = data.point;
                if (data.setState) {
                    point.fullState &= ~HOVER_STATE
                }
                if (!(that.isSelected() && includePointsMode(that.lastSelectionMode)) && !point.isSelected() && !point.hasSelectedView) {
                    if (!(that.isHovered() && includePointsMode(that.lastHoverMode)) || that.isSelected() && that.lastSelectionMode === EXLUDE_POINTS) {
                        point.applyStyle(NORMAL)
                    }
                }
                point.releaseHoverState()
            },
            setPointSelectedState: function(data) {
                var point = data.point;
                if (data.setState) {
                    point.fullState |= SELECTED_STATE
                } else {
                    point.hasSelectedView = true
                }
                point.applyStyle(SELECTION)
            },
            releasePointSelectedState: function(data) {
                var pointStyle, that = this,
                    point = data.point;
                if (data.setState) {
                    point.fullState &= ~SELECTED_STATE
                } else {
                    point.hasSelectedView = false
                }
                if (that.isHovered() && includePointsMode(that.lastHoverMode) || point.isHovered()) {
                    pointStyle = HOVER
                } else {
                    if (that.isSelected() && includePointsMode(that.lastSelectionMode)) {
                        pointStyle = SELECTION
                    } else {
                        pointStyle = NORMAL
                    }
                }
                point.applyStyle(pointStyle)
            },
            selectPoint: function(point) {
                triggerEvent(this._extGroups.seriesGroup, new _Event("selectpoint"), point)
            },
            deselectPoint: function(point) {
                triggerEvent(this._extGroups.seriesGroup, new _Event("deselectpoint"), point)
            },
            showPointTooltip: function(point) {
                triggerEvent(this._extGroups.seriesGroup, new _Event("showpointtooltip"), point)
            },
            hidePointTooltip: function(point) {
                triggerEvent(this._extGroups.seriesGroup, new _Event("hidepointtooltip"), point)
            },
            select: function() {
                var that = this;
                triggerEvent(that._extGroups.seriesGroup, new _Event("selectseries", {
                    target: that
                }), that._options.selectionMode);
                that._group.toForeground()
            },
            clearSelection: function() {
                var that = this;
                triggerEvent(that._extGroups.seriesGroup, new _Event("deselectseries", {
                    target: that
                }), that._options.selectionMode)
            },
            getPointsByArg: function(arg) {
                return this.pointsByArgument[arg.valueOf()] || []
            },
            _deletePoints: function() {
                var that = this;
                that._disposePoints(that._originalPoints);
                that._disposePoints(that._aggregatedPoints);
                that._disposePoints(that._oldPoints);
                that._points = that._oldPoints = that._aggregatedPoints = that._originalPoints = that._drawnPoints = null
            },
            _deletePatterns: function() {
                _each(this._patterns || [], function(_, pattern) {
                    pattern && pattern.dispose()
                });
                this._patterns = []
            },
            _deleteTrackers: function() {
                var that = this;
                _each(that._trackers || [], function(_, tracker) {
                    tracker.remove()
                });
                that._trackersGroup && that._trackersGroup.dispose();
                that._trackers = that._trackersGroup = null
            },
            dispose: function() {
                var that = this;
                that._deletePoints();
                that._group.dispose();
                that._labelsGroup && that._labelsGroup.dispose();
                that._errorBarGroup && that._errorBarGroup.dispose();
                that._deletePatterns();
                that._deleteTrackers();
                that._group = that._extGroups = that._markersGroup = that._elementsGroup = that._bordersGroup = that._labelsGroup = that._errorBarGroup = that._graphics = that._rangeData = that._renderer = that.translators = that._styles = that._options = that._pointOptions = that._drawnPoints = that._aggregatedPoints = that.pointsByArgument = that._segments = that._prevSeries = that._patterns = null
            },
            correctPosition: _noop,
            drawTrackers: _noop,
            getNeighborPoint: _noop,
            areErrorBarsVisible: _noop,
            getColor: function() {
                return this.getLegendStyles().normal.fill
            },
            getOpacity: function() {
                return this._options.opacity
            },
            getStackName: function() {
                return "stackedbar" === this.type || "fullstackedbar" === this.type ? this._stackName : null
            },
            getPointByCoord: function(x, y) {
                var point = this.getNeighborPoint(x, y);
                return point && point.coordsIn(x, y) ? point : null
            }
        }
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/series/points/base_point.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            mixins = {},
            statesConsts = __webpack_require__( /*! ../../components/consts */ 462).states,
            symbolPoint = __webpack_require__( /*! ./symbol_point */ 463),
            barPoint = __webpack_require__( /*! ./bar_point */ 466),
            bubblePoint = __webpack_require__( /*! ./bubble_point */ 467),
            piePoint = __webpack_require__( /*! ./pie_point */ 468),
            rangeSymbolPoint = __webpack_require__( /*! ./range_symbol_point */ 469),
            rangeBarPoint = __webpack_require__( /*! ./range_bar_point */ 470),
            candlestickPoint = __webpack_require__( /*! ./candlestick_point */ 471),
            stockPoint = __webpack_require__( /*! ./stock_point */ 472),
            polarPoints = __webpack_require__( /*! ./polar_point */ 473),
            _each = $.each,
            _extend = $.extend,
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _noop = $.noop,
            SYMBOL_POINT = "symbolPoint",
            POLAR_SYMBOL_POINT = "polarSymbolPoint",
            BAR_POINT = "barPoint",
            POLAR_BAR_POINT = "polarBarPoint",
            PIE_POINT = "piePoint",
            pointTypes = {
                chart: {
                    scatter: SYMBOL_POINT,
                    line: SYMBOL_POINT,
                    spline: SYMBOL_POINT,
                    stepline: SYMBOL_POINT,
                    stackedline: SYMBOL_POINT,
                    fullstackedline: SYMBOL_POINT,
                    stackedspline: SYMBOL_POINT,
                    fullstackedspline: SYMBOL_POINT,
                    stackedsplinearea: SYMBOL_POINT,
                    fullstackedsplinearea: SYMBOL_POINT,
                    area: SYMBOL_POINT,
                    splinearea: SYMBOL_POINT,
                    steparea: SYMBOL_POINT,
                    stackedarea: SYMBOL_POINT,
                    fullstackedarea: SYMBOL_POINT,
                    rangearea: "rangeSymbolPoint",
                    bar: BAR_POINT,
                    stackedbar: BAR_POINT,
                    fullstackedbar: BAR_POINT,
                    rangebar: "rangeBarPoint",
                    bubble: "bubblePoint",
                    stock: "stockPoint",
                    candlestick: "candlestickPoint"
                },
                pie: {
                    pie: PIE_POINT,
                    doughnut: PIE_POINT,
                    donut: PIE_POINT
                },
                polar: {
                    scatter: POLAR_SYMBOL_POINT,
                    line: POLAR_SYMBOL_POINT,
                    area: POLAR_SYMBOL_POINT,
                    bar: POLAR_BAR_POINT,
                    stackedbar: POLAR_BAR_POINT
                }
            };

        function Point(series, dataItem, options) {
            this.fullState = statesConsts.normalMark;
            this.series = series;
            this.update(dataItem, options);
            this._emptySettings = {
                fill: null,
                stroke: null,
                dashStyle: null
            }
        }
        exports.Point = Point;
        mixins.symbolPoint = symbolPoint;
        mixins.barPoint = barPoint;
        mixins.bubblePoint = bubblePoint;
        mixins.piePoint = piePoint;
        mixins.rangeSymbolPoint = rangeSymbolPoint;
        mixins.rangeBarPoint = rangeBarPoint;
        mixins.candlestickPoint = candlestickPoint;
        mixins.stockPoint = stockPoint;
        mixins.polarSymbolPoint = polarPoints.polarSymbolPoint;
        mixins.polarBarPoint = polarPoints.polarBarPoint;
        Point.prototype = {
            constructor: Point,
            getColor: function() {
                return this._styles.normal.fill || this.series.getColor()
            },
            _getStyle: function() {
                return this._styles[this._currentStyle || "normal"]
            },
            update: function(dataItem, options) {
                this.updateOptions(options);
                this.updateData(dataItem)
            },
            updateData: function(dataItem) {
                var that = this;
                that.argument = that.initialArgument = that.originalArgument = dataItem.argument;
                that.tag = dataItem.tag;
                that.index = dataItem.index;
                that.lowError = dataItem.lowError;
                that.highError = dataItem.highError;
                that._updateData(dataItem);
                !that.hasValue() && that.setInvisibility();
                that._fillStyle();
                that._updateLabelData()
            },
            deleteMarker: function() {
                var that = this;
                if (that.graphic) {
                    that.graphic.dispose()
                }
                that.graphic = null
            },
            _drawErrorBar: _noop,
            draw: function(renderer, groups, animationEnabled, firstDrawing) {
                var that = this;
                if (that._needDeletingOnDraw) {
                    that.deleteMarker();
                    that._needDeletingOnDraw = false
                }
                if (that._needClearingOnDraw) {
                    that.clearMarker();
                    that._needClearingOnDraw = false
                }
                if (!that._hasGraphic()) {
                    that._getMarkerVisibility() && that._drawMarker(renderer, groups.markers, animationEnabled, firstDrawing)
                } else {
                    that._updateMarker(animationEnabled, void 0, groups.markers)
                }
                that._drawLabel();
                that._drawErrorBar(renderer, groups.errorBars, animationEnabled);
                return that
            },
            applyStyle: function(style) {
                var that = this;
                that._currentStyle = style;
                if (that.graphic) {
                    if ("normal" === style) {
                        if (that.isHovered()) {
                            that.applyStyle("hover");
                            return
                        }
                        that.clearMarker()
                    } else {
                        that.graphic.toForeground()
                    }
                    that._updateMarker(true, that._styles[style])
                }
                return that
            },
            releaseHoverState: function() {
                var that = this;
                if (that.graphic && !that.isSelected()) {
                    that.graphic.toBackground()
                }
            },
            select: function() {
                this.series.selectPoint(this)
            },
            clearSelection: function() {
                this.series.deselectPoint(this)
            },
            showTooltip: function() {
                this.series.showPointTooltip(this)
            },
            hideTooltip: function() {
                this.series.hidePointTooltip(this)
            },
            _checkLabelsChanging: function(oldType, newType) {
                var isNewRange = ~newType.indexOf("range"),
                    isOldRange = ~oldType.indexOf("range");
                return isOldRange && !isNewRange || !isOldRange && isNewRange
            },
            updateOptions: function(newOptions) {
                if (!newOptions) {
                    return
                }
                var that = this,
                    oldOptions = that._options,
                    widgetType = newOptions.widgetType,
                    oldType = oldOptions && oldOptions.type,
                    newType = newOptions.type,
                    newPointTypeMixin = pointTypes[widgetType][newType];
                if (oldType !== newType) {
                    that._needDeletingOnDraw = true;
                    that._needClearingOnDraw = false;
                    if (oldType) {
                        that._checkLabelsChanging(oldType, newType) && that.deleteLabel();
                        that._resetType(mixins[pointTypes[oldType]])
                    }
                    that._setType(mixins[newPointTypeMixin])
                } else {
                    that._needDeletingOnDraw = that._checkSymbol(oldOptions, newOptions);
                    that._needClearingOnDraw = that._checkCustomize(oldOptions, newOptions)
                }
                that._options = newOptions;
                that._fillStyle();
                that._updateLabelOptions(newPointTypeMixin)
            },
            translate: function(translators) {
                var that = this;
                that.translators = translators || that.translators;
                that.translators && that.hasValue() && that._translate(that.translators)
            },
            _checkCustomize: function(oldOptions, newOptions) {
                return oldOptions.styles.usePointCustomOptions && !newOptions.styles.usePointCustomOptions
            },
            _getCustomLabelVisibility: function() {
                return this._styles.useLabelCustomOptions ? !!this._options.label.visible : null
            },
            getBoundingRect: function() {
                return this._getGraphicBbox()
            },
            _resetType: function(methods) {
                for (var methodName in methods) {
                    delete this[methodName]
                }
            },
            _setType: function(methods) {
                for (var methodName in methods) {
                    this[methodName] = methods[methodName]
                }
            },
            isInVisibleArea: function() {
                return this.inVisibleArea
            },
            isSelected: function() {
                return !!(this.fullState & statesConsts.selectedMark)
            },
            isHovered: function() {
                return !!(this.fullState & statesConsts.hoverMark)
            },
            getOptions: function() {
                return this._options
            },
            animate: function(complete, settings, partitionDuration) {
                if (!this.graphic) {
                    complete && complete();
                    return
                }
                this.graphic.animate(settings, {
                    partitionDuration: partitionDuration
                }, complete)
            },
            getCoords: function(min) {
                var that = this;
                if (!min) {
                    return {
                        x: that.x,
                        y: that.y
                    }
                }
                if (!that._options.rotated) {
                    return {
                        x: that.x,
                        y: that.minY
                    }
                }
                return {
                    x: that.minX,
                    y: that.y
                }
            },
            getDefaultCoords: function() {
                var that = this;
                return !that._options.rotated ? {
                    x: that.x,
                    y: that.defaultY
                } : {
                    x: that.defaultX,
                    y: that.y
                }
            },
            _getVisibleArea: function() {
                return this.series._visibleArea
            },
            _calculateVisibility: function(x, y, width, height) {
                var visibleAreaX, visibleAreaY, that = this,
                    rotated = that._options.rotated;
                if (that.translators) {
                    visibleAreaX = that.translators.x.getCanvasVisibleArea();
                    visibleAreaY = that.translators.y.getCanvasVisibleArea();
                    if (visibleAreaX.min > x + (width || 0) || visibleAreaX.max < x || visibleAreaY.min > y + (height || 0) || visibleAreaY.max < y || rotated && _isDefined(width) && 0 !== width && (visibleAreaX.min === x + width || visibleAreaX.max === x) || !rotated && _isDefined(height) && 0 !== height && (visibleAreaY.min === y + height || visibleAreaY.max === y)) {
                        that.inVisibleArea = false
                    } else {
                        that.inVisibleArea = true
                    }
                }
            },
            hasValue: function() {
                return null !== this.value && null !== this.minValue
            },
            getBoundaryCoords: function() {
                return this.getBoundingRect()
            },
            correctPosition: _noop,
            correctRadius: _noop,
            correctLabelRadius: _noop,
            getCrosshairData: _noop,
            getPointRadius: _noop,
            _populatePointShape: _noop,
            _checkSymbol: _noop,
            getMarkerCoords: _noop,
            hide: _noop,
            show: _noop,
            hideMarker: _noop,
            setInvisibility: _noop,
            clearVisibility: _noop,
            isVisible: _noop,
            resetCorrection: _noop,
            correctValue: _noop,
            resetValue: _noop,
            setPercentValue: _noop,
            correctCoordinates: _noop,
            coordsIn: _noop,
            getTooltipParams: _noop,
            setLabelEllipsis: _noop,
            setLabelTrackerData: _noop,
            updateLabelCoord: _noop,
            drawLabel: _noop,
            correctLabelPosition: _noop,
            setMaxLabelLength: _noop,
            dispose: function() {
                var that = this;
                that.deleteMarker();
                that.deleteLabel();
                that._errorBar && this._errorBar.dispose();
                that._options = that._styles = that.series = that.translators = that._errorBar = null
            },
            getTooltipFormatObject: function(tooltip) {
                var that = this,
                    tooltipFormatObject = that._getFormatObject(tooltip),
                    sharedTooltipValuesArray = [],
                    tooltipStackPointsFormatObject = [];
                if (that.stackPoints) {
                    _each(that.stackPoints, function(_, point) {
                        if (!point.isVisible()) {
                            return
                        }
                        var formatObject = point._getFormatObject(tooltip);
                        tooltipStackPointsFormatObject.push(formatObject);
                        sharedTooltipValuesArray.push(formatObject.seriesName + ": " + formatObject.valueText)
                    });
                    _extend(tooltipFormatObject, {
                        points: tooltipStackPointsFormatObject,
                        valueText: sharedTooltipValuesArray.join("\n"),
                        stackName: that.stackPoints.stackName
                    })
                }
                return tooltipFormatObject
            },
            setHole: function(holeValue, position) {
                var that = this,
                    minValue = isFinite(that.minValue) ? that.minValue : 0;
                if (_isDefined(holeValue)) {
                    if ("left" === position) {
                        that.leftHole = that.value - holeValue;
                        that.minLeftHole = minValue - holeValue
                    } else {
                        that.rightHole = that.value - holeValue;
                        that.minRightHole = minValue - holeValue
                    }
                }
            },
            resetHoles: function() {
                this.leftHole = null;
                this.minLeftHole = null;
                this.rightHole = null;
                this.minRightHole = null
            },
            getLabel: function() {
                return this._label
            }
        }
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/components/consts.js ***!
      \******************************************/
    function(module, exports) {
        module.exports = {
            events: {
                mouseover: "mouseover",
                mouseout: "mouseout",
                mousemove: "mousemove",
                touchstart: "touchstart",
                touchmove: "touchmove",
                touchend: "touchend",
                mousedown: "mousedown",
                mouseup: "mouseup",
                click: "click",
                selectSeries: "selectseries",
                deselectSeries: "deselectseries",
                selectPoint: "selectpoint",
                deselectPoint: "deselectpoint",
                showPointTooltip: "showpointtooltip",
                hidePointTooltip: "hidepointtooltip"
            },
            states: {
                hover: "hover",
                normal: "normal",
                selection: "selection",
                normalMark: 0,
                hoverMark: 1,
                selectedMark: 2,
                applyHover: "applyHover",
                applySelected: "applySelected",
                resetItem: "resetItem"
            },
            pieLabelIndent: 30,
            pieLabelSpacing: 10,
            pieSeriesSpacing: 4
        }
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/series/points/symbol_point.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            labelModule = __webpack_require__( /*! ./label */ 464),
            _extend = $.extend,
            _isDefined = commonUtils.isDefined,
            _normalizeEnum = __webpack_require__( /*! ../../core/utils */ 442).normalizeEnum,
            _math = Math,
            _round = _math.round,
            _floor = _math.floor,
            _ceil = _math.ceil,
            DEFAULT_IMAGE_WIDTH = 20,
            DEFAULT_IMAGE_HEIGHT = 20,
            LABEL_OFFSET = 10,
            CANVAS_POSITION_DEFAULT = "canvas_position_default";

        function getSquareMarkerCoords(radius) {
            return [-radius, -radius, radius, -radius, radius, radius, -radius, radius, -radius, -radius]
        }

        function getPolygonMarkerCoords(radius) {
            var r = _ceil(radius);
            return [-r, 0, 0, -r, r, 0, 0, r, -r, 0]
        }

        function getCrossMarkerCoords(radius) {
            var r = _ceil(radius),
                floorHalfRadius = _floor(r / 2),
                ceilHalfRadius = _ceil(r / 2);
            return [-r, -floorHalfRadius, -floorHalfRadius, -r, 0, -ceilHalfRadius, floorHalfRadius, -r, r, -floorHalfRadius, ceilHalfRadius, 0, r, floorHalfRadius, floorHalfRadius, r, 0, ceilHalfRadius, -floorHalfRadius, r, -r, floorHalfRadius, -ceilHalfRadius, 0]
        }

        function getTriangleDownMarkerCoords(radius) {
            return [-radius, -radius, radius, -radius, 0, radius, -radius, -radius]
        }

        function getTriangleUpMarkerCoords(radius) {
            return [-radius, radius, radius, radius, 0, -radius, -radius, radius]
        }
        module.exports = {
            deleteLabel: function() {
                this._label.dispose();
                this._label = null
            },
            _hasGraphic: function() {
                return this.graphic
            },
            clearVisibility: function() {
                var that = this,
                    graphic = that.graphic;
                if (graphic && graphic.attr("visibility")) {
                    graphic.attr({
                        visibility: null
                    })
                }
                that._label.clearVisibility()
            },
            isVisible: function() {
                return this.inVisibleArea && this.series.isVisible()
            },
            setInvisibility: function() {
                var that = this,
                    graphic = that.graphic;
                if (graphic && "hidden" !== graphic.attr("visibility")) {
                    graphic.attr({
                        visibility: "hidden"
                    })
                }
                that._errorBar && that._errorBar.attr({
                    visibility: "hidden"
                });
                that._label.hide()
            },
            clearMarker: function() {
                var graphic = this.graphic;
                graphic && graphic.attr(this._emptySettings)
            },
            _createLabel: function() {
                this._label = new labelModule.Label({
                    renderer: this.series._renderer,
                    labelsGroup: this.series._labelsGroup,
                    point: this
                })
            },
            _updateLabelData: function() {
                this._label.setData(this._getLabelFormatObject())
            },
            _updateLabelOptions: function() {
                !this._label && this._createLabel();
                this._label.setOptions(this._options.label)
            },
            _checkImage: function(image) {
                return _isDefined(image) && ("string" === typeof image || _isDefined(image.url))
            },
            _fillStyle: function() {
                this._styles = this._options.styles
            },
            _checkSymbol: function(oldOptions, newOptions) {
                var oldSymbol = oldOptions.symbol,
                    newSymbol = newOptions.symbol,
                    symbolChanged = "circle" === oldSymbol && "circle" !== newSymbol || "circle" !== oldSymbol && "circle" === newSymbol,
                    imageChanged = this._checkImage(oldOptions.image) !== this._checkImage(newOptions.image);
                return !!(symbolChanged || imageChanged)
            },
            _populatePointShape: function(symbol, radius) {
                switch (symbol) {
                    case "square":
                        return getSquareMarkerCoords(radius);
                    case "polygon":
                        return getPolygonMarkerCoords(radius);
                    case "triangle":
                    case "triangleDown":
                        return getTriangleDownMarkerCoords(radius);
                    case "triangleUp":
                        return getTriangleUpMarkerCoords(radius);
                    case "cross":
                        return getCrossMarkerCoords(radius)
                }
            },
            correctValue: function(correction) {
                var that = this;
                if (that.hasValue()) {
                    that.value = that.initialValue + correction;
                    that.minValue = correction;
                    that.translate()
                }
            },
            resetCorrection: function() {
                this.value = this.initialValue;
                this.minValue = CANVAS_POSITION_DEFAULT
            },
            resetValue: function() {
                var that = this;
                if (that.hasValue()) {
                    that.value = that.initialValue = 0;
                    that.minValue = 0;
                    that.translate();
                    that._label.setDataField("value", that.value)
                }
            },
            _getTranslates: function(animationEnabled) {
                var translateX = this.x,
                    translateY = this.y;
                if (animationEnabled) {
                    if (this._options.rotated) {
                        translateX = this.defaultX
                    } else {
                        translateY = this.defaultY
                    }
                }
                return {
                    x: translateX,
                    y: translateY
                }
            },
            _createImageMarker: function(renderer, settings, options) {
                var width = options.width || DEFAULT_IMAGE_WIDTH,
                    height = options.height || DEFAULT_IMAGE_HEIGHT;
                return renderer.image(-_round(.5 * width), -_round(.5 * height), width, height, options.url ? options.url.toString() : options.toString(), "center").attr({
                    translateX: settings.translateX,
                    translateY: settings.translateY,
                    visibility: settings.visibility
                })
            },
            _createSymbolMarker: function(renderer, pointSettings) {
                var marker, symbol = this._options.symbol;
                if ("circle" === symbol) {
                    delete pointSettings.points;
                    marker = renderer.circle().attr(pointSettings)
                } else {
                    if ("square" === symbol || "polygon" === symbol || "triangle" === symbol || "triangleDown" === symbol || "triangleUp" === symbol || "cross" === symbol) {
                        marker = renderer.path([], "area").attr(pointSettings).sharp()
                    }
                }
                return marker
            },
            _createMarker: function(renderer, group, image, settings, animationEnabled) {
                var that = this,
                    marker = that._checkImage(image) ? that._createImageMarker(renderer, settings, image) : that._createSymbolMarker(renderer, settings);
                if (marker) {
                    marker.data({
                        "chart-data-point": that
                    }).append(group)
                }
                return marker
            },
            _getSymbolBbox: function(x, y, r) {
                return {
                    x: x - r,
                    y: y - r,
                    width: 2 * r,
                    height: 2 * r
                }
            },
            _getImageBbox: function(x, y) {
                var image = this._options.image,
                    width = image.width || DEFAULT_IMAGE_WIDTH,
                    height = image.height || DEFAULT_IMAGE_HEIGHT;
                return {
                    x: x - _round(width / 2),
                    y: y - _round(height / 2),
                    width: width,
                    height: height
                }
            },
            _getGraphicBbox: function() {
                var bbox, that = this,
                    options = that._options,
                    x = that.x,
                    y = that.y;
                if (options.visible) {
                    bbox = that._checkImage(options.image) ? that._getImageBbox(x, y) : that._getSymbolBbox(x, y, options.styles.normal.r)
                } else {
                    bbox = {
                        x: x,
                        y: y,
                        width: 0,
                        height: 0
                    }
                }
                return bbox
            },
            _isLabelInsidePoint: $.noop,
            _getShiftLabelCoords: function(label) {
                var coord = this._addLabelAlignmentAndOffset(label, this._getLabelCoords(label));
                return this._checkLabelPosition(label, coord)
            },
            _drawLabel: function() {
                var that = this,
                    customVisibility = that._getCustomLabelVisibility(),
                    label = that._label;
                if ((that.series.getLabelVisibility() || customVisibility) && that._showForZeroValues() && that.hasValue()) {
                    label.show()
                } else {
                    label.hide()
                }
            },
            correctLabelPosition: function(label) {
                var coord, that = this;
                if (!that._isLabelInsidePoint(label)) {
                    coord = that._getShiftLabelCoords(label);
                    label.setFigureToDrawConnector(that._getLabelConnector(label.pointPosition));
                    label.shift(_round(coord.x), _round(coord.y))
                }
            },
            _showForZeroValues: function() {
                return true
            },
            _getLabelConnector: function(pointPosition) {
                var bbox = this._getGraphicBbox(pointPosition),
                    w2 = bbox.width / 2,
                    h2 = bbox.height / 2;
                return {
                    x: bbox.x + w2,
                    y: bbox.y + h2,
                    r: this._options.visible ? Math.max(w2, h2) : 0
                }
            },
            _getPositionFromLocation: function() {
                return {
                    x: this.x,
                    y: this.y
                }
            },
            _isPointInVisibleArea: function(visibleArea, graphicBbox) {
                return visibleArea.minX <= graphicBbox.x + graphicBbox.width && visibleArea.maxX >= graphicBbox.x && visibleArea.minY <= graphicBbox.y + graphicBbox.height && visibleArea.maxY >= graphicBbox.y
            },
            _checkLabelPosition: function(label, coord) {
                var that = this,
                    visibleArea = that._getVisibleArea(),
                    labelBbox = label.getBoundingRect(),
                    graphicBbox = that._getGraphicBbox(label.pointPosition),
                    offset = LABEL_OFFSET;
                if (that._isPointInVisibleArea(visibleArea, graphicBbox)) {
                    if (!that._options.rotated) {
                        if (visibleArea.minX > coord.x) {
                            coord.x = visibleArea.minX
                        }
                        if (visibleArea.maxX < coord.x + labelBbox.width) {
                            coord.x = visibleArea.maxX - labelBbox.width
                        }
                        if (visibleArea.minY > coord.y) {
                            coord.y = graphicBbox.y + graphicBbox.height + offset
                        }
                        if (visibleArea.maxY < coord.y + labelBbox.height) {
                            coord.y = graphicBbox.y - labelBbox.height - offset
                        }
                    } else {
                        if (visibleArea.minX > coord.x) {
                            coord.x = graphicBbox.x + graphicBbox.width + offset
                        }
                        if (visibleArea.maxX < coord.x + labelBbox.width) {
                            coord.x = graphicBbox.x - offset - labelBbox.width
                        }
                        if (visibleArea.minY > coord.y) {
                            coord.y = visibleArea.minY
                        }
                        if (visibleArea.maxY < coord.y + labelBbox.height) {
                            coord.y = visibleArea.maxY - labelBbox.height
                        }
                    }
                }
                return coord
            },
            _addLabelAlignmentAndOffset: function(label, coord) {
                var labelBBox = label.getBoundingRect(),
                    labelOptions = label.getLayoutOptions();
                if (!this._options.rotated) {
                    if ("left" === labelOptions.alignment) {
                        coord.x += labelBBox.width / 2
                    } else {
                        if ("right" === labelOptions.alignment) {
                            coord.x -= labelBBox.width / 2
                        }
                    }
                }
                coord.x += labelOptions.horizontalOffset;
                coord.y += labelOptions.verticalOffset;
                return coord
            },
            _getLabelCoords: function(label) {
                return this._getLabelCoordOfPosition(label, this._getLabelPosition(label.pointPosition))
            },
            _getLabelCoordOfPosition: function(label, position) {
                var that = this,
                    labelBBox = label.getBoundingRect(),
                    graphicBbox = that._getGraphicBbox(label.pointPosition),
                    offset = LABEL_OFFSET,
                    centerY = graphicBbox.height / 2 - labelBBox.height / 2,
                    centerX = graphicBbox.width / 2 - labelBBox.width / 2,
                    x = graphicBbox.x,
                    y = graphicBbox.y;
                switch (position) {
                    case "left":
                        x -= labelBBox.width + offset;
                        y += centerY;
                        break;
                    case "right":
                        x += graphicBbox.width + offset;
                        y += centerY;
                        break;
                    case "top":
                        x += centerX;
                        y -= labelBBox.height + offset;
                        break;
                    case "bottom":
                        x += centerX;
                        y += graphicBbox.height + offset;
                        break;
                    case "inside":
                        x += centerX;
                        y += centerY
                }
                return {
                    x: x,
                    y: y
                }
            },
            _drawMarker: function(renderer, group, animationEnabled) {
                var that = this,
                    options = that._options,
                    translates = that._getTranslates(animationEnabled),
                    style = that._getStyle();
                that.graphic = that._createMarker(renderer, group, options.image, _extend({
                    translateX: translates.x,
                    translateY: translates.y,
                    points: that._populatePointShape(options.symbol, style.r)
                }, style), animationEnabled)
            },
            _getErrorBarSettings: function() {
                return {
                    visibility: "visible"
                }
            },
            _drawErrorBar: function(renderer, group) {
                if (!this._options.errorBars) {
                    return
                }
                var settings, that = this,
                    options = that._options,
                    errorBarOptions = options.errorBars,
                    points = [],
                    pos = that._errorBarPos,
                    high = that._highErrorCoord,
                    low = that._lowErrorCoord,
                    displayMode = _normalizeEnum(errorBarOptions.displayMode),
                    isHighDisplayMode = "high" === displayMode,
                    isLowDisplayMode = "low" === displayMode,
                    edgeLength = _floor(parseInt(errorBarOptions.edgeLength) / 2),
                    highErrorOnly = (isHighDisplayMode || !_isDefined(low)) && _isDefined(high) && !isLowDisplayMode,
                    lowErrorOnly = (isLowDisplayMode || !_isDefined(high)) && _isDefined(low) && !isHighDisplayMode;
                highErrorOnly && (low = that._baseErrorBarPos);
                lowErrorOnly && (high = that._baseErrorBarPos);
                if ("none" !== displayMode && _isDefined(high) && _isDefined(low) && _isDefined(pos)) {
                    !lowErrorOnly && points.push([pos - edgeLength, high, pos + edgeLength, high]);
                    points.push([pos, high, pos, low]);
                    !highErrorOnly && points.push([pos + edgeLength, low, pos - edgeLength, low]);
                    options.rotated && $.each(points, function(_, p) {
                        p.reverse()
                    });
                    settings = that._getErrorBarSettings(errorBarOptions);
                    if (!that._errorBar) {
                        that._errorBar = renderer.path(points, "line").attr(settings).append(group)
                    } else {
                        settings.points = points;
                        that._errorBar.attr(settings)
                    }
                } else {
                    that._errorBar && that._errorBar.attr({
                        visibility: "hidden"
                    })
                }
            },
            getTooltipParams: function() {
                var that = this,
                    graphic = that.graphic;
                return {
                    x: that.x,
                    y: that.y,
                    offset: graphic ? graphic.getBBox().height / 2 : 0
                }
            },
            setPercentValue: function(total, fullStacked, leftHoleTotal, rightHoleTotal) {
                var that = this,
                    valuePercent = that.value / total || 0,
                    minValuePercent = that.minValue / total || 0,
                    percent = valuePercent - minValuePercent;
                that._label.setDataField("percent", percent);
                that._label.setDataField("total", total);
                if (that.series.isFullStackedSeries() && that.hasValue()) {
                    if (that.leftHole) {
                        that.leftHole /= total - leftHoleTotal;
                        that.minLeftHole /= total - leftHoleTotal
                    }
                    if (that.rightHole) {
                        that.rightHole /= total - rightHoleTotal;
                        that.minRightHole /= total - rightHoleTotal
                    }
                    that.value = valuePercent;
                    that.minValue = !minValuePercent ? that.minValue : minValuePercent;
                    that.translate()
                }
            },
            _storeTrackerR: function() {
                var minTrackerSize, that = this,
                    navigator = window.navigator,
                    r = that._options.styles.normal.r;
                navigator = that.__debug_navigator || navigator;
                that.__debug_browserNavigator = navigator;
                minTrackerSize = "ontouchstart" in window || navigator.msPointerEnabled && navigator.msMaxTouchPoints || navigator.pointerEnabled && navigator.maxTouchPoints ? 20 : 6;
                that._options.trackerR = r < minTrackerSize ? minTrackerSize : r;
                return that._options.trackerR
            },
            _translateErrorBars: function(valueTranslator) {
                var that = this,
                    options = that._options,
                    rotated = options.rotated,
                    errorBars = options.errorBars;
                if (!errorBars) {
                    return
                }
                _isDefined(that.lowError) && (that._lowErrorCoord = valueTranslator.translate(that.lowError));
                _isDefined(that.highError) && (that._highErrorCoord = valueTranslator.translate(that.highError));
                that._errorBarPos = _floor(rotated ? that.vy : that.vx);
                that._baseErrorBarPos = "stdDeviation" === errorBars.type ? that._lowErrorCoord + (that._highErrorCoord - that._lowErrorCoord) / 2 : rotated ? that.vx : that.vy
            },
            _translate: function(translators) {
                var valueTranslator, that = this;
                if (that._options.rotated) {
                    valueTranslator = translators.x;
                    that.vx = that.x = valueTranslator.translate(that.value);
                    that.vy = that.y = translators.y.translate(that.argument);
                    that.minX = valueTranslator.translate(that.minValue);
                    that.defaultX = valueTranslator.translate(CANVAS_POSITION_DEFAULT);
                    that._translateErrorBars(valueTranslator)
                } else {
                    valueTranslator = translators.y;
                    that.vy = that.y = valueTranslator.translate(that.value);
                    that.vx = that.x = translators.x.translate(that.argument);
                    that.minY = valueTranslator.translate(that.minValue);
                    that.defaultY = valueTranslator.translate(CANVAS_POSITION_DEFAULT);
                    that._translateErrorBars(valueTranslator)
                }
                that._calculateVisibility(that.x, that.y)
            },
            _updateData: function(data) {
                var that = this;
                that.value = that.initialValue = that.originalValue = data.value;
                that.minValue = that.initialMinValue = that.originalMinValue = _isDefined(data.minValue) ? data.minValue : CANVAS_POSITION_DEFAULT
            },
            _getImageSettings: function(image) {
                return {
                    href: image.url || image.toString(),
                    width: image.width || DEFAULT_IMAGE_WIDTH,
                    height: image.height || DEFAULT_IMAGE_HEIGHT
                }
            },
            getCrosshairData: function() {
                var that = this,
                    r = that._options.rotated,
                    value = that.value,
                    argument = that.argument;
                return {
                    x: that.vx,
                    y: that.vy,
                    xValue: r ? value : argument,
                    yValue: r ? argument : value,
                    axis: that.series.axis
                }
            },
            getPointRadius: function() {
                var extraSpace, style = this._getStyle(),
                    options = this._options,
                    r = style.r,
                    symbol = options.symbol,
                    isSquare = "square" === symbol,
                    isTriangle = "triangle" === symbol || "triangleDown" === symbol || "triangleUp" === symbol;
                if (options.visible && !options.image && r) {
                    extraSpace = style["stroke-width"] / 2;
                    return (isSquare || isTriangle ? 1.4 * r : r) + extraSpace
                }
                return 0
            },
            _updateMarker: function(animationEnabled, style) {
                var settings, that = this,
                    options = that._options,
                    image = options.image,
                    visibility = !that.isVisible() ? {
                        visibility: "hidden"
                    } : {};
                style = style || that._getStyle();
                if (that._checkImage(image)) {
                    settings = _extend({}, {
                        visibility: style.visibility
                    }, visibility, that._getImageSettings(image))
                } else {
                    settings = _extend({}, style, visibility, {
                        points: that._populatePointShape(options.symbol, style.r)
                    })
                }
                if (!animationEnabled) {
                    settings.translateX = that.x;
                    settings.translateY = that.y
                }
                that.graphic.attr(settings).sharp()
            },
            _getLabelFormatObject: function() {
                var that = this;
                return {
                    argument: that.initialArgument,
                    value: that.initialValue,
                    originalArgument: that.originalArgument,
                    originalValue: that.originalValue,
                    seriesName: that.series.name,
                    lowErrorValue: that.lowError,
                    highErrorValue: that.highError,
                    point: that
                }
            },
            _getLabelPosition: function() {
                var rotated = this._options.rotated;
                if (this.initialValue > 0) {
                    return rotated ? "right" : "top"
                } else {
                    return rotated ? "left" : "bottom"
                }
            },
            _getFormatObject: function(tooltip) {
                var that = this,
                    labelFormatObject = that._label.getData();
                return _extend({}, labelFormatObject, {
                    argumentText: tooltip.formatValue(that.initialArgument, "argument"),
                    valueText: tooltip.formatValue(that.initialValue)
                }, _isDefined(labelFormatObject.percent) ? {
                    percentText: tooltip.formatValue(labelFormatObject.percent, "percent")
                } : {}, _isDefined(labelFormatObject.total) ? {
                    totalText: tooltip.formatValue(labelFormatObject.total)
                } : {})
            },
            _getMarkerVisibility: function() {
                return this._options.visible
            },
            coordsIn: function(x, y) {
                var trackerRadius = this._storeTrackerR();
                return x >= this.x - trackerRadius && x <= this.x + trackerRadius && y >= this.y - trackerRadius && y <= this.y + trackerRadius
            }
        }
    },
    /*!********************************************!*\
      !*** ./Scripts/viz/series/points/label.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _format = __webpack_require__( /*! ../../core/format */ 465),
            vizUtils = __webpack_require__( /*! ../../core/utils */ 442),
            _degreesToRadians = vizUtils.degreesToRadians,
            _patchFontOptions = vizUtils.patchFontOptions,
            _round = Math.round,
            _getCosAndSin = vizUtils.getCosAndSin,
            _rotateBBox = vizUtils.rotateBBox,
            LABEL_BACKGROUND_PADDING_X = 8,
            LABEL_BACKGROUND_PADDING_Y = 4;

        function getClosestCoord(point, coords) {
            var closestCoord, closestDistance = 1 / 0;
            $.each(coords, function(_, coord) {
                var x = point[0] - coord[0],
                    y = point[1] - coord[1],
                    distance = x * x + y * y;
                if (distance < closestDistance) {
                    closestDistance = distance;
                    closestCoord = coord
                }
            });
            return closestCoord
        }
        var barPointStrategy = {
            isLabelInside: function(labelPoint, figure) {
                return labelPoint.x >= figure.x && labelPoint.x <= figure.x + figure.width && labelPoint.y >= figure.y && labelPoint.y <= figure.y + figure.height
            },
            prepareLabelPoints: function(points) {
                return points
            },
            getFigureCenter: function(figure) {
                return [figure.x + figure.width / 2, figure.y + figure.height / 2]
            },
            findFigurePoint: function(figure, labelPoint) {
                var figureCenter = barPointStrategy.getFigureCenter(figure),
                    point = getClosestCoord(labelPoint, [
                        [figure.x, figureCenter[1]],
                        [figureCenter[0], figure.y + figure.height],
                        [figure.x + figure.width, figureCenter[1]],
                        [figureCenter[0], figure.y]
                    ]);
                return [_round(point[0]), _round(point[1])]
            }
        };
        var symbolPointStrategy = {
            isLabelInside: function() {
                return false
            },
            prepareLabelPoints: barPointStrategy.prepareLabelPoints,
            getFigureCenter: function(figure) {
                return [figure.x, figure.y]
            },
            findFigurePoint: function(figure, labelPoint) {
                var angle = Math.atan2(figure.y - labelPoint[1], labelPoint[0] - figure.x);
                return [_round(figure.x + figure.r * Math.cos(angle)), _round(figure.y - figure.r * Math.sin(angle))]
            }
        };
        var piePointStrategy = {
            isLabelInside: function(_0, _1, isOutside) {
                return !isOutside
            },
            prepareLabelPoints: function(points, center, angle) {
                var rotatedPoints = [],
                    x0 = center[0],
                    y0 = center[1],
                    cossin = _getCosAndSin(angle || 0);
                $.each(points, function(_, point) {
                    rotatedPoints.push([_round((point[0] - x0) * cossin.cos + (point[1] - y0) * cossin.sin + x0), _round(-(point[0] - x0) * cossin.sin + (point[1] - y0) * cossin.cos + y0)])
                });
                return rotatedPoints
            },
            getFigureCenter: symbolPointStrategy.getFigureCenter,
            findFigurePoint: function(figure, labelPoint) {
                var x = figure.x + (figure.y - labelPoint[1]) / Math.tan(_degreesToRadians(figure.angle)),
                    point = [figure.x, figure.y];
                if (figure.x <= x && x <= labelPoint[0] || figure.x >= x && x >= labelPoint[0]) {
                    point.push(_round(x), labelPoint[1])
                }
                return point
            }
        };

        function selectStrategy(figure) {
            return void 0 !== figure.angle && piePointStrategy || void 0 !== figure.r && symbolPointStrategy || barPointStrategy
        }

        function disposeItem(obj, field) {
            obj[field] && obj[field].dispose();
            obj[field] = null
        }

        function checkBackground(background) {
            return background && (background.fill && "none" !== background.fill || background["stroke-width"] > 0 && background.stroke && "none" !== background.stroke)
        }

        function checkConnector(connector) {
            return connector && connector["stroke-width"] > 0 && connector.stroke && "none" !== connector.stroke
        }

        function formatText(data, options) {
            data.valueText = _format(data.value, options);
            data.argumentText = _format(data.argument, {
                format: options.argumentFormat,
                precision: options.argumentPrecision
            });
            if (void 0 !== data.percent) {
                data.percentText = _format(data.percent, {
                    format: {
                        type: "percent",
                        precision: options.format && options.format.percentPrecision || options.percentPrecision
                    }
                })
            }
            if (void 0 !== data.total) {
                data.totalText = _format(data.total, options)
            }
            if (void 0 !== data.openValue) {
                data.openValueText = _format(data.openValue, options)
            }
            if (void 0 !== data.closeValue) {
                data.closeValueText = _format(data.closeValue, options)
            }
            if (void 0 !== data.lowValue) {
                data.lowValueText = _format(data.lowValue, options)
            }
            if (void 0 !== data.highValue) {
                data.highValueText = _format(data.highValue, options)
            }
            if (void 0 !== data.reductionValue) {
                data.reductionValueText = _format(data.reductionValue, options)
            }
            return options.customizeText ? options.customizeText.call(data, data) : data.valueText
        }

        function Label(renderSettings) {
            this._renderer = renderSettings.renderer;
            this._container = renderSettings.labelsGroup;
            this._point = renderSettings.point
        }
        Label.prototype = {
            constructor: Label,
            _setVisibility: function(value, state) {
                this._group && this._group.attr({
                    visibility: value
                });
                this._visible = state
            },
            clearVisibility: function() {
                this._setVisibility(null, true)
            },
            hide: function() {
                this._setVisibility("hidden", false)
            },
            show: function() {
                var that = this;
                if (that._point.hasValue()) {
                    that._draw();
                    that._point.correctLabelPosition(that)
                }
            },
            isVisible: function() {
                return this._visible
            },
            setColor: function(color) {
                this._color = color
            },
            setOptions: function(options) {
                this._options = options
            },
            setData: function(data) {
                this._data = data
            },
            setDataField: function(fieldName, fieldValue) {
                this._data = this._data || {};
                this._data[fieldName] = fieldValue
            },
            getData: function() {
                return this._data
            },
            setFigureToDrawConnector: function(figure) {
                this._figure = figure
            },
            dispose: function() {
                var that = this;
                disposeItem(that, "_group");
                that._data = that._options = that._textContent = that._visible = that._insideGroup = that._text = that._background = that._connector = that._figure = null
            },
            _draw: function() {
                var that = this,
                    renderer = that._renderer,
                    container = that._container,
                    options = that._options || {},
                    text = that._textContent = formatText(that._data, that._options) || null;
                that.clearVisibility();
                if (text) {
                    if (!that._group) {
                        that._group = renderer.g().append(container);
                        that._insideGroup = renderer.g().append(that._group);
                        that._text = renderer.text("", 0, 0).append(that._insideGroup)
                    }
                    that._text.css(options.attributes ? _patchFontOptions(options.attributes.font) : {});
                    if (checkBackground(options.background)) {
                        that._background = that._background || renderer.rect().append(that._insideGroup).toBackground();
                        that._background.attr(options.background);
                        that._color && that._background.attr({
                            fill: that._color
                        })
                    } else {
                        disposeItem(that, "_background")
                    }
                    if (checkConnector(options.connector)) {
                        that._connector = that._connector || renderer.path([], "line").sharp().append(that._group).toBackground();
                        that._connector.attr(options.connector);
                        that._color && that._connector.attr({
                            stroke: that._color
                        })
                    } else {
                        disposeItem(that, "_connector")
                    }
                    that._text.attr({
                        text: text
                    });
                    that._updateBackground(that._text.getBBox());
                    that._setVisibility("visible", true)
                } else {
                    that.hide()
                }
                return that
            },
            _updateBackground: function(bbox) {
                var that = this;
                that._textSize = [bbox.width, bbox.height];
                if (that._background) {
                    bbox.x -= LABEL_BACKGROUND_PADDING_X;
                    bbox.y -= LABEL_BACKGROUND_PADDING_Y;
                    bbox.width += 2 * LABEL_BACKGROUND_PADDING_X;
                    bbox.height += 2 * LABEL_BACKGROUND_PADDING_Y;
                    that._background.attr(bbox)
                }
                if (that._options.rotationAngle) {
                    that._insideGroup.rotate(that._options.rotationAngle, bbox.x + bbox.width / 2, bbox.y + bbox.height / 2);
                    bbox = _rotateBBox(bbox, [bbox.x + bbox.width / 2, bbox.y + bbox.height / 2], -that._options.rotationAngle)
                }
                that._bbox = bbox
            },
            _getConnectorPoints: function() {
                var labelPoint, figurePoint, xc, yc, that = this,
                    figure = that._figure,
                    strategy = selectStrategy(figure),
                    bbox = that.getBoundingRect(),
                    points = [];
                if (!strategy.isLabelInside(bbox, figure, "inside" !== that._options.position)) {
                    xc = bbox.x + bbox.width / 2;
                    yc = bbox.y + bbox.height / 2;
                    points = strategy.prepareLabelPoints([
                        [xc, yc - that._textSize[1] / 2],
                        [xc + that._textSize[0] / 2, yc],
                        [xc, yc + that._textSize[1] / 2],
                        [xc - that._textSize[0] / 2, yc]
                    ], [xc, yc], -that._options.rotationAngle || 0);
                    labelPoint = getClosestCoord(strategy.getFigureCenter(figure), points);
                    labelPoint = [_round(labelPoint[0]), _round(labelPoint[1])];
                    figurePoint = strategy.findFigurePoint(figure, labelPoint);
                    points = figurePoint.concat(labelPoint)
                }
                return points
            },
            fit: function(maxWidth) {
                this._text && this._text.applyEllipsis(maxWidth);
                this._updateBackground(this._text.getBBox())
            },
            setTrackerData: function(point) {
                this._text.data({
                    "chart-data-point": point
                });
                this._background && this._background.data({
                    "chart-data-point": point
                })
            },
            shift: function(x, y) {
                var that = this;
                if (that._textContent) {
                    that._insideGroup.attr({
                        translateX: that._x = _round(x - that._bbox.x),
                        translateY: that._y = _round(y - that._bbox.y)
                    });
                    if (that._connector) {
                        that._connector.attr({
                            points: that._getConnectorPoints()
                        })
                    }
                }
                return that
            },
            getBoundingRect: function() {
                var bbox = this._bbox;
                return this._textContent ? {
                    x: bbox.x + this._x,
                    y: bbox.y + this._y,
                    width: bbox.width,
                    height: bbox.height
                } : {}
            },
            getLayoutOptions: function() {
                var options = this._options;
                return {
                    alignment: options.alignment,
                    background: checkBackground(options.background),
                    horizontalOffset: options.horizontalOffset,
                    verticalOffset: options.verticalOffset,
                    radialOffset: options.radialOffset,
                    position: options.position
                }
            }
        };
        exports.Label = Label;
        Label._DEBUG_formatText = formatText
    },
    /*!************************************!*\
      !*** ./Scripts/viz/core/format.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var _format = __webpack_require__( /*! ../../format_helper */ 55).format;
        module.exports = function(value, options) {
            return _format(value, options.format, options.precision)
        }
    },
    /*!************************************************!*\
      !*** ./Scripts/viz/series/points/bar_point.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _extend = $.extend,
            _math = Math,
            _floor = _math.floor,
            _abs = _math.abs,
            _min = _math.min,
            symbolPoint = __webpack_require__( /*! ./symbol_point */ 463),
            CANVAS_POSITION_DEFAULT = "canvas_position_default",
            DEFAULT_BAR_TRACKER_SIZE = 9,
            CORRECTING_BAR_TRACKER_VALUE = 4,
            RIGHT = "right",
            LEFT = "left",
            TOP = "top",
            BOTTOM = "bottom";
        module.exports = _extend({}, symbolPoint, {
            correctCoordinates: function(correctOptions) {
                var correction = _floor(correctOptions.offset - correctOptions.width / 2),
                    rotated = this._options.rotated,
                    valueSelector = rotated ? "height" : "width",
                    correctionSelector = (rotated ? "y" : "x") + "Correction";
                this[valueSelector] = correctOptions.width;
                this[correctionSelector] = correction
            },
            _getGraphicBbox: function() {
                var that = this,
                    bbox = {};
                bbox.x = that.x;
                bbox.y = that.y;
                bbox.width = that.width;
                bbox.height = that.height;
                return bbox
            },
            _getLabelConnector: function(location) {
                return this._getGraphicBbox(location)
            },
            _getLabelPosition: function() {
                var position, that = this,
                    translators = that.translators,
                    initialValue = that.initialValue,
                    invertX = translators.x.getBusinessRange().invert,
                    invertY = translators.y.getBusinessRange().invert,
                    isDiscreteValue = "discrete" === that.series.valueAxisType,
                    isFullStacked = that.series.isFullStackedSeries(),
                    notVerticalInverted = !isDiscreteValue && (initialValue >= 0 && !invertY || initialValue < 0 && invertY) || isDiscreteValue && !invertY || isFullStacked,
                    notHorizontalInverted = !isDiscreteValue && (initialValue >= 0 && !invertX || initialValue < 0 && invertX) || isDiscreteValue && !invertX || isFullStacked;
                if (!that._options.rotated) {
                    position = notVerticalInverted ? TOP : BOTTOM
                } else {
                    position = notHorizontalInverted ? RIGHT : LEFT
                }
                return position
            },
            _getLabelCoords: function(label) {
                var coords, that = this;
                if (0 === that.initialValue && that.series.isFullStackedSeries()) {
                    if (!this._options.rotated) {
                        coords = that._getLabelCoordOfPosition(label, TOP)
                    } else {
                        coords = that._getLabelCoordOfPosition(label, RIGHT)
                    }
                } else {
                    if ("inside" === label.getLayoutOptions().position) {
                        coords = that._getLabelCoordOfPosition(label, "inside")
                    } else {
                        coords = symbolPoint._getLabelCoords.call(this, label)
                    }
                }
                return coords
            },
            _checkLabelPosition: function(label, coord) {
                var that = this,
                    visibleArea = that._getVisibleArea();
                if (that._isPointInVisibleArea(visibleArea, that._getGraphicBbox())) {
                    return that._moveLabelOnCanvas(coord, visibleArea, label.getBoundingRect())
                }
                return coord
            },
            _isLabelInsidePoint: function(label) {
                var that = this,
                    graphicBbox = that._getGraphicBbox(),
                    labelBbox = label.getBoundingRect();
                if (that._options.resolveLabelsOverlapping && "inside" === label.getLayoutOptions().position) {
                    if (labelBbox.width > graphicBbox.width || labelBbox.height > graphicBbox.height) {
                        label.hide();
                        return true
                    }
                }
                return false
            },
            _moveLabelOnCanvas: function(coord, visibleArea, labelBbox) {
                var x = coord.x,
                    y = coord.y;
                if (visibleArea.minX > x) {
                    x = visibleArea.minX
                }
                if (visibleArea.maxX < x + labelBbox.width) {
                    x = visibleArea.maxX - labelBbox.width
                }
                if (visibleArea.minY > y) {
                    y = visibleArea.minY
                }
                if (visibleArea.maxY < y + labelBbox.height) {
                    y = visibleArea.maxY - labelBbox.height
                }
                return {
                    x: x,
                    y: y
                }
            },
            _showForZeroValues: function() {
                return this._options.label.showForZeroValues || this.initialValue
            },
            _drawMarker: function(renderer, group, animationEnabled) {
                var that = this,
                    style = that._getStyle(),
                    x = that.x,
                    y = that.y,
                    width = that.width,
                    height = that.height,
                    r = that._options.cornerRadius;
                if (animationEnabled) {
                    if (that._options.rotated) {
                        width = 0;
                        x = that.defaultX
                    } else {
                        height = 0;
                        y = that.defaultY
                    }
                }
                that.graphic = renderer.rect(x, y, width, height).attr({
                    rx: r,
                    ry: r
                }).attr(style).data({
                    "chart-data-point": that
                }).append(group)
            },
            _getSettingsForTracker: function() {
                var that = this,
                    y = that.y,
                    height = that.height,
                    x = that.x,
                    width = that.width;
                if (that._options.rotated) {
                    if (1 === width) {
                        width = DEFAULT_BAR_TRACKER_SIZE;
                        x -= CORRECTING_BAR_TRACKER_VALUE
                    }
                } else {
                    if (1 === height) {
                        height = DEFAULT_BAR_TRACKER_SIZE;
                        y -= CORRECTING_BAR_TRACKER_VALUE
                    }
                }
                return {
                    x: x,
                    y: y,
                    width: width,
                    height: height
                }
            },
            getGraphicSettings: function() {
                var graphic = this.graphic;
                return {
                    x: graphic.attr("x"),
                    y: graphic.attr("y"),
                    height: graphic.attr("height"),
                    width: graphic.attr("width")
                }
            },
            _getEdgeTooltipParams: function(x, y, width, height) {
                var xCoord, yCoord, isPositive = this.value >= 0,
                    invertedY = this.translators.y.getBusinessRange().invert,
                    invertedX = this.translators.x.getBusinessRange().invert;
                if (this._options.rotated) {
                    yCoord = y + height / 2;
                    if (invertedX) {
                        xCoord = isPositive ? x : x + width
                    } else {
                        xCoord = isPositive ? x + width : x
                    }
                } else {
                    xCoord = x + width / 2;
                    if (invertedY) {
                        yCoord = isPositive ? y + height : y
                    } else {
                        yCoord = isPositive ? y : y + height
                    }
                }
                return {
                    x: xCoord,
                    y: yCoord,
                    offset: 0
                }
            },
            getTooltipParams: function(location) {
                var x = this.x,
                    y = this.y,
                    width = this.width,
                    height = this.height;
                return "edge" === location ? this._getEdgeTooltipParams(x, y, width, height) : {
                    x: x + width / 2,
                    y: y + height / 2,
                    offset: 0
                }
            },
            _truncateCoord: function(coord, minBounce, maxBounce) {
                if (coord < minBounce) {
                    return minBounce
                }
                if (coord > maxBounce) {
                    return maxBounce
                }
                return coord
            },
            _translateErrorBars: function(valueTranslator, argVisibleArea) {
                symbolPoint._translateErrorBars.call(this, valueTranslator);
                if (this._errorBarPos < argVisibleArea.min || this._errorBarPos > argVisibleArea.max) {
                    this._errorBarPos = void 0
                }
            },
            _translate: function(translators) {
                var arg, minArg, val, minVal, that = this,
                    rotated = that._options.rotated,
                    valAxis = rotated ? "x" : "y",
                    argAxis = rotated ? "y" : "x",
                    valIntervalName = rotated ? "width" : "height",
                    argIntervalName = rotated ? "height" : "width",
                    argTranslator = translators[argAxis],
                    valTranslator = translators[valAxis],
                    argVisibleArea = argTranslator.getCanvasVisibleArea(),
                    valVisibleArea = valTranslator.getCanvasVisibleArea();
                arg = minArg = argTranslator.translate(that.argument) + (that[argAxis + "Correction"] || 0);
                val = valTranslator.translate(that.value);
                minVal = valTranslator.translate(that.minValue);
                that["v" + valAxis] = val;
                that["v" + argAxis] = arg + that[argIntervalName] / 2;
                that[valIntervalName] = _abs(val - minVal);
                that._calculateVisibility(rotated ? _min(val, minVal) : _min(arg, minArg), rotated ? _min(arg, minArg) : _min(val, minVal), that.width, that.height);
                val = that._truncateCoord(val, valVisibleArea.min, valVisibleArea.max);
                minVal = that._truncateCoord(minVal, valVisibleArea.min, valVisibleArea.max);
                that[argAxis] = arg;
                that["min" + argAxis.toUpperCase()] = minArg;
                that[valIntervalName] = _abs(val - minVal);
                that[valAxis] = _min(val, minVal) + (that[valAxis + "Correction"] || 0);
                that["min" + valAxis.toUpperCase()] = minVal + (that[valAxis + "Correction"] || 0);
                that["default" + valAxis.toUpperCase()] = valTranslator.translate(CANVAS_POSITION_DEFAULT);
                that._translateErrorBars(valTranslator, argVisibleArea);
                if (that.inVisibleArea) {
                    if (that[argAxis] < argVisibleArea.min) {
                        that[argIntervalName] = that[argIntervalName] - (argVisibleArea.min - that[argAxis]);
                        that[argAxis] = argVisibleArea.min;
                        that["min" + argAxis.toUpperCase()] = argVisibleArea.min
                    }
                    if (that[argAxis] + that[argIntervalName] > argVisibleArea.max) {
                        that[argIntervalName] = argVisibleArea.max - that[argAxis]
                    }
                }
            },
            _updateMarker: function(animationEnabled, style) {
                this.graphic.attr(_extend({}, style || this._getStyle(), !animationEnabled ? this.getMarkerCoords() : {}))
            },
            getMarkerCoords: function() {
                return {
                    x: this.x,
                    y: this.y,
                    width: this.width,
                    height: this.height
                }
            },
            coordsIn: function(x, y) {
                var that = this;
                return x >= that.x && x <= that.x + that.width && y >= that.y && y <= that.y + that.height
            }
        })
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/series/points/bubble_point.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            symbolPoint = __webpack_require__( /*! ./symbol_point */ 463),
            _extend = $.extend,
            MIN_BUBBLE_HEIGHT = 20;
        module.exports = _extend({}, symbolPoint, {
            correctCoordinates: function(diameter) {
                this.bubbleSize = diameter / 2
            },
            _drawMarker: function(renderer, group, animationEnabled) {
                var that = this,
                    attr = _extend({
                        translateX: that.x,
                        translateY: that.y
                    }, that._getStyle());
                that.graphic = renderer.circle(0, 0, animationEnabled ? 0 : that.bubbleSize).attr(attr).data({
                    "chart-data-point": that
                }).append(group)
            },
            getTooltipParams: function(location) {
                var height, that = this,
                    graphic = that.graphic;
                if (!graphic) {
                    return
                }
                height = graphic.getBBox().height;
                return {
                    x: that.x,
                    y: height < MIN_BUBBLE_HEIGHT || "edge" === location ? this.y - height / 2 : this.y,
                    offset: 0
                }
            },
            _getLabelFormatObject: function() {
                var formatObject = symbolPoint._getLabelFormatObject.call(this);
                formatObject.size = this.initialSize;
                return formatObject
            },
            _updateData: function(data) {
                symbolPoint._updateData.call(this, data);
                this.size = this.initialSize = data.size
            },
            _getGraphicBbox: function() {
                var that = this;
                return that._getSymbolBbox(that.x, that.y, that.bubbleSize)
            },
            _updateMarker: function(animationEnabled, style) {
                var that = this;
                style = style || that._getStyle();
                if (!animationEnabled) {
                    style = $.extend({
                        r: that.bubbleSize,
                        translateX: that.x,
                        translateY: that.y
                    }, style)
                }
                that.graphic.attr(style)
            },
            _getFormatObject: function(tooltip) {
                var formatObject = symbolPoint._getFormatObject.call(this, tooltip);
                formatObject.sizeText = tooltip.formatValue(this.initialSize);
                return formatObject
            },
            _storeTrackerR: function() {
                return this.bubbleSize
            },
            _getLabelCoords: function(label) {
                var coords;
                if ("inside" === label.getLayoutOptions().position) {
                    coords = this._getLabelCoordOfPosition(label, "inside")
                } else {
                    coords = symbolPoint._getLabelCoords.call(this, label)
                }
                return coords
            }
        })
    },
    /*!************************************************!*\
      !*** ./Scripts/viz/series/points/pie_point.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            CONNECTOR_LENGTH = 20,
            symbolPoint = __webpack_require__( /*! ./symbol_point */ 463),
            _extend = $.extend,
            _round = Math.round,
            _sqrt = Math.sqrt,
            _acos = Math.acos,
            DEG = 180 / Math.PI,
            _abs = Math.abs,
            vizUtils = __webpack_require__( /*! ../../core/utils */ 442),
            _normalizeAngle = vizUtils.normalizeAngle,
            _getCosAndSin = vizUtils.getCosAndSin,
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            getVerticallyShiftedAngularCoords = vizUtils.getVerticallyShiftedAngularCoords,
            INDENT_FROM_PIE = __webpack_require__( /*! ../../components/consts */ 462).pieLabelIndent;
        module.exports = _extend({}, symbolPoint, {
            _updateData: function(data) {
                var that = this;
                symbolPoint._updateData.call(this, data);
                that._visible = true;
                that.minValue = that.initialMinValue = that.originalMinValue = _isDefined(data.minValue) ? data.minValue : 0
            },
            animate: function(complete, duration, step) {
                var that = this;
                that.graphic.animate({
                    x: that.centerX,
                    y: that.centerY,
                    outerRadius: that.radiusOuter,
                    innerRadius: that.radiusInner,
                    startAngle: that.toAngle,
                    endAngle: that.fromAngle
                }, {
                    partitionDuration: duration,
                    step: step
                }, complete)
            },
            correctPosition: function(correction) {
                var that = this;
                that.correctRadius(correction);
                that.correctLabelRadius(correction.radiusOuter);
                that.centerX = correction.centerX;
                that.centerY = correction.centerY
            },
            correctRadius: function(correction) {
                this.radiusInner = correction.radiusInner;
                this.radiusOuter = correction.radiusOuter
            },
            correctLabelRadius: function(radiusLabels) {
                this.radiusLabels = radiusLabels
            },
            correctValue: function(correction, percent, base) {
                var that = this;
                that.value = (base || that.initialValue) + correction;
                that.minValue = correction;
                that.percent = percent;
                that._label.setDataField("percent", percent)
            },
            setMaxLabelLength: function(maxLabelLength) {
                this._maxLabelLength = maxLabelLength
            },
            _updateLabelData: function() {
                this._label.setData(this._getLabelFormatObject())
            },
            _getShiftLabelCoords: function() {
                var that = this,
                    bbox = that._label.getBoundingRect(),
                    coord = that._getLabelCoords(that._label),
                    visibleArea = that._getVisibleArea();
                if (that._isLabelDrawingWithoutPoints) {
                    return that._checkLabelPosition(coord, bbox, visibleArea)
                } else {
                    return that._getLabelExtraCoord(coord, that._checkVerticalLabelPosition(coord, bbox, visibleArea), bbox)
                }
            },
            _getLabelPosition: function(options) {
                return options.position
            },
            _getLabelCoords: function(label) {
                var rad, x, that = this,
                    bbox = label.getBoundingRect(),
                    options = label.getLayoutOptions(),
                    angleFunctions = _getCosAndSin(that.middleAngle),
                    position = that._getLabelPosition(options),
                    radiusInner = that.radiusInner,
                    radiusOuter = that.radiusOuter,
                    radiusLabels = that.radiusLabels;
                if ("inside" === position) {
                    rad = radiusInner + (radiusOuter - radiusInner) / 2 + options.radialOffset;
                    x = that.centerX + rad * angleFunctions.cos - bbox.width / 2
                } else {
                    rad = radiusLabels + options.radialOffset + INDENT_FROM_PIE;
                    if (angleFunctions.cos > .1) {
                        x = that.centerX + rad * angleFunctions.cos
                    } else {
                        if (angleFunctions.cos < -.1) {
                            x = that.centerX + rad * angleFunctions.cos - bbox.width
                        } else {
                            x = that.centerX + rad * angleFunctions.cos - bbox.width / 2
                        }
                    }
                }
                return {
                    x: x,
                    y: _round(that.centerY - rad * angleFunctions.sin - bbox.height / 2)
                }
            },
            _getColumnsCoord: function(coord) {
                var x, that = this,
                    label = that._label,
                    bbox = label.getBoundingRect(),
                    options = label.getLayoutOptions(),
                    rad = that.radiusLabels + options.radialOffset,
                    visibleArea = that._getVisibleArea(),
                    rightBorderX = visibleArea.maxX - bbox.width,
                    leftBorderX = visibleArea.minX,
                    angleOfPoint = _normalizeAngle(that.middleAngle);
                if ("columns" !== options.position) {
                    return coord
                }
                rad += CONNECTOR_LENGTH;
                if (angleOfPoint < 90 || angleOfPoint >= 270) {
                    x = that._maxLabelLength ? that.centerX + rad + that._maxLabelLength - bbox.width : rightBorderX;
                    x = x > rightBorderX ? rightBorderX : x
                } else {
                    x = that._maxLabelLength ? that.centerX - rad - that._maxLabelLength : leftBorderX;
                    x = x < leftBorderX ? leftBorderX : x
                }
                coord.x = x;
                return coord
            },
            drawLabel: function(translators) {
                this.translate(translators);
                this._isLabelDrawingWithoutPoints = true;
                this._drawLabel();
                this._isLabelDrawingWithoutPoints = false
            },
            updateLabelCoord: function() {
                var that = this,
                    bbox = that._label.getBoundingRect(),
                    coord = that._getColumnsCoord(bbox);
                coord = that._checkHorizontalLabelPosition(coord, bbox, that._getVisibleArea());
                that._label.shift(_round(coord.x), _round(bbox.y))
            },
            _checkVerticalLabelPosition: function(coord, box, visibleArea) {
                var x = coord.x,
                    y = coord.y;
                if (coord.y + box.height > visibleArea.maxY) {
                    y = visibleArea.maxY - box.height
                } else {
                    if (coord.y < visibleArea.minY) {
                        y = visibleArea.minY
                    }
                }
                return {
                    x: x,
                    y: y
                }
            },
            _getLabelExtraCoord: function(coord, shiftCoord, box) {
                return coord.y !== shiftCoord.y ? getVerticallyShiftedAngularCoords({
                    x: coord.x,
                    y: coord.y,
                    width: box.width,
                    height: box.height
                }, shiftCoord.y - coord.y, {
                    x: this.centerX,
                    y: this.centerY
                }) : coord
            },
            _checkHorizontalLabelPosition: function(coord, box, visibleArea) {
                var x = coord.x,
                    y = coord.y;
                if (coord.x + box.width > visibleArea.maxX) {
                    x = visibleArea.maxX - box.width
                } else {
                    if (coord.x < visibleArea.minX) {
                        x = visibleArea.minX
                    }
                }
                return {
                    x: x,
                    y: y
                }
            },
            setLabelEllipsis: function() {
                var that = this,
                    bbox = that._label.getBoundingRect(),
                    coord = that._checkHorizontalLabelPosition(bbox, bbox, that._getVisibleArea());
                that._label.fit(bbox.width - _abs(coord.x - bbox.x))
            },
            setLabelTrackerData: function() {
                this._label.setTrackerData(this)
            },
            _checkLabelPosition: function(coord, bbox, visibleArea) {
                coord = this._checkHorizontalLabelPosition(coord, bbox, visibleArea);
                return this._checkVerticalLabelPosition(coord, bbox, visibleArea)
            },
            getBoundaryCoords: function() {
                var that = this,
                    rad = that.radiusOuter,
                    seriesStyle = that._options.styles.normal,
                    strokeWidthBy2 = seriesStyle["stroke-width"] / 2,
                    borderWidth = that.series.getOptions().containerBackgroundColor === seriesStyle.stroke ? _round(strokeWidthBy2) : _round(-strokeWidthBy2),
                    angleFunctions = _getCosAndSin(_round(that.middleAngle));
                return {
                    x: _round(that.centerX + (rad - borderWidth) * angleFunctions.cos),
                    y: _round(that.centerY - (rad - borderWidth) * angleFunctions.sin)
                }
            },
            _getLabelConnector: function() {
                var coords = this.getBoundaryCoords();
                coords.angle = this.middleAngle;
                return coords
            },
            _drawMarker: function(renderer, group, animationEnabled, firstDrawing) {
                var that = this,
                    radiusOuter = that.radiusOuter,
                    radiusInner = that.radiusInner,
                    fromAngle = that.fromAngle,
                    toAngle = that.toAngle;
                if (animationEnabled) {
                    radiusInner = radiusOuter = 0;
                    if (!firstDrawing) {
                        fromAngle = toAngle = that.shiftedAngle
                    }
                }
                that.graphic = renderer.arc(that.centerX, that.centerY, radiusInner, radiusOuter, toAngle, fromAngle).attr({
                    "stroke-linejoin": "round"
                }).attr(that._getStyle()).data({
                    "chart-data-point": that
                }).sharp().append(group)
            },
            getTooltipParams: function() {
                var that = this,
                    angleFunctions = _getCosAndSin(that.middleAngle),
                    radiusInner = that.radiusInner,
                    radiusOuter = that.radiusOuter;
                return {
                    x: that.centerX + (radiusInner + (radiusOuter - radiusInner) / 2) * angleFunctions.cos,
                    y: that.centerY - (radiusInner + (radiusOuter - radiusInner) / 2) * angleFunctions.sin,
                    offset: 0
                }
            },
            _translate: function(translator) {
                var that = this,
                    angle = that.shiftedAngle || 0,
                    value = that.value,
                    minValue = that.minValue;
                that.fromAngle = translator.translate(minValue) + angle;
                that.toAngle = translator.translate(value) + angle;
                that.middleAngle = translator.translate((value - minValue) / 2 + minValue) + angle;
                if (!that.isVisible()) {
                    that.middleAngle = that.toAngle = that.fromAngle = that.fromAngle || angle
                }
            },
            _getMarkerVisibility: function() {
                return true
            },
            _updateMarker: function(animationEnabled, style) {
                var that = this;
                style = style || that._getStyle();
                if (!animationEnabled) {
                    style = _extend({
                        x: that.centerX,
                        y: that.centerY,
                        outerRadius: that.radiusOuter,
                        innerRadius: that.radiusInner,
                        startAngle: that.toAngle,
                        endAngle: that.fromAngle
                    }, style)
                }
                that.graphic.attr(style).sharp()
            },
            getLegendStyles: function() {
                return this._styles.legendStyles
            },
            isInVisibleArea: function() {
                return true
            },
            hide: function() {
                var that = this;
                if (that._visible) {
                    that._visible = false;
                    that.hideTooltip();
                    that._options.visibilityChanged(that)
                }
            },
            show: function() {
                var that = this;
                if (!that._visible) {
                    that._visible = true;
                    that._options.visibilityChanged(that)
                }
            },
            setInvisibility: function() {
                this._label.hide()
            },
            isVisible: function() {
                return this._visible
            },
            _getFormatObject: function(tooltip) {
                var formatObject = symbolPoint._getFormatObject.call(this, tooltip),
                    percent = this.percent;
                formatObject.percent = percent;
                formatObject.percentText = tooltip.formatValue(percent, "percent");
                return formatObject
            },
            getColor: function() {
                return this._styles.normal.fill
            },
            coordsIn: function(x, y) {
                var angle, that = this,
                    lx = x - that.centerX,
                    ly = y - that.centerY,
                    r = _sqrt(lx * lx + ly * ly),
                    fromAngle = that.fromAngle % 360,
                    toAngle = that.toAngle % 360;
                if (r < that.radiusInner || r > that.radiusOuter || 0 === r) {
                    return false
                }
                angle = _acos(lx / r) * DEG * (ly > 0 ? -1 : 1);
                if (angle < 0) {
                    angle += 360
                }
                if (fromAngle === toAngle && _abs(that.toAngle - that.fromAngle) > 1e-4) {
                    return true
                } else {
                    return fromAngle >= toAngle ? angle <= fromAngle && angle >= toAngle : !(angle >= fromAngle && angle <= toAngle)
                }
            }
        })
    },
    /*!*********************************************************!*\
      !*** ./Scripts/viz/series/points/range_symbol_point.js ***!
      \*********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            labelModule = __webpack_require__( /*! ./label */ 464),
            symbolPoint = __webpack_require__( /*! ./symbol_point */ 463),
            _extend = $.extend,
            _isDefined = commonUtils.isDefined,
            _math = Math,
            _abs = _math.abs,
            _min = _math.min,
            _max = _math.max,
            _round = _math.round,
            DEFAULT_IMAGE_WIDTH = 20,
            DEFAULT_IMAGE_HEIGHT = 20;
        module.exports = _extend({}, symbolPoint, {
            deleteLabel: function() {
                var that = this;
                that._topLabel.dispose();
                that._topLabel = null;
                that._bottomLabel.dispose();
                that._bottomLabel = null
            },
            hideMarker: function(type) {
                var graphic = this.graphic,
                    marker = graphic && graphic[type + "Marker"],
                    label = this["_" + type + "Label"];
                if (marker && "hidden" !== marker.attr("visibility")) {
                    marker.attr({
                        visibility: "hidden"
                    })
                }
                label.hide()
            },
            setInvisibility: function() {
                this.hideMarker("top");
                this.hideMarker("bottom")
            },
            clearVisibility: function() {
                var that = this,
                    graphic = that.graphic,
                    topMarker = graphic && graphic.topMarker,
                    bottomMarker = graphic && graphic.bottomMarker;
                if (topMarker && topMarker.attr("visibility")) {
                    topMarker.attr({
                        visibility: null
                    })
                }
                if (bottomMarker && bottomMarker.attr("visibility")) {
                    bottomMarker.attr({
                        visibility: null
                    })
                }
                that._topLabel.clearVisibility();
                that._bottomLabel.clearVisibility()
            },
            clearMarker: function() {
                var that = this,
                    graphic = that.graphic,
                    topMarker = graphic && graphic.topMarker,
                    bottomMarker = graphic && graphic.bottomMarker,
                    emptySettings = that._emptySettings;
                topMarker && topMarker.attr(emptySettings);
                bottomMarker && bottomMarker.attr(emptySettings)
            },
            _getLabelPosition: function(markerType) {
                var position, labelsInside = "inside" === this._options.label.position;
                if (!this._options.rotated) {
                    position = "top" === markerType ^ labelsInside ? "top" : "bottom"
                } else {
                    position = "top" === markerType ^ labelsInside ? "right" : "left"
                }
                return position
            },
            _getLabelMinFormatObject: function() {
                var that = this;
                return {
                    index: 0,
                    argument: that.initialArgument,
                    value: that.initialMinValue,
                    seriesName: that.series.name,
                    originalValue: that.originalMinValue,
                    originalArgument: that.originalArgument,
                    point: that
                }
            },
            _updateLabelData: function() {
                var maxFormatObject = this._getLabelFormatObject();
                maxFormatObject.index = 1;
                this._topLabel.setData(maxFormatObject);
                this._bottomLabel.setData(this._getLabelMinFormatObject())
            },
            _updateLabelOptions: function() {
                var that = this,
                    options = this._options.label;
                (!that._topLabel || !that._bottomLabel) && that._createLabel();
                that._topLabel.setOptions(options);
                that._bottomLabel.setOptions(options)
            },
            _createLabel: function() {
                var options = {
                    renderer: this.series._renderer,
                    labelsGroup: this.series._labelsGroup,
                    point: this
                };
                this._topLabel = new labelModule.Label(options);
                this._bottomLabel = new labelModule.Label(options)
            },
            _getGraphicBbox: function(location) {
                var bbox, options = this._options,
                    images = this._getImage(options.image),
                    image = "top" === location ? this._checkImage(images.top) : this._checkImage(images.bottom),
                    coord = this._getPositionFromLocation(location);
                if (options.visible) {
                    bbox = image ? this._getImageBbox(coord.x, coord.y) : this._getSymbolBbox(coord.x, coord.y, options.styles.normal.r)
                } else {
                    bbox = {
                        x: coord.x,
                        y: coord.y,
                        width: 0,
                        height: 0
                    }
                }
                return bbox
            },
            _getPositionFromLocation: function(location) {
                var x, y, isTop = "top" === location;
                if (!this._options.rotated) {
                    x = this.x;
                    y = isTop ? _min(this.y, this.minY) : _max(this.y, this.minY)
                } else {
                    x = isTop ? _max(this.x, this.minX) : _min(this.x, this.minX);
                    y = this.y
                }
                return {
                    x: x,
                    y: y
                }
            },
            _checkOverlay: function(bottomCoord, topCoord, topValue) {
                return bottomCoord < topCoord + topValue
            },
            _getOverlayCorrections: function(type, topCoords, bottomCoords) {
                var isVertical = "vertical" === type,
                    coordSelector = isVertical ? "y" : "x",
                    valueSelector = isVertical ? "height" : "width",
                    visibleArea = this.translators[coordSelector].getCanvasVisibleArea(),
                    minBound = visibleArea.min,
                    maxBound = visibleArea.max,
                    delta = _round((topCoords[coordSelector] + topCoords[valueSelector] - bottomCoords[coordSelector]) / 2),
                    coord1 = topCoords[coordSelector] - delta,
                    coord2 = bottomCoords[coordSelector] + delta;
                if (coord1 < minBound) {
                    delta = minBound - topCoords[coordSelector];
                    coord1 += delta;
                    coord2 += delta
                } else {
                    if (coord2 + bottomCoords[valueSelector] > maxBound) {
                        delta = -(bottomCoords[coordSelector] + bottomCoords[valueSelector] - maxBound);
                        coord1 += delta;
                        coord2 += delta
                    }
                }
                return {
                    coord1: coord1,
                    coord2: coord2
                }
            },
            _checkLabelsOverlay: function(topLocation) {
                var that = this,
                    topCoords = that._topLabel.getBoundingRect(),
                    bottomCoords = that._bottomLabel.getBoundingRect(),
                    corrections = {};
                if (!that._options.rotated) {
                    if ("top" === topLocation) {
                        if (this._checkOverlay(bottomCoords.y, topCoords.y, topCoords.height)) {
                            corrections = this._getOverlayCorrections("vertical", topCoords, bottomCoords);
                            that._topLabel.shift(topCoords.x, corrections.coord1);
                            that._bottomLabel.shift(bottomCoords.x, corrections.coord2)
                        }
                    } else {
                        if (this._checkOverlay(topCoords.y, bottomCoords.y, bottomCoords.height)) {
                            corrections = this._getOverlayCorrections("vertical", bottomCoords, topCoords);
                            that._topLabel.shift(topCoords.x, corrections.coord2);
                            that._bottomLabel.shift(bottomCoords.x, corrections.coord1)
                        }
                    }
                } else {
                    if ("top" === topLocation) {
                        if (this._checkOverlay(topCoords.x, bottomCoords.x, bottomCoords.width)) {
                            corrections = this._getOverlayCorrections("horizontal", bottomCoords, topCoords);
                            that._topLabel.shift(corrections.coord2, topCoords.y);
                            that._bottomLabel.shift(corrections.coord1, bottomCoords.y)
                        }
                    } else {
                        if (this._checkOverlay(bottomCoords.x, topCoords.x, topCoords.width)) {
                            corrections = this._getOverlayCorrections("horizontal", topCoords, bottomCoords);
                            that._topLabel.shift(corrections.coord1, topCoords.y);
                            that._bottomLabel.shift(corrections.coord2, bottomCoords.y)
                        }
                    }
                }
            },
            _drawLabel: function() {
                var that = this,
                    labels = [],
                    notInverted = that._options.rotated ? that.x >= that.minX : that.y < that.minY,
                    customVisibility = that._getCustomLabelVisibility(),
                    topLabel = that._topLabel,
                    bottomLabel = that._bottomLabel;
                topLabel.pointPosition = notInverted ? "top" : "bottom";
                bottomLabel.pointPosition = notInverted ? "bottom" : "top";
                if ((that.series.getLabelVisibility() || customVisibility) && that.hasValue()) {
                    false !== that.visibleTopMarker && labels.push(topLabel);
                    false !== that.visibleBottomMarker && labels.push(bottomLabel);
                    $.each(labels, function(_, label) {
                        label.show()
                    });
                    that._checkLabelsOverlay(that._topLabel.pointPosition)
                } else {
                    topLabel.hide();
                    bottomLabel.hide()
                }
            },
            _getImage: function(imageOption) {
                var image = {};
                if (_isDefined(imageOption)) {
                    if ("string" === typeof imageOption) {
                        image.top = image.bottom = imageOption
                    } else {
                        image.top = {
                            url: "string" === typeof imageOption.url ? imageOption.url : imageOption.url && imageOption.url.rangeMaxPoint,
                            width: "number" === typeof imageOption.width ? imageOption.width : imageOption.width && imageOption.width.rangeMaxPoint,
                            height: "number" === typeof imageOption.height ? imageOption.height : imageOption.height && imageOption.height.rangeMaxPoint
                        };
                        image.bottom = {
                            url: "string" === typeof imageOption.url ? imageOption.url : imageOption.url && imageOption.url.rangeMinPoint,
                            width: "number" === typeof imageOption.width ? imageOption.width : imageOption.width && imageOption.width.rangeMinPoint,
                            height: "number" === typeof imageOption.height ? imageOption.height : imageOption.height && imageOption.height.rangeMinPoint
                        }
                    }
                }
                return image
            },
            _checkSymbol: function(oldOptions, newOptions) {
                var that = this,
                    oldSymbol = oldOptions.symbol,
                    newSymbol = newOptions.symbol,
                    symbolChanged = "circle" === oldSymbol && "circle" !== newSymbol || "circle" !== oldSymbol && "circle" === newSymbol,
                    oldImages = that._getImage(oldOptions.image),
                    newImages = that._getImage(newOptions.image),
                    topImageChanged = that._checkImage(oldImages.top) !== that._checkImage(newImages.top),
                    bottomImageChanged = that._checkImage(oldImages.bottom) !== that._checkImage(newImages.bottom);
                return symbolChanged || topImageChanged || bottomImageChanged
            },
            _getSettingsForTwoMarkers: function(style) {
                var that = this,
                    options = that._options,
                    settings = {},
                    x = options.rotated ? _min(that.x, that.minX) : that.x,
                    y = options.rotated ? that.y : _min(that.y, that.minY),
                    radius = style.r,
                    points = that._populatePointShape(options.symbol, radius);
                settings.top = _extend({
                    translateX: x + that.width,
                    translateY: y,
                    r: radius
                }, style);
                settings.bottom = _extend({
                    translateX: x,
                    translateY: y + that.height,
                    r: radius
                }, style);
                if (points) {
                    settings.top.points = settings.bottom.points = points
                }
                return settings
            },
            _hasGraphic: function() {
                return this.graphic && this.graphic.topMarker && this.graphic.bottomMarker
            },
            _drawOneMarker: function(renderer, markerType, imageSettings, settings) {
                var that = this,
                    graphic = that.graphic;
                if (graphic[markerType]) {
                    that._updateOneMarker(markerType, settings)
                } else {
                    graphic[markerType] = that._createMarker(renderer, graphic, imageSettings, settings)
                }
            },
            _drawMarker: function(renderer, group, animationEnabled, firstDrawing, style) {
                var that = this,
                    settings = that._getSettingsForTwoMarkers(style || that._getStyle()),
                    image = that._getImage(that._options.image);
                if (that._checkImage(image.top)) {
                    settings.top = that._getImageSettings(settings.top, image.top)
                }
                if (that._checkImage(image.bottom)) {
                    settings.bottom = that._getImageSettings(settings.bottom, image.bottom)
                }
                that.graphic = that.graphic || renderer.g().append(group);
                that.visibleTopMarker && that._drawOneMarker(renderer, "topMarker", image.top, settings.top);
                that.visibleBottomMarker && that._drawOneMarker(renderer, "bottomMarker", image.bottom, settings.bottom)
            },
            _getSettingsForTracker: function(radius) {
                var that = this,
                    rotated = that._options.rotated;
                return {
                    translateX: rotated ? _min(that.x, that.minX) - radius : that.x - radius,
                    translateY: rotated ? that.y - radius : _min(that.y, that.minY) - radius,
                    width: that.width + 2 * radius,
                    height: that.height + 2 * radius
                }
            },
            isInVisibleArea: function() {
                var notVisibleByArg, notVisibleByVal, tmp, visibleArgArea, visibleValArea, that = this,
                    rotated = that._options.rotated,
                    argument = !rotated ? that.x : that.y,
                    maxValue = !rotated ? _max(that.minY, that.y) : _max(that.minX, that.x),
                    minValue = !rotated ? _min(that.minY, that.y) : _min(that.minX, that.x),
                    translators = that.translators,
                    visibleTopMarker = true,
                    visibleBottomMarker = true,
                    visibleRangeArea = true;
                if (translators) {
                    visibleArgArea = translators[!rotated ? "x" : "y"].getCanvasVisibleArea();
                    visibleValArea = translators[!rotated ? "y" : "x"].getCanvasVisibleArea();
                    notVisibleByArg = visibleArgArea.max < argument || visibleArgArea.min > argument;
                    notVisibleByVal = visibleValArea.min > minValue && visibleValArea.min > maxValue || visibleValArea.max < minValue && visibleValArea.max < maxValue;
                    if (notVisibleByArg || notVisibleByVal) {
                        visibleTopMarker = visibleBottomMarker = visibleRangeArea = false
                    } else {
                        visibleTopMarker = visibleValArea.min <= minValue && visibleValArea.max > minValue;
                        visibleBottomMarker = visibleValArea.min < maxValue && visibleValArea.max >= maxValue;
                        if (rotated) {
                            tmp = visibleTopMarker;
                            visibleTopMarker = visibleBottomMarker;
                            visibleBottomMarker = tmp
                        }
                    }
                }
                that.visibleTopMarker = visibleTopMarker;
                that.visibleBottomMarker = visibleBottomMarker;
                return visibleRangeArea
            },
            getTooltipParams: function() {
                var x, y, min, max, minValue, that = this,
                    translators = that.translators,
                    visibleAreaX = translators.x.getCanvasVisibleArea(),
                    visibleAreaY = translators.y.getCanvasVisibleArea();
                if (!that._options.rotated) {
                    minValue = _min(that.y, that.minY);
                    x = that.x;
                    min = visibleAreaY.min > minValue ? visibleAreaY.min : minValue;
                    max = visibleAreaY.max < minValue + that.height ? visibleAreaY.max : minValue + that.height;
                    y = min + (max - min) / 2
                } else {
                    minValue = _min(that.x, that.minX);
                    y = that.y;
                    min = visibleAreaX.min > minValue ? visibleAreaX.min : minValue;
                    max = visibleAreaX.max < minValue + that.width ? visibleAreaX.max : minValue + that.width;
                    x = min + (max - min) / 2
                }
                return {
                    x: x,
                    y: y,
                    offset: 0
                }
            },
            _translate: function(translators) {
                var that = this,
                    rotated = that._options.rotated;
                that.minX = that.minY = translators.y.translate(that.minValue);
                symbolPoint._translate.call(that, translators);
                that.height = rotated ? 0 : _abs(that.minY - that.y);
                that.width = rotated ? _abs(that.x - that.minX) : 0
            },
            _updateData: function(data) {
                var that = this;
                symbolPoint._updateData.call(that, data);
                that.minValue = that.initialMinValue = that.originalMinValue = data.minValue
            },
            _getImageSettings: function(settings, image) {
                return {
                    href: image.url || image.toString(),
                    width: image.width || DEFAULT_IMAGE_WIDTH,
                    height: image.height || DEFAULT_IMAGE_HEIGHT,
                    translateX: settings.translateX,
                    translateY: settings.translateY
                }
            },
            getCrosshairData: function(x, y) {
                var that = this,
                    rotated = that._options.rotated,
                    minX = that.minX,
                    minY = that.minY,
                    vx = that.vx,
                    vy = that.vy,
                    value = that.value,
                    minValue = that.minValue,
                    argument = that.argument,
                    coords = {
                        axis: that.series.axis,
                        x: vx,
                        y: vy,
                        yValue: value,
                        xValue: argument
                    };
                if (rotated) {
                    coords.yValue = argument;
                    if (_abs(vx - x) < _abs(minX - x)) {
                        coords.xValue = value
                    } else {
                        coords.x = minX;
                        coords.xValue = minValue
                    }
                } else {
                    if (_abs(vy - y) >= _abs(minY - y)) {
                        coords.y = minY;
                        coords.yValue = minValue
                    }
                }
                return coords
            },
            _updateOneMarker: function(markerType, settings) {
                this.graphic && this.graphic[markerType] && this.graphic[markerType].attr(settings)
            },
            _updateMarker: function(animationEnabled, style) {
                this._drawMarker(void 0, void 0, false, false, style)
            },
            _getFormatObject: function(tooltip) {
                var that = this,
                    initialMinValue = that.initialMinValue,
                    initialValue = that.initialValue,
                    initialArgument = that.initialArgument,
                    minValue = tooltip.formatValue(initialMinValue),
                    value = tooltip.formatValue(initialValue);
                return {
                    argument: initialArgument,
                    argumentText: tooltip.formatValue(initialArgument, "argument"),
                    valueText: minValue + " - " + value,
                    rangeValue1Text: minValue,
                    rangeValue2Text: value,
                    rangeValue1: initialMinValue,
                    rangeValue2: initialValue,
                    seriesName: that.series.name,
                    point: that,
                    originalMinValue: that.originalMinValue,
                    originalValue: that.originalValue,
                    originalArgument: that.originalArgument
                }
            },
            getLabel: function() {
                return [this._topLabel, this._bottomLabel]
            },
            getBoundingRect: $.noop,
            coordsIn: function(x, y) {
                var trackerRadius = this._storeTrackerR(),
                    xCond = x >= this.x - trackerRadius && x <= this.x + trackerRadius,
                    yCond = y >= this.y - trackerRadius && y <= this.y + trackerRadius;
                if (this._options.rotated) {
                    return yCond && (xCond || x >= this.minX - trackerRadius && x <= this.minX + trackerRadius)
                } else {
                    return xCond && (yCond || y >= this.minY - trackerRadius && y <= this.minY + trackerRadius)
                }
            }
        })
    },
    /*!******************************************************!*\
      !*** ./Scripts/viz/series/points/range_bar_point.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            barPoint = __webpack_require__( /*! ./bar_point */ 466),
            rangeSymbolPointMethods = __webpack_require__( /*! ./range_symbol_point */ 469),
            _extend = $.extend;
        module.exports = _extend({}, barPoint, {
            deleteLabel: rangeSymbolPointMethods.deleteLabel,
            _getFormatObject: rangeSymbolPointMethods._getFormatObject,
            clearVisibility: function() {
                var graphic = this.graphic;
                if (graphic && graphic.attr("visibility")) {
                    graphic.attr({
                        visibility: null
                    })
                }
                this._topLabel.clearVisibility();
                this._bottomLabel.clearVisibility()
            },
            setInvisibility: function() {
                var graphic = this.graphic;
                if (graphic && "hidden" !== graphic.attr("visibility")) {
                    graphic.attr({
                        visibility: "hidden"
                    })
                }
                this._topLabel.hide();
                this._bottomLabel.hide()
            },
            getTooltipParams: function(location) {
                var x, y, that = this,
                    edgeLocation = "edge" === location;
                if (that._options.rotated) {
                    x = edgeLocation ? that.x + that.width : that.x + that.width / 2;
                    y = that.y + that.height / 2
                } else {
                    x = that.x + that.width / 2;
                    y = edgeLocation ? that.y : that.y + that.height / 2
                }
                return {
                    x: x,
                    y: y,
                    offset: 0
                }
            },
            _translate: function(translator) {
                var that = this,
                    barMethods = barPoint;
                barMethods._translate.call(that, translator);
                if (that._options.rotated) {
                    that.width = that.width || 1
                } else {
                    that.height = that.height || 1
                }
            },
            _updateData: rangeSymbolPointMethods._updateData,
            _getLabelPosition: rangeSymbolPointMethods._getLabelPosition,
            _getLabelMinFormatObject: rangeSymbolPointMethods._getLabelMinFormatObject,
            _updateLabelData: rangeSymbolPointMethods._updateLabelData,
            _updateLabelOptions: rangeSymbolPointMethods._updateLabelOptions,
            getCrosshairData: rangeSymbolPointMethods.getCrosshairData,
            _createLabel: rangeSymbolPointMethods._createLabel,
            _checkOverlay: rangeSymbolPointMethods._checkOverlay,
            _checkLabelsOverlay: rangeSymbolPointMethods._checkLabelsOverlay,
            _getOverlayCorrections: rangeSymbolPointMethods._getOverlayCorrections,
            _drawLabel: rangeSymbolPointMethods._drawLabel,
            _getLabelCoords: rangeSymbolPointMethods._getLabelCoords,
            _getGraphicBbox: function(location) {
                var isTop = "top" === location,
                    bbox = barPoint._getGraphicBbox.call(this);
                if (!this._options.rotated) {
                    bbox.y = isTop ? bbox.y : bbox.y + bbox.height;
                    bbox.height = 0
                } else {
                    bbox.x = isTop ? bbox.x + bbox.width : bbox.x;
                    bbox.width = 0
                }
                return bbox
            },
            getLabel: rangeSymbolPointMethods.getLabel,
            getBoundingRect: $.noop
        })
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/series/points/candlestick_point.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            symbolPoint = __webpack_require__( /*! ./symbol_point */ 463),
            barPoint = __webpack_require__( /*! ./bar_point */ 466),
            _isNumeric = $.isNumeric,
            _extend = $.extend,
            _math = Math,
            _abs = _math.abs,
            _min = _math.min,
            _max = _math.max,
            _round = _math.round,
            DEFAULT_FINANCIAL_TRACKER_MARGIN = 2;
        module.exports = _extend({}, barPoint, {
            _getContinuousPoints: function(minValueName, maxValueName) {
                var points, that = this,
                    x = that.x,
                    createPoint = that._options.rotated ? function(x, y) {
                        return [y, x]
                    } : function(x, y) {
                        return [x, y]
                    },
                    width = that.width,
                    min = that[minValueName],
                    max = that[maxValueName];
                if (min === max) {
                    points = [].concat(createPoint(x, that.highY)).concat(createPoint(x, that.lowY)).concat(createPoint(x, that.closeY)).concat(createPoint(x - width / 2, that.closeY)).concat(createPoint(x + width / 2, that.closeY)).concat(createPoint(x, that.closeY))
                } else {
                    points = [].concat(createPoint(x, that.highY)).concat(createPoint(x, max)).concat(createPoint(x + width / 2, max)).concat(createPoint(x + width / 2, min)).concat(createPoint(x, min)).concat(createPoint(x, that.lowY)).concat(createPoint(x, min)).concat(createPoint(x - width / 2, min)).concat(createPoint(x - width / 2, max)).concat(createPoint(x, max))
                }
                return points
            },
            _getCategoryPoints: function(y) {
                var that = this,
                    x = that.x,
                    createPoint = that._options.rotated ? function(x, y) {
                        return [y, x]
                    } : function(x, y) {
                        return [x, y]
                    };
                return [].concat(createPoint(x, that.highY)).concat(createPoint(x, that.lowY)).concat(createPoint(x, y)).concat(createPoint(x - that.width / 2, y)).concat(createPoint(x + that.width / 2, y)).concat(createPoint(x, y))
            },
            _getPoints: function() {
                var points, minValueName, maxValueName, that = this,
                    openValue = that.openValue,
                    closeValue = that.closeValue;
                if (_isNumeric(openValue) && _isNumeric(closeValue)) {
                    minValueName = openValue > closeValue ? "closeY" : "openY";
                    maxValueName = openValue > closeValue ? "openY" : "closeY";
                    points = that._getContinuousPoints(minValueName, maxValueName)
                } else {
                    if (openValue === closeValue) {
                        points = [that.x, that.highY, that.x, that.lowY]
                    } else {
                        points = that._getCategoryPoints(_isNumeric(openValue) ? that.openY : that.closeY)
                    }
                }
                return points
            },
            getColor: function() {
                var that = this;
                return that._isReduction ? that._options.reduction.color : that._styles.normal.stroke || that.series.getColor()
            },
            _drawMarkerInGroup: function(group, attributes, renderer) {
                var that = this;
                that.graphic = renderer.path(that._getPoints(), "area").attr({
                    "stroke-linecap": "square"
                }).attr(attributes).data({
                    "chart-data-point": that
                }).sharp().append(group)
            },
            _fillStyle: function() {
                var that = this,
                    styles = that._options.styles;
                if (that._isReduction && that._isPositive) {
                    that._styles = styles.reductionPositive
                } else {
                    if (that._isReduction) {
                        that._styles = styles.reduction
                    } else {
                        if (that._isPositive) {
                            that._styles = styles.positive
                        } else {
                            that._styles = styles
                        }
                    }
                }
            },
            _getMinTrackerWidth: function() {
                return 2 + 2 * this._styles.normal["stroke-width"]
            },
            correctCoordinates: function(correctOptions) {
                var minWidth = this._getMinTrackerWidth(),
                    maxWidth = 10,
                    width = correctOptions.width;
                width = width < minWidth ? minWidth : width > maxWidth ? maxWidth : width;
                this.width = width + width % 2;
                this.xCorrection = correctOptions.offset
            },
            _getMarkerGroup: function(group) {
                var markerGroup, that = this;
                if (that._isReduction && that._isPositive) {
                    markerGroup = group.reductionPositiveMarkersGroup
                } else {
                    if (that._isReduction) {
                        markerGroup = group.reductionMarkersGroup
                    } else {
                        if (that._isPositive) {
                            markerGroup = group.defaultPositiveMarkersGroup
                        } else {
                            markerGroup = group.defaultMarkersGroup
                        }
                    }
                }
                return markerGroup
            },
            _drawMarker: function(renderer, group) {
                this._drawMarkerInGroup(this._getMarkerGroup(group), this._getStyle(), renderer)
            },
            _getSettingsForTracker: function() {
                var x, y, width, height, that = this,
                    highY = that.highY,
                    lowY = that.lowY,
                    rotated = that._options.rotated;
                if (highY === lowY) {
                    highY = rotated ? highY + DEFAULT_FINANCIAL_TRACKER_MARGIN : highY - DEFAULT_FINANCIAL_TRACKER_MARGIN;
                    lowY = rotated ? lowY - DEFAULT_FINANCIAL_TRACKER_MARGIN : lowY + DEFAULT_FINANCIAL_TRACKER_MARGIN
                }
                if (rotated) {
                    x = _min(lowY, highY);
                    y = that.x - that.width / 2;
                    width = _abs(lowY - highY);
                    height = that.width
                } else {
                    x = that.x - that.width / 2;
                    y = _min(lowY, highY);
                    width = that.width;
                    height = _abs(lowY - highY)
                }
                return {
                    x: x,
                    y: y,
                    width: width,
                    height: height
                }
            },
            _getGraphicBbox: function() {
                var that = this,
                    rotated = that._options.rotated,
                    x = that.x,
                    width = that.width,
                    lowY = that.lowY,
                    highY = that.highY;
                return {
                    x: !rotated ? x - _round(width / 2) : lowY,
                    y: !rotated ? highY : x - _round(width / 2),
                    width: !rotated ? width : highY - lowY,
                    height: !rotated ? lowY - highY : width
                }
            },
            getTooltipParams: function(location) {
                var that = this;
                if (that.graphic) {
                    var x, y, min, max, minValue = _min(that.lowY, that.highY),
                        maxValue = _max(that.lowY, that.highY),
                        visibleAreaX = that.translators.x.getCanvasVisibleArea(),
                        visibleAreaY = that.translators.y.getCanvasVisibleArea(),
                        edgeLocation = "edge" === location;
                    if (!that._options.rotated) {
                        min = _max(visibleAreaY.min, minValue);
                        max = _min(visibleAreaY.max, maxValue);
                        x = that.x;
                        y = edgeLocation ? min : min + (max - min) / 2
                    } else {
                        min = _max(visibleAreaX.min, minValue);
                        max = _min(visibleAreaX.max, maxValue);
                        y = that.x;
                        x = edgeLocation ? max : min + (max - min) / 2
                    }
                    return {
                        x: x,
                        y: y,
                        offset: 0
                    }
                }
            },
            hasValue: function() {
                return null !== this.highValue && null !== this.lowValue
            },
            _translate: function() {
                var centerValue, height, that = this,
                    rotated = that._options.rotated,
                    translators = that.translators,
                    argTranslator = rotated ? translators.y : translators.x,
                    valTranslator = rotated ? translators.x : translators.y;
                that.vx = that.vy = that.x = argTranslator.translate(that.argument) + (that.xCorrection || 0);
                that.openY = null !== that.openValue ? valTranslator.translate(that.openValue) : null;
                that.highY = valTranslator.translate(that.highValue);
                that.lowY = valTranslator.translate(that.lowValue);
                that.closeY = null !== that.closeValue ? valTranslator.translate(that.closeValue) : null;
                height = _abs(that.lowY - that.highY);
                centerValue = _min(that.lowY, that.highY) + _abs(that.lowY - that.highY) / 2;
                that._calculateVisibility(!rotated ? that.x : centerValue, !rotated ? centerValue : that.x)
            },
            getCrosshairData: function(x, y) {
                var yValue, coords, that = this,
                    rotated = that._options.rotated,
                    origY = rotated ? x : y,
                    argument = that.argument,
                    coord = "low";
                if (_abs(that.lowY - origY) < _abs(that.closeY - origY)) {
                    yValue = that.lowY
                } else {
                    yValue = that.closeY;
                    coord = "close"
                }
                if (_abs(yValue - origY) >= _abs(that.openY - origY)) {
                    yValue = that.openY;
                    coord = "open"
                }
                if (_abs(yValue - origY) >= _abs(that.highY - origY)) {
                    yValue = that.highY;
                    coord = "high"
                }
                if (rotated) {
                    coords = {
                        y: that.vy,
                        x: yValue,
                        xValue: that[coord + "Value"],
                        yValue: argument
                    }
                } else {
                    coords = {
                        x: that.vx,
                        y: yValue,
                        xValue: argument,
                        yValue: that[coord + "Value"]
                    }
                }
                coords.axis = that.series.axis;
                return coords
            },
            _updateData: function(data) {
                var that = this,
                    label = that._label,
                    reductionColor = this._options.reduction.color;
                that.value = that.initialValue = data.reductionValue;
                that.originalValue = data.value;
                that.lowValue = that.originalLowValue = data.lowValue;
                that.highValue = that.originalHighValue = data.highValue;
                that.openValue = that.originalOpenValue = data.openValue;
                that.closeValue = that.originalCloseValue = data.closeValue;
                that._isPositive = data.openValue < data.closeValue;
                that._isReduction = data.isReduction;
                if (that._isReduction) {
                    label.setColor(reductionColor)
                }
            },
            _updateMarker: function(animationEnabled, style, group) {
                var that = this,
                    graphic = that.graphic;
                graphic.attr({
                    points: that._getPoints()
                }).attr(style || that._getStyle()).sharp();
                group && graphic.append(that._getMarkerGroup(group))
            },
            _getLabelFormatObject: function() {
                var that = this;
                return {
                    openValue: that.openValue,
                    highValue: that.highValue,
                    lowValue: that.lowValue,
                    closeValue: that.closeValue,
                    reductionValue: that.initialValue,
                    argument: that.initialArgument,
                    value: that.initialValue,
                    seriesName: that.series.name,
                    originalOpenValue: that.originalOpenValue,
                    originalCloseValue: that.originalCloseValue,
                    originalLowValue: that.originalLowValue,
                    originalHighValue: that.originalHighValue,
                    originalArgument: that.originalArgument,
                    point: that
                }
            },
            _getFormatObject: function(tooltip) {
                var that = this,
                    highValue = tooltip.formatValue(that.highValue),
                    openValue = tooltip.formatValue(that.openValue),
                    closeValue = tooltip.formatValue(that.closeValue),
                    lowValue = tooltip.formatValue(that.lowValue),
                    symbolMethods = symbolPoint,
                    formatObject = symbolMethods._getFormatObject.call(that, tooltip);
                return _extend({}, formatObject, {
                    valueText: "h: " + highValue + ("" !== openValue ? " o: " + openValue : "") + ("" !== closeValue ? " c: " + closeValue : "") + " l: " + lowValue,
                    highValueText: highValue,
                    openValueText: openValue,
                    closeValueText: closeValue,
                    lowValueText: lowValue
                })
            }
        })
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/series/points/stock_point.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            candlestickPoint = __webpack_require__( /*! ./candlestick_point */ 471),
            _extend = $.extend,
            _isNumeric = $.isNumeric;
        module.exports = _extend({}, candlestickPoint, {
            _getPoints: function() {
                var points, that = this,
                    createPoint = that._options.rotated ? function(x, y) {
                        return [y, x]
                    } : function(x, y) {
                        return [x, y]
                    },
                    openYExist = _isNumeric(that.openY),
                    closeYExist = _isNumeric(that.closeY),
                    x = that.x,
                    width = that.width;
                points = [].concat(createPoint(x, that.highY));
                openYExist && (points = points.concat(createPoint(x, that.openY)));
                openYExist && (points = points.concat(createPoint(x - width / 2, that.openY)));
                openYExist && (points = points.concat(createPoint(x, that.openY)));
                closeYExist && (points = points.concat(createPoint(x, that.closeY)));
                closeYExist && (points = points.concat(createPoint(x + width / 2, that.closeY)));
                closeYExist && (points = points.concat(createPoint(x, that.closeY)));
                points = points.concat(createPoint(x, that.lowY));
                return points
            },
            _drawMarkerInGroup: function(group, attributes, renderer) {
                this.graphic = renderer.path(this._getPoints(), "line").attr({
                    "stroke-linecap": "square"
                }).attr(attributes).data({
                    "chart-data-point": this
                }).sharp().append(group)
            },
            _getMinTrackerWidth: function() {
                var width = 2 + this._styles.normal["stroke-width"];
                return width + width % 2
            }
        })
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/series/points/polar_point.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _extend = $.extend,
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            symbolPoint = __webpack_require__( /*! ./symbol_point */ 463),
            barPoint = __webpack_require__( /*! ./bar_point */ 466),
            piePoint = __webpack_require__( /*! ./pie_point */ 468),
            isDefined = commonUtils.isDefined,
            vizUtils = __webpack_require__( /*! ../../core/utils */ 442),
            normalizeAngle = vizUtils.normalizeAngle,
            _math = Math,
            _max = _math.max,
            ERROR_BARS_ANGLE_OFFSET = 90,
            CANVAS_POSITION_START = "canvas_position_start",
            CANVAS_POSITION_TOP = "canvas_position_top",
            CANVAS_POSITION_END = "canvas_position_end",
            CANVAS_POSITION_DEFAULT = "canvas_position_default";
        exports.polarSymbolPoint = _extend({}, symbolPoint, {
            _getLabelCoords: piePoint._getLabelCoords,
            _moveLabelOnCanvas: barPoint._moveLabelOnCanvas,
            _getLabelPosition: function() {
                return "outside"
            },
            _translate: function(translator) {
                var that = this,
                    coord = translator.translate(that.argument, that.value),
                    center = translator.translate(CANVAS_POSITION_START, CANVAS_POSITION_TOP);
                that.vx = normalizeAngle(coord.angle);
                that.vy = that.radiusOuter = that.radiusLabels = coord.radius;
                that.radius = coord.radius;
                that.middleAngle = -coord.angle;
                that.angle = -coord.angle;
                that.x = coord.x;
                that.y = coord.y;
                that.defaultX = that.centerX = center.x;
                that.defaultY = that.centerY = center.y;
                that._translateErrorBars(translator);
                that.inVisibleArea = true
            },
            _translateErrorBars: function(translator) {
                var that = this,
                    errorBars = that._options.errorBars;
                if (!errorBars) {
                    return
                }
                isDefined(that.lowError) && (that._lowErrorCoord = that.centerY - translator.translate(that.argument, that.lowError).radius);
                isDefined(that.highError) && (that._highErrorCoord = that.centerY - translator.translate(that.argument, that.highError).radius);
                that._errorBarPos = that.centerX;
                that._baseErrorBarPos = "stdDeviation" === errorBars.type ? that._lowErrorCoord + (that._highErrorCoord - that._lowErrorCoord) / 2 : that.centerY - that.radius
            },
            _getTranslates: function(animationEnabled) {
                return animationEnabled ? this.getDefaultCoords() : {
                    x: this.x,
                    y: this.y
                }
            },
            getDefaultCoords: function() {
                var cossin = vizUtils.getCosAndSin(-this.angle),
                    radius = this.translators.translate(CANVAS_POSITION_START, CANVAS_POSITION_DEFAULT).radius,
                    x = this.defaultX + radius * cossin.cos,
                    y = this.defaultY + radius * cossin.sin;
                return {
                    x: x,
                    y: y
                }
            },
            _addLabelAlignmentAndOffset: function(label, coord) {
                return coord
            },
            _checkLabelPosition: function(label, coord) {
                var that = this,
                    visibleArea = that._getVisibleArea(),
                    graphicBbox = that._getGraphicBbox();
                if (that._isPointInVisibleArea(visibleArea, graphicBbox)) {
                    coord = that._moveLabelOnCanvas(coord, visibleArea, label.getBoundingRect())
                }
                return coord
            },
            _getErrorBarSettings: function(errorBarOptions, animationEnabled) {
                var settings = symbolPoint._getErrorBarSettings.call(this, errorBarOptions, animationEnabled);
                settings.rotate = ERROR_BARS_ANGLE_OFFSET - this.angle;
                settings.rotateX = this.centerX;
                settings.rotateY = this.centerY;
                return settings
            },
            getCoords: function(min) {
                return min ? this.getDefaultCoords() : {
                    x: this.x,
                    y: this.y
                }
            }
        });
        exports.polarBarPoint = _extend({}, barPoint, {
            _translateErrorBars: exports.polarSymbolPoint._translateErrorBars,
            _getErrorBarSettings: exports.polarSymbolPoint._getErrorBarSettings,
            _moveLabelOnCanvas: barPoint._moveLabelOnCanvas,
            _getLabelCoords: piePoint._getLabelCoords,
            _getLabelConnector: piePoint._getLabelConnector,
            getBoundaryCoords: piePoint.getBoundaryCoords,
            getTooltipParams: piePoint.getTooltipParams,
            _getLabelPosition: piePoint._getLabelPosition,
            _translate: function(translator) {
                var that = this,
                    maxRadius = translator.translate(CANVAS_POSITION_TOP, CANVAS_POSITION_END).radius;
                that.radiusInner = translator.translate(that.argument, that.minValue).radius;
                exports.polarSymbolPoint._translate.call(that, translator);
                if (null === that.radiusInner) {
                    that.radiusInner = that.radius = maxRadius
                } else {
                    if (null === that.radius) {
                        this.radius = this.value >= 0 ? maxRadius : 0
                    }
                }
                that.radiusOuter = that.radiusLabels = _max(that.radiusInner, that.radius);
                that.radiusInner = that.defaultRadius = _math.min(that.radiusInner, that.radius);
                that.middleAngle = that.angle = -normalizeAngle(that.middleAngleCorrection - that.angle)
            },
            _checkVisibility: function(translator) {
                return translator.checkVisibility(this.radius, this.radiusInner)
            },
            getMarkerCoords: function() {
                return {
                    x: this.centerX,
                    y: this.centerY,
                    outerRadius: this.radiusOuter,
                    innerRadius: this.defaultRadius,
                    startAngle: this.middleAngle - this.interval / 2,
                    endAngle: this.middleAngle + this.interval / 2
                }
            },
            _drawMarker: function(renderer, group, animationEnabled) {
                var that = this,
                    styles = that._getStyle(),
                    coords = that.getMarkerCoords(),
                    innerRadius = coords.innerRadius,
                    outerRadius = coords.outerRadius,
                    start = that.translators.translate(that.argument, CANVAS_POSITION_DEFAULT),
                    x = coords.x,
                    y = coords.y;
                if (animationEnabled) {
                    innerRadius = 0;
                    outerRadius = 0;
                    x = start.x;
                    y = start.y
                }
                that.graphic = renderer.arc(x, y, innerRadius, outerRadius, coords.startAngle, coords.endAngle).attr(styles).data({
                    "chart-data-point": that
                }).append(group)
            },
            _checkLabelPosition: function(label, coord) {
                var that = this,
                    visibleArea = that._getVisibleArea(),
                    angleFunctions = vizUtils.getCosAndSin(that.middleAngle),
                    x = that.centerX + that.defaultRadius * angleFunctions.cos,
                    y = that.centerY - that.defaultRadius * angleFunctions.sin;
                if (x > visibleArea.minX && x < visibleArea.maxX && y > visibleArea.minY && y < visibleArea.maxY) {
                    coord = that._moveLabelOnCanvas(coord, visibleArea, label.getBoundingRect())
                }
                return coord
            },
            _addLabelAlignmentAndOffset: function(label, coord) {
                return coord
            },
            correctCoordinates: function(correctOptions) {
                this.middleAngleCorrection = correctOptions.offset;
                this.interval = correctOptions.width
            },
            coordsIn: function(x, y) {
                var val = this.translators.untranslate(x, y),
                    coords = this.getMarkerCoords(),
                    isBetweenAngles = coords.startAngle < coords.endAngle ? -val.phi >= coords.startAngle && -val.phi <= coords.endAngle : -val.phi <= coords.startAngle && -val.phi >= coords.endAngle;
                return val.r >= coords.innerRadius && val.r <= coords.outerRadius && isBetweenAngles
            }
        })
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/series/scatter_series.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            rangeCalculator = __webpack_require__( /*! ./helpers/range_data_calculator */ 475),
            _each = $.each,
            _extend = $.extend,
            _noop = $.noop,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _isString = commonUtils.isString,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _map = vizUtils.map,
            _normalizeEnum = vizUtils.normalizeEnum,
            math = Math,
            _floor = math.floor,
            _abs = math.abs,
            _sqrt = math.sqrt,
            _min = math.min,
            _max = math.max,
            DEFAULT_SYMBOL_POINT_SIZE = 2,
            DEFAULT_TRACKER_WIDTH = 12,
            DEFAULT_DURATION = 400,
            HIGH_ERROR = "highError",
            LOW_ERROR = "lowError",
            ORIGINAL = "original",
            VARIANCE = "variance",
            STANDARD_DEVIATION = "stddeviation",
            STANDARD_ERROR = "stderror",
            PERCENT = "percent",
            FIXED = "fixed",
            UNDEFINED = "undefined",
            DISCRETE = "discrete",
            LOGARITHMIC = "logarithmic",
            DATETIME = "datetime";
        exports.chart = {};
        exports.polar = {};

        function sum(array) {
            var result = 0;
            _each(array, function(_, value) {
                result += value
            });
            return result
        }

        function isErrorBarTypeCorrect(type) {
            return $.inArray(type, [FIXED, PERCENT, VARIANCE, STANDARD_DEVIATION, STANDARD_ERROR]) !== -1
        }

        function variance(array, expectedValue) {
            return sum(_map(array, function(value) {
                return (value - expectedValue) * (value - expectedValue)
            })) / array.length
        }
        var baseScatterMethods = {
            _defaultDuration: DEFAULT_DURATION,
            _defaultTrackerWidth: DEFAULT_TRACKER_WIDTH,
            _applyStyle: _noop,
            _updateOptions: _noop,
            _parseStyle: _noop,
            _prepareSegment: _noop,
            _drawSegment: _noop,
            _generateDefaultSegments: _noop,
            _prepareSeriesToDrawing: function() {
                var that = this;
                that._deleteOldAnimationMethods();
                that._disposePoints(that._oldPoints);
                that._oldPoints = null
            },
            _appendInGroup: function() {
                this._group.append(this._extGroups.seriesGroup)
            },
            _createLegendState: function(styleOptions, defaultColor) {
                return {
                    fill: styleOptions.color || defaultColor,
                    hatching: styleOptions.hatching
                }
            },
            updateTemplateFieldNames: function() {
                var that = this,
                    options = that._options;
                options.valueField = that.getValueFields()[0] + that.name;
                options.tagField = that.getTagField() + that.name
            },
            _applyElementsClipRect: function(settings) {
                settings.clipId = this._paneClipRectID
            },
            _applyMarkerClipRect: function(settings) {
                settings.clipId = this._forceClipping ? this._paneClipRectID : null
            },
            _createGroup: function(groupName, parent, target, settings) {
                var group = parent[groupName] = parent[groupName] || this._renderer.g();
                target && group.append(target);
                settings && group.attr(settings)
            },
            _applyClearingSettings: function(settings) {
                settings.opacity = null;
                settings.scale = null;
                if (this._options.rotated) {
                    settings.translateX = null
                } else {
                    settings.translateY = null
                }
            },
            _createGroups: function() {
                var that = this;
                that._createGroup("_markersGroup", that, that._group);
                that._createGroup("_labelsGroup", that)
            },
            _setMarkerGroupSettings: function() {
                var that = this,
                    settings = that._createPointStyles(that._getMarkerGroupOptions()).normal;
                settings.class = "dxc-markers";
                settings.opacity = 1;
                that._applyMarkerClipRect(settings);
                that._markersGroup.attr(settings)
            },
            _applyVisibleArea: function() {
                var that = this,
                    visibleX = that.translators.x.getCanvasVisibleArea(),
                    visibleY = that.translators.y.getCanvasVisibleArea();
                that._visibleArea = {
                    minX: visibleX.min,
                    maxX: visibleX.max,
                    minY: visibleY.min,
                    maxY: visibleY.max
                }
            },
            areErrorBarsVisible: function() {
                var errorBarOptions = this._options.valueErrorBar;
                return errorBarOptions && this._errorBarsEnabled() && "none" !== errorBarOptions.displayMode && (isErrorBarTypeCorrect(_normalizeEnum(errorBarOptions.type)) || _isDefined(errorBarOptions.lowValueField) || _isDefined(errorBarOptions.highValueField))
            },
            _createErrorBarGroup: function(animationEnabled) {
                var settings, that = this,
                    errorBarOptions = that._options.valueErrorBar;
                if (that.areErrorBarsVisible()) {
                    settings = {
                        "class": "dxc-error-bars",
                        stroke: errorBarOptions.color,
                        "stroke-width": errorBarOptions.lineWidth,
                        opacity: animationEnabled ? .001 : errorBarOptions.opacity || 1,
                        "stroke-linecap": "square",
                        sharp: true,
                        clipId: that._forceClipping ? that._paneClipRectID : that._widePaneClipRectID
                    };
                    that._createGroup("_errorBarGroup", that, that._group, settings)
                }
            },
            _setGroupsSettings: function(animationEnabled) {
                var that = this;
                that._setMarkerGroupSettings();
                that._setLabelGroupSettings(animationEnabled);
                that._createErrorBarGroup(animationEnabled)
            },
            _getCreatingPointOptions: function() {
                var defaultPointOptions, normalStyle, that = this,
                    creatingPointOptions = that._predefinedPointOptions;
                if (!creatingPointOptions) {
                    defaultPointOptions = that._getPointOptions();
                    that._predefinedPointOptions = creatingPointOptions = _extend(true, {
                        styles: {}
                    }, defaultPointOptions);
                    normalStyle = defaultPointOptions.styles && defaultPointOptions.styles.normal || {};
                    creatingPointOptions.styles = creatingPointOptions.styles || {};
                    creatingPointOptions.styles.normal = {
                        "stroke-width": normalStyle["stroke-width"],
                        r: normalStyle.r,
                        opacity: normalStyle.opacity
                    }
                }
                return creatingPointOptions
            },
            _getSpecialColor: function(mainSeriesColor) {
                return mainSeriesColor
            },
            _getPointOptions: function() {
                return this._parsePointOptions(this._preparePointOptions(), this._options.label)
            },
            _getOptionsForPoint: function() {
                return this._options.point
            },
            _parsePointStyle: function(style, defaultColor, defaultBorderColor) {
                var border = style.border || {};
                return {
                    fill: style.color || defaultColor,
                    stroke: border.color || defaultBorderColor,
                    "stroke-width": border.visible ? border.width : 0,
                    r: style.size / 2 + (border.visible && 0 !== style.size ? ~~(border.width / 2) || 0 : 0)
                }
            },
            _createPointStyles: function(pointOptions) {
                var that = this,
                    mainPointColor = pointOptions.color || that._options.mainSeriesColor,
                    containerColor = that._options.containerBackgroundColor,
                    normalStyle = that._parsePointStyle(pointOptions, mainPointColor, mainPointColor);
                normalStyle.visibility = pointOptions.visible ? "visible" : "hidden";
                return {
                    normal: normalStyle,
                    hover: that._parsePointStyle(pointOptions.hoverStyle, containerColor, mainPointColor),
                    selection: that._parsePointStyle(pointOptions.selectionStyle, containerColor, mainPointColor)
                }
            },
            _checkData: function(data) {
                return _isDefined(data.argument) && void 0 !== data.value
            },
            getErrorBarRangeCorrector: function() {
                var mode, func;
                if (this.areErrorBarsVisible()) {
                    mode = _normalizeEnum(this._options.valueErrorBar.displayMode);
                    func = function(point) {
                        var lowError = point.lowError,
                            highError = point.highError;
                        switch (mode) {
                            case "low":
                                return [lowError];
                            case "high":
                                return [highError];
                            case "none":
                                return [];
                            default:
                                return [lowError, highError]
                        }
                    }
                }
                return func
            },
            _processRange: function(point, prevPoint, errorBarCorrector) {
                rangeCalculator.processRange(this, point, prevPoint, errorBarCorrector)
            },
            _getRangeData: function(zoomArgs, calcIntervalFunction) {
                rangeCalculator.calculateRangeData(this, zoomArgs, calcIntervalFunction);
                rangeCalculator.addLabelPaddings(this);
                return this._rangeData
            },
            _getPointData: function(data, options) {
                var pointData = {
                    value: data[options.valueField || "val"],
                    argument: data[options.argumentField || "arg"],
                    tag: data[options.tagField || "tag"]
                };
                this._fillErrorBars(data, pointData, options);
                return pointData
            },
            _errorBarsEnabled: function() {
                return this.valueAxisType !== DISCRETE && this.valueAxisType !== LOGARITHMIC && this.valueType !== DATETIME
            },
            _fillErrorBars: function(data, pointData, options) {
                var errorBars = options.valueErrorBar;
                if (this.areErrorBarsVisible()) {
                    pointData.lowError = data[errorBars.lowValueField || LOW_ERROR];
                    pointData.highError = data[errorBars.highValueField || HIGH_ERROR]
                }
            },
            _drawPoint: function(options) {
                var point = options.point;
                if (point.isInVisibleArea()) {
                    point.clearVisibility();
                    point.draw(this._renderer, options.groups, options.hasAnimation, options.firstDrawing);
                    this._drawnPoints.push(point)
                } else {
                    point.setInvisibility()
                }
            },
            _clearingAnimation: function(translators, drawComplete) {
                var that = this,
                    params = {
                        opacity: .001
                    },
                    options = {
                        duration: that._defaultDuration,
                        partitionDuration: .5
                    };
                that._labelsGroup && that._labelsGroup.animate(params, options, function() {
                    that._markersGroup && that._markersGroup.animate(params, options, drawComplete)
                })
            },
            _animateComplete: function() {
                var that = this,
                    animationSettings = {
                        duration: that._defaultDuration
                    };
                that._labelsGroup && that._labelsGroup.animate({
                    opacity: 1
                }, animationSettings);
                that._errorBarGroup && that._errorBarGroup.animate({
                    opacity: that._options.valueErrorBar.opacity || 1
                }, animationSettings)
            },
            _animate: function() {
                var that = this,
                    lastPointIndex = that._drawnPoints.length - 1;
                _each(that._drawnPoints || [], function(i, p) {
                    p.animate(i === lastPointIndex ? function() {
                        that._animateComplete()
                    } : void 0, {
                        translateX: p.x,
                        translateY: p.y
                    })
                })
            },
            _getPointSize: function() {
                return this._options.point.visible ? this._options.point.size : DEFAULT_SYMBOL_POINT_SIZE
            },
            _calcMedianValue: function(fusionPoints, valueField) {
                var result, allValue = _map(fusionPoints, function(point) {
                    return _isDefined(point[valueField]) ? point[valueField] : null
                });
                allValue.sort(function(a, b) {
                    return a - b
                });
                result = allValue[_floor(allValue.length / 2)];
                return _isDefined(result) ? result : null
            },
            _calcErrorBarValues: function(fusionPoints) {
                if (!fusionPoints.length) {
                    return {}
                }
                var lowError, highError, lowValue = fusionPoints[0].lowError,
                    highValue = fusionPoints[0].highError,
                    i = 1,
                    length = fusionPoints.length;
                for (i; i < length; i++) {
                    lowError = fusionPoints[i].lowError;
                    highError = fusionPoints[i].highError;
                    if (_isDefined(lowError) && _isDefined(highError)) {
                        lowValue = _min(lowError, lowValue);
                        highValue = _max(highError, highValue)
                    }
                }
                return {
                    low: lowValue,
                    high: highValue
                }
            },
            _fusionPoints: function(fusionPoints, tick, index) {
                var errorBarValues = this._calcErrorBarValues(fusionPoints);
                return {
                    value: this._calcMedianValue(fusionPoints, "value"),
                    argument: tick,
                    tag: null,
                    index: index,
                    seriesName: this.name,
                    lowError: errorBarValues.low,
                    highError: errorBarValues.high
                }
            },
            _endUpdateData: function() {
                delete this._predefinedPointOptions
            },
            getArgumentField: function() {
                return this._options.argumentField || "arg"
            },
            getValueFields: function() {
                var lowValueField, highValueField, options = this._options,
                    errorBarsOptions = options.valueErrorBar,
                    valueFields = [options.valueField || "val"];
                if (errorBarsOptions) {
                    lowValueField = errorBarsOptions.lowValueField;
                    highValueField = errorBarsOptions.highValueField;
                    _isString(lowValueField) && valueFields.push(lowValueField);
                    _isString(highValueField) && valueFields.push(highValueField)
                }
                return valueFields
            },
            _calculateErrorBars: function(data) {
                if (!this.areErrorBarsVisible()) {
                    return
                }
                var value, valueArray, valueArrayLength, meanValue, processDataItem, that = this,
                    options = that._options,
                    errorBarsOptions = options.valueErrorBar,
                    errorBarType = _normalizeEnum(errorBarsOptions.type),
                    floatErrorValue = parseFloat(errorBarsOptions.value),
                    valueField = that.getValueFields()[0],
                    lowValueField = errorBarsOptions.lowValueField || LOW_ERROR,
                    highValueField = errorBarsOptions.highValueField || HIGH_ERROR,
                    addSubError = function(_i, item) {
                        value = item[valueField];
                        item[lowValueField] = value - floatErrorValue;
                        item[highValueField] = value + floatErrorValue
                    };
                switch (errorBarType) {
                    case FIXED:
                        processDataItem = addSubError;
                        break;
                    case PERCENT:
                        processDataItem = function(_, item) {
                            value = item[valueField];
                            var error = value * floatErrorValue / 100;
                            item[lowValueField] = value - error;
                            item[highValueField] = value + error
                        };
                        break;
                    case UNDEFINED:
                        processDataItem = function(_, item) {
                            item[lowValueField] = item[ORIGINAL + lowValueField];
                            item[highValueField] = item[ORIGINAL + highValueField]
                        };
                        break;
                    default:
                        valueArray = _map(data, function(item) {
                            return _isDefined(item[valueField]) ? item[valueField] : null
                        });
                        valueArrayLength = valueArray.length;
                        floatErrorValue = floatErrorValue || 1;
                        switch (errorBarType) {
                            case VARIANCE:
                                floatErrorValue = variance(valueArray, sum(valueArray) / valueArrayLength) * floatErrorValue;
                                processDataItem = addSubError;
                                break;
                            case STANDARD_DEVIATION:
                                meanValue = sum(valueArray) / valueArrayLength;
                                floatErrorValue = _sqrt(variance(valueArray, meanValue)) * floatErrorValue;
                                processDataItem = function(_, item) {
                                    item[lowValueField] = meanValue - floatErrorValue;
                                    item[highValueField] = meanValue + floatErrorValue
                                };
                                break;
                            case STANDARD_ERROR:
                                floatErrorValue = _sqrt(variance(valueArray, sum(valueArray) / valueArrayLength) / valueArrayLength) * floatErrorValue;
                                processDataItem = addSubError
                        }
                }
                processDataItem && _each(data, processDataItem)
            },
            _beginUpdateData: function(data) {
                this._calculateErrorBars(data)
            }
        };
        exports.chart = _extend({}, baseScatterMethods, {
            drawTrackers: function() {
                var trackers, trackersGroup, that = this,
                    segments = that._segments || [],
                    rotated = that._options.rotated,
                    cat = [];
                if (!that.isVisible()) {
                    return
                }
                if (segments.length) {
                    trackers = that._trackers = that._trackers || [];
                    trackersGroup = that._trackersGroup = (that._trackersGroup || that._renderer.g().attr({
                        fill: "gray",
                        opacity: .001,
                        stroke: "gray",
                        "class": "dxc-trackers"
                    })).attr({
                        clipId: this._paneClipRectID || null
                    }).append(that._group);
                    _each(segments, function(i, segment) {
                        if (!trackers[i]) {
                            trackers[i] = that._drawTrackerElement(segment).data({
                                "chart-data-series": that
                            }).append(trackersGroup)
                        } else {
                            that._updateTrackerElement(segment, trackers[i])
                        }
                    })
                }
                that._trackersTranslator = cat;
                _each(that.getVisiblePoints(), function(_, p) {
                    var pointCoord = parseInt(rotated ? p.vy : p.vx);
                    if (!cat[pointCoord]) {
                        cat[pointCoord] = p
                    } else {
                        $.isArray(cat[pointCoord]) ? cat[pointCoord].push(p) : cat[pointCoord] = [cat[pointCoord], p]
                    }
                })
            },
            getNeighborPoint: function(x, y) {
                var minDistance, pCoord = this._options.rotated ? y : x,
                    nCoord = pCoord,
                    cat = this._trackersTranslator,
                    point = null,
                    oppositeCoord = this._options.rotated ? x : y,
                    oppositeCoordName = this._options.rotated ? "vx" : "vy";
                if (this.isVisible() && cat) {
                    point = cat[pCoord];
                    do {
                        point = cat[nCoord] || cat[pCoord];
                        pCoord--;
                        nCoord++
                    } while ((pCoord >= 0 || nCoord < cat.length) && !point);
                    if ($.isArray(point)) {
                        minDistance = _abs(point[0][oppositeCoordName] - oppositeCoord);
                        _each(point, function(i, p) {
                            var distance = _abs(p[oppositeCoordName] - oppositeCoord);
                            if (minDistance >= distance) {
                                minDistance = distance;
                                point = p
                            }
                        })
                    }
                }
                return point
            }
        });
        exports.polar = _extend({}, baseScatterMethods, {
            drawTrackers: function() {
                exports.chart.drawTrackers.call(this);
                var index, cat = this._trackersTranslator;
                if (!this.isVisible()) {
                    return
                }
                _each(cat, function(i, category) {
                    if (category) {
                        index = i;
                        return false
                    }
                });
                cat[index + 360] = cat[index]
            },
            getNeighborPoint: function(x, y) {
                var pos = this.translators.untranslate(x, y);
                return exports.chart.getNeighborPoint.call(this, pos.phi, pos.r)
            },
            _applyVisibleArea: function() {
                var that = this,
                    canvas = that.translators.canvas;
                that._visibleArea = {
                    minX: canvas.left,
                    maxX: canvas.width - canvas.right,
                    minY: canvas.top,
                    maxY: canvas.height - canvas.bottom
                }
            }
        })
    },
    /*!*************************************************************!*\
      !*** ./Scripts/viz/series/helpers/range_data_calculator.js ***!
      \*************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _math = Math,
            _abs = _math.abs,
            _min = _math.min,
            _max = _math.max,
            _each = $.each,
            _isEmptyObject = $.isEmptyObject,
            commonUtils = __webpack_require__( /*! ../../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _isFinite = isFinite,
            unique = __webpack_require__( /*! ../../core/utils */ 442).unique,
            MIN_VISIBLE = "minVisible",
            MAX_VISIBLE = "maxVisible",
            DISCRETE = "discrete";

        function _truncateValue(data, value) {
            var min = data.min,
                max = data.max;
            data.min = value < min || !_isDefined(min) ? value : min;
            data.max = value > max || !_isDefined(max) ? value : max
        }

        function _processValue(series, type, value, prevValue, calcInterval) {
            var interval, isDiscrete = ("arg" === type ? series.argumentAxisType : series.valueAxisType) === DISCRETE,
                data = series._rangeData[type],
                minInterval = data.interval;
            if (isDiscrete && "val" === type) {
                data.categories = data.categories || [];
                data.categories.push(value)
            } else {
                if (!isDiscrete) {
                    _truncateValue(data, value);
                    if ("arg" === type) {
                        interval = (_isDefined(prevValue) ? _abs(calcInterval ? calcInterval(value, prevValue) : value - prevValue) : interval) || minInterval;
                        data.interval = _isDefined(interval) && (interval < minInterval || !_isDefined(minInterval)) ? interval : minInterval
                    }
                }
            }
        }

        function _addToVisibleRange(series, value) {
            var data = series._rangeData.val,
                isDiscrete = series.valueAxisType === DISCRETE;
            if (!isDiscrete) {
                if (value < data.minVisible || !_isDefined(data.minVisible)) {
                    data.minVisible = value
                }
                if (value > data.maxVisible || !_isDefined(data.maxVisible)) {
                    data.maxVisible = value
                }
            }
        }

        function _processRangeValue(series, val, minVal) {
            var data = series._rangeData.val;
            if (series.valueAxisType === DISCRETE) {
                data.categories = data.categories || [];
                data.categories.push(val, minVal)
            } else {
                _truncateValue(data, val);
                _truncateValue(data, minVal)
            }
        }

        function _processZoomArgument(series, zoomArgs, isDiscrete) {
            var minArg, maxArg, data = series._rangeData.arg;
            if (isDiscrete) {
                data.minVisible = zoomArgs.minArg;
                data.maxVisible = zoomArgs.maxArg;
                return
            }
            minArg = zoomArgs.minArg < zoomArgs.maxArg ? zoomArgs.minArg : zoomArgs.maxArg;
            maxArg = zoomArgs.maxArg > zoomArgs.minArg ? zoomArgs.maxArg : zoomArgs.minArg;
            data.min = minArg < data.min ? minArg : data.min;
            data.max = maxArg > data.max ? maxArg : data.max;
            data.minVisible = minArg;
            data.maxVisible = maxArg
        }

        function _correctZoomValue(series, zoomArgs) {
            var minVal, maxVal;
            if (_isDefined(zoomArgs.minVal) && _isDefined(zoomArgs.maxVal)) {
                minVal = zoomArgs.minVal < zoomArgs.maxVal ? zoomArgs.minVal : zoomArgs.maxVal;
                maxVal = zoomArgs.maxVal > zoomArgs.minVal ? zoomArgs.maxVal : zoomArgs.minVal
            }
            if (_isDefined(zoomArgs.minVal)) {
                series._rangeData.val.min = minVal < series._rangeData.val.min ? minVal : series._rangeData.val.min;
                series._rangeData.val.minVisible = minVal
            }
            if (_isDefined(zoomArgs.maxVal)) {
                series._rangeData.val.max = maxVal > series._rangeData.val.max ? maxVal : series._rangeData.val.max;
                series._rangeData.val.maxVisible = maxVal
            }
        }

        function _processZoomValue(series, zoomArgs) {
            var lastVisibleIndex, adjustOnZoom = zoomArgs.adjustOnZoom,
                points = series._points || [],
                prevPointAdded = false,
                rangeData = series._rangeData,
                errorBarCorrector = series.getErrorBarRangeCorrector();
            _each(points, function(index, point) {
                var arg = point.argument,
                    prevPoint = index > 0 ? points[index - 1] : null;
                if (adjustOnZoom && series.argumentAxisType !== DISCRETE && arg >= rangeData.arg.minVisible && arg <= rangeData.arg.maxVisible) {
                    if (!prevPointAdded) {
                        if (prevPoint && prevPoint.hasValue()) {
                            _addToVisibleRange(series, prevPoint.value);
                            _correctMinMaxByErrorBar(rangeData.val, prevPoint, errorBarCorrector, MIN_VISIBLE, MAX_VISIBLE)
                        }
                        prevPointAdded = true
                    }
                    if (point.hasValue()) {
                        _addToVisibleRange(series, point.value);
                        _correctMinMaxByErrorBar(rangeData.val, point, errorBarCorrector, MIN_VISIBLE, MAX_VISIBLE)
                    }
                    lastVisibleIndex = index
                }
            });
            if (_isDefined(lastVisibleIndex) && lastVisibleIndex < points.length - 1 && points[lastVisibleIndex + 1].hasValue()) {
                _addToVisibleRange(series, points[lastVisibleIndex + 1].value)
            }
            _correctZoomValue(series, zoomArgs)
        }

        function _processZoomRangeValue(series, zoomArgs, maxValueName, minValueName) {
            var lastVisibleIndex, adjustOnZoom = zoomArgs.adjustOnZoom,
                points = series._points || [],
                argRangeData = series._rangeData.arg,
                prevPointAdded = false;
            _each(points, function(index, point) {
                var arg = point.argument,
                    prevPoint = index > 0 ? points[index - 1] : null;
                if (adjustOnZoom && series.argumentAxisType !== DISCRETE && arg >= argRangeData.minVisible && arg <= argRangeData.maxVisible) {
                    if (!prevPointAdded) {
                        if (prevPoint && prevPoint.hasValue()) {
                            _addToVisibleRange(series, prevPoint[maxValueName]);
                            _addToVisibleRange(series, prevPoint[minValueName])
                        }
                        prevPointAdded = true
                    }
                    if (point.hasValue()) {
                        _addToVisibleRange(series, point[maxValueName]);
                        _addToVisibleRange(series, point[minValueName])
                    }
                    lastVisibleIndex = index
                }
            });
            if (_isDefined(lastVisibleIndex) && lastVisibleIndex < points.length - 1 && points[lastVisibleIndex + 1].hasValue()) {
                _addToVisibleRange(series, points[lastVisibleIndex + 1].value)
            }
            _correctZoomValue(series, zoomArgs)
        }

        function _processNewInterval(series, calcInterval) {
            var data = series._rangeData,
                points = series._points || [],
                isArgumentAxisDiscrete = series.argumentAxisType === DISCRETE;
            delete data.arg.interval;
            _each(points, function(index, point) {
                var arg = point.argument,
                    prevPoint = index > 0 ? points[index - 1] : null,
                    prevArg = prevPoint && prevPoint.argument;
                !isArgumentAxisDiscrete && _processValue(series, "arg", arg, prevArg, calcInterval)
            })
        }

        function _fillRangeData(series) {
            var data = series._rangeData;
            data.arg.categories && (data.arg.categories = unique(data.arg.categories));
            data.val.categories && (data.val.categories = unique(data.val.categories));
            data.arg.axisType = series.argumentAxisType;
            data.arg.dataType = series.argumentType;
            data.val.axisType = series.valueAxisType;
            data.val.dataType = series.valueType
        }

        function processTwoValues(series, point, prevPoint, highValueName, lowValueName) {
            var val = point[highValueName],
                minVal = point[lowValueName],
                arg = point.argument,
                prevVal = prevPoint && prevPoint[highValueName],
                prevMinVal = prevPoint && prevPoint[lowValueName],
                prevArg = prevPoint && prevPoint.argument;
            point.hasValue() && _processRangeValue(series, val, minVal, prevVal, prevMinVal);
            _processValue(series, "arg", arg, prevArg)
        }

        function calculateRangeMinValue(series, zoomArgs) {
            var data = series._rangeData.val,
                minVisible = data[MIN_VISIBLE],
                maxVisible = data[MAX_VISIBLE];
            zoomArgs = zoomArgs || {};
            if (data) {
                if ("logarithmic" !== series.valueAxisType && "datetime" !== series.valueType && false !== series.showZero) {
                    data[MIN_VISIBLE] = minVisible > (zoomArgs.minVal || 0) ? zoomArgs.minVal || 0 : minVisible;
                    data[MAX_VISIBLE] = maxVisible < (zoomArgs.maxVal || 0) ? zoomArgs.maxVal || 0 : maxVisible;
                    data.min = data.min > 0 ? 0 : data.min;
                    data.max = data.max < 0 ? 0 : data.max
                }
            }
        }

        function processFullStackedRange(series) {
            var data = series._rangeData.val,
                isRangeEmpty = _isEmptyObject(data);
            data.percentStick = true;
            if (!isRangeEmpty) {
                data.min = data.min > 0 ? 0 : data.min;
                data.max = data.max < 0 ? 0 : data.max
            }
        }

        function _correctMinMaxByErrorBar(data, point, getMinMaxCorrector, minSelector, maxSelector) {
            if (!getMinMaxCorrector) {
                return
            }
            var correctionData = getMinMaxCorrector(point),
                minError = _min.apply(void 0, correctionData),
                maxError = _max.apply(void 0, correctionData);
            if (_isFinite(minError) && data[minSelector] > minError) {
                data[minSelector] = minError
            }
            if (_isFinite(maxError) && data[maxSelector] < maxError) {
                data[maxSelector] = maxError
            }
        }

        function processRange(series, point, prevPoint, getMinMaxCorrector) {
            var val = point.value,
                arg = point.argument,
                prevVal = prevPoint && prevPoint.value,
                prevArg = prevPoint && prevPoint.argument;
            point.hasValue() && _processValue(series, "val", val, prevVal);
            _processValue(series, "arg", arg, prevArg);
            _correctMinMaxByErrorBar(series._rangeData.val, point, getMinMaxCorrector, "min", "max")
        }

        function addLabelPaddings(series) {
            var valueData, labelOptions = series.getOptions().label;
            if (series.areLabelsVisible() && labelOptions && labelOptions.visible && "inside" !== labelOptions.position) {
                valueData = series._rangeData.val;
                if (valueData.min < 0) {
                    valueData.minSpaceCorrection = true
                }
                if (valueData.max > 0) {
                    valueData.maxSpaceCorrection = true
                }
            }
        }

        function addRangeSeriesLabelPaddings(series) {
            var data = series._rangeData.val;
            if (series.areLabelsVisible() && series._options.label.visible && "inside" !== series._options.label.position) {
                data.minSpaceCorrection = data.maxSpaceCorrection = true
            }
        }

        function calculateRangeData(series, zoomArgs, calcIntervalFunction, maxValueName, minValueName) {
            var valueData = series._rangeData.val,
                isRangeSeries = !!maxValueName && !!minValueName,
                isDiscrete = series.argumentAxisType === DISCRETE;
            if (zoomArgs && _isDefined(zoomArgs.minArg) && _isDefined(zoomArgs.maxArg)) {
                if (!isDiscrete) {
                    valueData[MIN_VISIBLE] = zoomArgs.minVal;
                    valueData[MAX_VISIBLE] = zoomArgs.maxVal
                }
                _processZoomArgument(series, zoomArgs, isDiscrete);
                if (isRangeSeries) {
                    _processZoomRangeValue(series, zoomArgs, maxValueName, minValueName)
                } else {
                    _processZoomValue(series, zoomArgs)
                }
            } else {
                if (!zoomArgs && calcIntervalFunction) {
                    _processNewInterval(series, calcIntervalFunction)
                }
            }
            _fillRangeData(series)
        }
        module.exports = {
            processRange: processRange,
            calculateRangeData: calculateRangeData,
            addLabelPaddings: addLabelPaddings,
            addRangeSeriesLabelPaddings: addRangeSeriesLabelPaddings,
            processFullStackedRange: processFullStackedRange,
            calculateRangeMinValue: calculateRangeMinValue,
            processTwoValues: processTwoValues
        }
    },
    /*!*******************************************!*\
      !*** ./Scripts/viz/series/line_series.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            series = __webpack_require__( /*! ./scatter_series */ 474),
            chartScatterSeries = series.chart,
            polarScatterSeries = series.polar,
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            normalizeAngle = vizUtils.normalizeAngle,
            CANVAS_POSITION_START = "canvas_position_start",
            CANVAS_POSITION_TOP = "canvas_position_top",
            DISCRETE = "discrete",
            _map = vizUtils.map,
            _extend = $.extend,
            _each = $.each;
        exports.chart = {};
        exports.polar = {};

        function clonePoint(point, newX, newY, newAngle) {
            var p = objectUtils.clone(point);
            p.x = newX;
            p.y = newY;
            p.angle = newAngle;
            return p
        }

        function getTangentPoint(point, prevPoint, centerPoint, tan, nextStepAngle) {
            var correctAngle = point.angle + nextStepAngle,
                cossin = vizUtils.getCosAndSin(correctAngle),
                x = centerPoint.x + (point.radius + tan * nextStepAngle) * cossin.cos,
                y = centerPoint.y - (point.radius + tan * nextStepAngle) * cossin.sin;
            return clonePoint(prevPoint, x, y, correctAngle)
        }
        var lineMethods = {
            _applyGroupSettings: function(style, settings, group) {
                var that = this;
                settings = _extend(settings, style);
                that._applyElementsClipRect(settings);
                group.attr(settings)
            },
            _setGroupsSettings: function(animationEnabled) {
                var that = this,
                    style = that._styles.normal;
                that._applyGroupSettings(style.elements, {
                    "class": "dxc-elements"
                }, that._elementsGroup);
                that._bordersGroup && that._applyGroupSettings(style.border, {
                    "class": "dxc-borders"
                }, that._bordersGroup);
                chartScatterSeries._setGroupsSettings.call(that, animationEnabled);
                animationEnabled && that._markersGroup && that._markersGroup.attr({
                    opacity: .001
                })
            },
            _createGroups: function() {
                var that = this;
                that._createGroup("_elementsGroup", that, that._group);
                that._areBordersVisible() && that._createGroup("_bordersGroup", that, that._group);
                chartScatterSeries._createGroups.call(that)
            },
            _areBordersVisible: function() {
                return false
            },
            _getDefaultSegment: function(segment) {
                return {
                    line: _map(segment.line || [], function(pt) {
                        return pt.getDefaultCoords()
                    })
                }
            },
            _prepareSegment: function(points) {
                return {
                    line: points
                }
            },
            _parseLineOptions: function(options, defaultColor) {
                return {
                    stroke: options.color || defaultColor,
                    "stroke-width": options.width,
                    dashStyle: options.dashStyle || "solid"
                }
            },
            _parseStyle: function(options, defaultColor) {
                return {
                    elements: this._parseLineOptions(options, defaultColor)
                }
            },
            _applyStyle: function(style) {
                var that = this;
                that._elementsGroup && that._elementsGroup.attr(style.elements);
                _each(that._graphics || [], function(_, graphic) {
                    graphic.line && graphic.line.attr({
                        "stroke-width": style.elements["stroke-width"]
                    }).sharp()
                })
            },
            _drawElement: function(segment, group) {
                return {
                    line: this._createMainElement(segment.line, {
                        "stroke-width": this._styles.normal.elements["stroke-width"]
                    }).append(group)
                }
            },
            _removeElement: function(element) {
                element.line.remove()
            },
            _generateDefaultSegments: function() {
                var that = this;
                return _map(that._segments || [], function(segment) {
                    return that._getDefaultSegment(segment)
                })
            },
            _updateElement: function(element, segment, animate, animateParams, complete) {
                var params = {
                        points: segment.line
                    },
                    lineElement = element.line;
                animate ? lineElement.animate(params, animateParams, complete) : lineElement.attr(params)
            },
            _clearingAnimation: function(translator, drawComplete) {
                var that = this,
                    lastIndex = that._graphics.length - 1,
                    settings = {
                        opacity: .001
                    },
                    options = {
                        duration: that._defaultDuration,
                        partitionDuration: .5
                    };
                that._labelsGroup && that._labelsGroup.animate(settings, options, function() {
                    that._markersGroup && that._markersGroup.animate(settings, options, function() {
                        _each(that._defaultSegments || [], function(i, segment) {
                            that._oldUpdateElement(that._graphics[i], segment, true, {
                                partitionDuration: .5
                            }, i === lastIndex ? drawComplete : void 0)
                        })
                    })
                })
            },
            _animateComplete: function() {
                var that = this;
                chartScatterSeries._animateComplete.call(this);
                that._markersGroup && that._markersGroup.animate({
                    opacity: 1
                }, {
                    duration: that._defaultDuration
                })
            },
            _animate: function() {
                var that = this,
                    lastIndex = that._graphics.length - 1;
                _each(that._graphics || [], function(i, elem) {
                    that._updateElement(elem, that._segments[i], true, {
                        complete: i === lastIndex ? function() {
                            that._animateComplete()
                        } : void 0
                    })
                })
            },
            _drawPoint: function(options) {
                chartScatterSeries._drawPoint.call(this, {
                    point: options.point,
                    groups: options.groups
                })
            },
            _createMainElement: function(points, settings) {
                return this._renderer.path(points, "line").attr(settings).sharp()
            },
            _drawSegment: function(points, animationEnabled, segmentCount, lastSegment) {
                var that = this,
                    segment = that._prepareSegment(points, that._options.rotated, lastSegment);
                that._segments.push(segment);
                if (!that._graphics[segmentCount]) {
                    that._graphics[segmentCount] = that._drawElement(animationEnabled ? that._getDefaultSegment(segment) : segment, that._elementsGroup)
                } else {
                    if (!animationEnabled) {
                        that._updateElement(that._graphics[segmentCount], segment)
                    }
                }
            },
            _getTrackerSettings: function() {
                var that = this,
                    defaultTrackerWidth = that._defaultTrackerWidth,
                    strokeWidthFromElements = that._styles.normal.elements["stroke-width"];
                return {
                    "stroke-width": strokeWidthFromElements > defaultTrackerWidth ? strokeWidthFromElements : defaultTrackerWidth,
                    fill: "none"
                }
            },
            _getMainPointsFromSegment: function(segment) {
                return segment.line
            },
            _drawTrackerElement: function(segment) {
                return this._createMainElement(this._getMainPointsFromSegment(segment), this._getTrackerSettings(segment))
            },
            _updateTrackerElement: function(segment, element) {
                var settings = this._getTrackerSettings(segment);
                settings.points = this._getMainPointsFromSegment(segment);
                element.attr(settings)
            }
        };
        exports.chart.line = _extend({}, chartScatterSeries, lineMethods);
        exports.chart.stepline = _extend({}, exports.chart.line, {
            _calculateStepLinePoints: function(points) {
                var segment = [];
                _each(points, function(i, pt) {
                    var stepY, point;
                    if (!i) {
                        segment.push(pt);
                        return
                    }
                    stepY = segment[segment.length - 1].y;
                    if (stepY !== pt.y) {
                        point = objectUtils.clone(pt);
                        point.y = stepY;
                        segment.push(point)
                    }
                    segment.push(pt)
                });
                return segment
            },
            _prepareSegment: function(points) {
                return exports.chart.line._prepareSegment(this._calculateStepLinePoints(points))
            }
        });
        exports.chart.spline = _extend({}, exports.chart.line, {
            _calculateBezierPoints: function(src, rotated) {
                var bezierPoints = [],
                    pointsCopy = src,
                    checkExtr = function(otherPointCoord, pointCoord, controlCoord) {
                        return otherPointCoord > pointCoord && controlCoord > otherPointCoord || otherPointCoord < pointCoord && controlCoord < otherPointCoord ? otherPointCoord : controlCoord
                    };
                if (1 !== pointsCopy.length) {
                    _each(pointsCopy, function(i, curPoint) {
                        var leftControlX, leftControlY, rightControlX, rightControlY, prevPoint, nextPoint, xCur, yCur, x1, x2, y1, y2, curIsExtremum, leftPoint, rightPoint, a, b, c, xc, yc, shift, lambda = .5;
                        if (!i) {
                            bezierPoints.push(curPoint);
                            bezierPoints.push(curPoint);
                            return
                        }
                        prevPoint = pointsCopy[i - 1];
                        if (i < pointsCopy.length - 1) {
                            nextPoint = pointsCopy[i + 1];
                            xCur = curPoint.x;
                            yCur = curPoint.y;
                            x1 = prevPoint.x;
                            x2 = nextPoint.x;
                            y1 = prevPoint.y;
                            y2 = nextPoint.y;
                            curIsExtremum = !!(!rotated && (yCur <= prevPoint.y && yCur <= nextPoint.y || yCur >= prevPoint.y && yCur >= nextPoint.y) || rotated && (xCur <= prevPoint.x && xCur <= nextPoint.x || xCur >= prevPoint.x && xCur >= nextPoint.x));
                            if (curIsExtremum) {
                                if (!rotated) {
                                    rightControlY = leftControlY = yCur;
                                    rightControlX = (xCur + nextPoint.x) / 2;
                                    leftControlX = (xCur + prevPoint.x) / 2
                                } else {
                                    rightControlX = leftControlX = xCur;
                                    rightControlY = (yCur + nextPoint.y) / 2;
                                    leftControlY = (yCur + prevPoint.y) / 2
                                }
                            } else {
                                a = y2 - y1;
                                b = x1 - x2;
                                c = y1 * x2 - x1 * y2;
                                if (!rotated) {
                                    xc = xCur;
                                    yc = -1 * (a * xc + c) / b;
                                    shift = yc - yCur || 0;
                                    y1 -= shift;
                                    y2 -= shift
                                } else {
                                    yc = yCur;
                                    xc = -1 * (b * yc + c) / a;
                                    shift = xc - xCur || 0;
                                    x1 -= shift;
                                    x2 -= shift
                                }
                                rightControlX = (xCur + lambda * x2) / (1 + lambda);
                                rightControlY = (yCur + lambda * y2) / (1 + lambda);
                                leftControlX = (xCur + lambda * x1) / (1 + lambda);
                                leftControlY = (yCur + lambda * y1) / (1 + lambda)
                            }
                            if (!rotated) {
                                leftControlY = checkExtr(prevPoint.y, yCur, leftControlY);
                                rightControlY = checkExtr(nextPoint.y, yCur, rightControlY)
                            } else {
                                leftControlX = checkExtr(prevPoint.x, xCur, leftControlX);
                                rightControlX = checkExtr(nextPoint.x, xCur, rightControlX)
                            }
                            leftPoint = clonePoint(curPoint, leftControlX, leftControlY);
                            rightPoint = clonePoint(curPoint, rightControlX, rightControlY);
                            bezierPoints.push(leftPoint, curPoint, rightPoint)
                        } else {
                            bezierPoints.push(curPoint, curPoint);
                            return
                        }
                    })
                } else {
                    bezierPoints.push(pointsCopy[0])
                }
                return bezierPoints
            },
            _prepareSegment: function(points, rotated) {
                return exports.chart.line._prepareSegment(this._calculateBezierPoints(points, rotated))
            },
            _createMainElement: function(points, settings) {
                return this._renderer.path(points, "bezier").attr(settings).sharp()
            }
        });
        exports.polar.line = _extend({}, polarScatterSeries, lineMethods, {
            _prepareSegment: function(points, rotated, lastSegment) {
                var i, preparedPoints = [],
                    centerPoint = this.translators.translate(CANVAS_POSITION_START, CANVAS_POSITION_TOP);
                lastSegment && this._closeSegment(points);
                if (this.argumentAxisType !== DISCRETE && this.valueAxisType !== DISCRETE) {
                    for (i = 1; i < points.length; i++) {
                        preparedPoints = preparedPoints.concat(this._getTangentPoints(points[i], points[i - 1], centerPoint))
                    }
                    if (!preparedPoints.length) {
                        preparedPoints = points
                    }
                } else {
                    return exports.chart.line._prepareSegment.apply(this, arguments)
                }
                return {
                    line: preparedPoints
                }
            },
            _getRemainingAngle: function(angle) {
                var normAngle = normalizeAngle(angle);
                return angle >= 0 ? 360 - normAngle : -normAngle
            },
            _closeSegment: function(points) {
                var point, differenceAngle;
                if (this._segments.length) {
                    point = this._segments[0].line[0]
                } else {
                    point = clonePoint(points[0], points[0].x, points[0].y, points[0].angle)
                }
                if (points[points.length - 1].angle !== point.angle) {
                    if (normalizeAngle(Math.round(points[points.length - 1].angle)) === normalizeAngle(Math.round(point.angle))) {
                        point.angle = points[points.length - 1].angle
                    } else {
                        differenceAngle = points[points.length - 1].angle - point.angle;
                        point.angle = points[points.length - 1].angle + this._getRemainingAngle(differenceAngle)
                    }
                    points.push(point)
                }
            },
            _getTangentPoints: function(point, prevPoint, centerPoint) {
                var i, tangentPoints = [],
                    betweenAngle = Math.round(prevPoint.angle - point.angle),
                    tan = (prevPoint.radius - point.radius) / betweenAngle;
                if (0 === betweenAngle) {
                    tangentPoints = [prevPoint, point]
                } else {
                    if (betweenAngle > 0) {
                        for (i = betweenAngle; i >= 0; i--) {
                            tangentPoints.push(getTangentPoint(point, prevPoint, centerPoint, tan, i))
                        }
                    } else {
                        for (i = 0; i >= betweenAngle; i--) {
                            tangentPoints.push(getTangentPoint(point, prevPoint, centerPoint, tan, betweenAngle - i))
                        }
                    }
                }
                return tangentPoints
            }
        })
    },
    /*!*******************************************!*\
      !*** ./Scripts/viz/series/area_series.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            rangeCalculator = __webpack_require__( /*! ./helpers/range_data_calculator */ 475),
            Color = __webpack_require__( /*! ../../color */ 26),
            scatterSeries = __webpack_require__( /*! ./scatter_series */ 474).chart,
            lineSeries = __webpack_require__( /*! ./line_series */ 476),
            chartLineSeries = lineSeries.chart.line,
            polarLineSeries = lineSeries.polar.line,
            _map = __webpack_require__( /*! ../core/utils */ 442).map,
            _extend = $.extend,
            HOVER_COLOR_HIGHLIGHTING = 20;
        exports.chart = {};
        exports.polar = {};
        var baseAreaMethods = {
            _createBorderElement: chartLineSeries._createMainElement,
            _createLegendState: function(styleOptions, defaultColor) {
                var legendState = scatterSeries._createLegendState.call(this, styleOptions, defaultColor);
                legendState.opacity = styleOptions.opacity;
                return legendState
            },
            _getSpecialColor: function(color) {
                return this._options._IE8 ? new Color(color).highlight(HOVER_COLOR_HIGHLIGHTING) : color
            },
            _getRangeData: function(zoomArgs, calcIntervalFunction) {
                rangeCalculator.calculateRangeData(this, zoomArgs, calcIntervalFunction);
                rangeCalculator.addLabelPaddings(this);
                rangeCalculator.calculateRangeMinValue(this, zoomArgs);
                return this._rangeData
            },
            _getDefaultSegment: function(segment) {
                var defaultSegment = chartLineSeries._getDefaultSegment(segment);
                defaultSegment.area = defaultSegment.line.concat(defaultSegment.line.slice().reverse());
                return defaultSegment
            },
            _updateElement: function(element, segment, animate, animateParams, complete) {
                var lineParams = {
                        points: segment.line
                    },
                    areaParams = {
                        points: segment.area
                    },
                    borderElement = element.line;
                if (animate) {
                    borderElement && borderElement.animate(lineParams, animateParams);
                    element.area.animate(areaParams, animateParams, complete)
                } else {
                    borderElement && borderElement.attr(lineParams);
                    element.area.attr(areaParams)
                }
            },
            _removeElement: function(element) {
                element.line && element.line.remove();
                element.area.remove()
            },
            _drawElement: function(segment) {
                return {
                    line: this._bordersGroup && this._createBorderElement(segment.line, {
                        "stroke-width": this._styles.normal.border["stroke-width"]
                    }).append(this._bordersGroup),
                    area: this._createMainElement(segment.area).append(this._elementsGroup)
                }
            },
            _applyStyle: function(style) {
                var that = this;
                that._elementsGroup && that._elementsGroup.attr(style.elements);
                that._bordersGroup && that._bordersGroup.attr(style.border);
                $.each(that._graphics || [], function(_, graphic) {
                    graphic.line && graphic.line.attr({
                        "stroke-width": style.border["stroke-width"]
                    }).sharp()
                })
            },
            _createPattern: function(color, hatching) {
                if (hatching && commonUtils.isObject(hatching)) {
                    var pattern = this._renderer.pattern(color, hatching);
                    this._patterns.push(pattern);
                    return pattern.id
                }
                return color
            },
            _parseStyle: function(options, defaultColor, defaultBorderColor) {
                var borderOptions = options.border || {},
                    borderStyle = chartLineSeries._parseLineOptions(borderOptions, defaultBorderColor);
                borderStyle["stroke-width"] = borderOptions.visible ? borderStyle["stroke-width"] : 0;
                return {
                    border: borderStyle,
                    elements: {
                        stroke: "none",
                        fill: this._createPattern(options.color || defaultColor, options.hatching),
                        opacity: options.opacity
                    }
                }
            },
            _areBordersVisible: function() {
                var options = this._options;
                return options.border.visible || options.hoverStyle.border.visible || options.selectionStyle.border.visible
            },
            _createMainElement: function(points, settings) {
                return this._renderer.path(points, "area").attr(settings)
            },
            _getTrackerSettings: function(segment) {
                return {
                    "stroke-width": segment.singlePointSegment ? this._defaultTrackerWidth : 0
                }
            },
            _getMainPointsFromSegment: function(segment) {
                return segment.area
            }
        };
        exports.chart.area = _extend({}, chartLineSeries, baseAreaMethods, {
            _prepareSegment: function(points, rotated) {
                var processedPoints = this._processSinglePointsAreaSegment(points, rotated);
                return {
                    line: processedPoints,
                    area: _map(processedPoints, function(pt) {
                        return pt.getCoords()
                    }).concat(_map(processedPoints.slice().reverse(), function(pt) {
                        return pt.getCoords(true)
                    })),
                    singlePointSegment: processedPoints !== points
                }
            },
            _processSinglePointsAreaSegment: function(points, rotated) {
                if (1 === points.length) {
                    var p = points[0],
                        p1 = objectUtils.clone(p);
                    p1[rotated ? "y" : "x"] += 1;
                    p1.argument = null;
                    return [p, p1]
                }
                return points
            }
        });
        exports.polar.area = _extend({}, polarLineSeries, baseAreaMethods, {
            _prepareSegment: function(points, rotated, lastSegment) {
                lastSegment && polarLineSeries._closeSegment.call(this, points);
                var preparedPoints = exports.chart.area._prepareSegment.call(this, points);
                return preparedPoints
            },
            _processSinglePointsAreaSegment: function(points) {
                return lineSeries.polar.line._prepareSegment.call(this, points).line
            }
        });
        exports.chart.steparea = _extend({}, exports.chart.area, {
            _prepareSegment: function(points, rotated) {
                points = exports.chart.area._processSinglePointsAreaSegment(points, rotated);
                return exports.chart.area._prepareSegment.call(this, lineSeries.chart.stepline._calculateStepLinePoints(points))
            }
        });
        exports.chart.splinearea = _extend({}, exports.chart.area, {
            _areaPointsToSplineAreaPoints: function(areaPoints) {
                var lastFwPoint = areaPoints[areaPoints.length / 2 - 1],
                    firstBwPoint = areaPoints[areaPoints.length / 2];
                areaPoints.splice(areaPoints.length / 2, 0, {
                    x: lastFwPoint.x,
                    y: lastFwPoint.y
                }, {
                    x: firstBwPoint.x,
                    y: firstBwPoint.y
                });
                if (lastFwPoint.defaultCoords) {
                    areaPoints[areaPoints.length / 2].defaultCoords = true
                }
                if (firstBwPoint.defaultCoords) {
                    areaPoints[areaPoints.length / 2 - 1].defaultCoords = true
                }
            },
            _prepareSegment: function(points, rotated) {
                var areaSeries = exports.chart.area,
                    processedPoints = areaSeries._processSinglePointsAreaSegment(points, rotated),
                    areaSegment = areaSeries._prepareSegment.call(this, lineSeries.chart.spline._calculateBezierPoints(processedPoints, rotated));
                this._areaPointsToSplineAreaPoints(areaSegment.area);
                areaSegment.singlePointSegment = processedPoints !== points;
                return areaSegment
            },
            _getDefaultSegment: function(segment) {
                var areaDefaultSegment = exports.chart.area._getDefaultSegment(segment);
                this._areaPointsToSplineAreaPoints(areaDefaultSegment.area);
                return areaDefaultSegment
            },
            _createMainElement: function(points, settings) {
                return this._renderer.path(points, "bezierarea").attr(settings)
            },
            _createBorderElement: lineSeries.chart.spline._createMainElement
        })
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/series/bar_series.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            scatterSeries = __webpack_require__( /*! ./scatter_series */ 474),
            areaSeries = __webpack_require__( /*! ./area_series */ 477).chart.area,
            chartSeries = scatterSeries.chart,
            polarSeries = scatterSeries.polar,
            _extend = $.extend,
            _each = $.each,
            DEFAULT_BAR_POINT_SIZE = 3;
        exports.chart = {};
        exports.polar = {};
        var baseBarSeriesMethods = {
            _getSpecialColor: areaSeries._getSpecialColor,
            _createPattern: areaSeries._createPattern,
            _updateOptions: function(options) {
                this._stackName = "axis_" + (options.axis || "default") + "_stack_" + (options.stack || "default")
            },
            _parsePointStyle: function(style, defaultColor, defaultBorderColor) {
                var color = this._createPattern(style.color || defaultColor, style.hatching),
                    base = chartSeries._parsePointStyle.call(this, style, color, defaultBorderColor);
                base.fill = color;
                base.dashStyle = style.border && style.border.dashStyle || "solid";
                delete base.r;
                return base
            },
            _applyMarkerClipRect: function(settings) {
                settings.clipId = null
            },
            _clearingAnimation: function(translators, drawComplete) {
                var that = this,
                    settings = that._oldgetAffineCoordOptions(translators) || that._getAffineCoordOptions(translators);
                that._labelsGroup && that._labelsGroup.animate({
                    opacity: .001
                }, {
                    duration: that._defaultDuration,
                    partitionDuration: .5
                }, function() {
                    that._markersGroup.animate(settings, {
                        partitionDuration: .5
                    }, function() {
                        that._markersGroup.attr({
                            scaleX: null,
                            scaleY: null,
                            translateX: 0,
                            translateY: 0
                        });
                        drawComplete()
                    })
                })
            },
            _setGroupsSettings: function(animationEnabled, firstDrawing) {
                var that = this,
                    settings = {};
                chartSeries._setGroupsSettings.apply(that, arguments);
                if (animationEnabled && firstDrawing) {
                    settings = this._getAffineCoordOptions(that.translators, true)
                } else {
                    if (!animationEnabled) {
                        settings = {
                            scaleX: 1,
                            scaleY: 1,
                            translateX: 0,
                            translateY: 0
                        }
                    }
                }
                that._markersGroup.attr(settings)
            },
            _drawPoint: function(options) {
                options.hasAnimation = options.hasAnimation && !options.firstDrawing;
                options.firstDrawing = false;
                chartSeries._drawPoint.call(this, options)
            },
            _getMainColor: function() {
                return this._options.mainSeriesColor
            },
            _createPointStyles: function(pointOptions) {
                var that = this,
                    mainColor = pointOptions.color || that._getMainColor(),
                    specialMainColor = that._getSpecialColor(mainColor);
                return {
                    normal: that._parsePointStyle(pointOptions, mainColor, mainColor),
                    hover: that._parsePointStyle(pointOptions.hoverStyle || {}, specialMainColor, mainColor),
                    selection: that._parsePointStyle(pointOptions.selectionStyle || {}, specialMainColor, mainColor)
                }
            },
            _updatePointsVisibility: function() {
                var visibility = this._options.visible;
                $.each(this._points, function(_, point) {
                    point._options.visible = visibility
                })
            },
            _getOptionsForPoint: function() {
                return this._options
            },
            _animate: function(firstDrawing) {
                var that = this,
                    complete = function() {
                        that._animateComplete()
                    },
                    animateFunc = function(drawnPoints, complete) {
                        var lastPointIndex = drawnPoints.length - 1;
                        _each(drawnPoints || [], function(i, point) {
                            point.animate(i === lastPointIndex ? complete : void 0, point.getMarkerCoords())
                        })
                    };
                that._animatePoints(firstDrawing, complete, animateFunc)
            },
            _getPointSize: function() {
                return DEFAULT_BAR_POINT_SIZE
            },
            _beginUpdateData: function(data) {
                chartSeries._beginUpdateData.call(this, data);
                this._deletePatterns()
            }
        };
        exports.chart.bar = _extend({}, chartSeries, baseBarSeriesMethods, {
            _getAffineCoordOptions: function(translators) {
                var rotated = this._options.rotated,
                    direction = rotated ? "x" : "y",
                    settings = {
                        scaleX: rotated ? .001 : 1,
                        scaleY: rotated ? 1 : .001
                    };
                settings["translate" + direction.toUpperCase()] = translators[direction].translate("canvas_position_default");
                return settings
            },
            _getRangeData: function() {
                var rangeData = areaSeries._getRangeData.apply(this, arguments);
                rangeData.arg.stick = false;
                return rangeData
            },
            _animatePoints: function(firstDrawing, complete, animateFunc) {
                var that = this;
                that._markersGroup.animate({
                    scaleX: 1,
                    scaleY: 1,
                    translateY: 0,
                    translateX: 0
                }, void 0, complete);
                if (!firstDrawing) {
                    animateFunc(that._drawnPoints, complete)
                }
            }
        });
        exports.polar.bar = _extend({}, polarSeries, baseBarSeriesMethods, {
            _animatePoints: function(firstDrawing, complete, animateFunc) {
                animateFunc(this._drawnPoints, complete)
            },
            _setGroupsSettings: chartSeries._setGroupsSettings,
            _drawPoint: function(point, groups, animationEnabled) {
                chartSeries._drawPoint.call(this, point, groups, animationEnabled)
            },
            _parsePointStyle: function(style) {
                var base = baseBarSeriesMethods._parsePointStyle.apply(this, arguments);
                base.opacity = style.opacity;
                return base
            },
            _createGroups: chartSeries._createGroups,
            _setMarkerGroupSettings: function() {
                var groupSettings, that = this,
                    markersSettings = that._createPointStyles(that._getMarkerGroupOptions()).normal;
                markersSettings.class = "dxc-markers";
                that._applyMarkerClipRect(markersSettings);
                groupSettings = _extend({}, markersSettings);
                delete groupSettings.opacity;
                that._markersGroup.attr(groupSettings)
            },
            _createLegendState: areaSeries._createLegendState,
            _getRangeData: areaSeries._getRangeData
        })
    },
    /*!********************************************!*\
      !*** ./Scripts/viz/series/range_series.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _extend = $.extend,
            _isDefined = commonUtils.isDefined,
            _map = __webpack_require__( /*! ../core/utils */ 442).map,
            _noop = $.noop,
            rangeCalculator = __webpack_require__( /*! ./helpers/range_data_calculator */ 475),
            scatterSeries = __webpack_require__( /*! ./scatter_series */ 474).chart,
            barSeries = __webpack_require__( /*! ./bar_series */ 478).chart.bar,
            areaSeries = __webpack_require__( /*! ./area_series */ 477).chart.area;
        exports.chart = {};
        var baseRangeSeries = {
            _beginUpdateData: _noop,
            areErrorBarsVisible: _noop,
            _createErrorBarGroup: _noop,
            _checkData: function(data) {
                return _isDefined(data.argument) && void 0 !== data.value && void 0 !== data.minValue
            },
            updateTemplateFieldNames: function() {
                var that = this,
                    options = that._options,
                    valueFields = that.getValueFields(),
                    name = that.name;
                options.rangeValue1Field = valueFields[0] + name;
                options.rangeValue2Field = valueFields[1] + name;
                options.tagField = that.getTagField() + name
            },
            _processRange: function(point, prevPoint) {
                rangeCalculator.processTwoValues(this, point, prevPoint, "value", "minValue")
            },
            _getRangeData: function(zoomArgs, calcIntervalFunction) {
                rangeCalculator.calculateRangeData(this, zoomArgs, calcIntervalFunction, "value", "minValue");
                rangeCalculator.addRangeSeriesLabelPaddings(this);
                return this._rangeData
            },
            _getPointData: function(data, options) {
                return {
                    tag: data[options.tagField || "tag"],
                    minValue: data[options.rangeValue1Field || "val1"],
                    value: data[options.rangeValue2Field || "val2"],
                    argument: data[options.argumentField || "arg"]
                }
            },
            _fusionPoints: function(fusionPoints, tick) {
                var calcMedianValue = scatterSeries._calcMedianValue,
                    value = calcMedianValue.call(this, fusionPoints, "value"),
                    minValue = calcMedianValue.call(this, fusionPoints, "minValue");
                if (null === value || null === minValue) {
                    value = minValue = null
                }
                return {
                    minValue: minValue,
                    value: value,
                    argument: tick,
                    tag: null
                }
            },
            getValueFields: function() {
                return [this._options.rangeValue1Field || "val1", this._options.rangeValue2Field || "val2"]
            }
        };
        exports.chart.rangebar = _extend({}, barSeries, baseRangeSeries);
        exports.chart.rangearea = _extend({}, areaSeries, {
            _drawPoint: function(options) {
                var point = options.point;
                if (point.isInVisibleArea()) {
                    point.clearVisibility();
                    point.draw(this._renderer, options.groups);
                    this._drawnPoints.push(point);
                    if (!point.visibleTopMarker) {
                        point.hideMarker("top")
                    }
                    if (!point.visibleBottomMarker) {
                        point.hideMarker("bottom")
                    }
                } else {
                    point.setInvisibility()
                }
            },
            _prepareSegment: function(points, rotated) {
                var processedPoints = this._processSinglePointsAreaSegment(points, rotated),
                    processedMinPointsCoords = _map(processedPoints, function(pt) {
                        return pt.getCoords(true)
                    });
                return {
                    line: processedPoints,
                    bottomLine: processedMinPointsCoords,
                    area: _map(processedPoints, function(pt) {
                        return pt.getCoords()
                    }).concat(processedMinPointsCoords.slice().reverse()),
                    singlePointSegment: processedPoints !== points
                }
            },
            _getDefaultSegment: function(segment) {
                var defaultSegment = areaSeries._getDefaultSegment.call(this, segment);
                defaultSegment.bottomLine = defaultSegment.line;
                return defaultSegment
            },
            _removeElement: function(element) {
                areaSeries._removeElement.call(this, element);
                element.bottomLine && element.bottomLine.remove()
            },
            _drawElement: function(segment, group) {
                var that = this,
                    drawnElement = areaSeries._drawElement.call(that, segment, group);
                drawnElement.bottomLine = that._bordersGroup && that._createBorderElement(segment.bottomLine, {
                    "stroke-width": that._styles.normal.border["stroke-width"]
                }).append(that._bordersGroup);
                return drawnElement
            },
            _applyStyle: function(style) {
                var that = this,
                    elementsGroup = that._elementsGroup,
                    bordersGroup = that._bordersGroup;
                elementsGroup && elementsGroup.attr(style.elements);
                bordersGroup && bordersGroup.attr(style.border);
                $.each(that._graphics || [], function(_, graphic) {
                    graphic.line && graphic.line.attr({
                        "stroke-width": style.border["stroke-width"]
                    });
                    graphic.bottomLine && graphic.bottomLine.attr({
                        "stroke-width": style.border["stroke-width"]
                    })
                })
            },
            _updateElement: function(element, segment, animate, animateParams, complete) {
                areaSeries._updateElement.call(this, element, segment, animate, animateParams, complete);
                var bottomLineParams = {
                        points: segment.bottomLine
                    },
                    bottomBorderElement = element.bottomLine;
                if (bottomBorderElement) {
                    animate ? bottomBorderElement.animate(bottomLineParams, animateParams) : bottomBorderElement.attr(bottomLineParams)
                }
            }
        }, baseRangeSeries)
    },
    /*!*********************************************!*\
      !*** ./Scripts/viz/series/bubble_series.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            lineSeries = __webpack_require__( /*! ./line_series */ 476).chart.line,
            scatterSeries = __webpack_require__( /*! ./scatter_series */ 474).chart,
            areaSeries = __webpack_require__( /*! ./area_series */ 477).chart.area,
            barSeries = __webpack_require__( /*! ./bar_series */ 478),
            chartBarSeries = barSeries.chart.bar,
            polarBarSeries = barSeries.polar.bar,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _extend = $.extend,
            _each = $.each,
            _noop = $.noop;
        exports.chart = {};
        exports.chart.bubble = _extend({}, scatterSeries, {
            _fillErrorBars: _noop,
            getErrorBarRangeCorrector: _noop,
            _calculateErrorBars: _noop,
            _getMainColor: chartBarSeries._getMainColor,
            _createPointStyles: chartBarSeries._createPointStyles,
            _createPattern: chartBarSeries._createPattern,
            _updatePointsVisibility: chartBarSeries._updatePointsVisibility,
            _getOptionsForPoint: chartBarSeries._getOptionsForPoint,
            _getSpecialColor: chartBarSeries._getSpecialColor,
            _applyMarkerClipRect: lineSeries._applyElementsClipRect,
            _parsePointStyle: polarBarSeries._parsePointStyle,
            _createLegendState: areaSeries._createLegendState,
            _setMarkerGroupSettings: polarBarSeries._setMarkerGroupSettings,
            areErrorBarsVisible: _noop,
            _createErrorBarGroup: _noop,
            _checkData: function(data) {
                return _isDefined(data.argument) && _isDefined(data.size) && void 0 !== data.value
            },
            _getPointData: function(data, options) {
                var pointData = scatterSeries._getPointData.call(this, data, options);
                pointData.size = data[options.sizeField || "size"];
                return pointData
            },
            _fusionPoints: function(fusionPoints, tick) {
                var calcMedianValue = scatterSeries._calcMedianValue;
                return {
                    size: calcMedianValue.call(this, fusionPoints, "size"),
                    value: calcMedianValue.call(this, fusionPoints, "value"),
                    argument: tick,
                    tag: null
                }
            },
            getValueFields: function() {
                return [this._options.valueField || "val"]
            },
            getSizeField: function() {
                return this._options.sizeField || "size"
            },
            updateTemplateFieldNames: function() {
                var that = this,
                    options = that._options,
                    name = that.name;
                options.valueField = that.getValueFields()[0] + name;
                options.sizeField = that.getSizeField() + name;
                options.tagField = that.getTagField() + name
            },
            _clearingAnimation: function(translators, drawComplete) {
                var that = this,
                    partitionDuration = .5,
                    lastPointIndex = that._drawnPoints.length - 1,
                    labelsGroup = that._labelsGroup;
                labelsGroup && labelsGroup.animate({
                    opacity: .001
                }, {
                    duration: that._defaultDuration,
                    partitionDuration: partitionDuration
                }, function() {
                    _each(that._drawnPoints || [], function(i, p) {
                        p.animate(i === lastPointIndex ? drawComplete : void 0, {
                            r: 0
                        }, partitionDuration)
                    })
                })
            },
            _animate: function() {
                var that = this,
                    lastPointIndex = that._drawnPoints.length - 1,
                    labelsGroup = that._labelsGroup,
                    labelAnimFunc = function() {
                        labelsGroup && labelsGroup.animate({
                            opacity: 1
                        }, {
                            duration: that._defaultDuration
                        })
                    };
                _each(that._drawnPoints || [], function(i, p) {
                    p.animate(i === lastPointIndex ? labelAnimFunc : void 0, {
                        r: p.bubbleSize,
                        translateX: p.x,
                        translateY: p.y
                    })
                })
            },
            _beginUpdateData: chartBarSeries._beginUpdateData
        })
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/series/pie_series.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            scatterSeries = __webpack_require__( /*! ./scatter_series */ 474),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            chartScatterSeries = scatterSeries.chart,
            barSeries = __webpack_require__( /*! ./bar_series */ 478).chart.bar,
            _extend = $.extend,
            _each = $.each,
            _noop = $.noop,
            _map = vizUtils.map,
            _isFinite = isFinite,
            _max = Math.max,
            INSIDE = "inside";
        exports.pie = _extend({}, barSeries, {
            _setGroupsSettings: chartScatterSeries._setGroupsSettings,
            _createErrorBarGroup: _noop,
            _drawPoint: function(options) {
                var point = options.point,
                    legendCallback = options.legendCallback;
                chartScatterSeries._drawPoint.call(this, options);
                !point.isVisible() && point.setInvisibility();
                legendCallback && point.isSelected() && legendCallback(point)("applySelected")
            },
            adjustLabels: function() {
                var maxLabelLength, that = this,
                    points = that._points || [],
                    labelsBBoxes = [];
                _each(points, function(_, point) {
                    if (point._label.isVisible()) {
                        point.setLabelTrackerData();
                        if (point._label.getLayoutOptions().position !== INSIDE) {
                            point.setLabelEllipsis();
                            labelsBBoxes.push(point._label.getBoundingRect().width)
                        }
                    }
                });
                if (labelsBBoxes.length) {
                    maxLabelLength = _max.apply(null, labelsBBoxes)
                }
                _each(points, function(_, point) {
                    if (point._label.isVisible() && point._label.getLayoutOptions().position !== INSIDE) {
                        point.setMaxLabelLength(maxLabelLength);
                        point.updateLabelCoord()
                    }
                })
            },
            _processRange: _noop,
            _applyElementsClipRect: _noop,
            getColor: _noop,
            areErrorBarsVisible: _noop,
            _prepareSeriesToDrawing: _noop,
            _endUpdateData: function() {
                this._arrayArguments = {};
                chartScatterSeries._prepareSeriesToDrawing.call(this)
            },
            drawLabelsWOPoints: function(translators) {
                var that = this,
                    options = that._options,
                    points = that._points || [];
                if (options.label.position === INSIDE) {
                    return false
                }
                that._labelsGroup.append(that._extGroups.labelsGroup);
                _each(points, function(_, point) {
                    point.drawLabel(translators)
                });
                return true
            },
            _getCreatingPointOptions: function(data) {
                return this._getPointOptions(data)
            },
            _updateOptions: function(options) {
                this.labelSpace = 0;
                this.innerRadius = "pie" === this.type ? 0 : options.innerRadius
            },
            _checkData: function(data) {
                var base = barSeries._checkData(data);
                return this._options.paintNullPoints ? base : base && null !== data.value
            },
            _createGroups: chartScatterSeries._createGroups,
            _setMarkerGroupSettings: function() {
                var that = this;
                that._markersGroup.attr({
                    "class": "dxc-markers"
                })
            },
            _getMainColor: function(data) {
                var that = this,
                    arr = that._arrayArguments || {},
                    argument = data.argument;
                arr[argument] = ++arr[argument] || 0;
                that._arrayArguments = arr;
                return that._options.mainSeriesColor(argument, arr[argument])
            },
            _getPointOptions: function(data) {
                return this._parsePointOptions(this._preparePointOptions(), this._options.label, data)
            },
            _getRangeData: function() {
                return this._rangeData
            },
            _getArrangeTotal: function(points) {
                var total = 0;
                _each(points, function(_, point) {
                    if (point.isVisible()) {
                        total += point.initialValue
                    }
                });
                return total
            },
            _createPointStyles: function(pointOptions, data) {
                var that = this,
                    mainColor = pointOptions.color || that._getMainColor(data),
                    specialMainColor = that._getSpecialColor(mainColor);
                return {
                    normal: that._parsePointStyle(pointOptions, mainColor, mainColor),
                    hover: that._parsePointStyle(pointOptions.hoverStyle, specialMainColor, mainColor),
                    selection: that._parsePointStyle(pointOptions.selectionStyle, specialMainColor, mainColor),
                    legendStyles: {
                        normal: that._createLegendState(pointOptions, mainColor),
                        hover: that._createLegendState(pointOptions.hoverStyle, specialMainColor),
                        selection: that._createLegendState(pointOptions.selectionStyle, specialMainColor)
                    }
                }
            },
            _getArrangeMinShownValue: function(points, total) {
                var minSegmentSize = this._options.minSegmentSize,
                    totalMinSegmentSize = 0,
                    totalNotMinValues = 0;
                total = total || points.length;
                _each(points, function(_, point) {
                    if (point.isVisible()) {
                        if (point.initialValue < minSegmentSize * total / 360) {
                            totalMinSegmentSize += minSegmentSize
                        } else {
                            totalNotMinValues += point.initialValue
                        }
                    }
                });
                return totalMinSegmentSize < 360 ? minSegmentSize * totalNotMinValues / (360 - totalMinSegmentSize) : 0
            },
            _applyArrangeCorrection: function(points, minShownValue, total) {
                var percent, options = this._options,
                    isClockWise = "anticlockwise" !== options.segmentsDirection,
                    shiftedAngle = _isFinite(options.startAngle) ? vizUtils.normalizeAngle(options.startAngle) : 0,
                    minSegmentSize = options.minSegmentSize,
                    correction = 0,
                    zeroTotalCorrection = 0;
                if (0 === total) {
                    total = points.filter(function(el) {
                        return el.isVisible()
                    }).length;
                    zeroTotalCorrection = 1
                }
                _each(isClockWise ? points : points.concat([]).reverse(), function(_, point) {
                    var updatedZeroValue, val = point.isVisible() ? zeroTotalCorrection || point.initialValue : 0;
                    if (minSegmentSize && point.isVisible() && val < minShownValue) {
                        updatedZeroValue = minShownValue
                    }
                    percent = val / total;
                    point.correctValue(correction, percent, zeroTotalCorrection + (updatedZeroValue || 0));
                    point.shiftedAngle = shiftedAngle;
                    correction += updatedZeroValue || val
                });
                this._rangeData = {
                    val: {
                        min: 0,
                        max: correction
                    }
                }
            },
            arrangePoints: function() {
                var minShownValue, total, points, that = this,
                    originalPoints = that._originalPoints || [],
                    minSegmentSize = that._options.minSegmentSize,
                    isAllPointsNegative = true,
                    i = 0,
                    len = originalPoints.length;
                while (i < len && isAllPointsNegative) {
                    isAllPointsNegative = originalPoints[i].value <= 0;
                    i++
                }
                points = that._originalPoints = that._points = _map(originalPoints, function(point) {
                    if (null === point.value || !isAllPointsNegative && point.value < 0) {
                        point.dispose();
                        return null
                    } else {
                        return point
                    }
                });
                total = that._getArrangeTotal(points);
                if (minSegmentSize) {
                    minShownValue = this._getArrangeMinShownValue(points, total)
                }
                that._applyArrangeCorrection(points, minShownValue, total)
            },
            correctPosition: function(correction) {
                var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
                debug.assert(correction, "correction was not passed");
                debug.assertParam(correction.centerX, "correction.centerX was not passed");
                debug.assertParam(correction.centerY, "correction.centerY was not passed");
                debug.assertParam(correction.radiusInner, "correction.radiusInner was not passed");
                debug.assertParam(correction.radiusOuter, "correction.radiusOuter was not passed");
                debug.assertParam(correction.canvas, "correction.canvas was not passed");
                _each(this._points, function(_, point) {
                    point.correctPosition(correction)
                });
                this.setVisibleArea(correction.canvas)
            },
            correctRadius: function(correction) {
                _each(this._points, function(_, point) {
                    point.correctRadius(correction)
                })
            },
            correctLabelRadius: function(labelRadius) {
                _each(this._points, function(_, point) {
                    point.correctLabelRadius(labelRadius)
                })
            },
            setVisibleArea: function(canvas) {
                this._visibleArea = {
                    minX: canvas.left,
                    maxX: canvas.width - canvas.right,
                    minY: canvas.top,
                    maxY: canvas.height - canvas.bottom
                }
            },
            _applyVisibleArea: _noop,
            _animate: function(firstDrawing) {
                var that = this,
                    index = 0,
                    timeThreshold = .2,
                    points = that._points,
                    pointsCount = points && points.length,
                    duration = 1 / (timeThreshold * (pointsCount - 1) + 1),
                    completeFunc = function() {
                        that._animateComplete()
                    },
                    animateP = function() {
                        points[index] && points[index].animate(index === pointsCount - 1 ? completeFunc : void 0, duration, stepFunc);
                        index++
                    },
                    stepFunc = function(_, progress) {
                        if (progress >= timeThreshold) {
                            this.step = null;
                            animateP()
                        }
                    };
                if (firstDrawing) {
                    animateP()
                } else {
                    $.each(points, function(i, p) {
                        p.animate(i === pointsCount - 1 ? completeFunc : void 0)
                    })
                }
            },
            getVisiblePoints: function() {
                return _map(this._points, function(p) {
                    return p.isVisible() ? p : null
                })
            },
            _beginUpdateData: function() {
                this._deletePatterns()
            }
        });
        exports.doughnut = exports.donut = exports.pie
    },
    /*!************************************************!*\
      !*** ./Scripts/viz/series/financial_series.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            scatterSeries = __webpack_require__( /*! ./scatter_series */ 474).chart,
            barSeries = __webpack_require__( /*! ./bar_series */ 478).chart.bar,
            rangeCalculator = __webpack_require__( /*! ./helpers/range_data_calculator */ 475),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            _extend = $.extend,
            _each = $.each,
            _noop = $.noop,
            DEFAULT_FINANCIAL_POINT_SIZE = 10;
        exports.stock = _extend({}, scatterSeries, {
            _animate: _noop,
            _applyMarkerClipRect: function(settings) {
                settings.clipId = this._forceClipping ? this._paneClipRectID : this._widePaneClipRectID
            },
            _updatePointsVisibility: barSeries._updatePointsVisibility,
            _getOptionsForPoint: barSeries._getOptionsForPoint,
            getErrorBarRangeCorrector: _noop,
            _createErrorBarGroup: _noop,
            areErrorBarsVisible: _noop,
            _createGroups: scatterSeries._createGroups,
            _setMarkerGroupSettings: function() {
                var that = this,
                    markersGroup = that._markersGroup,
                    styles = that._createPointStyles(that._getMarkerGroupOptions()),
                    defaultStyle = _extend(styles.normal, {
                        "class": "default-markers"
                    }),
                    defaultPositiveStyle = _extend(styles.positive.normal, {
                        "class": "default-positive-markers"
                    }),
                    reductionStyle = _extend(styles.reduction.normal, {
                        "class": "reduction-markers"
                    }),
                    reductionPositiveStyle = _extend(styles.reductionPositive.normal, {
                        "class": "reduction-positive-markers"
                    }),
                    markerSettings = {
                        "class": "dxc-markers"
                    };
                that._applyMarkerClipRect(markerSettings);
                markersGroup.attr(markerSettings);
                that._createGroup("defaultMarkersGroup", markersGroup, markersGroup, defaultStyle);
                that._createGroup("reductionMarkersGroup", markersGroup, markersGroup, reductionStyle);
                that._createGroup("defaultPositiveMarkersGroup", markersGroup, markersGroup, defaultPositiveStyle);
                that._createGroup("reductionPositiveMarkersGroup", markersGroup, markersGroup, reductionPositiveStyle)
            },
            _setGroupsSettings: function() {
                scatterSeries._setGroupsSettings.call(this, false)
            },
            _clearingAnimation: function(translators, drawComplete) {
                drawComplete()
            },
            _getCreatingPointOptions: function() {
                var defaultPointOptions, that = this,
                    creatingPointOptions = that._predefinedPointOptions;
                if (!creatingPointOptions) {
                    defaultPointOptions = this._getPointOptions();
                    that._predefinedPointOptions = creatingPointOptions = _extend(true, {
                        styles: {}
                    }, defaultPointOptions);
                    creatingPointOptions.styles.normal = creatingPointOptions.styles.positive.normal = creatingPointOptions.styles.reduction.normal = creatingPointOptions.styles.reductionPositive.normal = {
                        "stroke-width": defaultPointOptions.styles && defaultPointOptions.styles.normal && defaultPointOptions.styles.normal["stroke-width"]
                    }
                }
                return creatingPointOptions
            },
            _checkData: function(data) {
                return _isDefined(data.argument) && void 0 !== data.highValue && void 0 !== data.lowValue && void 0 !== data.openValue && void 0 !== data.closeValue
            },
            _processRange: function(point, prevPoint) {
                rangeCalculator.processTwoValues(this, point, prevPoint, "highValue", "lowValue")
            },
            _getRangeData: function(zoomArgs, calcIntervalFunction) {
                rangeCalculator.calculateRangeData(this, zoomArgs, calcIntervalFunction, "highValue", "lowValue");
                rangeCalculator.addRangeSeriesLabelPaddings(this);
                return this._rangeData
            },
            _getPointData: function(data, options) {
                var level, reductionValue, that = this,
                    openValueField = options.openValueField || "open",
                    closeValueField = options.closeValueField || "close",
                    highValueField = options.highValueField || "high",
                    lowValueField = options.lowValueField || "low";
                that.level = options.reduction.level;
                switch (_normalizeEnum(that.level)) {
                    case "open":
                        level = openValueField;
                        break;
                    case "high":
                        level = highValueField;
                        break;
                    case "low":
                        level = lowValueField;
                        break;
                    default:
                        level = closeValueField;
                        that.level = "close"
                }
                reductionValue = data[level];
                return {
                    argument: data[options.argumentField || "date"],
                    highValue: data[highValueField],
                    lowValue: data[lowValueField],
                    closeValue: data[closeValueField],
                    openValue: data[openValueField],
                    reductionValue: reductionValue,
                    tag: data[options.tagField || "tag"],
                    isReduction: that._checkReduction(reductionValue)
                }
            },
            _parsePointStyle: function(style, defaultColor, innerColor) {
                return {
                    stroke: style.color || defaultColor,
                    "stroke-width": style.width,
                    fill: style.color || innerColor
                }
            },
            updateTemplateFieldNames: function() {
                var that = this,
                    options = that._options,
                    valueFields = that.getValueFields(),
                    name = that.name;
                options.openValueField = valueFields[0] + name;
                options.highValueField = valueFields[1] + name;
                options.lowValueField = valueFields[2] + name;
                options.closeValueField = valueFields[3] + name;
                options.tagField = that.getTagField() + name
            },
            _getDefaultStyle: function(options) {
                var that = this,
                    mainPointColor = options.color || that._options.mainSeriesColor;
                return {
                    normal: that._parsePointStyle(options, mainPointColor, mainPointColor),
                    hover: that._parsePointStyle(options.hoverStyle, mainPointColor, mainPointColor),
                    selection: that._parsePointStyle(options.selectionStyle, mainPointColor, mainPointColor)
                }
            },
            _getReductionStyle: function(options) {
                var that = this,
                    reductionColor = options.reduction.color;
                return {
                    normal: that._parsePointStyle({
                        color: reductionColor,
                        width: options.width,
                        hatching: options.hatching
                    }, reductionColor, reductionColor),
                    hover: that._parsePointStyle(options.hoverStyle, reductionColor, reductionColor),
                    selection: that._parsePointStyle(options.selectionStyle, reductionColor, reductionColor)
                }
            },
            _createPointStyles: function(pointOptions) {
                var positiveStyle, reductionStyle, reductionPositiveStyle, that = this,
                    innerColor = that._options.innerColor,
                    styles = that._getDefaultStyle(pointOptions);
                positiveStyle = _extend(true, {}, styles);
                reductionStyle = that._getReductionStyle(pointOptions);
                reductionPositiveStyle = _extend(true, {}, reductionStyle);
                positiveStyle.normal.fill = positiveStyle.hover.fill = positiveStyle.selection.fill = innerColor;
                reductionPositiveStyle.normal.fill = reductionPositiveStyle.hover.fill = reductionPositiveStyle.selection.fill = innerColor;
                styles.positive = positiveStyle;
                styles.reduction = reductionStyle;
                styles.reductionPositive = reductionPositiveStyle;
                return styles
            },
            _endUpdateData: function() {
                delete this.prevLevelValue;
                delete this._predefinedPointOptions
            },
            _checkReduction: function(value) {
                var that = this,
                    result = false;
                if (null !== value) {
                    if (_isDefined(that.prevLevelValue)) {
                        result = value < that.prevLevelValue
                    }
                    that.prevLevelValue = value
                }
                return result
            },
            _fusionPoints: function(fusionPoints, tick) {
                var reductionLevel, openValue, closeValue, fusedPointData = {},
                    highValue = -(1 / 0),
                    lowValue = +(1 / 0);
                if (!fusionPoints.length) {
                    return {}
                }
                _each(fusionPoints, function(_, point) {
                    if (!point.hasValue()) {
                        return
                    }
                    highValue = Math.max(highValue, point.highValue);
                    lowValue = Math.min(lowValue, point.lowValue);
                    openValue = void 0 !== openValue ? openValue : point.openValue;
                    closeValue = void 0 !== point.closeValue ? point.closeValue : closeValue
                });
                fusedPointData.argument = tick;
                fusedPointData.openValue = openValue;
                fusedPointData.closeValue = closeValue;
                fusedPointData.highValue = highValue;
                fusedPointData.lowValue = lowValue;
                fusedPointData.tag = null;
                switch (_normalizeEnum(this.level)) {
                    case "open":
                        reductionLevel = openValue;
                        break;
                    case "high":
                        reductionLevel = highValue;
                        break;
                    case "low":
                        reductionLevel = lowValue;
                        break;
                    default:
                        reductionLevel = closeValue
                }
                fusedPointData.reductionValue = reductionLevel;
                fusedPointData.isReduction = this._checkReduction(reductionLevel);
                return fusedPointData
            },
            _getPointSize: function() {
                return DEFAULT_FINANCIAL_POINT_SIZE
            },
            getValueFields: function() {
                var options = this._options;
                return [options.openValueField || "open", options.highValueField || "high", options.lowValueField || "low", options.closeValueField || "close"]
            },
            getArgumentField: function() {
                return this._options.argumentField || "date"
            },
            _beginUpdateData: _noop
        });
        exports.candlestick = _extend({}, exports.stock, {
            _createPattern: barSeries._createPattern,
            _beginUpdateData: barSeries._beginUpdateData,
            _parsePointStyle: function(style, defaultColor, innerColor) {
                var color = this._createPattern(style.color || innerColor, style.hatching),
                    base = exports.stock._parsePointStyle.call(this, style, defaultColor, color);
                base.fill = color;
                return base
            }
        })
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/series/stacked_series.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            areaSeries = __webpack_require__( /*! ./area_series */ 477).chart,
            chartAreaSeries = areaSeries.area,
            barSeries = __webpack_require__( /*! ./bar_series */ 478),
            chartBarSeries = barSeries.chart.bar,
            lineSeries = __webpack_require__( /*! ./line_series */ 476).chart,
            rangeCalculator = __webpack_require__( /*! ./helpers/range_data_calculator */ 475),
            _extend = $.extend,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            _noop = $.noop,
            baseStackedSeries = {
                _processRange: _noop,
                getErrorBarRangeCorrector: _noop,
                _fillErrorBars: _noop,
                _calculateErrorBars: _noop,
                _processStackedRange: function() {
                    var prevPoint, that = this;
                    that._resetRangeData();
                    $.each(that.getAllPoints(), function(i, p) {
                        rangeCalculator.processRange(that, p, prevPoint);
                        prevPoint = p
                    })
                },
                _getRangeData: function() {
                    this._processStackedRange();
                    return chartAreaSeries._getRangeData.apply(this, arguments)
                }
            },
            baseFullStackedSeries = _extend({}, baseStackedSeries, {
                _getRangeData: function(zoomArgs, calcIntervalFunction) {
                    var that = this;
                    that._processStackedRange();
                    rangeCalculator.calculateRangeData(that, zoomArgs, calcIntervalFunction);
                    rangeCalculator.addLabelPaddings(that);
                    rangeCalculator.processFullStackedRange(that);
                    rangeCalculator.calculateRangeMinValue(that, zoomArgs);
                    return that._rangeData
                },
                isFullStackedSeries: function() {
                    return true
                }
            });
        exports.chart = {};
        exports.polar = {};
        exports.chart.stackedline = _extend({}, lineSeries.line, baseStackedSeries, {
            _getRangeData: function() {
                this._processStackedRange();
                return lineSeries.line._getRangeData.apply(this, arguments)
            }
        });
        exports.chart.stackedspline = _extend({}, lineSeries.spline, baseStackedSeries, {
            _getRangeData: exports.chart.stackedline._getRangeData
        });
        exports.chart.fullstackedline = _extend({}, lineSeries.line, baseFullStackedSeries, {
            _getRangeData: function(zoomArgs, calcIntervalFunction) {
                var that = this;
                that._processStackedRange();
                rangeCalculator.calculateRangeData(that, zoomArgs, calcIntervalFunction);
                rangeCalculator.addLabelPaddings(that);
                rangeCalculator.processFullStackedRange(that);
                return that._rangeData
            }
        });
        exports.chart.fullstackedspline = _extend({}, lineSeries.spline, baseFullStackedSeries, {
            _getRangeData: exports.chart.fullstackedline._getRangeData
        });
        exports.chart.stackedbar = _extend({}, chartBarSeries, baseStackedSeries, {
            _getRangeData: function() {
                this._processStackedRange();
                return chartBarSeries._getRangeData.apply(this, arguments)
            }
        });
        exports.chart.fullstackedbar = _extend({}, chartBarSeries, baseFullStackedSeries, {
            _getRangeData: function() {
                var rangeData = baseFullStackedSeries._getRangeData.apply(this, arguments);
                rangeData.arg.stick = false;
                return rangeData
            }
        });

        function clonePoint(point, value, minValue, position) {
            point = objectUtils.clone(point);
            point.value = value;
            point.minValue = minValue;
            point.translate();
            point.argument = point.argument + position;
            return point
        }

        function preparePointsForStackedAreaSegment(points) {
            var p, array, i = 0,
                result = [],
                len = points.length;
            while (i < len) {
                p = points[i];
                array = [p];
                if (p.leftHole) {
                    array = [clonePoint(p, p.leftHole, p.minLeftHole, "left"), p]
                }
                if (p.rightHole) {
                    array.push(clonePoint(p, p.rightHole, p.minRightHole, "right"))
                }
                result.push(array);
                i++
            }
            return [].concat.apply([], result)
        }
        exports.chart.stackedarea = _extend({}, chartAreaSeries, baseStackedSeries, {
            _prepareSegment: function(points, rotated) {
                return chartAreaSeries._prepareSegment.call(this, preparePointsForStackedAreaSegment(points, this._prevSeries), rotated)
            },
            _appendInGroup: function() {
                this._group.append(this._extGroups.seriesGroup).toBackground()
            }
        });

        function getPointsByArgFromPrevSeries(prevSeries, argument) {
            var result;
            while (!result && prevSeries) {
                result = prevSeries._segmentByArg && prevSeries._segmentByArg[argument];
                prevSeries = prevSeries._prevSeries
            }
            return result
        }
        exports.chart.stackedsplinearea = _extend({}, areaSeries.splinearea, baseStackedSeries, {
            _prepareSegment: function(points, rotated) {
                var areaSegment, that = this;
                points = preparePointsForStackedAreaSegment(points, that._prevSeries);
                if (!this._prevSeries || 1 === points.length) {
                    areaSegment = areaSeries.splinearea._prepareSegment.call(this, points, rotated)
                } else {
                    var fwPoints = lineSeries.spline._calculateBezierPoints(points, rotated),
                        bwPoints = vizUtils.map(points, function(p) {
                            var point = p.getCoords(true);
                            point.argument = p.argument;
                            return point
                        }),
                        prevSeriesFwPoints = [],
                        pointByArg = {},
                        i = 0,
                        len = that._prevSeries._segments.length;
                    while (i < len) {
                        prevSeriesFwPoints = prevSeriesFwPoints.concat(that._prevSeries._segments[i].line);
                        i++
                    }
                    $.each(prevSeriesFwPoints, function(_, p) {
                        if (null !== p.argument) {
                            var argument = p.argument.valueOf();
                            if (!pointByArg[argument]) {
                                pointByArg[argument] = [p]
                            } else {
                                pointByArg[argument].push(p)
                            }
                        }
                    });
                    that._prevSeries._segmentByArg = pointByArg;
                    bwPoints = lineSeries.spline._calculateBezierPoints(bwPoints, rotated);
                    $.each(bwPoints, function(i, p) {
                        var prevSeriesPoints, argument = p.argument.valueOf();
                        if (i % 3 === 0) {
                            prevSeriesPoints = pointByArg[argument] || getPointsByArgFromPrevSeries(that._prevSeries, argument);
                            if (prevSeriesPoints) {
                                bwPoints[i - 1] && prevSeriesPoints[0] && (bwPoints[i - 1] = prevSeriesPoints[0]);
                                bwPoints[i + 1] && (bwPoints[i + 1] = prevSeriesPoints[2] || p)
                            }
                        }
                    });
                    areaSegment = {
                        line: fwPoints,
                        area: fwPoints.concat(bwPoints.reverse())
                    };
                    that._areaPointsToSplineAreaPoints(areaSegment.area)
                }
                return areaSegment
            },
            _appendInGroup: exports.chart.stackedarea._appendInGroup
        });
        exports.chart.fullstackedarea = _extend({}, chartAreaSeries, baseFullStackedSeries, {
            _prepareSegment: exports.chart.stackedarea._prepareSegment,
            _appendInGroup: exports.chart.stackedarea._appendInGroup
        });
        exports.chart.fullstackedsplinearea = _extend({}, areaSeries.splinearea, baseFullStackedSeries, {
            _prepareSegment: exports.chart.stackedsplinearea._prepareSegment,
            _appendInGroup: exports.chart.stackedarea._appendInGroup
        });
        exports.polar.stackedbar = _extend({}, barSeries.polar.bar, baseStackedSeries, {
            _getRangeData: function() {
                this._processStackedRange();
                return barSeries.polar.bar._getRangeData.apply(this, arguments)
            }
        })
    },
    /*!*******************************************************!*\
      !*** ./Scripts/viz/components/chart_theme_manager.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            rendererModule = __webpack_require__( /*! ../core/renderers/renderer */ 451),
            isIE8 = !rendererModule.isSvg(),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            BaseThemeManager = __webpack_require__( /*! ../core/base_theme_manager */ 485).BaseThemeManager,
            _isString = commonUtils.isString,
            _isDefined = commonUtils.isDefined,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            FONT = "font",
            COMMON_AXIS_SETTINGS = "commonAxisSettings",
            PIE_FONT_FIELDS = ["legend." + FONT, "title." + FONT, "title.subtitle." + FONT, "tooltip." + FONT, "loadingIndicator." + FONT, "export." + FONT, "commonSeriesSettings.label." + FONT],
            POLAR_FONT_FIELDS = PIE_FONT_FIELDS.concat([COMMON_AXIS_SETTINGS + ".label." + FONT, COMMON_AXIS_SETTINGS + ".title." + FONT]),
            CHART_FONT_FIELDS = POLAR_FONT_FIELDS.concat(["crosshair.label." + FONT]),
            chartToFontFieldsMap = {
                pie: PIE_FONT_FIELDS,
                chart: CHART_FONT_FIELDS,
                polar: POLAR_FONT_FIELDS
            };
        var ThemeManager = BaseThemeManager.inherit(function() {
            var ctor = function(options, themeGroupName) {
                var that = this;
                that.callBase.apply(that, arguments);
                options = options || {};
                that._userOptions = options;
                that._mergeAxisTitleOptions = [];
                that._multiPieColors = {};
                that._themeSection = themeGroupName;
                that._fontFields = chartToFontFieldsMap[themeGroupName];
                that._IE8 = isIE8;
                that._callback = $.noop
            };
            var dispose = function() {
                var that = this;
                that.palette && that.palette.dispose();
                that.palette = that._userOptions = that._mergedSettings = that._multiPieColors = null;
                return that.callBase.apply(that, arguments)
            };
            var resetPalette = function() {
                this.palette.reset();
                this._multiPieColors = {}
            };
            var updatePalette = function(palette) {
                this.palette = this.createPalette(palette, {
                    useHighlight: true
                })
            };
            var processTitleOptions = function(options) {
                return _isString(options) ? {
                    text: options
                } : options
            };
            var processAxisOptions = function(axisOptions) {
                if (!axisOptions) {
                    return
                }
                axisOptions = $.extend(true, {}, axisOptions);
                axisOptions.title = processTitleOptions(axisOptions.title);
                if ("logarithmic" === axisOptions.type && axisOptions.logarithmBase <= 0 || axisOptions.logarithmBase && !$.isNumeric(axisOptions.logarithmBase)) {
                    axisOptions.logarithmBase = void 0;
                    axisOptions.logarithmBaseError = true
                }
                if (axisOptions.label) {
                    if (axisOptions.label.alignment) {
                        axisOptions.label.userAlignment = true
                    }
                    if (_isString(axisOptions.label.overlappingBehavior)) {
                        axisOptions.label.overlappingBehavior = {
                            mode: axisOptions.label.overlappingBehavior
                        }
                    }
                    if (!axisOptions.label.overlappingBehavior || !axisOptions.label.overlappingBehavior.mode) {
                        axisOptions.label.overlappingBehavior = axisOptions.label.overlappingBehavior || {}
                    }
                }
                return axisOptions
            };
            var applyParticularAxisOptions = function(name, userOptions, rotated) {
                var theme = this._theme,
                    position = !(rotated ^ "valueAxis" === name) ? "horizontalAxis" : "verticalAxis",
                    commonAxisSettings = processAxisOptions(this._userOptions.commonAxisSettings, name);
                return $.extend(true, {}, theme.commonAxisSettings, theme[position], theme[name], commonAxisSettings, processAxisOptions(userOptions, name))
            };
            var mergeOptions = function(name, userOptions) {
                userOptions = userOptions || this._userOptions[name];
                var theme = this._theme[name],
                    result = this._mergedSettings[name];
                if (result) {
                    return result
                }
                if ($.isPlainObject(theme) && $.isPlainObject(userOptions)) {
                    result = $.extend(true, {}, theme, userOptions)
                } else {
                    result = _isDefined(userOptions) ? userOptions : theme
                }
                this._mergedSettings[name] = result;
                return result
            };
            var applyParticularTheme = {
                base: mergeOptions,
                argumentAxis: applyParticularAxisOptions,
                valueAxisRangeSelector: function() {
                    return mergeOptions.call(this, "valueAxis")
                },
                valueAxis: applyParticularAxisOptions,
                series: function(name, userOptions) {
                    var settings, mainSeriesColor, seriesVisibility, that = this,
                        theme = that._theme,
                        userCommonSettings = that._userOptions.commonSeriesSettings || {},
                        themeCommonSettings = theme.commonSeriesSettings,
                        widgetType = that._themeSection.split(".").slice(-1)[0],
                        type = _normalizeEnum(userOptions.type || userCommonSettings.type || themeCommonSettings.type || "pie" === widgetType && theme.type),
                        palette = that.palette,
                        isBar = ~type.indexOf("bar"),
                        isLine = ~type.indexOf("line"),
                        isArea = ~type.indexOf("area"),
                        isBubble = "bubble" === type,
                        resolveLabelsOverlapping = that.getOptions("resolveLabelsOverlapping"),
                        resolveLabelOverlapping = that.getOptions("resolveLabelOverlapping"),
                        containerBackgroundColor = that.getOptions("containerBackgroundColor");
                    if (isBar || isBubble) {
                        userOptions = $.extend(true, {}, userCommonSettings, userCommonSettings[type], userOptions);
                        seriesVisibility = userOptions.visible;
                        userCommonSettings = {
                            type: {}
                        };
                        $.extend(true, userOptions, userOptions.point);
                        userOptions.visible = seriesVisibility
                    }
                    settings = $.extend(true, {}, themeCommonSettings, themeCommonSettings[type], userCommonSettings, userCommonSettings[type], userOptions);
                    settings.type = type;
                    settings.widgetType = widgetType;
                    settings.containerBackgroundColor = containerBackgroundColor;
                    if ("pie" !== widgetType) {
                        mainSeriesColor = settings.color || palette.getNextColor()
                    } else {
                        mainSeriesColor = function(argument, index) {
                            var cat = argument + index;
                            if (!that._multiPieColors[cat]) {
                                that._multiPieColors[cat] = palette.getNextColor()
                            }
                            return that._multiPieColors[cat]
                        }
                    }
                    settings.mainSeriesColor = mainSeriesColor;
                    settings._IE8 = isIE8;
                    settings.resolveLabelOverlapping = resolveLabelOverlapping;
                    settings.resolveLabelsOverlapping = resolveLabelsOverlapping;
                    if (settings.label && (isLine || isArea && "rangearea" !== type || "scatter" === type)) {
                        settings.label.position = "outside"
                    }
                    return settings
                },
                animation: function(name) {
                    var userOptions = this._userOptions[name];
                    userOptions = $.isPlainObject(userOptions) ? userOptions : _isDefined(userOptions) ? {
                        enabled: !!userOptions
                    } : {};
                    return mergeOptions.call(this, name, userOptions)
                }
            };
            return {
                _themeSection: "chart",
                ctor: ctor,
                dispose: dispose,
                resetPalette: resetPalette,
                getOptions: function(name) {
                    return (applyParticularTheme[name] || applyParticularTheme.base).apply(this, arguments)
                },
                refresh: function() {
                    this._mergedSettings = {};
                    return this.callBase.apply(this, arguments)
                },
                _initializeTheme: function() {
                    var that = this;
                    that.callBase.apply(that, arguments);
                    that.updatePalette(that.getOptions("palette"))
                },
                resetOptions: function(name) {
                    this._mergedSettings[name] = null
                },
                update: function(options) {
                    this._userOptions = options
                },
                updatePalette: updatePalette
            }
        }());
        exports.ThemeManager = ThemeManager;
        exports._setIE8Mode = function(isIE8Mode) {
            var initIEMode = isIE8;
            isIE8 = isIE8Mode;
            return initIEMode
        };
        exports._resetIE8Mode = function(initIEMode) {
            isIE8 = initIEMode
        }
    },
    /*!************************************************!*\
      !*** ./Scripts/viz/core/base_theme_manager.js ***!
      \************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            Class = __webpack_require__( /*! ../../core/class */ 20),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            paletteModule = __webpack_require__( /*! ../palette */ 445),
            _isString = commonUtils.isString,
            _parseScalar = __webpack_require__( /*! ./utils */ 442).parseScalar,
            themeModule = __webpack_require__( /*! ../themes */ 441),
            _findTheme = themeModule.findTheme,
            _addCacheItem = themeModule.addCacheItem,
            _removeCacheItem = themeModule.removeCacheItem,
            _extend = $.extend,
            _each = $.each;
        __webpack_require__( /*! ./default */ 486);
        __webpack_require__( /*! ./ios */ 487);
        __webpack_require__( /*! ./android */ 488);
        __webpack_require__( /*! ./win */ 489);

        function getThemePart(theme, path) {
            var _theme = theme;
            path && _each(path.split("."), function(_, pathItem) {
                return _theme = _theme[pathItem]
            });
            return _theme
        }
        exports.BaseThemeManager = Class.inherit({
            ctor: function() {
                _addCacheItem(this)
            },
            dispose: function() {
                var that = this;
                _removeCacheItem(that);
                that._callback = that._theme = that._font = null;
                return that
            },
            setCallback: function(callback) {
                this._callback = callback;
                return this
            },
            setTheme: function(theme, rtl) {
                this._current = theme;
                this._rtl = rtl;
                return this.refresh()
            },
            refresh: function() {
                var that = this,
                    current = that._current || {},
                    theme = _findTheme(current.name || current);
                that._themeName = theme.name;
                that._defaultPalette = theme.defaultPalette;
                that._font = _extend({}, theme.font, current.font);
                that._themeSection && _each(that._themeSection.split("."), function(_, path) {
                    theme = _extend(true, {}, theme[path], that._IE8 ? theme[path + "IE8"] : {})
                });
                that._theme = _extend(true, {}, theme, _isString(current) ? {} : current);
                that._initializeTheme();
                if (_parseScalar(that._rtl, that._theme.rtlEnabled)) {
                    _extend(true, that._theme, that._theme._rtl)
                }
                that._callback();
                return that
            },
            theme: function(path) {
                return getThemePart(this._theme, path)
            },
            themeName: function() {
                return this._themeName
            },
            createPalette: function(palette, options) {
                return new paletteModule.Palette(palette || this._defaultPalette, options)
            },
            createDiscretePalette: function(palette, count) {
                return new paletteModule.DiscretePalette(palette || this._defaultPalette, count)
            },
            createGradientPalette: function(palette) {
                return new paletteModule.GradientPalette(palette || this._defaultPalette)
            },
            _initializeTheme: function() {
                var that = this;
                _each(that._fontFields || [], function(_, path) {
                    that._initializeFont(getThemePart(that._theme, path))
                })
            },
            _initializeFont: function(font) {
                _extend(font, this._font, _extend({}, font))
            }
        })
    },
    /*!*************************************!*\
      !*** ./Scripts/viz/core/default.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var WHITE = "#ffffff",
            BLACK = "#000000",
            LIGHT_GREY = "#d3d3d3",
            GREY_GREEN = "#303030",
            SOME_GREY = "#2b2b2b",
            RED = "#ff0000",
            PRIMARY_TITLE_COLOR = "#232323",
            SECONDARY_TITLE_COLOR = "#767676",
            CONTRAST_ACTIVE = "#cf00da",
            MARKER_COLOR = "#f8ca00",
            TARGET_COLOR = "#8e8e8e",
            POSITIVE_COLOR = "#b8b8b8",
            LINE_COLOR = "#c7c7c7",
            AREA_LAYER_COLOR = "#686868",
            RANGE_COLOR = "#b5b5b5",
            NONE = "none",
            SOLID = "solid",
            TOP = "top",
            RIGHT = "right",
            BOTTOM = "bottom",
            LEFT = "left",
            CENTER = "center",
            INSIDE = "inside",
            OUTSIDE = "outside",
            themeModule = __webpack_require__( /*! ../themes */ 441),
            registerTheme = themeModule.registerTheme,
            registerThemeAlias = themeModule.registerThemeAlias;
        registerTheme({
            name: "generic.light",
            font: {
                color: SECONDARY_TITLE_COLOR,
                family: "'Segoe UI', 'Helvetica Neue', 'Trebuchet MS', Verdana",
                weight: 400,
                size: 12,
                cursor: "default"
            },
            redrawOnResize: true,
            backgroundColor: WHITE,
            primaryTitleColor: PRIMARY_TITLE_COLOR,
            secondaryTitleColor: SECONDARY_TITLE_COLOR,
            axisColor: LIGHT_GREY,
            axisLabelColor: SECONDARY_TITLE_COLOR,
            title: {
                backgroundColor: WHITE,
                font: {
                    size: 28,
                    family: "'Segoe UI Light', 'Helvetica Neue Light', 'Segoe UI', 'Helvetica Neue', 'Trebuchet MS', Verdana",
                    weight: 200
                },
                subtitle: {
                    font: {
                        size: 16
                    }
                }
            },
            loadingIndicator: {
                text: "Loading..."
            },
            "export": {
                backgroundColor: WHITE,
                font: {
                    size: 14,
                    color: PRIMARY_TITLE_COLOR,
                    weight: 400
                },
                button: {
                    "default": {
                        color: "#333",
                        borderColor: "#ddd",
                        backgroundColor: WHITE
                    },
                    hover: {
                        color: "#333",
                        borderColor: "#bebebe",
                        backgroundColor: "#e6e6e6"
                    },
                    focus: {
                        color: BLACK,
                        borderColor: "#9d9d9d",
                        backgroundColor: "#e6e6e6"
                    },
                    active: {
                        color: "#333",
                        borderColor: "#9d9d9d",
                        backgroundColor: "#d4d4d4"
                    }
                },
                shadowColor: LIGHT_GREY
            },
            tooltip: {
                enabled: false,
                border: {
                    width: 1,
                    color: LIGHT_GREY,
                    dashStyle: SOLID,
                    visible: true
                },
                font: {
                    color: PRIMARY_TITLE_COLOR
                },
                color: WHITE,
                arrowLength: 10,
                paddingLeftRight: 18,
                paddingTopBottom: 15,
                shared: false,
                location: CENTER,
                shadow: {
                    opacity: .4,
                    offsetX: 0,
                    offsetY: 4,
                    blur: 2,
                    color: BLACK
                }
            },
            legend: {
                hoverMode: "includePoints",
                verticalAlignment: TOP,
                horizontalAlignment: RIGHT,
                position: OUTSIDE,
                visible: true,
                margin: 10,
                markerSize: 12,
                border: {
                    visible: false,
                    width: 1,
                    cornerRadius: 0,
                    dashStyle: SOLID
                },
                paddingLeftRight: 20,
                paddingTopBottom: 15,
                columnCount: 0,
                rowCount: 0,
                columnItemSpacing: 20,
                rowItemSpacing: 8
            },
            "chart:common": {
                animation: {
                    enabled: true,
                    duration: 1e3,
                    easing: "easeOutCubic",
                    maxPointCountSupported: 300
                },
                commonSeriesSettings: {
                    border: {
                        visible: false,
                        width: 2
                    },
                    showInLegend: true,
                    visible: true,
                    hoverMode: "nearestPoint",
                    selectionMode: "includePoints",
                    hoverStyle: {
                        hatching: {
                            direction: RIGHT,
                            width: 2,
                            step: 6,
                            opacity: .75
                        },
                        border: {
                            visible: false,
                            width: 3
                        }
                    },
                    selectionStyle: {
                        hatching: {
                            direction: RIGHT,
                            width: 2,
                            step: 6,
                            opacity: .5
                        },
                        border: {
                            visible: false,
                            width: 3
                        }
                    },
                    valueErrorBar: {
                        displayMode: "auto",
                        value: 1,
                        color: BLACK,
                        lineWidth: 2,
                        edgeLength: 8
                    },
                    label: {
                        visible: false,
                        alignment: CENTER,
                        rotationAngle: 0,
                        horizontalOffset: 0,
                        verticalOffset: 0,
                        radialOffset: 0,
                        showForZeroValues: true,
                        customizeText: void 0,
                        maxLabelCount: void 0,
                        position: OUTSIDE,
                        font: {
                            color: WHITE
                        },
                        border: {
                            visible: false,
                            width: 1,
                            color: LIGHT_GREY,
                            dashStyle: SOLID
                        },
                        connector: {
                            visible: false,
                            width: 1
                        }
                    }
                },
                seriesSelectionMode: "single",
                pointSelectionMode: "single",
                equalRowHeight: true,
                dataPrepareSettings: {
                    checkTypeForAllData: false,
                    convertToAxisDataType: true,
                    sortingMethod: true
                },
                title: {
                    margin: 10
                },
                adaptiveLayout: {
                    width: 80,
                    height: 80,
                    keepLabels: true
                },
                _rtl: {
                    legend: {
                        itemTextPosition: LEFT
                    }
                },
                resolveLabelOverlapping: NONE
            },
            "chart:common:axis": {
                visible: false,
                setTicksAtUnitBeginning: true,
                valueMarginsEnabled: true,
                placeholderSize: null,
                logarithmBase: 10,
                discreteAxisDivisionMode: "betweenLabels",
                width: 1,
                label: {
                    visible: true
                },
                grid: {
                    visible: false,
                    width: 1
                },
                minorGrid: {
                    visible: false,
                    width: 1,
                    opacity: .3
                },
                tick: {
                    visible: false,
                    width: 1,
                    length: 8
                },
                minorTick: {
                    visible: false,
                    width: 1,
                    opacity: .3,
                    length: 8
                },
                stripStyle: {
                    paddingLeftRight: 10,
                    paddingTopBottom: 5
                },
                constantLineStyle: {
                    width: 1,
                    color: BLACK,
                    dashStyle: SOLID,
                    label: {
                        visible: true,
                        position: INSIDE
                    }
                },
                marker: {
                    label: {}
                }
            },
            chart: {
                commonSeriesSettings: {
                    type: "line",
                    stack: "default",
                    point: {
                        visible: true,
                        symbol: "circle",
                        size: 12,
                        border: {
                            visible: false,
                            width: 1
                        },
                        hoverMode: "onlyPoint",
                        selectionMode: "onlyPoint",
                        hoverStyle: {
                            border: {
                                visible: true,
                                width: 4
                            },
                            size: 12
                        },
                        selectionStyle: {
                            border: {
                                visible: true,
                                width: 4
                            },
                            size: 12
                        }
                    },
                    scatter: {},
                    line: {
                        width: 2,
                        dashStyle: SOLID,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    stackedline: {
                        width: 2,
                        dashStyle: SOLID,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    stackedspline: {
                        width: 2,
                        dashStyle: SOLID,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    fullstackedline: {
                        width: 2,
                        dashStyle: SOLID,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    fullstackedspline: {
                        width: 2,
                        dashStyle: SOLID,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    stepline: {
                        width: 2,
                        dashStyle: SOLID,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    area: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    stackedarea: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    fullstackedarea: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    fullstackedsplinearea: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    steparea: {
                        border: {
                            visible: true,
                            width: 2
                        },
                        point: {
                            visible: false
                        },
                        hoverStyle: {
                            border: {
                                visible: true,
                                width: 3
                            }
                        },
                        selectionStyle: {
                            border: {
                                visible: true,
                                width: 3
                            }
                        },
                        opacity: .5
                    },
                    spline: {
                        width: 2,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    splinearea: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    stackedsplinearea: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    bar: {
                        cornerRadius: 0,
                        point: {
                            hoverStyle: {
                                border: {
                                    visible: false
                                }
                            },
                            selectionStyle: {
                                border: {
                                    visible: false
                                }
                            }
                        }
                    },
                    stackedbar: {
                        cornerRadius: 0,
                        point: {
                            hoverStyle: {
                                border: {
                                    visible: false
                                }
                            },
                            selectionStyle: {
                                border: {
                                    visible: false
                                }
                            }
                        },
                        label: {
                            position: INSIDE
                        }
                    },
                    fullstackedbar: {
                        cornerRadius: 0,
                        point: {
                            hoverStyle: {
                                border: {
                                    visible: false
                                }
                            },
                            selectionStyle: {
                                border: {
                                    visible: false
                                }
                            }
                        },
                        label: {
                            position: INSIDE
                        }
                    },
                    rangebar: {
                        cornerRadius: 0,
                        point: {
                            hoverStyle: {
                                border: {
                                    visible: false
                                }
                            },
                            selectionStyle: {
                                border: {
                                    visible: false
                                }
                            }
                        }
                    },
                    rangearea: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    rangesplinearea: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    bubble: {
                        opacity: .5,
                        point: {
                            hoverStyle: {
                                border: {
                                    visible: false
                                }
                            },
                            selectionStyle: {
                                border: {
                                    visible: false
                                }
                            }
                        }
                    },
                    candlestick: {
                        width: 1,
                        reduction: {
                            color: RED
                        },
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        },
                        point: {
                            border: {
                                visible: true
                            }
                        }
                    },
                    stock: {
                        width: 1,
                        reduction: {
                            color: RED
                        },
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        },
                        point: {
                            border: {
                                visible: true
                            }
                        }
                    }
                },
                crosshair: {
                    enabled: false,
                    color: "#f05b41",
                    width: 1,
                    dashStyle: SOLID,
                    label: {
                        visible: false,
                        font: {
                            color: WHITE,
                            size: 12
                        }
                    },
                    verticalLine: {
                        visible: true
                    },
                    horizontalLine: {
                        visible: true
                    }
                },
                commonAxisSettings: {
                    multipleAxesSpacing: 5,
                    label: {
                        overlappingBehavior: {
                            mode: "enlargeTickInterval",
                            rotationAngle: 90,
                            staggeringSpacing: 5
                        },
                        indentFromAxis: 10
                    },
                    title: {
                        font: {
                            size: 16
                        },
                        margin: 6
                    },
                    constantLineStyle: {
                        paddingLeftRight: 10,
                        paddingTopBottom: 10
                    }
                },
                horizontalAxis: {
                    position: BOTTOM,
                    axisDivisionFactor: 50,
                    label: {
                        alignment: CENTER
                    },
                    stripStyle: {
                        label: {
                            horizontalAlignment: CENTER,
                            verticalAlignment: TOP
                        }
                    },
                    constantLineStyle: {
                        label: {
                            horizontalAlignment: RIGHT,
                            verticalAlignment: TOP
                        }
                    },
                    constantLines: {}
                },
                verticalAxis: {
                    position: LEFT,
                    axisDivisionFactor: 30,
                    label: {
                        alignment: RIGHT,
                        overlappingBehavior: {
                            mode: "enlargeTickInterval"
                        }
                    },
                    stripStyle: {
                        label: {
                            horizontalAlignment: LEFT,
                            verticalAlignment: CENTER
                        }
                    },
                    constantLineStyle: {
                        label: {
                            horizontalAlignment: LEFT,
                            verticalAlignment: TOP
                        }
                    },
                    constantLines: {}
                },
                argumentAxis: {},
                valueAxis: {
                    grid: {
                        visible: true
                    }
                },
                commonPaneSettings: {
                    backgroundColor: NONE,
                    border: {
                        color: LIGHT_GREY,
                        width: 1,
                        visible: false,
                        top: true,
                        bottom: true,
                        left: true,
                        right: true,
                        dashStyle: SOLID
                    }
                },
                scrollBar: {
                    visible: false,
                    offset: 5,
                    color: "gray",
                    width: 10
                },
                useAggregation: false,
                adjustOnZoom: true,
                rotated: false,
                zoomingMode: NONE,
                scrollingMode: NONE,
                synchronizeMultiAxes: true,
                equalBarWidth: true,
                minBubbleSize: 12,
                maxBubbleSize: .2
            },
            pie: {
                innerRadius: .5,
                type: "pie",
                commonSeriesSettings: {
                    pie: {
                        border: {
                            visible: false,
                            width: 2,
                            color: WHITE
                        },
                        hoverStyle: {
                            hatching: {
                                direction: RIGHT,
                                width: 4,
                                step: 10,
                                opacity: .75
                            },
                            border: {
                                visible: false,
                                width: 2
                            }
                        },
                        selectionStyle: {
                            hatching: {
                                direction: RIGHT,
                                width: 4,
                                step: 10,
                                opacity: .5
                            },
                            border: {
                                visible: false,
                                width: 2
                            }
                        }
                    },
                    doughnut: {
                        border: {
                            visible: false,
                            width: 2,
                            color: WHITE
                        },
                        hoverStyle: {
                            hatching: {
                                direction: RIGHT,
                                width: 4,
                                step: 10,
                                opacity: .75
                            },
                            border: {
                                visible: false,
                                width: 2
                            }
                        },
                        selectionStyle: {
                            hatching: {
                                direction: RIGHT,
                                width: 4,
                                step: 10,
                                opacity: .5
                            },
                            border: {
                                visible: false,
                                width: 2
                            }
                        }
                    },
                    donut: {
                        border: {
                            visible: false,
                            width: 2,
                            color: WHITE
                        },
                        hoverStyle: {
                            hatching: {
                                direction: RIGHT,
                                width: 4,
                                step: 10,
                                opacity: .75
                            },
                            border: {
                                visible: false,
                                width: 2
                            }
                        },
                        selectionStyle: {
                            hatching: {
                                direction: RIGHT,
                                width: 4,
                                step: 10,
                                opacity: .5
                            },
                            border: {
                                visible: false,
                                width: 2
                            }
                        }
                    }
                },
                legend: {
                    hoverMode: "allArgumentPoints",
                    backgroundColor: NONE
                },
                adaptiveLayout: {
                    keepLabels: false
                }
            },
            pieIE8: {
                commonSeriesSettings: {
                    pie: {
                        hoverStyle: {
                            border: {
                                visible: true,
                                color: WHITE
                            }
                        },
                        selectionStyle: {
                            border: {
                                visible: true,
                                color: WHITE
                            }
                        }
                    },
                    donut: {
                        hoverStyle: {
                            border: {
                                visible: true,
                                color: WHITE
                            }
                        },
                        selectionStyle: {
                            border: {
                                visible: true,
                                color: WHITE
                            }
                        }
                    },
                    doughnut: {
                        hoverStyle: {
                            border: {
                                visible: true,
                                color: WHITE
                            }
                        },
                        selectionStyle: {
                            border: {
                                visible: true,
                                color: WHITE
                            }
                        }
                    }
                }
            },
            gauge: {
                scale: {
                    tick: {
                        visible: true,
                        length: 5,
                        width: 2,
                        opacity: 1
                    },
                    minorTick: {
                        visible: false,
                        length: 3,
                        width: 1,
                        opacity: 1
                    },
                    label: {
                        visible: true,
                        alignment: CENTER,
                        overlappingBehavior: {
                            hideFirstOrLast: "last",
                            useAutoArrangement: true
                        }
                    },
                    position: TOP
                },
                rangeContainer: {
                    offset: 0,
                    width: 5,
                    backgroundColor: "#808080"
                },
                valueIndicators: {
                    _default: {
                        color: "#c2c2c2"
                    },
                    rangebar: {
                        space: 2,
                        size: 10,
                        color: "#cbc5cf",
                        backgroundColor: NONE,
                        text: {
                            indent: 0,
                            font: {
                                size: 14,
                                color: null
                            }
                        }
                    },
                    twocolorneedle: {
                        secondColor: "#e18e92"
                    },
                    trianglemarker: {
                        space: 2,
                        length: 14,
                        width: 13,
                        color: "#8798a5"
                    },
                    textcloud: {
                        arrowLength: 5,
                        horizontalOffset: 6,
                        verticalOffset: 3,
                        color: "#679ec5",
                        text: {
                            font: {
                                color: WHITE,
                                size: 18
                            }
                        }
                    }
                },
                indicator: {
                    hasPositiveMeaning: true,
                    layout: {
                        horizontalAlignment: CENTER,
                        verticalAlignment: BOTTOM
                    },
                    text: {
                        font: {
                            size: 18
                        }
                    }
                },
                _circular: {
                    scale: {
                        orientation: OUTSIDE,
                        label: {
                            indentFromTick: 10
                        }
                    },
                    rangeContainer: {
                        orientation: OUTSIDE
                    },
                    valueIndicatorType: "rectangleneedle",
                    subvalueIndicatorType: "trianglemarker",
                    valueIndicators: {
                        _type: "rectangleneedle",
                        _default: {
                            offset: 20,
                            indentFromCenter: 0,
                            width: 2,
                            spindleSize: 14,
                            spindleGapSize: 10
                        },
                        triangleneedle: {
                            width: 4
                        },
                        twocolorneedle: {
                            space: 2,
                            secondFraction: .4
                        },
                        rangebar: {
                            offset: 30
                        },
                        trianglemarker: {
                            offset: 6
                        },
                        textcloud: {
                            offset: -6
                        }
                    }
                },
                _linear: {
                    scale: {
                        horizontalOrientation: RIGHT,
                        verticalOrientation: BOTTOM,
                        label: {
                            indentFromTick: -10
                        }
                    },
                    rangeContainer: {
                        horizontalOrientation: RIGHT,
                        verticalOrientation: BOTTOM
                    },
                    valueIndicatorType: "rangebar",
                    subvalueIndicatorType: "trianglemarker",
                    valueIndicators: {
                        _type: "rectangle",
                        _default: {
                            offset: 2.5,
                            length: 15,
                            width: 15
                        },
                        rectangle: {
                            width: 10
                        },
                        rangebar: {
                            offset: 10,
                            horizontalOrientation: RIGHT,
                            verticalOrientation: BOTTOM
                        },
                        trianglemarker: {
                            offset: 10,
                            horizontalOrientation: LEFT,
                            verticalOrientation: TOP
                        },
                        textcloud: {
                            offset: -1,
                            horizontalOrientation: LEFT,
                            verticalOrientation: TOP
                        }
                    }
                }
            },
            barGauge: {
                backgroundColor: "#e0e0e0",
                relativeInnerRadius: .3,
                barSpacing: 4,
                label: {
                    indent: 20,
                    connectorWidth: 2,
                    font: {
                        size: 16
                    }
                },
                indicator: {
                    hasPositiveMeaning: true,
                    layout: {
                        horizontalAlignment: CENTER,
                        verticalAlignment: BOTTOM
                    },
                    text: {
                        font: {
                            size: 18
                        }
                    }
                }
            },
            rangeSelector: {
                scale: {
                    width: 1,
                    color: BLACK,
                    opacity: .1,
                    showCustomBoundaryTicks: true,
                    showMinorTicks: true,
                    useTicksAutoArrangement: true,
                    setTicksAtUnitBeginning: true,
                    label: {
                        alignment: "center",
                        visible: true,
                        topIndent: 7,
                        font: {
                            size: 11
                        }
                    },
                    tick: {
                        width: 1,
                        color: BLACK,
                        opacity: .17,
                        visible: true,
                        length: 12
                    },
                    minorTick: {
                        width: 1,
                        color: BLACK,
                        opacity: .05,
                        visible: true,
                        length: 12
                    },
                    marker: {
                        width: 1,
                        color: "#000000",
                        opacity: .1,
                        visible: true,
                        separatorHeight: 33,
                        topIndent: 10,
                        textLeftIndent: 7,
                        textTopIndent: 11,
                        label: {}
                    },
                    logarithmBase: 10
                },
                selectedRangeColor: "#606060",
                sliderMarker: {
                    visible: true,
                    paddingTopBottom: 2,
                    paddingLeftRight: 4,
                    color: "#606060",
                    invalidRangeColor: RED,
                    font: {
                        color: WHITE,
                        size: 11
                    }
                },
                sliderHandle: {
                    width: 1,
                    color: BLACK,
                    opacity: .2
                },
                shutter: {
                    opacity: .75
                },
                background: {
                    color: "#c0bae1",
                    visible: true,
                    image: {
                        location: "full"
                    }
                },
                behavior: {
                    snapToTicks: true,
                    animationEnabled: true,
                    moveSelectedRangeByClick: true,
                    manualRangeSelectionEnabled: true,
                    allowSlidersSwap: true,
                    callSelectedRangeChanged: "onMovingComplete"
                },
                redrawOnResize: true,
                chart: {
                    useAggregation: false,
                    equalBarWidth: true,
                    minBubbleSize: 12,
                    maxBubbleSize: .2,
                    topIndent: .1,
                    bottomIndent: 0,
                    valueAxis: {
                        inverted: false,
                        logarithmBase: 10
                    },
                    commonSeriesSettings: {
                        type: "area",
                        point: {
                            visible: false
                        },
                        scatter: {
                            point: {
                                visible: true
                            }
                        }
                    }
                }
            },
            map: {
                title: {
                    margin: 10
                },
                background: {
                    borderWidth: 1,
                    borderColor: "#cacaca"
                },
                layer: {
                    label: {
                        enabled: false,
                        stroke: WHITE,
                        "stroke-width": 1,
                        "stroke-opacity": .7,
                        font: {
                            color: SOME_GREY,
                            size: 12
                        }
                    }
                },
                "layer:area": {
                    borderWidth: 1,
                    borderColor: WHITE,
                    color: "#d2d2d2",
                    hoveredBorderColor: GREY_GREEN,
                    selectedBorderWidth: 2,
                    selectedBorderColor: GREY_GREEN,
                    label: {
                        "stroke-width": 2,
                        font: {
                            size: 16
                        }
                    }
                },
                "layer:line": {
                    borderWidth: 2,
                    color: "#ba8365",
                    hoveredColor: "#a94813",
                    selectedBorderWidth: 3,
                    selectedColor: "#e55100",
                    label: {
                        "stroke-width": 2,
                        font: {
                            size: 16
                        }
                    }
                },
                "layer:marker": {
                    label: {
                        enabled: true,
                        "stroke-width": 1,
                        font: {
                            size: 12
                        }
                    }
                },
                "layer:marker:dot": {
                    borderWidth: 2,
                    borderColor: WHITE,
                    color: "#ba4d51",
                    size: 8,
                    selectedStep: 2,
                    backStep: 18,
                    backColor: WHITE,
                    backOpacity: .32,
                    shadow: true
                },
                "layer:marker:bubble": {
                    minSize: 20,
                    maxSize: 50,
                    color: "#ba4d51",
                    hoveredBorderWidth: 1,
                    hoveredBorderColor: GREY_GREEN,
                    selectedBorderWidth: 2,
                    selectedBorderColor: GREY_GREEN
                },
                "layer:marker:pie": {
                    size: 50,
                    hoveredBorderWidth: 1,
                    hoveredBorderColor: GREY_GREEN,
                    selectedBorderWidth: 2,
                    selectedBorderColor: GREY_GREEN
                },
                "layer:marker:image": {
                    size: 20
                },
                legend: {
                    verticalAlignment: BOTTOM,
                    horizontalAlignment: RIGHT,
                    position: INSIDE,
                    backgroundOpacity: .65,
                    border: {
                        visible: true
                    },
                    paddingLeftRight: 16,
                    paddingTopBottom: 12,
                    markerColor: "#ba4d51"
                },
                controlBar: {
                    borderColor: "#5d5d5d",
                    borderWidth: 3,
                    color: WHITE,
                    margin: 20,
                    opacity: .3
                },
                _rtl: {
                    legend: {
                        itemTextPosition: LEFT
                    }
                }
            },
            treeMap: {
                tile: {
                    border: {
                        width: 1,
                        opacity: .2,
                        color: "#000000"
                    },
                    color: "#5f8b95",
                    hoverStyle: {
                        hatching: {
                            opacity: .75,
                            step: 6,
                            width: 2,
                            direction: "right"
                        },
                        border: {}
                    },
                    selectionStyle: {
                        hatching: {
                            opacity: .5,
                            step: 6,
                            width: 2,
                            direction: "right"
                        },
                        border: {
                            opacity: 1
                        }
                    },
                    label: {
                        visible: true,
                        paddingLeftRight: 5,
                        paddingTopBottom: 4,
                        stroke: "#000000",
                        "stroke-width": 1,
                        "stroke-opacity": .3,
                        font: {
                            color: "#ffffff",
                            weight: 300
                        },
                        shadow: {
                            opacity: .8,
                            offsetX: 0,
                            offsetY: 1,
                            blur: 1,
                            color: "#000000"
                        }
                    }
                },
                group: {
                    padding: 4,
                    border: {
                        width: 1
                    },
                    color: "#eeeeee",
                    hoverStyle: {
                        hatching: {
                            opacity: 0,
                            step: 6,
                            width: 2,
                            direction: "right"
                        },
                        border: {}
                    },
                    selectionStyle: {
                        hatching: {
                            opacity: 0,
                            step: 6,
                            width: 2,
                            direction: "right"
                        },
                        border: {}
                    },
                    label: {
                        visible: true,
                        paddingLeftRight: 5,
                        paddingTopBottom: 4,
                        font: {
                            weight: 600
                        }
                    }
                },
                title: {
                    subtitle: {}
                },
                tooltip: {},
                loadingIndicator: {}
            },
            sparkline: {
                lineColor: "#666666",
                lineWidth: 2,
                areaOpacity: .2,
                minColor: "#e8c267",
                maxColor: "#e55253",
                barPositiveColor: "#a9a9a9",
                barNegativeColor: "#d7d7d7",
                winColor: "#a9a9a9",
                lossColor: "#d7d7d7",
                firstLastColor: "#666666",
                pointSymbol: "circle",
                pointColor: WHITE,
                pointSize: 4,
                type: "line",
                argumentField: "arg",
                valueField: "val",
                winlossThreshold: 0,
                showFirstLast: true,
                showMinMax: false,
                tooltip: {
                    enabled: true
                }
            },
            bullet: {
                color: "#e8c267",
                targetColor: "#666666",
                targetWidth: 4,
                showTarget: true,
                showZeroLevel: true,
                tooltip: {
                    enabled: true
                }
            },
            polar: {
                commonSeriesSettings: {
                    type: "scatter",
                    closed: true,
                    point: {
                        visible: true,
                        symbol: "circle",
                        size: 12,
                        border: {
                            visible: false,
                            width: 1
                        },
                        hoverMode: "onlyPoint",
                        selectionMode: "onlyPoint",
                        hoverStyle: {
                            border: {
                                visible: true,
                                width: 4
                            },
                            size: 12
                        },
                        selectionStyle: {
                            border: {
                                visible: true,
                                width: 4
                            },
                            size: 12
                        }
                    },
                    scatter: {},
                    line: {
                        width: 2,
                        dashStyle: SOLID,
                        hoverStyle: {
                            width: 3,
                            hatching: {
                                direction: NONE
                            }
                        },
                        selectionStyle: {
                            width: 3
                        }
                    },
                    area: {
                        point: {
                            visible: false
                        },
                        opacity: .5
                    },
                    stackedline: {
                        width: 2
                    },
                    bar: {
                        opacity: .8
                    },
                    stackedbar: {
                        opacity: .8
                    }
                },
                adaptiveLayout: {
                    width: 170,
                    height: 170,
                    keepLabels: true
                },
                equalBarWidth: true,
                commonAxisSettings: {
                    visible: true,
                    label: {
                        overlappingBehavior: {
                            mode: "enlargeTickInterval"
                        },
                        indentFromAxis: 5
                    },
                    grid: {
                        visible: true
                    },
                    minorGrid: {
                        visible: true
                    },
                    tick: {
                        visible: true
                    },
                    title: {
                        font: {
                            size: 16
                        },
                        margin: 10
                    }
                },
                argumentAxis: {
                    startAngle: 0,
                    firstPointOnStartAngle: false,
                    period: void 0
                },
                valueAxis: {
                    tick: {
                        visible: false
                    }
                },
                horizontalAxis: {
                    position: TOP,
                    axisDivisionFactor: 50,
                    label: {
                        alignment: CENTER
                    }
                },
                verticalAxis: {
                    position: TOP,
                    axisDivisionFactor: 30,
                    label: {
                        alignment: RIGHT
                    }
                }
            }
        });
        registerTheme({
            name: "generic.dark",
            font: {
                color: "#808080"
            },
            backgroundColor: "#2a2a2a",
            primaryTitleColor: "#dedede",
            secondaryTitleColor: "#a3a3a3",
            axisColor: "#555555",
            axisLabelColor: "#a3a3a3",
            "export": {
                backgroundColor: "#2a2a2a",
                font: {
                    color: "#dbdbdb"
                },
                button: {
                    "default": {
                        color: "#dedede",
                        borderColor: "#4d4d4d",
                        backgroundColor: "#2e2e2e"
                    },
                    hover: {
                        color: "#dedede",
                        borderColor: "#6c6c6c",
                        backgroundColor: "#444"
                    },
                    focus: {
                        color: "#dedede",
                        borderColor: "#8d8d8d",
                        backgroundColor: "#444444"
                    },
                    active: {
                        color: "#dedede",
                        borderColor: "#8d8d8d",
                        backgroundColor: "#555555"
                    }
                },
                shadowColor: "#292929"
            },
            tooltip: {
                color: SOME_GREY,
                border: {
                    color: "#494949"
                },
                font: {
                    color: "#929292"
                }
            },
            "chart:common": {
                commonSeriesSettings: {
                    label: {
                        border: {
                            color: "#494949"
                        }
                    },
                    valueErrorBar: {
                        color: WHITE
                    }
                }
            },
            "chart:common:axis": {
                constantLineStyle: {
                    color: WHITE
                }
            },
            chart: {
                commonPaneSettings: {
                    border: {
                        color: "#494949"
                    }
                }
            },
            pieIE8: {
                commonSeriesSettings: {
                    pie: {
                        hoverStyle: {
                            border: {
                                color: SOME_GREY
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: SOME_GREY
                            }
                        }
                    },
                    donut: {
                        hoverStyle: {
                            border: {
                                color: SOME_GREY
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: SOME_GREY
                            }
                        }
                    },
                    doughnut: {
                        hoverStyle: {
                            border: {
                                color: SOME_GREY
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: SOME_GREY
                            }
                        }
                    }
                }
            },
            gauge: {
                rangeContainer: {
                    backgroundColor: RANGE_COLOR
                },
                valueIndicators: {
                    _default: {
                        color: RANGE_COLOR
                    },
                    rangebar: {
                        color: "#84788b"
                    },
                    twocolorneedle: {
                        secondColor: "#ba544d"
                    },
                    trianglemarker: {
                        color: "#b7918f"
                    },
                    textcloud: {
                        color: "#ba544d"
                    }
                }
            },
            barGauge: {
                backgroundColor: "#3c3c3c"
            },
            rangeSelector: {
                scale: {
                    tick: {
                        color: WHITE,
                        opacity: .32
                    },
                    minorTick: {
                        color: WHITE,
                        opacity: .1
                    }
                },
                selectedRangeColor: RANGE_COLOR,
                sliderMarker: {
                    color: RANGE_COLOR,
                    font: {
                        color: GREY_GREEN
                    }
                },
                sliderHandle: {
                    color: WHITE,
                    opacity: .2
                },
                shutter: {
                    color: SOME_GREY,
                    opacity: .9
                }
            },
            map: {
                background: {
                    borderColor: "#3f3f3f"
                },
                layer: {
                    label: {
                        stroke: BLACK,
                        font: {
                            color: WHITE
                        }
                    }
                },
                "layer:area": {
                    borderColor: GREY_GREEN,
                    color: AREA_LAYER_COLOR,
                    hoveredBorderColor: WHITE,
                    selectedBorderColor: WHITE
                },
                "layer:line": {
                    color: "#c77244",
                    hoveredColor: "#ff5d04",
                    selectedColor: "#ff784f"
                },
                "layer:marker:bubble": {
                    hoveredBorderColor: WHITE,
                    selectedBorderColor: WHITE
                },
                "layer:marker:pie": {
                    hoveredBorderColor: WHITE,
                    selectedBorderColor: WHITE
                },
                legend: {
                    border: {
                        color: "#3f3f3f"
                    },
                    font: {
                        color: WHITE
                    }
                },
                controlBar: {
                    borderColor: LINE_COLOR,
                    color: GREY_GREEN
                }
            },
            treeMap: {
                group: {
                    color: "#4c4c4c"
                }
            },
            sparkline: {
                lineColor: LINE_COLOR,
                firstLastColor: LINE_COLOR,
                barPositiveColor: POSITIVE_COLOR,
                barNegativeColor: TARGET_COLOR,
                winColor: POSITIVE_COLOR,
                lossColor: TARGET_COLOR,
                pointColor: GREY_GREEN
            },
            bullet: {
                targetColor: TARGET_COLOR
            }
        }, "generic.light");
        registerTheme({
            name: "generic.contrast",
            defaultPalette: "Bright",
            font: {
                color: WHITE
            },
            backgroundColor: BLACK,
            primaryTitleColor: WHITE,
            secondaryTitleColor: WHITE,
            axisColor: WHITE,
            axisLabelColor: WHITE,
            "export": {
                backgroundColor: BLACK,
                font: {
                    color: WHITE
                },
                button: {
                    "default": {
                        color: WHITE,
                        borderColor: WHITE,
                        backgroundColor: BLACK
                    },
                    hover: {
                        color: WHITE,
                        borderColor: WHITE,
                        backgroundColor: "#cf00d7"
                    },
                    focus: {
                        color: WHITE,
                        borderColor: "#cf00d7",
                        backgroundColor: BLACK
                    },
                    active: {
                        color: BLACK,
                        borderColor: WHITE,
                        backgroundColor: WHITE
                    }
                },
                borderColor: WHITE,
                menuButtonColor: BLACK,
                activeBackgroundColor: WHITE,
                activeColor: BLACK,
                selectedBorderColor: CONTRAST_ACTIVE,
                selectedColor: CONTRAST_ACTIVE,
                shadowColor: "none"
            },
            tooltip: {
                border: {
                    color: WHITE
                },
                font: {
                    color: WHITE
                },
                color: BLACK
            },
            "chart:common": {
                commonSeriesSettings: {
                    valueErrorBar: {
                        color: WHITE
                    },
                    hoverStyle: {
                        hatching: {
                            opacity: .5
                        }
                    },
                    selectionStyle: {
                        hatching: {
                            opacity: .35
                        }
                    },
                    label: {
                        font: {
                            color: WHITE
                        },
                        border: {
                            color: WHITE
                        }
                    }
                }
            },
            "chart:common:axis": {
                constantLineStyle: {
                    color: WHITE
                }
            },
            chart: {
                commonSeriesSettings: {},
                commonPaneSettings: {
                    backgroundColor: BLACK,
                    border: {
                        color: WHITE
                    }
                },
                scrollBar: {
                    color: WHITE
                }
            },
            pie: {
                commonSeriesSettings: {
                    pie: {
                        hoverStyle: {
                            hatching: {
                                opacity: .5
                            }
                        },
                        selectionStyle: {
                            hatching: {
                                opacity: .35
                            }
                        }
                    },
                    doughnut: {
                        hoverStyle: {
                            hatching: {
                                opacity: .5
                            }
                        },
                        selectionStyle: {
                            hatching: {
                                opacity: .35
                            }
                        }
                    },
                    donut: {
                        hoverStyle: {
                            hatching: {
                                opacity: .5
                            }
                        },
                        selectionStyle: {
                            hatching: {
                                opacity: .35
                            }
                        }
                    }
                },
                legend: {
                    backgroundColor: BLACK
                }
            },
            gauge: {
                rangeContainer: {
                    backgroundColor: WHITE
                },
                valueIndicators: {
                    _default: {
                        color: WHITE
                    },
                    rangebar: {
                        color: WHITE,
                        backgroundColor: BLACK
                    },
                    twocolorneedle: {
                        secondColor: WHITE
                    },
                    trianglemarker: {
                        color: WHITE
                    },
                    textcloud: {
                        color: WHITE,
                        text: {
                            font: {
                                color: BLACK
                            }
                        }
                    }
                }
            },
            barGauge: {
                backgroundColor: "#3c3c3c"
            },
            rangeSelector: {
                scale: {
                    tick: {
                        opacity: .4
                    },
                    minorTick: {
                        opacity: .12
                    }
                },
                selectedRangeColor: CONTRAST_ACTIVE,
                sliderMarker: {
                    color: CONTRAST_ACTIVE
                },
                sliderHandle: {
                    color: CONTRAST_ACTIVE,
                    opacity: 1
                },
                shutter: {
                    opacity: .75
                },
                background: {
                    color: BLACK
                }
            },
            map: {
                background: {
                    borderColor: WHITE
                },
                layer: {
                    label: {
                        stroke: BLACK,
                        font: {
                            color: WHITE
                        }
                    }
                },
                "layer:area": {
                    borderColor: BLACK,
                    color: AREA_LAYER_COLOR,
                    hoveredBorderColor: WHITE,
                    selectedBorderColor: WHITE,
                    label: {
                        font: {
                            opacity: 1
                        }
                    }
                },
                "layer:line": {
                    color: "#267cff",
                    hoveredColor: "#f613ff",
                    selectedColor: WHITE
                },
                "layer:marker:dot": {
                    borderColor: BLACK,
                    color: MARKER_COLOR,
                    backColor: BLACK,
                    backOpacity: .32
                },
                "layer:marker:bubble": {
                    color: MARKER_COLOR,
                    hoveredBorderColor: WHITE,
                    selectedBorderColor: WHITE
                },
                "layer:marker:pie": {
                    hoveredBorderColor: WHITE,
                    selectedBorderColor: WHITE
                },
                legend: {
                    markerColor: MARKER_COLOR
                },
                controlBar: {
                    borderColor: WHITE,
                    color: BLACK,
                    opacity: .3
                }
            },
            treeMap: {
                tile: {
                    color: "#70c92f"
                },
                group: {
                    color: "#797979"
                }
            },
            sparkline: {
                pointColor: BLACK
            },
            bullet: {},
            polar: {
                commonSeriesSettings: {}
            }
        }, "generic.light");
        themeModule.currentTheme("generic.light");
        registerThemeAlias("desktop.light", "generic.light");
        registerThemeAlias("desktop.dark", "generic.dark")
    },
    /*!*********************************!*\
      !*** ./Scripts/viz/core/ios.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var themeModule = __webpack_require__( /*! ../themes */ 441),
            IOS7_DEFAULT = "ios7.default",
            SECONDARY_TEXT_COLOR = "#767676",
            BORDER_COLOR = "#d3d3d3",
            BLACK = "#000000";
        themeModule.registerTheme({
            name: IOS7_DEFAULT,
            backgroundColor: "#ffffff",
            primaryTitleColor: BLACK,
            secondaryTitleColor: SECONDARY_TEXT_COLOR,
            axisColor: "#ececec",
            axisLabelColor: SECONDARY_TEXT_COLOR,
            legend: {
                font: {
                    color: BLACK
                }
            },
            tooltip: {
                font: {
                    color: SECONDARY_TEXT_COLOR
                }
            },
            "chart:common": {
                commonSeriesSettings: {
                    label: {
                        border: {
                            color: BORDER_COLOR
                        }
                    }
                }
            },
            chart: {
                commonPaneSettings: {
                    border: {
                        color: BORDER_COLOR
                    }
                }
            },
            rangeSelector: {
                scale: {
                    tick: {
                        color: BLACK,
                        opacity: .1
                    },
                    minorTick: {
                        color: BLACK,
                        opacity: .03
                    }
                }
            }
        }, "generic.light");
        themeModule.registerThemeAlias("ios", IOS7_DEFAULT)
    },
    /*!*************************************!*\
      !*** ./Scripts/viz/core/android.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var ANDROID5_LIGHT = "android5.light",
            themeModule = __webpack_require__( /*! ../themes */ 441),
            registerThemeAlias = themeModule.registerThemeAlias,
            SECONDARY_TEXT_COLOR = "#767676",
            BORDER_COLOR = "#e8e8e8",
            BLACK = "#000000";
        themeModule.registerTheme({
            name: ANDROID5_LIGHT,
            backgroundColor: "#ffffff",
            primaryTitleColor: "#232323",
            secondaryTitleColor: SECONDARY_TEXT_COLOR,
            axisColor: "#d3d3d3",
            axisLabelColor: SECONDARY_TEXT_COLOR,
            tooltip: {
                color: BORDER_COLOR,
                font: {
                    color: SECONDARY_TEXT_COLOR
                }
            },
            legend: {
                font: {
                    color: BLACK
                }
            },
            pieIE8: {
                commonSeriesSettings: {
                    pie: {
                        hoverStyle: {
                            border: {
                                color: BORDER_COLOR
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: BORDER_COLOR
                            }
                        }
                    },
                    donut: {
                        hoverStyle: {
                            border: {
                                color: BORDER_COLOR
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: BORDER_COLOR
                            }
                        }
                    },
                    doughnut: {
                        hoverStyle: {
                            border: {
                                color: BORDER_COLOR
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: BORDER_COLOR
                            }
                        }
                    }
                }
            },
            rangeSelector: {
                scale: {
                    tick: {
                        color: BLACK,
                        opacity: .17
                    },
                    minorTick: {
                        color: BLACK,
                        opacity: .05
                    }
                }
            }
        }, "generic.light");
        registerThemeAlias("android", ANDROID5_LIGHT);
        registerThemeAlias("android.holo-dark", ANDROID5_LIGHT);
        registerThemeAlias("android.holo-light", ANDROID5_LIGHT);
        registerThemeAlias("android.dark", ANDROID5_LIGHT);
        registerThemeAlias("android.light", ANDROID5_LIGHT)
    },
    /*!*********************************!*\
      !*** ./Scripts/viz/core/win.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        var themeModule = __webpack_require__( /*! ../themes */ 441),
            registerTheme = themeModule.registerTheme,
            registerThemeSchemeAlias = themeModule.registerThemeSchemeAlias,
            BLACK = "#000000",
            WHITE = "#ffffff",
            WIN10_WHITE = "win10.white",
            WIN10_BLACK = "win10.black",
            WIN8_WHITE = "win8.white",
            WIN8_BLACK = "win8.black";
        registerTheme({
            name: WIN10_BLACK,
            backgroundColor: BLACK,
            primaryTitleColor: WHITE,
            secondaryTitleColor: "#d8d8d8",
            axisColor: "#4c4c4c",
            axisLabelColor: WHITE,
            title: {
                font: {
                    color: WHITE
                }
            },
            legend: {
                font: {
                    color: WHITE
                }
            },
            tooltip: {
                color: BLACK,
                font: {
                    color: WHITE
                }
            },
            "chart:common": {
                commonSeriesSettings: {
                    label: {
                        border: {
                            color: "#454545"
                        }
                    }
                }
            },
            chart: {
                commonPaneSettings: {
                    border: {
                        color: "#454545"
                    }
                }
            },
            pieIE8: {
                commonSeriesSettings: {
                    pie: {
                        hoverStyle: {
                            border: {
                                color: BLACK
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: BLACK
                            }
                        }
                    },
                    donut: {
                        hoverStyle: {
                            border: {
                                color: BLACK
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: BLACK
                            }
                        }
                    },
                    doughnut: {
                        hoverStyle: {
                            border: {
                                color: BLACK
                            }
                        },
                        selectionStyle: {
                            border: {
                                color: BLACK
                            }
                        }
                    }
                }
            },
            barGauge: {
                backgroundColor: "#2b3036"
            },
            rangeSelector: {
                scale: {
                    tick: {
                        color: WHITE,
                        opacity: .23
                    },
                    minorTick: {
                        color: WHITE,
                        opacity: .07
                    }
                }
            }
        }, "generic.dark");
        registerTheme({
            name: WIN10_WHITE,
            backgroundColor: WHITE,
            primaryTitleColor: BLACK,
            secondaryTitleColor: "#767676",
            axisColor: "#ececec",
            axisLabelColor: BLACK,
            title: {
                font: {
                    color: BLACK
                }
            },
            legend: {
                font: {
                    color: BLACK
                }
            },
            tooltip: {
                font: {
                    color: BLACK
                }
            },
            rangeSelector: {
                scale: {
                    tick: {
                        color: BLACK,
                        opacity: .1
                    },
                    minorTick: {
                        color: BLACK,
                        opacity: .03
                    }
                }
            }
        }, "generic.light");
        registerThemeSchemeAlias("win10.dark", WIN10_BLACK);
        registerThemeSchemeAlias("win10.light", WIN10_WHITE);
        registerTheme({
            name: WIN8_BLACK
        }, WIN10_BLACK);
        registerTheme({
            name: WIN8_WHITE
        }, WIN10_WHITE);
        registerThemeSchemeAlias("win8.dark", WIN8_BLACK);
        registerThemeSchemeAlias("win8.light", WIN8_WHITE)
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/chart_components/layout_manager.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            layoutElementModule = __webpack_require__( /*! ../core/layout_element */ 457),
            _isNumber = commonUtils.isNumber,
            _min = Math.min,
            _max = Math.max,
            _floor = Math.floor,
            _sqrt = Math.sqrt,
            _each = $.each,
            _extend = $.extend,
            consts = __webpack_require__( /*! ../components/consts */ 462),
            pieLabelIndent = consts.pieLabelIndent,
            pieLabelSpacing = consts.pieLabelSpacing;

        function updateAxis(axes, side, needRemoveSpace) {
            if (axes && needRemoveSpace[side] > 0) {
                _each(axes, function(i, axis) {
                    var bbox = axis.getBoundingRect();
                    axis.updateSize();
                    needRemoveSpace[side] -= bbox[side] - axis.getBoundingRect()[side]
                });
                if (needRemoveSpace[side] > 0) {
                    _each(axes, function(_, axis) {
                        axis.updateSize(true)
                    })
                }
            }
        }

        function getNearestCoord(firstCoord, secondCoord, pointCenterCoord) {
            var nearestCoord;
            if (pointCenterCoord < firstCoord) {
                nearestCoord = firstCoord
            } else {
                if (secondCoord < pointCenterCoord) {
                    nearestCoord = secondCoord
                } else {
                    nearestCoord = pointCenterCoord
                }
            }
            return nearestCoord
        }

        function getLabelLayout(point) {
            if (point._label.isVisible() && "inside" !== point._label.getLayoutOptions().position) {
                return point._label.getBoundingRect()
            }
        }

        function getPieRadius(series, paneCenterX, paneCenterY, accessibleRadius, minR) {
            var radiusIsFound = false;
            _each(series, function(_, singleSeries) {
                if (radiusIsFound) {
                    return false
                }
                _each(singleSeries.getVisiblePoints(), function(_, point) {
                    var labelBBox = getLabelLayout(point);
                    if (labelBBox) {
                        var xCoords = getNearestCoord(labelBBox.x, labelBBox.x + labelBBox.width, paneCenterX),
                            yCoords = getNearestCoord(labelBBox.y, labelBBox.y + labelBBox.height, paneCenterY);
                        accessibleRadius = _min(_max(getLengthFromCenter(xCoords, yCoords, paneCenterX, paneCenterY) - pieLabelIndent, minR), accessibleRadius);
                        radiusIsFound = true
                    }
                })
            });
            return accessibleRadius
        }

        function getSizeLabels(series) {
            var sizes = [],
                commonWidth = 0;
            _each(series, function(_, singleSeries) {
                var maxWidth = 0;
                _each(singleSeries.getVisiblePoints(), function(_, point) {
                    var labelBBox = getLabelLayout(point);
                    if (labelBBox) {
                        maxWidth = _max(labelBBox.width + pieLabelSpacing, maxWidth)
                    }
                });
                sizes.push(maxWidth);
                commonWidth += maxWidth
            });
            return {
                sizes: sizes,
                common: commonWidth
            }
        }

        function correctLabelRadius(sizes, radius, series, canvas, averageWidthLabels) {
            var curRadius, i, centerX = (canvas.width - canvas.left - canvas.right) / 2;
            for (i = 0; i < series.length; i++) {
                if (0 === sizes[i]) {
                    curRadius && (curRadius += sizes[i - 1]);
                    continue
                }
                curRadius = _floor(curRadius ? curRadius + sizes[i - 1] : radius);
                series[i].correctLabelRadius(curRadius);
                if (averageWidthLabels && i !== series.length - 1) {
                    sizes[i] = averageWidthLabels;
                    series[i].setVisibleArea({
                        left: centerX - radius - averageWidthLabels * (i + 1),
                        right: canvas.width - (centerX + radius + averageWidthLabels * (i + 1)),
                        top: canvas.top,
                        bottom: canvas.bottom,
                        width: canvas.width,
                        height: canvas.height
                    })
                }
            }
        }

        function getLengthFromCenter(x, y, paneCenterX, paneCenterY) {
            return _sqrt((x - paneCenterX) * (x - paneCenterX) + (y - paneCenterY) * (y - paneCenterY))
        }

        function getInnerRadius(series) {
            var innerRadius;
            if ("pie" === series.type) {
                innerRadius = 0
            } else {
                innerRadius = _isNumber(series.innerRadius) ? Number(series.innerRadius) : .5;
                innerRadius = innerRadius < .2 ? .2 : innerRadius;
                innerRadius = innerRadius > .8 ? .8 : innerRadius
            }
            return innerRadius
        }

        function isValidBox(box) {
            return !!(box.x || box.y || box.width || box.height)
        }

        function correctDeltaMarginValue(panes, marginSides) {
            var canvas, deltaSide, requireAxesRedraw = false;
            _each(panes, function(_, pane) {
                canvas = pane.canvas;
                _each(marginSides, function(_, side) {
                    deltaSide = "delta" + side;
                    canvas[deltaSide] = _max(canvas[deltaSide] - (canvas[side.toLowerCase()] - canvas["original" + side]), 0);
                    if (canvas[deltaSide] > 0) {
                        requireAxesRedraw = true
                    }
                })
            });
            return requireAxesRedraw
        }

        function getPane(name, panes) {
            var findPane = panes[0];
            _each(panes, function(_, pane) {
                if (name === pane.name) {
                    findPane = pane
                }
            });
            return findPane
        }

        function applyFoundExceedings(panes, rotated) {
            var stopDrawAxes = false,
                maxLeft = 0,
                maxRight = 0,
                maxTop = 0,
                maxBottom = 0;
            _each(panes, function(_, pane) {
                maxLeft = _max(maxLeft, pane.canvas.deltaLeft);
                maxRight = _max(maxRight, pane.canvas.deltaRight);
                maxTop = _max(maxTop, pane.canvas.deltaTop);
                maxBottom = _max(maxBottom, pane.canvas.deltaBottom)
            });
            if (rotated) {
                _each(panes, function(_, pane) {
                    pane.canvas.top += maxTop;
                    pane.canvas.bottom += maxBottom;
                    pane.canvas.right += pane.canvas.deltaRight;
                    pane.canvas.left += pane.canvas.deltaLeft
                })
            } else {
                _each(panes, function(_, pane) {
                    pane.canvas.top += pane.canvas.deltaTop;
                    pane.canvas.bottom += pane.canvas.deltaBottom;
                    pane.canvas.right += maxRight;
                    pane.canvas.left += maxLeft
                })
            }
            _each(panes, function(_, pane) {
                if (pane.canvas.top + pane.canvas.bottom > pane.canvas.height) {
                    stopDrawAxes = true
                }
                if (pane.canvas.left + pane.canvas.right > pane.canvas.width) {
                    stopDrawAxes = true
                }
            });
            return stopDrawAxes
        }
        var inverseAlign = {
            left: "right",
            right: "left",
            top: "bottom",
            bottom: "top",
            center: "center"
        };

        function downSize(canvas, layoutOptions) {
            canvas[layoutOptions.cutLayoutSide] += "horizontal" === layoutOptions.cutSide ? layoutOptions.width : layoutOptions.height
        }

        function getOffset(layoutOptions, offsets) {
            var side = layoutOptions.cutLayoutSide,
                offset = {
                    horizontal: 0,
                    vertical: 0
                };
            switch (side) {
                case "top":
                case "left":
                    offset[layoutOptions.cutSide] = -offsets[side];
                    break;
                case "bottom":
                case "right":
                    offset[layoutOptions.cutSide] = offsets[side]
            }
            return offset
        }

        function LayoutManager() {}

        function toLayoutElementCoords(canvas) {
            return new layoutElementModule.WrapperLayoutElement(null, {
                x: canvas.left,
                y: canvas.top,
                width: canvas.width - canvas.left - canvas.right,
                height: canvas.height - canvas.top - canvas.bottom
            })
        }
        LayoutManager.prototype = {
            constructor: LayoutManager,
            setOptions: function(options) {
                this._options = options
            },
            applyVerticalAxesLayout: function(axes, panes, rotated) {
                this._applyAxesLayout(axes, panes, rotated)
            },
            applyHorizontalAxesLayout: function(axes, panes, rotated) {
                axes.reverse();
                this._applyAxesLayout(axes, panes, rotated);
                axes.reverse()
            },
            _applyAxesLayout: function(axes, panes, rotated) {
                var canvas, axisPosition, box, delta, axis, axisLength, direction, directionMultiplier, pane, i, that = this,
                    someDirection = [];
                _each(panes, function(_, pane) {
                    _extend(pane.canvas, {
                        deltaLeft: 0,
                        deltaRight: 0,
                        deltaTop: 0,
                        deltaBottom: 0
                    })
                });
                for (i = 0; i < axes.length; i++) {
                    axis = axes[i];
                    axisPosition = axis.getOptions().position || "left";
                    axis.delta = {};
                    box = axis.getBoundingRect();
                    pane = getPane(axis.pane, panes);
                    canvas = pane.canvas;
                    if (!isValidBox(box)) {
                        continue
                    }
                    direction = "delta" + axisPosition.slice(0, 1).toUpperCase() + axisPosition.slice(1);
                    switch (axisPosition) {
                        case "right":
                            directionMultiplier = 1;
                            canvas.deltaLeft += axis.padding ? axis.padding.left : 0;
                            break;
                        case "left":
                            directionMultiplier = -1;
                            canvas.deltaRight += axis.padding ? axis.padding.right : 0;
                            break;
                        case "top":
                            directionMultiplier = -1;
                            canvas.deltaBottom += axis.padding ? axis.padding.bottom : 0;
                            break;
                        case "bottom":
                            directionMultiplier = 1;
                            canvas.deltaTop += axis.padding ? axis.padding.top : 0
                    }
                    switch (axisPosition) {
                        case "right":
                        case "left":
                            if (!box.isEmpty) {
                                delta = box.y + box.height - (canvas.height - canvas.originalBottom);
                                if (delta > 0) {
                                    that.requireAxesRedraw = true;
                                    canvas.deltaBottom += delta
                                }
                                delta = canvas.originalTop - box.y;
                                if (delta > 0) {
                                    that.requireAxesRedraw = true;
                                    canvas.deltaTop += delta
                                }
                            }
                            axisLength = box.width;
                            someDirection = ["Left", "Right"];
                            break;
                        case "top":
                        case "bottom":
                            if (!box.isEmpty) {
                                delta = box.x + box.width - (canvas.width - canvas.originalRight);
                                if (delta > 0) {
                                    that.requireAxesRedraw = true;
                                    canvas.deltaRight += delta
                                }
                                delta = canvas.originalLeft - box.x;
                                if (delta > 0) {
                                    that.requireAxesRedraw = true;
                                    canvas.deltaLeft += delta
                                }
                            }
                            someDirection = ["Bottom", "Top"];
                            axisLength = box.height
                    }
                    if (!axis.delta[axisPosition] && canvas[direction] > 0) {
                        canvas[direction] += axis.getMultipleAxesSpacing()
                    }
                    axis.delta[axisPosition] = axis.delta[axisPosition] || 0;
                    axis.delta[axisPosition] += canvas[direction] * directionMultiplier;
                    canvas[direction] += axisLength
                }
                that.requireAxesRedraw = correctDeltaMarginValue(panes, someDirection) || that.requireAxesRedraw;
                that.stopDrawAxes = applyFoundExceedings(panes, rotated)
            },
            applyPieChartSeriesLayout: function(canvas, series, hideLayoutLabels) {
                var sizeLabels, averageWidthLabels, fullRadiusWithLabels, paneSpaceHeight = canvas.height - canvas.top - canvas.bottom,
                    paneSpaceWidth = canvas.width - canvas.left - canvas.right,
                    paneCenterX = paneSpaceWidth / 2 + canvas.left,
                    paneCenterY = paneSpaceHeight / 2 + canvas.top,
                    piePercentage = this._options.piePercentage,
                    accessibleRadius = _isNumber(piePercentage) ? piePercentage * _min(canvas.height, canvas.width) / 2 : _min(paneSpaceWidth, paneSpaceHeight) / 2,
                    minR = .7 * accessibleRadius,
                    countSeriesWithOuterLabels = 0,
                    innerRadius = getInnerRadius(series[0]);
                if (!hideLayoutLabels && !_isNumber(piePercentage)) {
                    sizeLabels = getSizeLabels(series);
                    fullRadiusWithLabels = paneCenterX - sizeLabels.common + canvas.left;
                    if (fullRadiusWithLabels < minR) {
                        accessibleRadius = minR;
                        _each(sizeLabels.sizes, function(_, size) {
                            0 !== size && countSeriesWithOuterLabels++
                        });
                        averageWidthLabels = (paneCenterX - accessibleRadius - canvas.left) / countSeriesWithOuterLabels
                    } else {
                        accessibleRadius = _min(getPieRadius(series, paneCenterX, paneCenterY, accessibleRadius, minR), fullRadiusWithLabels)
                    }
                    correctLabelRadius(sizeLabels.sizes, accessibleRadius, series, canvas, averageWidthLabels)
                }
                return {
                    centerX: _floor(paneCenterX),
                    centerY: _floor(paneCenterY),
                    radiusInner: _floor(accessibleRadius * innerRadius),
                    radiusOuter: _floor(accessibleRadius),
                    canvas: canvas
                }
            },
            needMoreSpaceForPanesCanvas: function(panes, rotated) {
                var options = this._options,
                    width = options.width,
                    height = options.height,
                    piePercentage = options.piePercentage,
                    percentageIsValid = _isNumber(piePercentage),
                    needHorizontalSpace = 0,
                    needVerticalSpace = 0;
                _each(panes, function(_, pane) {
                    var paneCanvas = pane.canvas,
                        minSize = percentageIsValid ? _min(paneCanvas.width, paneCanvas.height) * piePercentage : void 0,
                        needPaneHorizontalSpace = (percentageIsValid ? minSize : width) - (paneCanvas.width - paneCanvas.left - paneCanvas.right),
                        needPaneVerticalSpace = (percentageIsValid ? minSize : height) - (paneCanvas.height - paneCanvas.top - paneCanvas.bottom);
                    if (rotated) {
                        needHorizontalSpace += needPaneHorizontalSpace > 0 ? needPaneHorizontalSpace : 0;
                        needVerticalSpace = _max(needPaneVerticalSpace > 0 ? needPaneVerticalSpace : 0, needVerticalSpace)
                    } else {
                        needHorizontalSpace = _max(needPaneHorizontalSpace > 0 ? needPaneHorizontalSpace : 0, needHorizontalSpace);
                        needVerticalSpace += needPaneVerticalSpace > 0 ? needPaneVerticalSpace : 0
                    }
                });
                return needHorizontalSpace > 0 || needVerticalSpace > 0 ? {
                    width: needHorizontalSpace,
                    height: needVerticalSpace
                } : false
            },
            layoutElements: function(elements, canvas, funcAxisDrawer, panes, rotated, axes) {
                this._elements = elements;
                this._probeDrawing(canvas);
                this._drawElements(canvas);
                funcAxisDrawer && funcAxisDrawer();
                this._processAdaptiveLayout(panes, rotated, canvas, axes, funcAxisDrawer);
                this._positionElements(canvas)
            },
            _processAdaptiveLayout: function(panes, rotated, canvas, axes, funcAxisDrawer) {
                var that = this,
                    size = that.needMoreSpaceForPanesCanvas(panes, rotated),
                    items = this._elements;
                if (!size) {
                    return
                }

                function processCanvases(item, layoutOptions, side) {
                    if (!item.getLayoutOptions()[side]) {
                        canvas[layoutOptions.cutLayoutSide] -= layoutOptions[side];
                        size[side] = Math.max(size[side] - layoutOptions[side], 0)
                    }
                }
                $.each(items.slice().reverse(), function(_, item) {
                    var sizeObject, layoutOptions = _extend({}, item.getLayoutOptions());
                    if (!layoutOptions) {
                        return
                    }
                    sizeObject = $.extend({}, layoutOptions);
                    if ("vertical" === layoutOptions.cutSide && size.height) {
                        item.draw(sizeObject.width, sizeObject.height - size.height);
                        processCanvases(item, layoutOptions, "height")
                    }
                    if ("horizontal" === layoutOptions.cutSide && size.width) {
                        item.draw(sizeObject.width - size.width, sizeObject.height);
                        processCanvases(item, layoutOptions, "width")
                    }
                });
                updateAxis(axes.verticalAxes, "width", size);
                updateAxis(axes.horizontalAxes, "height", size);
                funcAxisDrawer && funcAxisDrawer(true)
            },
            _probeDrawing: function(canvas) {
                var that = this;
                $.each(this._elements, function(_, item) {
                    var sizeObject, layoutOptions = item.getLayoutOptions();
                    if (!layoutOptions) {
                        return
                    }
                    sizeObject = {
                        width: canvas.width - canvas.left - canvas.right,
                        height: canvas.height - canvas.top - canvas.bottom
                    };
                    if ("vertical" === layoutOptions.cutSide) {
                        sizeObject.height -= that._options.height
                    } else {
                        sizeObject.width -= that._options.width
                    }
                    item.probeDraw(sizeObject.width, sizeObject.height);
                    downSize(canvas, item.getLayoutOptions())
                })
            },
            _drawElements: function(canvas) {
                $.each(this._elements.slice().reverse(), function(_, item) {
                    var sizeObject, cutSide, length, layoutOptions = item.getLayoutOptions();
                    if (!layoutOptions) {
                        return
                    }
                    sizeObject = {
                        width: canvas.width - canvas.left - canvas.right,
                        height: canvas.height - canvas.top - canvas.bottom
                    };
                    cutSide = layoutOptions.cutSide;
                    length = "horizontal" === cutSide ? "width" : "height";
                    sizeObject[length] = layoutOptions[length];
                    item.draw(sizeObject.width, sizeObject.height)
                })
            },
            _positionElements: function(canvas) {
                var offsets = {
                    left: 0,
                    right: 0,
                    top: 0,
                    bottom: 0
                };
                $.each(this._elements.slice().reverse(), function(_, item) {
                    var position, cutSide, my, layoutOptions = item.getLayoutOptions();
                    if (!layoutOptions) {
                        return
                    }
                    position = layoutOptions.position;
                    cutSide = layoutOptions.cutSide;
                    my = {
                        horizontal: position.horizontal,
                        vertical: position.vertical
                    };
                    my[cutSide] = inverseAlign[my[cutSide]];
                    item.position({
                        of: toLayoutElementCoords(canvas),
                        my: my,
                        at: position,
                        offset: getOffset(layoutOptions, offsets)
                    });
                    offsets[layoutOptions.cutLayoutSide] += layoutOptions["horizontal" === layoutOptions.cutSide ? "width" : "height"]
                })
            }
        };
        exports.LayoutManager = LayoutManager
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/chart_components/tracker.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            clickEvent = __webpack_require__( /*! ../../events/click */ 64),
            eventsConsts = __webpack_require__( /*! ../components/consts */ 462).events,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            wheelEvent = __webpack_require__( /*! ../../events/core/wheel */ 77),
            holdEvent = __webpack_require__( /*! ../../events/hold */ 164),
            devices = __webpack_require__( /*! ../../core/devices */ 40),
            isDefined = commonUtils.isDefined,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            _floor = Math.floor,
            _each = $.each,
            _inArray = $.inArray,
            _noop = $.noop,
            MULTIPLE_MODE = "multiple",
            ALL_ARGUMENTS_POINTS_MODE = "allargumentpoints",
            ALL_SERIES_POINTS_MODE = "allseriespoints",
            NONE_MODE = "none",
            POINTER_ACTION = [pointerEvents.down, pointerEvents.move].join(" "),
            POINT_SELECTION_CHANGED = "pointSelectionChanged",
            LEGEND_CLICK = "legendClick",
            SERIES_CLICK = "seriesClick",
            POINT_CLICK = "pointClick",
            RELEASE_POINT_SELECTED_STATE = "releasePointSelectedState",
            SET_POINT_SELECTED_STATE = "setPointSelectedState",
            SET_POINT_HOVER_STATE = "setPointHoverState",
            SERIES_HOVER_CHANGED = "seriesHoverChanged",
            POINT_HOVER_CHANGED = "pointHoverChanged",
            RELEASE_POINT_HOVER_STATE = "releasePointHoverState",
            SERIES_SELECTION_CHANGED = "seriesSelectionChanged",
            ZOOM_START = "zoomStart",
            POINT_DATA = "chart-data-point",
            SERIES_DATA = "chart-data-series",
            ARG_DATA = "chart-data-argument",
            DELAY = 100;

        function getData(event, dataKey) {
            var target = event.target;
            return ("tspan" === target.tagName ? target.parentNode : target)[dataKey]
        }

        function eventCanceled(event, target) {
            return event.cancel || !target.getOptions()
        }

        function inCanvas(canvas, x, y) {
            return x >= canvas.left && x <= canvas.right && y >= canvas.top && y <= canvas.bottom
        }

        function setPointsSpecState(points, targetPoint, func, eventName, eventTrigger) {
            _each(points, function(_, currentPoint) {
                var series = currentPoint.series;
                if (currentPoint === targetPoint) {
                    series[func]({
                        point: currentPoint,
                        setState: true
                    });
                    eventName && eventTrigger(eventName, {
                        target: currentPoint
                    })
                } else {
                    series[func]({
                        point: currentPoint
                    })
                }
            })
        }

        function getArgumentPointsByIndex(storedSeries, argument, targetPointIndex) {
            var points = [];
            _each(storedSeries, function(_, series) {
                _each(series.getPointsByArg(argument), function(_, currentPoint) {
                    if (targetPointIndex === currentPoint.index) {
                        points.push(currentPoint)
                    }
                })
            });
            return points
        }
        var baseTrackerPrototype = {
            ctor: function(options) {
                var that = this,
                    data = {
                        tracker: that
                    };
                that._renderer = options.renderer;
                that._legend = options.legend;
                that._tooltip = options.tooltip;
                that._eventTrigger = options.eventTrigger;
                options.seriesGroup.off().on(eventsConsts.selectSeries, data, that._selectSeries).on(eventsConsts.deselectSeries, data, that._deselectSeries).on(eventsConsts.selectPoint, data, that._selectPoint).on(eventsConsts.deselectPoint, data, that._deselectPoint).on(eventsConsts.showPointTooltip, data, that._showPointTooltip).on(eventsConsts.hidePointTooltip, data, that._hidePointTooltip);
                that._renderer.root.off(POINTER_ACTION).off([clickEvent.name, holdEvent.name].join(" ")).on(POINTER_ACTION, data, that._pointerHandler).on(clickEvent.name, data, that._clickHandler).on(holdEvent.name, {
                    timeout: 300
                }, _noop)
            },
            _setSelectedPoint: _noop,
            _releaseSelectedPoint: _noop,
            _releaseSelectedSeries: _noop,
            _setSelectedSeries: _noop,
            update: function(options) {
                var that = this;
                if (_normalizeEnum(options.pointSelectionMode) === MULTIPLE_MODE) {
                    that._setSelectedPoint = that._selectPointMultipleMode;
                    that._releaseSelectedPoint = that._releaseSelectedPointMultipleMode
                } else {
                    that._setSelectedPoint = that._selectPointSingleMode;
                    that._releaseSelectedPoint = that._releaseSelectedPointSingleMode
                }
                if (_normalizeEnum(options.seriesSelectionMode) === MULTIPLE_MODE) {
                    that._releaseSelectedSeries = that._releaseSelectedSeriesMultipleMode;
                    that._setSelectedSeries = that._setSelectedSeriesMultipleMode
                } else {
                    that._releaseSelectedSeries = that._releaseSelectedSeriesSingleMode;
                    that._setSelectedSeries = that._setSelectedSeriesSingleMode
                }
                that._prepare()
            },
            updateSeries: function(series) {
                var that = this;
                if (that._storedSeries !== series) {
                    that._storedSeries = series || [];
                    that._clean()
                } else {
                    that._hideTooltip(that.pointAtShownTooltip);
                    that._clearHover();
                    that.clearSelection()
                }
            },
            setCanvases: function(mainCanvas, paneCanvases) {
                this._mainCanvas = mainCanvas;
                this._canvases = paneCanvases
            },
            repairTooltip: function() {
                var point = this.pointAtShownTooltip;
                if (point && !point.isVisible()) {
                    this._hideTooltip(point, true)
                } else {
                    this._showTooltip(point)
                }
            },
            _prepare: function() {
                this._toggleParentsScrollSubscription(true)
            },
            _toggleParentsScrollSubscription: function(subscribe) {
                var that = this,
                    $parents = $(that._renderer.root.element).parents(),
                    scrollEvents = "scroll.dxChartTracker";
                if ("generic" === devices.real().platform) {
                    $parents = $parents.add(window)
                }
                $().add(that._$prevRootParents).off(scrollEvents);
                if (subscribe) {
                    $parents.on(scrollEvents, function(e) {
                        that._pointerOut()
                    });
                    that._$prevRootParents = $parents
                }
            },
            _selectPointMultipleMode: function(point) {
                var that = this;
                that._selectedPoint = that._selectedPoint || [];
                if (_inArray(point, that._selectedPoint) < 0) {
                    that._selectedPoint.push(point);
                    that._setPointState(point, SET_POINT_SELECTED_STATE, _normalizeEnum(point.getOptions().selectionMode), POINT_SELECTION_CHANGED, that._legend.getActionCallback(point))
                }
            },
            _releaseSelectedPointMultipleMode: function(point) {
                var that = this,
                    points = that._selectedPoint || [],
                    pointIndex = _inArray(point, points);
                if (pointIndex >= 0) {
                    that._setPointState(point, RELEASE_POINT_SELECTED_STATE, _normalizeEnum(point.getOptions().selectionMode), POINT_SELECTION_CHANGED, that._legend.getActionCallback(point));
                    points.splice(pointIndex, 1)
                } else {
                    if (!point) {
                        _each(points, function(_, point) {
                            that._releaseSelectedPoint(point)
                        })
                    }
                }
            },
            _selectPointSingleMode: function(point) {
                var that = this;
                if (that._selectedPoint !== point) {
                    that._releaseSelectedPoint();
                    that._selectedPoint = point;
                    that._setPointState(point, SET_POINT_SELECTED_STATE, _normalizeEnum(point.getOptions().selectionMode), POINT_SELECTION_CHANGED, that._legend.getActionCallback(point))
                }
            },
            _releaseSelectedPointSingleMode: function() {
                var that = this,
                    point = that._selectedPoint;
                if (point) {
                    that._setPointState(point, RELEASE_POINT_SELECTED_STATE, _normalizeEnum(point.getOptions().selectionMode), POINT_SELECTION_CHANGED, that._legend.getActionCallback(point));
                    that._selectedPoint = null
                }
            },
            _setHoveredPoint: function(point, mode) {
                var that = this;
                var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
                debug.assert(point.series, "series was not assigned to point or empty");
                if (that.hoveredPoint === point || !point.series) {
                    return
                }
                that._releaseHoveredPoint();
                if (point && point.getOptions() && mode !== NONE_MODE) {
                    that.hoveredPoint = point;
                    that._setPointState(point, SET_POINT_HOVER_STATE, mode || _normalizeEnum(point.getOptions().hoverMode), POINT_HOVER_CHANGED, that._legend.getActionCallback(point))
                }
            },
            _releaseHoveredPoint: function() {
                var that = this,
                    point = that.hoveredPoint,
                    eventTrigger = that._eventTrigger;
                if (!point || !point.getOptions()) {
                    return
                }
                that._releasePoint(point, eventTrigger);
                if (that._tooltip.isEnabled()) {
                    that._hideTooltip(point)
                }
                that.hoveredPoint = null
            },
            _setSelectedSeriesMultipleMode: function(series, mode) {
                var that = this;
                that._selectedSeries = that._selectedSeries || [];
                if (_inArray(series, that._selectedSeries) < 0) {
                    that._selectedSeries.push(series);
                    series.setSelectedState(true, mode, that._legend.getActionCallback(series));
                    that._eventTrigger(SERIES_SELECTION_CHANGED, {
                        target: series
                    })
                }
            },
            _setSelectedSeriesSingleMode: function(series, mode) {
                var that = this;
                if (series !== that._selectedSeries || series.lastSelectionMode !== mode) {
                    that._releaseSelectedSeries();
                    that._selectedSeries = series;
                    series.setSelectedState(true, mode, that._legend.getActionCallback(series));
                    that._eventTrigger(SERIES_SELECTION_CHANGED, {
                        target: series
                    })
                }
            },
            _releaseSelectedSeriesMultipleMode: function(series) {
                var that = this,
                    selectedSeries = that._selectedSeries || [],
                    seriesIndex = _inArray(series, selectedSeries);
                if (seriesIndex >= 0) {
                    series.setSelectedState(false, void 0, that._legend.getActionCallback(series));
                    that._eventTrigger(SERIES_SELECTION_CHANGED, {
                        target: series
                    });
                    selectedSeries.splice(seriesIndex, 1)
                } else {
                    if (!series) {
                        _each(selectedSeries, function(_, series) {
                            that._releaseSelectedSeries(series)
                        })
                    }
                }
            },
            _releaseSelectedSeriesSingleMode: function(series) {
                var that = this,
                    selectedSeries = that._selectedSeries;
                if (selectedSeries && (!series || series === selectedSeries)) {
                    selectedSeries.setSelectedState(false, void 0, that._legend.getActionCallback(selectedSeries));
                    that._eventTrigger(SERIES_SELECTION_CHANGED, {
                        target: selectedSeries
                    });
                    that._selectedSeries = null
                }
            },
            _setHoveredSeries: function(series, mode) {
                var that = this;
                if (mode !== NONE_MODE && that.hoveredSeries !== series || that._isModeChanged(series, mode)) {
                    that._clearHover();
                    series.setHoverState(true, mode, that._legend.getActionCallback(series));
                    that._eventTrigger(SERIES_HOVER_CHANGED, {
                        target: series
                    });
                    that.hoveredSeries = series
                }
            },
            _releaseHoveredSeries: function(needSetHoverView, hoveredPoint) {
                var that = this,
                    hoveredSeries = that.hoveredSeries,
                    seriesWithHoverView = that._seriesWithHoverView;
                if (hoveredSeries) {
                    hoveredSeries.setHoverState(false, void 0, that._legend.getActionCallback(hoveredSeries));
                    if (needSetHoverView && hoveredPoint && hoveredPoint.series === hoveredSeries) {
                        that._seriesWithHoverView = hoveredSeries.setHoverView()
                    }
                    that._eventTrigger(SERIES_HOVER_CHANGED, {
                        target: hoveredSeries
                    });
                    that.hoveredSeries = null
                } else {
                    if (seriesWithHoverView && !needSetHoverView) {
                        seriesWithHoverView.releaseHoverView();
                        that._seriesWithHoverView = null
                    }
                }
            },
            _selectSeries: function(event, mode) {
                event.data.tracker._setSelectedSeries(event.target, mode)
            },
            _deselectSeries: function(event, mode) {
                event.data.tracker._releaseSelectedSeries(event.target, mode)
            },
            _selectPoint: function(event, point) {
                event.data.tracker._setSelectedPoint(point)
            },
            _deselectPoint: function(event, point) {
                event.data.tracker._releaseSelectedPoint(point)
            },
            clearSelection: function() {
                this._releaseSelectedPoint();
                this._releaseSelectedSeries()
            },
            _clean: function() {
                var that = this;
                that._selectedPoint = that._selectedSeries = that.hoveredPoint = that.hoveredSeries = that._hoveredArgumentPoints = that._seriesWithHoverView = null;
                that._hideTooltip(that.pointAtShownTooltip)
            },
            _clearHover: function() {
                this._releaseHoveredSeries(false);
                this._releaseHoveredPoint()
            },
            _hideTooltip: function(point, silent) {
                var that = this;
                if (!that._tooltip || point && that.pointAtShownTooltip !== point) {
                    return
                }
                if (!silent && that.pointAtShownTooltip) {
                    that.pointAtShownTooltip = null
                }
                that._tooltip.hide()
            },
            _showTooltip: function(point) {
                var tooltipFormatObject, eventData, that = this;
                if (point && point.getOptions()) {
                    tooltipFormatObject = point.getTooltipFormatObject(that._tooltip);
                    if (!isDefined(tooltipFormatObject.valueText) && !tooltipFormatObject.points || !point.isVisible()) {
                        return
                    }
                    if (!that.pointAtShownTooltip || that.pointAtShownTooltip !== point) {
                        eventData = {
                            target: point
                        }
                    }
                    var coords = point.getTooltipParams(that._tooltip.getLocation()),
                        rootOffset = that._renderer.getRootOffset();
                    coords.x += rootOffset.left;
                    coords.y += rootOffset.top;
                    if (!that._tooltip.show(tooltipFormatObject, coords, eventData)) {
                        return
                    }
                    that.pointAtShownTooltip = point
                }
            },
            _showPointTooltip: function(event, point) {
                var that = event.data.tracker,
                    pointWithTooltip = that.pointAtShownTooltip;
                if (pointWithTooltip && pointWithTooltip !== point) {
                    that._hideTooltip(pointWithTooltip)
                }
                that._showTooltip(point)
            },
            _hidePointTooltip: function(event, point) {
                event.data.tracker._hideTooltip(point)
            },
            _enableOutHandler: function() {
                if (this._outHandler) {
                    return
                }
                var that = this,
                    handler = function(e) {
                        var rootOffset = that._renderer.getRootOffset(),
                            x = _floor(e.pageX - rootOffset.left),
                            y = _floor(e.pageY - rootOffset.top);
                        if (!inCanvas(that._mainCanvas, x, y)) {
                            that._pointerOut();
                            that._disableOutHandler()
                        }
                    };
                $(document).on(POINTER_ACTION, handler);
                this._outHandler = handler
            },
            _disableOutHandler: function() {
                this._outHandler && $(document).off(POINTER_ACTION, this._outHandler);
                this._outHandler = null
            },
            _pointerOut: function() {
                this._clearHover();
                this._tooltip.isEnabled() && this._hideTooltip(this.pointAtShownTooltip)
            },
            _triggerLegendClick: function(eventArgs, elementClick) {
                var eventTrigger = this._eventTrigger;
                eventTrigger(LEGEND_CLICK, eventArgs, function() {
                    !eventCanceled(eventArgs.jQueryEvent, eventArgs.target) && eventTrigger(elementClick, eventArgs)
                })
            },
            _hoverLegendItem: function(x, y) {
                var series, that = this,
                    item = that._legend.getItemByCoord(x, y);
                if (item) {
                    series = that._storedSeries[item.id];
                    that._setHoveredSeries(series, that._legend._options.hoverMode);
                    that._tooltip.isEnabled() && that._hideTooltip(that.pointAtShownTooltip)
                } else {
                    that._clearHover()
                }
            },
            _pointerHandler: function(e) {
                var that = e.data.tracker,
                    rootOffset = that._renderer.getRootOffset(),
                    x = _floor(e.pageX - rootOffset.left),
                    y = _floor(e.pageY - rootOffset.top),
                    canvas = that._getCanvas(x, y),
                    series = getData(e, SERIES_DATA),
                    point = getData(e, POINT_DATA) || series && series.getPointByCoord(x, y);
                that._enableOutHandler();
                if (that._checkGestureEvents(e, canvas, rootOffset)) {
                    return
                }
                if (that._legend.coordsIn(x, y)) {
                    that._hoverLegendItem(x, y);
                    return
                }
                if (that.hoveredSeries && that.hoveredSeries !== that._stickedSeries) {
                    that._releaseHoveredSeries()
                }
                if (that._hoverArgumentAxis(x, y, e)) {
                    return
                }
                if (that._isPointerOut(canvas, point)) {
                    that._pointerOut()
                }
                if (!canvas && !point) {
                    return
                }
                if (series && !point) {
                    point = series.getNeighborPoint(x, y);
                    if (series !== that.hoveredSeries) {
                        that._setTimeout(function() {
                            that._setHoveredSeries(series, series.getOptions().hoverMode);
                            that._stickedSeries = series;
                            that._pointerComplete(point, x, y)
                        }, series);
                        return
                    }
                } else {
                    if (point) {
                        if (that.hoveredSeries) {
                            that._setTimeout(function() {
                                that._pointerOnPoint(point, x, y)
                            }, point)
                        } else {
                            that._pointerOnPoint(point, x, y);
                            that._setSeriesWithHoverView(point)
                        }
                        return
                    } else {
                        if (that._setStickedSeries(x, y)) {
                            series = that._stickedSeries;
                            point = series.getNeighborPoint(x, y);
                            that._releaseHoveredSeries();
                            point && that._setHoveredPoint(point)
                        }
                    }
                }
                that._pointerComplete(point, x, y)
            },
            _pointerOnPoint: function(point, x, y) {
                this._setHoveredPoint(point);
                this._pointerComplete(point, x, y)
            },
            _pointerComplete: function(point) {
                this.pointAtShownTooltip !== point && this._tooltip.isEnabled() && this._showTooltip(point)
            },
            _clickHandler: function(e) {
                var that = e.data.tracker,
                    rootOffset = that._renderer.getRootOffset(),
                    x = _floor(e.pageX - rootOffset.left),
                    y = _floor(e.pageY - rootOffset.top),
                    point = getData(e, POINT_DATA),
                    series = that._stickedSeries || getData(e, SERIES_DATA) || point && point.series,
                    axis = that._argumentAxis;
                if (that._legend.coordsIn(x, y)) {
                    var item = that._legend.getItemByCoord(x, y);
                    if (item) {
                        that._legendClick(item, e)
                    }
                } else {
                    if (axis && axis.coordsIn(x, y)) {
                        var argument = getData(e, ARG_DATA);
                        if (isDefined(argument)) {
                            that._eventTrigger("argumentAxisClick", {
                                argument: argument,
                                jQueryEvent: e
                            })
                        }
                    } else {
                        if (series) {
                            point = point || series.getPointByCoord(x, y);
                            if (point) {
                                that._pointClick(point, e)
                            } else {
                                getData(e, SERIES_DATA) && that._eventTrigger(SERIES_CLICK, {
                                    target: series,
                                    jQueryEvent: e
                                })
                            }
                        }
                    }
                }
            },
            dispose: function() {
                var that = this;
                that._disableOutHandler();
                that._toggleParentsScrollSubscription();
                _each(that, function(k) {
                    that[k] = null
                })
            }
        };
        var ChartTracker = function(options) {
            this.ctor(options)
        };
        $.extend(ChartTracker.prototype, baseTrackerPrototype, {
            _pointClick: function(point, event) {
                var that = this,
                    eventTrigger = that._eventTrigger,
                    series = point.series;
                eventTrigger(POINT_CLICK, {
                    target: point,
                    jQueryEvent: event
                }, function() {
                    !eventCanceled(event, series) && eventTrigger(SERIES_CLICK, {
                        target: series,
                        jQueryEvent: event
                    })
                })
            },
            __trackerDelay: DELAY,
            update: function(options) {
                var that = this;
                that._zoomingMode = _normalizeEnum(options.zoomingMode);
                that._scrollingMode = _normalizeEnum(options.scrollingMode);
                baseTrackerPrototype.update.call(this, options);
                that._argumentAxis = options.argumentAxis || {};
                that._axisHoverEnabled = that._argumentAxis && _normalizeEnum(that._argumentAxis.getOptions().hoverMode) === ALL_ARGUMENTS_POINTS_MODE;
                that._chart = options.chart;
                that._rotated = options.rotated;
                that._crosshair = options.crosshair
            },
            _getCanvas: function(x, y) {
                var that = this,
                    canvases = that._canvases || [];
                for (var i = 0; i < canvases.length; i++) {
                    var c = canvases[i];
                    if (inCanvas(c, x, y)) {
                        return c
                    }
                }
                return null
            },
            _getPointSeries: function(point) {
                return point.series
            },
            _isModeChanged: function(series, mode) {
                return series.lastHoverMode !== mode
            },
            _isPointerOut: function(canvas) {
                return !canvas && this._stickedSeries
            },
            _resetHoveredArgument: function() {
                if (isDefined(this.hoveredArgument)) {
                    this._toAllArgumentPoints(this.hoveredArgument, RELEASE_POINT_HOVER_STATE);
                    this.hoveredArgument = null
                }
            },
            _toAllArgumentPoints: function(argument, func, eventName, targetPoint) {
                var that = this;
                _each(that._storedSeries, function(_, series) {
                    setPointsSpecState(series.getPointsByArg(argument), targetPoint, func, eventName, that._eventTrigger)
                })
            },
            _hideCrosshair: function() {
                this._crosshair && this._crosshair.hide()
            },
            _moveCrosshair: function(point, x, y) {
                if (point && this._crosshair && point.isVisible()) {
                    this._crosshair.show({
                        point: point,
                        x: x,
                        y: y
                    })
                }
            },
            _releasePoint: function(point, eventTrigger) {
                var that = this,
                    mode = _normalizeEnum(point.getOptions().hoverMode);
                if (mode === ALL_SERIES_POINTS_MODE) {
                    setPointsSpecState(point.series.getPoints(), point, RELEASE_POINT_HOVER_STATE, POINT_HOVER_CHANGED, eventTrigger)
                } else {
                    if (mode === ALL_ARGUMENTS_POINTS_MODE) {
                        that._toAllArgumentPoints(point.argument, RELEASE_POINT_HOVER_STATE, POINT_HOVER_CHANGED, point)
                    } else {
                        if ("none" !== mode) {
                            that._getPointSeries(point).releasePointHoverState({
                                point: point,
                                setState: true,
                                legendCallback: that._legend.getActionCallback(point)
                            });
                            eventTrigger(POINT_HOVER_CHANGED, {
                                target: point
                            })
                        }
                    }
                }
            },
            _setPointState: function(point, action, mode, eventName, legendCallback) {
                var series, that = this,
                    eventTrigger = that._eventTrigger;
                switch (mode) {
                    case ALL_ARGUMENTS_POINTS_MODE:
                        that._toAllArgumentPoints(point.argument, action, eventName, point);
                        break;
                    case ALL_SERIES_POINTS_MODE:
                        setPointsSpecState(point.series.getPoints(), point, action, eventName, eventTrigger);
                        break;
                    case NONE_MODE:
                        break;
                    default:
                        series = that._getPointSeries(point);
                        series[action]({
                            point: point,
                            legendCallback: legendCallback,
                            setState: true
                        });
                        eventTrigger(eventName, {
                            target: point
                        })
                }
            },
            _prepare: function() {
                var that = this,
                    root = that._renderer.root,
                    touchScrollingEnabled = "all" === that._scrollingMode || "touch" === that._scrollingMode,
                    touchZoomingEnabled = "all" === that._zoomingMode || "touch" === that._zoomingMode,
                    cssValue = (!touchScrollingEnabled ? "pan-x pan-y " : "") + (!touchZoomingEnabled ? "pinch-zoom" : "") || "none",
                    rootStyles = {
                        "touch-action": cssValue,
                        "-ms-touch-action": cssValue
                    },
                    wheelzoomingEnabled = "all" === that._zoomingMode || "mouse" === that._zoomingMode;
                root.off(wheelEvent.name + " dxc-scroll-start dxc-scroll-move");
                baseTrackerPrototype._prepare.call(that);
                if (!that._gestureEndHandler) {
                    that._gestureEndHandler = function() {
                        that._gestureEnd && that._gestureEnd()
                    };
                    $(document).on(pointerEvents.up, that._gestureEndHandler)
                }
                wheelzoomingEnabled && root.on(wheelEvent.name, function(e) {
                    var rootOffset = that._renderer.getRootOffset(),
                        x = that._rotated ? e.pageY - rootOffset.top : e.pageX - rootOffset.left,
                        scale = that._argumentAxis.getTranslator().getMinScale(e.delta > 0),
                        translate = x - x * scale,
                        zoom = that._argumentAxis.getTranslator().zoom(-translate, scale);
                    that._pointerOut();
                    that._eventTrigger(ZOOM_START);
                    that._chart.zoomArgument(zoom.min, zoom.max, true);
                    e.preventDefault();
                    e.stopPropagation()
                });
                root.on("dxc-scroll-start", function(e) {
                    that._startScroll = true;
                    that._gestureStart(that._getGestureParams(e, {
                        left: 0,
                        top: 0
                    }))
                }).on("dxc-scroll-move", function(e) {
                    that._gestureChange(that._getGestureParams(e, {
                        left: 0,
                        top: 0
                    })) && e.preventDefault()
                });
                root.css(rootStyles)
            },
            _getGestureParams: function(e, offset) {
                var x1, x2, left, right, that = this,
                    touches = e.pointers.length,
                    eventCoordField = that._rotated ? "pageY" : "pageX";
                offset = that._rotated ? offset.top : offset.left;
                if (2 === touches) {
                    x1 = e.pointers[0][eventCoordField] - offset, x2 = e.pointers[1][eventCoordField] - offset
                } else {
                    if (1 === touches) {
                        x1 = x2 = e.pointers[0][eventCoordField] - offset
                    }
                }
                left = Math.min(x1, x2);
                right = Math.max(x1, x2);
                return {
                    center: left + (right - left) / 2,
                    distance: right - left,
                    touches: touches,
                    scale: 1,
                    pointerType: e.pointerType
                }
            },
            _gestureStart: function(gestureParams) {
                var that = this;
                that._startGesture = that._startGesture || gestureParams;
                if (that._startGesture.touches !== gestureParams.touches) {
                    that._startGesture = gestureParams
                }
            },
            _gestureChange: function(gestureParams) {
                var that = this,
                    startGesture = that._startGesture,
                    gestureChanged = false,
                    scrollingEnabled = "all" === that._scrollingMode || "none" !== that._scrollingMode && that._scrollingMode === gestureParams.pointerType,
                    zoomingEnabled = "all" === that._zoomingMode || "touch" === that._zoomingMode;
                if (!startGesture) {
                    return gestureChanged
                }
                if (1 === startGesture.touches && Math.abs(startGesture.center - gestureParams.center) < 3) {
                    that._gestureStart(gestureParams);
                    return gestureChanged
                }
                if (2 === startGesture.touches && zoomingEnabled) {
                    gestureChanged = true;
                    startGesture.scale = gestureParams.distance / startGesture.distance;
                    startGesture.scroll = gestureParams.center - startGesture.center + (startGesture.center - startGesture.center * startGesture.scale)
                } else {
                    if (1 === startGesture.touches && scrollingEnabled) {
                        gestureChanged = true;
                        startGesture.scroll = gestureParams.center - startGesture.center
                    }
                }
                if (gestureChanged) {
                    if (that._startScroll) {
                        that._eventTrigger(ZOOM_START);
                        that._startScroll = false
                    }
                    startGesture.changed = gestureChanged;
                    that._chart._transformArgument(startGesture.scroll, startGesture.scale)
                }
                return gestureChanged
            },
            _gestureEnd: function() {
                var zoom, that = this,
                    startGesture = that._startGesture,
                    renderer = that._renderer;
                that._startGesture = null;
                that._startScroll = false;

                function complete() {
                    that._chart.zoomArgument(zoom.min, zoom.max, true)
                }
                if (startGesture && startGesture.changed) {
                    zoom = that._argumentAxis._translator.zoom(-startGesture.scroll, startGesture.scale);
                    if (renderer.animationEnabled() && (-startGesture.scroll !== zoom.translate || startGesture.scale !== zoom.scale)) {
                        var translateDelta = -(startGesture.scroll + zoom.translate),
                            scaleDelta = startGesture.scale - zoom.scale;
                        renderer.root.animate({
                            _: 0
                        }, {
                            step: function(pos) {
                                var translateValue = -startGesture.scroll - translateDelta * pos,
                                    scaleValue = startGesture.scale - scaleDelta * pos;
                                that._chart._transformArgument(-translateValue, scaleValue)
                            },
                            complete: complete,
                            duration: 250
                        })
                    } else {
                        complete()
                    }
                }
            },
            _clean: function() {
                var that = this;
                baseTrackerPrototype._clean.call(that);
                that._resetTimer();
                that._stickedSeries = null
            },
            _getSeriesForShared: function(x, y) {
                var that = this,
                    points = [],
                    point = null,
                    distance = 1 / 0;
                if (that._tooltip.isShared() && !that.hoveredSeries) {
                    _each(that._storedSeries, function(_, series) {
                        var point = series.getNeighborPoint(x, y);
                        point && points.push(point)
                    });
                    _each(points, function(_, p) {
                        var coords = p.getCrosshairData(x, y),
                            d = vizUtils.getDistance(x, y, coords.x, coords.y);
                        if (d < distance) {
                            point = p;
                            distance = d
                        }
                    })
                }
                return point && point.series
            },
            _setTimeout: function(callback, keeper) {
                var that = this;
                if (that._timeoutKeeper !== keeper) {
                    that._resetTimer();
                    that._hoverTimeout = setTimeout(function() {
                        callback();
                        that._timeoutKeeper = null
                    }, DELAY);
                    that._timeoutKeeper = keeper
                }
            },
            _resetTimer: function() {
                clearTimeout(this._hoverTimeout);
                this._timeoutKeeper = this._hoverTimeout = null
            },
            _checkGestureEvents: function(e, canvas, rootOffset) {
                var that = this;
                if (e.type === pointerEvents.down) {
                    if (canvas) {
                        that._startScroll = true;
                        that._gestureStart(that._getGestureParams(e, rootOffset))
                    }
                } else {
                    if (that._startGesture && canvas) {
                        if (that._gestureChange(that._getGestureParams(e, rootOffset))) {
                            that._pointerOut();
                            e.preventDefault();
                            return true
                        }
                    }
                }
            },
            _setStickedSeries: function(x, y) {
                this._stickedSeries = this._stickedSeries || this._getSeriesForShared(x, y);
                return !!this._stickedSeries
            },
            _setSeriesWithHoverView: function(point) {
                this._seriesWithHoverView = point.series.setHoverView()
            },
            _pointerOut: function() {
                var that = this;
                that._stickedSeries = null;
                that._hideCrosshair();
                that._resetHoveredArgument();
                that._resetTimer();
                baseTrackerPrototype._pointerOut.call(that)
            },
            _hoverArgumentAxis: function(x, y, e) {
                var that = this;
                that._resetHoveredArgument();
                if (that._axisHoverEnabled && that._argumentAxis.coordsIn(x, y)) {
                    var argument = getData(e, ARG_DATA);
                    if (isDefined(argument) && that.hoveredArgument !== argument) {
                        that._clearHover();
                        that._toAllArgumentPoints(argument, SET_POINT_HOVER_STATE);
                        that.hoveredArgument = argument
                    }
                    return true
                }
            },
            _pointerComplete: function(point, x, y) {
                var that = this;
                that.hoveredSeries && that.hoveredSeries.updateHover(x, y);
                that._resetTimer();
                that._moveCrosshair(point, x, y);
                baseTrackerPrototype._pointerComplete.call(that, point)
            },
            _legendClick: function(item, e) {
                var series = this._storedSeries[item.id];
                this._triggerLegendClick({
                    target: series,
                    jQueryEvent: e
                }, SERIES_CLICK)
            },
            _hoverLegendItem: function(x, y) {
                this._stickedSeries = null;
                this._hideCrosshair();
                baseTrackerPrototype._hoverLegendItem.call(this, x, y)
            },
            _pointerOnPoint: function(point, x, y) {
                var that = this,
                    seriesWithHoverView = that._seriesWithHoverView,
                    seriesFromPoint = point.series;
                that._stickedSeries = seriesFromPoint;
                that._releaseHoveredSeries(!seriesWithHoverView || seriesWithHoverView === seriesFromPoint, point);
                baseTrackerPrototype._pointerOnPoint.call(that, point, x, y)
            },
            dispose: function() {
                this._gestureEndHandler && $(document).off(pointerEvents.up, this._gestureEndHandler);
                this._resetTimer();
                baseTrackerPrototype.dispose.call(this)
            }
        });
        var PieTracker = function(options) {
            this.ctor(options)
        };
        $.extend(PieTracker.prototype, baseTrackerPrototype, {
            _getPointSeries: function(point) {
                return this._storedSeries[point.index]
            },
            _isModeChanged: function() {
                return false
            },
            _isPointerOut: function(_, point) {
                return !point
            },
            _legendClick: function(item, e) {
                var points, that = this,
                    argument = item.argument;
                if (1 === that._storedSeries.length) {
                    points = getArgumentPointsByIndex(that._storedSeries, argument, item.id);
                    that._triggerLegendClick({
                        target: points[0],
                        jQueryEvent: e
                    }, POINT_CLICK)
                } else {
                    that._eventTrigger(LEGEND_CLICK, {
                        target: argument,
                        jQueryEvent: e
                    })
                }
            },
            _pointClick: function(point, e) {
                this._eventTrigger(POINT_CLICK, {
                    target: point,
                    jQueryEvent: e
                })
            },
            _releasePoint: function(point, eventTrigger) {
                var that = this,
                    mode = _normalizeEnum(point.getOptions().hoverMode);
                if ("none" !== mode) {
                    that._getPointSeries(point).releasePointHoverState({
                        point: point,
                        setState: true,
                        legendCallback: that._legend.getActionCallback(point)
                    });
                    eventTrigger(POINT_HOVER_CHANGED, {
                        target: point
                    })
                }
            },
            _setPointState: function(point, action, mode, eventName, legendCallback) {
                var series, that = this,
                    eventTrigger = that._eventTrigger;
                if ("none" !== mode) {
                    series = that._getPointSeries(point);
                    series[action]({
                        point: point,
                        legendCallback: legendCallback,
                        setState: true
                    });
                    eventTrigger(eventName, {
                        target: point
                    })
                }
            },
            _hoverArgumentAxis: _noop,
            _setStickedSeries: _noop,
            _setSeriesWithHoverView: _noop,
            _getCanvas: _noop,
            _checkGestureEvents: _noop
        });
        exports.ChartTracker = ChartTracker;
        exports.PieTracker = PieTracker
    },
    /*!******************************************************!*\
      !*** ./Scripts/viz/chart_components/header_block.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            LayoutElementModule = __webpack_require__( /*! ../core/layout_element */ 457),
            _extend = $.extend,
            _each = $.each;

        function HeaderBlock(elements) {}
        _extend(HeaderBlock.prototype, LayoutElementModule.LayoutElement.prototype, {
            update: function(elements, canvas) {
                this._elements = $.map(elements, function(element) {
                    return element.getLayoutOptions() ? element : null
                });
                this._canvas = canvas
            },
            dispose: function() {
                this._elements = null
            },
            measure: function(size) {
                var result, that = this,
                    layoutOptions = that.getLayoutOptions();
                if (layoutOptions) {
                    result = {
                        size: [layoutOptions.width, layoutOptions.height],
                        alignment: [layoutOptions.horizontalAlignment, layoutOptions.verticalAlignment],
                        side: 1
                    };
                    _each(that._elements, function(_, elem) {
                        elem.draw(layoutOptions.width, layoutOptions.height, that._canvas)
                    })
                }
                return result || null
            },
            getLayoutOptions: function() {
                var firstElement, layout, elementLayout, that = this,
                    elements = that._elements,
                    length = elements.length,
                    i = 1;
                if (!length) {
                    return null
                }
                firstElement = elements[0];
                layout = _extend(true, {}, firstElement.getLayoutOptions());
                layout.position = {};
                for (i; i < length; i++) {
                    elementLayout = elements[i].getLayoutOptions();
                    if (elementLayout.height > layout.height) {
                        layout.height = elementLayout.height
                    }
                    if (elementLayout.width > layout.width) {
                        layout.width = elementLayout.width
                    }
                    if (elementLayout.position) {
                        layout.position = elementLayout.position;
                        layout.verticalAlignment = elementLayout.position.vertical;
                        layout.horizontalAlignment = elementLayout.position.horizontal
                    }
                }
                return layout
            },
            probeDraw: function(width, height) {
                _each(this._elements, function(_, elem) {
                    elem.probeDraw(width, height)
                })
            },
            draw: function(width, height) {
                var that = this;
                _each(this._elements, function(_, elem) {
                    elem.draw(width, height, that._canvas)
                })
            },
            shift: function(x, y) {
                _each(this._elements, function(_, elem) {
                    elem.shift(x, y)
                })
            }
        });
        exports.HeaderBlock = HeaderBlock
    },
    /*!*****************************************!*\
      !*** ./Scripts/viz/core/data_source.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var dataSourceBaseModule = __webpack_require__( /*! ../../data/data_source/data_source */ 155),
            _isArray = __webpack_require__( /*! ../../core/utils/common */ 14).isArray;

        function createDataSource(options) {
            var ops = dataSourceBaseModule.normalizeDataSourceOptions(options);
            "paginate" in ops || (ops.paginate = false);
            return new dataSourceBaseModule.DataSource(ops)
        }

        function DataSource(callback) {
            this._callback = callback;
            this._items = this._ds = null;
            this._isShared = false
        }
        DataSource.prototype = {
            constructor: DataSource,
            dispose: function() {
                this._reset()
            },
            isLoaded: function() {
                return !this._ds || this._ds.isLoaded()
            },
            items: function() {
                return this._ds ? this._ds.items() : this._items
            },
            _reset: function() {
                var that = this;
                that._items = null;
                if (that._ds) {
                    if (that._isShared) {
                        that._ds.off("changed", that._callback);
                        that._ds.off("loadError", that._callback)
                    } else {
                        that._ds.dispose()
                    }
                    that._ds = null;
                    that._isShared = false
                }
            },
            update: function(value) {
                var that = this;
                that._reset();
                if (!value || _isArray(value)) {
                    that._items = value || null;
                    that._callback()
                } else {
                    that._isShared = value instanceof dataSourceBaseModule.DataSource;
                    that._ds = that._isShared ? value : createDataSource(value);
                    that._ds.on({
                        changed: that._callback,
                        loadError: that._callback
                    });
                    if (that._ds.isLoaded()) {
                        that._callback()
                    } else {
                        that._ds.load()
                    }
                }
            }
        };
        exports.DataSource = DataSource;
        exports.plugin = {
            name: "data_source",
            init: function() {
                var that = this;
                that._dataSource = new exports.DataSource(function() {
                    that._dataSourceChangedHandler()
                })
            },
            dispose: function() {
                this._dataSource.dispose()
            },
            members: {
                _updateDataSource: function() {
                    this._dataSource.update(this.option("dataSource"))
                }
            }
        }
    },
    /*!***********************************!*\
      !*** ./Scripts/viz/core/title.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _Number = Number,
            _isString = __webpack_require__( /*! ../../core/utils/common */ 14).isString,
            _patchFontOptions = __webpack_require__( /*! ./utils */ 442).patchFontOptions,
            parseHorizontalAlignment = __webpack_require__( /*! ./utils */ 442).enumParser(["left", "center", "right"]),
            parseVerticalAlignment = __webpack_require__( /*! ./utils */ 442).enumParser(["top", "bottom"]),
            DEFAULT_MARGIN = 10,
            DEFAULT_GAP = 3;

        function hasText(text) {
            return !!(text && String(text).length > 0)
        }

        function processTitleLength(elem, text, width) {
            if (elem.attr({
                    text: text
                }).applyEllipsis(width)) {
                elem.setTitle(text)
            }
        }

        function pickMarginValue(value) {
            return value >= 0 ? _Number(value) : DEFAULT_MARGIN
        }

        function validateMargin(margin) {
            var result;
            if (margin >= 0) {
                result = {
                    left: _Number(margin),
                    top: _Number(margin),
                    right: _Number(margin),
                    bottom: _Number(margin)
                }
            } else {
                margin = margin || {};
                result = {
                    left: pickMarginValue(margin.left),
                    top: pickMarginValue(margin.top),
                    right: pickMarginValue(margin.right),
                    bottom: pickMarginValue(margin.bottom)
                }
            }
            return result
        }

        function Title(params) {
            this._params = params;
            this._group = params.renderer.g().attr({
                "class": params.cssClass
            }).linkOn(params.renderer.root, {
                name: "title",
                after: "peripheral"
            });
            this._hasText = false
        }
        __webpack_require__( /*! jquery */ 9).extend(Title.prototype, __webpack_require__( /*! ./layout_element */ 457).LayoutElement.prototype, {
            dispose: function() {
                var that = this;
                that._group.linkRemove();
                that._group.linkOff();
                if (that._titleElement) {
                    that._clipRect.dispose();
                    that._titleElement = that._subtitleElement = that._clipRect = null
                }
                that._params = that._group = that._options = null
            },
            _updateOptions: function(options) {
                this._options = options;
                this._options.horizontalAlignment = parseHorizontalAlignment(options.horizontalAlignment, "center");
                this._options.verticalAlignment = parseVerticalAlignment(options.verticalAlignment, "top");
                this._options.margin = validateMargin(options.margin)
            },
            _updateStructure: function() {
                var that = this,
                    renderer = that._params.renderer,
                    group = that._group,
                    alignObj = {
                        align: that._options.horizontalAlignment
                    };
                if (!that._titleElement) {
                    that._titleElement = renderer.text().attr(alignObj).append(group);
                    that._subtitleElement = renderer.text().attr(alignObj);
                    that._clipRect = renderer.clipRect();
                    group.attr({
                        clipId: that._clipRect.id
                    })
                }
                group.linkAppend();
                hasText(that._options.subtitle.text) ? that._subtitleElement.append(group) : that._subtitleElement.remove()
            },
            _updateTexts: function() {
                var titleBox, y, that = this,
                    options = that._options,
                    subtitleOptions = options.subtitle,
                    titleElement = that._titleElement,
                    subtitleElement = that._subtitleElement,
                    testText = "A";
                titleElement.attr({
                    text: testText,
                    y: 0
                }).css(_patchFontOptions(options.font));
                titleBox = titleElement.getBBox();
                that._titleTextY = titleBox.height + titleBox.y;
                titleElement.attr({
                    text: options.text
                });
                titleBox = titleElement.getBBox();
                y = -titleBox.y;
                titleElement.attr({
                    y: y
                });
                if (hasText(subtitleOptions.text)) {
                    y += titleBox.height + titleBox.y;
                    subtitleElement.attr({
                        text: subtitleOptions.text,
                        y: 0
                    }).css(_patchFontOptions(subtitleOptions.font));
                    y += -subtitleElement.getBBox().y - that._titleTextY + DEFAULT_GAP;
                    subtitleElement.attr({
                        y: y
                    })
                }
            },
            _updateBoundingRectAlignment: function() {
                var boundingRect = this._boundingRect,
                    options = this._options;
                boundingRect.verticalAlignment = options.verticalAlignment;
                boundingRect.horizontalAlignment = options.horizontalAlignment;
                boundingRect.cutLayoutSide = options.verticalAlignment;
                boundingRect.cutSide = "vertical";
                boundingRect.position = {
                    horizontal: options.horizontalAlignment,
                    vertical: options.verticalAlignment
                }
            },
            update: function(options) {
                var that = this,
                    _hasText = hasText(options.text),
                    isLayoutChanged = _hasText || _hasText !== that._hasText;
                if (_hasText) {
                    that._updateOptions(options);
                    that._updateStructure();
                    that._updateTexts();
                    that._boundingRect = {};
                    that._updateBoundingRect();
                    that._updateBoundingRectAlignment()
                } else {
                    that._group.linkRemove();
                    that._boundingRect = null
                }
                that._hasText = _hasText;
                return isLayoutChanged
            },
            draw: function(width, height) {
                var layoutOptions, that = this;
                that._group.linkAppend();
                that._correctTitleLength(width);
                layoutOptions = that.getLayoutOptions();
                if (layoutOptions.width > width || layoutOptions.height > height) {
                    that._params.incidentOccurred("W2103");
                    that._group.linkRemove();
                    that._boundingRect.width = that._boundingRect.height = 0
                }
                return that
            },
            probeDraw: function(width, height) {
                this.draw(width, height);
                return this
            },
            _correctTitleLength: function(width) {
                var that = this,
                    options = that._options,
                    margin = options.margin,
                    maxWidth = width - margin.left - margin.right;
                processTitleLength(that._titleElement, options.text, maxWidth);
                that._subtitleElement && processTitleLength(that._subtitleElement, options.subtitle.text, maxWidth);
                that._updateBoundingRect()
            },
            getLayoutOptions: function() {
                return this._boundingRect || null
            },
            shift: function(x, y) {
                var that = this,
                    box = that.getLayoutOptions();
                that._group.move(x - box.x, y - box.y);
                that._setClipRectSettings();
                return that
            },
            _setClipRectSettings: function() {
                var bbox = this.getLayoutOptions();
                this._clipRect.attr({
                    x: bbox.x,
                    y: bbox.y,
                    width: bbox.width,
                    height: bbox.height
                })
            },
            _updateBoundingRect: function() {
                var box, that = this,
                    options = that._options,
                    margin = options.margin,
                    boundingRect = that._boundingRect;
                box = that._group.getBBox();
                box.height += margin.top + margin.bottom - that._titleTextY;
                box.width += margin.left + margin.right;
                box.x -= margin.left;
                box.y += that._titleTextY - margin.top;
                if (options.placeholderSize > 0) {
                    box.height = options.placeholderSize
                }
                boundingRect.height = box.height;
                boundingRect.width = box.width;
                boundingRect.x = box.x;
                boundingRect.y = box.y
            },
            layoutOptions: function() {
                return this._boundingRect && {
                    horizontalAlignment: this._boundingRect.horizontalAlignment,
                    verticalAlignment: this._boundingRect.verticalAlignment
                }
            },
            measure: function(size) {
                this.draw(size[0], size[1]);
                return [this._boundingRect.width, this._boundingRect.height]
            },
            move: function(rect) {
                var boundingRect = this._boundingRect;
                if (rect[2] - rect[0] < boundingRect.width || rect[3] - rect[1] < boundingRect.height) {
                    this.draw(rect[2] - rect[0], rect[3] - rect[1])
                }
                this.shift(Math.round(rect[0]), Math.round(rect[1]))
            }
        });
        exports.Title = Title;
        Title.prototype.DEBUG_getOptions = function() {
            return this._options
        };

        function processTitleOptions(options) {
            var newOptions = _isString(options) ? {
                text: options
            } : options || {};
            newOptions.subtitle = _isString(newOptions.subtitle) ? {
                text: newOptions.subtitle
            } : newOptions.subtitle || {};
            return newOptions
        }
        exports.plugin = {
            name: "title",
            init: function() {
                var that = this;
                that._title = new exports.Title({
                    renderer: that._renderer,
                    cssClass: that._rootClassPrefix + "-title",
                    incidentOccurred: that._incidentOccurred
                });
                that._layout.add(that._title)
            },
            dispose: function() {
                this._title.dispose();
                this._title = null
            },
            members: {
                _getTitleOptions: function() {
                    return $.extend(true, {}, this._themeManager.theme("title"), processTitleOptions(this.option("title")))
                }
            },
            customize: function(constructor) {
                constructor.addChange({
                    code: "TITLE",
                    handler: function() {
                        if (this._title.update(this._getTitleOptions())) {
                            this._change(["LAYOUT"])
                        }
                    },
                    isThemeDependent: true,
                    option: "title",
                    isOptionChange: true
                })
            }
        }
    },
    /*!*************************************!*\
      !*** ./Scripts/viz/core/tooltip.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var doc = document,
            win = window,
            $ = __webpack_require__( /*! jquery */ 9),
            rendererModule = __webpack_require__( /*! ./renderers/renderer */ 451),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            HALF_ARROW_WIDTH = 10,
            vizUtils = __webpack_require__( /*! ./utils */ 442),
            _format = __webpack_require__( /*! ./format */ 465),
            mathCeil = Math.ceil;

        function hideElement($element) {
            $element.css({
                left: "-9999px"
            }).detach()
        }

        function getSpecialFormatOptions(options, specialFormat) {
            var ret = options;
            switch (specialFormat) {
                case "argument":
                    ret = {
                        format: options.argumentFormat,
                        precision: options.argumentPrecision
                    };
                    break;
                case "percent":
                    ret = {
                        format: {
                            type: "percent",
                            precision: options.format && options.format.percentPrecision || options.percentPrecision
                        }
                    }
            }
            return ret
        }

        function Tooltip(params) {
            var renderer, root, that = this;
            that._eventTrigger = params.eventTrigger;
            that._wrapper = $("<div></div>").css({
                position: "absolute",
                overflow: "visible",
                width: 0,
                height: 0,
                "pointer-events": "none"
            }).addClass(params.cssClass);
            that._renderer = renderer = new rendererModule.Renderer({
                pathModified: params.pathModified,
                container: that._wrapper[0]
            });
            root = renderer.root;
            root.attr({
                "pointer-events": "none"
            });
            that._cloud = renderer.path([], "area").sharp().append(root);
            that._shadow = renderer.shadowFilter();
            that._textGroup = renderer.g().attr({
                align: "center"
            }).append(root);
            that._text = renderer.text(void 0, 0, 0).append(that._textGroup);
            that._textGroupHtml = $("<div></div>").css({
                position: "absolute",
                width: 0,
                padding: 0,
                margin: 0,
                border: "0px solid transparent"
            }).appendTo(that._wrapper);
            that._textHtml = $("<div></div>").css({
                position: "relative",
                display: "inline-block",
                padding: 0,
                margin: 0,
                border: "0px solid transparent"
            }).appendTo(that._textGroupHtml)
        }
        Tooltip.prototype = {
            constructor: Tooltip,
            dispose: function() {
                this._wrapper.remove();
                this._renderer.dispose();
                this._options = null
            },
            setOptions: function(options) {
                options = options || {};
                var that = this,
                    cloudSettings = that._cloudSettigns = {
                        opacity: options.opacity,
                        filter: that._shadow.ref,
                        "stroke-width": null,
                        stroke: null
                    },
                    borderOptions = options.border || {},
                    container = $(options.container);
                that._container = (container.length ? container : $("body")).get(0);
                that._shadowSettings = $.extend({
                    x: "-50%",
                    y: "-50%",
                    width: "200%",
                    height: "200%"
                }, options.shadow);
                that._options = options;
                if (borderOptions.visible) {
                    $.extend(cloudSettings, {
                        "stroke-width": borderOptions.width,
                        stroke: borderOptions.color,
                        "stroke-opacity": borderOptions.opacity,
                        dashStyle: borderOptions.dashStyle
                    })
                }
                that._textFontStyles = vizUtils.patchFontOptions(options.font);
                that._textFontStyles.color = options.font.color;
                that._wrapper.css({
                    "z-index": options.zIndex
                });
                that._customizeTooltip = $.isFunction(options.customizeTooltip) ? options.customizeTooltip : null;
                return that
            },
            setRendererOptions: function(options) {
                this._renderer.setOptions(options);
                this._textGroupHtml.css({
                    direction: options.rtl ? "rtl" : "ltr"
                });
                return this
            },
            render: function() {
                var that = this;
                hideElement(that._wrapper);
                that._cloud.attr(that._cloudSettigns);
                that._shadow.attr(that._shadowSettings);
                that._textGroupHtml.css(that._textFontStyles);
                that._textGroup.css(that._textFontStyles);
                that._text.css(that._textFontStyles);
                that._eventData = null;
                return that
            },
            update: function(options) {
                return this.setOptions(options).render()
            },
            _prepare: function(formatObject, state) {
                var options = this._options,
                    customize = {};
                if (this._customizeTooltip) {
                    customize = this._customizeTooltip.call(formatObject, formatObject);
                    customize = $.isPlainObject(customize) ? customize : {};
                    if ("text" in customize) {
                        state.text = commonUtils.isDefined(customize.text) ? String(customize.text) : ""
                    }
                    if ("html" in customize) {
                        state.html = commonUtils.isDefined(customize.html) ? String(customize.html) : ""
                    }
                }
                if (!("text" in state) && !("html" in state)) {
                    state.text = formatObject.valueText || ""
                }
                state.color = customize.color || options.color;
                state.borderColor = customize.borderColor || (options.border || {}).color;
                state.textColor = customize.fontColor || (options.font || {}).color;
                return !!state.text || !!state.html
            },
            show: function(formatObject, params, eventData) {
                var bBox, contentSize, that = this,
                    state = {},
                    options = that._options,
                    plr = options.paddingLeftRight,
                    ptb = options.paddingTopBottom,
                    textGroupHtml = that._textGroupHtml,
                    textHtml = that._textHtml,
                    ss = that._shadowSettings,
                    xOff = ss.offsetX,
                    yOff = ss.offsetY,
                    blur = 2 * ss.blur + 1,
                    getComputedStyle = win.getComputedStyle;
                if (!that._prepare(formatObject, state)) {
                    return false
                }
                that._state = state;
                state.tc = {};
                that._wrapper.appendTo(that._container);
                that._cloud.attr({
                    fill: state.color,
                    stroke: state.borderColor
                });
                if (state.html) {
                    that._text.attr({
                        text: ""
                    });
                    textGroupHtml.css({
                        color: state.textColor,
                        width: that._getCanvas().width
                    });
                    textHtml.html(state.html);
                    if (getComputedStyle) {
                        bBox = getComputedStyle(textHtml.get(0));
                        bBox = {
                            x: 0,
                            y: 0,
                            width: mathCeil(parseFloat(bBox.width)),
                            height: mathCeil(parseFloat(bBox.height))
                        }
                    } else {
                        bBox = textHtml.get(0).getBoundingClientRect();
                        bBox = {
                            x: 0,
                            y: 0,
                            width: mathCeil(bBox.width ? bBox.width : bBox.right - bBox.left),
                            height: mathCeil(bBox.height ? bBox.height : bBox.bottom - bBox.top)
                        }
                    }
                    textGroupHtml.width(bBox.width);
                    textGroupHtml.height(bBox.height)
                } else {
                    textHtml.html("");
                    that._text.css({
                        fill: state.textColor
                    }).attr({
                        text: state.text
                    });
                    bBox = that._textGroup.css({
                        fill: state.textColor
                    }).getBBox()
                }
                contentSize = state.contentSize = {
                    x: bBox.x - plr,
                    y: bBox.y - ptb,
                    width: bBox.width + 2 * plr,
                    height: bBox.height + 2 * ptb,
                    lm: blur - xOff > 0 ? blur - xOff : 0,
                    rm: blur + xOff > 0 ? blur + xOff : 0,
                    tm: blur - yOff > 0 ? blur - yOff : 0,
                    bm: blur + yOff > 0 ? blur + yOff : 0
                };
                contentSize.fullWidth = contentSize.width + contentSize.lm + contentSize.rm;
                contentSize.fullHeight = contentSize.height + contentSize.tm + contentSize.bm + options.arrowLength;
                that.move(params.x, params.y, params.offset);
                that._eventData && that._eventTrigger("tooltipHidden", that._eventData);
                that._eventData = eventData;
                that._eventTrigger("tooltipShown", that._eventData);
                return true
            },
            hide: function() {
                var that = this;
                hideElement(that._wrapper);
                that._eventData && that._eventTrigger("tooltipHidden", that._eventData);
                that._eventData = null
            },
            move: function(x, y, offset) {
                offset = offset || 0;
                var that = this,
                    canvas = that._getCanvas(),
                    state = that._state,
                    coords = state.tc,
                    contentSize = state.contentSize;
                if (that._calculatePosition(x, y, offset, canvas)) {
                    that._cloud.attr({
                        points: coords.cloudPoints
                    }).move(contentSize.lm, contentSize.tm);
                    if (state.html) {
                        that._textGroupHtml.css({
                            left: -contentSize.x + contentSize.lm,
                            top: -contentSize.y + contentSize.tm + coords.correction
                        })
                    } else {
                        that._textGroup.move(-contentSize.x + contentSize.lm, -contentSize.y + contentSize.tm + coords.correction)
                    }
                    that._renderer.resize("out" === coords.hp ? canvas.fullWidth - canvas.left : contentSize.fullWidth, "out" === coords.vp ? canvas.fullHeight - canvas.top : contentSize.fullHeight)
                }
                offset = that._wrapper.css({
                    left: 0,
                    top: 0
                }).offset();
                that._wrapper.css({
                    left: coords.x - offset.left,
                    top: coords.y - offset.top
                })
            },
            formatValue: function(value, _specialFormat) {
                var options = _specialFormat ? getSpecialFormatOptions(this._options, _specialFormat) : this._options;
                return _format(value, options)
            },
            getLocation: function() {
                return vizUtils.normalizeEnum(this._options.location)
            },
            isEnabled: function() {
                return !!this._options.enabled
            },
            isShared: function() {
                return !!this._options.shared
            },
            _calculatePosition: function(x, y, offset, canvas) {
                var cloudPoints, y1, y3, hasDeprecatedPosition, that = this,
                    options = that._options,
                    arrowLength = options.arrowLength,
                    state = that._state,
                    coords = state.tc,
                    contentSize = state.contentSize,
                    contentWidth = contentSize.width,
                    halfContentWidth = contentWidth / 2,
                    contentHeight = contentSize.height,
                    cTop = y - canvas.top,
                    cBottom = canvas.top + canvas.height - y,
                    cLeft = x - canvas.left,
                    cRight = canvas.width + canvas.left - x,
                    tTop = contentHeight + arrowLength + offset + contentSize.tm,
                    tBottom = contentHeight + arrowLength + offset + contentSize.bm,
                    tLeft = contentWidth + contentSize.lm,
                    tRight = contentWidth + contentSize.rm,
                    tHalfLeft = halfContentWidth + contentSize.lm,
                    tHalfRight = halfContentWidth + contentSize.rm,
                    correction = 0,
                    arrowPoints = [6, 0],
                    x1 = halfContentWidth + HALF_ARROW_WIDTH,
                    x2 = halfContentWidth,
                    x3 = halfContentWidth - HALF_ARROW_WIDTH,
                    y2 = contentHeight + arrowLength,
                    hp = "center",
                    vp = "bottom";
                y1 = y3 = contentHeight;
                switch (options.verticalAlignment) {
                    case "top":
                        vp = "bottom";
                        hasDeprecatedPosition = true;
                        break;
                    case "bottom":
                        vp = "top";
                        hasDeprecatedPosition = true
                }
                if (!hasDeprecatedPosition) {
                    if (tTop > cTop && tBottom > cBottom) {
                        vp = "out"
                    } else {
                        if (tTop > cTop) {
                            vp = "top"
                        }
                    }
                }
                hasDeprecatedPosition = false;
                switch (options.horizontalAlignment) {
                    case "left":
                        hp = "right";
                        hasDeprecatedPosition = true;
                        break;
                    case "center":
                        hp = "center";
                        hasDeprecatedPosition = true;
                        break;
                    case "right":
                        hp = "left";
                        hasDeprecatedPosition = true
                }
                if (!hasDeprecatedPosition) {
                    if (tLeft > cLeft && tRight > cRight) {
                        hp = "out"
                    } else {
                        if (tHalfLeft > cLeft && tRight < cRight) {
                            hp = "left"
                        } else {
                            if (tHalfRight > cRight && tLeft < cLeft) {
                                hp = "right"
                            }
                        }
                    }
                }
                if ("out" === hp) {
                    x = canvas.left
                } else {
                    if ("left" === hp) {
                        x1 = HALF_ARROW_WIDTH;
                        x2 = x3 = 0
                    } else {
                        if ("right" === hp) {
                            x1 = x2 = contentWidth;
                            x3 = contentWidth - HALF_ARROW_WIDTH;
                            x -= contentWidth
                        } else {
                            if ("center" === hp) {
                                x -= halfContentWidth
                            }
                        }
                    }
                }
                if ("out" === vp) {
                    y = canvas.top
                } else {
                    if ("top" === vp) {
                        "out" !== hp && (correction = arrowLength);
                        arrowPoints[0] = 2;
                        y1 = y3 = arrowLength;
                        y2 = x1;
                        x1 = x3;
                        x3 = y2;
                        y2 = 0;
                        y += offset
                    } else {
                        y -= contentHeight + arrowLength + offset
                    }
                }
                coords.x = x - contentSize.lm;
                coords.y = y - contentSize.tm;
                coords.correction = correction;
                if (hp === coords.hp && vp === coords.vp) {
                    return false
                }
                coords.hp = hp;
                coords.vp = vp;
                cloudPoints = [0, 0 + correction, contentWidth, 0 + correction, contentWidth, contentHeight + correction, 0, contentHeight + correction];
                if ("out" !== hp && "out" !== vp) {
                    arrowPoints.splice(2, 0, x1, y1, x2, y2, x3, y3);
                    cloudPoints.splice.apply(cloudPoints, arrowPoints)
                }
                coords.cloudPoints = cloudPoints;
                return true
            },
            _getCanvas: function() {
                var html = doc.documentElement,
                    body = doc.body;
                return {
                    left: win.pageXOffset || html.scrollLeft || 0,
                    top: win.pageYOffset || html.scrollTop || 0,
                    width: html.clientWidth || 0,
                    height: html.clientHeight || 0,
                    fullWidth: Math.max(body.scrollWidth, html.scrollWidth, body.offsetWidth, html.offsetWidth, body.clientWidth, html.clientWidth),
                    fullHeight: Math.max(body.scrollHeight, html.scrollHeight, body.offsetHeight, html.offsetHeight, body.clientHeight, html.clientHeight)
                }
            }
        };
        exports.Tooltip = Tooltip;
        exports.plugin = {
            name: "tooltip",
            init: function() {
                this._initTooltip()
            },
            dispose: function() {
                this._disposeTooltip()
            },
            members: {
                _initTooltip: function() {
                    this._tooltip = new exports.Tooltip({
                        cssClass: this._rootClassPrefix + "-tooltip",
                        eventTrigger: this._eventTrigger,
                        pathModified: this.option("pathModified")
                    })
                },
                _disposeTooltip: function() {
                    this._tooltip.dispose();
                    this._tooltip = null
                },
                _hideTooltip: function() {
                    this._tooltip.hide()
                },
                _onRender: function() {
                    if (!this._$element.is(":visible")) {
                        this._hideTooltip()
                    }
                },
                _setTooltipRendererOptions: function() {
                    this._tooltip.setRendererOptions(this._getRendererOptions())
                },
                _setTooltipOptions: function() {
                    this._tooltip.update(this._getOption("tooltip"))
                }
            },
            customize: function(constructor) {
                var proto = constructor.prototype;
                proto._eventsMap.onTooltipShown = {
                    name: "tooltipShown"
                };
                proto._eventsMap.onTooltipHidden = {
                    name: "tooltipHidden"
                };
                constructor.addChange({
                    code: "TOOLTIP_RENDERER",
                    handler: function() {
                        this._setTooltipRendererOptions()
                    },
                    isThemeDependent: true,
                    isOptionChange: true
                });
                constructor.addChange({
                    code: "TOOLTIP",
                    handler: function() {
                        this._setTooltipOptions()
                    },
                    isThemeDependent: true,
                    isOptionChange: true,
                    option: "tooltip"
                })
            }
        }
    },
    /*!***********************************************!*\
      !*** ./Scripts/viz/core/loading_indicator.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var _patchFontOptions = __webpack_require__( /*! ./utils */ 442).patchFontOptions,
            STATE_HIDDEN = 0,
            STATE_SHOWN = 1,
            ANIMATION_EASING = "linear",
            ANIMATION_DURATION = 400,
            LOADING_INDICATOR_READY = "loadingIndicatorReady";

        function LoadingIndicator(parameters) {
            var that = this,
                renderer = parameters.renderer;
            that._group = renderer.g().attr({
                "class": "dx-loading-indicator"
            }).linkOn(renderer.root, {
                name: "loading-indicator",
                after: "peripheral"
            });
            that._rect = renderer.rect().attr({
                opacity: 0
            }).append(that._group);
            that._text = renderer.text().attr({
                align: "center"
            }).append(that._group);
            that._createStates(parameters.eventTrigger, that._group, renderer.root, parameters.notify)
        }
        LoadingIndicator.prototype = {
            constructor: LoadingIndicator,
            _createStates: function(eventTrigger, group, root, notify) {
                var that = this;
                that._states = [{
                    opacity: 0,
                    start: function() {
                        notify(false)
                    },
                    complete: function() {
                        group.linkRemove();
                        root.attr({
                            "pointer-events": null
                        });
                        eventTrigger(LOADING_INDICATOR_READY)
                    }
                }, {
                    opacity: .85,
                    start: function() {
                        group.linkAppend();
                        root.attr({
                            "pointer-events": "none"
                        });
                        notify(true)
                    },
                    complete: function() {
                        eventTrigger(LOADING_INDICATOR_READY)
                    }
                }];
                that._state = STATE_HIDDEN
            },
            setSize: function(size) {
                var width = size.width,
                    height = size.height;
                this._rect.attr({
                    width: width,
                    height: height
                });
                this._text.attr({
                    x: width / 2,
                    y: height / 2
                })
            },
            setOptions: function(options) {
                this._rect.attr({
                    fill: options.backgroundColor
                });
                this._text.css(_patchFontOptions(options.font)).attr({
                    text: options.text
                });
                this[options.show ? "show" : "hide"]()
            },
            dispose: function() {
                var that = this;
                that._group.linkRemove().linkOff();
                that._group = that._rect = that._text = that._states = null
            },
            _transit: function(stateId) {
                var state, that = this;
                if (that._state !== stateId) {
                    that._state = stateId;
                    that._isHiding = false;
                    state = that._states[stateId];
                    that._rect.stopAnimation().animate({
                        opacity: state.opacity
                    }, {
                        complete: state.complete,
                        easing: ANIMATION_EASING,
                        duration: ANIMATION_DURATION,
                        unstoppable: true
                    });
                    that._noHiding = true;
                    state.start();
                    that._noHiding = false
                }
            },
            show: function() {
                this._transit(STATE_SHOWN)
            },
            hide: function() {
                this._transit(STATE_HIDDEN)
            },
            scheduleHiding: function() {
                if (!this._noHiding) {
                    this._isHiding = true
                }
            },
            fulfillHiding: function() {
                if (this._isHiding) {
                    this.hide()
                }
            }
        };
        exports.LoadingIndicator = LoadingIndicator;
        exports.plugin = {
            name: "loading_indicator",
            init: function() {
                var that = this;
                that._loadingIndicator = new exports.LoadingIndicator({
                    eventTrigger: that._eventTrigger,
                    renderer: that._renderer,
                    notify: notify
                });
                that._scheduleLoadingIndicatorHiding();

                function notify(state) {
                    that._skipLoadingIndicatorOptions = true;
                    that.option("loadingIndicator", {
                        show: state
                    });
                    that._skipLoadingIndicatorOptions = false;
                    if (state) {
                        that._hideTooltip && that._hideTooltip()
                    }
                }
            },
            dispose: function() {
                this._loadingIndicator.dispose();
                this._loadingIndicator = null
            },
            members: {
                _scheduleLoadingIndicatorHiding: function() {
                    this._loadingIndicator.scheduleHiding()
                },
                _fulfillLoadingIndicatorHiding: function() {
                    this._loadingIndicator.fulfillHiding()
                },
                showLoadingIndicator: function() {
                    this._loadingIndicator.show()
                },
                hideLoadingIndicator: function() {
                    this._loadingIndicator.hide()
                },
                _onBeginUpdate: function() {
                    this._scheduleLoadingIndicatorHiding()
                }
            },
            customize: function(constructor) {
                var proto = constructor.prototype;
                if (proto._dataSourceChangedHandler) {
                    var _dataSourceChangedHandler = proto._dataSourceChangedHandler;
                    proto._dataSourceChangedHandler = function() {
                        this._scheduleLoadingIndicatorHiding();
                        _dataSourceChangedHandler.apply(this, arguments)
                    }
                }
                var _setContentSize = proto._setContentSize;
                proto._setContentSize = function() {
                    _setContentSize.apply(this, arguments);
                    this._loadingIndicator.setSize(this._canvas)
                };
                constructor.addChange({
                    code: "LOADING_INDICATOR",
                    handler: function() {
                        if (!this._skipLoadingIndicatorOptions) {
                            this._loadingIndicator.setOptions(this._getOption("loadingIndicator"))
                        }
                        this._scheduleLoadingIndicatorHiding()
                    },
                    isThemeDependent: true,
                    option: "loadingIndicator",
                    isOptionChange: true
                });
                proto._eventsMap.onLoadingIndicatorReady = {
                    name: "loadingIndicatorReady"
                };
                var _drawn = proto._drawn;
                proto._drawn = function() {
                    _drawn.apply(this, arguments);
                    if (this._dataIsReady()) {
                        this._fulfillLoadingIndicatorHiding()
                    }
                }
            }
        }
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/translators/translator2d.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var _Translator2d, $ = __webpack_require__( /*! jquery */ 9),
            numericTranslator = __webpack_require__( /*! ./numeric_translator */ 498),
            categoryTranslator = __webpack_require__( /*! ./category_translator */ 499),
            intervalTranslator = __webpack_require__( /*! ./interval_translator */ 500),
            datetimeTranslator = __webpack_require__( /*! ./datetime_translator */ 501),
            logarithmicTranslator = __webpack_require__( /*! ./logarithmic_translator */ 502),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            getLog = vizUtils.getLog,
            getPower = vizUtils.getPower,
            isDefined = commonUtils.isDefined,
            _abs = Math.abs,
            CANVAS_PROP = ["width", "height", "left", "top", "bottom", "right"],
            NUMBER_EQUALITY_CORRECTION = 1,
            DATETIME_EQUALITY_CORRECTION = 6e4,
            _noop = $.noop,
            addInterval = __webpack_require__( /*! ../../core/utils/date */ 52).addInterval;
        var validateCanvas = function(canvas) {
            $.each(CANVAS_PROP, function(_, prop) {
                canvas[prop] = parseInt(canvas[prop]) || 0
            });
            return canvas
        };
        var makeCategoriesToPoints = function(categories) {
            var categoriesToPoints = {},
                length = categories.length,
                i = 0;
            for (; i < length; i++) {
                categoriesToPoints[categories[i]] = i
            }
            return categoriesToPoints
        };
        var validateBusinessRange = function(businessRange) {
            function validate(valueSelector, baseValueSelector) {
                if (!isDefined(businessRange[valueSelector]) && isDefined(businessRange[baseValueSelector])) {
                    businessRange[valueSelector] = businessRange[baseValueSelector]
                }
            }
            validate("minVisible", "min");
            validate("maxVisible", "max");
            return businessRange
        };

        function valuesIsDefinedAndEqual(val1, val2) {
            return isDefined(val1) && isDefined(val2) && val1.valueOf() === val2.valueOf()
        }

        function getCanvasBounds(range) {
            var newMin, newMax, min = range.min,
                max = range.max,
                minVisible = range.minVisible,
                maxVisible = range.maxVisible,
                base = range.base,
                isDateTime = commonUtils.isDate(max) || commonUtils.isDate(min),
                correction = isDateTime ? DATETIME_EQUALITY_CORRECTION : NUMBER_EQUALITY_CORRECTION,
                isLogarithmic = "logarithmic" === range.axisType;
            if (isLogarithmic) {
                maxVisible = getLog(maxVisible, base);
                minVisible = getLog(minVisible, base);
                min = getLog(min, base);
                max = getLog(max, base)
            }
            if (valuesIsDefinedAndEqual(min, max)) {
                newMin = min.valueOf() - correction;
                newMax = max.valueOf() + correction;
                if (isDateTime) {
                    min = new Date(newMin);
                    max = new Date(newMax)
                } else {
                    min = 0 !== min || isLogarithmic ? newMin : 0;
                    max = newMax
                }
            }
            if (valuesIsDefinedAndEqual(minVisible, maxVisible)) {
                newMin = minVisible.valueOf() - correction;
                newMax = maxVisible.valueOf() + correction;
                if (isDateTime) {
                    minVisible = newMin < min.valueOf() ? min : new Date(newMin);
                    maxVisible = newMax > max.valueOf() ? max : new Date(newMax)
                } else {
                    if (0 !== minVisible || isLogarithmic) {
                        minVisible = newMin < min ? min : newMin
                    }
                    maxVisible = newMax > max ? max : newMax
                }
            }
            return {
                base: base,
                rangeMin: min,
                rangeMax: max,
                rangeMinVisible: minVisible,
                rangeMaxVisible: maxVisible
            }
        }
        exports.Translator2D = _Translator2d = function(businessRange, canvas, options) {
            this.update(businessRange, canvas, options)
        };
        _Translator2d.prototype = {
            constructor: _Translator2d,
            reinit: function() {
                var that = this,
                    range = that._businessRange,
                    categories = range.categories || [],
                    script = {},
                    canvasOptions = that._prepareCanvasOptions(),
                    visibleCategories = vizUtils.getCategoriesInfo(categories, range.minVisible, range.maxVisible).categories,
                    categoriesLength = (visibleCategories || categories).length;
                switch (range.axisType) {
                    case "logarithmic":
                        script = logarithmicTranslator;
                        break;
                    case "semidiscrete":
                        script = intervalTranslator;
                        canvasOptions.ratioOfCanvasRange = canvasOptions.canvasLength / (addInterval(canvasOptions.rangeMaxVisible, that._options.interval) - canvasOptions.rangeMinVisible);
                        break;
                    case "discrete":
                        script = categoryTranslator;
                        that._categories = categories;
                        canvasOptions.interval = that._getDiscreteInterval(range.addSpiderCategory ? categoriesLength + 1 : categoriesLength, canvasOptions);
                        that._categoriesToPoints = makeCategoriesToPoints(categories, canvasOptions.invert);
                        if (visibleCategories && categoriesLength) {
                            canvasOptions.startPointIndex = that._categoriesToPoints[visibleCategories[0]];
                            that.visibleCategories = visibleCategories
                        }
                        break;
                    default:
                        if ("datetime" === range.dataType) {
                            script = datetimeTranslator
                        } else {
                            script = numericTranslator
                        }
                }
                $.extend(that, script);
                that._conversionValue = that._options.conversionValue ? function(value) {
                    return value
                } : function(value) {
                    return Math.round(value)
                };
                that._calculateSpecialValues()
            },
            _getDiscreteInterval: function(categoriesLength, canvasOptions) {
                var correctedCategoriesCount = categoriesLength - (this._businessRange.stick ? 1 : 0);
                return correctedCategoriesCount > 0 ? canvasOptions.canvasLength / correctedCategoriesCount : canvasOptions.canvasLength
            },
            _prepareCanvasOptions: function() {
                var length, that = this,
                    businessRange = that._businessRange,
                    canvasOptions = that._canvasOptions = getCanvasBounds(businessRange),
                    canvas = that._canvas;
                if (that._options.isHorizontal) {
                    canvasOptions.startPoint = canvas.left;
                    length = canvas.width;
                    canvasOptions.endPoint = canvas.width - canvas.right;
                    canvasOptions.invert = businessRange.invert
                } else {
                    canvasOptions.startPoint = canvas.top;
                    length = canvas.height;
                    canvasOptions.endPoint = canvas.height - canvas.bottom;
                    canvasOptions.invert = !businessRange.invert
                }
                that.canvasLength = canvasOptions.canvasLength = canvasOptions.endPoint - canvasOptions.startPoint;
                canvasOptions.rangeDoubleError = Math.pow(10, getPower(canvasOptions.rangeMax - canvasOptions.rangeMin) - getPower(length) - 2);
                canvasOptions.ratioOfCanvasRange = canvasOptions.canvasLength / (canvasOptions.rangeMaxVisible - canvasOptions.rangeMinVisible);
                return canvasOptions
            },
            updateCanvas: function(canvas) {
                this._canvas = validateCanvas(canvas);
                this.reinit()
            },
            updateBusinessRange: function(businessRange) {
                this._businessRange = validateBusinessRange(businessRange);
                this.reinit()
            },
            update: function(businessRange, canvas, options) {
                var that = this;
                that._options = $.extend(that._options || {}, options);
                that._canvas = validateCanvas(canvas);
                that.updateBusinessRange(businessRange)
            },
            getBusinessRange: function() {
                return this._businessRange
            },
            getCanvasVisibleArea: function() {
                return {
                    min: this._canvasOptions.startPoint,
                    max: this._canvasOptions.endPoint
                }
            },
            _calculateSpecialValues: function() {
                var invert, canvas_position_default, canvas_position_center_middle, that = this,
                    canvasOptions = that._canvasOptions,
                    startPoint = canvasOptions.startPoint,
                    endPoint = canvasOptions.endPoint,
                    range = that._businessRange,
                    minVisible = range.minVisible,
                    maxVisible = range.maxVisible;
                if (minVisible <= 0 && maxVisible >= 0) {
                    that.sc = {};
                    canvas_position_default = that.translate(0)
                } else {
                    invert = range.invert ^ (minVisible <= 0 && maxVisible <= 0);
                    if (that._options.isHorizontal) {
                        canvas_position_default = invert ? endPoint : startPoint
                    } else {
                        canvas_position_default = invert ? startPoint : endPoint
                    }
                }
                canvas_position_center_middle = startPoint + canvasOptions.canvasLength / 2;
                that.sc = {
                    canvas_position_default: canvas_position_default,
                    canvas_position_left: startPoint,
                    canvas_position_top: startPoint,
                    canvas_position_center: canvas_position_center_middle,
                    canvas_position_middle: canvas_position_center_middle,
                    canvas_position_right: endPoint,
                    canvas_position_bottom: endPoint,
                    canvas_position_start: canvasOptions.invert ? endPoint : startPoint,
                    canvas_position_end: canvasOptions.invert ? startPoint : endPoint
                }
            },
            translateSpecialCase: function(value) {
                return this.sc[value]
            },
            _calculateProjection: function(distance) {
                var canvasOptions = this._canvasOptions;
                return canvasOptions.invert ? canvasOptions.endPoint - distance : canvasOptions.startPoint + distance
            },
            _calculateUnProjection: function(distance) {
                var canvasOptions = this._canvasOptions;
                return canvasOptions.invert ? canvasOptions.rangeMaxVisible.valueOf() - distance : canvasOptions.rangeMinVisible.valueOf() + distance
            },
            getVisibleCategories: function() {
                return this.visibleCategories
            },
            getMinBarSize: function(minBarSize) {
                var visibleArea = this.getCanvasVisibleArea(),
                    minValue = this.untranslate(visibleArea.min + minBarSize);
                return _abs(this.untranslate(visibleArea.min) - (!isDefined(minValue) ? this.untranslate(visibleArea.max) : minValue))
            },
            translate: _noop,
            untranslate: _noop,
            getInterval: _noop,
            zoom: _noop,
            getMinScale: _noop,
            getRange: function() {
                return [this.untranslate(this._canvasOptions.startPoint, -1), this.untranslate(this._canvasOptions.endPoint, 1)]
            },
            isEmptyValueRange: function() {
                return this._businessRange.stubData
            },
            getScreenRange: function() {
                return [this._canvasOptions.startPoint, this._canvasOptions.endPoint]
            },
            add: function(value, diff, dir) {
                return this._add(value, diff, (this._businessRange.invert ? -1 : 1) * dir)
            }
        }
    },
    /*!*******************************************************!*\
      !*** ./Scripts/viz/translators/numeric_translator.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isDefined = commonUtils.isDefined,
            round = Math.round;
        module.exports = {
            translate: function(bp) {
                var that = this,
                    canvasOptions = that._canvasOptions,
                    doubleError = canvasOptions.rangeDoubleError,
                    specialValue = that.translateSpecialCase(bp);
                if (isDefined(specialValue)) {
                    return specialValue
                }
                if (isNaN(bp) || bp.valueOf() + doubleError < canvasOptions.rangeMin || bp.valueOf() - doubleError > canvasOptions.rangeMax) {
                    return null
                }
                return that._conversionValue(that._calculateProjection((bp - canvasOptions.rangeMinVisible) * canvasOptions.ratioOfCanvasRange))
            },
            untranslate: function(pos, _directionOffset, enableOutOfCanvas) {
                var canvasOptions = this._canvasOptions,
                    startPoint = canvasOptions.startPoint;
                if (!enableOutOfCanvas && (pos < startPoint || pos > canvasOptions.endPoint) || !isDefined(canvasOptions.rangeMin) || !isDefined(canvasOptions.rangeMax)) {
                    return null
                }
                return this._calculateUnProjection((pos - startPoint) / canvasOptions.ratioOfCanvasRange)
            },
            getInterval: function() {
                return round(this._canvasOptions.ratioOfCanvasRange * (this._businessRange.interval || Math.abs(this._canvasOptions.rangeMax - this._canvasOptions.rangeMin)))
            },
            _getValue: function(val) {
                return val
            },
            zoom: function(translate, scale) {
                var that = this,
                    canvasOptions = that._canvasOptions,
                    startPoint = canvasOptions.startPoint,
                    endPoint = canvasOptions.endPoint,
                    newStart = (startPoint + translate) / scale,
                    newEnd = (endPoint + translate) / scale,
                    translatedRangeMinMax = [that.translate(that._getValue(canvasOptions.rangeMin)), that.translate(that._getValue(canvasOptions.rangeMax))],
                    minPoint = Math.min(translatedRangeMinMax[0], translatedRangeMinMax[1]),
                    maxPoint = Math.max(translatedRangeMinMax[0], translatedRangeMinMax[1]);
                if (minPoint > newStart) {
                    newEnd -= newStart - minPoint;
                    newStart = minPoint
                }
                if (maxPoint < newEnd) {
                    newStart -= newEnd - maxPoint;
                    newEnd = maxPoint
                }
                if (maxPoint - minPoint < newEnd - newStart) {
                    newStart = minPoint;
                    newEnd = maxPoint
                }
                translate = (endPoint - startPoint) * newStart / (newEnd - newStart) - startPoint;
                scale = (startPoint + translate) / newStart || 1;
                return {
                    min: that.untranslate(newStart, void 0, true),
                    max: that.untranslate(newEnd, void 0, true),
                    translate: translate,
                    scale: scale
                }
            },
            getMinScale: function(zoom) {
                return zoom ? 1.1 : .9
            },
            getScale: function(val1, val2) {
                var canvasOptions = this._canvasOptions;
                val1 = isDefined(val1) ? val1 : canvasOptions.rangeMin;
                val2 = isDefined(val2) ? val2 : canvasOptions.rangeMax;
                return (canvasOptions.rangeMax - canvasOptions.rangeMin) / Math.abs(val1 - val2)
            },
            isValid: function(value) {
                var co = this._canvasOptions;
                return null !== value && !isNaN(value) && value.valueOf() + co.rangeDoubleError >= co.rangeMin && value.valueOf() - co.rangeDoubleError <= co.rangeMax
            },
            parse: function(value) {
                return Number(value)
            },
            to: function(value) {
                return this._conversionValue(this._calculateProjection((value - this._canvasOptions.rangeMinVisible) * this._canvasOptions.ratioOfCanvasRange))
            },
            from: function(position) {
                return this._calculateUnProjection((position - this._canvasOptions.startPoint) / this._canvasOptions.ratioOfCanvasRange)
            },
            _add: function(value, diff, coeff) {
                return value + diff * coeff
            },
            isValueProlonged: false
        }
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/translators/category_translator.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isDefined = commonUtils.isDefined,
            round = Math.round;
        module.exports = {
            translate: function(category, directionOffset) {
                var stickDelta, that = this,
                    canvasOptions = that._canvasOptions,
                    categoryIndex = that._categoriesToPoints[category],
                    specialValue = that.translateSpecialCase(category),
                    startPointIndex = canvasOptions.startPointIndex || 0,
                    stickInterval = that._businessRange.stick ? 0 : .5;
                if (isDefined(specialValue)) {
                    return specialValue
                }
                if (!categoryIndex && 0 !== categoryIndex) {
                    return null
                }
                directionOffset = directionOffset || 0;
                stickDelta = categoryIndex + stickInterval - startPointIndex + .5 * directionOffset;
                return round(that._calculateProjection(canvasOptions.interval * stickDelta))
            },
            untranslate: function(pos, directionOffset, enableOutOfCanvas) {
                var that = this,
                    canvasOptions = that._canvasOptions,
                    startPoint = canvasOptions.startPoint,
                    categories = that.visibleCategories || that._categories,
                    categoriesLength = categories.length,
                    result = 0,
                    stickInterval = that._businessRange.stick ? .5 : 0;
                if (!enableOutOfCanvas && (pos < startPoint || pos > canvasOptions.endPoint)) {
                    return null
                }
                directionOffset = directionOffset || 0;
                result = round((pos - startPoint) / canvasOptions.interval + stickInterval - .5 - .5 * directionOffset);
                if (categoriesLength === result) {
                    result--
                }
                if (result === -1) {
                    result = 0
                }
                if (canvasOptions.invert) {
                    result = categoriesLength - result - 1
                }
                return categories[result]
            },
            getInterval: function() {
                return this._canvasOptions.interval
            },
            zoom: function(translate, scale) {
                var endCategoryIndex, newVisibleCategories, newInterval, that = this,
                    canvasOptions = that._canvasOptions,
                    stick = that._businessRange.stick,
                    invert = canvasOptions.invert,
                    interval = canvasOptions.interval * scale,
                    translateCategories = translate / interval,
                    startCategoryIndex = parseInt((canvasOptions.startPointIndex || 0) + translateCategories + .5),
                    categoriesLength = parseInt(canvasOptions.canvasLength / interval + (stick ? 1 : 0)) || 1,
                    categories = that._categories;
                if (invert) {
                    startCategoryIndex = parseInt((canvasOptions.startPointIndex || 0) + (that.visibleCategories || []).length - translateCategories + .5) - categoriesLength
                }
                if (startCategoryIndex < 0) {
                    startCategoryIndex = 0
                }
                endCategoryIndex = startCategoryIndex + categoriesLength;
                if (endCategoryIndex > categories.length) {
                    endCategoryIndex = categories.length;
                    startCategoryIndex = endCategoryIndex - categoriesLength;
                    if (startCategoryIndex < 0) {
                        startCategoryIndex = 0
                    }
                }
                newVisibleCategories = categories.slice(parseInt(startCategoryIndex), parseInt(endCategoryIndex));
                newInterval = that._getDiscreteInterval(newVisibleCategories.length, canvasOptions);
                scale = newInterval / canvasOptions.interval;
                translate = that.translate(!invert ? newVisibleCategories[0] : newVisibleCategories[newVisibleCategories.length - 1]) * scale - (canvasOptions.startPoint + (stick ? 0 : newInterval / 2));
                return {
                    min: newVisibleCategories[0],
                    max: newVisibleCategories[newVisibleCategories.length - 1],
                    translate: translate,
                    scale: scale
                }
            },
            getMinScale: function(zoom) {
                var that = this,
                    canvasOptions = that._canvasOptions,
                    categoriesLength = (that.visibleCategories || that._categories).length;
                categoriesLength += (parseInt(.1 * categoriesLength) || 1) * (zoom ? -2 : 2);
                return canvasOptions.canvasLength / (Math.max(categoriesLength, 1) * canvasOptions.interval)
            },
            getScale: function(min, max) {
                var that = this,
                    canvasOptions = that._canvasOptions,
                    visibleArea = that.getCanvasVisibleArea(),
                    stickOffset = !that._businessRange.stick && 1,
                    minPoint = that.translate(min, -stickOffset),
                    maxPoint = that.translate(max, +stickOffset);
                if (!isDefined(minPoint)) {
                    minPoint = canvasOptions.invert ? visibleArea.max : visibleArea.min
                }
                if (!isDefined(maxPoint)) {
                    maxPoint = canvasOptions.invert ? visibleArea.min : visibleArea.max
                }
                return that.canvasLength / Math.abs(maxPoint - minPoint)
            },
            isValid: function(value) {
                return this._categoriesToPoints[value] >= 0
            },
            parse: function(value) {
                return value
            },
            to: function(value, direction) {
                var canvasOptions = this._canvasOptions,
                    businessRange = this._businessRange,
                    categoryIndex = this._categoriesToPoints[value],
                    startPointIndex = canvasOptions.startPointIndex || 0,
                    stickInterval = businessRange.stick ? 0 : .5,
                    stickDelta = categoryIndex + stickInterval - startPointIndex + (businessRange.invert ? -1 : 1) * direction * .5;
                return round(this._calculateProjection(canvasOptions.interval * stickDelta))
            },
            from: function(position, direction) {
                var canvasOptions = this._canvasOptions,
                    businessRange = this._businessRange,
                    startPoint = canvasOptions.startPoint,
                    categories = this._categories,
                    categoriesLength = categories.length,
                    stickInterval = businessRange.stick ? .5 : 0,
                    result = round((position - startPoint) / canvasOptions.interval + stickInterval - .5 - .5 * direction);
                if (categoriesLength === result) {
                    result--
                }
                if (result === -1) {
                    result = 0
                }
                if (canvasOptions.invert) {
                    result = categoriesLength - result - 1
                }
                return categories[result]
            },
            _add: function(value, diff, coeff) {
                return NaN
            },
            isValueProlonged: true
        }
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/translators/interval_translator.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var adjustValue = __webpack_require__( /*! ../core/utils */ 442).adjustValue,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            isNumber = commonUtils.isNumber,
            isDefined = commonUtils.isDefined,
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            addInterval = dateUtils.addInterval,
            dateToMilliseconds = dateUtils.dateToMilliseconds,
            floor = Math.floor;
        module.exports = {
            _intervalize: function(value, interval) {
                if (!isDefined(value)) {
                    return
                }
                if ("datetime" === this._businessRange.dataType) {
                    if (isNumber(value)) {
                        value = new Date(value)
                    } else {
                        value = new Date(value.getTime())
                    }
                    value = dateUtils.correctDateWithUnitBeginning(value, interval)
                } else {
                    value = adjustValue(floor(value / interval) * interval)
                }
                return value
            },
            translate: function(bp, direction, interval) {
                var that = this,
                    specialValue = that.translateSpecialCase(bp);
                if (isDefined(specialValue)) {
                    return specialValue
                }
                interval = interval || that._options.interval;
                if (!that.isValid(bp, interval)) {
                    return null
                }
                return that.to(bp, direction, interval)
            },
            untranslate: function(pos, direction, enableOutOfCanvas) {
                var canvasOptions = this._canvasOptions,
                    startPoint = canvasOptions.startPoint;
                if (!enableOutOfCanvas && (pos < startPoint || pos > canvasOptions.endPoint) || !isDefined(canvasOptions.rangeMin) || !isDefined(canvasOptions.rangeMax)) {
                    return null
                }
                return this.from(pos, direction)
            },
            getInterval: function() {
                return Math.round(this._canvasOptions.ratioOfCanvasRange * (this._businessRange.interval || Math.abs(this._canvasOptions.rangeMax - this._canvasOptions.rangeMin)))
            },
            _getValue: function() {},
            zoom: function() {},
            getMinScale: function() {},
            getScale: function() {},
            isValid: function(value, interval) {
                var that = this,
                    co = that._canvasOptions,
                    rangeMin = co.rangeMin,
                    rangeMax = co.rangeMax;
                interval = interval || that._options.interval;
                if (null === value || isNaN(value)) {
                    return false
                }
                value = "datetime" === that._businessRange.dataType && isNumber(value) ? new Date(value) : value;
                if (interval !== that._options.interval) {
                    rangeMin = that._intervalize(rangeMin, interval);
                    rangeMax = that._intervalize(rangeMax, interval)
                }
                if (value.valueOf() < rangeMin || value.valueOf() >= addInterval(rangeMax, interval)) {
                    return false
                }
                return true
            },
            parse: function(value) {
                return "datetime" === this._businessRange.dataType ? isNumber(value) ? new Date(value) : value : Number(value)
            },
            to: function(bp, direction, interval) {
                var that = this;
                interval = interval || that._options.interval;
                var v1 = that._intervalize(bp, interval),
                    v2 = addInterval(v1, interval),
                    res = that._to(v1),
                    p2 = that._to(v2);
                if (!direction) {
                    res = floor((res + p2) / 2)
                } else {
                    if (direction > 0) {
                        res = p2
                    }
                }
                return res
            },
            _to: function(value) {
                var co = this._canvasOptions,
                    rMin = co.rangeMinVisible,
                    rMax = co.rangeMaxVisible,
                    offset = value - rMin;
                if (value < rMin) {
                    offset = 0
                } else {
                    if (value > rMax) {
                        offset = addInterval(rMax, this._options.interval) - rMin
                    }
                }
                return this._conversionValue(this._calculateProjection(offset * this._canvasOptions.ratioOfCanvasRange))
            },
            from: function(position, direction) {
                var value, that = this,
                    origInterval = that._options.interval,
                    interval = origInterval,
                    co = that._canvasOptions,
                    rMin = co.rangeMinVisible,
                    rMax = co.rangeMaxVisible;
                if ("datetime" === that._businessRange.dataType) {
                    interval = dateToMilliseconds(origInterval)
                }
                value = that._calculateUnProjection((position - that._canvasOptions.startPoint) / that._canvasOptions.ratioOfCanvasRange);
                value = that._intervalize(addInterval(value, interval / 2, direction > 0), origInterval);
                if (value < rMin) {
                    value = rMin
                } else {
                    if (value > rMax) {
                        value = rMax
                    }
                }
                return value
            },
            _add: function(value, diff, coeff) {
                return NaN
            },
            isValueProlonged: true
        }
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/translators/datetime_translator.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var numericTranslator = __webpack_require__( /*! ./numeric_translator */ 498);
        module.exports = {
            translate: numericTranslator.translate,
            untranslate: function() {
                var result = numericTranslator.untranslate.apply(this, arguments);
                return null === result ? result : new Date(result)
            },
            _getValue: numericTranslator._getValue,
            getInterval: numericTranslator.getInterval,
            zoom: numericTranslator.zoom,
            getMinScale: numericTranslator.getMinScale,
            getScale: numericTranslator.getScale,
            isValid: function(value) {
                return numericTranslator.isValid.call(this, new Date(value))
            },
            parse: function(value) {
                return new Date(value)
            },
            to: numericTranslator.to,
            from: function(position) {
                return new Date(numericTranslator.from.call(this, position))
            },
            _add: __webpack_require__( /*! ../../core/utils/date */ 52).addDateInterval,
            isValueProlonged: numericTranslator.isValueProlonged
        }
    },
    /*!***********************************************************!*\
      !*** ./Scripts/viz/translators/logarithmic_translator.js ***!
      \***********************************************************/
    function(module, exports, __webpack_require__) {
        var numericTranslator = __webpack_require__( /*! ./numeric_translator */ 498),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            raiseTo = vizUtils.raiseTo,
            getLog = vizUtils.getLog;
        module.exports = {
            translate: function(bp) {
                var that = this,
                    specialValue = that.translateSpecialCase(bp);
                if (commonUtils.isDefined(specialValue)) {
                    return specialValue
                }
                return numericTranslator.translate.call(that, getLog(bp, that._businessRange.base))
            },
            untranslate: function() {
                var result = numericTranslator.untranslate.apply(this, arguments);
                return null === result ? result : raiseTo(result, this._businessRange.base)
            },
            getInterval: numericTranslator.getInterval,
            _getValue: function(value) {
                return Math.pow(this._canvasOptions.base, value)
            },
            zoom: numericTranslator.zoom,
            getMinScale: numericTranslator.getMinScale,
            getScale: function(val1, val2) {
                var base = this._businessRange.base;
                val1 = commonUtils.isDefined(val1) ? getLog(val1, base) : void 0;
                val2 = commonUtils.isDefined(val2) ? getLog(val2, base) : void 0;
                return numericTranslator.getScale.call(this, val1, val2)
            },
            isValid: function(value) {
                return numericTranslator.isValid.call(this, getLog(value, this._businessRange.base))
            },
            parse: numericTranslator.parse,
            to: function(value) {
                return numericTranslator.to.call(this, getLog(value, this._businessRange.base))
            },
            from: function(position) {
                return raiseTo(numericTranslator.from.call(this, position), this._businessRange.base)
            },
            _add: function(value, diff, dir) {
                var b = this._businessRange.base;
                return raiseTo(numericTranslator._add(getLog(value, b), diff, dir), b)
            },
            isValueProlonged: numericTranslator.isValueProlonged
        }
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/translators/range.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var _Range, $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _isDate = commonUtils.isDate,
            unique = __webpack_require__( /*! ../core/utils */ 442).unique,
            minSelector = "min",
            maxSelector = "max",
            minVisibleSelector = "minVisible",
            maxVisibleSelector = "maxVisible",
            baseSelector = "base",
            axisTypeSelector = "axisType";

        function otherLessThan(thisValue, otherValue) {
            return otherValue < thisValue
        }

        function otherGreaterThan(thisValue, otherValue) {
            return otherValue > thisValue
        }

        function compareAndReplace(thisValue, otherValue, setValue, compare) {
            var otherValueDefined = _isDefined(otherValue);
            if (_isDefined(thisValue)) {
                if (otherValueDefined && compare(thisValue, otherValue)) {
                    setValue(otherValue)
                }
            } else {
                if (otherValueDefined) {
                    setValue(otherValue)
                }
            }
        }
        _Range = exports.Range = function(range) {
            range && $.extend(this, range)
        };
        _Range.prototype = {
            constructor: _Range,
            addRange: function(otherRange) {
                var that = this,
                    categories = that.categories,
                    otherCategories = otherRange.categories;
                var compareAndReplaceByField = function(field, compare) {
                    compareAndReplace(that[field], otherRange[field], function(value) {
                        that[field] = value
                    }, compare)
                };
                var controlValuesByVisibleBounds = function(valueField, visibleValueField, compare) {
                    compareAndReplace(that[valueField], that[visibleValueField], function(value) {
                        _isDefined(that[valueField]) && (that[valueField] = value)
                    }, compare)
                };
                var checkField = function(field) {
                    that[field] = that[field] || otherRange[field]
                };
                if (commonUtils.isDefined(otherRange.stick)) {
                    that.stick = otherRange.stick
                }
                checkField("addSpiderCategory");
                checkField("percentStick");
                checkField("minSpaceCorrection");
                checkField("maxSpaceCorrection");
                checkField("invert");
                checkField(axisTypeSelector);
                checkField("dataType");
                if ("logarithmic" === that[axisTypeSelector]) {
                    checkField(baseSelector)
                } else {
                    that[baseSelector] = void 0
                }
                compareAndReplaceByField(minSelector, otherLessThan);
                compareAndReplaceByField(maxSelector, otherGreaterThan);
                if ("discrete" === that[axisTypeSelector]) {
                    checkField(minVisibleSelector);
                    checkField(maxVisibleSelector)
                } else {
                    compareAndReplaceByField(minVisibleSelector, otherLessThan);
                    compareAndReplaceByField(maxVisibleSelector, otherGreaterThan)
                }
                compareAndReplaceByField("interval", otherLessThan);
                controlValuesByVisibleBounds(minSelector, minVisibleSelector, otherLessThan);
                controlValuesByVisibleBounds(minSelector, maxVisibleSelector, otherLessThan);
                controlValuesByVisibleBounds(maxSelector, maxVisibleSelector, otherGreaterThan);
                controlValuesByVisibleBounds(maxSelector, minVisibleSelector, otherGreaterThan);
                if (void 0 === categories) {
                    that.categories = otherCategories
                } else {
                    that.categories = otherCategories ? unique(categories.concat(otherCategories)) : categories
                }
                return that
            },
            isDefined: function() {
                return _isDefined(this[minSelector]) && _isDefined(this[maxSelector]) || this.categories && this.categories.length
            },
            setStubData: function(dataType) {
                var that = this,
                    year = (new Date).getYear() - 1,
                    isDate = "datetime" === dataType,
                    isCategories = "discrete" === that[axisTypeSelector];
                if (isCategories) {
                    that.categories = ["0", "1", "2"]
                } else {
                    that[minSelector] = isDate ? new Date(year, 0, 1) : 0;
                    that[maxSelector] = isDate ? new Date(year, 11, 31) : 10
                }
                that.stubData = true;
                return that
            },
            correctValueZeroLevel: function() {
                var that = this;
                if ("logarithmic" === that[axisTypeSelector] || _isDate(that[maxSelector]) || _isDate(that[minSelector])) {
                    return that
                }

                function setZeroLevel(min, max) {
                    that[min] < 0 && that[max] < 0 && (that[max] = 0);
                    that[min] > 0 && that[max] > 0 && (that[min] = 0)
                }
                setZeroLevel(minSelector, maxSelector);
                setZeroLevel(minVisibleSelector, maxVisibleSelector);
                return that
            },
            checkZeroStick: function() {
                var that = this;
                if (that.min >= 0 && that.max >= 0) {
                    that.minStickValue = 0
                } else {
                    if (that.min <= 0 && that.max <= 0) {
                        that.maxStickValue = 0
                    }
                }
                return that
            }
        }
    },
    /*!*****************************************************************!*\
      !*** ./Scripts/viz/chart_components/multi_axes_synchronizer.js ***!
      \*****************************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug,
            Range = __webpack_require__( /*! ../translators/range */ 503).Range,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _adjustValue = vizUtils.adjustValue,
            _applyPrecisionByMinDelta = vizUtils.applyPrecisionByMinDelta,
            _isDefined = commonUtils.isDefined,
            _math = Math,
            _floor = _math.floor,
            _max = _math.max,
            _abs = _math.abs,
            _each = $.each,
            _map = __webpack_require__( /*! ../core/utils */ 442).map,
            MIN_RANGE_FOR_ADJUST_BOUNDS = .1;
        var getValueAxesPerPanes = function(valueAxes) {
            var result = {};
            _each(valueAxes, function(_, axis) {
                var pane = axis.pane;
                if (!result[pane]) {
                    result[pane] = []
                }
                result[pane].push(axis)
            });
            return result
        };
        var restoreOriginalBusinessRange = function(axis) {
            var businessRange, translator = axis.getTranslator();
            if (!translator._originalBusinessRange) {
                translator._originalBusinessRange = new Range(translator.getBusinessRange())
            } else {
                businessRange = new Range(translator._originalBusinessRange);
                translator.updateBusinessRange(businessRange)
            }
        };
        var linearConverter = {
            transform: function(v, b) {
                return vizUtils.getLog(v, b)
            },
            addInterval: function(v, i) {
                return v + i
            },
            getInterval: function(base, tickInterval) {
                return tickInterval
            },
            adjustValue: _floor
        };
        var logConverter = {
            transform: function(v, b) {
                return vizUtils.raiseTo(v, b)
            },
            addInterval: function(v, i) {
                return v * i
            },
            getInterval: function(base, tickInterval) {
                return _math.pow(base, tickInterval)
            },
            adjustValue: _adjustValue
        };
        var convertAxisInfo = function(axisInfo, converter) {
            if (!axisInfo.isLogarithmic) {
                return
            }
            var tick, interval, i, base = axisInfo.logarithmicBase,
                tickValues = axisInfo.tickValues,
                ticks = [];
            axisInfo.minValue = converter.transform(axisInfo.minValue, base);
            axisInfo.oldMinValue = converter.transform(axisInfo.oldMinValue, base);
            axisInfo.maxValue = converter.transform(axisInfo.maxValue, base);
            axisInfo.oldMaxValue = converter.transform(axisInfo.oldMaxValue, base);
            axisInfo.tickInterval = _math.round(axisInfo.tickInterval);
            if (axisInfo.tickInterval < 1) {
                axisInfo.tickInterval = 1
            }
            interval = converter.getInterval(base, axisInfo.tickInterval);
            tick = converter.transform(tickValues[0], base);
            for (i = 0; i < tickValues.length; i++) {
                ticks.push(converter.adjustValue(tick));
                tick = converter.addInterval(tick, interval)
            }
            ticks.tickInterval = axisInfo.tickInterval;
            axisInfo.tickValues = ticks
        };
        var populateAxesInfo = function(axes) {
            return _map(axes, function(axis) {
                restoreOriginalBusinessRange(axis);
                var minValue, maxValue, businessRange, tickInterval, synchronizedValue, ticksValues = axis.getTicksValues(),
                    majorTicks = ticksValues.majorTicksValues,
                    options = axis.getOptions(),
                    axisInfo = null;
                if (majorTicks && majorTicks.length > 0 && commonUtils.isNumber(majorTicks[0]) && "discrete" !== options.type) {
                    businessRange = axis.getTranslator().getBusinessRange();
                    tickInterval = axis._tickManager.getTickInterval();
                    minValue = businessRange.minVisible;
                    maxValue = businessRange.maxVisible;
                    synchronizedValue = options.synchronizedValue;
                    if (minValue === maxValue && _isDefined(synchronizedValue)) {
                        tickInterval = _abs(majorTicks[0] - synchronizedValue) || 1;
                        minValue = majorTicks[0] - tickInterval;
                        maxValue = majorTicks[0] + tickInterval
                    }
                    axisInfo = {
                        axis: axis,
                        isLogarithmic: "logarithmic" === options.type,
                        logarithmicBase: businessRange.base,
                        tickValues: majorTicks,
                        minorValues: ticksValues.minorTicksValues,
                        minValue: minValue,
                        oldMinValue: minValue,
                        maxValue: maxValue,
                        oldMaxValue: maxValue,
                        inverted: businessRange.invert,
                        tickInterval: tickInterval,
                        synchronizedValue: synchronizedValue
                    };
                    if (businessRange.stubData) {
                        axisInfo.stubData = true;
                        axisInfo.tickInterval = axisInfo.tickInterval || options.tickInterval;
                        axisInfo.isLogarithmic = false
                    }
                    convertAxisInfo(axisInfo, linearConverter);
                    debug.assert(void 0 !== axisInfo.tickInterval && null !== axisInfo.tickInterval, "tickInterval was not provided")
                }
                return axisInfo
            })
        };
        var updateTickValues = function(axesInfo) {
            var maxTicksCount = 0;
            _each(axesInfo, function(_, axisInfo) {
                maxTicksCount = _max(maxTicksCount, axisInfo.tickValues.length)
            });
            _each(axesInfo, function(_, axisInfo) {
                var ticksMultiplier, ticksCount, additionalStartTicksCount = 0,
                    synchronizedValue = axisInfo.synchronizedValue,
                    tickValues = axisInfo.tickValues,
                    tickInterval = axisInfo.tickInterval;
                if (_isDefined(synchronizedValue)) {
                    axisInfo.baseTickValue = axisInfo.invertedBaseTickValue = synchronizedValue;
                    axisInfo.tickValues = [axisInfo.baseTickValue]
                } else {
                    if (tickValues.length > 1 && tickInterval) {
                        ticksMultiplier = _floor((maxTicksCount + 1) / tickValues.length);
                        ticksCount = ticksMultiplier > 1 ? _floor((maxTicksCount + 1) / ticksMultiplier) : maxTicksCount;
                        additionalStartTicksCount = _floor((ticksCount - tickValues.length) / 2);
                        while (additionalStartTicksCount > 0 && 0 !== tickValues[0]) {
                            tickValues.unshift(_applyPrecisionByMinDelta(tickValues[0], tickInterval, tickValues[0] - tickInterval));
                            additionalStartTicksCount--
                        }
                        while (tickValues.length < ticksCount) {
                            tickValues.push(_applyPrecisionByMinDelta(tickValues[0], tickInterval, tickValues[tickValues.length - 1] + tickInterval))
                        }
                        axisInfo.tickInterval = tickInterval / ticksMultiplier
                    }
                    axisInfo.baseTickValue = tickValues[0];
                    axisInfo.invertedBaseTickValue = tickValues[tickValues.length - 1]
                }
            })
        };
        var getAxisRange = function(axisInfo) {
            return axisInfo.maxValue - axisInfo.minValue || 1
        };
        var getMainAxisInfo = function(axesInfo) {
            for (var i = 0; i < axesInfo.length; i++) {
                if (!axesInfo[i].stubData) {
                    return axesInfo[i]
                }
            }
            return null
        };
        var correctMinMaxValues = function(axesInfo) {
            var mainAxisInfo = getMainAxisInfo(axesInfo),
                mainAxisInfoTickInterval = mainAxisInfo.tickInterval;
            _each(axesInfo, function(_, axisInfo) {
                var scale, move, mainAxisBaseValueOffset, valueFromAxisInfo;
                if (axisInfo !== mainAxisInfo) {
                    if (mainAxisInfoTickInterval && axisInfo.tickInterval) {
                        if (axisInfo.stubData && _isDefined(axisInfo.synchronizedValue)) {
                            axisInfo.oldMinValue = axisInfo.minValue = axisInfo.baseTickValue - (mainAxisInfo.baseTickValue - mainAxisInfo.minValue) / mainAxisInfoTickInterval * axisInfo.tickInterval;
                            axisInfo.oldMaxValue = axisInfo.maxValue = axisInfo.baseTickValue - (mainAxisInfo.baseTickValue - mainAxisInfo.maxValue) / mainAxisInfoTickInterval * axisInfo.tickInterval
                        }
                        scale = mainAxisInfoTickInterval / getAxisRange(mainAxisInfo) / axisInfo.tickInterval * getAxisRange(axisInfo);
                        axisInfo.maxValue = axisInfo.minValue + getAxisRange(axisInfo) / scale
                    }
                    if (mainAxisInfo.inverted && !axisInfo.inverted || !mainAxisInfo.inverted && axisInfo.inverted) {
                        mainAxisBaseValueOffset = mainAxisInfo.maxValue - mainAxisInfo.invertedBaseTickValue
                    } else {
                        mainAxisBaseValueOffset = mainAxisInfo.baseTickValue - mainAxisInfo.minValue
                    }
                    valueFromAxisInfo = getAxisRange(axisInfo);
                    move = (mainAxisBaseValueOffset / getAxisRange(mainAxisInfo) - (axisInfo.baseTickValue - axisInfo.minValue) / valueFromAxisInfo) * valueFromAxisInfo;
                    axisInfo.minValue -= move;
                    axisInfo.maxValue -= move
                }
            })
        };
        var calculatePaddings = function(axesInfo) {
            var minPadding, maxPadding, startPadding = 0,
                endPadding = 0;
            _each(axesInfo, function(_, axisInfo) {
                var inverted = axisInfo.inverted;
                minPadding = axisInfo.minValue > axisInfo.oldMinValue ? (axisInfo.minValue - axisInfo.oldMinValue) / getAxisRange(axisInfo) : 0;
                maxPadding = axisInfo.maxValue < axisInfo.oldMaxValue ? (axisInfo.oldMaxValue - axisInfo.maxValue) / getAxisRange(axisInfo) : 0;
                startPadding = _max(startPadding, inverted ? maxPadding : minPadding);
                endPadding = _max(endPadding, inverted ? minPadding : maxPadding)
            });
            return {
                start: startPadding,
                end: endPadding
            }
        };
        var correctMinMaxValuesByPaddings = function(axesInfo, paddings) {
            _each(axesInfo, function(_, info) {
                var range = getAxisRange(info),
                    inverted = info.inverted;
                info.minValue -= paddings[inverted ? "end" : "start"] * range;
                info.maxValue += paddings[inverted ? "start" : "end"] * range;
                if (range > MIN_RANGE_FOR_ADJUST_BOUNDS) {
                    info.minValue = _math.min(info.minValue, _adjustValue(info.minValue));
                    info.maxValue = _max(info.maxValue, _adjustValue(info.maxValue))
                }
            })
        };
        var updateTickValuesIfSynchronizedValueUsed = function(axesInfo) {
            var hasSynchronizedValue = false;
            _each(axesInfo, function(_, info) {
                hasSynchronizedValue = hasSynchronizedValue || _isDefined(info.synchronizedValue)
            });
            _each(axesInfo, function(_, info) {
                var lastTickValue, tickInterval = info.tickInterval,
                    tickValues = info.tickValues,
                    maxValue = info.maxValue,
                    minValue = info.minValue;
                if (hasSynchronizedValue && tickInterval) {
                    while (tickValues[0] - tickInterval >= minValue) {
                        tickValues.unshift(_adjustValue(tickValues[0] - tickInterval))
                    }
                    lastTickValue = tickValues[tickValues.length - 1];
                    while ((lastTickValue += tickInterval) <= maxValue) {
                        tickValues.push(commonUtils.isExponential(lastTickValue) ? _adjustValue(lastTickValue) : _applyPrecisionByMinDelta(minValue, tickInterval, lastTickValue))
                    }
                }
                while (tickValues[0] < minValue) {
                    tickValues.shift()
                }
                while (tickValues[tickValues.length - 1] > maxValue) {
                    tickValues.pop()
                }
            })
        };
        var applyMinMaxValues = function(axesInfo) {
            _each(axesInfo, function(_, info) {
                var axis = info.axis,
                    range = axis.getTranslator().getBusinessRange();
                if (range.min === range.minVisible) {
                    range.min = info.minValue
                }
                if (range.max === range.maxVisible) {
                    range.max = info.maxValue
                }
                range.minVisible = info.minValue;
                range.maxVisible = info.maxValue;
                if (_isDefined(info.stubData)) {
                    range.stubData = info.stubData
                }
                if (range.min > range.minVisible) {
                    range.min = range.minVisible
                }
                if (range.max < range.maxVisible) {
                    range.max = range.maxVisible
                }
                range.isSynchronized = true;
                axis.getTranslator().updateBusinessRange(range);
                axis.setTicks({
                    majorTicks: info.tickValues,
                    minorTicks: info.minorValues
                })
            })
        };
        var correctAfterSynchronize = function(axesInfo) {
            var correctValue, validAxisInfo, invalidAxisInfo = [];
            _each(axesInfo, function(i, info) {
                if (info.oldMaxValue - info.oldMinValue === 0) {
                    invalidAxisInfo.push(info)
                } else {
                    if (!_isDefined(correctValue) && !_isDefined(info.synchronizedValue)) {
                        correctValue = _abs((info.maxValue - info.minValue) / (info.tickValues[_floor(info.tickValues.length / 2)] || info.maxValue));
                        validAxisInfo = info
                    }
                }
            });
            if (!_isDefined(correctValue)) {
                return
            }
            _each(invalidAxisInfo, function(i, info) {
                var firstTick = info.tickValues[0],
                    correctedTick = firstTick * correctValue,
                    tickValues = validAxisInfo.tickValues,
                    centralTick = tickValues[_floor(tickValues.length / 2)];
                if (firstTick > 0) {
                    info.maxValue = correctedTick;
                    info.minValue = 0
                } else {
                    if (firstTick < 0) {
                        info.minValue = correctedTick;
                        info.maxValue = 0
                    } else {
                        if (0 === firstTick) {
                            info.maxValue = validAxisInfo.maxValue - centralTick;
                            info.minValue = validAxisInfo.minValue - centralTick
                        }
                    }
                }
            })
        };
        var multiAxesSynchronizer = {
            synchronize: function(valueAxes) {
                _each(getValueAxesPerPanes(valueAxes), function(_, axes) {
                    var axesInfo, paddings;
                    if (axes.length > 1) {
                        axesInfo = populateAxesInfo(axes);
                        if (0 === axesInfo.length || !getMainAxisInfo(axesInfo)) {
                            return
                        }
                        updateTickValues(axesInfo);
                        correctMinMaxValues(axesInfo);
                        paddings = calculatePaddings(axesInfo);
                        correctMinMaxValuesByPaddings(axesInfo, paddings);
                        correctAfterSynchronize(axesInfo);
                        updateTickValuesIfSynchronizedValueUsed(axesInfo);
                        _each(axesInfo, function() {
                            convertAxisInfo(this, logConverter)
                        });
                        applyMinMaxValues(axesInfo)
                    }
                })
            }
        };
        module.exports = multiAxesSynchronizer
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/chart_components/advanced_chart.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            rangeModule = __webpack_require__( /*! ../translators/range */ 503),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            DEFAULT_AXIS_NAME = "defaultAxisName",
            axisModule = __webpack_require__( /*! ../axes/base_axis */ 506),
            seriesFamilyModule = __webpack_require__( /*! ../core/series_family */ 515),
            BaseChart = __webpack_require__( /*! ./base_chart */ 447).BaseChart,
            _isArray = commonUtils.isArray,
            _isDefined = commonUtils.isDefined,
            _each = $.each,
            _noop = $.noop,
            _extend = $.extend,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _map = vizUtils.map,
            MIN = "min",
            MAX = "max";

        function prepareAxis(axisOptions) {
            return _isArray(axisOptions) ? 0 === axisOptions.length ? [{}] : axisOptions : [axisOptions]
        }
        var AdvancedChart = BaseChart.inherit({
            _dispose: function() {
                var that = this,
                    disposeObjectsInArray = this._disposeObjectsInArray;
                that.callBase();
                that.panes = null;
                if (that._legend) {
                    that._legend.dispose();
                    that._legend = null
                }
                disposeObjectsInArray.call(that, "panesBackground");
                disposeObjectsInArray.call(that, "seriesFamilies");
                that._disposeAxes()
            },
            _reinitAxes: function() {
                this.translators = {};
                this.panes = this._createPanes();
                this._populateAxes()
            },
            _populateAxes: function() {
                var argumentAxes, paneWithNonVirtualAxis, that = this,
                    valueAxes = [],
                    panes = that.panes,
                    rotated = that._isRotated(),
                    valueAxisOptions = that.option("valueAxis") || {},
                    argumentOption = that.option("argumentAxis") || {},
                    argumentAxesOptions = prepareAxis(argumentOption)[0],
                    valueAxesOptions = prepareAxis(valueAxisOptions),
                    axisNames = [],
                    valueAxesCounter = 0,
                    crosshairOptions = that._getCrosshairOptions() || {},
                    crosshairEnabled = crosshairOptions.enabled,
                    horCrosshairEnabled = crosshairEnabled && crosshairOptions.horizontalLine.visible,
                    verCrosshairEnabled = crosshairEnabled && crosshairOptions.verticalLine.visible;

                function getNextAxisName() {
                    return DEFAULT_AXIS_NAME + valueAxesCounter++
                }
                that._disposeAxes();
                if (rotated) {
                    paneWithNonVirtualAxis = "right" === argumentAxesOptions.position ? panes[panes.length - 1].name : panes[0].name
                } else {
                    paneWithNonVirtualAxis = "top" === argumentAxesOptions.position ? panes[0].name : panes[panes.length - 1].name
                }
                argumentAxes = _map(panes, function(pane, index) {
                    return that._createAxis("argumentAxis", argumentAxesOptions, {
                        pane: pane.name,
                        crosshairEnabled: rotated ? horCrosshairEnabled : verCrosshairEnabled
                    }, rotated, pane.name !== paneWithNonVirtualAxis, index)
                });
                _each(valueAxesOptions, function(priority, axisOptions) {
                    var axisPanes = [],
                        name = axisOptions.name;
                    if (name && $.inArray(name, axisNames) !== -1) {
                        that._incidentOccurred("E2102");
                        return
                    }
                    name && axisNames.push(name);
                    if (axisOptions.pane) {
                        axisPanes.push(axisOptions.pane)
                    }
                    if (axisOptions.panes && axisOptions.panes.length) {
                        axisPanes = axisPanes.concat(axisOptions.panes.slice(0))
                    }
                    axisPanes = vizUtils.unique(axisPanes);
                    if (!axisPanes.length) {
                        axisPanes.push(void 0)
                    }
                    _each(axisPanes, function(_, pane) {
                        valueAxes.push(that._createAxis("valueAxis", axisOptions, {
                            name: name || getNextAxisName(),
                            pane: pane,
                            priority: priority,
                            crosshairEnabled: rotated ? verCrosshairEnabled : horCrosshairEnabled
                        }, rotated))
                    })
                });
                that._valueAxes = valueAxes;
                that._argumentAxes = argumentAxes
            },
            _prepareStackPoints: function(singleSeries, stackPoints) {
                var points = singleSeries.getPoints(),
                    stackName = singleSeries.getStackName();
                _each(points, function(_, point) {
                    var argument = point.argument;
                    if (!stackPoints[argument]) {
                        stackPoints[argument] = {};
                        stackPoints[argument][null] = []
                    }
                    if (stackName && !_isArray(stackPoints[argument][stackName])) {
                        stackPoints[argument][stackName] = [];
                        _each(stackPoints[argument][null], function(_, point) {
                            if (!point.stackName) {
                                stackPoints[argument][stackName].push(point)
                            }
                        })
                    }
                    if (stackName) {
                        stackPoints[argument][stackName].push(point);
                        stackPoints[argument][null].push(point)
                    } else {
                        _each(stackPoints[argument], function(_, stack) {
                            stack.push(point)
                        })
                    }
                    point.stackPoints = stackPoints[argument][stackName];
                    point.stackName = stackName
                })
            },
            _resetStackPoints: function(singleSeries) {
                _each(singleSeries.getPoints(), function(_, point) {
                    point.stackPoints = null;
                    point.stackName = null
                })
            },
            _disposeAxes: function() {
                var that = this,
                    disposeObjectsInArray = that._disposeObjectsInArray;
                disposeObjectsInArray.call(that, "_argumentAxes");
                disposeObjectsInArray.call(that, "_valueAxes")
            },
            _drawAxes: function(panesBorderOptions, drawOptions, adjustUnits) {
                var that = this,
                    drawAxes = function(axes) {
                        _each(axes, function(_, axis) {
                            axis.draw(adjustUnits)
                        })
                    },
                    drawStaticAxisElements = function(axes) {
                        _each(axes, function(_i, axis) {
                            axis.drawGrids(panesBorderOptions[axis.pane])
                        })
                    };
                that._restoreOriginalBusinessRange();
                that._reinitTranslators();
                that._prepareAxesAndDraw(drawAxes, drawStaticAxisElements, drawOptions)
            },
            _restoreOriginalBusinessRange: _noop,
            _appendAdditionalSeriesGroups: function() {
                this._crosshairCursorGroup.linkAppend();
                this._scrollBar && this._scrollBarGroup.linkAppend()
            },
            _getLegendTargets: function() {
                var that = this;
                return _map(that.series, function(item) {
                    if (item.getOptions().showInLegend) {
                        return that._getLegendOptions(item)
                    }
                    return null
                })
            },
            _legendItemTextField: "name",
            _seriesPopulatedHandlerCore: function() {
                this._processSeriesFamilies();
                this._processValueAxisFormat()
            },
            _renderTrackers: function() {
                var i, that = this;
                for (i = 0; i < that.series.length; ++i) {
                    that.series[i].drawTrackers()
                }
            },
            _specialProcessSeries: function() {
                this._processSeriesFamilies()
            },
            _processSeriesFamilies: function() {
                var paneSeries, that = this,
                    types = [],
                    families = [],
                    themeManager = that._themeManager,
                    negativesAsZeroes = themeManager.getOptions("negativesAsZeroes"),
                    negativesAsZeros = themeManager.getOptions("negativesAsZeros"),
                    familyOptions = {
                        equalBarWidth: themeManager.getOptions("equalBarWidth"),
                        minBubbleSize: themeManager.getOptions("minBubbleSize"),
                        maxBubbleSize: themeManager.getOptions("maxBubbleSize"),
                        barWidth: themeManager.getOptions("barWidth"),
                        negativesAsZeroes: _isDefined(negativesAsZeroes) ? negativesAsZeroes : negativesAsZeros
                    };
                if (that.seriesFamilies && that.seriesFamilies.length) {
                    _each(that.seriesFamilies, function(_, family) {
                        family.updateOptions(familyOptions);
                        family.adjustSeriesValues()
                    });
                    return
                }
                _each(that.series, function(_, item) {
                    if ($.inArray(item.type, types) === -1) {
                        types.push(item.type)
                    }
                });
                _each(that._getLayoutTargets(), function(_, pane) {
                    paneSeries = that._getSeriesForPane(pane.name);
                    _each(types, function(_, type) {
                        var family = new seriesFamilyModule.SeriesFamily({
                            type: type,
                            pane: pane.name,
                            equalBarWidth: familyOptions.equalBarWidth,
                            minBubbleSize: familyOptions.minBubbleSize,
                            maxBubbleSize: familyOptions.maxBubbleSize,
                            barWidth: familyOptions.barWidth,
                            negativesAsZeroes: familyOptions.negativesAsZeroes,
                            rotated: that._isRotated()
                        });
                        family.add(paneSeries);
                        family.adjustSeriesValues();
                        families.push(family)
                    })
                });
                that.seriesFamilies = families
            },
            _updateSeriesDimensions: function() {
                var i, that = this,
                    seriesFamilies = that.seriesFamilies || [];
                for (i = 0; i < seriesFamilies.length; i++) {
                    var family = seriesFamilies[i],
                        translators = that._getTranslator(family.pane) || {};
                    family.updateSeriesValues(translators);
                    family.adjustSeriesDimensions(translators)
                }
            },
            _getLegendCallBack: function(series) {
                return this._legend && this._legend.getActionCallback(series)
            },
            _appendAxesGroups: function() {
                var that = this;
                that._stripsGroup.linkAppend();
                that._gridGroup.linkAppend();
                that._axesGroup.linkAppend();
                that._constantLinesGroup.linkAppend();
                that._labelAxesGroup.linkAppend()
            },
            _populateBusinessRange: function(visibleArea) {
                var argBusinessRange, that = this,
                    businessRanges = [],
                    rotated = that._isRotated(),
                    argAxes = that._argumentAxes,
                    lastArgAxis = argAxes[argAxes.length - 1],
                    calcInterval = lastArgAxis.calcInterval,
                    argRange = new rangeModule.Range({
                        rotated: !!rotated
                    }),
                    groupsData = that._groupsData;
                that.businessRanges = null;
                _each(argAxes, function(_, axis) {
                    argRange.addRange(axis.getRangeData())
                });
                _each(groupsData.groups, function(_, group) {
                    var groupRange = new rangeModule.Range({
                            rotated: !!rotated,
                            pane: group.valueAxis.pane,
                            axis: group.valueAxis.name
                        }),
                        groupAxisRange = group.valueAxis.getRangeData();
                    groupRange.addRange(groupAxisRange);
                    if (visibleArea) {
                        visibleArea.minArg = _isDefined(visibleArea.minArg) ? visibleArea.minArg : argRange.minVisible;
                        visibleArea.maxArg = _isDefined(visibleArea.maxArg) ? visibleArea.maxArg : argRange.maxVisible
                    }
                    _each(group.series, function(_, series) {
                        var aggregationRange = series.getRangeData(),
                            visibleSeriesArea = visibleArea && {
                                minArg: _isDefined(visibleArea.minArg) ? visibleArea.minArg : aggregationRange.arg.min,
                                maxArg: _isDefined(visibleArea.maxArg) ? visibleArea.maxArg : aggregationRange.arg.max,
                                minVal: groupAxisRange.min,
                                maxVal: groupAxisRange.max,
                                adjustOnZoom: visibleArea.adjustOnZoom,
                                notApplyMargins: visibleArea.notApplyMargins
                            },
                            seriesRange = series.getRangeData(visibleSeriesArea, calcInterval);
                        groupRange.addRange(seriesRange.val);
                        argRange.addRange(seriesRange.arg)
                    });
                    if (!groupRange.isDefined()) {
                        groupRange.setStubData(group.valueAxis.getOptions().valueType)
                    }
                    if (group.valueAxis.getOptions().showZero) {
                        groupRange.correctValueZeroLevel()
                    }
                    groupRange.checkZeroStick();
                    businessRanges.push({
                        val: groupRange,
                        arg: argRange
                    })
                });
                argRange.addRange({
                    categories: groupsData.categories
                });
                if (!argRange.isDefined()) {
                    argRange.setStubData(argAxes[0].getOptions().argumentType)
                }
                if (visibleArea && visibleArea.notApplyMargins && "discrete" !== argRange.axisType) {
                    argBusinessRange = argAxes[0].getTranslator().getBusinessRange();
                    argRange.addRange({
                        min: argBusinessRange.min,
                        max: argBusinessRange.max,
                        stick: true
                    })
                }
                that._correctBusinessRange(argRange, lastArgAxis);
                that.businessRanges = businessRanges
            },
            _correctBusinessRange: function(range, lastArgAxis) {
                var setTicksAtUnitBeginning = lastArgAxis.getOptions().setTicksAtUnitBeginning,
                    tickIntervalRange = {},
                    tickInterval = lastArgAxis.getOptions().tickInterval,
                    originInterval = tickInterval;
                tickInterval = $.isNumeric(tickInterval) ? tickInterval : dateUtils.dateToMilliseconds(tickInterval);
                if (tickInterval && _isDefined(range[MIN]) && _isDefined(range[MAX]) && tickInterval >= Math.abs(range[MAX] - range[MIN])) {
                    if (commonUtils.isDate(range[MIN])) {
                        if (!$.isNumeric(originInterval)) {
                            tickIntervalRange[MIN] = dateUtils.addInterval(range[MIN], originInterval, true);
                            tickIntervalRange[MAX] = dateUtils.addInterval(range[MAX], originInterval, false)
                        } else {
                            tickIntervalRange[MIN] = new Date(range[MIN].valueOf() - tickInterval);
                            tickIntervalRange[MAX] = new Date(range[MAX].valueOf() + tickInterval)
                        }
                        if (setTicksAtUnitBeginning) {
                            tickIntervalRange[MAX] = dateUtils.correctDateWithUnitBeginning(tickIntervalRange[MAX], originInterval);
                            tickIntervalRange[MIN] = dateUtils.correctDateWithUnitBeginning(tickIntervalRange[MIN], originInterval)
                        }
                    } else {
                        tickIntervalRange[MIN] = range[MIN] - tickInterval;
                        tickIntervalRange[MAX] = range[MAX] + tickInterval
                    }
                    range.addRange(tickIntervalRange)
                }
            },
            _getArgumentAxes: function() {
                return this._argumentAxes
            },
            _getValueAxes: function() {
                return this._valueAxes
            },
            _processValueAxisFormat: function() {
                var that = this,
                    valueAxes = that._valueAxes,
                    axesWithFullStackedFormat = [];
                _each(that.series, function() {
                    if (this.isFullStackedSeries() && $.inArray(this.axis, axesWithFullStackedFormat) === -1) {
                        axesWithFullStackedFormat.push(this.axis)
                    }
                });
                _each(valueAxes, function() {
                    if ($.inArray(this.name, axesWithFullStackedFormat) !== -1) {
                        this.setPercentLabelFormat()
                    } else {
                        this.resetAutoLabelFormat()
                    }
                })
            },
            _createAxis: function(typeSelector, userOptions, axisOptions, rotated, virtual, index) {
                var axis, that = this,
                    renderingSettings = _extend({
                        renderer: that._renderer,
                        incidentOccurred: that._incidentOccurred,
                        axisClass: "argumentAxis" === typeSelector ? "arg" : "val",
                        widgetClass: "dxc",
                        stripsGroup: that._stripsGroup,
                        labelAxesGroup: that._labelAxesGroup,
                        constantLinesGroup: that._constantLinesGroup,
                        axesContainerGroup: that._axesGroup,
                        gridGroup: that._gridGroup
                    }, that._getAxisRenderingOptions(typeSelector)),
                    preparedUserOptions = that._prepareStripsAndConstantLines(typeSelector, userOptions, rotated),
                    options = _extend(true, {}, preparedUserOptions, axisOptions, that._prepareAxisOptions(typeSelector, preparedUserOptions, rotated));
                if (virtual) {
                    options.visible = options.tick.visible = options.minorTick.visible = options.label.visible = false;
                    options.title = {}
                }
                axis = new axisModule.Axis(renderingSettings);
                axis.updateOptions(options);
                if (!virtual && _isDefined(index)) {
                    that._displayedArgumentAxisIndex = index
                }
                return axis
            },
            _getTrackerSettings: function() {
                return _extend(this.callBase(), {
                    argumentAxis: this._argumentAxes[this._displayedArgumentAxisIndex]
                })
            },
            _prepareStripsAndConstantLines: function(typeSelector, userOptions, rotated) {
                userOptions = this._themeManager.getOptions(typeSelector, userOptions, rotated);
                if (userOptions.strips) {
                    _each(userOptions.strips, function(i) {
                        userOptions.strips[i] = _extend(true, {}, userOptions.stripStyle, userOptions.strips[i])
                    })
                }
                if (userOptions.constantLines) {
                    _each(userOptions.constantLines, function(i, line) {
                        userOptions.constantLines[i] = _extend(true, {}, userOptions.constantLineStyle, line)
                    })
                }
                return userOptions
            },
            _legendDataField: "series",
            _getStoredSeries: function() {
                return this.series
            },
            _adjustSeries: _noop,
            _collectPointsByArg: _noop
        });
        exports.AdvancedChart = AdvancedChart
    },
    /*!***************************************!*\
      !*** ./Scripts/viz/axes/base_axis.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var Axis, $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            constants = __webpack_require__( /*! ./axes_constants */ 507),
            parseUtils = __webpack_require__( /*! ../components/parse_utils */ 459),
            tickManagerModule = __webpack_require__( /*! ./base_tick_manager */ 508),
            formatLabel = constants.formatLabel,
            convertTicksToValues = constants.convertTicksToValues,
            convertValuesToTicks = constants.convertValuesToTicks,
            _isDefined = commonUtils.isDefined,
            _isNumber = commonUtils.isNumber,
            _getSignificantDigitPosition = vizUtils.getSignificantDigitPosition,
            _roundValue = vizUtils.roundValue,
            patchFontOptions = vizUtils.patchFontOptions,
            _math = Math,
            _abs = _math.abs,
            _round = _math.round,
            _extend = $.extend,
            _each = $.each,
            _noop = $.noop,
            DEFAULT_AXIS_LABEL_SPACING = 5,
            MAX_GRID_BORDER_ADHENSION = 4,
            LABEL_BACKGROUND_PADDING_X = 8,
            LABEL_BACKGROUND_PADDING_Y = 4;

        function hasCategories(range) {
            return range.categories && range.categories.length
        }

        function validateAxisOptions(options) {
            var labelOptions = options.label,
                position = options.position,
                defaultPosition = options.isHorizontal ? constants.bottom : constants.left,
                secondaryPosition = options.isHorizontal ? constants.top : constants.right;
            if (position !== defaultPosition && position !== secondaryPosition) {
                position = defaultPosition
            }
            if (position === constants.right && !labelOptions.userAlignment) {
                labelOptions.alignment = constants.left
            }
            options.position = position;
            options.hoverMode = options.hoverMode ? options.hoverMode.toLowerCase() : "none";
            labelOptions.minSpacing = _isDefined(labelOptions.minSpacing) ? labelOptions.minSpacing : DEFAULT_AXIS_LABEL_SPACING
        }

        function findSkippedIndexCategory(ticks, skippedCategory) {
            var i = ticks.length;
            if (void 0 !== skippedCategory) {
                while (i--) {
                    if (ticks[i].value === skippedCategory) {
                        return i
                    }
                }
            }
            return -1
        }
        Axis = exports.Axis = function(renderSettings) {
            var that = this;
            that._renderer = renderSettings.renderer;
            that._incidentOccurred = renderSettings.incidentOccurred;
            that._stripsGroup = renderSettings.stripsGroup;
            that._labelAxesGroup = renderSettings.labelAxesGroup;
            that._constantLinesGroup = renderSettings.constantLinesGroup;
            that._axesContainerGroup = renderSettings.axesContainerGroup;
            that._gridContainerGroup = renderSettings.gridGroup;
            that._axisCssPrefix = renderSettings.widgetClass + "-" + (renderSettings.axisClass ? renderSettings.axisClass + "-" : "");
            that._setType(renderSettings.axisType, renderSettings.drawingType);
            that._createAxisGroups();
            that._tickManager = that._createTickManager()
        };
        Axis.prototype = {
            constructor: Axis,
            _updateIntervalAndBounds: function() {
                var i, ticks, length, minInterval, bounds, that = this,
                    translator = that._translator,
                    businessRange = translator.getBusinessRange();
                if (!hasCategories(businessRange)) {
                    ticks = that.getMajorTicks(true);
                    length = ticks.length;
                    if (!businessRange.isSynchronized) {
                        bounds = this._tickManager.getTickBounds()
                    }
                    if (length > 1) {
                        minInterval = _abs(ticks[0].value - ticks[1].value);
                        for (i = 1; i < length - 1; i++) {
                            minInterval = Math.min(_abs(ticks[i].value - ticks[i + 1].value), minInterval)
                        }
                        bounds = _extend({
                            interval: minInterval
                        }, bounds)
                    }
                    if (bounds) {
                        businessRange.addRange(bounds);
                        translator.reinit()
                    }
                }
            },
            _createAllTicks: function(businessRange) {
                var that = this;
                that._boundaryTicks = that._getBoundaryTicks();
                that._majorTicks = that.getMajorTicks(that._options.withoutOverlappingBehavior);
                that._decimatedTicks = hasCategories(businessRange) || "semidiscrete" === that._options.type ? that.getDecimatedTicks() : [];
                that._minorTicks = that.getMinorTicks()
            },
            _drawAxis: function() {
                var that = this,
                    options = that._options,
                    axis = that._createAxis({
                        "stroke-width": options.width,
                        stroke: options.color,
                        "stroke-opacity": options.opacity
                    });
                axis.append(that._axisLineGroup)
            },
            _correctMinForTicks: function(min, max, screenDelta) {
                var correctingValue, digitPosition = _getSignificantDigitPosition(_abs(max - min) / screenDelta),
                    newMin = _roundValue(Number(min), digitPosition);
                if (newMin < min) {
                    correctingValue = _math.pow(10, -digitPosition);
                    newMin = vizUtils.applyPrecisionByMinDelta(newMin, correctingValue, newMin + correctingValue)
                }
                if (newMin > max) {
                    newMin = min
                }
                return newMin
            },
            _getTickManagerData: function() {
                var that = this,
                    options = that._options,
                    screenDelta = that._getScreenDelta(),
                    min = that._minBound,
                    max = that._maxBound,
                    categories = that._translator.getVisibleCategories() || that._translator.getBusinessRange().categories,
                    customTicks = options.customTicks || (hasCategories({
                        categories: categories
                    }) ? categories : that._majorTicks && that._majorTicks.length && convertTicksToValues(that._majorTicks)),
                    customMinorTicks = options.customMinorTicks || that._minorTicks && that._minorTicks.length && convertTicksToValues(that._minorTicks);
                if (_isNumber(min) && options.type !== constants.logarithmic) {
                    min = that._correctMinForTicks(min, max, screenDelta)
                }
                return {
                    min: min,
                    max: max,
                    customTicks: customTicks,
                    customMinorTicks: customMinorTicks,
                    customBoundTicks: options.customBoundTicks,
                    screenDelta: screenDelta
                }
            },
            _getTickManagerTypes: function() {
                return {
                    axisType: this._options.type,
                    dataType: this._options.dataType
                }
            },
            _getTicksOptions: function() {
                var options = this._options;
                return {
                    base: options.type === constants.logarithmic ? options.logarithmBase : void 0,
                    tickInterval: this._translator.getBusinessRange().stubData ? null : options.tickInterval,
                    gridSpacingFactor: options.axisDivisionFactor,
                    minorGridSpacingFactor: options.minorAxisDivisionFactor,
                    numberMultipliers: options.numberMultipliers,
                    incidentOccurred: options.incidentOccurred,
                    setTicksAtUnitBeginning: options.setTicksAtUnitBeginning,
                    showMinorTicks: options.minorTick.visible || options.minorGrid.visible,
                    minorTickInterval: options.minorTickInterval,
                    minorTickCount: options.minorTickCount,
                    useTicksAutoArrangement: options.useTicksAutoArrangement,
                    showCalculatedTicks: options.tick.showCalculatedTicks,
                    showMinorCalculatedTicks: options.minorTick.showCalculatedTicks
                }
            },
            _getBoundaryTicks: function() {
                var categories = this._translator.getVisibleCategories() || this._translator.getBusinessRange().categories,
                    boundaryValues = hasCategories({
                        categories: categories
                    }) && this._tickOffset ? [categories[0], categories[categories.length - 1]] : this._tickManager.getBoundaryTicks();
                return convertValuesToTicks(boundaryValues)
            },
            _createTickManager: function() {
                return new tickManagerModule.TickManager({}, {}, {
                    overlappingBehaviorType: this._overlappingBehaviorType
                })
            },
            _getMarginsOptions: function() {
                var range = this._translator.getBusinessRange();
                return {
                    stick: range.stick || this._options.stick,
                    minStickValue: range.minStickValue,
                    maxStickValue: range.maxStickValue,
                    percentStick: range.percentStick,
                    minValueMargin: this._options.minValueMargin,
                    maxValueMargin: this._options.maxValueMargin,
                    minSpaceCorrection: range.minSpaceCorrection,
                    maxSpaceCorrection: range.maxSpaceCorrection
                }
            },
            _updateTickManager: function() {
                var options, overlappingOptions = this._getOverlappingBehaviorOptions();
                options = _extend(true, this._getMarginsOptions(), overlappingOptions, this._getTicksOptions());
                this._tickManager.update(this._getTickManagerTypes(), this._getTickManagerData(), options)
            },
            _correctLabelAlignment: function() {
                var that = this,
                    labelOptions = that._options.label,
                    overlappingBehavior = that._tickManager.getOverlappingBehavior();
                if (overlappingBehavior && "rotate" === overlappingBehavior.mode) {
                    that._textOptions.rotate = overlappingBehavior.rotationAngle;
                    if (!labelOptions.userAlignment) {
                        that._textOptions.align = constants.left
                    }
                } else {
                    if (!labelOptions.userAlignment) {
                        that._textOptions.align = labelOptions.alignment
                    }
                }
            },
            _correctLabelFormat: function() {
                this._options.label = this._tickManager.getOptions().labelOptions
            },
            _deleteLabels: function() {
                this._axisElementsGroup && this._axisElementsGroup.clear()
            },
            _drawTicks: function(ticks) {
                var that = this,
                    group = that._axisLineGroup;
                _each(ticks || [], function(_, tick) {
                    var points, coord = that._getTickCoord(tick);
                    if (coord) {
                        points = that._isHorizontal ? [coord.x1, coord.y1, coord.x2, coord.y2] : [coord.y1, coord.x1, coord.y2, coord.x2];
                        tick.graphic = that._createPathElement(points, tick.tickStyle).append(group);
                        coord.angle && that._rotateTick(tick, coord.angle)
                    }
                })
            },
            _createPathElement: function(points, attr) {
                return this._renderer.path(points, "line").attr(attr).sharp(this._getSharpParam())
            },
            _createAxis: function(options) {
                return this._createAxisElement().attr(options).sharp(this._getSharpParam(true))
            },
            _drawLabels: function() {
                var that = this,
                    renderer = that._renderer,
                    group = that._axisElementsGroup,
                    emptyStrRegExp = /^\s+$/;
                _each(that._majorTicks, function(_, tick) {
                    var xCoord, yCoord, text = tick.labelText;
                    if (_isDefined(text) && "" !== text && !emptyStrRegExp.test(text)) {
                        xCoord = that._isHorizontal ? tick.labelPos.x : tick.labelPos.y;
                        yCoord = that._isHorizontal ? tick.labelPos.y : tick.labelPos.x;
                        if (!tick.label) {
                            tick.label = renderer.text(text, xCoord, yCoord).css(tick.labelFontStyle).attr(tick.labelStyle).append(group)
                        } else {
                            tick.label.css(tick.labelFontStyle).attr(tick.labelStyle).attr({
                                text: text,
                                x: xCoord,
                                y: yCoord
                            })
                        }
                        tick.label.data({
                            "chart-data-argument": tick.value
                        })
                    }
                })
            },
            _getGridLineDrawer: function(borderOptions) {
                var that = this,
                    translator = that._translator,
                    additionalTranslator = that._additionalTranslator,
                    isHorizontal = that._isHorizontal,
                    canvasStart = isHorizontal ? constants.left : constants.top,
                    canvasEnd = isHorizontal ? constants.right : constants.bottom,
                    positionFrom = additionalTranslator.translateSpecialCase(constants.canvasPositionStart),
                    positionTo = additionalTranslator.translateSpecialCase(constants.canvasPositionEnd),
                    firstBorderLinePosition = borderOptions.visible && borderOptions[canvasStart] ? translator.translateSpecialCase(constants.canvasPositionPrefix + canvasStart) : void 0,
                    lastBorderLinePosition = borderOptions.visible && borderOptions[canvasEnd] ? translator.translateSpecialCase(constants.canvasPositionPrefix + canvasEnd) : void 0,
                    getPoints = isHorizontal ? function(tick) {
                        return null !== tick.posX ? [tick.posX, positionFrom, tick.posX, positionTo] : null
                    } : function(tick) {
                        return null !== tick.posX ? [positionFrom, tick.posX, positionTo, tick.posX] : null
                    },
                    minDelta = MAX_GRID_BORDER_ADHENSION + firstBorderLinePosition,
                    maxDelta = lastBorderLinePosition - MAX_GRID_BORDER_ADHENSION;
                return function(tick) {
                    if (void 0 === tick.posX || tick.posX < minDelta || tick.posX > maxDelta) {
                        return
                    }
                    var points = getPoints(tick);
                    return points && that._createPathElement(points, tick.gridStyle)
                }
            },
            _drawGrids: function(ticks, borderOptions) {
                var tick, that = this,
                    group = that._axisGridGroup,
                    i = 0,
                    length = ticks.length,
                    drawLine = that._getGridLineDrawer(borderOptions || {
                        visible: false
                    });
                for (i; i < length; i++) {
                    tick = ticks[i];
                    tick.grid = drawLine(tick);
                    tick.grid && tick.grid.append(group)
                }
            },
            _getConstantLinePos: function(lineValue, canvasStart, canvasEnd) {
                var parsedValue = this._validateUnit(lineValue, "E2105", "constantLine"),
                    value = this._getTranslatedCoord(parsedValue);
                if (!_isDefined(value) || value < _math.min(canvasStart, canvasEnd) || value > _math.max(canvasStart, canvasEnd)) {
                    return {}
                }
                return {
                    value: value,
                    parsedValue: parsedValue
                }
            },
            _createConstantLine: function(value, attr) {
                var that = this,
                    additionalTranslator = this._additionalTranslator,
                    positionFrom = additionalTranslator.translateSpecialCase(constants.canvasPositionStart),
                    positionTo = additionalTranslator.translateSpecialCase(constants.canvasPositionEnd),
                    points = this._isHorizontal ? [value, positionTo, value, positionFrom] : [positionFrom, value, positionTo, value];
                return that._createPathElement(points, attr)
            },
            _drawConstantLinesAndLabels: function(lineOptions, canvasStart, canvasEnd) {
                if (!_isDefined(lineOptions.value)) {
                    return
                }
                var that = this,
                    pos = that._getConstantLinePos(lineOptions.value, canvasStart, canvasEnd),
                    labelOptions = lineOptions.label || {},
                    value = pos.value,
                    attr = {
                        stroke: lineOptions.color,
                        "stroke-width": lineOptions.width,
                        dashStyle: lineOptions.dashStyle
                    };
                if (!_isDefined(value)) {
                    that._constantLines.push(null);
                    if (labelOptions.visible) {
                        that._constantLineLabels.push(null)
                    }
                    return
                }
                that._constantLines.push(that._createConstantLine(value, attr).append(that._axisConstantLineGroup));
                that._constantLineLabels.push(labelOptions.visible ? that._drawConstantLineLabels(pos.parsedValue, labelOptions, value) : null)
            },
            _drawConstantLine: function() {
                var that = this,
                    options = that._options,
                    data = options.constantLines,
                    canvas = that._getCanvasStartEnd();
                if (that._translator.getBusinessRange().stubData) {
                    return
                }
                that._constantLines = [];
                that._constantLineLabels = [];
                _each(data, function(_, dataItem) {
                    that._drawConstantLinesAndLabels(dataItem, canvas.start, canvas.end)
                })
            },
            _drawConstantLineLabels: function(parsedValue, lineLabelOptions, value) {
                var coords, that = this,
                    text = lineLabelOptions.text,
                    options = that._options,
                    labelOptions = options.label;
                that._checkAlignmentConstantLineLabels(lineLabelOptions);
                text = _isDefined(text) ? text : formatLabel(parsedValue, labelOptions);
                coords = that._getConstantLineLabelsCoords(value, lineLabelOptions);
                return that._renderer.text(text, coords.x, coords.y).css(patchFontOptions(_extend({}, labelOptions.font, lineLabelOptions.font))).attr({
                    align: coords.align
                }).append(that._axisConstantLineGroup)
            },
            _getStripPos: function(startValue, endValue, canvasStart, canvasEnd, range) {
                var start, end, swap, startCategoryIndex, endCategoryIndex, isContinuous = !!(range.minVisible || range.maxVisible),
                    categories = range.categories || [],
                    min = range.minVisible;
                if (!isContinuous) {
                    if (_isDefined(startValue) && _isDefined(endValue)) {
                        startCategoryIndex = $.inArray(startValue, categories);
                        endCategoryIndex = $.inArray(endValue, categories);
                        if (startCategoryIndex === -1 || endCategoryIndex === -1) {
                            return {
                                stripFrom: 0,
                                stripTo: 0
                            }
                        }
                        if (startCategoryIndex > endCategoryIndex) {
                            swap = endValue;
                            endValue = startValue;
                            startValue = swap
                        }
                    }
                }
                if (_isDefined(startValue)) {
                    startValue = this._validateUnit(startValue, "E2105", "strip");
                    start = this._getTranslatedCoord(startValue, -1);
                    if (!_isDefined(start) && isContinuous) {
                        start = startValue < min ? canvasStart : canvasEnd
                    }
                } else {
                    start = canvasStart
                }
                if (_isDefined(endValue)) {
                    endValue = this._validateUnit(endValue, "E2105", "strip");
                    end = this._getTranslatedCoord(endValue, 1);
                    if (!_isDefined(end) && isContinuous) {
                        end = endValue > min ? canvasEnd : canvasStart
                    }
                } else {
                    end = canvasEnd
                }
                return start < end ? {
                    stripFrom: start,
                    stripTo: end
                } : {
                    stripFrom: end,
                    stripTo: start
                }
            },
            _createStrip: function(fromPoint, toPoint, attr) {
                var x, y, width, height, additionalTranslator = this._additionalTranslator,
                    positionFrom = additionalTranslator.translateSpecialCase(constants.canvasPositionStart),
                    positionTo = additionalTranslator.translateSpecialCase(constants.canvasPositionEnd);
                if (this._isHorizontal) {
                    x = fromPoint;
                    y = _math.min(positionFrom, positionTo);
                    width = toPoint - fromPoint;
                    height = _abs(positionFrom - positionTo)
                } else {
                    x = _math.min(positionFrom, positionTo);
                    y = fromPoint;
                    width = _abs(positionFrom - positionTo);
                    height = _abs(fromPoint - toPoint)
                }
                return this._renderer.rect(x, y, width, height).attr(attr)
            },
            _drawStrip: function() {
                var i, stripOptions, stripPos, stripLabelOptions, attr, that = this,
                    options = that._options,
                    stripData = options.strips,
                    canvas = this._getCanvasStartEnd(),
                    range = that._translator.getBusinessRange();
                if (range.stubData) {
                    return
                }
                that._strips = [];
                that._stripLabels = [];
                for (i = 0; i < stripData.length; i++) {
                    stripOptions = stripData[i];
                    stripLabelOptions = stripOptions.label || {};
                    attr = {
                        fill: stripOptions.color
                    };
                    if ((_isDefined(stripOptions.startValue) || _isDefined(stripOptions.endValue)) && _isDefined(stripOptions.color)) {
                        stripPos = that._getStripPos(stripOptions.startValue, stripOptions.endValue, canvas.start, canvas.end, range);
                        if (stripPos.stripTo - stripPos.stripFrom === 0 || !_isDefined(stripPos.stripTo) || !_isDefined(stripPos.stripFrom)) {
                            that._strips.push(null);
                            if (stripLabelOptions.text) {
                                that._stripLabels.push(null)
                            }
                            continue
                        }
                        that._strips.push(that._createStrip(stripPos.stripFrom, stripPos.stripTo, attr).append(that._axisStripGroup));
                        that._stripLabels.push(stripLabelOptions.text ? that._drawStripLabel(stripLabelOptions, stripPos.stripFrom, stripPos.stripTo) : null)
                    }
                }
            },
            _drawStripLabel: function(stripLabelOptions, stripFrom, stripTo) {
                var that = this,
                    options = that._options,
                    coords = that._getStripLabelCoords(stripLabelOptions, stripFrom, stripTo);
                return that._renderer.text(stripLabelOptions.text, coords.x, coords.y).css(patchFontOptions(_extend({}, options.label.font, stripLabelOptions.font))).attr({
                    align: coords.align
                }).append(that._axisLabelGroup)
            },
            _adjustStripLabels: function() {
                var i, coords, that = this,
                    labels = that._stripLabels,
                    rects = that._strips;
                if (void 0 === labels && void 0 === rects) {
                    return
                }
                for (i = 0; i < labels.length; i++) {
                    if (null !== labels[i]) {
                        coords = that._getAdjustedStripLabelCoords(that._options.strips[i], labels[i], rects[i]);
                        labels[i].move(coords.x, coords.y)
                    }
                }
            },
            _adjustLabels: function() {
                var label, labelHeight, isNeedLabelAdjustment, staggeringSpacing, i, box, that = this,
                    options = that._options,
                    majorTicks = that._majorTicks,
                    majorTicksLength = majorTicks.length,
                    isHorizontal = that._isHorizontal,
                    overlappingBehavior = that._tickManager ? that._tickManager.getOverlappingBehavior() : options.label.overlappingBehavior,
                    position = options.position,
                    hasLabels = false,
                    boxAxis = that._axisElementsGroup && that._axisElementsGroup.getBBox() || {};
                _each(majorTicks, function(_, tick) {
                    if (tick.label) {
                        tick.label.attr(that._getLabelAdjustedCoord(tick, boxAxis));
                        hasLabels = true
                    }
                });
                isNeedLabelAdjustment = hasLabels && isHorizontal && overlappingBehavior && "stagger" === overlappingBehavior.mode;
                if (isNeedLabelAdjustment) {
                    labelHeight = 0;
                    for (i = 0; i < majorTicksLength; i += 2) {
                        label = majorTicks[i].label;
                        box = label && label.getBBox() || {};
                        if (box.height > labelHeight) {
                            labelHeight = box.height
                        }
                    }
                    staggeringSpacing = overlappingBehavior.staggeringSpacing;
                    labelHeight = _round(labelHeight) + staggeringSpacing;
                    for (i = 1; i < majorTicksLength; i += 2) {
                        label = majorTicks[i].label;
                        if (label) {
                            if (position === constants.bottom) {
                                label.move(0, labelHeight)
                            } else {
                                if (position === constants.top) {
                                    label.move(0, -labelHeight)
                                }
                            }
                        }
                    }
                    for (i = 0; i < majorTicksLength; i++) {
                        majorTicks[i].label && majorTicks[i].label.rotate(0)
                    }
                }
            },
            _getLabelAdjustedCoord: function(tick, boxAxis) {
                var x, y, that = this,
                    options = that._options,
                    box = tick.label.getBBox(),
                    isHorizontal = that._isHorizontal,
                    position = options.position,
                    shift = that.padding && that.padding[position] || 0,
                    textOptions = that._textOptions,
                    labelSettingsY = tick.label.attr("y");
                if (isHorizontal && position === constants.bottom) {
                    y = 2 * labelSettingsY - box.y + shift
                } else {
                    if (!isHorizontal) {
                        if (position === constants.left) {
                            if (textOptions.align === constants.right) {
                                x = box.x + box.width - shift
                            } else {
                                if (textOptions.align === constants.center) {
                                    x = box.x + box.width / 2 - shift - (boxAxis.width / 2 || 0)
                                } else {
                                    x = box.x - shift - (boxAxis.width || 0)
                                }
                            }
                        } else {
                            if (textOptions.align === constants.center) {
                                x = box.x + box.width / 2 + (boxAxis.width / 2 || 0) + shift
                            } else {
                                if (textOptions.align === constants.right) {
                                    x = box.x + box.width + (boxAxis.width || 0) + shift
                                } else {
                                    x = box.x + shift
                                }
                            }
                        }
                        y = labelSettingsY + ~~(labelSettingsY - box.y - box.height / 2)
                    } else {
                        if (isHorizontal && position === constants.top) {
                            y = 2 * labelSettingsY - box.y - box.height - shift
                        }
                    }
                }
                return {
                    x: x,
                    y: y
                }
            },
            _createAxisGroups: function() {
                var that = this,
                    renderer = that._renderer,
                    classSelector = that._axisCssPrefix;
                that._axisGroup = renderer.g().attr({
                    "class": classSelector + "axis"
                });
                that._axisStripGroup = renderer.g().attr({
                    "class": classSelector + "strips"
                });
                that._axisGridGroup = renderer.g().attr({
                    "class": classSelector + "grid"
                });
                that._axisElementsGroup = renderer.g().attr({
                    "class": classSelector + "elements"
                }).append(that._axisGroup);
                that._axisLineGroup = renderer.g().attr({
                    "class": classSelector + "line"
                }).append(that._axisGroup);
                that._axisTitleGroup = renderer.g().attr({
                    "class": classSelector + "title"
                }).append(that._axisGroup);
                that._axisConstantLineGroup = renderer.g().attr({
                    "class": classSelector + "constant-lines"
                });
                that._axisLabelGroup = renderer.g().attr({
                    "class": classSelector + "axis-labels"
                })
            },
            _clearAxisGroups: function(adjustAxis) {
                var that = this,
                    classSelector = that._axisCssPrefix;
                that._axisGroup.remove();
                that._axisStripGroup.remove();
                that._axisLabelGroup.remove();
                that._axisConstantLineGroup.remove();
                that._axisGridGroup.remove();
                if (that._axisTitleGroup) {
                    that._axisTitleGroup.clear()
                } else {
                    if (!adjustAxis) {
                        that._axisTitleGroup = that._renderer.g().attr({
                            "class": classSelector + "title"
                        }).append(that._axisGroup)
                    }
                }
                if (that._axisElementsGroup) {
                    that._axisElementsGroup.clear()
                } else {
                    if (!adjustAxis) {
                        that._axisElementsGroup = that._renderer.g().attr({
                            "class": classSelector + "elements"
                        }).append(that._axisGroup)
                    }
                }
                that._axisLineGroup && that._axisLineGroup.clear();
                that._axisStripGroup && that._axisStripGroup.clear();
                that._axisGridGroup && that._axisGridGroup.clear();
                that._axisConstantLineGroup && that._axisConstantLineGroup.clear();
                that._axisLabelGroup && that._axisLabelGroup.clear()
            },
            _initTickCoord: function(tick, offset) {
                var coord = this._getTranslatedValue(tick.value, this._axisPosition, offset);
                tick.posX = coord.x;
                tick.posY = coord.y;
                tick.angle = coord.angle
            },
            _initTickStyle: function(tick, style) {
                tick.length = style.length;
                tick.tickStyle = tick.withoutPath ? {
                    stroke: "none",
                    "stroke-width": 0,
                    "stroke-opacity": 0
                } : style.tickStyle;
                tick.gridStyle = style.gridStyle
            },
            _initTickLabel: function(tick, position) {
                var that = this,
                    customizeColor = that._options.label.customizeColor;
                tick.labelText = formatLabel(tick.value, that._options.label, {
                    min: that._minBound,
                    max: that._maxBound
                });
                tick.labelPos = that._getTranslatedValue(tick.value, position);
                tick.labelStyle = that._textOptions;
                tick.labelFontStyle = _extend({}, that._textFontStyles);
                if (customizeColor && customizeColor.call) {
                    tick.labelFontStyle.fill = customizeColor.call(tick, tick)
                }
                tick.labelHint = constants.formatHint(tick.value, that._options.label, {
                    min: that._minBound,
                    max: that._maxBound
                })
            },
            _getTickStyle: function(tickOptions, gridOptions) {
                return {
                    tickStyle: {
                        stroke: tickOptions.color,
                        "stroke-width": tickOptions.width,
                        "stroke-opacity": tickOptions.opacity
                    },
                    gridStyle: {
                        stroke: gridOptions.color,
                        "stroke-width": gridOptions.width,
                        "stroke-opacity": gridOptions.opacity
                    },
                    length: tickOptions.length
                }
            },
            _initTicks: function(ticks, style, withLabels, skippedCategory, offset, labelPosition) {
                var tick, that = this,
                    i = 0,
                    length = ticks.length,
                    indexSkippedCategory = findSkippedIndexCategory(ticks, skippedCategory);
                for (i; i < length; i++) {
                    tick = ticks[i];
                    i !== indexSkippedCategory && that._initTickCoord(tick, offset);
                    that._initTickStyle(tick, style);
                    withLabels && !tick.withoutLabel && that._initTickLabel(tick, labelPosition)
                }
            },
            _initAllTicks: function() {
                var that = this,
                    options = that._options,
                    majorTickStyle = that._getTickStyle(options.tick, options.grid),
                    minorTickStyle = that._getTickStyle(options.minorTick, options.minorGrid),
                    skippedCategory = that._getSkippedCategory(),
                    boundaryTicks = this._boundaryTicks,
                    withLabels = options.label.visible && that._axisElementsGroup && !that._translator.getBusinessRange().stubData,
                    labelPosition = that.getLabelsParams().pos,
                    offset = that._tickOffset;
                that._initTicks(that._majorTicks, majorTickStyle, withLabels, skippedCategory, offset, labelPosition);
                that._initTicks(that._minorTicks, minorTickStyle, false, void 0, offset);
                that._initTicks(that._decimatedTicks, majorTickStyle, false, skippedCategory, offset);
                if (options.showCustomBoundaryTicks && boundaryTicks.length) {
                    that._initTicks([boundaryTicks[0]], majorTickStyle, false, -1, -1);
                    boundaryTicks.length > 1 && that._initTicks([boundaryTicks[1]], majorTickStyle, false, -1, 1)
                }
            },
            _buildTicks: function() {
                var that = this;
                that._createAllTicks(that._translator.getBusinessRange());
                that._correctLabelAlignment();
                that._correctLabelFormat()
            },
            _setTickOffset: function() {
                var options = this._options,
                    discreteAxisDivisionMode = options.discreteAxisDivisionMode;
                this._tickOffset = +("crossLabels" !== discreteAxisDivisionMode || !discreteAxisDivisionMode)
            },
            _createHints: function() {
                var that = this;
                _each(that._majorTicks || [], function(_, tick) {
                    var labelHint = tick.labelHint;
                    if (_isDefined(labelHint) && "" !== labelHint) {
                        tick.label.setTitle(labelHint)
                    }
                })
            },
            _setBoundingRect: function() {
                var start, that = this,
                    options = that._options,
                    axisBox = that._axisElementsGroup ? that._axisElementsGroup.getBBox() : {
                        x: 0,
                        y: 0,
                        width: 0,
                        height: 0,
                        isEmpty: true
                    },
                    lineBox = that._axisLineGroup.getBBox(),
                    placeholderSize = options.placeholderSize,
                    isHorizontal = that._isHorizontal,
                    coord = isHorizontal ? "y" : "x",
                    side = isHorizontal ? "height" : "width",
                    shiftCoords = options.crosshairEnabled ? isHorizontal ? LABEL_BACKGROUND_PADDING_Y : LABEL_BACKGROUND_PADDING_X : 0,
                    axisTitleBox = that._title && that._axisTitleGroup ? that._axisTitleGroup.getBBox() : axisBox;
                if (axisBox.isEmpty && axisTitleBox.isEmpty && !placeholderSize) {
                    that.boundingRect = axisBox;
                    return
                }
                start = lineBox[coord] || that._axisPosition;
                if (options.position === (isHorizontal && constants.bottom || constants.right)) {
                    axisBox[side] = placeholderSize || axisTitleBox[coord] + axisTitleBox[side] - start + shiftCoords;
                    axisBox[coord] = start
                } else {
                    axisBox[side] = placeholderSize || lineBox[side] + start - axisTitleBox[coord] + shiftCoords;
                    axisBox[coord] = axisTitleBox.isEmpty ? start : axisTitleBox[coord] - shiftCoords
                }
                that.boundingRect = axisBox
            },
            _validateUnit: function(unit, idError, parameters) {
                var that = this;
                unit = that.parser(unit);
                if (void 0 === unit && idError) {
                    that._incidentOccurred(idError, [parameters])
                }
                return unit
            },
            _setType: function(axisType, drawingType) {
                var axisTypeMethods, that = this;
                switch (axisType) {
                    case "xyAxes":
                        axisTypeMethods = __webpack_require__( /*! ./xy_axes */ 513);
                        break;
                    case "polarAxes":
                        axisTypeMethods = __webpack_require__( /*! ./polar_axes */ 514)
                }
                _each(axisTypeMethods[drawingType], function(methodName, method) {
                    that[methodName] = method
                })
            },
            _getSharpParam: function() {
                return true
            },
            dispose: function() {
                var that = this;
                that._axisElementsGroup && that._axisElementsGroup.dispose();
                that._stripLabels = that._strips = null;
                that._title = null;
                that._axisStripGroup = that._axisConstantLineGroup = that._axisLabelGroup = null;
                that._axisLineGroup = that._axisElementsGroup = that._axisGridGroup = null;
                that._axisGroup = that._axisTitleGroup = null;
                that._axesContainerGroup = that._stripsGroup = that._constantLinesGroup = null;
                that._renderer = that._options = that._textOptions = that._textFontStyles = null;
                that._translator = that._additionalTranslator = null;
                that._majorTicks = that._minorTicks = null;
                that._tickManager = null
            },
            getOptions: function() {
                return this._options
            },
            setPane: function(pane) {
                this.pane = pane;
                this._options.pane = pane
            },
            setTypes: function(type, axisType, typeSelector) {
                this._options.type = type || this._options.type;
                this._options[typeSelector] = axisType || this._options[typeSelector]
            },
            resetTypes: function(typeSelector) {
                this._options.type = this._initTypes.type;
                this._options[typeSelector] = this._initTypes[typeSelector]
            },
            getTranslator: function() {
                return this._translator
            },
            updateOptions: function(options) {
                var that = this,
                    labelOpt = options.label;
                that._options = options;
                options.tick = options.tick || {};
                options.minorTick = options.minorTick || {};
                options.grid = options.grid || {};
                options.minorGrid = options.minorGrid || {};
                options.title = options.title || {};
                options.marker = options.marker || {};
                that._initTypes = {
                    type: options.type,
                    argumentType: options.argumentType,
                    valueType: options.valueType
                };
                validateAxisOptions(options);
                that._setTickOffset();
                that._isHorizontal = options.isHorizontal;
                that.pane = options.pane;
                that.name = options.name;
                that.priority = options.priority;
                that._hasLabelFormat = "" !== labelOpt.format && _isDefined(labelOpt.format);
                that._textOptions = {
                    align: labelOpt.alignment,
                    opacity: labelOpt.opacity
                };
                that._textFontStyles = vizUtils.patchFontOptions(labelOpt.font);
                if (options.type === constants.logarithmic) {
                    if (options.logarithmBaseError) {
                        that._incidentOccurred("E2104");
                        delete options.logarithmBaseError
                    }
                    that.calcInterval = function(value, prevValue) {
                        return vizUtils.getLog(value / prevValue, options.logarithmBase)
                    }
                }
            },
            updateSize: function(clearAxis) {
                var that = this,
                    options = that._options,
                    direction = that._isHorizontal ? "horizontal" : "vertical";
                if (options.title.text && that._axisTitleGroup) {
                    that._incidentOccurred("W2105", [direction]);
                    that._axisTitleGroup.dispose();
                    that._axisTitleGroup = null
                }
                if (clearAxis && that._axisElementsGroup && options.label.visible && !that._translator.getBusinessRange().stubData) {
                    that._incidentOccurred("W2106", [direction]);
                    that._axisElementsGroup.dispose();
                    that._axisElementsGroup = null
                }
                that._setBoundingRect()
            },
            setTranslator: function(translator, additionalTranslator) {
                var that = this,
                    range = translator.getBusinessRange();
                this._minBound = range.minVisible;
                this._maxBound = range.maxVisible;
                that._translator = translator;
                that._additionalTranslator = additionalTranslator;
                that.resetTicks();
                that._updateIntervalAndBounds();
                that._buildTicks()
            },
            resetTicks: function() {
                this._deleteLabels();
                this._majorTicks = this._minorTicks = null
            },
            getLabelsParams: function() {
                var that = this,
                    options = that._options,
                    position = options.position,
                    labelOffset = options.label.indentFromAxis,
                    axisPosition = that._axisPosition,
                    axisElementsGroup = that._axisElementsGroup;
                return {
                    pos: position === constants.top || position === constants.left ? axisPosition - labelOffset : axisPosition + labelOffset,
                    width: axisElementsGroup && axisElementsGroup.getBBox().width || 0
                }
            },
            getFormattedValue: function(value, options, point) {
                var labelOptions = this._options.label;
                return _isDefined(value) ? formatLabel(value, _extend(true, {}, labelOptions, options), void 0, point) : null
            },
            getTicksValues: function() {
                return {
                    majorTicksValues: convertTicksToValues(this._majorTicks || this.getMajorTicks()),
                    minorTicksValues: convertTicksToValues(this._minorTicks || this.getMinorTicks())
                }
            },
            getMajorTicks: function(withoutOverlappingBehavior) {
                var majorTicks, boundedOverlappedTicks, that = this,
                    overlappingBehavior = that._options.label.overlappingBehavior;
                that._updateTickManager();
                that._textOptions.rotate = 0;
                majorTicks = convertValuesToTicks(that._tickManager.getTicks(withoutOverlappingBehavior));
                if (majorTicks.length) {
                    if (overlappingBehavior.hideFirstTick || overlappingBehavior.hideLastTick || overlappingBehavior.hideFirstLabel || overlappingBehavior.hideLastLabel) {
                        overlappingBehavior.hideFirstLabel && (majorTicks[0].withoutLabel = true);
                        overlappingBehavior.hideLastLabel && (majorTicks[majorTicks.length - 1].withoutLabel = true);
                        overlappingBehavior.hideFirstTick && (majorTicks[0].withoutPath = true);
                        overlappingBehavior.hideLastTick && (majorTicks[majorTicks.length - 1].withoutPath = true)
                    } else {
                        if (!withoutOverlappingBehavior && "ignore" !== overlappingBehavior.mode) {
                            boundedOverlappedTicks = that._tickManager.checkBoundedTicksOverlapping();
                            boundedOverlappedTicks.overlappedDates && (majorTicks[1].withoutLabel = true);
                            if (boundedOverlappedTicks.overlappedStartEnd) {
                                "first" === overlappingBehavior.hideFirstOrLast ? majorTicks[0].withoutLabel = true : majorTicks[majorTicks.length - 1].withoutLabel = true
                            }
                        }
                    }
                }
                that._addBoundaryTick(majorTicks);
                return majorTicks
            },
            getMinorTicks: function() {
                return convertValuesToTicks(this._tickManager.getMinorTicks())
            },
            getDecimatedTicks: function() {
                return convertValuesToTicks(this._tickManager.getDecimatedTicks())
            },
            setTicks: function(ticks) {
                this.resetTicks();
                this._majorTicks = convertValuesToTicks(ticks.majorTicks);
                this._minorTicks = convertValuesToTicks(ticks.minorTicks)
            },
            setPercentLabelFormat: function() {
                if (!this._hasLabelFormat) {
                    this._options.label.format = "percent"
                }
            },
            resetAutoLabelFormat: function() {
                if (!this._hasLabelFormat) {
                    delete this._options.label.format
                }
            },
            getMultipleAxesSpacing: function() {
                return this._options.multipleAxesSpacing || 0
            },
            drawGrids: function(borderOptions) {
                var that = this,
                    options = that._options;
                borderOptions = borderOptions || {};
                that._axisGridGroup.append(that._gridContainerGroup);
                if (options.grid.visible) {
                    that._drawGrids(that._majorTicks.concat(that._decimatedTicks), borderOptions)
                }
                options.minorGrid.visible && that._drawGrids(that._minorTicks, borderOptions)
            },
            draw: function(adjustAxis) {
                var areLabelsVisible, that = this,
                    options = that._options;
                that._axisGroup && that._clearAxisGroups(adjustAxis);
                areLabelsVisible = options.label.visible && that._axisElementsGroup && !that._translator.getBusinessRange().stubData;
                that._updateIntervalAndBounds();
                that._buildTicks();
                that._initAxisPositions();
                that._initAllTicks();
                options.visible && that._drawAxis();
                if (options.tick.visible) {
                    that._drawTicks(that._majorTicks);
                    that._drawTicks(that._decimatedTicks)
                }
                options.minorTick.visible && that._drawTicks(that._minorTicks);
                areLabelsVisible && that._drawLabels();
                options.showCustomBoundaryTicks && this._drawTicks(that._boundaryTicks);
                that._drawTitle();
                options.strips && that._drawStrip();
                options.constantLines && that._drawConstantLine();
                that._stripsGroup && that._axisStripGroup.append(that._stripsGroup);
                that._constantLinesGroup && that._axisConstantLineGroup.append(that._constantLinesGroup);
                that._axisGroup.append(that._axesContainerGroup);
                that._labelAxesGroup && that._axisLabelGroup.append(that._labelAxesGroup);
                that._adjustConstantLineLabels();
                areLabelsVisible && that._adjustLabels();
                options.marker.visible && that._drawDateMarkers();
                that._createHints();
                that._adjustStripLabels();
                that._adjustTitle();
                that._setBoundingRect()
            },
            getBoundingRect: function() {
                return this._axisElementsGroup ? this.boundingRect : {
                    x: 0,
                    y: 0,
                    width: 0,
                    height: 0
                }
            },
            shift: function(x, y) {
                this._axisGroup.attr({
                    translateX: x,
                    translateY: y
                })
            },
            applyClipRects: function(elementsClipID, canvasClipID) {
                this._axisGroup.attr({
                    clipId: canvasClipID
                });
                this._axisStripGroup.attr({
                    clipId: elementsClipID
                })
            },
            validate: function(isArgumentAxis) {
                var that = this,
                    options = that._options,
                    dataType = isArgumentAxis ? options.argumentType : options.valueType,
                    parser = dataType ? parseUtils.getParser(dataType) : function(unit) {
                        return unit
                    };
                that.parser = parser;
                options.dataType = dataType;
                if (void 0 !== options.min) {
                    options.min = that._validateUnit(options.min, "E2106")
                }
                if (void 0 !== options.max) {
                    options.max = that._validateUnit(options.max, "E2106")
                }
                if (void 0 !== that._minBound) {
                    that._minBound = that._validateUnit(that._minBound)
                }
                if (void 0 !== that._maxBound) {
                    that._maxBound = that._validateUnit(that._maxBound)
                }
            },
            zoom: function(min, max, skipAdjusting) {
                var that = this,
                    minOpt = that._options.min,
                    maxOpt = that._options.max;
                skipAdjusting = skipAdjusting || that._options.type === constants.discrete;
                min = that._validateUnit(min);
                max = that._validateUnit(max);
                if (!skipAdjusting) {
                    if (void 0 !== minOpt) {
                        min = minOpt > min ? minOpt : min;
                        max = minOpt > max ? minOpt : max
                    }
                    if (void 0 !== maxOpt) {
                        max = maxOpt < max ? maxOpt : max;
                        min = maxOpt < min ? maxOpt : min
                    }
                }
                that._zoomArgs = {
                    min: min,
                    max: max
                };
                return that._zoomArgs
            },
            resetZoom: function() {
                this._zoomArgs = null
            },
            getRangeData: function() {
                var rangeMin, rangeMax, rangeMinVisible, rangeMaxVisible, that = this,
                    options = that._options,
                    minMax = that._getMinMax(),
                    min = minMax.min,
                    max = minMax.max,
                    zoomArgs = that._zoomArgs || {},
                    type = options.type;
                if (type === constants.logarithmic) {
                    min = min <= 0 ? void 0 : min;
                    max = max <= 0 ? void 0 : max
                }
                if (type !== constants.discrete) {
                    rangeMin = min;
                    rangeMax = max;
                    if (_isDefined(min) && _isDefined(max)) {
                        rangeMin = min < max ? min : max;
                        rangeMax = max > min ? max : min
                    }
                    rangeMinVisible = _isDefined(zoomArgs.min) ? zoomArgs.min : rangeMin;
                    rangeMaxVisible = _isDefined(zoomArgs.max) ? zoomArgs.max : rangeMax
                } else {
                    rangeMinVisible = _isDefined(zoomArgs.min) ? zoomArgs.min : min;
                    rangeMaxVisible = _isDefined(zoomArgs.max) ? zoomArgs.max : max
                }
                return {
                    min: rangeMin,
                    max: rangeMax,
                    stick: that._getStick(),
                    categories: options.categories,
                    dataType: options.dataType,
                    axisType: type,
                    base: options.logarithmBase,
                    invert: options.inverted,
                    addSpiderCategory: that._getSpiderCategoryOption(),
                    minVisible: rangeMinVisible,
                    maxVisible: rangeMaxVisible
                }
            },
            getFullTicks: function() {
                return this._tickManager.getFullTicks()
            },
            _addBoundaryTick: _noop,
            getMarkerTrackers: _noop,
            measureLabels: _noop,
            _drawDateMarkers: _noop,
            coordsIn: _noop,
            _getSkippedCategory: _noop,
            _initAxisPositions: _noop,
            _drawTitle: _noop,
            _adjustConstantLineLabels: _noop,
            _adjustTitle: _noop,
            getSpiderTicks: _noop,
            setSpiderTicks: _noop,
            _getTickCoord: _noop
        }
    },
    /*!********************************************!*\
      !*** ./Scripts/viz/axes/axes_constants.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _map = __webpack_require__( /*! ../core/utils */ 442).map,
            _format = __webpack_require__( /*! ../core/format */ 465);

        function getFormatObject(value, options, axisMinMax, point) {
            var formatObject = {
                value: value,
                valueText: _format(value, options) || ""
            };
            if (axisMinMax) {
                formatObject.min = axisMinMax.min;
                formatObject.max = axisMinMax.max
            }
            if (point) {
                formatObject.point = point
            }
            return formatObject
        }
        module.exports = {
            logarithmic: "logarithmic",
            discrete: "discrete",
            numeric: "numeric",
            left: "left",
            right: "right",
            top: "top",
            bottom: "bottom",
            center: "center",
            canvasPositionPrefix: "canvas_position_",
            canvasPositionTop: "canvas_position_top",
            canvasPositionBottom: "canvas_position_bottom",
            canvasPositionLeft: "canvas_position_left",
            canvasPositionRight: "canvas_position_right",
            canvasPositionStart: "canvas_position_start",
            canvasPositionEnd: "canvas_position_end",
            horizontal: "horizontal",
            vertical: "vertical",
            convertTicksToValues: function(ticks) {
                return _map(ticks || [], function(item) {
                    return item.value
                })
            },
            convertValuesToTicks: function(values) {
                return _map(values || [], function(item) {
                    return {
                        value: item
                    }
                })
            },
            validateOverlappingMode: function(mode) {
                return "ignore" !== mode ? "enlargeTickInterval" : "ignore"
            },
            formatLabel: function(value, options, axisMinMax, point) {
                var formatObject = getFormatObject(value, options, axisMinMax, point);
                return $.isFunction(options.customizeText) ? options.customizeText.call(formatObject, formatObject) : formatObject.valueText
            },
            formatHint: function(value, options, axisMinMax) {
                var formatObject = getFormatObject(value, options, axisMinMax);
                return $.isFunction(options.customizeHint) ? options.customizeHint.call(formatObject, formatObject) : void 0
            }
        }
    },
    /*!***********************************************!*\
      !*** ./Scripts/viz/axes/base_tick_manager.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var TickManager, $ = __webpack_require__( /*! jquery */ 9),
            coreTickManager = __webpack_require__( /*! ./numeric_tick_manager */ 509),
            dateTimeManager = __webpack_require__( /*! ./datetime_tick_manager */ 510),
            overlappingMethods = __webpack_require__( /*! ./tick_overlapping_manager */ 511),
            logarithmicMethods = __webpack_require__( /*! ./logarithmic_tick_manager */ 512),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            formatHelper = __webpack_require__( /*! ../../format_helper */ 55),
            _isDefined = commonUtils.isDefined,
            _isNumber = commonUtils.isNumber,
            _addInterval = dateUtils.addInterval,
            utils = __webpack_require__( /*! ../core/utils */ 442),
            _adjustValue = utils.adjustValue,
            _map = utils.map,
            _each = $.each,
            _inArray = $.inArray,
            _noop = $.noop,
            DEFAULT_GRID_SPACING_FACTOR = 30,
            DEFAULT_MINOR_GRID_SPACING_FACTOR = 15,
            DEFAULT_NUMBER_MULTIPLIERS = [1, 2, 3, 5],
            TICKS_COUNT_LIMIT = 2e3,
            MIN_ARRANGEMENT_TICKS_COUNT = 2;

        function getUniqueValues(array) {
            var currentValue, lastValue = array[0],
                result = [lastValue.obj],
                length = array.length,
                i = 1;
            for (i; i < length; i++) {
                currentValue = array[i];
                if (lastValue.value !== currentValue.value) {
                    result.push(currentValue.obj);
                    lastValue = currentValue
                }
            }
            return result
        }

        function concatAndSort(array1, array2) {
            if (!array1.length && !array2.length) {
                return []
            }
            var array = array1.concat(array2),
                values = [],
                length = array.length,
                hasNull = false,
                i = 0;
            for (i; i < length; i++) {
                if (null !== array[i]) {
                    values.push({
                        obj: array[i],
                        value: array[i].valueOf()
                    })
                } else {
                    hasNull = true
                }
            }
            values.sort(function(x, y) {
                return x.value - y.value
            });
            values = getUniqueValues(values);
            hasNull && values.push(null);
            return values
        }
        exports.discrete = $.extend({}, coreTickManager.continuous, {
            _calculateMinorTicks: _noop,
            _findTickInterval: _noop,
            _createTicks: function() {
                return []
            },
            _getMarginValue: _noop,
            _generateBounds: _noop,
            _correctMin: _noop,
            _correctMax: _noop,
            _findBusinessDelta: _noop,
            _addBoundedTicks: _noop,
            getFullTicks: function() {
                return this._customTicks
            },
            getMinorTicks: function() {
                return this._decimatedTicks || []
            },
            _findTickIntervalForCustomTicks: function() {
                return 1
            }
        });
        TickManager = exports.TickManager = function(types, data, options) {
            options = options || {};
            this.update(types || {}, data || {}, options);
            this._initOverlappingMethods(options.overlappingBehaviorType)
        };
        TickManager.prototype = {
            constructor: TickManager,
            dispose: function() {
                this._ticks = null;
                this._minorTicks = null;
                this._decimatedTicks = null;
                this._boundaryTicks = null;
                this._options = null
            },
            update: function(types, data, options) {
                this._updateOptions(options || {});
                this._min = data.min;
                this._updateTypes(types || {});
                this._updateData(data || {})
            },
            _updateMinMax: function(data) {
                var min = data.min || 0,
                    max = data.max || 0,
                    newMinMax = this._applyMinMaxMargins(min, max);
                this._min = this._originalMin = newMinMax.min;
                this._max = this._originalMax = newMinMax.max;
                this._updateBusinessDelta()
            },
            _updateBusinessDelta: function() {
                this._businessDelta = this._findBusinessDelta && this._findBusinessDelta(this._min, this._max)
            },
            _updateTypes: function(types) {
                var that = this,
                    axisType = that._validateAxisType(types.axisType),
                    dataType = that._validateDataType(types.dataType);
                that._resetMethods();
                this._axisType = axisType;
                this._dataType = dataType;
                this._initMethods()
            },
            _updateData: function(data) {
                data = $.extend({}, data);
                data.min = _isDefined(data.min) ? data.min : this._originalMin;
                data.max = _isDefined(data.max) ? data.max : this._originalMax;
                this._updateMinMax(data);
                this._customTicks = data.customTicks && data.customTicks.slice();
                this._customMinorTicks = data.customMinorTicks;
                this._customBoundTicks = data.customBoundTicks;
                this._screenDelta = data.screenDelta || 0
            },
            _updateOptions: function(options) {
                var opt;
                this._options = opt = options;
                this._useAutoArrangement = !!this._options.useTicksAutoArrangement;
                opt.gridSpacingFactor = opt.gridSpacingFactor || DEFAULT_GRID_SPACING_FACTOR;
                opt.minorGridSpacingFactor = opt.minorGridSpacingFactor || DEFAULT_MINOR_GRID_SPACING_FACTOR;
                opt.numberMultipliers = opt.numberMultipliers || DEFAULT_NUMBER_MULTIPLIERS
            },
            getTickBounds: function() {
                return {
                    minVisible: this._minBound,
                    maxVisible: this._maxBound
                }
            },
            getTicks: function(withoutOverlappingBehavior) {
                var that = this,
                    options = that._options;
                that._ticks = that._calculateMajorTicks();
                that._checkLabelFormat();
                that._decimatedTicks = [];
                that._applyAutoArrangement();
                !withoutOverlappingBehavior && that._applyOverlappingBehavior();
                that._generateBounds();
                if (options.showMinorTicks) {
                    that._minorTicks = that._calculateMinorTicks()
                }
                that._addBoundedTicks();
                return that._ticks
            },
            getMinorTicks: function() {
                var that = this,
                    decimatedTicks = that.getDecimatedTicks(),
                    options = that._options || {},
                    hasDecimatedTicks = decimatedTicks.length,
                    hasMinorTickOptions = _isDefined(options.minorTickInterval) || _isDefined(options.minorTickCount),
                    hasCustomMinorTicks = that._customMinorTicks && that._customMinorTicks.length,
                    hasMinorTicks = options.showMinorTicks && (hasMinorTickOptions || hasCustomMinorTicks),
                    ticks = hasDecimatedTicks && !hasMinorTicks ? decimatedTicks : that._minorTicks || [];
                return concatAndSort(ticks, [])
            },
            getDecimatedTicks: function() {
                return this._decimatedTicks || []
            },
            getFullTicks: function() {
                var that = this,
                    needCalculateMinorTicks = that._ticks && !that._minorTicks,
                    minorTicks = needCalculateMinorTicks ? that._calculateMinorTicks() : that._minorTicks || [];
                return concatAndSort(that._ticks || [], minorTicks.concat(that.getBoundaryTicks()))
            },
            getBoundaryTicks: function() {
                return this._boundaryTicks || []
            },
            getTickInterval: function() {
                return this._tickInterval
            },
            getMinorTickInterval: function() {
                return this._minorTickInterval
            },
            getOverlappingBehavior: function() {
                return this._options.overlappingBehavior
            },
            getOptions: function() {
                return this._options
            },
            _calculateMajorTicks: function() {
                var ticks, that = this;
                if (that._options.showCalculatedTicks || !that._customTicks) {
                    ticks = that._createTicks(that._options.showCalculatedTicks ? that._customTicks || [] : [], that._findTickInterval(), that._min, that._max)
                } else {
                    ticks = that._customTicks.slice();
                    that._tickInterval = ticks.length > 1 ? that._findTickIntervalForCustomTicks() : 0
                }
                return ticks
            },
            _applyMargin: function(margin, min, max, isNegative) {
                var coef, value = min;
                if (isFinite(margin)) {
                    coef = this._getMarginValue(min, max, margin);
                    if (coef) {
                        value = this._getNextTickValue(min, coef, isNegative, false)
                    }
                }
                return value
            },
            _applyMinMaxMargins: function(min, max) {
                var options = this._options,
                    newMin = min > max ? max : min,
                    newMax = max > min ? max : min;
                this._minCorrectionEnabled = this._getCorrectionEnabled(min, "min");
                this._maxCorrectionEnabled = this._getCorrectionEnabled(max, "max");
                if (options && !options.stick) {
                    newMin = this._applyMargin(options.minValueMargin, min, max, true);
                    newMax = this._applyMargin(options.maxValueMargin, max, min, false)
                }
                return {
                    min: newMin,
                    max: newMax
                }
            },
            _checkBoundedTickInArray: function(value, array) {
                var arrayValues = _map(array || [], function(item) {
                        return item.valueOf()
                    }),
                    minorTicksIndex = _inArray(value.valueOf(), arrayValues);
                if (minorTicksIndex !== -1) {
                    array.splice(minorTicksIndex, 1)
                }
            },
            _checkLabelFormat: function() {
                var options = this._options;
                if ("datetime" === this._dataType && !options.hasLabelFormat && this._ticks.length) {
                    options.labelOptions.format = options.isMarkersVisible ? dateUtils.getDateFormatByTickInterval(this._tickInterval) : formatHelper.getDateFormatByTicks(this._ticks)
                }
            },
            _generateBounds: function() {
                var that = this,
                    interval = that._getBoundInterval(),
                    stick = that._options.stick,
                    minStickValue = that._options.minStickValue,
                    maxStickValue = that._options.maxStickValue,
                    minBound = that._minCorrectionEnabled && !stick ? that._getNextTickValue(that._min, interval, true) : that._originalMin,
                    maxBound = that._maxCorrectionEnabled && !stick ? that._getNextTickValue(that._max, interval) : that._originalMax;
                that._minBound = minBound < minStickValue ? minStickValue : minBound;
                that._maxBound = maxBound > maxStickValue ? maxStickValue : maxBound
            },
            _initOverlappingMethods: function(type) {
                this._initMethods(overlappingMethods[type || "linear"])
            },
            _addBoundedTicks: function() {
                var that = this,
                    tickValues = _map(that._ticks, function(tick) {
                        return tick.valueOf()
                    }),
                    customBounds = that._customBoundTicks,
                    min = that._originalMin,
                    max = that._originalMax,
                    addMinMax = that._options.addMinMax || {};

                function processTick(tick) {
                    that._boundaryTicks.push(tick);
                    that._checkBoundedTickInArray(tick, that._minorTicks);
                    that._checkBoundedTickInArray(tick, that._decimatedTicks)
                }
                that._boundaryTicks = [];
                if (customBounds) {
                    if (addMinMax.min && _isDefined(customBounds[0])) {
                        processTick(customBounds[0])
                    }
                    if (addMinMax.max && _isDefined(customBounds[1])) {
                        processTick(customBounds[1])
                    }
                } else {
                    if (addMinMax.min && _inArray(min.valueOf(), tickValues) === -1) {
                        processTick(min)
                    }
                    if (addMinMax.max && _inArray(max.valueOf(), tickValues) === -1) {
                        processTick(max)
                    }
                }
            },
            _getCorrectionEnabled: function(value, marginSelector) {
                var options = this._options || {},
                    hasPercentStick = options.percentStick && 1 === Math.abs(value),
                    hasValueMargin = options[marginSelector + "ValueMargin"];
                return !hasPercentStick && !hasValueMargin
            },
            _validateAxisType: function(type) {
                var defaultType = "continuous",
                    allowedTypes = {
                        continuous: true,
                        discrete: true,
                        logarithmic: true
                    };
                return allowedTypes[type] ? type : defaultType
            },
            _validateDataType: function(type) {
                var allowedTypes = {
                    numeric: true,
                    datetime: true,
                    string: true
                };
                if (!allowedTypes[type]) {
                    type = _isDefined(this._min) ? this._getDataType(this._min) : "numeric"
                }
                return type
            },
            _getDataType: function(value) {
                return commonUtils.isDate(value) ? "datetime" : "numeric"
            },
            _getMethods: function() {
                var methods;
                if ("continuous" === this._axisType) {
                    methods = "datetime" === this._dataType ? dateTimeManager.datetime : coreTickManager.continuous
                } else {
                    switch (this._axisType) {
                        case "discrete":
                            methods = exports.discrete;
                            break;
                        case "logarithmic":
                            methods = logarithmicMethods.logarithmic;
                            break;
                        default:
                            methods = coreTickManager.continuous
                    }
                }
                return methods
            },
            _resetMethods: function() {
                var that = this,
                    methods = that._getMethods();
                _each(methods, function(name) {
                    if (that[name]) {
                        delete that[name]
                    }
                })
            },
            _initMethods: function(methods) {
                var that = this;
                methods = methods || that._getMethods();
                _each(methods, function(name, func) {
                    that[name] = func
                })
            },
            _getDeltaCoef: function(screenDelta, businessDelta, gridSpacingFactor) {
                var count;
                gridSpacingFactor = gridSpacingFactor || this._options.gridSpacingFactor;
                screenDelta = screenDelta || this._screenDelta;
                businessDelta = businessDelta || this._businessDelta;
                count = screenDelta / gridSpacingFactor;
                count = count <= 1 ? MIN_ARRANGEMENT_TICKS_COUNT : count;
                return businessDelta / count
            },
            _adjustNumericTickValue: function(value, interval, min) {
                return commonUtils.isExponential(value) ? _adjustValue(value) : utils.applyPrecisionByMinDelta(min, interval, value)
            },
            _isTickIntervalCorrect: function(tickInterval, tickCountLimit, businessDelta) {
                var date;
                businessDelta = businessDelta || this._businessDelta;
                if (!_isNumber(tickInterval)) {
                    date = new Date;
                    tickInterval = _addInterval(date, tickInterval) - date;
                    if (!tickInterval) {
                        return false
                    }
                }
                if (_isNumber(tickInterval)) {
                    if (tickInterval > 0 && businessDelta / tickInterval > tickCountLimit) {
                        if (this._options.incidentOccurred) {
                            this._options.incidentOccurred("W2003")
                        }
                    } else {
                        return true
                    }
                }
                return false
            },
            _correctValue: function(valueTypeSelector, tickInterval, correctionMethod) {
                var that = this,
                    correctionEnabledSelector = "_" + valueTypeSelector + "CorrectionEnabled",
                    spaceCorrectionSelector = valueTypeSelector + "SpaceCorrection",
                    valueSelector = "_" + valueTypeSelector,
                    minStickValue = that._options.minStickValue,
                    maxStickValue = that._options.maxStickValue;
                if (that[correctionEnabledSelector]) {
                    if (that._options[spaceCorrectionSelector]) {
                        that[valueSelector] = that._getNextTickValue(that[valueSelector], tickInterval, "min" === valueTypeSelector)
                    }
                    correctionMethod.call(this, tickInterval)
                }
                if ("min" === valueTypeSelector) {
                    that[valueSelector] = that[valueSelector] < minStickValue ? minStickValue : that[valueSelector]
                }
                if ("max" === valueTypeSelector) {
                    that[valueSelector] = that[valueSelector] > maxStickValue ? maxStickValue : that[valueSelector]
                }
            },
            _findTickInterval: function() {
                var tickInterval, that = this,
                    options = that._options,
                    calculatedTickInterval = that._getInterval(),
                    userTickInterval = that._isTickIntervalValid(options.tickInterval) && that._isTickIntervalCorrect(options.tickInterval, TICKS_COUNT_LIMIT) && options.tickInterval;
                tickInterval = that.checkUserTickInterval(userTickInterval, calculatedTickInterval);
                if (that._isTickIntervalValid(tickInterval)) {
                    that._correctValue("min", tickInterval, that._correctMin);
                    that._correctValue("max", tickInterval, that._correctMax);
                    that._updateBusinessDelta()
                }
                that._tickInterval = tickInterval;
                return tickInterval
            },
            _findMinorTickInterval: function(firstTick, secondTick) {
                var that = this,
                    ticks = that._ticks,
                    intervals = that._options.stick ? ticks.length - 1 : ticks.length;
                if (intervals < 1) {
                    intervals = 1
                }
                that._getMinorInterval(that._screenDelta / intervals, that._findBusinessDelta(firstTick, secondTick, false));
                return that._minorTickInterval
            },
            _createMinorTicks: function(ticks, firstTick, secondTick) {
                var that = this,
                    tickInterval = that._findMinorTickInterval(firstTick, secondTick),
                    isTickIntervalNegative = false,
                    isTickIntervalWithPow = false,
                    needCorrectTick = false,
                    startTick = that._getNextTickValue(firstTick, tickInterval, isTickIntervalNegative, isTickIntervalWithPow, needCorrectTick);
                if (that._isTickIntervalValid(tickInterval)) {
                    ticks = that._createCountedTicks(ticks, tickInterval, startTick, secondTick, that._minorTickCount, isTickIntervalNegative, isTickIntervalWithPow, needCorrectTick)
                }
                return ticks
            },
            _calculateMinorTicks: function() {
                var that = this,
                    options = that._options,
                    minorTicks = [],
                    ticks = that._ticks,
                    ticksLength = ticks.length,
                    hasUnitBeginningTick = that._hasUnitBeginningTickCorrection(),
                    i = hasUnitBeginningTick ? 1 : 0;
                if (options.showMinorCalculatedTicks || !that._customMinorTicks) {
                    if (ticks.length) {
                        minorTicks = that._getBoundedMinorTicks(minorTicks, that._minBound, ticks[0], true);
                        if (hasUnitBeginningTick) {
                            minorTicks = that._getUnitBeginningMinorTicks(minorTicks)
                        }
                        for (i; i < ticksLength - 1; i++) {
                            minorTicks = that._createMinorTicks(minorTicks, ticks[i], ticks[i + 1])
                        }
                        minorTicks = that._getBoundedMinorTicks(minorTicks, that._maxBound, ticks[ticksLength - 1])
                    } else {
                        minorTicks = that._createMinorTicks(minorTicks, that._minBound, that._maxBound)
                    }
                    options.showMinorCalculatedTicks && (minorTicks = minorTicks.concat(that._customMinorTicks || []))
                } else {
                    minorTicks = that._customMinorTicks
                }
                return minorTicks
            },
            _createCountedTicks: function(ticks, tickInterval, min, max, count, isTickIntervalWithPow, needMax) {
                var i, value = min;
                for (i = 0; i < count; i++) {
                    if (!(false === needMax && value.valueOf() === max.valueOf())) {
                        ticks.push(value)
                    }
                    value = this._getNextTickValue(value, tickInterval, false, isTickIntervalWithPow, false)
                }
                return ticks
            },
            _createTicks: function(ticks, tickInterval, min, max, isTickIntervalNegative, isTickIntervalWithPow, withCorrection) {
                var leftBound, rightBound, boundedRule, that = this,
                    value = min,
                    newValue = min;
                if (that._isTickIntervalValid(tickInterval)) {
                    boundedRule = min - max < 0;
                    do {
                        value = newValue;
                        if (that._options.stick) {
                            if (value >= that._originalMin && value <= that._originalMax) {
                                ticks.push(value)
                            }
                        } else {
                            ticks.push(value)
                        }
                        newValue = that._getNextTickValue(value, tickInterval, isTickIntervalNegative, isTickIntervalWithPow, withCorrection);
                        if (value.valueOf() === newValue.valueOf()) {
                            break
                        }
                        leftBound = newValue - min >= 0;
                        rightBound = max - newValue >= 0
                    } while (boundedRule === leftBound && boundedRule === rightBound)
                } else {
                    ticks.push(value)
                }
                return ticks
            },
            _getBoundedMinorTicks: function(minorTicks, boundedTick, tick, isNegative) {
                var startTick, endTick, that = this,
                    needCorrectTick = false,
                    nextTick = that._tickInterval ? this._getNextTickValue(tick, that._tickInterval, isNegative, true, needCorrectTick) : boundedTick,
                    tickInterval = that._findMinorTickInterval(tick, nextTick),
                    isTickIntervalCorrect = that._isTickIntervalCorrect(tickInterval, TICKS_COUNT_LIMIT, that._findBusinessDelta(tick, boundedTick, false)),
                    boundedTickValue = boundedTick.valueOf();
                if (isTickIntervalCorrect && that._isTickIntervalValid(tickInterval) && that._minorTickCount > 0) {
                    if (isNegative) {
                        if (tick.valueOf() <= boundedTickValue) {
                            return minorTicks
                        }
                        while (nextTick.valueOf() < boundedTickValue) {
                            nextTick = this._getNextTickValue(nextTick, tickInterval, false, false, needCorrectTick)
                        }
                        startTick = nextTick;
                        endTick = that._getNextTickValue(tick, tickInterval, true, false, false)
                    } else {
                        startTick = that._getNextTickValue(tick, tickInterval, false, false, false);
                        endTick = boundedTick
                    }
                    minorTicks = that._createTicks(minorTicks, tickInterval, startTick, endTick, false, false, needCorrectTick)
                }
                return minorTicks
            },
            getTypes: function() {
                return {
                    axisType: this._axisType,
                    dataType: this._dataType
                }
            },
            getData: function() {
                return {
                    min: this._min,
                    max: this._max,
                    customTicks: this._customTicks,
                    customMinorTicks: this._customMinorTicks,
                    screenDelta: this._screenDelta
                }
            }
        }
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/axes/numeric_tick_manager.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _adjustValue = vizUtils.adjustValue,
            _math = Math,
            _abs = _math.abs,
            _ceil = _math.ceil,
            _floor = _math.floor,
            _noop = $.noop,
            MINOR_TICKS_COUNT_LIMIT = 200,
            DEFAULT_MINOR_NUMBER_MULTIPLIERS = [2, 4, 5, 8, 10];
        exports.continuous = {
            _hasUnitBeginningTickCorrection: _noop,
            _checkBoundedDatesOverlapping: _noop,
            _correctInterval: function(step) {
                this._tickInterval *= step
            },
            _correctMax: function(tickInterval) {
                this._max = this._adjustNumericTickValue(_ceil(this._max / tickInterval) * tickInterval, tickInterval, this._min)
            },
            _correctMin: function(tickInterval) {
                this._min = this._adjustNumericTickValue(_floor(this._min / tickInterval) * tickInterval, tickInterval, this._min)
            },
            _findBusinessDelta: function(min, max) {
                return _adjustValue(_abs(min - max))
            },
            _findTickIntervalForCustomTicks: function() {
                return _abs(this._customTicks[1] - this._customTicks[0])
            },
            _getBoundInterval: function() {
                var that = this,
                    boundCoef = that._options.boundCoef;
                return _isDefined(boundCoef) && isFinite(boundCoef) ? that._tickInterval * _abs(boundCoef) : that._tickInterval / 2
            },
            _getInterval: function(deltaCoef, numberMultipliers) {
                var factor, newResult, i, interval = deltaCoef || this._getDeltaCoef(this._screenDelta, this._businessDelta, this._options.gridSpacingFactor),
                    multipliers = numberMultipliers || this._options.numberMultipliers,
                    result = 0,
                    hasResult = false;
                if (interval > 1) {
                    for (factor = 1; !hasResult; factor *= 10) {
                        for (i = 0; i < multipliers.length; i++) {
                            result = multipliers[i] * factor;
                            if (interval <= result) {
                                hasResult = true;
                                break
                            }
                        }
                    }
                } else {
                    if (interval > 0) {
                        result = 1;
                        for (factor = .1; !hasResult; factor /= 10) {
                            for (i = multipliers.length - 1; i >= 0; i--) {
                                newResult = multipliers[i] * factor;
                                if (interval > newResult) {
                                    hasResult = true;
                                    break
                                }
                                result = newResult
                            }
                        }
                    }
                }
                return _adjustValue(result)
            },
            _getMarginValue: function(min, max, margin) {
                return vizUtils.applyPrecisionByMinDelta(min, margin, _abs(max - min) * margin)
            },
            _getDefaultMinorInterval: function(screenDelta, businessDelta) {
                var result, deltaCoef = this._getDeltaCoef(screenDelta, businessDelta, this._options.minorGridSpacingFactor),
                    multipliers = DEFAULT_MINOR_NUMBER_MULTIPLIERS,
                    i = multipliers.length - 1;
                for (i; i >= 0; i--) {
                    result = businessDelta / multipliers[i];
                    if (deltaCoef <= result) {
                        return _adjustValue(result)
                    }
                }
                return 0
            },
            _getMinorInterval: function(screenDelta, businessDelta) {
                var interval, intervalsCount, count, that = this,
                    options = that._options,
                    minorTickInterval = options.minorTickInterval,
                    minorTickCount = options.minorTickCount;
                if (isFinite(minorTickInterval) && that._isTickIntervalCorrect(minorTickInterval, MINOR_TICKS_COUNT_LIMIT, businessDelta)) {
                    interval = minorTickInterval;
                    count = interval < businessDelta ? _ceil(businessDelta / interval) - 1 : 0
                } else {
                    if (_isDefined(minorTickCount)) {
                        intervalsCount = _isDefined(minorTickCount) ? minorTickCount + 1 : _floor(screenDelta / options.minorGridSpacingFactor);
                        count = intervalsCount - 1;
                        interval = count > 0 ? businessDelta / intervalsCount : 0
                    } else {
                        interval = that._getDefaultMinorInterval(screenDelta, businessDelta);
                        count = interval < businessDelta ? _floor(businessDelta / interval) - 1 : 0
                    }
                }
                that._minorTickInterval = interval;
                that._minorTickCount = count
            },
            _getNextTickValue: function(value, tickInterval, isTickIntervalNegative) {
                tickInterval = _isDefined(isTickIntervalNegative) && isTickIntervalNegative ? -tickInterval : tickInterval;
                value += tickInterval;
                return this._adjustNumericTickValue(value, tickInterval, this._min)
            },
            _isTickIntervalValid: function(tickInterval) {
                return _isDefined(tickInterval) && isFinite(tickInterval) && 0 !== tickInterval
            }
        }
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/axes/datetime_tick_manager.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            tickManagerContinuous = __webpack_require__( /*! ./numeric_tick_manager */ 509).continuous,
            _isDefined = commonUtils.isDefined,
            _convertDateUnitToMilliseconds = dateUtils.convertDateUnitToMilliseconds,
            _correctDateWithUnitBeginning = dateUtils.correctDateWithUnitBeginning,
            _dateToMilliseconds = dateUtils.dateToMilliseconds,
            _convertMillisecondsToDateUnits = dateUtils.convertMillisecondsToDateUnits,
            _math = Math,
            _abs = _math.abs,
            _ceil = _math.ceil,
            _floor = _math.floor,
            _round = _math.round,
            MINOR_TICKS_COUNT_LIMIT = 50,
            DEFAULT_DATETIME_MULTIPLIERS = {
                millisecond: [1, 2, 5, 10, 25, 100, 250, 300, 500],
                second: [1, 2, 3, 5, 10, 15, 20, 30],
                minute: [1, 2, 3, 5, 10, 15, 20, 30],
                hour: [1, 2, 3, 4, 6, 8, 12],
                day: [1, 2, 3, 5, 7, 10, 14],
                month: [1, 2, 3, 6]
            };

        function correctDate(date, tickInterval, correctionMethod) {
            var interval = _dateToMilliseconds(tickInterval),
                timezoneOffset = 60 * date.getTimezoneOffset() * 1e3;
            return new Date(Math[correctionMethod]((date - 0 - timezoneOffset) / interval) * interval + timezoneOffset)
        }
        exports.datetime = $.extend({}, tickManagerContinuous, {
            _correctInterval: function(step) {
                var tickIntervalInMs = _dateToMilliseconds(this._tickInterval);
                this._tickInterval = _convertMillisecondsToDateUnits(tickIntervalInMs * step)
            },
            _correctMax: function(tickInterval) {
                this._max = correctDate(this._max, tickInterval, "ceil")
            },
            _correctMin: function(tickInterval) {
                this._min = correctDate(this._min, tickInterval, "floor");
                if (this._options.setTicksAtUnitBeginning) {
                    this._min = _correctDateWithUnitBeginning(this._min, tickInterval)
                }
            },
            _findTickIntervalForCustomTicks: function() {
                return _convertMillisecondsToDateUnits(_abs(this._customTicks[1] - this._customTicks[0]))
            },
            _getBoundInterval: function() {
                var that = this,
                    interval = that._tickInterval,
                    intervalInMs = _dateToMilliseconds(interval),
                    boundCoef = that._options.boundCoef,
                    boundIntervalInMs = _isDefined(boundCoef) && isFinite(boundCoef) ? intervalInMs * _abs(boundCoef) : intervalInMs / 2;
                return _convertMillisecondsToDateUnits(boundIntervalInMs)
            },
            _getInterval: function(deltaCoef) {
                var factor, i, key, specificMultipliers, yearsCount, interval = deltaCoef || this._getDeltaCoef(this._screenDelta, this._businessDelta, this._options.gridSpacingFactor),
                    multipliers = this._options.numberMultipliers,
                    result = {};
                if (interval > 0 && interval < 1) {
                    return {
                        milliseconds: 1
                    }
                }
                if (0 === interval) {
                    return 0
                }
                for (key in DEFAULT_DATETIME_MULTIPLIERS) {
                    if (DEFAULT_DATETIME_MULTIPLIERS.hasOwnProperty(key)) {
                        specificMultipliers = DEFAULT_DATETIME_MULTIPLIERS[key];
                        for (i = 0; i < specificMultipliers.length; i++) {
                            if (interval <= _convertDateUnitToMilliseconds(key, specificMultipliers[i])) {
                                result[key + "s"] = specificMultipliers[i];
                                return result
                            }
                        }
                    }
                }
                for (factor = 1;; factor *= 10) {
                    for (i = 0; i < multipliers.length; i++) {
                        yearsCount = factor * multipliers[i];
                        if (interval <= _convertDateUnitToMilliseconds("year", yearsCount)) {
                            return {
                                years: yearsCount
                            }
                        }
                    }
                }
                return 0
            },
            _getMarginValue: function(min, max, margin) {
                return _convertMillisecondsToDateUnits(_round(_abs(max - min) * margin))
            },
            _getMinorInterval: function(screenDelta, businessDelta) {
                var interval, intervalInMs, intervalsCount, count, that = this,
                    options = that._options;
                if (_isDefined(options.minorTickInterval) && that._isTickIntervalCorrect(options.minorTickInterval, MINOR_TICKS_COUNT_LIMIT, businessDelta)) {
                    interval = options.minorTickInterval;
                    intervalInMs = _dateToMilliseconds(interval);
                    count = intervalInMs < businessDelta ? _ceil(businessDelta / intervalInMs) - 1 : 0
                } else {
                    intervalsCount = _isDefined(options.minorTickCount) ? options.minorTickCount + 1 : _floor(screenDelta / options.minorGridSpacingFactor);
                    count = intervalsCount - 1;
                    interval = count > 0 ? _convertMillisecondsToDateUnits(businessDelta / intervalsCount) : 0
                }
                that._minorTickInterval = interval;
                that._minorTickCount = count
            },
            _getNextTickValue: function(value, tickInterval, isTickIntervalNegative, isTickIntervalWithPow, withCorrection) {
                var newValue = dateUtils.addInterval(value, tickInterval, isTickIntervalNegative);
                if (this._options.setTicksAtUnitBeginning && false !== withCorrection) {
                    newValue = _correctDateWithUnitBeginning(newValue, tickInterval, true);
                    this._correctDateWithUnitBeginningCalled = true
                }
                return newValue
            },
            _getUnitBeginningMinorTicks: function(minorTicks) {
                var that = this,
                    ticks = that._ticks,
                    tickInterval = that._findMinorTickInterval(ticks[1], ticks[2]),
                    isTickIntervalNegative = true,
                    isTickIntervalWithPow = false,
                    needCorrectTick = false,
                    startTick = that._getNextTickValue(ticks[1], tickInterval, isTickIntervalNegative, isTickIntervalWithPow, needCorrectTick);
                if (that._isTickIntervalValid(tickInterval)) {
                    minorTicks = that._createTicks(minorTicks, tickInterval, startTick, ticks[0], isTickIntervalNegative, isTickIntervalWithPow, needCorrectTick)
                }
                return minorTicks
            },
            _hasUnitBeginningTickCorrection: function() {
                var ticks = this._ticks;
                if (ticks.length < 3) {
                    return false
                }
                return ticks[1] - ticks[0] !== ticks[2] - ticks[1] && this._options.setTicksAtUnitBeginning && this._options.minorTickCount
            },
            _isTickIntervalValid: function(tickInterval) {
                return _isDefined(tickInterval) && 0 !== _dateToMilliseconds(tickInterval)
            },
            _checkBoundedDatesOverlapping: function() {
                var dates = this._ticks,
                    overlappingBehavior = this.getOverlappingBehavior();
                return dates.length > 2 && "stagger" !== overlappingBehavior.mode && "ignore" !== overlappingBehavior.mode && !this._areDisplayValuesValid(dates[0], dates[1])
            }
        })
    },
    /*!******************************************************!*\
      !*** ./Scripts/viz/axes/tick_overlapping_manager.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            numericTickManager = __webpack_require__( /*! ./numeric_tick_manager */ 509),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _addInterval = __webpack_require__( /*! ../../core/utils/date */ 52).addInterval,
            _isDefined = commonUtils.isDefined,
            _isNumber = commonUtils.isNumber,
            _math = Math,
            _abs = _math.abs,
            _ceil = _math.ceil,
            _floor = _math.floor,
            _atan = _math.atan,
            _max = _math.max,
            _each = $.each,
            _noop = $.noop,
            _isFunction = $.isFunction,
            _extend = $.extend,
            SCREEN_DELTA_KOEF = 4,
            AXIS_STAGGER_OVERLAPPING_KOEF = 2,
            STAGGER = "stagger",
            ROTATE = "rotate",
            MIN_ARRANGEMENT_TICKS_COUNT = 2,
            outOfScreen = {
                x: -1e3,
                y: -1e3
            };

        function nextState(state) {
            switch (state) {
                case "overlap":
                    return STAGGER;
                case STAGGER:
                    return ROTATE;
                default:
                    return "end"
            }
        }

        function defaultGetTextFunc(value) {
            return value.toString()
        }

        function convertDateIntervalToNumeric(interval) {
            if (!_isNumber(interval)) {
                var date = new Date;
                interval = _addInterval(date, interval) - date
            }
            return interval
        }
        exports.base = {
            _applyOverlappingBehavior: function() {
                var that = this,
                    options = that._options,
                    overlappingBehavior = options.overlappingBehavior;
                if ("ignore" !== overlappingBehavior.mode) {
                    that._useAutoArrangement = true;
                    that._correctTicks();
                    if ("_auto" === overlappingBehavior.mode) {
                        that._applyAutoOverlappingBehavior();
                        that._useAutoArrangement = options.overlappingBehavior.isOverlapped
                    }
                    if (that._useAutoArrangement) {
                        if (overlappingBehavior.mode === STAGGER) {
                            that._screenDelta *= AXIS_STAGGER_OVERLAPPING_KOEF
                        }
                        that._applyAutoArrangement()
                    }
                }
            },
            checkBoundedTicksOverlapping: function() {
                return {
                    overlappedDates: this._checkBoundedDatesOverlapping(),
                    overlappedStartEnd: this._checkStartEndOverlapping()
                }
            },
            getMaxLabelParams: function(ticks) {
                var tickWithMaxLength, tickTextWithMaxLength, that = this,
                    getText = that._options.getText || defaultGetTextFunc,
                    maxLength = 0;
                ticks = ticks || that._calculateMajorTicks();
                _each(ticks, function(_, item) {
                    var text = getText(item, that._options.labelOptions),
                        length = _isDefined(text) ? text.length : -1;
                    if (maxLength < length) {
                        maxLength = length;
                        tickWithMaxLength = item;
                        tickTextWithMaxLength = text
                    }
                });
                return maxLength > 0 ? that._getTextElementBbox(tickWithMaxLength, tickTextWithMaxLength) : {
                    width: 0,
                    height: 0,
                    length: 0,
                    y: 0
                }
            },
            _applyAutoArrangement: function() {
                var arrangementStep, maxDisplayValueSize, that = this,
                    options = that._options;
                if (that._useAutoArrangement) {
                    maxDisplayValueSize = that._getTicksSize();
                    arrangementStep = that._getAutoArrangementStep(maxDisplayValueSize);
                    if (arrangementStep > 1) {
                        if (_isDefined(that._tickInterval) || _isDefined(that._customTicks)) {
                            that._ticks = that._getAutoArrangementTicks(arrangementStep)
                        } else {
                            options.gridSpacingFactor = maxDisplayValueSize;
                            that._ticks = that._createTicks([], that._findTickInterval(), that._min, that._max)
                        }
                    }
                }
            },
            _getAutoArrangementTicks: function(step) {
                var i, that = this,
                    ticks = that._ticks,
                    ticksLength = ticks.length,
                    resultTicks = ticks,
                    decimatedTicks = that._decimatedTicks || [];
                if (step > 1) {
                    resultTicks = [];
                    for (i = 0; i < ticksLength; i++) {
                        if (i % step === 0) {
                            resultTicks.push(ticks[i])
                        } else {
                            decimatedTicks.push(ticks[i])
                        }
                    }
                    that._correctInterval(step)
                }
                return resultTicks
            },
            _isOverlappedTicks: function(screenDelta) {
                return this._getAutoArrangementStep(this._getTicksSize(), screenDelta, -1) > 1
            },
            _areDisplayValuesValid: function(value1, value2) {
                var hasHorizontalOverlapping, hasVerticalOverlapping, result, that = this,
                    options = that._options,
                    getText = options.getText || defaultGetTextFunc,
                    rotationAngle = options.overlappingBehavior && _isNumber(options.overlappingBehavior.rotationAngle) ? options.overlappingBehavior.rotationAngle : 0,
                    bBox1 = that._getTextElementBbox(value1, getText(value1, options.labelOptions)),
                    bBox2 = that._getTextElementBbox(value2, getText(value2, options.labelOptions)),
                    horizontalInverted = bBox1.x > bBox2.x,
                    verticalInverted = bBox1.y > bBox2.y;
                if (0 !== rotationAngle) {
                    result = that._getDistanceByAngle(bBox1, rotationAngle) <= _abs(bBox2.x - bBox1.x)
                } else {
                    hasHorizontalOverlapping = !horizontalInverted ? bBox1.x + bBox1.width > bBox2.x : bBox2.x + bBox2.width > bBox1.x;
                    hasVerticalOverlapping = !verticalInverted ? bBox1.y + bBox1.height > bBox2.y : bBox2.y + bBox2.height > bBox1.y;
                    result = !(hasHorizontalOverlapping && hasVerticalOverlapping)
                }
                return result
            },
            checkUserTickInterval: function(userTickInterval, calculatedTickInterval) {
                var tickInterval1, tickInterval2, behavior = this._options.overlappingBehavior;
                if (!behavior || "enlargeTickInterval" !== behavior.mode) {
                    return userTickInterval || calculatedTickInterval
                }
                if (!userTickInterval) {
                    return calculatedTickInterval
                }
                tickInterval1 = convertDateIntervalToNumeric(userTickInterval);
                tickInterval2 = convertDateIntervalToNumeric(calculatedTickInterval);
                if (_isNumber(tickInterval1) && _isNumber(tickInterval2)) {
                    if (tickInterval1 > tickInterval2) {
                        return userTickInterval
                    }
                }
                return calculatedTickInterval
            }
        };
        exports.circular = _extend({}, exports.base, {
            checkUserTickInterval: function(userTickInterval, calculatedTickInterval) {
                return userTickInterval || calculatedTickInterval
            },
            _correctTicks: _noop,
            _applyAutoOverlappingBehavior: function() {
                this._options.overlappingBehavior.isOverlapped = true
            },
            _getTextElementBbox: function(value, text) {
                var bbox, textOptions = _extend({}, this._options.textOptions, {
                        rotate: 0
                    }),
                    delta = _isFunction(this._options.translate) ? this._options.translate(value) : {
                        x: 0,
                        y: 0
                    };
                text = this._options.renderText(text, delta.x, delta.y).css(this._options.textFontStyles).attr(textOptions);
                bbox = text.getBBox();
                text.remove();
                return bbox
            },
            _getTicksSize: function() {
                return this.getMaxLabelParams(this._ticks)
            },
            _checkStartEndOverlapping: function() {
                var ticks = this._ticks,
                    lastTick = ticks[ticks.length - 1];
                return ticks.length > 1 && !this._areDisplayValuesValid(ticks[0], lastTick)
            },
            _getAutoArrangementStep: function(maxDisplayValueSize) {
                var that = this,
                    options = that._options,
                    radius = options.circularRadius,
                    startAngle = options.circularStartAngle,
                    endAngle = options.circularEndAngle,
                    circleDelta = startAngle === endAngle ? 360 : _abs(startAngle - endAngle),
                    businessDelta = that._businessDelta || that._ticks.length,
                    degreesPerTick = that._tickInterval * circleDelta / businessDelta,
                    width = maxDisplayValueSize.width,
                    height = maxDisplayValueSize.height,
                    angle1 = _abs(2 * _atan(height / (2 * radius - width)) * 180 / _math.PI),
                    angle2 = _abs(2 * _atan(width / (2 * radius - height)) * 180 / _math.PI),
                    minAngleForTick = _max(angle1, angle2),
                    step = 1;
                if (degreesPerTick < minAngleForTick) {
                    step = _ceil(minAngleForTick / degreesPerTick)
                }
                return _max(1, step)
            }
        });
        exports.linear = _extend({}, exports.base, {
            _correctTicks: function() {
                var arrangementStep, getIntervalFunc = numericTickManager.continuous._getInterval;
                if (this._testingGetIntervalFunc) {
                    getIntervalFunc = this._testingGetIntervalFunc
                }
                arrangementStep = _ceil(getIntervalFunc.call(this, this._getDeltaCoef(this._screenDelta * SCREEN_DELTA_KOEF, this._ticks.length))) || this._ticks.length;
                this._appliedArrangementStep = arrangementStep;
                this._ticks = this._getAutoArrangementTicks(arrangementStep)
            },
            _getTextElementBbox: function(value, text) {
                var bbox, textOptions = _extend({}, this._options.textOptions, {
                        rotate: 0
                    }),
                    x = 0,
                    y = 0,
                    delta = _isFunction(this._options.translate) ? this._options.translate(value) : 0;
                if (this._options.isHorizontal) {
                    x += delta
                } else {
                    y += delta
                }
                text = this._options.renderText(text, x, y).css(this._options.textFontStyles).attr(textOptions);
                bbox = text.getBBox();
                text.remove();
                return bbox
            },
            _checkStartEndOverlapping: _noop,
            _getAutoArrangementStep: function(maxDisplayValueSize, screenDelta, minArrangementTicksStep) {
                var requiredValuesCount, that = this,
                    options = that._options,
                    textSpacing = options.textSpacing || 0,
                    addedSpacing = options.isHorizontal ? textSpacing : 0;
                screenDelta = screenDelta || that._screenDelta;
                minArrangementTicksStep = _isDefined(minArrangementTicksStep) ? minArrangementTicksStep : 1;
                if (options.getCustomAutoArrangementStep) {
                    return options.getCustomAutoArrangementStep(that._ticks, options)
                }
                if (maxDisplayValueSize > 0) {
                    requiredValuesCount = _floor((screenDelta + textSpacing) / (maxDisplayValueSize + addedSpacing));
                    requiredValuesCount = requiredValuesCount <= minArrangementTicksStep ? MIN_ARRANGEMENT_TICKS_COUNT : requiredValuesCount;
                    return _ceil((options.ticksCount || that._ticks.length) / requiredValuesCount)
                }
                return 1
            },
            _getOptimalRotationAngle: function() {
                var that = this,
                    options = that._options,
                    tick1 = that._ticks[0],
                    tick2 = that._ticks[1],
                    textOptions = that._textOptions,
                    getText = options.getText || defaultGetTextFunc,
                    textFontStyles = options.textFontStyles,
                    svgElement1 = options.renderText(getText(tick1, options.labelOptions), outOfScreen.x + options.translate(tick1, !options.isHorizontal), outOfScreen.y).css(textFontStyles).attr(textOptions),
                    svgElement2 = options.renderText(getText(tick2, options.labelOptions), outOfScreen.x + options.translate(tick2, !options.isHorizontal), outOfScreen.y).css(textFontStyles).attr(textOptions),
                    bBox1 = svgElement1.getBBox(),
                    bBox2 = svgElement2.getBBox(),
                    angle = 180 * _math.asin((bBox1.height + options.textSpacing) / (bBox2.x - bBox1.x)) / Math.PI;
                svgElement1.remove();
                svgElement2.remove();
                return isNaN(angle) ? 90 : _ceil(angle)
            },
            _applyAutoOverlappingBehavior: function() {
                var that = this,
                    overlappingBehavior = that._options.overlappingBehavior,
                    screenDelta = that._screenDelta,
                    isOverlapped = false,
                    rotationAngle = null,
                    mode = null,
                    state = "overlap";
                while ("end" !== state) {
                    isOverlapped = rotationAngle && 90 !== rotationAngle ? false : that._isOverlappedTicks(screenDelta);
                    state = nextState(isOverlapped ? state : null);
                    switch (state) {
                        case STAGGER:
                            screenDelta *= AXIS_STAGGER_OVERLAPPING_KOEF;
                            mode = state;
                            break;
                        case ROTATE:
                            rotationAngle = that._getOptimalRotationAngle();
                            screenDelta = that._screenDelta;
                            mode = state
                    }
                }
                overlappingBehavior.isOverlapped = isOverlapped;
                overlappingBehavior.mode = mode;
                overlappingBehavior.rotationAngle = rotationAngle
            },
            _getDistanceByAngle: function(bBox, rotationAngle) {
                var a = rotationAngle * (_math.PI / 180);
                if (a >= _atan(bBox.height / bBox.width)) {
                    return bBox.height / _abs(_math.sin(a))
                } else {
                    return bBox.width
                }
            },
            _getTicksSize: function() {
                var bBox = this.getMaxLabelParams(this._ticks),
                    options = this._options,
                    rotationAngle = options.overlappingBehavior ? options.overlappingBehavior.rotationAngle : 0,
                    isRotate = _isNumber(rotationAngle) && 0 !== rotationAngle;
                return _ceil(isRotate ? this._getDistanceByAngle(bBox, rotationAngle) : options.isHorizontal ? bBox.width : bBox.height)
            }
        })
    },
    /*!******************************************************!*\
      !*** ./Scripts/viz/axes/logarithmic_tick_manager.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _addInterval = dateUtils.addInterval,
            _adjustValue = vizUtils.adjustValue,
            tickManagerContinuous = __webpack_require__( /*! ./numeric_tick_manager */ 509).continuous,
            _getLog = vizUtils.getLog,
            _raiseTo = vizUtils.raiseTo,
            _math = Math,
            _abs = _math.abs,
            _ceil = _math.ceil,
            _floor = _math.floor,
            _round = _math.round;
        exports.logarithmic = $.extend({}, tickManagerContinuous, {
            _correctMax: function() {
                var base = this._options.base;
                this._max = _adjustValue(_raiseTo(_ceil(_adjustValue(_getLog(this._max, base))), base))
            },
            _correctMin: function() {
                var base = this._options.base;
                this._min = _adjustValue(_raiseTo(_floor(_adjustValue(_getLog(this._min, base))), base))
            },
            _findBusinessDelta: function(min, max, isTickIntervalWithPow) {
                var delta;
                if (min <= 0 || max <= 0) {
                    return 0
                }
                if (false === isTickIntervalWithPow) {
                    delta = tickManagerContinuous._findBusinessDelta(min, max)
                } else {
                    delta = _round(_abs(_getLog(min, this._options.base) - _getLog(max, this._options.base)))
                }
                return delta
            },
            _findTickIntervalForCustomTicks: function() {
                return _adjustValue(_getLog(this._customTicks[1] / this._customTicks[0], this._options.base))
            },
            _getInterval: function(deltaCoef) {
                var factor, i, interval = deltaCoef || this._getDeltaCoef(this._screenDelta, this._businessDelta, this._options.gridSpacingFactor),
                    multipliers = this._options.numberMultipliers,
                    result = 0,
                    hasResult = false;
                if (0 !== interval) {
                    for (factor = 1; !hasResult; factor *= 10) {
                        for (i = 0; i < multipliers.length; i++) {
                            result = multipliers[i] * factor;
                            if (interval <= result) {
                                hasResult = true;
                                break
                            }
                        }
                    }
                }
                return _adjustValue(result)
            },
            _getMinorInterval: function(screenDelta, businessDelta) {
                var that = this,
                    options = that._options,
                    minorTickCount = options.minorTickCount,
                    intervalsCount = _isDefined(minorTickCount) ? minorTickCount + 1 : _floor(screenDelta / options.minorGridSpacingFactor),
                    count = intervalsCount - 1,
                    interval = count > 0 ? businessDelta / intervalsCount : 0;
                that._minorTickInterval = interval;
                that._minorTickCount = count
            },
            _getMarginValue: function() {
                return null
            },
            _getNextTickValue: function(value, tickInterval, isTickIntervalNegative, isTickIntervalWithPow) {
                var pow, nextTickValue, that = this;
                tickInterval = _isDefined(isTickIntervalNegative) && isTickIntervalNegative ? -tickInterval : tickInterval;
                if (false === isTickIntervalWithPow) {
                    nextTickValue = value + tickInterval
                } else {
                    pow = _addInterval(_getLog(value, that._options.base), tickInterval, that._min > that._max);
                    nextTickValue = _adjustValue(_raiseTo(pow, that._options.base))
                }
                return nextTickValue
            }
        })
    },
    /*!*************************************!*\
      !*** ./Scripts/viz/axes/xy_axes.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            formatHelper = __webpack_require__( /*! ../../format_helper */ 55),
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            getNextDateUnit = dateUtils.getNextDateUnit,
            correctDateWithUnitBeginning = dateUtils.correctDateWithUnitBeginning,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _isDefined = commonUtils.isDefined,
            constants = __webpack_require__( /*! ./axes_constants */ 507),
            _extend = $.extend,
            CANVAS_POSITION_PREFIX = constants.canvasPositionPrefix,
            TOP = constants.top,
            BOTTOM = constants.bottom,
            LEFT = constants.left,
            RIGHT = constants.right,
            CENTER = constants.center;

        function prepareDatesDifferences(datesDifferences, tickInterval) {
            var dateUnitInterval, i;
            if ("week" === tickInterval) {
                tickInterval = "day"
            }
            if ("quarter" === tickInterval) {
                tickInterval = "month"
            }
            if (datesDifferences[tickInterval]) {
                for (i = 0; i < dateUtils.dateUnitIntervals.length; i++) {
                    dateUnitInterval = dateUtils.dateUnitIntervals[i];
                    if (datesDifferences[dateUnitInterval]) {
                        datesDifferences[dateUnitInterval] = false;
                        datesDifferences.count--
                    }
                    if (dateUnitInterval === tickInterval) {
                        break
                    }
                }
            }
        }

        function getMarkerDates(min, max, markerInterval) {
            var dates, origMin = min;
            min = correctDateWithUnitBeginning(min, markerInterval);
            max = correctDateWithUnitBeginning(max, markerInterval);
            dates = dateUtils.getSequenceByInterval(min, max, markerInterval);
            if (dates.length && origMin > dates[0]) {
                dates = dates.slice(1)
            }
            return dates
        }

        function getMarkerInterval(tickInterval) {
            var markerInterval = getNextDateUnit(tickInterval);
            if ("quarter" === markerInterval) {
                markerInterval = getNextDateUnit(markerInterval)
            }
            return markerInterval
        }

        function getMarkerFormat(curDate, prevDate, tickInterval, markerInterval) {
            var format = markerInterval,
                datesDifferences = prevDate && dateUtils.getDatesDifferences(prevDate, curDate);
            if (prevDate) {
                prepareDatesDifferences(datesDifferences, tickInterval);
                format = formatHelper.getDateFormatByDifferences(datesDifferences)
            }
            return format
        }
        module.exports = {
            linear: {
                measureLabels: function() {
                    return this._tickManager.getMaxLabelParams()
                },
                getMarkerTrackers: function() {
                    return this._markerTrackers
                },
                _getSharpParam: function(opposite) {
                    return this._isHorizontal ^ opposite ? "h" : "v"
                },
                _createAxisElement: function() {
                    var axisCoord = this._axisPosition,
                        canvas = this._getCanvasStartEnd(),
                        points = this._isHorizontal ? [canvas.start, axisCoord, canvas.end, axisCoord] : [axisCoord, canvas.start, axisCoord, canvas.end];
                    return this._renderer.path(points, "line")
                },
                _getTranslatedCoord: function(value, offset) {
                    return this._translator.translate(value, offset)
                },
                _getCanvasStartEnd: function() {
                    return {
                        start: this._translator.translateSpecialCase(constants.canvasPositionStart),
                        end: this._translator.translateSpecialCase(constants.canvasPositionEnd)
                    }
                },
                _getScreenDelta: function() {
                    return Math.abs(this._translator.translateSpecialCase(constants.canvasPositionStart) - this._translator.translateSpecialCase(constants.canvasPositionEnd))
                },
                _initAxisPositions: function() {
                    var that = this,
                        position = that._options.position,
                        delta = 0;
                    if (that.delta) {
                        delta = that.delta[position] || 0
                    }
                    that._axisPosition = that._additionalTranslator.translateSpecialCase(CANVAS_POSITION_PREFIX + position) + delta
                },
                _getTickCoord: function(tick) {
                    var coords, corrections = {
                            top: -1,
                            middle: -.5,
                            bottom: 0,
                            left: -1,
                            center: -.5,
                            right: 0
                        },
                        tickCorrection = corrections[this._options.tickOrientation || "center"];
                    if (_isDefined(tick.posX) && _isDefined(tick.posY)) {
                        coords = {
                            x1: tick.posX,
                            y1: tick.posY + tickCorrection * tick.length,
                            x2: tick.posX,
                            y2: tick.posY + tickCorrection * tick.length + tick.length
                        }
                    } else {
                        coords = null
                    }
                    return coords
                },
                _drawTitle: function() {
                    var that = this,
                        options = that._options,
                        titleOptions = options.title,
                        attr = {
                            opacity: titleOptions.opacity,
                            align: CENTER
                        };
                    if (!titleOptions.text || !that._axisTitleGroup) {
                        return
                    }
                    that._title = that._renderer.text(titleOptions.text, 0, 0).css(vizUtils.patchFontOptions(titleOptions.font)).attr(attr).append(that._axisTitleGroup)
                },
                _drawDateMarker: function(date, options) {
                    var labelPosX, labelPosY, textElement, text, textSize, textIndent, pathElement, that = this,
                        markerOptions = that._options.marker;
                    if (null === options.x) {
                        return
                    }
                    if (!options.withoutStick) {
                        pathElement = that._renderer.path([options.x, options.y, options.x, options.y + markerOptions.separatorHeight], "line").attr({
                            "stroke-width": markerOptions.width,
                            stroke: markerOptions.color,
                            "stroke-opacity": markerOptions.opacity,
                            sharp: "h"
                        }).append(that._axisElementsGroup)
                    }
                    text = String(constants.formatLabel(date, options.labelFormat));
                    textElement = that._renderer.text(text, 0, 0).attr({
                        align: "left"
                    }).css(vizUtils.patchFontOptions(markerOptions.label.font)).append(that._axisElementsGroup);
                    textSize = textElement.getBBox();
                    textIndent = markerOptions.width + markerOptions.textLeftIndent;
                    labelPosX = this._translator.getBusinessRange().invert ? options.x - textIndent - textSize.width : options.x + textIndent;
                    labelPosY = options.y + markerOptions.textTopIndent + textSize.height / 2;
                    textElement.move(labelPosX, labelPosY);
                    return {
                        labelStartPosX: labelPosX - textIndent,
                        labelEndPosX: labelPosX + textSize.width,
                        date: date,
                        dateMarkerStartPosX: options.x,
                        setTitle: function() {
                            this.title = text
                        },
                        dispose: function(onlyLabel) {
                            if (!onlyLabel && pathElement) {
                                pathElement.dispose();
                                pathElement = null
                            }
                            textElement.dispose();
                            textElement = null
                        }
                    }
                },
                _drawDateMarkers: function() {
                    var tickInterval, markerInterval, markerDates, prevDateMarker, markersAreaTop, dateMarker, curDate, that = this,
                        options = that._options,
                        translator = that._translator,
                        minBound = that._minBound,
                        dateMarkers = [],
                        invert = translator.getBusinessRange().invert,
                        xBound = translator.translateSpecialCase("canvas_position_end"),
                        i = 1;

                    function draw(markerDate, format, withoutStick) {
                        return that._drawDateMarker(markerDate, {
                            x: translator.translate(markerDate),
                            y: markersAreaTop,
                            labelFormat: that._getLabelFormatOptions(format),
                            withoutStick: withoutStick
                        })
                    }
                    if ("datetime" !== options.argumentType || "discrete" === options.type || that._majorTicks.length <= 1) {
                        return
                    }
                    markersAreaTop = that._axisPosition + this._axisElementsGroup.getBBox().height + options.label.indentFromAxis + options.marker.topIndent;
                    tickInterval = dateUtils.getDateUnitInterval(this._tickManager.getTickInterval());
                    markerInterval = getMarkerInterval(tickInterval);
                    markerDates = getMarkerDates(minBound, that._maxBound, markerInterval);
                    if (markerDates.length > 1 || 1 === markerDates.length && minBound < markerDates[0]) {
                        for (i = 0; i < markerDates.length; i++) {
                            curDate = markerDates[i];
                            dateMarker = draw(curDate, getMarkerFormat(curDate, markerDates[i - 1] || minBound < curDate && minBound, tickInterval, markerInterval));
                            if (dateMarker) {
                                if (invert ? dateMarker.labelStartPosX < xBound : dateMarker.labelEndPosX > xBound) {
                                    dateMarkers.push(dateMarker);
                                    dateMarker.dispose(true);
                                    dateMarker.setTitle()
                                } else {
                                    if (that._checkMarkersPosition(dateMarker, prevDateMarker)) {
                                        dateMarkers.push(dateMarker);
                                        prevDateMarker = dateMarker
                                    } else {
                                        dateMarker.dispose()
                                    }
                                }
                            }
                        }
                        if (minBound < markerDates[0]) {
                            dateMarker = draw(minBound, getMarkerFormat(minBound, markerDates[0], tickInterval, markerInterval), true);
                            if (dateMarker) {
                                if (!that._checkMarkersPosition(dateMarker, dateMarkers[0])) {
                                    dateMarker.dispose();
                                    dateMarker.setTitle()
                                }
                                dateMarkers.unshift(dateMarker)
                            }
                        }
                    }
                    that._initializeMarkersTrackers(dateMarkers, that._axisElementsGroup, that._axisGroup.getBBox().width, markersAreaTop)
                },
                _initializeMarkersTrackers: function(dateMarkers, group, axisWidth, markersAreaTop) {
                    var markerTracker, nextMarker, i, x, currentMarker, that = this,
                        separatorHeight = that._options.marker.separatorHeight,
                        renderer = that._renderer,
                        businessRange = this._translator.getBusinessRange();
                    that._markerTrackers = [];
                    for (i = 0; i < dateMarkers.length; i++) {
                        currentMarker = dateMarkers[i];
                        nextMarker = dateMarkers[i + 1] || {
                            dateMarkerStartPosX: businessRange.invert ? this._translator.translateSpecialCase("canvas_position_end") : axisWidth,
                            date: businessRange.max
                        };
                        x = currentMarker.dateMarkerStartPosX;
                        markerTracker = renderer.path([x, markersAreaTop, x, markersAreaTop + separatorHeight, nextMarker.dateMarkerStartPosX, markersAreaTop + separatorHeight, nextMarker.dateMarkerStartPosX, markersAreaTop, x, markersAreaTop]).attr({
                            "stroke-width": 1,
                            stroke: "grey",
                            fill: "grey",
                            "fill-opacity": 1e-4,
                            "stroke-opacity": 1e-4
                        }).append(group);
                        markerTracker.data("range", {
                            startValue: currentMarker.date,
                            endValue: nextMarker.date
                        });
                        if (currentMarker.title) {
                            markerTracker.setTitle(currentMarker.title)
                        }
                        that._markerTrackers.push(markerTracker)
                    }
                },
                _checkMarkersPosition: function(dateMarker, prevDateMarker) {
                    return void 0 === prevDateMarker || dateMarker.labelStartPosX > prevDateMarker.labelEndPosX || dateMarker.labelEndPosX < prevDateMarker.labelStartPosX
                },
                _getLabelFormatOptions: function(formatString) {
                    var that = this,
                        markerLabelOptions = that._markerLabelOptions;
                    if (!markerLabelOptions) {
                        that._markerLabelOptions = markerLabelOptions = _extend(true, {}, that._options.marker.label)
                    }
                    if (!_isDefined(that._options.marker.label.format)) {
                        markerLabelOptions.format = formatString
                    }
                    return markerLabelOptions
                },
                _adjustConstantLineLabels: function() {
                    var label, line, lineBox, linesOptions, labelOptions, box, x, y, i, paddingTopBottom, paddingLeftRight, labelVerticalAlignment, labelHorizontalAlignment, labelIsInside, labelHeight, labelWidth, that = this,
                        options = that._options,
                        isHorizontal = that._isHorizontal,
                        lines = that._constantLines,
                        labels = that._constantLineLabels,
                        padding = isHorizontal ? {
                            top: 0,
                            bottom: 0
                        } : {
                            left: 0,
                            right: 0
                        },
                        delta = 0;
                    if (void 0 === labels && void 0 === lines) {
                        return
                    }
                    for (i = 0; i < labels.length; i++) {
                        x = y = 0;
                        linesOptions = options.constantLines[i];
                        paddingTopBottom = linesOptions.paddingTopBottom;
                        paddingLeftRight = linesOptions.paddingLeftRight;
                        labelOptions = linesOptions.label;
                        labelVerticalAlignment = labelOptions.verticalAlignment;
                        labelHorizontalAlignment = labelOptions.horizontalAlignment;
                        labelIsInside = "inside" === labelOptions.position;
                        label = labels[i];
                        if (null !== label) {
                            line = lines[i];
                            box = label.getBBox();
                            lineBox = line.getBBox();
                            labelHeight = box.height;
                            labelWidth = box.width;
                            if (isHorizontal) {
                                if (labelIsInside) {
                                    if (labelHorizontalAlignment === LEFT) {
                                        x -= paddingLeftRight
                                    } else {
                                        x += paddingLeftRight
                                    }
                                    switch (labelVerticalAlignment) {
                                        case CENTER:
                                            y += lineBox.y + lineBox.height / 2 - box.y - labelHeight / 2;
                                            break;
                                        case BOTTOM:
                                            y += lineBox.y + lineBox.height - box.y - labelHeight - paddingTopBottom;
                                            break;
                                        default:
                                            y += lineBox.y - box.y + paddingTopBottom
                                    }
                                } else {
                                    if (labelVerticalAlignment === BOTTOM) {
                                        delta = that.delta && that.delta[BOTTOM] || 0;
                                        y += paddingTopBottom - box.y + that._additionalTranslator.translateSpecialCase(CANVAS_POSITION_PREFIX + BOTTOM) + delta;
                                        if (padding[BOTTOM] < labelHeight + paddingTopBottom) {
                                            padding[BOTTOM] = labelHeight + paddingTopBottom
                                        }
                                    } else {
                                        delta = that.delta && that.delta[TOP] || 0;
                                        y -= paddingTopBottom + box.y + labelHeight - that._additionalTranslator.translateSpecialCase(CANVAS_POSITION_PREFIX + TOP) - delta;
                                        if (padding[TOP] < paddingTopBottom + labelHeight) {
                                            padding[TOP] = paddingTopBottom + labelHeight
                                        }
                                    }
                                }
                            } else {
                                if (labelIsInside) {
                                    switch (labelHorizontalAlignment) {
                                        case CENTER:
                                            x += lineBox.x + lineBox.width / 2 - box.x - labelWidth / 2;
                                            break;
                                        case RIGHT:
                                            x -= paddingLeftRight;
                                            break;
                                        default:
                                            x += paddingLeftRight
                                    }
                                    if (labelVerticalAlignment === BOTTOM) {
                                        y += lineBox.y - box.y + paddingTopBottom
                                    } else {
                                        y += lineBox.y - box.y - labelHeight - paddingTopBottom
                                    }
                                } else {
                                    y += lineBox.y + lineBox.height / 2 - box.y - labelHeight / 2;
                                    if (labelHorizontalAlignment === RIGHT) {
                                        x += paddingLeftRight;
                                        if (padding[RIGHT] < paddingLeftRight + labelWidth) {
                                            padding[RIGHT] = paddingLeftRight + labelWidth
                                        }
                                    } else {
                                        x -= paddingLeftRight;
                                        if (padding[LEFT] < paddingLeftRight + labelWidth) {
                                            padding[LEFT] = paddingLeftRight + labelWidth
                                        }
                                    }
                                }
                            }
                            label.move(x, y)
                        }
                    }
                    that.padding = padding
                },
                _checkAlignmentConstantLineLabels: function(labelOptions) {
                    var position = labelOptions.position,
                        verticalAlignment = (labelOptions.verticalAlignment || "").toLowerCase(),
                        horizontalAlignment = (labelOptions.horizontalAlignment || "").toLowerCase();
                    if (this._isHorizontal) {
                        if ("outside" === position) {
                            verticalAlignment = verticalAlignment === BOTTOM ? BOTTOM : TOP;
                            horizontalAlignment = CENTER
                        } else {
                            verticalAlignment = verticalAlignment === CENTER ? CENTER : verticalAlignment === BOTTOM ? BOTTOM : TOP;
                            horizontalAlignment = horizontalAlignment === LEFT ? LEFT : RIGHT
                        }
                    } else {
                        if ("outside" === position) {
                            verticalAlignment = CENTER;
                            horizontalAlignment = horizontalAlignment === LEFT ? LEFT : RIGHT
                        } else {
                            verticalAlignment = verticalAlignment === BOTTOM ? BOTTOM : TOP;
                            horizontalAlignment = horizontalAlignment === RIGHT ? RIGHT : horizontalAlignment === CENTER ? CENTER : LEFT
                        }
                    }
                    labelOptions.verticalAlignment = verticalAlignment;
                    labelOptions.horizontalAlignment = horizontalAlignment
                },
                _getConstantLineLabelsCoords: function(value, lineLabelOptions) {
                    var that = this,
                        additionalTranslator = that._additionalTranslator,
                        align = CENTER,
                        x = value,
                        y = value;
                    if (that._isHorizontal) {
                        y = additionalTranslator.translateSpecialCase(CANVAS_POSITION_PREFIX + lineLabelOptions.verticalAlignment)
                    } else {
                        x = additionalTranslator.translateSpecialCase(CANVAS_POSITION_PREFIX + lineLabelOptions.horizontalAlignment)
                    }
                    switch (lineLabelOptions.horizontalAlignment) {
                        case LEFT:
                            align = !that._isHorizontal && "inside" === lineLabelOptions.position ? LEFT : RIGHT;
                            break;
                        case CENTER:
                            align = CENTER;
                            break;
                        case RIGHT:
                            align = !that._isHorizontal && "inside" === lineLabelOptions.position ? RIGHT : LEFT
                    }
                    return {
                        x: x,
                        y: y,
                        align: align
                    }
                },
                _getAdjustedStripLabelCoords: function(stripOptions, label, rect) {
                    var x = 0,
                        y = 0,
                        horizontalAlignment = stripOptions.label.horizontalAlignment,
                        verticalAlignment = stripOptions.label.verticalAlignment,
                        box = label.getBBox(),
                        rectBox = rect.getBBox();
                    if (horizontalAlignment === LEFT) {
                        x += stripOptions.paddingLeftRight
                    } else {
                        if (horizontalAlignment === RIGHT) {
                            x -= stripOptions.paddingLeftRight
                        }
                    }
                    if (verticalAlignment === TOP) {
                        y += rectBox.y - box.y + stripOptions.paddingTopBottom
                    } else {
                        if (verticalAlignment === CENTER) {
                            y += rectBox.y + rectBox.height / 2 - box.y - box.height / 2
                        } else {
                            if (verticalAlignment === BOTTOM) {
                                y -= stripOptions.paddingTopBottom
                            }
                        }
                    }
                    return {
                        x: x,
                        y: y
                    }
                },
                _adjustTitle: function() {
                    var boxGroup, boxTitle, params, heightTitle, noLabels, that = this,
                        options = that._options,
                        position = options.position,
                        title = that._title,
                        margin = options.title.margin,
                        centerPosition = that._translator.translateSpecialCase(CANVAS_POSITION_PREFIX + CENTER),
                        axisElementsGroup = that._axisElementsGroup,
                        axisPosition = that._axisPosition;
                    if (!title || !axisElementsGroup) {
                        return
                    }
                    boxTitle = title.getBBox();
                    boxGroup = axisElementsGroup.getBBox();
                    noLabels = boxGroup.isEmpty;
                    heightTitle = boxTitle.height;
                    if (that._isHorizontal) {
                        if (position === BOTTOM) {
                            params = {
                                y: (noLabels ? axisPosition : boxGroup.y + boxGroup.height) - boxTitle.y + margin,
                                x: centerPosition
                            }
                        } else {
                            params = {
                                y: (noLabels ? axisPosition : boxGroup.y) - heightTitle - boxTitle.y - margin,
                                x: centerPosition
                            }
                        }
                    } else {
                        if (position === LEFT) {
                            params = {
                                x: (noLabels ? axisPosition : boxGroup.x) - heightTitle - boxTitle.y - margin,
                                y: centerPosition
                            }
                        } else {
                            params = {
                                x: (noLabels ? axisPosition : boxGroup.x + boxGroup.width) + heightTitle + boxTitle.y + margin,
                                y: centerPosition
                            }
                        }
                        params.rotate = options.position === LEFT ? 270 : 90
                    }
                    title.attr(params)
                },
                coordsIn: function(x, y) {
                    var rect = this.getBoundingRect();
                    return x >= rect.x && x <= rect.x + rect.width && y >= rect.y && y <= rect.y + rect.height
                },
                _boundaryTicksVisibility: {
                    min: true,
                    max: true
                },
                _getOverlappingBehaviorOptions: function() {
                    var that = this,
                        options = that._options,
                        getText = function() {
                            return ""
                        },
                        overlappingBehavior = options.label.overlappingBehavior ? _extend({}, options.label.overlappingBehavior) : null;
                    if (overlappingBehavior) {
                        if (!that._isHorizontal) {
                            overlappingBehavior.mode = constants.validateOverlappingMode(overlappingBehavior.mode)
                        }
                        if ("rotate" !== overlappingBehavior.mode) {
                            overlappingBehavior.rotationAngle = 0
                        }
                    }
                    if (!that._translator.getBusinessRange().stubData) {
                        getText = function(value, labelOptions) {
                            return constants.formatLabel(value, labelOptions, {
                                min: options.min,
                                max: options.max
                            })
                        }
                    }
                    return {
                        hasLabelFormat: that._hasLabelFormat,
                        labelOptions: options.label,
                        isMarkersVisible: "discrete" === options.type ? false : options.marker.visible,
                        overlappingBehavior: overlappingBehavior,
                        isHorizontal: that._isHorizontal,
                        textOptions: that._textOptions,
                        textFontStyles: that._textFontStyles,
                        textSpacing: options.label.minSpacing,
                        getText: getText,
                        renderText: function(text, x, y, options) {
                            return that._renderer.text(text, x, y, options).append(that._renderer.root)
                        },
                        translate: function(value, useAdditionalTranslator) {
                            return useAdditionalTranslator ? that._additionalTranslator.translate(value) : that._translator.translate(value)
                        },
                        addMinMax: options.showCustomBoundaryTicks ? that._boundaryTicksVisibility : void 0
                    }
                },
                _getMinMax: function() {
                    return {
                        min: this._options.min,
                        max: this._options.max
                    }
                },
                _getStick: function() {
                    return !this._options.valueMarginsEnabled
                },
                _getStripLabelCoords: function(stripLabelOptions, stripFrom, stripTo) {
                    var x, y, that = this,
                        additionalTranslator = that._additionalTranslator,
                        isHorizontal = that._isHorizontal,
                        align = isHorizontal ? CENTER : LEFT;
                    if (isHorizontal) {
                        if (stripLabelOptions.horizontalAlignment === CENTER) {
                            x = stripFrom + (stripTo - stripFrom) / 2;
                            align = CENTER
                        } else {
                            if (stripLabelOptions.horizontalAlignment === LEFT) {
                                x = stripFrom;
                                align = LEFT
                            } else {
                                if (stripLabelOptions.horizontalAlignment === RIGHT) {
                                    x = stripTo;
                                    align = RIGHT
                                }
                            }
                        }
                        y = additionalTranslator.translateSpecialCase(CANVAS_POSITION_PREFIX + stripLabelOptions.verticalAlignment)
                    } else {
                        x = additionalTranslator.translateSpecialCase(CANVAS_POSITION_PREFIX + stripLabelOptions.horizontalAlignment);
                        align = stripLabelOptions.horizontalAlignment;
                        if (stripLabelOptions.verticalAlignment === TOP) {
                            y = stripFrom
                        } else {
                            if (stripLabelOptions.verticalAlignment === CENTER) {
                                y = stripTo + (stripFrom - stripTo) / 2
                            } else {
                                if (stripLabelOptions.verticalAlignment === BOTTOM) {
                                    y = stripTo
                                }
                            }
                        }
                    }
                    return {
                        x: x,
                        y: y,
                        align: align
                    }
                },
                _getTranslatedValue: function(value, y, offset) {
                    return {
                        x: this._translator.translate(value, offset, "semidiscrete" === this._options.type && this._options.tickInterval),
                        y: y
                    }
                },
                _getSkippedCategory: function() {
                    var skippedCategory, categories = this._translator.getVisibleCategories() || this._translator.getBusinessRange().categories;
                    if (categories && categories.length && !!this._tickOffset) {
                        skippedCategory = categories[categories.length - 1]
                    }
                    return skippedCategory
                },
                _getSpiderCategoryOption: $.noop
            }
        }
    },
    /*!****************************************!*\
      !*** ./Scripts/viz/axes/polar_axes.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var circularAxes, polarAxes, $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            constants = __webpack_require__( /*! ./axes_constants */ 507),
            xyAxesLinear = __webpack_require__( /*! ./xy_axes */ 513).linear,
            _map = vizUtils.map,
            _math = Math,
            _abs = _math.abs,
            _round = _math.round,
            convertPolarToXY = vizUtils.convertPolarToXY,
            _extend = $.extend,
            _noop = $.noop,
            HALF_PI_ANGLE = 90;

        function getPolarQuarter(angle) {
            var quarter;
            angle = vizUtils.normalizeAngle(angle);
            if (angle >= 315 && angle <= 360 || angle < 45 && angle >= 0) {
                quarter = 1
            } else {
                if (angle >= 45 && angle < 135) {
                    quarter = 2
                } else {
                    if (angle >= 135 && angle < 225) {
                        quarter = 3
                    } else {
                        if (angle >= 225 && angle < 315) {
                            quarter = 4
                        }
                    }
                }
            }
            return quarter
        }
        polarAxes = exports;
        circularAxes = polarAxes.circular = {
            _overlappingBehaviorType: "circular",
            _createAxisElement: function() {
                var additionalTranslator = this._additionalTranslator;
                return this._renderer.circle(additionalTranslator.getCenter().x, additionalTranslator.getCenter().y, additionalTranslator.getRadius())
            },
            _setBoundingRect: function() {
                this.boundingRect = {
                    width: 0,
                    height: 0
                }
            },
            _boundaryTicksVisibility: {
                min: true
            },
            _getOverlappingBehaviorOptions: function() {
                var that = this,
                    additionalTranslator = that._additionalTranslator,
                    angles = additionalTranslator.getAngles(),
                    options = xyAxesLinear._getOverlappingBehaviorOptions.call(that),
                    translator = that._translator,
                    indentFromAxis = that._options.label.indentFromAxis || 0;
                if (options.overlappingBehavior) {
                    options.overlappingBehavior = {
                        mode: constants.validateOverlappingMode(options.overlappingBehavior.mode)
                    }
                }
                options.translate = function(value) {
                    return convertPolarToXY(additionalTranslator.getCenter(), angles[0], translator.translate(value), additionalTranslator.translate(constants.canvasPositionBottom))
                };
                options.circularRadius = additionalTranslator.getRadius() + indentFromAxis;
                options.circularStartAngle = angles[0];
                options.circularEndAngle = angles[1];
                options.isHorizontal = false;
                return options
            },
            _addBoundaryTick: function(ticks) {
                var boundaryTicks = this._tickManager.getBoundaryTicks();
                boundaryTicks.length && ticks.unshift({
                    value: boundaryTicks[0]
                })
            },
            _getSpiderCategoryOption: function() {
                return this._options.firstPointOnStartAngle
            },
            _getMinMax: function() {
                var max, options = this._options,
                    min = commonUtils.isNumber(options.originValue) ? options.originValue : void 0;
                if (options.period > 0 && options.argumentType === constants.numeric) {
                    min = min || 0;
                    max = min + options.period
                }
                return {
                    min: min,
                    max: max
                }
            },
            _getStick: function() {
                return this._options.firstPointOnStartAngle || this._options.type !== constants.discrete
            },
            measureLabels: function(withIndents) {
                var maxLabelParams, that = this,
                    options = that._options,
                    indentFromAxis = options.label.indentFromAxis || 0,
                    widthAxis = options.visible ? options.width : 0,
                    halfTickLength = .5 * options.tick.length,
                    indent = withIndents ? indentFromAxis + halfTickLength : 0;
                if (!that._axisElementsGroup || !that._options.label.visible) {
                    return {
                        height: widthAxis,
                        width: widthAxis
                    }
                }
                that._updateTickManager();
                maxLabelParams = that._tickManager.getMaxLabelParams();
                return {
                    height: maxLabelParams.height + indent,
                    width: maxLabelParams.width + indent
                }
            },
            _getTranslatedCoord: function(value, offset) {
                return this._translator.translate(value, offset) - HALF_PI_ANGLE
            },
            _getCanvasStartEnd: function() {
                return {
                    start: 0 - HALF_PI_ANGLE,
                    end: 360 - HALF_PI_ANGLE
                }
            },
            _createStrip: function(fromAngle, toAngle, attr) {
                var center = this._additionalTranslator.getCenter(),
                    r = this._additionalTranslator.getRadius();
                return this._renderer.arc(center.x, center.y, 0, r, -toAngle, -fromAngle).attr(attr)
            },
            _getStripLabelCoords: function(_, stripFrom, stripTo) {
                var that = this,
                    angle = stripFrom + (stripTo - stripFrom) / 2,
                    cossin = vizUtils.getCosAndSin(-angle),
                    halfRad = that._additionalTranslator.getRadius() / 2,
                    center = that._additionalTranslator.getCenter(),
                    x = _round(center.x + halfRad * cossin.cos),
                    y = _round(center.y - halfRad * cossin.sin);
                return {
                    x: x,
                    y: y,
                    align: constants.center
                }
            },
            _createConstantLine: function(value, attr) {
                var center = this._additionalTranslator.getCenter(),
                    r = this._additionalTranslator.getRadius();
                return this._createPathElement([center.x, center.y, center.x + r, center.y], attr).rotate(value, center.x, center.y)
            },
            _getConstantLineLabelsCoords: function(value) {
                var that = this,
                    cossin = vizUtils.getCosAndSin(-value),
                    halfRad = that._additionalTranslator.getRadius() / 2,
                    center = that._additionalTranslator.getCenter(),
                    x = _round(center.x + halfRad * cossin.cos),
                    y = _round(center.y - halfRad * cossin.sin);
                return {
                    x: x,
                    y: y,
                    align: constants.center
                }
            },
            _checkAlignmentConstantLineLabels: _noop,
            _getScreenDelta: function() {
                return 2 * Math.PI * this._additionalTranslator.getRadius()
            },
            _getTickCoord: function(tick) {
                var center = this._additionalTranslator.getCenter(),
                    r = this._additionalTranslator.getRadius(),
                    corrections = {
                        inside: -1,
                        center: -.5,
                        outside: 0
                    },
                    tickCorrection = tick.length * corrections[this._options.tickOrientation || "center"],
                    radiusWithTicks = r + tickCorrection;
                return {
                    x1: center.x + radiusWithTicks,
                    y1: center.y,
                    x2: center.x + radiusWithTicks + tick.length,
                    y2: center.y,
                    angle: tick.angle
                }
            },
            _getLabelAdjustedCoord: function(tick) {
                var that = this,
                    pos = tick.labelPos,
                    cossin = vizUtils.getCosAndSin(pos.angle),
                    cos = cossin.cos,
                    sin = cossin.sin,
                    box = tick.label.getBBox(),
                    halfWidth = box.width / 2,
                    halfHeight = box.height / 2,
                    indentFromAxis = that._options.label.indentFromAxis || 0,
                    x = pos.x + indentFromAxis * cos,
                    y = pos.y + (pos.y - box.y - halfHeight) + indentFromAxis * sin;
                switch (getPolarQuarter(pos.angle)) {
                    case 1:
                        x += halfWidth;
                        y += halfHeight * sin;
                        break;
                    case 2:
                        x += halfWidth * cos;
                        y += halfHeight;
                        break;
                    case 3:
                        x += -halfWidth;
                        y += halfHeight * sin;
                        break;
                    case 4:
                        x += halfWidth * cos;
                        y += -halfHeight
                }
                return {
                    x: x,
                    y: y
                }
            },
            _getGridLineDrawer: function() {
                var that = this,
                    r = that._additionalTranslator.getRadius(),
                    center = that._additionalTranslator.getCenter();
                return function(tick) {
                    return that._createPathElement([center.x, center.y, center.x + r, center.y], tick.gridStyle).rotate(tick.angle, center.x, center.y)
                }
            },
            _getTranslatedValue: function(value, _, offset) {
                var additionalTranslator = this._additionalTranslator,
                    startAngle = additionalTranslator.getAngles()[0],
                    angle = this._translator.translate(value, -offset),
                    coords = convertPolarToXY(additionalTranslator.getCenter(), startAngle, angle, additionalTranslator.translate(constants.canvasPositionBottom));
                return {
                    x: coords.x,
                    y: coords.y,
                    angle: angle + startAngle - HALF_PI_ANGLE
                }
            },
            _getAdjustedStripLabelCoords: function(_, label) {
                var y, box = label.getBBox();
                y = label.attr("y") - box.y - box.height / 2;
                return {
                    x: 0,
                    y: y
                }
            },
            coordsIn: function(x, y) {
                return vizUtils.convertXYToPolar(this._additionalTranslator.getCenter(), x, y).r > this._additionalTranslator.getRadius()
            },
            _rotateTick: function(tick, angle) {
                var center = this._additionalTranslator.getCenter();
                tick.graphic.rotate(angle, center.x, center.y)
            }
        };
        exports.circularSpider = _extend({}, circularAxes, {
            _createAxisElement: function() {
                var points = _map(this.getSpiderTicks(), function(tick) {
                    return {
                        x: tick.posX,
                        y: tick.posY
                    }
                });
                return this._renderer.path(points, "area")
            },
            _getStick: function() {
                return true
            },
            _getSpiderCategoryOption: function() {
                return true
            },
            getSpiderTicks: function() {
                var that = this;
                that._spiderTicks = constants.convertValuesToTicks(that._tickManager.getFullTicks());
                that._initTicks(that._spiderTicks, {
                    tickStyle: {},
                    gridStyle: {}
                }, false, that._getSkippedCategory(), that._tickOffset);
                return that._spiderTicks
            },
            _createStrip: function(fromAngle, toAngle, attr) {
                var firstTick, lastTick, nextTick, tick, center = this._additionalTranslator.getCenter(),
                    spiderTicks = this.getSpiderTicks(),
                    points = [],
                    i = 0,
                    len = spiderTicks.length;
                while (i < len) {
                    tick = spiderTicks[i];
                    if (tick.angle >= fromAngle && tick.angle <= toAngle) {
                        if (!firstTick) {
                            firstTick = spiderTicks[i - 1] || spiderTicks[spiderTicks.length - 1];
                            points.push((tick.posX + firstTick.posX) / 2, (tick.posY + firstTick.posY) / 2)
                        }
                        points.push(tick.posX, tick.posY);
                        nextTick = spiderTicks[i + 1] || spiderTicks[0];
                        lastTick = {
                            x: (tick.posX + nextTick.posX) / 2,
                            y: (tick.posY + nextTick.posY) / 2
                        }
                    }
                    i++
                }
                points.push(lastTick.x, lastTick.y);
                points.push(center.x, center.y);
                return this._renderer.path(points, "area").attr(attr)
            },
            _getTranslatedCoord: function(value, offset) {
                return this._translator.translate(value, offset) - HALF_PI_ANGLE
            },
            _setTickOffset: function() {
                this._tickOffset = false
            }
        });
        polarAxes.linear = {
            _overlappingBehaviorType: "linear",
            _getMinMax: circularAxes._getMinMax,
            _getStick: xyAxesLinear._getStick,
            _getSpiderCategoryOption: $.noop,
            _createAxisElement: function() {
                var additionalTranslator = this._additionalTranslator,
                    centerCoord = additionalTranslator.getCenter(),
                    points = [centerCoord.x, centerCoord.y, centerCoord.x + additionalTranslator.getRadius(), centerCoord.y];
                return this._renderer.path(points, "line").rotate(additionalTranslator.getAngles()[0] - HALF_PI_ANGLE, centerCoord.x, centerCoord.y)
            },
            _setBoundingRect: circularAxes._setBoundingRect,
            _getScreenDelta: function() {
                return this._additionalTranslator.getRadius()
            },
            _getTickCoord: function(tick) {
                return {
                    x1: tick.posX - tick.length / 2,
                    y1: tick.posY,
                    x2: tick.posX + tick.length / 2,
                    y2: tick.posY,
                    angle: tick.angle + HALF_PI_ANGLE
                }
            },
            _getOverlappingBehaviorOptions: function() {
                var that = this,
                    translator = that._translator,
                    orthTranslator = that._additionalTranslator,
                    options = xyAxesLinear._getOverlappingBehaviorOptions.call(this),
                    startAngle = vizUtils.normalizeAngle(that._additionalTranslator.getAngles()[0]);
                if (options.overlappingBehavior) {
                    options.overlappingBehavior = {
                        mode: constants.validateOverlappingMode(options.overlappingBehavior.mode)
                    }
                }
                options.isHorizontal = startAngle > 45 && startAngle < 135 || startAngle > 225 && startAngle < 315 ? true : false;
                options.translate = function(value) {
                    return convertPolarToXY(orthTranslator.getCenter(), that._options.startAngle, orthTranslator.translate(constants.canvasPositionTop), translator.translate(value)).x
                };
                return options
            },
            _getLabelAdjustedCoord: function(tick) {
                var x, y, that = this,
                    pos = tick.labelPos,
                    cossin = vizUtils.getCosAndSin(pos.angle),
                    indentFromAxis = that._options.label.indentFromAxis || 0,
                    box = tick.label.getBBox();
                x = pos.x - _abs(indentFromAxis * cossin.sin) + _abs(box.width / 2 * cossin.cos);
                y = pos.y + (pos.y - box.y) - _abs(box.height / 2 * cossin.sin) + _abs(indentFromAxis * cossin.cos);
                return {
                    x: x,
                    y: y
                }
            },
            _getGridLineDrawer: function() {
                var that = this,
                    pos = that._additionalTranslator.getCenter();
                return function(tick) {
                    return that._renderer.circle(pos.x, pos.y, vizUtils.getDistance(pos.x, pos.y, tick.posX, tick.posY)).attr(tick.gridStyle).sharp()
                }
            },
            _getTranslatedValue: function(value, _, offset) {
                var additionalTranslator = this._additionalTranslator,
                    startAngle = additionalTranslator.getAngles()[0],
                    angle = additionalTranslator.translate(constants.canvasPositionStart),
                    xy = convertPolarToXY(additionalTranslator.getCenter(), startAngle, angle, this._translator.translate(value, offset));
                return {
                    x: xy.x,
                    y: xy.y,
                    angle: angle + startAngle - HALF_PI_ANGLE
                }
            },
            _getTranslatedCoord: function(value, offset) {
                return this._translator.translate(value, offset)
            },
            _getCanvasStartEnd: function() {
                return {
                    start: 0,
                    end: this._additionalTranslator.getRadius()
                }
            },
            _createStrip: function(fromPoint, toPoint, attr) {
                var center = this._additionalTranslator.getCenter();
                return this._renderer.arc(center.x, center.y, fromPoint, toPoint, 0, 360).attr(attr)
            },
            _getAdjustedStripLabelCoords: circularAxes._getAdjustedStripLabelCoords,
            _getStripLabelCoords: function(_, stripFrom, stripTo) {
                var that = this,
                    labelPos = stripFrom + (stripTo - stripFrom) / 2,
                    center = that._additionalTranslator.getCenter(),
                    y = _round(center.y - labelPos);
                return {
                    x: center.x,
                    y: y,
                    align: constants.center
                }
            },
            _createConstantLine: function(value, attr) {
                var center = this._additionalTranslator.getCenter();
                return this._renderer.circle(center.x, center.y, value).attr(attr).sharp()
            },
            _getConstantLineLabelsCoords: function(value) {
                var that = this,
                    center = that._additionalTranslator.getCenter(),
                    y = _round(center.y - value);
                return {
                    x: center.x,
                    y: y,
                    align: constants.center
                }
            },
            _checkAlignmentConstantLineLabels: _noop,
            _rotateTick: function(tick, angle) {
                tick.graphic.rotate(angle, tick.posX, tick.posY)
            }
        };
        polarAxes.linearSpider = _extend({}, polarAxes.linear, {
            _createPathElement: function(points, attr) {
                return this._renderer.path(points, "area").attr(attr).sharp()
            },
            setSpiderTicks: function(ticks) {
                this._spiderTicks = ticks
            },
            _getGridLineDrawer: function() {
                var that = this,
                    pos = that._additionalTranslator.getCenter();
                return function(tick) {
                    var radius = vizUtils.getDistance(pos.x, pos.y, tick.posX, tick.posY);
                    return that._createPathElement(that._getGridPoints(pos, radius), tick.gridStyle)
                }
            },
            _getGridPoints: function(pos, radius) {
                return _map(this._spiderTicks, function(tick) {
                    var cossin = vizUtils.getCosAndSin(tick.angle);
                    return {
                        x: _round(pos.x + radius * cossin.cos),
                        y: _round(pos.y + radius * cossin.sin)
                    }
                })
            },
            _createStrip: function(fromPoint, toPoint, attr) {
                var center = this._additionalTranslator.getCenter(),
                    innerPoints = this._getGridPoints(center, toPoint),
                    outerPoints = this._getGridPoints(center, fromPoint);
                return this._renderer.path([outerPoints, innerPoints.reverse()], "area").attr(attr)
            },
            _createConstantLine: function(value, attr) {
                var center = this._additionalTranslator.getCenter(),
                    points = this._getGridPoints(center, value);
                return this._createPathElement(points, attr)
            }
        })
    },
    /*!*******************************************!*\
      !*** ./Scripts/viz/core/series_family.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _math = Math,
            _round = _math.round,
            _abs = _math.abs,
            _pow = _math.pow,
            _each = $.each,
            _noop = $.noop,
            vizUtils = __webpack_require__( /*! ./utils */ 442),
            _normalizeEnum = vizUtils.normalizeEnum;

        function getStacksWithArgument(stackKeepers, argument) {
            var stacksWithArgument = [];
            _each(stackKeepers, function(stackName, seriesInStack) {
                _each(seriesInStack, function(_, singleSeries) {
                    var i, points = singleSeries.getPointsByArg(argument),
                        pointsLength = points.length;
                    for (i = 0; i < pointsLength; ++i) {
                        if (points[i].value) {
                            stacksWithArgument.push(stackName);
                            return false
                        }
                    }
                })
            });
            return stacksWithArgument
        }

        function correctPointCoordinatesForStacks(stackKeepers, stacksWithArgument, argument, parameters) {
            _each(stackKeepers, function(stackName, seriesInStack) {
                var offset, stackIndex = $.inArray(stackName, stacksWithArgument);
                if (stackIndex === -1) {
                    return
                }
                offset = getOffset(stackIndex, parameters);
                _each(seriesInStack, function(_, singleSeries) {
                    correctPointCoordinates(singleSeries.getPointsByArg(argument) || [], parameters.width, offset)
                })
            })
        }

        function adjustBarSeriesDimensionsCore(series, interval, stackCount, options, seriesStackIndexCallback) {
            var percentWidth, stackIndex, i, points, stackName, stacksWithArgument, parameters, argumentsKeeper = {},
                stackKeepers = {},
                barsArea = .7 * interval,
                barWidth = options.barWidth;
            if (options.equalBarWidth) {
                percentWidth = barWidth && (barWidth < 0 || barWidth > 1) ? 0 : barWidth;
                parameters = calculateParams(barsArea, stackCount, percentWidth);
                for (i = 0; i < series.length; i++) {
                    stackIndex = seriesStackIndexCallback(i, stackCount);
                    points = series[i].getPoints();
                    correctPointCoordinates(points, parameters.width, getOffset(stackIndex, parameters))
                }
            } else {
                _each(series, function(i, singleSeries) {
                    stackName = singleSeries.getStackName && singleSeries.getStackName();
                    stackName = stackName || i.toString();
                    if (!stackKeepers[stackName]) {
                        stackKeepers[stackName] = []
                    }
                    stackKeepers[stackName].push(singleSeries);
                    _each(singleSeries.getPoints(), function(_, point) {
                        var argument = point.argument;
                        if (!argumentsKeeper.hasOwnProperty(argument)) {
                            argumentsKeeper[argument.valueOf()] = 1
                        }
                    })
                });
                for (var argument in argumentsKeeper) {
                    stacksWithArgument = getStacksWithArgument(stackKeepers, argument);
                    parameters = calculateParams(barsArea, stacksWithArgument.length);
                    correctPointCoordinatesForStacks(stackKeepers, stacksWithArgument, argument, parameters)
                }
            }
        }

        function calculateParams(barsArea, count, percentWidth) {
            var spacing, width, middleIndex = count / 2;
            if (!percentWidth) {
                spacing = _round(barsArea / count * .2);
                width = _round((barsArea - spacing * (count - 1)) / count);
                width < 2 && (width = 2)
            } else {
                width = _round(barsArea * percentWidth / count);
                spacing = _round(count > 1 ? (barsArea - barsArea * percentWidth) / (count - 1) : 0)
            }
            return {
                width: width,
                spacing: spacing,
                middleIndex: middleIndex
            }
        }

        function getOffset(stackIndex, parameters) {
            return (stackIndex - parameters.middleIndex + .5) * parameters.width - (parameters.middleIndex - stackIndex - .5) * parameters.spacing
        }

        function correctPointCoordinates(points, width, offset) {
            _each(points, function(_, point) {
                point.correctCoordinates({
                    width: width,
                    offset: offset
                })
            })
        }

        function checkMinBarSize(value, minShownValue) {
            return _abs(value) < minShownValue ? value >= 0 ? minShownValue : -minShownValue : value
        }

        function getValueType(value) {
            return value >= 0 ? "positive" : "negative"
        }

        function getVisibleSeries(that) {
            return vizUtils.map(that.series, function(s) {
                return s.isVisible() ? s : null
            })
        }

        function getAbsStackSumByArg(stackKeepers, stackName, argument) {
            var positiveStackValue = (stackKeepers.positive[stackName] || {})[argument] || 0,
                negativeStackValue = -(stackKeepers.negative[stackName] || {})[argument] || 0;
            return positiveStackValue + negativeStackValue
        }

        function getSeriesStackIndexCallback(rotated, series, stackIndexes) {
            if (!rotated) {
                return function(seriesIndex, stackCount) {
                    return stackIndexes ? stackIndexes[series[seriesIndex].getStackName()] : seriesIndex
                }
            } else {
                return function(seriesIndex, stackCount) {
                    return stackCount - (stackIndexes ? stackIndexes[series[seriesIndex].getStackName()] : seriesIndex) - 1
                }
            }
        }

        function adjustBarSeriesDimensions(translators) {
            var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
            debug.assert(translators, "translator was not passed or empty");
            var that = this,
                series = getVisibleSeries(that);
            adjustBarSeriesDimensionsCore(series, translators.arg.getInterval(), series.length, that._options, getSeriesStackIndexCallback(that.rotated, series))
        }

        function adjustStackedBarSeriesDimensions(translators) {
            var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
            debug.assert(translators, "translators was not passed or empty");
            var that = this,
                series = getVisibleSeries(that),
                stackIndexes = {},
                stackCount = 0;
            _each(series, function() {
                var stackName = this.getStackName();
                if (!stackIndexes.hasOwnProperty(stackName)) {
                    stackIndexes[stackName] = stackCount++
                }
            });
            adjustBarSeriesDimensionsCore(series, translators.arg.getInterval(), stackCount, that._options, getSeriesStackIndexCallback(that.rotated, series, stackIndexes))
        }

        function adjustStackedSeriesValues() {
            var that = this,
                negativesAsZeroes = that._options.negativesAsZeroes,
                series = getVisibleSeries(that),
                stackKeepers = {
                    positive: {},
                    negative: {}
                },
                holesStack = {
                    left: {},
                    right: {}
                };
            _each(series, function(seriesIndex, singleSeries) {
                var points = singleSeries.getPoints(),
                    hole = false;
                singleSeries._prevSeries = series[seriesIndex - 1];
                singleSeries.holes = $.extend(true, {}, holesStack);
                _each(points, function(index, point) {
                    var currentStack, value = point.initialValue,
                        argument = point.argument.valueOf(),
                        stackName = singleSeries.getStackName(),
                        stacks = value >= 0 ? stackKeepers.positive : stackKeepers.negative;
                    if (negativesAsZeroes && value < 0) {
                        stacks = stackKeepers.positive;
                        value = 0;
                        point.resetValue()
                    }
                    stacks[stackName] = stacks[stackName] || {};
                    currentStack = stacks[stackName];
                    if (currentStack[argument]) {
                        point.correctValue(currentStack[argument]);
                        currentStack[argument] += value
                    } else {
                        currentStack[argument] = value;
                        point.resetCorrection()
                    }
                    if (!point.hasValue()) {
                        var prevPoint = points[index - 1];
                        if (!hole && prevPoint && prevPoint.hasValue()) {
                            argument = prevPoint.argument.valueOf();
                            prevPoint._skipSetRightHole = true;
                            holesStack.right[argument] = (holesStack.right[argument] || 0) + (prevPoint.value - (isFinite(prevPoint.minValue) ? prevPoint.minValue : 0))
                        }
                        hole = true
                    } else {
                        if (hole) {
                            hole = false;
                            holesStack.left[argument] = (holesStack.left[argument] || 0) + (point.value - (isFinite(point.minValue) ? point.minValue : 0));
                            point._skipSetLeftHole = true
                        }
                    }
                })
            });
            _each(series, function(seriesIndex, singleSeries) {
                var points = singleSeries.getPoints(),
                    holes = singleSeries.holes;
                _each(points, function(index, point) {
                    var argument = point.argument.valueOf();
                    point.resetHoles();
                    !point._skipSetLeftHole && point.setHole(holes.left[argument] || holesStack.left[argument] && 0, "left");
                    !point._skipSetRightHole && point.setHole(holes.right[argument] || holesStack.right[argument] && 0, "right");
                    point._skipSetLeftHole = null;
                    point._skipSetRightHole = null
                })
            });
            that._stackKeepers = stackKeepers;
            _each(series, function(_, singleSeries) {
                _each(singleSeries.getPoints(), function(_, point) {
                    var argument = point.argument.valueOf();
                    point.setPercentValue(getAbsStackSumByArg(stackKeepers, singleSeries.getStackName(), argument), that.fullStacked, holesStack.left[argument], holesStack.right[argument])
                })
            })
        }

        function updateStackedSeriesValues(translators) {
            var that = this,
                series = getVisibleSeries(that),
                stack = that._stackKeepers,
                stackKeepers = {
                    positive: {},
                    negative: {}
                };
            _each(series, function(_, singleSeries) {
                var minBarSize = singleSeries.getOptions().minBarSize,
                    tr = singleSeries.axis ? translators.axesTrans[singleSeries.axis] : translators,
                    minShownBusinessValue = minBarSize && tr.val.getMinBarSize(minBarSize),
                    stackName = singleSeries.getStackName();
                _each(singleSeries.getPoints(), function(index, point) {
                    if (!point.hasValue()) {
                        return
                    }
                    var updateValue, valueType, currentStack, value = point.initialValue,
                        argument = point.argument.valueOf();
                    if (that.fullStacked) {
                        value = value / getAbsStackSumByArg(stack, stackName, argument) || 0
                    }
                    updateValue = checkMinBarSize(value, minShownBusinessValue);
                    valueType = getValueType(updateValue);
                    currentStack = stackKeepers[valueType][stackName] = stackKeepers[valueType][stackName] || {};
                    if (currentStack[argument]) {
                        point.minValue = currentStack[argument];
                        currentStack[argument] += updateValue
                    } else {
                        currentStack[argument] = updateValue
                    }
                    point.value = currentStack[argument]
                })
            });
            if (that.fullStacked) {
                updateFullStackedSeriesValues(series, stackKeepers)
            }
        }

        function updateFullStackedSeriesValues(series, stackKeepers) {
            _each(series, function(_, singleSeries) {
                var stackName = singleSeries.getStackName ? singleSeries.getStackName() : "default";
                _each(singleSeries.getPoints(), function(index, point) {
                    var stackSum = getAbsStackSumByArg(stackKeepers, stackName, point.argument.valueOf());
                    point.value = point.value / stackSum;
                    if (commonUtils.isNumber(point.minValue)) {
                        point.minValue = point.minValue / stackSum
                    }
                })
            })
        }

        function updateBarSeriesValues(translators) {
            _each(this.series, function(_, singleSeries) {
                var minBarSize = singleSeries.getOptions().minBarSize,
                    tr = singleSeries.axis ? translators.axesTrans[singleSeries.axis] : translators,
                    minShownBusinessValue = minBarSize && tr.val.getMinBarSize(minBarSize);
                if (minShownBusinessValue) {
                    _each(singleSeries.getPoints(), function(index, point) {
                        if (point.hasValue()) {
                            point.value = checkMinBarSize(point.initialValue, minShownBusinessValue)
                        }
                    })
                }
            })
        }

        function adjustCandlestickSeriesDimensions(translators) {
            var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
            debug.assert(translators, "translator was not passed or empty");
            var series = getVisibleSeries(this);
            adjustBarSeriesDimensionsCore(series, translators.arg.getInterval(), series.length, {
                barWidth: null,
                equalBarWidth: true
            }, getSeriesStackIndexCallback(this.rotated, series))
        }

        function adjustBubbleSeriesDimensions(translators) {
            var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
            debug.assert(translators, "translator was not passed or empty");
            var pointSize, bubbleArea, sizeProportion, sizeDispersion, areaDispersion, that = this,
                series = getVisibleSeries(that),
                options = that._options,
                visibleAreaX = translators.arg.getCanvasVisibleArea(),
                visibleAreaY = translators.val.getCanvasVisibleArea(),
                min = _math.min(visibleAreaX.max - visibleAreaX.min, visibleAreaY.max - visibleAreaY.min),
                minBubbleArea = _pow(options.minBubbleSize, 2),
                maxBubbleArea = _pow(min * options.maxBubbleSize, 2),
                equalBubbleSize = (min * options.maxBubbleSize + options.minBubbleSize) / 2,
                minPointSize = 1 / 0,
                maxPointSize = 0;
            _each(series, function(_, seriesItem) {
                _each(seriesItem.getPoints(), function(_, point) {
                    maxPointSize = maxPointSize > point.size ? maxPointSize : point.size;
                    minPointSize = minPointSize < point.size ? minPointSize : point.size
                })
            });
            sizeDispersion = maxPointSize - minPointSize;
            areaDispersion = _abs(maxBubbleArea - minBubbleArea);
            minPointSize = minPointSize < 0 ? 0 : minPointSize;
            _each(series, function(_, seriesItem) {
                _each(seriesItem.getPoints(), function(_, point) {
                    if (maxPointSize === minPointSize) {
                        pointSize = _round(equalBubbleSize)
                    } else {
                        sizeProportion = _abs(point.size - minPointSize) / sizeDispersion;
                        bubbleArea = areaDispersion * sizeProportion + minBubbleArea;
                        pointSize = _round(_math.sqrt(bubbleArea))
                    }
                    point.correctCoordinates(pointSize)
                })
            })
        }

        function SeriesFamily(options) {
            var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
            debug.assert(options.type, "type was not passed or empty");
            var that = this;
            that.type = _normalizeEnum(options.type);
            that.pane = options.pane;
            that.rotated = options.rotated;
            that.series = [];
            that.updateOptions(options);
            switch (that.type) {
                case "bar":
                    that.adjustSeriesDimensions = adjustBarSeriesDimensions;
                    that.updateSeriesValues = updateBarSeriesValues;
                    break;
                case "rangebar":
                    that.adjustSeriesDimensions = adjustBarSeriesDimensions;
                    break;
                case "fullstackedbar":
                    that.fullStacked = true;
                    that.adjustSeriesDimensions = adjustStackedBarSeriesDimensions;
                    that.adjustSeriesValues = adjustStackedSeriesValues;
                    that.updateSeriesValues = updateStackedSeriesValues;
                    break;
                case "stackedbar":
                    that.adjustSeriesDimensions = adjustStackedBarSeriesDimensions;
                    that.adjustSeriesValues = adjustStackedSeriesValues;
                    that.updateSeriesValues = updateStackedSeriesValues;
                    break;
                case "fullstackedarea":
                case "fullstackedline":
                case "fullstackedspline":
                case "fullstackedsplinearea":
                    that.fullStacked = true;
                    that.adjustSeriesValues = adjustStackedSeriesValues;
                    break;
                case "stackedarea":
                case "stackedsplinearea":
                case "stackedline":
                case "stackedspline":
                    that.adjustSeriesValues = adjustStackedSeriesValues;
                    break;
                case "candlestick":
                case "stock":
                    that.adjustSeriesDimensions = adjustCandlestickSeriesDimensions;
                    break;
                case "bubble":
                    that.adjustSeriesDimensions = adjustBubbleSeriesDimensions
            }
        }
        exports.SeriesFamily = SeriesFamily;
        SeriesFamily.prototype = {
            constructor: SeriesFamily,
            adjustSeriesDimensions: _noop,
            adjustSeriesValues: _noop,
            updateSeriesValues: _noop,
            updateOptions: function(options) {
                this._options = options
            },
            dispose: function() {
                this.series = this.translators = null
            },
            add: function(series) {
                var type = this.type;
                this.series = vizUtils.map(series, function(singleSeries) {
                    return singleSeries.type === type ? singleSeries : null
                })
            }
        }
    },
    /*!****************************************************!*\
      !*** ./Scripts/viz/chart_components/scroll_bar.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            MIN_SCROLL_BAR_SIZE = 2,
            translator2DModule = __webpack_require__( /*! ../translators/translator2d */ 497),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            isDefined = commonUtils.isDefined,
            _min = Math.min,
            _max = Math.max;
        var ScrollBar = function(renderer, group) {
            this._translator = new translator2DModule.Translator2D({}, {}, {});
            this._scroll = renderer.rect().append(group);
            this._addEvents()
        };

        function _getXCoord(canvas, pos, offset, width) {
            var x = 0;
            if ("right" === pos) {
                x = canvas.width - canvas.right + offset
            } else {
                if ("left" === pos) {
                    x = canvas.left - offset - width
                }
            }
            return x
        }

        function _getYCoord(canvas, pos, offset, width) {
            var y = 0;
            if ("top" === pos) {
                y = canvas.top - offset
            } else {
                if ("bottom" === pos) {
                    y = canvas.height - canvas.bottom + width + offset
                }
            }
            return y
        }
        ScrollBar.prototype = {
            _addEvents: function() {
                var that = this,
                    $scroll = $(that._scroll.element),
                    startPosX = 0,
                    startPosY = 0,
                    scrollChangeHandler = function(e) {
                        var dX = (startPosX - e.pageX) * that._scale,
                            dY = (startPosY - e.pageY) * that._scale;
                        $scroll.trigger(new $.Event("dxc-scroll-move", $.extend(e, {
                            type: "dxc-scroll-move",
                            pointers: [{
                                pageX: startPosX + dX,
                                pageY: startPosY + dY
                            }]
                        })))
                    };
                $scroll.on(pointerEvents.down, function(e) {
                    startPosX = e.pageX;
                    startPosY = e.pageY;
                    $scroll.trigger(new $.Event("dxc-scroll-start", {
                        pointers: [{
                            pageX: startPosX,
                            pageY: startPosY
                        }]
                    }));
                    $(document).on(pointerEvents.move, scrollChangeHandler)
                });
                $(document).on(pointerEvents.up, function() {
                    $(document).off(pointerEvents.move, scrollChangeHandler)
                })
            },
            update: function(options) {
                var that = this,
                    position = options.position,
                    isVertical = options.rotated,
                    defaultPosition = isVertical ? "right" : "top",
                    secondaryPosition = isVertical ? "left" : "bottom";
                if (position !== defaultPosition && position !== secondaryPosition) {
                    position = defaultPosition
                }
                that._scroll.attr({
                    rotate: !options.rotated ? -90 : 0,
                    rotateX: 0,
                    rotateY: 0,
                    fill: options.color,
                    width: options.width,
                    opacity: options.opacity
                });
                that._layoutOptions = {
                    width: options.width,
                    offset: options.offset,
                    vertical: isVertical,
                    position: position
                };
                return that
            },
            init: function(range, canvas) {
                var that = this;
                that._translateWithOffset = "discrete" === range.axisType && !range.stick && 1 || 0;
                that._translator.update($.extend({}, range, {
                    minVisible: null,
                    maxVisible: null,
                    visibleCategories: null
                }), $.extend({}, canvas), {
                    isHorizontal: !that._layoutOptions.vertical
                });
                return that
            },
            getOptions: function() {
                return this._layoutOptions
            },
            shift: function(x, y) {
                this._scroll.attr({
                    translateX: x,
                    translateY: y
                })
            },
            setPane: function(panes) {
                var pane, position = this._layoutOptions.position;
                if ("left" === position || "top" === position) {
                    pane = panes[0]
                } else {
                    pane = panes[panes.length - 1]
                }
                this.pane = pane.name;
                this._canvas = pane.canvas;
                return this
            },
            getMultipleAxesSpacing: function() {
                return 0
            },
            getBoundingRect: function() {
                var options = this._layoutOptions,
                    isVertical = options.vertical,
                    offset = options.offset,
                    width = options.width,
                    pos = options.position,
                    size = width + offset,
                    canvas = this._canvas;
                return isVertical ? {
                    x: _getXCoord(canvas, pos, offset, width),
                    y: canvas.top,
                    width: size,
                    height: canvas.height - canvas.top - canvas.bottom
                } : {
                    x: canvas.left,
                    y: _getYCoord(canvas, pos, offset, width),
                    width: canvas.width - canvas.left - canvas.right,
                    height: size
                }
            },
            applyLayout: function() {
                var canvas = this._canvas,
                    options = this._layoutOptions,
                    pos = options.position,
                    offset = options.offset,
                    width = options.width;
                this.shift(_getXCoord(canvas, pos, offset, width), _getYCoord(canvas, pos, offset, width))
            },
            setPosition: function(min, max) {
                var that = this,
                    translator = that._translator,
                    minPoint = isDefined(min) ? translator.translate(min, -that._translateWithOffset) : translator.translate("canvas_position_start"),
                    maxPoint = isDefined(max) ? translator.translate(max, that._translateWithOffset) : translator.translate("canvas_position_end");
                that._offset = _min(minPoint, maxPoint);
                that._scale = translator.getScale(min, max);
                that._applyPosition(_min(minPoint, maxPoint), _max(minPoint, maxPoint))
            },
            transform: function(translate, scale) {
                var translator = this._translator,
                    x = translator.getCanvasVisibleArea().min,
                    dx = x - (x * scale - translate),
                    lx = this._offset + dx / (this._scale * scale);
                this._applyPosition(lx, lx + translator.canvasLength / (this._scale * scale))
            },
            dispose: function() {
                this._scroll.dispose();
                this._scroll = this._translator = null
            },
            _applyPosition: function(x1, x2) {
                var height, that = this,
                    visibleArea = that._translator.getCanvasVisibleArea();
                x1 = _max(x1, visibleArea.min);
                x1 = _min(x1, visibleArea.max);
                x2 = _min(x2, visibleArea.max);
                x2 = _max(x2, visibleArea.min);
                height = Math.abs(x2 - x1);
                that._scroll.attr({
                    y: x1,
                    height: height < MIN_SCROLL_BAR_SIZE ? MIN_SCROLL_BAR_SIZE : height
                })
            }
        };
        exports.ScrollBar = ScrollBar
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/chart_components/crosshair.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            math = Math,
            mathAbs = math.abs,
            mathMin = math.min,
            mathMax = math.max,
            mathFloor = math.floor,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            HORIZONTAL = "horizontal",
            VERTICAL = "vertical",
            LABEL_BACKGROUND_PADDING_X = 8,
            LABEL_BACKGROUND_PADDING_Y = 4,
            CENTER = "center",
            RIGHT = "right",
            LEFT = "left",
            TOP = "top",
            BOTTOM = "bottom";

        function Crosshair(renderer, options, params, group) {
            var that = this;
            that._renderer = renderer;
            that._crosshairGroup = group;
            that._options = {};
            that.update(options, params)
        }
        Crosshair.prototype = {
            constructor: Crosshair,
            update: function(options, params) {
                var that = this,
                    canvas = params.canvas;
                that._canvas = {
                    top: canvas.top,
                    bottom: canvas.height - canvas.bottom,
                    left: canvas.left,
                    right: canvas.width - canvas.right,
                    width: canvas.width,
                    height: canvas.height
                };
                that._axes = params.axes;
                that._panes = params.panes;
                that._prepareOptions(options, HORIZONTAL);
                that._prepareOptions(options, VERTICAL)
            },
            dispose: function() {
                var that = this;
                that._renderer = that._crosshairGroup = that._options = that._axes = that._canvas = that._horizontalGroup = that._verticalGroup = that._horizontal = that._vertical = that._circle = that._panes = null
            },
            _prepareOptions: function(options, direction) {
                var lineOptions = options[direction + "Line"];
                this._options[direction] = {
                    visible: lineOptions.visible,
                    line: {
                        stroke: lineOptions.color || options.color,
                        "stroke-width": lineOptions.width || options.width,
                        dashStyle: lineOptions.dashStyle || options.dashStyle,
                        opacity: lineOptions.opacity || options.opacity,
                        "stroke-linecap": "butt"
                    },
                    label: $.extend(true, {}, options.label, lineOptions.label)
                }
            },
            _createLines: function(options, sharpParam, group) {
                var lines = [],
                    canvas = this._canvas,
                    points = [canvas.left, canvas.top, canvas.left, canvas.top];
                for (var i = 0; i < 2; i++) {
                    lines.push(this._renderer.path(points, "line").attr(options).sharp(sharpParam).append(group))
                }
                return lines
            },
            render: function() {
                var that = this,
                    renderer = that._renderer,
                    options = that._options,
                    verticalOptions = options.vertical,
                    horizontalOptions = options.horizontal,
                    extraOptions = horizontalOptions.visible ? horizontalOptions.line : verticalOptions.line,
                    circleOptions = {
                        stroke: extraOptions.stroke,
                        "stroke-width": extraOptions["stroke-width"],
                        dashStyle: extraOptions.dashStyle,
                        opacity: extraOptions.opacity
                    },
                    canvas = that._canvas;
                that._horizontal = {};
                that._vertical = {};
                that._circle = renderer.circle(canvas.left, canvas.top, 0).attr(circleOptions).append(that._crosshairGroup);
                that._horizontalGroup = renderer.g().append(that._crosshairGroup);
                that._verticalGroup = renderer.g().append(that._crosshairGroup);
                if (verticalOptions.visible) {
                    that._vertical.lines = that._createLines(verticalOptions.line, "h", that._verticalGroup);
                    that._vertical.labels = that._createLabels(that._axes[0], verticalOptions, false, that._verticalGroup)
                }
                if (horizontalOptions.visible) {
                    that._horizontal.lines = that._createLines(horizontalOptions.line, "v", that._horizontalGroup);
                    that._horizontal.labels = that._createLabels(that._axes[1], horizontalOptions, true, that._horizontalGroup)
                }
                that.hide()
            },
            _createLabels: function(axes, options, isHorizontal, group) {
                var x, y, text, background, currentLabelPos, bbox, that = this,
                    canvas = that._canvas,
                    renderer = that._renderer,
                    labels = [],
                    labelOptions = options.label;
                if (!labelOptions || !labelOptions.visible) {
                    return
                }
                $.each(axes, function(_, axis) {
                    var align, position = axis.getOptions().position;
                    if (axis.getTranslator().getBusinessRange().stubData) {
                        return
                    }
                    currentLabelPos = axis.getLabelsParams().pos;
                    if (isHorizontal) {
                        y = canvas.top;
                        x = currentLabelPos
                    } else {
                        x = canvas.left;
                        y = currentLabelPos
                    }
                    align = position === TOP || position === BOTTOM ? CENTER : position === RIGHT ? LEFT : RIGHT;
                    background = renderer.rect(0, 0, 0, 0).attr({
                        fill: labelOptions.backgroundColor || options.line.stroke
                    }).append(group);
                    text = renderer.text("0", x, y).css(vizUtils.patchFontOptions(options.label.font)).attr({
                        align: align
                    }).append(group);
                    bbox = text.getBBox();
                    text.attr({
                        y: isHorizontal ? 2 * y - bbox.y - bbox.height / 2 : position === BOTTOM ? 2 * y - bbox.y : 2 * y - (bbox.y + bbox.height)
                    });
                    labels.push({
                        text: text,
                        background: background,
                        axis: axis,
                        options: labelOptions,
                        pos: {
                            coord: currentLabelPos,
                            side: position,
                            align: align
                        }
                    })
                });
                return labels
            },
            _updateText: function(value, labels, axisName, point, isHorizontalLine) {
                var bbox, text, textElement, backgroundElement, axisLabelsParams, labelSide, that = this;
                if (!labels) {
                    return
                }
                $.each(labels, function(i, label) {
                    var axis = label.axis;
                    text = "";
                    textElement = label.text;
                    backgroundElement = label.background;
                    if (!textElement) {
                        return
                    }
                    if (!axis.name || axis.name === axisName) {
                        text = axis.getFormattedValue(value, label.options, point)
                    }
                    if (text) {
                        textElement.attr({
                            text: text
                        });
                        bbox = textElement.getBBox();
                        axisLabelsParams = axis.getLabelsParams();
                        labelSide = label.pos.side;
                        if (isHorizontalLine) {
                            if (axisLabelsParams.width < bbox.width) {
                                textElement.attr({
                                    align: labelSide,
                                    x: axisLabelsParams.pos + (labelSide === LEFT ? -1 : 1) * axisLabelsParams.width
                                })
                            } else {
                                textElement.attr({
                                    align: label.pos.align,
                                    x: axisLabelsParams.pos
                                })
                            }
                            bbox = textElement.getBBox()
                        }
                        that._updateLinesCanvas(labelSide, label.pos.coord);
                        backgroundElement.attr({
                            x: bbox.x - LABEL_BACKGROUND_PADDING_X,
                            y: bbox.y - LABEL_BACKGROUND_PADDING_Y,
                            width: bbox.width + 2 * LABEL_BACKGROUND_PADDING_X,
                            height: bbox.height + 2 * LABEL_BACKGROUND_PADDING_Y
                        })
                    } else {
                        textElement.attr({
                            text: ""
                        });
                        backgroundElement.attr({
                            x: 0,
                            y: 0,
                            width: 0,
                            height: 0
                        })
                    }
                })
            },
            hide: function() {
                this._crosshairGroup.attr({
                    visibility: "hidden"
                })
            },
            _updateLinesCanvas: function(position, labelPosition) {
                var coords = this._linesCanvas,
                    canvas = this._canvas;
                coords[position] = coords[position] !== canvas[position] && mathAbs(coords[position] - canvas[position]) < mathAbs(labelPosition - canvas[position]) ? coords[position] : labelPosition
            },
            _updateLines: function(lines, x, y, r, isHorizontal) {
                var coords = this._linesCanvas,
                    canvas = this._canvas,
                    points = isHorizontal ? [
                        [mathMin(x - r, coords.left), canvas.top, x - r, canvas.top],
                        [x + r, canvas.top, mathMax(coords.right, x + r), canvas.top]
                    ] : [
                        [canvas.left, mathMin(coords.top, y - r), canvas.left, y - r],
                        [canvas.left, y + r, canvas.left, mathMax(coords.bottom, y + r)]
                    ];
                for (var i = 0; i < 2; i++) {
                    lines[i].attr({
                        points: points[i]
                    })
                }
            },
            _resetLinesCanvas: function() {
                var canvas = this._canvas;
                this._linesCanvas = {
                    left: canvas.left,
                    right: canvas.right,
                    top: canvas.top,
                    bottom: canvas.bottom
                }
            },
            _getClipRectForPane: function(x, y) {
                var i, coords, panes = this._panes;
                for (i = 0; i < panes.length; i++) {
                    coords = panes[i].coords;
                    if (coords.left <= x && coords.right >= x && coords.top <= y && coords.bottom >= y) {
                        return panes[i].clipRect
                    }
                }
                return {
                    id: null
                }
            },
            show: function(data) {
                var clipRect, that = this,
                    point = data.point,
                    pointData = point.getCrosshairData(data.x, data.y),
                    r = point.getPointRadius(),
                    horizontal = that._horizontal,
                    vertical = that._vertical,
                    rad = !r ? 0 : r + 3,
                    canvas = that._canvas,
                    x = mathFloor(pointData.x),
                    y = mathFloor(pointData.y);
                if (x >= canvas.left && x <= canvas.right && y >= canvas.top && y <= canvas.bottom) {
                    that._crosshairGroup.attr({
                        visibility: "visible"
                    });
                    that._resetLinesCanvas();
                    clipRect = that._getClipRectForPane(x, y);
                    that._circle.attr({
                        cx: x,
                        cy: y,
                        r: rad,
                        clipId: clipRect.id
                    });
                    if (horizontal.lines) {
                        that._updateText(pointData.yValue, horizontal.labels, pointData.axis, point, true);
                        that._updateLines(horizontal.lines, x, y, rad, true);
                        that._horizontalGroup.attr({
                            translateY: y - canvas.top
                        })
                    }
                    if (vertical.lines) {
                        that._updateText(pointData.xValue, vertical.labels, pointData.axis, point, false);
                        that._updateLines(vertical.lines, x, y, rad, false);
                        that._verticalGroup.attr({
                            translateX: x - canvas.left
                        })
                    }
                } else {
                    that.hide()
                }
            }
        };
        exports.Crosshair = Crosshair
    },
    /*!**********************************!*\
      !*** ./Scripts/viz/pie_chart.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            errors = __webpack_require__( /*! ../core/errors */ 17),
            seriesConsts = __webpack_require__( /*! ./components/consts */ 462),
            vizUtils = __webpack_require__( /*! ./core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../core/utils/common */ 14),
            rangeModule = __webpack_require__( /*! ./translators/range */ 503),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            baseChartModule = __webpack_require__( /*! ./chart_components/base_chart */ 447),
            BaseChart = baseChartModule.BaseChart,
            overlapping = baseChartModule.overlapping,
            seriesSpacing = seriesConsts.pieSeriesSpacing,
            translator1DModule = __webpack_require__( /*! ./translators/translator1d */ 519),
            OPTIONS_FOR_REFRESH_SERIES = ["startAngle", "innerRadius", "segmentsDirection", "type"],
            _extend = $.extend,
            _each = $.each,
            _noop = $.noop,
            _getVerticallyShiftedAngularCoords = __webpack_require__( /*! ./core/utils */ 442).getVerticallyShiftedAngularCoords,
            states = seriesConsts.states,
            SELECTED_STATE = states.selectedMark,
            HOVER_STATE = states.hoverMark,
            HOVER = states.hover,
            NORMAL = states.normal,
            SELECTION = states.selection,
            APPLY_HOVER = states.applyHover,
            RESET_ITEM = states.resetItem;

        function AbstractSeries(index, points) {
            var that = this;
            that.index = index;
            that.fullState = 0;
            that._points = points;
            that._selectedPointsCount = 0;
            return that
        }
        AbstractSeries.prototype = {
            isHovered: function() {
                return !!(1 & this.fullState)
            },
            setHoverState: function(state, _, legendCallback) {
                var that = this;
                if (state && !that.isHovered()) {
                    that._changeStyle(legendCallback, APPLY_HOVER, HOVER);
                    that.fullState |= HOVER_STATE
                } else {
                    if (!state && that.isHovered()) {
                        that._changeStyle(legendCallback, RESET_ITEM, NORMAL);
                        that.fullState &= ~HOVER_STATE
                    }
                }
            },
            _changeStyle: function(legendCallback, legendAction, pointAction) {
                var that = this;
                !that._selectedPointsCount && legendCallback(legendAction);
                _each(that._points || [], function(_, p) {
                    !p.isSelected() && p.applyStyle(pointAction)
                })
            },
            setPointHoverState: function(data) {
                var point = data.point;
                point.fullState |= HOVER_STATE;
                if (!point.isSelected()) {
                    point.applyStyle(HOVER);
                    if (!this._selectedPointsCount) {
                        data.legendCallback(APPLY_HOVER)
                    }
                }
            },
            releasePointHoverState: function(data) {
                var point = data.point;
                point.fullState &= ~HOVER_STATE;
                if (!point.isSelected()) {
                    point.applyStyle(NORMAL);
                    if (!this._selectedPointsCount) {
                        data.legendCallback(RESET_ITEM)
                    }
                }
            },
            setPointSelectedState: function(data) {
                var that = this,
                    point = data.point;
                point.fullState |= SELECTED_STATE;
                point.applyStyle(SELECTION);
                !that._selectedPointsCount && data.legendCallback(states.applySelected);
                that._selectedPointsCount++
            },
            releasePointSelectedState: function(data) {
                var action, that = this,
                    point = data.point;
                point.fullState &= ~SELECTED_STATE;
                if (point.isHovered() || that.isHovered()) {
                    point.applyStyle(HOVER);
                    action = APPLY_HOVER
                } else {
                    point.applyStyle(NORMAL);
                    action = RESET_ITEM
                }
                that._selectedPointsCount--;
                !that._selectedPointsCount && data.legendCallback(action)
            }
        };
        var dxPieChart = BaseChart.inherit({
            _setDeprecatedOptions: function() {
                this.callBase.apply(this, arguments);
                _extend(this._deprecatedOptions, {
                    "series.innerRadius": {
                        since: "15.2",
                        message: "Use the 'innerRadius' option instead"
                    },
                    "series.startAngle": {
                        since: "15.2",
                        message: "Use the 'startAngle' option instead"
                    },
                    "series.segmentsDirection": {
                        since: "15.2",
                        message: "Use the 'segmentsDirection' option instead"
                    },
                    "series.type": {
                        since: "15.2",
                        message: "Use the 'type' option instead"
                    }
                })
            },
            _chartType: "pie",
            _layoutManagerOptions: function() {
                var diameter = this._themeManager.getOptions("diameter");
                if (commonUtils.isNumber(diameter)) {
                    if (diameter > 1) {
                        diameter = 1
                    } else {
                        if (diameter < 0) {
                            diameter = 0
                        }
                    }
                } else {
                    diameter = void 0
                }
                return _extend(true, {}, this.callBase(), {
                    piePercentage: diameter
                })
            },
            _optionChangesMap: {
                diameter: "REINIT"
            },
            _groupSeries: function() {
                var series = this.series;
                this._groupsData = {
                    groups: [{
                        series: series,
                        valueOptions: {
                            valueType: "numeric"
                        }
                    }],
                    argumentOptions: series[0] && series[0].getOptions()
                }
            },
            _populateBusinessRange: function() {
                var singleSeriesRange, businessRanges = [],
                    series = this.series;
                this.businessRanges = null;
                _each(series, function(_, singleSeries) {
                    var range = new rangeModule.Range;
                    singleSeriesRange = singleSeries.getRangeData();
                    range.addRange(singleSeriesRange.val);
                    if (!range.isDefined()) {
                        range.setStubData()
                    }
                    businessRanges.push(range)
                });
                this.businessRanges = businessRanges
            },
            _specialProcessSeries: function() {
                _each(this.series, function(_, singleSeries) {
                    singleSeries.arrangePoints()
                })
            },
            _createTranslator: function(range) {
                return (new translator1DModule.Translator1D).setDomain(range.min, range.max).setCodomain(360, 0)
            },
            _checkPaneName: function() {
                return true
            },
            _processSingleSeries: function(singleSeries) {
                singleSeries.arrangePoints()
            },
            _collectPointsByArg: function() {
                var itemIndex, that = this,
                    points = {},
                    args = {},
                    index = 0;
                _each(that.series, function(_, singleSeries) {
                    var count, arrayArguments = {};
                    _each(singleSeries.getPoints(), function(_, point) {
                        var argument = point.argument;
                        arrayArguments[argument] = ++arrayArguments[argument] || 0;
                        count = arrayArguments[argument];
                        itemIndex = args[argument + count];
                        if (void 0 === itemIndex) {
                            point.index = args[argument + count] = index;
                            points[index] = [point];
                            index++
                        } else {
                            point.index = itemIndex;
                            points[itemIndex].push(point)
                        }
                    })
                });
                that._collectionPointsArg = points
            },
            _getLegendTargets: function() {
                var that = this,
                    points = [];
                _each(that._collectionPointsArg, function(_, id) {
                    _each(id, function(i, point) {
                        if (0 === i) {
                            points.push(that._getLegendOptions(point))
                        } else {
                            if (!points[points.length - 1].visible) {
                                points[points.length - 1].visible = point.isVisible()
                            }
                        }
                    })
                });
                return points
            },
            _getAxisDrawingMethods: _noop,
            _getLayoutTargets: function() {
                return [{
                    canvas: this._canvas
                }]
            },
            _getAxesForTransform: function() {
                return {
                    verticalAxes: [],
                    horizontalAxes: []
                }
            },
            _getLayoutSeries: function(series, drawOptions) {
                var layout, that = this,
                    canvas = that._canvas,
                    drawnLabels = false;
                layout = that.layoutManager.applyPieChartSeriesLayout(canvas, series, true);
                _each(series, function(i, singleSeries) {
                    singleSeries.correctPosition(layout);
                    drawnLabels = singleSeries.drawLabelsWOPoints(that._createTranslator(that.businessRanges[i])) || drawnLabels
                });
                if (drawnLabels) {
                    layout = that.layoutManager.applyPieChartSeriesLayout(canvas, series, drawOptions.hideLayoutLabels)
                }
                return layout
            },
            _updateSeriesDimensions: function(drawOptions) {
                var innerRad, delta, layout, that = this,
                    visibleSeries = that._getVisibleSeries(),
                    lengthVisibleSeries = visibleSeries.length;
                if (lengthVisibleSeries) {
                    layout = that._getLayoutSeries(visibleSeries, drawOptions);
                    delta = (layout.radiusOuter - layout.radiusInner - seriesSpacing * (lengthVisibleSeries - 1)) / lengthVisibleSeries;
                    innerRad = layout.radiusInner;
                    that._setCenter({
                        x: layout.centerX,
                        y: layout.centerY
                    });
                    _each(visibleSeries, function(_, singleSeries) {
                        singleSeries.correctRadius({
                            radiusInner: innerRad,
                            radiusOuter: innerRad + delta
                        });
                        innerRad += delta + seriesSpacing
                    })
                }
            },
            _prepareTranslators: function(_, i) {
                return this._createTranslator(this.businessRanges[i])
            },
            _getLegendCallBack: function() {
                var legend = this._legend;
                return function(point) {
                    return legend.getActionCallback(point)
                }
            },
            _adjustSeries: function() {
                _each(this.series, function(_, singleSeries) {
                    singleSeries.adjustLabels()
                })
            },
            _prepareStackPoints: _noop,
            _resetStackPoints: _noop,
            _applyExtraSettings: _noop,
            _resolveLabelOverlappingShift: function() {
                var that = this,
                    series = that.series,
                    center = that._center;
                _each(series, function(_, singleSeries) {
                    if ("inside" === singleSeries.getOptions().label.position) {
                        return
                    }
                    var points = singleSeries.getVisiblePoints(),
                        lPoints = [],
                        rPoints = [];
                    $.each(points, function(_, point) {
                        var angle = vizUtils.normalizeAngle(point.middleAngle);
                        (angle <= 90 || angle >= 270 ? rPoints : lPoints).push(point)
                    });
                    overlapping.resolveLabelOverlappingInOneDirection(lPoints, that._canvas, false, shiftFunction);
                    overlapping.resolveLabelOverlappingInOneDirection(rPoints, that._canvas, false, shiftFunction)
                });

                function shiftFunction(box, length) {
                    return _getVerticallyShiftedAngularCoords(box, -length, center)
                }
            },
            _setCenter: function(center) {
                this._center = center
            },
            _getStoredSeries: function() {
                var abstractSeries = this._abstractSeries;
                if (!abstractSeries) {
                    abstractSeries = this._abstractSeries = []
                } else {
                    abstractSeries.splice(0, abstractSeries.length)
                }
                _each(this._collectionPointsArg, function(i, points) {
                    abstractSeries.push(new AbstractSeries(i, points))
                });
                return abstractSeries
            },
            _disposeSeries: function() {
                this.callBase.apply(this, arguments);
                this._abstractSeries = null
            },
            getSeries: function() {
                errors.log("W0002", "dxPieChart", "getSeries", "15.2", "Use the 'getAllSeries' method instead");
                return this.series[0]
            },
            _legendDataField: "point",
            _legendItemTextField: "argument",
            _updateLegendPosition: _noop,
            _renderTrackers: _noop,
            _trackerType: "PieTracker",
            _createScrollBar: _noop,
            _updateAxesLayout: _noop,
            _applyClipRects: _noop,
            _appendAdditionalSeriesGroups: _noop,
            _prepareToRender: _noop,
            _isLegendInside: _noop,
            _renderAxes: _noop,
            _isRotated: _noop,
            _seriesPopulatedHandlerCore: _noop,
            _reinitAxes: _noop,
            _correctAxes: _noop,
            _getExtraOptions: function() {
                var that = this;
                return {
                    startAngle: that.option("startAngle"),
                    innerRadius: that.option("innerRadius"),
                    segmentsDirection: that.option("segmentsDirection"),
                    type: that.option("type")
                }
            }
        });
        _each(OPTIONS_FOR_REFRESH_SERIES, function(_, name) {
            dxPieChart.prototype._optionChangesMap[name] = "REFRESH_SERIES_DATA_INIT"
        });
        registerComponent("dxPieChart", dxPieChart);
        module.exports = dxPieChart
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/translators/translator1d.js ***!
      \*************************************************/
    function(module, exports) {
        var _Number = Number;

        function Translator1D() {
            this.setDomain(arguments[0], arguments[1]).setCodomain(arguments[2], arguments[3])
        }
        Translator1D.prototype = {
            constructor: Translator1D,
            setDomain: function(domain1, domain2) {
                var that = this;
                that._domain1 = _Number(domain1);
                that._domain2 = _Number(domain2);
                that._domainDelta = that._domain2 - that._domain1;
                return that
            },
            setCodomain: function(codomain1, codomain2) {
                var that = this;
                that._codomain1 = _Number(codomain1);
                that._codomain2 = _Number(codomain2);
                that._codomainDelta = that._codomain2 - that._codomain1;
                return that
            },
            getDomain: function() {
                return [this._domain1, this._domain2]
            },
            getCodomain: function() {
                return [this._codomain1, this._codomain2]
            },
            getDomainStart: function() {
                return this._domain1
            },
            getDomainEnd: function() {
                return this._domain2
            },
            getCodomainStart: function() {
                return this._codomain1
            },
            getCodomainEnd: function() {
                return this._codomain2
            },
            getDomainRange: function() {
                return this._domainDelta
            },
            getCodomainRange: function() {
                return this._codomainDelta
            },
            translate: function(value) {
                var ratio = (_Number(value) - this._domain1) / this._domainDelta;
                return 0 <= ratio && ratio <= 1 ? this._codomain1 + ratio * this._codomainDelta : NaN
            },
            adjust: function(value) {
                var ratio = (_Number(value) - this._domain1) / this._domainDelta,
                    result = NaN;
                if (ratio < 0) {
                    result = this._domain1
                } else {
                    if (ratio > 1) {
                        result = this._domain2
                    } else {
                        if (0 <= ratio && ratio <= 1) {
                            result = _Number(value)
                        }
                    }
                }
                return result
            }
        };
        exports.Translator1D = Translator1D
    },
    /*!************************************!*\
      !*** ./Scripts/viz/polar_chart.js ***!
      \************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../core/component_registrator */ 43),
            vizUtils = __webpack_require__( /*! ./core/utils */ 442),
            polarTranslatorModule = __webpack_require__( /*! ./translators/polar_translator */ 521),
            rangeModule = __webpack_require__( /*! ./translators/range */ 503),
            AdvancedChart = __webpack_require__( /*! ./chart_components/advanced_chart */ 505).AdvancedChart,
            _noop = $.noop,
            DEFAULT_PANE_NAME = "default";
        var dxPolarChart = AdvancedChart.inherit({
            _chartType: "polar",
            _createPanes: function() {
                return [{
                    name: DEFAULT_PANE_NAME
                }]
            },
            _checkPaneName: function() {
                return true
            },
            _getAxisRenderingOptions: function(typeSelector) {
                var isArgumentAxis = "argumentAxis" === typeSelector,
                    type = isArgumentAxis ? "circular" : "linear",
                    useSpiderWeb = this.option("useSpiderWeb");
                if (useSpiderWeb) {
                    type += "Spider"
                }
                return {
                    axisType: "polarAxes",
                    drawingType: type
                }
            },
            _prepareAxisOptions: function(typeSelector, axisOptions) {
                var isArgumentAxis = "argumentAxis" === typeSelector;
                return {
                    type: this.option("useSpiderWeb") && isArgumentAxis ? "discrete" : axisOptions.type,
                    isHorizontal: true,
                    showCustomBoundaryTicks: isArgumentAxis
                }
            },
            _optionChangesMap: {
                useSpiderWeb: "REINIT"
            },
            _getExtraOptions: function() {
                return {
                    spiderWidget: this.option("useSpiderWeb")
                }
            },
            _groupSeries: function() {
                var that = this;
                that._groupsData = {
                    groups: [{
                        series: that.series,
                        valueAxis: that._valueAxes[0],
                        valueOptions: that._valueAxes[0].getOptions()
                    }],
                    argumentAxes: that._argumentAxes,
                    argumentOptions: that._argumentAxes[0].getOptions()
                }
            },
            _prepareToRender: function() {
                this._appendAxesGroups();
                return {}
            },
            _renderAxes: function(drawOptions, _, __, adjustUnits) {
                this._drawAxes({}, drawOptions, adjustUnits)
            },
            _getAxisDrawingMethods: function(drawOptions, preparedOptions, isRotated, adjustUnits) {
                var that = this;
                return function() {
                    that._renderAxes(drawOptions, preparedOptions, isRotated, adjustUnits)
                }
            },
            _reinitTranslators: function() {
                var that = this,
                    valueAxes = that._valueAxes,
                    argumentAxes = that._argumentAxes,
                    translator = that._createTranslator({
                        arg: new rangeModule.Range(that.businessRanges[0].arg),
                        val: new rangeModule.Range(that.businessRanges[0].val)
                    }),
                    argTranslator = translator.getComponent("arg"),
                    valTranslator = translator.getComponent("val"),
                    i = 0;
                that.translator = translator;
                argumentAxes[0].setTranslator(argTranslator, valTranslator);
                for (i; i < valueAxes.length; i++) {
                    valueAxes[i].setTranslator(valTranslator, argTranslator)
                }
            },
            _prepareAxesAndDraw: function(drawAxes, drawStaticAxisElements) {
                var that = this,
                    valueAxes = that._valueAxes,
                    argAxes = that._argumentAxes,
                    argumentAxis = argAxes[0];
                that._calcCanvas(argumentAxis.measureLabels(true));
                that.translator.reinit();
                drawAxes(argAxes);
                $.each(valueAxes, function(_, valAxis) {
                    valAxis.setSpiderTicks(argumentAxis.getSpiderTicks())
                });
                drawAxes(valueAxes);
                drawStaticAxisElements(argAxes);
                drawStaticAxisElements(valueAxes)
            },
            _calcCanvas: function(measure) {
                var canvas = this.translator.canvas;
                canvas.left += measure.width;
                canvas.right += measure.width;
                canvas.top += measure.height;
                canvas.bottom += measure.height
            },
            _getLayoutTargets: function() {
                return [{
                    canvas: this._canvas
                }]
            },
            _getAxesForTransform: function() {
                var argAxes = this._getArgumentAxes();
                return {
                    verticalAxes: argAxes,
                    horizontalAxes: argAxes
                }
            },
            _getTranslator: function() {
                var translator = this.translator;
                return {
                    val: translator,
                    arg: translator
                }
            },
            _prepareTranslators: function() {
                return this.translator
            },
            _createTranslator: function(br) {
                var themeManager = this._themeManager,
                    axisUserOptions = this.option("argumentAxis"),
                    axisOptions = themeManager.getOptions("argumentAxis", axisUserOptions) || {},
                    startAngle = isFinite(axisOptions.startAngle) ? vizUtils.normalizeAngle(axisOptions.startAngle) : 0;
                return new polarTranslatorModule.PolarTranslator(br, $.extend(true, {}, this._canvas), {
                    startAngle: startAngle,
                    endAngle: startAngle + 360
                })
            },
            _getSeriesForPane: function() {
                return this.series
            },
            _applyExtraSettings: _noop,
            _updateLegendPosition: _noop,
            _createScrollBar: _noop,
            _applyClipRects: _noop,
            _isRotated: _noop,
            _getCrosshairOptions: _noop,
            _isLegendInside: _noop,
            _processSingleSeries: _noop
        });
        registerComponent("dxPolarChart", dxPolarChart);
        module.exports = dxPolarChart
    },
    /*!*****************************************************!*\
      !*** ./Scripts/viz/translators/polar_translator.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            translator2DModule = __webpack_require__( /*! ./translator2d */ 497),
            SHIFT_ANGLE = 90,
            _round = Math.round;

        function PolarTranslator(businessRange, canvas, options) {
            var that = this;
            that._startAngle = options.startAngle;
            that._endAngle = options.endAngle;
            that._argCanvas = {
                left: 0,
                right: 0,
                width: this._getAngle()
            };
            that._valCanvas = {
                left: 0,
                right: 0
            };
            that.canvas = $.extend({}, canvas);
            that._init();
            that._arg = new translator2DModule.Translator2D(businessRange.arg, that._argCanvas, {
                isHorizontal: true,
                conversionValue: true
            });
            that._val = new translator2DModule.Translator2D(businessRange.val, that._valCanvas, {
                isHorizontal: true
            });
            that._businessRange = businessRange
        }
        PolarTranslator.prototype = {
            constructor: PolarTranslator,
            _init: function() {
                var canvas = this.canvas;
                this._setCoords({
                    x: canvas.left + (canvas.width - canvas.right - canvas.left) / 2,
                    y: canvas.top + (canvas.height - canvas.top - canvas.bottom) / 2,
                    r: Math.min(canvas.width - canvas.left - canvas.right, canvas.height - canvas.top - canvas.bottom) / 2
                });
                this._valCanvas.width = this._rad
            },
            reinit: function() {
                this._init();
                this._arg.reinit();
                this._val.reinit()
            },
            _setCoords: function(coord) {
                this._x0 = coord.x;
                this._y0 = coord.y;
                this._rad = coord.r < 0 ? 0 : coord.r
            },
            getBusinessRange: function() {
                return this._businessRange
            },
            translate: function(arg, val, offsets) {
                var x, y, that = this,
                    argTranslate = that._arg.translate(arg, offsets && offsets[0]),
                    radius = that._val.translate(val, offsets && offsets[1]),
                    angle = commonUtils.isDefined(argTranslate) ? argTranslate + that._startAngle - SHIFT_ANGLE : null,
                    cossin = vizUtils.getCosAndSin(angle);
                y = _round(that._y0 + radius * cossin.sin);
                x = _round(that._x0 + radius * cossin.cos);
                return {
                    x: x,
                    y: y,
                    angle: angle,
                    radius: radius
                }
            },
            setCanvasDimension: function(dimension) {
                this.canvas.width = this.canvas.height = dimension;
                this.reinit()
            },
            setAngles: function(startAngle, endAngle) {
                var that = this;
                that._startAngle = startAngle;
                that._endAngle = endAngle;
                that._argCanvas.width = that._getAngle();
                that._arg.update(that._arg.getBusinessRange(), that._argCanvas)
            },
            getAngles: function() {
                return [this._startAngle, this._endAngle]
            },
            getValLength: function() {
                return this._rad
            },
            getCenter: function() {
                return {
                    x: this._x0,
                    y: this._y0
                }
            },
            getBaseAngle: function() {
                return this._startAngle - SHIFT_ANGLE
            },
            getInterval: function() {
                return this._arg.getInterval()
            },
            getValInterval: function() {
                return this._val.getInterval()
            },
            _getAngle: function() {
                return Math.abs(this._endAngle - this._startAngle)
            },
            getComponent: function(type) {
                var that = this,
                    translator = this["_" + type];
                translator.getRadius = function() {
                    return that.getValLength()
                };
                translator.getCenter = function() {
                    return that.getCenter()
                };
                translator.getAngles = function() {
                    return that.getAngles()
                };
                return translator
            },
            _untranslate: function(x, y) {
                var radius = vizUtils.getDistance(this._x0, this._y0, x, y),
                    angle = Math.atan2(y - this._y0, x - this._x0);
                return {
                    r: radius,
                    phi: angle
                }
            },
            untranslate: function(x, y) {
                var pos = this._untranslate(x, y);
                pos.phi = _round(vizUtils.normalizeAngle(180 * pos.phi / Math.PI));
                pos.r = _round(pos.r);
                return pos
            },
            getVisibleCategories: $.noop,
            getCanvasVisibleArea: function() {
                return {}
            },
            getMinBarSize: function(minBarSize) {
                return this._val.getMinBarSize(minBarSize)
            }
        };
        exports.PolarTranslator = PolarTranslator
    },
    /*!*************************************!*\
      !*** ./Scripts/viz/linear_gauge.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./gauges/linear_gauge */ 523)
    },
    /*!********************************************!*\
      !*** ./Scripts/viz/gauges/linear_gauge.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _max = Math.max,
            _min = Math.min,
            _round = Math.round,
            _each = $.each,
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            dxBaseGauge = __webpack_require__( /*! ./base_gauge */ 524).dxBaseGauge,
            dxGauge = __webpack_require__( /*! ./common */ 526).dxGauge,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            translator2DModule = __webpack_require__( /*! ../translators/translator2d */ 497),
            linearIndicatorsModule = __webpack_require__( /*! ./linear_indicators */ 527),
            createIndicatorCreator = __webpack_require__( /*! ./common */ 526).createIndicatorCreator,
            LinearRangeContainer = __webpack_require__( /*! ./linear_range_container */ 529),
            ThemeManager = __webpack_require__( /*! ./theme_manager */ 531);
        var dxLinearGauge = dxGauge.inherit({
            _rootClass: "dxg-linear-gauge",
            _factoryMethods: {
                rangeContainer: "createLinearRangeContainer",
                indicator: "createLinearIndicator"
            },
            _gridSpacingFactor: 25,
            _scaleTypes: {
                type: "xyAxes",
                drawingType: "linear"
            },
            _initScaleTranslator: function(range) {
                var canvas = $.extend({}, this._canvas);
                return {
                    val: new translator2DModule.Translator2D(range, canvas),
                    arg: new translator2DModule.Translator2D(range, canvas, {
                        isHorizontal: true
                    })
                }
            },
            _getScaleTranslatorComponent: function(name) {
                return this._scaleTranslator["arg" === name !== this._area.vertical ? "arg" : "val"]
            },
            _updateScaleAngles: $.noop,
            _getTicksOrientation: function(scaleOptions) {
                return scaleOptions.isHorizontal ? scaleOptions.verticalOrientation : scaleOptions.horizontalOrientation
            },
            _updateScaleTickIndent: function(scaleOptions) {
                var orientation, textCorrection, tickCorrection, indentFromTick = scaleOptions.label.indentFromTick,
                    length = scaleOptions.tick.length,
                    textParams = this._scale.measureLabels(),
                    verticalTextCorrection = scaleOptions.isHorizontal ? textParams.height + textParams.y : 0,
                    isIndentPositive = indentFromTick > 0;
                if (scaleOptions.isHorizontal) {
                    orientation = isIndentPositive ? {
                        center: .5,
                        middle: .5,
                        top: 0,
                        bottom: 1
                    } : {
                        center: .5,
                        middle: .5,
                        top: 1,
                        bottom: 0
                    };
                    tickCorrection = length * orientation[scaleOptions.verticalOrientation];
                    textCorrection = textParams.y
                } else {
                    orientation = isIndentPositive ? {
                        center: .5,
                        left: 0,
                        right: 1
                    } : {
                        center: .5,
                        left: 1,
                        right: 0
                    };
                    tickCorrection = length * orientation[scaleOptions.horizontalOrientation];
                    textCorrection = -textParams.width
                }
                scaleOptions.label.indentFromAxis = -indentFromTick + (isIndentPositive ? -tickCorrection + textCorrection : tickCorrection - verticalTextCorrection);
                this._scale.updateOptions(scaleOptions)
            },
            _shiftScale: function(layout, scaleOptions) {
                var that = this,
                    canvas = $.extend({}, that._canvas),
                    isHorizontal = scaleOptions.isHorizontal,
                    translator = that._getScaleTranslatorComponent("arg"),
                    additionalTranslator = that._getScaleTranslatorComponent("val"),
                    scale = that._scale;
                canvas[isHorizontal ? "left" : "top"] = that._area[isHorizontal ? "startCoord" : "endCoord"];
                canvas[isHorizontal ? "right" : "bottom"] = canvas[isHorizontal ? "width" : "height"] - that._area[isHorizontal ? "endCoord" : "startCoord"];
                translator.updateCanvas(canvas);
                additionalTranslator.updateCanvas(canvas);
                scale.setTranslator(translator, additionalTranslator);
                scale.draw();
                scale.shift(layout.x, layout.y)
            },
            _setupCodomain: function() {
                var that = this,
                    geometry = that.option("geometry") || {},
                    vertical = "vertical" === _normalizeEnum(geometry.orientation);
                that._area = {
                    vertical: vertical,
                    x: 0,
                    y: 0,
                    startCoord: -100,
                    endCoord: 100
                };
                that._rangeContainer.vertical = vertical
            },
            _getScaleLayoutValue: function() {
                return this._area[this._area.vertical ? "x" : "y"]
            },
            _getTicksCoefficients: function(options) {
                var coefs = {
                    inner: 0,
                    outer: 1
                };
                if (this._area.vertical) {
                    if ("left" === options.horizontalOrientation) {
                        coefs.inner = 1;
                        coefs.outer = 0
                    } else {
                        if ("center" === options.horizontalOrientation) {
                            coefs.inner = coefs.outer = .5
                        }
                    }
                } else {
                    if ("top" === options.verticalOrientation) {
                        coefs.inner = 1;
                        coefs.outer = 0
                    } else {
                        if ("center" === options.verticalOrientation || "middle" === options.verticalOrientation) {
                            coefs.inner = coefs.outer = .5
                        }
                    }
                }
                return coefs
            },
            _correctScaleIndents: function(result, indentFromTick, textParams) {
                var vertical = this._area.vertical;
                if (indentFromTick >= 0) {
                    result.max += indentFromTick + textParams[vertical ? "width" : "height"]
                } else {
                    result.min -= -indentFromTick + textParams[vertical ? "width" : "height"]
                }
                result.indent = textParams[vertical ? "height" : "width"] / 2
            },
            _measureMainElements: function(elements, scaleMeasurement) {
                var that = this,
                    x = that._area.x,
                    y = that._area.y,
                    minBound = 1e3,
                    maxBound = 0,
                    indent = 0,
                    scale = that._scale;
                _each(elements.concat(scale), function(_, element) {
                    var bounds = element.measure ? element.measure({
                        x: x + element.getOffset(),
                        y: y + element.getOffset()
                    }) : scaleMeasurement;
                    void 0 !== bounds.max && (maxBound = _max(maxBound, bounds.max));
                    void 0 !== bounds.min && (minBound = _min(minBound, bounds.min));
                    bounds.indent > 0 && (indent = _max(indent, bounds.indent))
                });
                return {
                    minBound: minBound,
                    maxBound: maxBound,
                    indent: indent
                }
            },
            _applyMainLayout: function(elements, scaleMeasurement) {
                var rect, offset, that = this,
                    measurements = that._measureMainElements(elements, scaleMeasurement),
                    area = that._area;
                if (area.vertical) {
                    rect = selectRectBySizes(that._innerRect, {
                        width: measurements.maxBound - measurements.minBound
                    });
                    offset = (rect.left + rect.right) / 2 - (measurements.minBound + measurements.maxBound) / 2;
                    area.startCoord = rect.bottom - measurements.indent;
                    area.endCoord = rect.top + measurements.indent;
                    area.x = _round(area.x + offset)
                } else {
                    rect = selectRectBySizes(that._innerRect, {
                        height: measurements.maxBound - measurements.minBound
                    });
                    offset = (rect.top + rect.bottom) / 2 - (measurements.minBound + measurements.maxBound) / 2;
                    area.startCoord = rect.left + measurements.indent;
                    area.endCoord = rect.right - measurements.indent;
                    area.y = _round(area.y + offset)
                }
                that._translator.setCodomain(area.startCoord, area.endCoord);
                that._innerRect = rect
            },
            _getElementLayout: function(offset) {
                return {
                    x: _round(this._area.x + offset),
                    y: _round(this._area.y + offset)
                }
            },
            _getApproximateScreenRange: function() {
                var that = this,
                    area = that._area,
                    s = area.vertical ? that._canvas.height : that._canvas.width;
                s > area.totalSize && (s = area.totalSize);
                s = .8 * s;
                return s
            },
            _getDefaultSize: function() {
                var geometry = this.option("geometry") || {};
                if ("vertical" === geometry.orientation) {
                    return {
                        width: 100,
                        height: 300
                    }
                } else {
                    return {
                        width: 300,
                        height: 100
                    }
                }
            },
            _factory: objectUtils.clone(dxBaseGauge.prototype._factory)
        });

        function selectRectBySizes(srcRect, sizes, margins) {
            var step, rect = $.extend({}, srcRect);
            margins = margins || {};
            if (sizes) {
                rect.left += margins.left || 0;
                rect.right -= margins.right || 0;
                rect.top += margins.top || 0;
                rect.bottom -= margins.bottom || 0;
                if (sizes.width > 0) {
                    step = (rect.right - rect.left - sizes.width) / 2;
                    if (step > 0) {
                        rect.left += step;
                        rect.right -= step
                    }
                }
                if (sizes.height > 0) {
                    step = (rect.bottom - rect.top - sizes.height) / 2;
                    if (step > 0) {
                        rect.top += step;
                        rect.bottom -= step
                    }
                }
            }
            return rect
        }
        dxLinearGauge._TESTS_selectRectBySizes = selectRectBySizes;
        var indicators = dxLinearGauge.prototype._factory.indicators = {};
        dxLinearGauge.prototype._factory.createIndicator = createIndicatorCreator(indicators);
        indicators._default = linearIndicatorsModule._default;
        indicators.rectangle = linearIndicatorsModule.rectangle;
        indicators.rhombus = linearIndicatorsModule.rhombus;
        indicators.circle = linearIndicatorsModule.circle;
        indicators.trianglemarker = linearIndicatorsModule.trianglemarker;
        indicators.textcloud = linearIndicatorsModule.textcloud;
        indicators.rangebar = linearIndicatorsModule.rangebar;
        dxLinearGauge.prototype._factory.RangeContainer = LinearRangeContainer;
        dxLinearGauge.prototype._factory.ThemeManager = ThemeManager.inherit({
            _subTheme: "_linear"
        });
        registerComponent("dxLinearGauge", dxLinearGauge);
        module.exports = dxLinearGauge
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/gauges/base_gauge.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _Number = Number,
            _getAppropriateFormat = __webpack_require__( /*! ../core/utils */ 442).getAppropriateFormat,
            translator1DModule = __webpack_require__( /*! ../translators/translator1d */ 519),
            _extend = $.extend,
            BaseWidget = __webpack_require__( /*! ../core/base_widget */ 448),
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            Tracker = __webpack_require__( /*! ./tracker */ 525),
            _isString = commonUtils.isString;
        var dxBaseGauge = BaseWidget.inherit({
            _rootClassPrefix: "dxg",
            _createThemeManager: function() {
                return new this._factory.ThemeManager
            },
            _setDeprecatedOptions: function() {
                this.callBase();
                _extend(this._deprecatedOptions, {
                    subtitle: {
                        since: "15.2",
                        message: "Use the 'title.subtitle' option instead"
                    },
                    "title.position": {
                        since: "15.2",
                        message: "Use the 'verticalAlignment' and 'horizontalAlignment' options instead"
                    },
                    "scale.hideFirstTick": {
                        since: "15.2",
                        message: "The functionality is not more available"
                    },
                    "scale.hideLastTick": {
                        since: "15.2",
                        message: "The functionality is not more available"
                    },
                    "scale.hideFirstLabel": {
                        since: "15.2",
                        message: "The functionality is not more available"
                    },
                    "scale.hideLastLabel": {
                        since: "15.2",
                        message: "The functionality is not more available"
                    },
                    "scale.majorTick": {
                        since: "15.2",
                        message: "Use the 'tick' option instead"
                    },
                    "scale.minorTick.showCalculatedTicks": {
                        since: "15.2",
                        message: "The functionality is not more available"
                    },
                    "scale.minorTick.customTickValues": {
                        since: "15.2",
                        message: "Use the 'customMinorTicks' option instead"
                    },
                    "scale.minorTick.tickInterval": {
                        since: "15.2",
                        message: "Use the 'minorTickInterval' option instead"
                    }
                })
            },
            _initCore: function() {
                var that = this,
                    root = that._renderer.root;
                that._valueChangingLocker = 0;
                that._translator = that._factory.createTranslator();
                that._initDeltaIndicator();
                that._tracker = that._factory.createTracker({
                    renderer: that._renderer,
                    container: root
                });
                that._setTrackerCallbacks()
            },
            _beginValueChanging: function() {
                this._resetIsReady();
                ++this._valueChangingLocker
            },
            _endValueChanging: function() {
                if (0 === --this._valueChangingLocker) {
                    this._drawn()
                }
            },
            _initDeltaIndicator: function() {
                var that = this,
                    DeltaIndicator = that._DeltaIndicator;
                if (DeltaIndicator) {
                    that._deltaIndicator = new DeltaIndicator({
                        renderer: that._renderer,
                        container: that._renderer.root
                    });
                    that._deltaIndicator.layoutOptions = function() {
                        this.clean();
                        this.draw(that._getOption("indicator"));
                        var options = this.getLayoutOptions();
                        this._size = options ? [options.width, options.height] : null;
                        return options && {
                            horizontalAlignment: options.horizontalAlignment || "center",
                            verticalAlignment: options.verticalAlignment || "bottom"
                        }
                    };
                    that._deltaIndicator.measure = function() {
                        return this._size
                    };
                    that._deltaIndicator.move = function(rect) {
                        return this.shift(Math.round(rect[0]), Math.round(rect[1]))
                    };
                    that._layout.add(that._deltaIndicator)
                }
            },
            _disposeDeltaIndicator: function() {
                if (this._deltaIndicator) {
                    this._deltaIndicator.clean();
                    this._deltaIndicator.dispose()
                }
            },
            _setTrackerCallbacks: function() {
                var that = this,
                    renderer = that._renderer,
                    tooltip = that._tooltip;
                that._tracker.setCallbacks({
                    "tooltip-show": function(target, info) {
                        var tooltipParameters = target.getTooltipParameters(),
                            offset = renderer.getRootOffset(),
                            formatObject = _extend({
                                value: tooltipParameters.value,
                                valueText: tooltip.formatValue(tooltipParameters.value),
                                color: tooltipParameters.color
                            }, info);
                        return tooltip.show(formatObject, {
                            x: tooltipParameters.x + offset.left,
                            y: tooltipParameters.y + offset.top,
                            offset: tooltipParameters.offset
                        }, {
                            target: info
                        })
                    },
                    "tooltip-hide": function() {
                        return tooltip.hide()
                    }
                });
                that._resetTrackerCallbacks = function() {
                    that._resetTrackerCallbacks = that = renderer = tooltip = null
                }
            },
            _dispose: function() {
                this._cleanCore();
                this.callBase.apply(this, arguments)
            },
            _disposeCore: function() {
                var that = this;
                that._themeManager.dispose();
                that._tracker.dispose();
                that._disposeDeltaIndicator();
                that._translator = that._tracker = null
            },
            _cleanCore: function() {
                var that = this;
                that._tracker.deactivate();
                that._cleanContent()
            },
            _renderCore: function() {
                var that = this;
                if (!that._isValidDomain) {
                    return
                }
                that._renderContent();
                that._tracker.setTooltipState(that._tooltip.isEnabled());
                that._tracker.activate();
                that._noAnimation = false;
                that._debug_rendered && that._debug_rendered()
            },
            _applyChanges: function() {
                this.callBase.apply(this, arguments);
                this._resizing = this._noAnimation = false
            },
            _setContentSize: function() {
                var that = this;
                that._resizing = that._noAnimation = 2 === that._changes.count();
                that.callBase.apply(that, arguments)
            },
            _applySize: function(rect) {
                var that = this;
                that._DEBUG_rootRect = rect;
                that._innerRect = {
                    left: rect[0],
                    top: rect[1],
                    right: rect[2],
                    bottom: rect[3]
                };
                var layoutCache = that._layout._cache;
                that._cleanCore();
                that._renderCore();
                that._layout._cache = that._layout._cache || layoutCache;
                return [rect[0], that._innerRect.top, rect[2], that._innerRect.bottom]
            },
            _initialChanges: ["DOMAIN"],
            _themeDependentChanges: ["DOMAIN"],
            _optionChangesMap: {
                subtitle: "MOSTLY_TOTAL",
                indicator: "MOSTLY_TOTAL",
                geometry: "MOSTLY_TOTAL",
                animation: "MOSTLY_TOTAL",
                startValue: "DOMAIN",
                endValue: "DOMAIN"
            },
            _optionChangesOrder: ["DOMAIN", "MOSTLY_TOTAL"],
            _change_DOMAIN: function() {
                this._setupDomain()
            },
            _change_MOSTLY_TOTAL: function() {
                this._applyMostlyTotalChange()
            },
            _setupDomain: function() {
                var that = this;
                that._setupDomainCore();
                that._isValidDomain = isFinite(1 / (that._translator.getDomain()[1] - that._translator.getDomain()[0]));
                if (!that._isValidDomain) {
                    that._incidentOccurred("W2301")
                }
                that._change(["MOSTLY_TOTAL"])
            },
            _applyMostlyTotalChange: function() {
                var that = this;
                that._setupCodomain();
                that._setupAnimationSettings();
                that._setupDefaultFormat();
                that._change(["LAYOUT"])
            },
            _setupAnimationSettings: function() {
                var that = this,
                    option = that.option("animation");
                that._animationSettings = null;
                if (void 0 === option || option) {
                    option = _extend({
                        enabled: true,
                        duration: 1e3,
                        easing: "easeOutCubic"
                    }, option);
                    if (option.enabled && option.duration > 0) {
                        that._animationSettings = {
                            duration: _Number(option.duration),
                            easing: option.easing
                        }
                    }
                }
                that._containerBackgroundColor = that.option("containerBackgroundColor") || that._themeManager.theme().containerBackgroundColor
            },
            _setupDefaultFormat: function() {
                var domain = this._translator.getDomain();
                this._defaultFormatOptions = _getAppropriateFormat(domain[0], domain[1], this._getApproximateScreenRange())
            },
            _setupDomainCore: null,
            _calculateSize: null,
            _cleanContent: null,
            _renderContent: null,
            _setupCodomain: null,
            _getApproximateScreenRange: null,
            _factory: {
                createTranslator: function() {
                    return new translator1DModule.Translator1D
                },
                createTracker: function(parameters) {
                    return new Tracker(parameters)
                }
            }
        });
        exports.dxBaseGauge = dxBaseGauge;
        var _format = __webpack_require__( /*! ../core/format */ 465);
        var formatValue = function(value, options, extra) {
            options = options || {};
            var formatObject, text = _format(value, options);
            if ("function" === typeof options.customizeText) {
                formatObject = _extend({
                    value: value,
                    valueText: text
                }, extra);
                return String(options.customizeText.call(formatObject, formatObject))
            }
            return text
        };
        var getSampleText = function(translator, options) {
            var text1 = formatValue(translator.getDomainStart(), options),
                text2 = formatValue(translator.getDomainEnd(), options);
            return text1.length >= text2.length ? text1 : text2
        };
        exports.formatValue = formatValue;
        exports.getSampleText = getSampleText;
        exports.compareArrays = function(array1, array2) {
            return array1 && array2 && array1.length === array2.length && compareArraysElements(array1, array2)
        };

        function compareArraysElements(array1, array2) {
            var i, ii = array1.length;
            for (i = 0; i < ii; ++i) {
                if (array1[i] !== array2[i]) {
                    return false
                }
            }
            return true
        }
        dxBaseGauge.addPlugin(__webpack_require__( /*! ../core/export */ 444).plugin);
        dxBaseGauge.addPlugin(__webpack_require__( /*! ../core/title */ 494).plugin);
        dxBaseGauge.addPlugin(__webpack_require__( /*! ../core/tooltip */ 495).plugin);
        dxBaseGauge.addPlugin(__webpack_require__( /*! ../core/loading_indicator */ 496).plugin);
        var _setTooltipOptions = dxBaseGauge.prototype._setTooltipOptions;
        dxBaseGauge.prototype._setTooltipOptions = function() {
            _setTooltipOptions.apply(this, arguments);
            this._tracker && this._tracker.setTooltipState(this._tooltip.isEnabled())
        };

        function processTitleOptions(options) {
            return _isString(options) ? {
                text: options
            } : options || {}
        }
        dxBaseGauge.prototype._getTitleOptions = function() {
            var options, position, that = this,
                titleOptions = processTitleOptions(that.option("title"));
            that._suppressDeprecatedWarnings();
            titleOptions.subtitle = $.extend(processTitleOptions(titleOptions.subtitle), processTitleOptions(that.option("subtitle")));
            that._resumeDeprecatedWarnings();
            options = _extend(true, {}, that._themeManager.theme("title"), titleOptions);
            if (options.position) {
                position = _normalizeEnum(options.position).split("-");
                options.verticalAlignment = position[0];
                options.horizontalAlignment = position[1]
            }
            return options
        }
    },
    /*!***************************************!*\
      !*** ./Scripts/viz/gauges/tracker.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _abs = Math.abs,
            Class = __webpack_require__( /*! ../../core/class */ 20),
            wheelEvent = __webpack_require__( /*! ../../events/core/wheel */ 77),
            TOOLTIP_SHOW_DELAY = 300,
            TOOLTIP_HIDE_DELAY = 300,
            TOOLTIP_TOUCH_SHOW_DELAY = 400,
            TOOLTIP_TOUCH_HIDE_DELAY = 300;
        var Tracker = Class.inherit({
            ctor: function(parameters) {
                var debug = __webpack_require__( /*! ../../core/utils/console */ 12).debug;
                debug.assertParam(parameters, "parameters");
                debug.assertParam(parameters.renderer, "parameters.renderer");
                debug.assertParam(parameters.container, "parameters.container");
                var that = this;
                that._element = parameters.renderer.g().attr({
                    "class": "dxg-tracker",
                    stroke: "none",
                    "stroke-width": 0,
                    fill: "#000000",
                    opacity: 1e-4
                }).linkOn(parameters.container, {
                    name: "tracker",
                    after: "peripheral"
                });
                that._showTooltipCallback = function() {
                    that._showTooltipTimeout = null;
                    var target = that._tooltipEvent.target,
                        data_target = target["gauge-data-target"],
                        data_info = target["gauge-data-info"];
                    that._targetEvent = null;
                    if (that._tooltipTarget !== target && that._callbacks["tooltip-show"](data_target, data_info)) {
                        that._tooltipTarget = target
                    }
                };
                that._hideTooltipCallback = function() {
                    that._hideTooltipTimeout = null;
                    that._targetEvent = null;
                    if (that._tooltipTarget) {
                        that._callbacks["tooltip-hide"]();
                        that._tooltipTarget = null
                    }
                };
                that._dispose = function() {
                    clearTimeout(that._showTooltipTimeout);
                    clearTimeout(that._hideTooltipTimeout);
                    that._showTooltipCallback = that._hideTooltipCallback = that._dispose = null
                };
                that._DEBUG_showTooltipTimeoutSet = that._DEBUG_showTooltipTimeoutCleared = that._DEBUG_hideTooltipTimeoutSet = that._DEBUG_hideTooltipTimeoutCleared = 0;
                that.TOOLTIP_SHOW_DELAY = TOOLTIP_SHOW_DELAY;
                that.TOOLTIP_HIDE_DELAY = TOOLTIP_HIDE_DELAY;
                that.TOOLTIP_TOUCH_SHOW_DELAY = TOOLTIP_TOUCH_SHOW_DELAY;
                that.TOOLTIP_TOUCH_HIDE_DELAY = TOOLTIP_TOUCH_HIDE_DELAY
            },
            dispose: function() {
                var that = this;
                that._dispose();
                that.deactivate();
                that._element.linkOff();
                that._element = that._context = that._callbacks = null;
                return that
            },
            activate: function() {
                this._element.linkAppend();
                return this
            },
            deactivate: function() {
                this._element.linkRemove().clear();
                return this
            },
            attach: function(element, target, info) {
                element.data({
                    "gauge-data-target": target,
                    "gauge-data-info": info
                }).append(this._element);
                return this
            },
            detach: function(element) {
                element.remove();
                return this
            },
            setTooltipState: function(state) {
                var data, that = this;
                that._element.off(tooltipMouseEvents).off(tooltipTouchEvents).off(tooltipMouseWheelEvents);
                if (state) {
                    data = {
                        tracker: that
                    };
                    that._element.on(tooltipMouseEvents, data).on(tooltipTouchEvents, data).on(tooltipMouseWheelEvents, data)
                }
                return that
            },
            setCallbacks: function(callbacks) {
                this._callbacks = callbacks;
                return this
            },
            _showTooltip: function(event, delay) {
                var that = this;
                that._hideTooltipTimeout && ++that._DEBUG_hideTooltipTimeoutCleared;
                clearTimeout(that._hideTooltipTimeout);
                that._hideTooltipTimeout = null;
                if (that._tooltipTarget === event.target) {
                    return
                }
                clearTimeout(that._showTooltipTimeout);
                that._tooltipEvent = event;
                ++that._DEBUG_showTooltipTimeoutSet;
                that._showTooltipTimeout = setTimeout(that._showTooltipCallback, delay)
            },
            _hideTooltip: function(delay) {
                var that = this;
                that._showTooltipTimeout && ++that._DEBUG_showTooltipTimeoutCleared;
                clearTimeout(that._showTooltipTimeout);
                that._showTooltipTimeout = null;
                clearTimeout(that._hideTooltipTimeout);
                if (delay) {
                    ++that._DEBUG_hideTooltipTimeoutSet;
                    that._hideTooltipTimeout = setTimeout(that._hideTooltipCallback, delay)
                } else {
                    that._hideTooltipCallback()
                }
            }
        });
        var tooltipMouseEvents = {
            "mouseover.gauge-tooltip": handleTooltipMouseOver,
            "mouseout.gauge-tooltip": handleTooltipMouseOut
        };
        var tooltipMouseMoveEvents = {
            "mousemove.gauge-tooltip": handleTooltipMouseMove
        };
        var tooltipMouseWheelEvents = {};
        tooltipMouseWheelEvents[wheelEvent.name + ".gauge-tooltip"] = handleTooltipMouseWheel;
        var tooltipTouchEvents = {
            "touchstart.gauge-tooltip": handleTooltipTouchStart
        };

        function handleTooltipMouseOver(event) {
            var tracker = event.data.tracker;
            tracker._x = event.pageX;
            tracker._y = event.pageY;
            tracker._element.off(tooltipMouseMoveEvents).on(tooltipMouseMoveEvents, event.data);
            tracker._showTooltip(event, TOOLTIP_SHOW_DELAY)
        }

        function handleTooltipMouseMove(event) {
            var tracker = event.data.tracker;
            if (tracker._showTooltipTimeout && _abs(event.pageX - tracker._x) > 4 || _abs(event.pageY - tracker._y) > 4) {
                tracker._x = event.pageX;
                tracker._y = event.pageY;
                tracker._showTooltip(event, TOOLTIP_SHOW_DELAY)
            }
        }

        function handleTooltipMouseOut(event) {
            var tracker = event.data.tracker;
            tracker._element.off(tooltipMouseMoveEvents);
            tracker._hideTooltip(TOOLTIP_HIDE_DELAY)
        }

        function handleTooltipMouseWheel(event) {
            event.data.tracker._hideTooltip()
        }
        var active_touch_tooltip_tracker = null;
        Tracker._DEBUG_reset = function() {
            active_touch_tooltip_tracker = null
        };

        function handleTooltipTouchStart(event) {
            event.preventDefault();
            var tracker = active_touch_tooltip_tracker;
            if (tracker && tracker !== event.data.tracker) {
                tracker._hideTooltip(TOOLTIP_TOUCH_HIDE_DELAY)
            }
            tracker = active_touch_tooltip_tracker = event.data.tracker;
            tracker._showTooltip(event, TOOLTIP_TOUCH_SHOW_DELAY);
            tracker._touch = true
        }

        function handleTooltipDocumentTouchStart() {
            var tracker = active_touch_tooltip_tracker;
            if (tracker) {
                if (!tracker._touch) {
                    tracker._hideTooltip(TOOLTIP_TOUCH_HIDE_DELAY);
                    active_touch_tooltip_tracker = null
                }
                tracker._touch = null
            }
        }

        function handleTooltipDocumentTouchEnd() {
            var tracker = active_touch_tooltip_tracker;
            if (tracker) {
                if (tracker._showTooltipTimeout) {
                    tracker._hideTooltip(TOOLTIP_TOUCH_HIDE_DELAY);
                    active_touch_tooltip_tracker = null
                }
            }
        }
        $(window.document).on({
            "touchstart.gauge-tooltip": handleTooltipDocumentTouchStart,
            "touchend.gauge-tooltip": handleTooltipDocumentTouchEnd
        });
        module.exports = Tracker
    },
    /*!**************************************!*\
      !*** ./Scripts/viz/gauges/common.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            dxBaseGauge = __webpack_require__( /*! ./base_gauge */ 524).dxBaseGauge,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isDefined = commonUtils.isDefined,
            _isArray = commonUtils.isArray,
            _isNumber = commonUtils.isNumber,
            rangeModule = __webpack_require__( /*! ../translators/range */ 503),
            axisModule = __webpack_require__( /*! ../axes/base_axis */ 506),
            _map = __webpack_require__( /*! ../core/utils */ 442).map,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            _compareArrays = __webpack_require__( /*! ./base_gauge */ 524).compareArrays,
            _isFinite = isFinite,
            _Number = Number,
            _min = Math.min,
            _max = Math.max,
            _extend = $.extend,
            _each = $.each,
            _noop = $.noop,
            OPTION_VALUE = "value",
            OPTION_SUBVALUES = "subvalues",
            DEFAULT_MINOR_AXIS_DIVISION_FACTOR = 5,
            DEFAULT_NUMBER_MULTIPLIERS = [1, 2, 5];

        function processValue(value, fallbackValue) {
            return _isFinite(value) ? _Number(value) : fallbackValue
        }

        function parseArrayOfNumbers(arg) {
            return _isArray(arg) ? arg : _isNumber(arg) ? [arg] : null
        }
        exports.dxGauge = dxBaseGauge.inherit({
            _initCore: function() {
                var that = this,
                    renderer = that._renderer;
                that._setupValue(that.option(OPTION_VALUE));
                that.__subvalues = parseArrayOfNumbers(that.option(OPTION_SUBVALUES));
                that._setupSubvalues(that.__subvalues);
                selectMode(that);
                that.callBase.apply(that, arguments);
                that._rangeContainer = new that._factory.RangeContainer({
                    renderer: renderer,
                    container: renderer.root,
                    translator: that._translator,
                    themeManager: that._themeManager
                });
                that._initScale()
            },
            _initScale: function() {
                var that = this;
                that._scaleGroup = that._renderer.g().attr({
                    "class": "dxg-scale"
                }).linkOn(that._renderer.root, "scale");
                that._scale = new axisModule.Axis({
                    incidentOccurred: that._incidentOccurred,
                    renderer: that._renderer,
                    axesContainerGroup: that._scaleGroup,
                    axisType: that._scaleTypes.type,
                    drawingType: that._scaleTypes.drawingType,
                    widgetClass: "dxg"
                });
                that._scaleTranslator = that._initScaleTranslator(new rangeModule.Range({
                    axisType: "continuous",
                    dataType: "numeric",
                    stick: true
                }))
            },
            _disposeCore: function() {
                var that = this;
                that.callBase.apply(that, arguments);
                that._scale.dispose();
                that._scaleGroup.linkOff();
                that._rangeContainer.dispose();
                that._disposeValueIndicators();
                that._scale = that._scaleGroup = that._scaleTranslators = that._rangeContainer = null
            },
            _disposeValueIndicators: function() {
                var that = this;
                that._valueIndicator && that._valueIndicator.dispose();
                that._subvalueIndicatorsSet && that._subvalueIndicatorsSet.dispose();
                that._valueIndicator = that._subvalueIndicatorsSet = null
            },
            _setupDomainCore: function() {
                var that = this,
                    scaleOption = that.option("scale") || {},
                    startValue = that.option("startValue"),
                    endValue = that.option("endValue");
                startValue = _isNumber(startValue) ? _Number(startValue) : _isNumber(scaleOption.startValue) ? _Number(scaleOption.startValue) : 0;
                endValue = _isNumber(endValue) ? _Number(endValue) : _isNumber(scaleOption.endValue) ? _Number(scaleOption.endValue) : 100;
                that._baseValue = startValue < endValue ? startValue : endValue;
                that._translator.setDomain(startValue, endValue)
            },
            _cleanContent: function() {
                var that = this;
                that._rangeContainer.clean();
                that._cleanValueIndicators()
            },
            _measureScale: function(scaleOptions) {
                var textParams, layoutValue, result, coefs, innerCoef, outerCoef, that = this,
                    majorTick = scaleOptions.tick,
                    majorTickEnabled = majorTick.visible && majorTick.length > 0 && majorTick.width > 0,
                    minorTick = scaleOptions.minorTick,
                    minorTickEnabled = minorTick.visible && minorTick.length > 0 && minorTick.width > 0,
                    label = scaleOptions.label,
                    indentFromTick = Number(label.indentFromTick);
                if (!majorTickEnabled && !minorTickEnabled && !label.visible) {
                    return {}
                }
                textParams = that._scale.measureLabels();
                layoutValue = that._getScaleLayoutValue();
                result = {
                    min: layoutValue,
                    max: layoutValue
                };
                coefs = that._getTicksCoefficients(scaleOptions);
                innerCoef = coefs.inner;
                outerCoef = coefs.outer;
                if (majorTickEnabled) {
                    result.min = _min(result.min, layoutValue - innerCoef * majorTick.length);
                    result.max = _max(result.max, layoutValue + outerCoef * majorTick.length)
                }
                if (minorTickEnabled) {
                    result.min = _min(result.min, layoutValue - innerCoef * minorTick.length);
                    result.max = _max(result.max, layoutValue + outerCoef * minorTick.length)
                }
                label.visible && that._correctScaleIndents(result, indentFromTick, textParams);
                return result
            },
            _renderContent: function() {
                var elements, that = this,
                    scaleOptions = that._prepareScaleSettings();
                that._rangeContainer.render(_extend(that._getOption("rangeContainer"), {
                    vertical: that._area.vertical
                }));
                that._renderScale(scaleOptions);
                elements = _map([that._rangeContainer].concat(that._prepareValueIndicators()), function(element) {
                    return element && element.enabled ? element : null
                });
                that._applyMainLayout(elements, that._measureScale(scaleOptions));
                _each(elements, function(_, element) {
                    element.resize(that._getElementLayout(element.getOffset()))
                });
                that._shiftScale(that._getElementLayout(0), scaleOptions);
                that._beginValueChanging();
                that._updateActiveElements();
                that._endValueChanging()
            },
            _prepareScaleSettings: function() {
                var that = this,
                    scaleOptions = $.extend(true, {}, that._themeManager.theme("scale"), that.option("scale")),
                    useAutoArrangement = scaleOptions.label.overlappingBehavior.useAutoArrangement,
                    scaleMajorTick = scaleOptions.majorTick,
                    scaleMinorTick = scaleOptions.minorTick,
                    overlappingBehavior = scaleOptions.label.overlappingBehavior;
                if (scaleMajorTick) {
                    scaleOptions.tick = _extend(scaleOptions.tick, scaleMajorTick);
                    useAutoArrangement = void 0 !== scaleMajorTick.useTickAutoArrangement ? scaleMajorTick.useTickAutoArrangement : true;
                    void 0 !== scaleMajorTick.tickInterval && (scaleOptions.tickInterval = scaleMajorTick.tickInterval);
                    void 0 !== scaleMajorTick.customTickValues && (scaleOptions.customTicks = scaleMajorTick.customTickValues);
                    if (scaleOptions.customTicks) {
                        scaleOptions.tick.showCalculatedTicks = void 0 !== scaleMajorTick.showCalculatedTicks ? scaleMajorTick.showCalculatedTicks : true
                    } else {
                        scaleOptions.tick.showCalculatedTicks = false
                    }
                }
                overlappingBehavior.hideFirstTick = scaleOptions.hideFirstTick;
                overlappingBehavior.hideFirstLabel = scaleOptions.hideFirstLabel;
                overlappingBehavior.hideLastTick = scaleOptions.hideLastTick;
                overlappingBehavior.hideLastLabel = scaleOptions.hideLastLabel;
                void 0 !== scaleMinorTick.customTickValues && (scaleOptions.customMinorTicks = scaleOptions.minorTick.customTickValues);
                void 0 !== scaleMinorTick.tickInterval && (scaleOptions.minorTickInterval = scaleOptions.minorTick.tickInterval);
                if (scaleOptions.customMinorTicks) {
                    scaleMinorTick.showCalculatedTicks = void 0 !== scaleMinorTick.showCalculatedTicks ? scaleMinorTick.showCalculatedTicks : true
                } else {
                    scaleMinorTick.showCalculatedTicks = false
                }
                scaleOptions.label.indentFromAxis = 0;
                scaleOptions.isHorizontal = !that._area.vertical;
                overlappingBehavior.mode = useAutoArrangement ? "enlargeTickInterval" : "ignore";
                scaleOptions.axisDivisionFactor = that._gridSpacingFactor;
                scaleOptions.minorAxisDivisionFactor = DEFAULT_MINOR_AXIS_DIVISION_FACTOR;
                scaleOptions.numberMultipliers = DEFAULT_NUMBER_MULTIPLIERS;
                scaleOptions.tickOrientation = that._getTicksOrientation(scaleOptions);
                if (scaleOptions.label.useRangeColors) {
                    scaleOptions.label.customizeColor = function() {
                        return that._rangeContainer.getColorForValue(this.value)
                    }
                }
                return scaleOptions
            },
            _renderScale: function(scaleOptions) {
                var that = this,
                    bounds = that._translator.getDomain(),
                    startValue = bounds[0],
                    endValue = bounds[1];
                scaleOptions.min = startValue;
                scaleOptions.max = endValue;
                that._scale.updateOptions(scaleOptions);
                that._updateScaleTranslator(startValue, endValue);
                that._updateScaleTickIndent(scaleOptions);
                that._scaleGroup.linkAppend();
                that._scale.draw()
            },
            _updateScaleTranslator: function(startValue, endValue) {
                var that = this,
                    argTranslator = that._getScaleTranslatorComponent("arg");
                that._updateScaleAngles();
                argTranslator.updateBusinessRange(_extend(argTranslator.getBusinessRange(), {
                    minVisible: startValue,
                    maxVisible: endValue,
                    invert: startValue > endValue
                }));
                that._scale.setTranslator(argTranslator, that._getScaleTranslatorComponent("val"))
            },
            _updateIndicatorSettings: function(settings) {
                var that = this;
                settings.currentValue = settings.baseValue = _isFinite(that._translator.translate(settings.baseValue)) ? _Number(settings.baseValue) : that._baseValue;
                settings.vertical = that._area.vertical;
                if (settings.text && !settings.text.format && !settings.text.precision) {
                    settings.text.format = that._defaultFormatOptions
                }
            },
            _prepareIndicatorSettings: function(options, defaultTypeField) {
                var that = this,
                    theme = that._themeManager.theme("valueIndicators"),
                    type = _normalizeEnum(options.type || that._themeManager.theme(defaultTypeField)),
                    settings = _extend(true, {}, theme._default, theme[type], options);
                settings.type = type;
                settings.animation = that._animationSettings;
                settings.containerBackgroundColor = that._containerBackgroundColor;
                that._updateIndicatorSettings(settings);
                return settings
            },
            _cleanValueIndicators: function() {
                this._valueIndicator && this._valueIndicator.clean();
                this._subvalueIndicatorsSet && this._subvalueIndicatorsSet.clean()
            },
            _prepareValueIndicators: function() {
                var that = this;
                that._prepareValueIndicator();
                null !== that.__subvalues && that._prepareSubvalueIndicators();
                return [that._valueIndicator, that._subvalueIndicatorsSet]
            },
            _updateActiveElements: function() {
                this._updateValueIndicator();
                this._updateSubvalueIndicators()
            },
            _prepareValueIndicator: function() {
                var that = this,
                    target = that._valueIndicator,
                    settings = that._prepareIndicatorSettings(that.option("valueIndicator") || {}, "valueIndicatorType");
                if (target && target.type !== settings.type) {
                    target.dispose();
                    target = null
                }
                if (!target) {
                    target = that._valueIndicator = that._createIndicator(settings.type, that._renderer.root, "dxg-value-indicator", "value-indicator")
                }
                target.render(settings)
            },
            _createSubvalueIndicatorsSet: function() {
                var that = this,
                    root = that._renderer.root;
                return new ValueIndicatorsSet({
                    createIndicator: function(type, i) {
                        return that._createIndicator(type, root, "dxg-subvalue-indicator", "subvalue-indicator", i)
                    },
                    createPalette: function(palette) {
                        return that._themeManager.createPalette(palette)
                    }
                })
            },
            _prepareSubvalueIndicators: function() {
                var isRecreate, dummy, that = this,
                    target = that._subvalueIndicatorsSet,
                    settings = that._prepareIndicatorSettings(that.option("subvalueIndicator") || {}, "subvalueIndicatorType");
                if (!target) {
                    target = that._subvalueIndicatorsSet = that._createSubvalueIndicatorsSet()
                }
                isRecreate = settings.type !== target.type;
                target.type = settings.type;
                dummy = that._createIndicator(settings.type, that._renderer.root);
                if (dummy) {
                    dummy.dispose();
                    target.render(settings, isRecreate)
                }
            },
            _setupValue: function(value) {
                this.__value = processValue(value, this.__value)
            },
            _setupSubvalues: function(subvalues) {
                var i, ii, list, vals = void 0 === subvalues ? this.__subvalues : parseArrayOfNumbers(subvalues);
                if (null === vals) {
                    return
                }
                for (i = 0, ii = vals.length, list = []; i < ii; ++i) {
                    list.push(processValue(vals[i], this.__subvalues[i]))
                }
                this.__subvalues = list
            },
            _updateValueIndicator: function() {
                var that = this;
                that._valueIndicator && that._valueIndicator.value(that.__value, that._noAnimation)
            },
            _updateSubvalueIndicators: function() {
                var that = this;
                that._subvalueIndicatorsSet && that._subvalueIndicatorsSet.values(that.__subvalues, that._noAnimation)
            },
            value: function(arg) {
                if (void 0 !== arg) {
                    this._changeValue(arg);
                    return this
                }
                return this.__value
            },
            subvalues: function(arg) {
                if (void 0 !== arg) {
                    this._changeSubvalues(arg);
                    return this
                }
                return null !== this.__subvalues ? this.__subvalues.slice() : void 0
            },
            _changeValue: function(value) {
                var that = this;
                that._setupValue(value);
                that._beginValueChanging();
                that._updateValueIndicator();
                if (that.__value !== that.option(OPTION_VALUE)) {
                    that.option(OPTION_VALUE, that.__value)
                }
                that._endValueChanging()
            },
            _changeSubvalues: function(subvalues) {
                var that = this;
                if (null !== that.__subvalues) {
                    that._setupSubvalues(subvalues);
                    that._beginValueChanging();
                    that._updateSubvalueIndicators();
                    if (!_compareArrays(that.__subvalues, that.option(OPTION_SUBVALUES))) {
                        that.option(OPTION_SUBVALUES, that.__subvalues)
                    }
                    that._endValueChanging()
                }
            },
            _optionChangesMap: {
                scale: "DOMAIN",
                rangeContainer: "MOSTLY_TOTAL",
                valueIndicator: "MOSTLY_TOTAL",
                subvalueIndicator: "MOSTLY_TOTAL",
                containerBackgroundColor: "MOSTLY_TOTAL",
                value: "VALUE",
                subvalues: "SUBVALUES",
                valueIndicators: "MOSTLY_TOTAL"
            },
            _customChangesOrder: ["VALUE", "SUBVALUES"],
            _change_VALUE: function() {
                this._changeValue(this.option(OPTION_VALUE))
            },
            _change_SUBVALUES: function() {
                this._changeSubvalues(this.option(OPTION_SUBVALUES))
            },
            _applyMainLayout: null,
            _getElementLayout: null,
            _createIndicator: function(type, owner, className, trackerType, trackerIndex, _strict) {
                var that = this,
                    indicator = that._factory.createIndicator({
                        renderer: that._renderer,
                        translator: that._translator,
                        owner: owner,
                        tracker: that._tracker,
                        className: className
                    }, type, _strict);
                if (indicator) {
                    indicator.type = type;
                    indicator._trackerInfo = {
                        type: trackerType,
                        index: trackerIndex
                    }
                }
                return indicator
            },
            _getApproximateScreenRange: null
        });

        function valueGetter(arg) {
            return arg ? arg.value : null
        }

        function setupValues(that, fieldName, optionItems) {
            var currentValues = that[fieldName],
                newValues = _isArray(optionItems) ? _map(optionItems, valueGetter) : [],
                i = 0,
                ii = newValues.length,
                list = [];
            for (; i < ii; ++i) {
                list.push(processValue(newValues[i], currentValues[i]))
            }
            that[fieldName] = list
        }

        function selectMode(gauge) {
            if (void 0 === gauge.option(OPTION_VALUE) && void 0 === gauge.option(OPTION_SUBVALUES)) {
                if (void 0 !== gauge.option("valueIndicators")) {
                    disableDefaultMode(gauge);
                    selectHardMode(gauge)
                }
            }
        }

        function disableDefaultMode(that) {
            that.value = that.subvalues = _noop;
            that._setupValue = that._setupSubvalues = that._updateValueIndicator = that._updateSubvalueIndicators = null
        }

        function selectHardMode(that) {
            that._indicatorValues = [];
            setupValues(that, "_indicatorValues", that.option("valueIndicators"));
            that._valueIndicators = [];
            var _applyMostlyTotalChange = that._applyMostlyTotalChange;
            that._applyMostlyTotalChange = function() {
                setupValues(this, "_indicatorValues", this.option("valueIndicators"));
                _applyMostlyTotalChange.call(this)
            };
            that._updateActiveElements = updateActiveElements_hardMode;
            that._prepareValueIndicators = prepareValueIndicators_hardMode;
            that._disposeValueIndicators = disposeValueIndicators_hardMode;
            that._cleanValueIndicators = cleanValueIndicators_hardMode;
            that.indicatorValue = indicatorValue_hardMode
        }

        function updateActiveElements_hardMode() {
            var that = this;
            _each(that._valueIndicators, function(_, valueIndicator) {
                valueIndicator.value(that._indicatorValues[valueIndicator.index], that._noAnimation)
            })
        }

        function prepareValueIndicators_hardMode() {
            var ii, that = this,
                valueIndicators = that._valueIndicators || [],
                userOptions = that.option("valueIndicators"),
                optionList = [],
                i = 0;
            for (ii = _isArray(userOptions) ? userOptions.length : 0; i < ii; ++i) {
                optionList.push(userOptions[i])
            }
            for (ii = valueIndicators.length; i < ii; ++i) {
                optionList.push(null)
            }
            var newValueIndicators = [];
            _each(optionList, function(i, userSettings) {
                var valueIndicator = valueIndicators[i];
                if (!userSettings) {
                    valueIndicator && valueIndicator.dispose();
                    return
                }
                var settings = that._prepareIndicatorSettings(userSettings, "valueIndicatorType");
                if (valueIndicator && valueIndicator.type !== settings.type) {
                    valueIndicator.dispose();
                    valueIndicator = null
                }
                if (!valueIndicator) {
                    valueIndicator = that._createIndicator(settings.type, that._renderer.root, "dxg-value-indicator", "value-indicator", i, true)
                }
                if (valueIndicator) {
                    valueIndicator.index = i;
                    valueIndicator.render(settings);
                    newValueIndicators.push(valueIndicator)
                }
            });
            that._valueIndicators = newValueIndicators;
            return that._valueIndicators
        }

        function disposeValueIndicators_hardMode() {
            _each(this._valueIndicators, function(_, valueIndicator) {
                valueIndicator.dispose()
            });
            this._valueIndicators = null
        }

        function cleanValueIndicators_hardMode() {
            _each(this._valueIndicators, function(_, valueIndicator) {
                valueIndicator.clean()
            })
        }

        function indicatorValue_hardMode(index, value) {
            return accessPointerValue(this, this._valueIndicators, this._indicatorValues, index, value)
        }

        function accessPointerValue(that, pointers, values, index, value) {
            if (void 0 !== value) {
                if (void 0 !== values[index]) {
                    values[index] = processValue(value, values[index]);
                    pointers[index] && pointers[index].value(values[index])
                }
                return that
            } else {
                return values[index]
            }
        }

        function ValueIndicatorsSet(parameters) {
            this._parameters = parameters;
            this._indicators = []
        }
        ValueIndicatorsSet.prototype = {
            constructor: ValueIndicatorsSet,
            dispose: function() {
                var that = this;
                _each(that._indicators, function(_, indicator) {
                    indicator.dispose()
                });
                that._parameters = that._options = that._indicators = that._colorPalette = that._palette = null;
                return that
            },
            clean: function() {
                var that = this;
                that._sample && that._sample.clean().dispose();
                _each(that._indicators, function(_, indicator) {
                    indicator.clean()
                });
                that._sample = that._options = that._palette = null;
                return that
            },
            render: function(options, isRecreate) {
                var that = this;
                that._options = options;
                that._sample = that._parameters.createIndicator(that.type);
                that._sample.render(options);
                that.enabled = that._sample.enabled;
                that._palette = _isDefined(options.palette) ? that._parameters.createPalette(options.palette) : null;
                if (that.enabled) {
                    that._generatePalette(that._indicators.length);
                    that._indicators = _map(that._indicators, function(indicator, i) {
                        if (isRecreate) {
                            indicator.dispose();
                            indicator = that._parameters.createIndicator(that.type, i)
                        }
                        indicator.render(that._getIndicatorOptions(i));
                        return indicator
                    })
                }
                return that
            },
            getOffset: function() {
                return _Number(this._options.offset) || 0
            },
            resize: function(layout) {
                var that = this;
                that._layout = layout;
                _each(that._indicators, function(_, indicator) {
                    indicator.resize(layout)
                });
                return that
            },
            measure: function(layout) {
                return this._sample.measure(layout)
            },
            _getIndicatorOptions: function(index) {
                var result = this._options;
                if (this._colorPalette) {
                    result = _extend({}, result, {
                        color: this._colorPalette[index]
                    })
                }
                return result
            },
            _generatePalette: function(count) {
                var that = this,
                    colors = null;
                if (that._palette) {
                    colors = [];
                    that._palette.reset();
                    var i = 0;
                    for (; i < count; ++i) {
                        colors.push(that._palette.getNextColor())
                    }
                }
                that._colorPalette = colors
            },
            _adjustIndicatorsCount: function(count) {
                var i, ii, indicator, that = this,
                    indicators = that._indicators,
                    indicatorsLen = indicators.length;
                if (indicatorsLen > count) {
                    for (i = count, ii = indicatorsLen; i < ii; ++i) {
                        indicators[i].clean().dispose()
                    }
                    that._indicators = indicators.slice(0, count);
                    that._generatePalette(indicators.length)
                } else {
                    if (indicatorsLen < count) {
                        that._generatePalette(count);
                        for (i = indicatorsLen, ii = count; i < ii; ++i) {
                            indicator = that._parameters.createIndicator(that.type, i);
                            indicator.render(that._getIndicatorOptions(i)).resize(that._layout);
                            indicators.push(indicator)
                        }
                    }
                }
            },
            values: function(arg, _noAnimation) {
                var that = this;
                if (!that.enabled) {
                    return
                }
                if (void 0 !== arg) {
                    if (!_isArray(arg)) {
                        arg = _isFinite(arg) ? [Number(arg)] : null
                    }
                    if (arg) {
                        that._adjustIndicatorsCount(arg.length);
                        _each(that._indicators, function(i, indicator) {
                            indicator.value(arg[i], _noAnimation)
                        })
                    }
                    return that
                }
                return _map(that._indicators, function(indicator) {
                    return indicator.value()
                })
            }
        };
        exports.createIndicatorCreator = function(indicators) {
            return function(parameters, type, _strict) {
                var indicatorType = indicators[_normalizeEnum(type)] || !_strict && indicators._default;
                return indicatorType ? new indicatorType(parameters) : null
            }
        }
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/gauges/linear_indicators.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var baseIndicatorsModule = __webpack_require__( /*! ./base_indicators */ 528),
            BaseIndicator = baseIndicatorsModule.BaseIndicator,
            BaseTextCloudMarker = baseIndicatorsModule.BaseTextCloudMarker,
            BaseRangeBar = baseIndicatorsModule.BaseRangeBar,
            _Number = Number,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum;
        var SimpleIndicator = BaseIndicator.inherit({
            _move: function() {
                var that = this,
                    delta = that._actualPosition - that._zeroPosition;
                that._rootElement.move(that.vertical ? 0 : delta, that.vertical ? delta : 0);
                that._trackerElement && that._trackerElement.move(that.vertical ? 0 : delta, that.vertical ? delta : 0)
            },
            _isEnabled: function() {
                this.vertical = this._options.vertical;
                return this._options.length > 0 && this._options.width > 0
            },
            _isVisible: function() {
                return true
            },
            _getTrackerSettings: function() {
                var x1, x2, y1, y2, options = this._options,
                    width = options.width / 2,
                    length = options.length / 2,
                    p = this._zeroPosition;
                width > 10 || (width = 10);
                length > 10 || (length = 10);
                if (this.vertical) {
                    x1 = options.x - length;
                    x2 = options.x + length;
                    y1 = p + width;
                    y2 = p - width
                } else {
                    x1 = p - width;
                    x2 = p + width;
                    y1 = options.y + length;
                    y2 = options.y - length
                }
                return {
                    points: [x1, y1, x1, y2, x2, y2, x2, y1]
                }
            },
            _render: function() {
                var that = this;
                that._zeroPosition = that._translator.getCodomainStart()
            },
            _clear: function() {
                delete this._element
            },
            measure: function(layout) {
                var p = this.vertical ? layout.x : layout.y;
                return {
                    min: p - this._options.length / 2,
                    max: p + this._options.length / 2
                }
            },
            getTooltipParameters: function() {
                var that = this,
                    options = that._options,
                    p = that._actualPosition,
                    parameters = {
                        x: p,
                        y: p,
                        value: that._currentValue,
                        color: options.color,
                        offset: options.width / 2
                    };
                that.vertical ? parameters.x = options.x : parameters.y = options.y;
                return parameters
            }
        });
        var rectangle = SimpleIndicator.inherit({
            _render: function() {
                var p, x1, x2, y1, y2, that = this,
                    options = that._options;
                that.callBase();
                p = that._zeroPosition;
                if (that.vertical) {
                    x1 = options.x - options.length / 2;
                    x2 = options.x + options.length / 2;
                    y1 = p + options.width / 2;
                    y2 = p - options.width / 2
                } else {
                    x1 = p - options.width / 2;
                    x2 = p + options.width / 2;
                    y1 = options.y + options.length / 2;
                    y2 = options.y - options.length / 2
                }
                that._element = that._element || that._renderer.path([], "area").append(that._rootElement);
                that._element.attr({
                    points: [x1, y1, x1, y2, x2, y2, x2, y1]
                })
            }
        });
        var rhombus = SimpleIndicator.inherit({
            _render: function() {
                var x, y, dx, dy, that = this,
                    options = that._options;
                that.callBase();
                if (that.vertical) {
                    x = options.x;
                    y = that._zeroPosition;
                    dx = options.length / 2 || 0;
                    dy = options.width / 2 || 0
                } else {
                    x = that._zeroPosition;
                    y = options.y;
                    dx = options.width / 2 || 0;
                    dy = options.length / 2 || 0
                }
                that._element = that._element || that._renderer.path([], "area").append(that._rootElement);
                that._element.attr({
                    points: [x - dx, y, x, y - dy, x + dx, y, x, y + dy]
                })
            }
        });
        var circle = SimpleIndicator.inherit({
            _render: function() {
                var x, y, r, that = this,
                    options = that._options;
                that.callBase();
                if (that.vertical) {
                    x = options.x;
                    y = that._zeroPosition
                } else {
                    x = that._zeroPosition;
                    y = options.y
                }
                r = options.length / 2 || 0;
                that._element = that._element || that._renderer.circle().append(that._rootElement);
                that._element.attr({
                    cx: x,
                    cy: y,
                    r: r
                })
            }
        });
        var trianglemarker = SimpleIndicator.inherit({
            _isEnabled: function() {
                var that = this;
                that.vertical = that._options.vertical;
                that._inverted = that.vertical ? "right" === _normalizeEnum(that._options.horizontalOrientation) : "bottom" === _normalizeEnum(that._options.verticalOrientation);
                return that._options.length > 0 && that._options.width > 0
            },
            _isVisible: function() {
                return true
            },
            _render: function() {
                var x1, x2, y1, y2, that = this,
                    options = that._options,
                    settings = {
                        stroke: "none",
                        "stroke-width": 0,
                        "stroke-linecap": "square"
                    };
                that.callBase();
                if (that.vertical) {
                    x1 = options.x;
                    y1 = that._zeroPosition;
                    x2 = x1 + _Number(that._inverted ? options.length : -options.length);
                    settings.points = [x1, y1, x2, y1 - options.width / 2, x2, y1 + options.width / 2]
                } else {
                    y1 = options.y;
                    x1 = that._zeroPosition;
                    y2 = y1 + _Number(that._inverted ? options.length : -options.length);
                    settings.points = [x1, y1, x1 - options.width / 2, y2, x1 + options.width / 2, y2]
                }
                if (options.space > 0) {
                    settings["stroke-width"] = Math.min(options.space, options.width / 4) || 0;
                    settings.stroke = settings["stroke-width"] > 0 ? options.containerBackgroundColor || "none" : "none"
                }
                that._element = that._element || that._renderer.path([], "area").append(that._rootElement);
                that._element.attr(settings).sharp()
            },
            _getTrackerSettings: function() {
                var x1, x2, y1, y2, result, that = this,
                    options = that._options,
                    width = options.width / 2,
                    length = _Number(options.length);
                width > 10 || (width = 10);
                length > 20 || (length = 20);
                if (that.vertical) {
                    x1 = x2 = options.x;
                    x2 = x1 + (that._inverted ? length : -length);
                    y1 = that._zeroPosition + width;
                    y2 = that._zeroPosition - width;
                    result = [x1, y1, x2, y1, x2, y2, x1, y2]
                } else {
                    y1 = options.y;
                    y2 = y1 + (that._inverted ? length : -length);
                    x1 = that._zeroPosition - width;
                    x2 = that._zeroPosition + width;
                    result = [x1, y1, x1, y2, x2, y2, x2, y1]
                }
                return {
                    points: result
                }
            },
            measure: function(layout) {
                var minbound, maxbound, that = this,
                    length = _Number(that._options.length);
                if (that.vertical) {
                    minbound = maxbound = layout.x;
                    if (that._inverted) {
                        maxbound = minbound + length
                    } else {
                        minbound = maxbound - length
                    }
                } else {
                    minbound = maxbound = layout.y;
                    if (that._inverted) {
                        maxbound = minbound + length
                    } else {
                        minbound = maxbound - length
                    }
                }
                return {
                    min: minbound,
                    max: maxbound,
                    indent: that._options.width / 2
                }
            },
            getTooltipParameters: function() {
                var that = this,
                    options = that._options,
                    s = (that._inverted ? options.length : -options.length) / 2,
                    parameters = that.callBase();
                that.vertical ? parameters.x += s : parameters.y += s;
                parameters.offset = options.length / 2;
                return parameters
            }
        });
        var textcloud = BaseTextCloudMarker.inherit({
            _isEnabled: function() {
                var that = this;
                that.vertical = that._options.vertical;
                that._inverted = that.vertical ? "right" === _normalizeEnum(that._options.horizontalOrientation) : "bottom" === _normalizeEnum(that._options.verticalOrientation);
                return true
            },
            _isVisible: function() {
                return true
            },
            _getTextCloudOptions: function() {
                var type, that = this,
                    x = that._actualPosition,
                    y = that._actualPosition;
                if (that.vertical) {
                    x = that._options.x;
                    type = that._inverted ? "top-left" : "top-right"
                } else {
                    y = that._options.y;
                    type = that._inverted ? "right-top" : "right-bottom"
                }
                return {
                    x: x,
                    y: y,
                    type: type
                }
            },
            measure: function(layout) {
                var minbound, maxbound, indent, that = this,
                    arrowLength = _Number(that._options.arrowLength) || 0;
                that._measureText();
                if (that.vertical) {
                    indent = that._textFullHeight;
                    if (that._inverted) {
                        minbound = layout.x;
                        maxbound = layout.x + arrowLength + that._textFullWidth
                    } else {
                        minbound = layout.x - arrowLength - that._textFullWidth;
                        maxbound = layout.x
                    }
                } else {
                    indent = that._textFullWidth;
                    if (that._inverted) {
                        minbound = layout.y;
                        maxbound = layout.y + arrowLength + that._textFullHeight
                    } else {
                        minbound = layout.y - arrowLength - that._textFullHeight;
                        maxbound = layout.y
                    }
                }
                return {
                    min: minbound,
                    max: maxbound,
                    indent: indent
                }
            }
        });
        var rangebar = BaseRangeBar.inherit({
            _isEnabled: function() {
                var that = this;
                that.vertical = that._options.vertical;
                that._inverted = that.vertical ? "right" === _normalizeEnum(that._options.horizontalOrientation) : "bottom" === _normalizeEnum(that._options.verticalOrientation);
                return that._options.size > 0
            },
            _isVisible: function() {
                return true
            },
            _createBarItem: function() {
                return this._renderer.path([], "area").append(this._rootElement)
            },
            _createTracker: function() {
                return this._renderer.path([], "area")
            },
            _setBarSides: function() {
                var minSide, maxSide, that = this,
                    options = that._options,
                    size = _Number(options.size);
                if (that.vertical) {
                    if (that._inverted) {
                        minSide = options.x;
                        maxSide = options.x + size
                    } else {
                        minSide = options.x - size;
                        maxSide = options.x
                    }
                } else {
                    if (that._inverted) {
                        minSide = options.y;
                        maxSide = options.y + size
                    } else {
                        minSide = options.y - size;
                        maxSide = options.y
                    }
                }
                that._minSide = minSide;
                that._maxSide = maxSide;
                that._minBound = minSide;
                that._maxBound = maxSide
            },
            _getSpace: function() {
                var options = this._options;
                return options.space > 0 ? _Number(options.space) : 0
            },
            _isTextVisible: function() {
                var textOptions = this._options.text || {};
                return textOptions.indent > 0 || textOptions.indent < 0
            },
            _getTextAlign: function() {
                return this.vertical ? this._options.text.indent > 0 ? "left" : "right" : "center"
            },
            _setTextItemsSides: function() {
                var that = this,
                    indent = _Number(that._options.text.indent);
                if (indent > 0) {
                    that._lineStart = that._maxSide;
                    that._lineEnd = that._maxSide + indent;
                    that._textPosition = that._lineEnd + (that.vertical ? 2 : that._textHeight / 2);
                    that._maxBound = that._textPosition + (that.vertical ? that._textWidth : that._textHeight / 2)
                } else {
                    if (indent < 0) {
                        that._lineStart = that._minSide;
                        that._lineEnd = that._minSide + indent;
                        that._textPosition = that._lineEnd - (that.vertical ? 2 : that._textHeight / 2);
                        that._minBound = that._textPosition - (that.vertical ? that._textWidth : that._textHeight / 2)
                    }
                }
            },
            _getPositions: function() {
                var mainPosition1, mainPosition2, backPosition1, backPosition2, that = this,
                    startPosition = that._startPosition,
                    endPosition = that._endPosition,
                    space = that._space,
                    basePosition = that._basePosition,
                    actualPosition = that._actualPosition;
                if (startPosition < endPosition) {
                    if (basePosition < actualPosition) {
                        mainPosition1 = basePosition;
                        mainPosition2 = actualPosition
                    } else {
                        mainPosition1 = actualPosition;
                        mainPosition2 = basePosition
                    }
                    backPosition1 = mainPosition1 - space;
                    backPosition2 = mainPosition2 + space
                } else {
                    if (basePosition > actualPosition) {
                        mainPosition1 = basePosition;
                        mainPosition2 = actualPosition
                    } else {
                        mainPosition1 = actualPosition;
                        mainPosition2 = basePosition
                    }
                    backPosition1 = mainPosition1 + space;
                    backPosition2 = mainPosition2 - space
                }
                return {
                    start: startPosition,
                    end: endPosition,
                    main1: mainPosition1,
                    main2: mainPosition2,
                    back1: backPosition1,
                    back2: backPosition2
                }
            },
            _buildItemSettings: function(from, to) {
                var that = this,
                    side1 = that._minSide,
                    side2 = that._maxSide,
                    points = that.vertical ? [side1, from, side1, to, side2, to, side2, from] : [from, side1, from, side2, to, side2, to, side1];
                return {
                    points: points
                }
            },
            _updateTextPosition: function() {
                var that = this;
                that._text.attr(that.vertical ? {
                    x: that._textPosition,
                    y: that._actualPosition + that._textVerticalOffset
                } : {
                    x: that._actualPosition,
                    y: that._textPosition + that._textVerticalOffset
                })
            },
            _updateLinePosition: function() {
                var side1, side2, points, that = this,
                    actualPosition = that._actualPosition;
                if (that.vertical) {
                    if (that._basePosition >= actualPosition) {
                        side1 = actualPosition;
                        side2 = actualPosition + 2
                    } else {
                        side1 = actualPosition - 2;
                        side2 = actualPosition
                    }
                    points = [that._lineStart, side1, that._lineStart, side2, that._lineEnd, side2, that._lineEnd, side1]
                } else {
                    if (that._basePosition <= actualPosition) {
                        side1 = actualPosition - 2;
                        side2 = actualPosition
                    } else {
                        side1 = actualPosition;
                        side2 = actualPosition + 2
                    }
                    points = [side1, that._lineStart, side1, that._lineEnd, side2, that._lineEnd, side2, that._lineStart]
                }
                that._line.attr({
                    points: points
                }).sharp()
            },
            _getTooltipPosition: function() {
                var that = this,
                    crossCenter = (that._minSide + that._maxSide) / 2,
                    alongCenter = (that._basePosition + that._actualPosition) / 2;
                return that.vertical ? {
                    x: crossCenter,
                    y: alongCenter
                } : {
                    x: alongCenter,
                    y: crossCenter
                }
            },
            measure: function(layout) {
                var minbound, maxbound, indent, that = this,
                    size = _Number(that._options.size),
                    textIndent = _Number(that._options.text.indent);
                that._measureText();
                if (that.vertical) {
                    minbound = maxbound = layout.x;
                    if (that._inverted) {
                        maxbound += size
                    } else {
                        minbound -= size
                    }
                    if (that._hasText) {
                        indent = that._textHeight / 2;
                        if (textIndent > 0) {
                            maxbound += textIndent + that._textWidth
                        }
                        if (textIndent < 0) {
                            minbound += textIndent - that._textWidth
                        }
                    }
                } else {
                    minbound = maxbound = layout.y;
                    if (that._inverted) {
                        maxbound += size
                    } else {
                        minbound -= size
                    }
                    if (that._hasText) {
                        indent = that._textWidth / 2;
                        if (textIndent > 0) {
                            maxbound += textIndent + that._textHeight
                        }
                        if (textIndent < 0) {
                            minbound += textIndent - that._textHeight
                        }
                    }
                }
                return {
                    min: minbound,
                    max: maxbound,
                    indent: indent
                }
            }
        });
        exports._default = rangebar;
        exports.rectangle = rectangle;
        exports.rhombus = rhombus;
        exports.circle = circle;
        exports.trianglemarker = trianglemarker;
        exports.textcloud = textcloud;
        exports.rangebar = rangebar
    },
    /*!***********************************************!*\
      !*** ./Scripts/viz/gauges/base_indicators.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _isFinite = isFinite,
            _Number = Number,
            _round = Math.round,
            baseGaugeModule = __webpack_require__( /*! ./base_gauge */ 524),
            _formatValue = baseGaugeModule.formatValue,
            _getSampleText = baseGaugeModule.getSampleText,
            _patchFontOptions = __webpack_require__( /*! ../core/utils */ 442).patchFontOptions,
            Class = __webpack_require__( /*! ../../core/class */ 20);
        var BaseElement = Class.inherit({
            ctor: function(parameters) {
                var that = this;
                $.each(parameters, function(name, value) {
                    that["_" + name] = value
                });
                that._init()
            },
            dispose: function() {
                var that = this;
                that._dispose();
                $.each(that, function(name) {
                    that[name] = null
                });
                return that
            },
            getOffset: function() {
                return _Number(this._options.offset) || 0
            }
        });
        var BaseIndicator = BaseElement.inherit({
            _init: function() {
                var that = this;
                that._rootElement = that._createRoot().linkOn(that._owner, {
                    name: "value-indicator",
                    after: "core"
                });
                that._trackerElement = that._createTracker()
            },
            _dispose: function() {
                this._rootElement.linkOff()
            },
            _setupAnimation: function() {
                var that = this;
                if (that._options.animation) {
                    that._animation = {
                        step: function(pos) {
                            that._actualValue = that._animation.start + that._animation.delta * pos;
                            that._actualPosition = that._translator.translate(that._actualValue);
                            that._move()
                        },
                        duration: that._options.animation.duration > 0 ? _Number(that._options.animation.duration) : 0,
                        easing: that._options.animation.easing
                    }
                }
            },
            _runAnimation: function(value) {
                var that = this,
                    animation = that._animation;
                animation.start = that._actualValue;
                animation.delta = value - that._actualValue;
                that._rootElement.animate({
                    _: 0
                }, {
                    step: animation.step,
                    duration: animation.duration,
                    easing: animation.easing
                })
            },
            _createRoot: function() {
                return this._renderer.g().attr({
                    "class": this._className
                })
            },
            _createTracker: function() {
                return this._renderer.path([], "area")
            },
            _getTrackerSettings: $.noop,
            clean: function() {
                var that = this;
                that._animation && that._rootElement.stopAnimation();
                that._rootElement.linkRemove().clear();
                that._clear();
                that._tracker.detach(that._trackerElement);
                that._options = that.enabled = that._animation = null;
                return that
            },
            render: function(options) {
                var that = this;
                that.type = options.type;
                that._options = options;
                that._actualValue = that._currentValue = that._translator.adjust(that._options.currentValue);
                that.enabled = that._isEnabled();
                if (that.enabled) {
                    that._setupAnimation();
                    that._rootElement.attr({
                        fill: that._options.color
                    }).linkAppend();
                    that._tracker.attach(that._trackerElement, that, that._trackerInfo)
                }
                return that
            },
            resize: function(layout) {
                var that = this;
                that._rootElement.clear();
                that._clear();
                that.visible = that._isVisible(layout);
                if (that.visible) {
                    $.extend(that._options, layout);
                    that._actualPosition = that._translator.translate(that._actualValue);
                    that._render();
                    that._trackerElement.attr(that._getTrackerSettings());
                    that._move()
                }
                return that
            },
            value: function(arg, _noAnimation) {
                var val, that = this;
                if (void 0 !== arg) {
                    val = that._translator.adjust(arg);
                    if (that._currentValue !== val && _isFinite(val)) {
                        that._currentValue = val;
                        if (that.visible) {
                            if (that._animation && !_noAnimation) {
                                that._runAnimation(val)
                            } else {
                                that._actualValue = val;
                                that._actualPosition = that._translator.translate(val);
                                that._move()
                            }
                        }
                    }
                    return that
                }
                return that._currentValue
            },
            _isEnabled: null,
            _isVisible: null,
            _render: null,
            _clear: null,
            _move: null
        });
        var COEFFICIENTS_MAP = {};
        COEFFICIENTS_MAP["right-bottom"] = COEFFICIENTS_MAP.rb = [0, -1, -1, 0, 0, 1, 1, 0];
        COEFFICIENTS_MAP["bottom-right"] = COEFFICIENTS_MAP.br = [-1, 0, 0, -1, 1, 0, 0, 1];
        COEFFICIENTS_MAP["left-bottom"] = COEFFICIENTS_MAP.lb = [0, -1, 1, 0, 0, 1, -1, 0];
        COEFFICIENTS_MAP["bottom-left"] = COEFFICIENTS_MAP.bl = [1, 0, 0, -1, -1, 0, 0, 1];
        COEFFICIENTS_MAP["left-top"] = COEFFICIENTS_MAP.lt = [0, 1, 1, 0, 0, -1, -1, 0];
        COEFFICIENTS_MAP["top-left"] = COEFFICIENTS_MAP.tl = [1, 0, 0, 1, -1, 0, 0, -1];
        COEFFICIENTS_MAP["right-top"] = COEFFICIENTS_MAP.rt = [0, 1, -1, 0, 0, -1, 1, 0];
        COEFFICIENTS_MAP["top-right"] = COEFFICIENTS_MAP.tr = [-1, 0, 0, 1, 1, 0, 0, -1];

        function getTextCloudInfo(options) {
            var tailWidth, tailHeight, x = options.x,
                y = options.y,
                type = COEFFICIENTS_MAP[options.type],
                cloudWidth = options.textWidth + 2 * options.horMargin,
                cloudHeight = options.textHeight + 2 * options.verMargin,
                cx = x,
                cy = y;
            tailWidth = tailHeight = options.tailLength;
            if (1 & type[0]) {
                tailHeight = Math.min(tailHeight, cloudHeight / 3)
            } else {
                tailWidth = Math.min(tailWidth, cloudWidth / 3)
            }
            return {
                cx: _round(cx + type[0] * tailWidth + (type[0] + type[2]) * cloudWidth / 2),
                cy: _round(cy + type[1] * tailHeight + (type[1] + type[3]) * cloudHeight / 2),
                points: [_round(x), _round(y), _round(x += type[0] * (cloudWidth + tailWidth)), _round(y += type[1] * (cloudHeight + tailHeight)), _round(x += type[2] * cloudWidth), _round(y += type[3] * cloudHeight), _round(x += type[4] * cloudWidth), _round(y += type[5] * cloudHeight), _round(x += type[6] * (cloudWidth - tailWidth)), _round(y += type[7] * (cloudHeight - tailHeight))]
            }
        }
        var BaseTextCloudMarker = BaseIndicator.inherit({
            _move: function() {
                var bbox, info, that = this,
                    textCloudOptions = that._getTextCloudOptions(),
                    text = _formatValue(that._actualValue, that._options.text);
                that._text.attr({
                    text: text
                });
                bbox = that._text.getBBox();
                info = getTextCloudInfo({
                    x: textCloudOptions.x,
                    y: textCloudOptions.y,
                    textWidth: bbox.width || text.length * that._textUnitWidth,
                    textHeight: bbox.height || that._textHeight,
                    horMargin: that._options.horizontalOffset,
                    verMargin: that._options.verticalOffset,
                    tailLength: that._options.arrowLength,
                    type: textCloudOptions.type
                });
                that._text.attr({
                    x: info.cx,
                    y: info.cy + that._textVerticalOffset
                });
                that._cloud.attr({
                    points: info.points
                });
                that._trackerElement && that._trackerElement.attr({
                    points: info.points
                })
            },
            _measureText: function() {
                var root, text, bbox, sampleText, that = this;
                if (!that._textVerticalOffset) {
                    root = that._createRoot().append(that._owner);
                    sampleText = _getSampleText(that._translator, that._options.text);
                    text = that._renderer.text(sampleText, 0, 0).attr({
                        align: "center"
                    }).css(_patchFontOptions(that._options.text.font)).append(root);
                    bbox = text.getBBox();
                    root.remove();
                    that._textVerticalOffset = -bbox.y - bbox.height / 2;
                    that._textWidth = bbox.width;
                    that._textHeight = bbox.height;
                    that._textUnitWidth = that._textWidth / sampleText.length;
                    that._textFullWidth = that._textWidth + 2 * that._options.horizontalOffset;
                    that._textFullHeight = that._textHeight + 2 * that._options.verticalOffset
                }
            },
            _render: function() {
                var that = this;
                that._measureText();
                that._cloud = that._cloud || that._renderer.path([], "area").append(that._rootElement);
                that._text = that._text || that._renderer.text().append(that._rootElement);
                that._text.attr({
                    align: "center"
                }).css(_patchFontOptions(that._options.text.font))
            },
            _clear: function() {
                delete this._cloud;
                delete this._text
            },
            getTooltipParameters: function() {
                var position = this._getTextCloudOptions();
                return {
                    x: position.x,
                    y: position.y,
                    value: this._currentValue,
                    color: this._options.color
                }
            }
        });
        var BaseRangeBar = BaseIndicator.inherit({
            _measureText: function() {
                var root, text, bbox, that = this;
                that._hasText = that._isTextVisible();
                if (that._hasText && !that._textVerticalOffset) {
                    root = that._createRoot().append(that._owner);
                    text = that._renderer.text(_getSampleText(that._translator, that._options.text), 0, 0).attr({
                        "class": "dxg-text",
                        align: "center"
                    }).css(_patchFontOptions(that._options.text.font)).append(root);
                    bbox = text.getBBox();
                    root.remove();
                    that._textVerticalOffset = -bbox.y - bbox.height / 2;
                    that._textWidth = bbox.width;
                    that._textHeight = bbox.height
                }
            },
            _move: function() {
                var that = this;
                that._updateBarItemsPositions();
                if (that._hasText) {
                    that._text.attr({
                        text: _formatValue(that._actualValue, that._options.text)
                    });
                    that._updateTextPosition();
                    that._updateLinePosition()
                }
            },
            _updateBarItems: function() {
                var backgroundColor, spaceColor, that = this,
                    options = that._options,
                    translator = that._translator;
                that._setBarSides();
                that._startPosition = translator.translate(translator.getDomainStart());
                that._endPosition = translator.translate(translator.getDomainEnd());
                that._basePosition = translator.translate(options.baseValue);
                that._space = that._getSpace();
                backgroundColor = options.backgroundColor || "none";
                if ("none" !== backgroundColor && that._space > 0) {
                    spaceColor = options.containerBackgroundColor || "none"
                } else {
                    that._space = 0;
                    spaceColor = "none"
                }
                that._backItem1.attr({
                    fill: backgroundColor
                });
                that._backItem2.attr({
                    fill: backgroundColor
                });
                that._spaceItem1.attr({
                    fill: spaceColor
                });
                that._spaceItem2.attr({
                    fill: spaceColor
                })
            },
            _getSpace: function() {
                return 0
            },
            _updateTextItems: function() {
                var that = this;
                if (that._hasText) {
                    that._line = that._line || that._renderer.path([], "line").attr({
                        "class": "dxg-main-bar",
                        "stroke-linecap": "square"
                    }).append(that._rootElement);
                    that._text = that._text || that._renderer.text("", 0, 0).attr({
                        "class": "dxg-text"
                    }).append(that._rootElement);
                    that._text.attr({
                        align: that._getTextAlign()
                    }).css(that._getFontOptions());
                    that._setTextItemsSides()
                } else {
                    if (that._line) {
                        that._line.remove();
                        delete that._line
                    }
                    if (that._text) {
                        that._text.remove();
                        delete that._text
                    }
                }
            },
            _isTextVisible: function() {
                return false
            },
            _getTextAlign: function() {
                return "center"
            },
            _getFontOptions: function() {
                var options = this._options,
                    font = options.text.font;
                if (!font || !font.color) {
                    font = $.extend({}, font, {
                        color: options.color
                    })
                }
                return _patchFontOptions(font)
            },
            _updateBarItemsPositions: function() {
                var that = this,
                    positions = that._getPositions();
                that._backItem1.attr(that._buildItemSettings(positions.start, positions.back1));
                that._backItem2.attr(that._buildItemSettings(positions.back2, positions.end));
                that._spaceItem1.attr(that._buildItemSettings(positions.back1, positions.main1));
                that._spaceItem2.attr(that._buildItemSettings(positions.main2, positions.back2));
                that._mainItem.attr(that._buildItemSettings(positions.main1, positions.main2));
                that._trackerElement && that._trackerElement.attr(that._buildItemSettings(positions.main1, positions.main2))
            },
            _render: function() {
                var that = this;
                that._measureText();
                if (!that._backItem1) {
                    that._backItem1 = that._createBarItem();
                    that._backItem1.attr({
                        "class": "dxg-back-bar"
                    })
                }
                if (!that._backItem2) {
                    that._backItem2 = that._createBarItem();
                    that._backItem2.attr({
                        "class": "dxg-back-bar"
                    })
                }
                if (!that._spaceItem1) {
                    that._spaceItem1 = that._createBarItem();
                    that._spaceItem1.attr({
                        "class": "dxg-space-bar"
                    })
                }
                if (!that._spaceItem2) {
                    that._spaceItem2 = that._createBarItem();
                    that._spaceItem2.attr({
                        "class": "dxg-space-bar"
                    })
                }
                if (!that._mainItem) {
                    that._mainItem = that._createBarItem();
                    that._mainItem.attr({
                        "class": "dxg-main-bar"
                    })
                }
                that._updateBarItems();
                that._updateTextItems()
            },
            _clear: function() {
                var that = this;
                delete that._backItem1;
                delete that._backItem2;
                delete that._spaceItem1;
                delete that._spaceItem2;
                delete that._mainItem;
                delete that._hasText;
                delete that._line;
                delete that._text
            },
            getTooltipParameters: function() {
                var position = this._getTooltipPosition();
                return {
                    x: position.x,
                    y: position.y,
                    value: this._currentValue,
                    color: this._options.color,
                    offset: 0
                }
            }
        });
        exports.BaseElement = BaseElement;
        exports.BaseIndicator = BaseIndicator;
        exports.BaseTextCloudMarker = BaseTextCloudMarker;
        exports.BaseRangeBar = BaseRangeBar;
        exports.getTextCloudInfo = getTextCloudInfo
    },
    /*!******************************************************!*\
      !*** ./Scripts/viz/gauges/linear_range_container.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var BaseRangeContainer = __webpack_require__( /*! ./base_range_container */ 530),
            _Number = Number,
            _max = Math.max,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum;
        var LinearRangeContainer = BaseRangeContainer.inherit({
            _processOptions: function() {
                var that = this;
                that.vertical = that._options.vertical;
                that._inner = that._outer = 0;
                if (that.vertical) {
                    switch (_normalizeEnum(that._options.horizontalOrientation)) {
                        case "left":
                            that._inner = 1;
                            break;
                        case "center":
                            that._inner = that._outer = .5;
                            break;
                        default:
                            that._outer = 1
                    }
                } else {
                    switch (_normalizeEnum(that._options.verticalOrientation)) {
                        case "top":
                            that._inner = 1;
                            break;
                        case "center":
                        case "middle":
                            that._inner = that._outer = .5;
                            break;
                        default:
                            that._outer = 1
                    }
                }
            },
            _isVisible: function() {
                return true
            },
            _createRange: function(range, layout) {
                var points, that = this,
                    inner = that._inner,
                    outer = that._outer,
                    startPosition = that._translator.translate(range.start),
                    endPosition = that._translator.translate(range.end),
                    x = layout.x,
                    y = layout.y,
                    startWidth = range.startWidth,
                    endWidth = range.endWidth;
                if (that.vertical) {
                    points = [x - startWidth * inner, startPosition, x - endWidth * inner, endPosition, x + endWidth * outer, endPosition, x + startWidth * outer, startPosition]
                } else {
                    points = [startPosition, y + startWidth * outer, startPosition, y - startWidth * inner, endPosition, y - endWidth * inner, endPosition, y + endWidth * outer]
                }
                return that._renderer.path(points, "area")
            },
            measure: function(layout) {
                var width, result = {};
                result.min = result.max = layout[this.vertical ? "x" : "y"];
                width = this._options.width;
                width = _Number(width) || _max(_Number(width.start), _Number(width.end));
                result.min -= this._inner * width;
                result.max += this._outer * width;
                return result
            }
        });
        module.exports = LinearRangeContainer
    },
    /*!****************************************************!*\
      !*** ./Scripts/viz/gauges/base_range_container.js ***!
      \****************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseElement = __webpack_require__( /*! ./base_indicators */ 528).BaseElement,
            _Number = Number,
            _abs = Math.abs,
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            _isString = commonUtils.isString,
            _isArray = commonUtils.isArray,
            _isFinite = isFinite,
            _each = $.each,
            _map = $.map;
        var BaseRangeContainer = BaseElement.inherit({
            _init: function() {
                this._root = this._renderer.g().attr({
                    "class": "dxg-range-container"
                }).linkOn(this._container, "range-container")
            },
            _dispose: function() {
                this._root.linkOff()
            },
            clean: function() {
                this._root.linkRemove().clear();
                this._options = this.enabled = null;
                return this
            },
            _getRanges: function() {
                var that = this,
                    options = that._options,
                    translator = that._translator,
                    totalStart = translator.getDomain()[0],
                    totalEnd = translator.getDomain()[1],
                    totalDelta = totalEnd - totalStart,
                    isNotEmptySegment = totalDelta >= 0 ? isNotEmptySegmentAsc : isNotEmptySegmentDes,
                    subtractSegment = totalDelta >= 0 ? subtractSegmentAsc : subtractSegmentDes,
                    list = [],
                    ranges = [],
                    backgroundRanges = [{
                        start: totalStart,
                        end: totalEnd
                    }],
                    threshold = _abs(totalDelta) / 1e4,
                    palette = that._themeManager.createPalette(options.palette, {
                        type: "indicatingSet"
                    }),
                    backgroundColor = _isString(options.backgroundColor) ? options.backgroundColor : "none",
                    width = options.width || {},
                    startWidth = _Number(width > 0 ? width : width.start),
                    endWidth = _Number(width > 0 ? width : width.end),
                    deltaWidth = endWidth - startWidth;
                if (void 0 !== options.ranges && !_isArray(options.ranges)) {
                    return null
                }
                if (!(startWidth >= 0 && endWidth >= 0 && startWidth + endWidth > 0)) {
                    return null
                }
                list = _map(_isArray(options.ranges) ? options.ranges : [], function(rangeOptions, i) {
                    rangeOptions = rangeOptions || {};
                    var start = translator.adjust(rangeOptions.startValue),
                        end = translator.adjust(rangeOptions.endValue);
                    return _isFinite(start) && _isFinite(end) && isNotEmptySegment(start, end, threshold) ? {
                        start: start,
                        end: end,
                        color: rangeOptions.color,
                        classIndex: i
                    } : null
                });
                _each(list, function(i, item) {
                    var paletteColor = palette.getNextColor();
                    item.color = _isString(item.color) && item.color || paletteColor || "none";
                    item.className = "dxg-range dxg-range-" + item.classIndex;
                    delete item.classIndex
                });
                _each(list, function(_, item) {
                    var i, ii, sub, subs, range, newRanges = [],
                        newBackgroundRanges = [];
                    for (i = 0, ii = ranges.length; i < ii; ++i) {
                        range = ranges[i];
                        subs = subtractSegment(range.start, range.end, item.start, item.end);
                        (sub = subs[0]) && (sub.color = range.color) && (sub.className = range.className) && newRanges.push(sub);
                        (sub = subs[1]) && (sub.color = range.color) && (sub.className = range.className) && newRanges.push(sub)
                    }
                    newRanges.push(item);
                    ranges = newRanges;
                    for (i = 0, ii = backgroundRanges.length; i < ii; ++i) {
                        range = backgroundRanges[i];
                        subs = subtractSegment(range.start, range.end, item.start, item.end);
                        (sub = subs[0]) && newBackgroundRanges.push(sub);
                        (sub = subs[1]) && newBackgroundRanges.push(sub)
                    }
                    backgroundRanges = newBackgroundRanges
                });
                _each(backgroundRanges, function(_, range) {
                    range.color = backgroundColor;
                    range.className = "dxg-range dxg-background-range";
                    ranges.push(range)
                });
                _each(ranges, function(_, range) {
                    range.startWidth = (range.start - totalStart) / totalDelta * deltaWidth + startWidth;
                    range.endWidth = (range.end - totalStart) / totalDelta * deltaWidth + startWidth
                });
                return ranges
            },
            render: function(options) {
                var that = this;
                that._options = options;
                that._processOptions();
                that._ranges = that._getRanges();
                if (that._ranges) {
                    that.enabled = true;
                    that._root.linkAppend()
                }
                return that
            },
            resize: function(layout) {
                var that = this;
                that._root.clear();
                if (that._isVisible(layout)) {
                    _each(that._ranges, function(_, range) {
                        that._createRange(range, layout).attr({
                            fill: range.color,
                            "class": range.className
                        }).append(that._root)
                    })
                }
                return that
            },
            _processOptions: null,
            _isVisible: null,
            _createRange: null,
            getColorForValue: function(value) {
                var color = null;
                _each(this._ranges, function(_, range) {
                    if (range.start <= value && value <= range.end || range.start >= value && value >= range.end) {
                        color = range.color;
                        return false
                    }
                });
                return color
            }
        });

        function subtractSegmentAsc(segmentStart, segmentEnd, otherStart, otherEnd) {
            var result;
            if (otherStart > segmentStart && otherEnd < segmentEnd) {
                result = [{
                    start: segmentStart,
                    end: otherStart
                }, {
                    start: otherEnd,
                    end: segmentEnd
                }]
            } else {
                if (otherStart >= segmentEnd || otherEnd <= segmentStart) {
                    result = [{
                        start: segmentStart,
                        end: segmentEnd
                    }]
                } else {
                    if (otherStart <= segmentStart && otherEnd >= segmentEnd) {
                        result = []
                    } else {
                        if (otherStart > segmentStart) {
                            result = [{
                                start: segmentStart,
                                end: otherStart
                            }]
                        } else {
                            if (otherEnd < segmentEnd) {
                                result = [{
                                    start: otherEnd,
                                    end: segmentEnd
                                }]
                            }
                        }
                    }
                }
            }
            return result
        }

        function subtractSegmentDes(segmentStart, segmentEnd, otherStart, otherEnd) {
            var result;
            if (otherStart < segmentStart && otherEnd > segmentEnd) {
                result = [{
                    start: segmentStart,
                    end: otherStart
                }, {
                    start: otherEnd,
                    end: segmentEnd
                }]
            } else {
                if (otherStart <= segmentEnd || otherEnd >= segmentStart) {
                    result = [{
                        start: segmentStart,
                        end: segmentEnd
                    }]
                } else {
                    if (otherStart >= segmentStart && otherEnd <= segmentEnd) {
                        result = []
                    } else {
                        if (otherStart < segmentStart) {
                            result = [{
                                start: segmentStart,
                                end: otherStart
                            }]
                        } else {
                            if (otherEnd > segmentEnd) {
                                result = [{
                                    start: otherEnd,
                                    end: segmentEnd
                                }]
                            }
                        }
                    }
                }
            }
            return result
        }

        function isNotEmptySegmentAsc(start, end, threshold) {
            return end - start >= threshold
        }

        function isNotEmptySegmentDes(start, end, threshold) {
            return start - end >= threshold
        }
        module.exports = BaseRangeContainer
    },
    /*!*********************************************!*\
      !*** ./Scripts/viz/gauges/theme_manager.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _extend = $.extend,
            BaseThemeManager = __webpack_require__( /*! ../core/base_theme_manager */ 485).BaseThemeManager;
        var ThemeManager = BaseThemeManager.inherit({
            _themeSection: "gauge",
            _fontFields: ["scale.label.font", "valueIndicators.rangebar.text.font", "valueIndicators.textcloud.text.font", "title.font", "title.subtitle.font", "tooltip.font", "indicator.text.font", "loadingIndicator.font", "export.font"],
            _initializeTheme: function() {
                var subTheme, that = this;
                if (that._subTheme) {
                    subTheme = _extend(true, {}, that._theme[that._subTheme], that._theme);
                    _extend(true, that._theme, subTheme)
                }
                that.callBase.apply(that, arguments)
            }
        });
        module.exports = ThemeManager
    },
    /*!***************************************!*\
      !*** ./Scripts/viz/circular_gauge.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./gauges/circular_gauge */ 533)
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/gauges/circular_gauge.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _isFinite = isFinite,
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            dxBaseGauge = __webpack_require__( /*! ./base_gauge */ 524).dxBaseGauge,
            dxGauge = __webpack_require__( /*! ./common */ 526).dxGauge,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _normalizeAngle = vizUtils.normalizeAngle,
            _getCosAndSin = vizUtils.getCosAndSin,
            polarTranslatorModule = __webpack_require__( /*! ../translators/polar_translator */ 521),
            circularIndicatorsModule = __webpack_require__( /*! ./circular_indicators */ 534),
            createIndicatorCreator = __webpack_require__( /*! ./common */ 526).createIndicatorCreator,
            CircularRangeContainer = __webpack_require__( /*! ./circular_range_container */ 535),
            ThemeManager = __webpack_require__( /*! ./theme_manager */ 531),
            _abs = Math.abs,
            _max = Math.max,
            _min = Math.min,
            _round = Math.round,
            _each = $.each,
            SHIFT_ANGLE = 90,
            PI = Math.PI;

        function getSides(startAngle, endAngle) {
            var startCosSin = _getCosAndSin(startAngle),
                endCosSin = _getCosAndSin(endAngle),
                startCos = startCosSin.cos,
                startSin = startCosSin.sin,
                endCos = endCosSin.cos,
                endSin = endCosSin.sin;
            return {
                left: startSin <= 0 && endSin >= 0 || startSin <= 0 && endSin <= 0 && startCos <= endCos || startSin >= 0 && endSin >= 0 && startCos >= endCos ? -1 : _min(startCos, endCos, 0),
                right: startSin >= 0 && endSin <= 0 || startSin >= 0 && endSin >= 0 && startCos >= endCos || startSin <= 0 && endSin <= 0 && startCos <= endCos ? 1 : _max(startCos, endCos, 0),
                up: startCos <= 0 && endCos >= 0 || startCos <= 0 && endCos <= 0 && startSin >= endSin || startCos >= 0 && endCos >= 0 && startSin <= endSin ? -1 : -_max(startSin, endSin, 0),
                down: startCos >= 0 && endCos <= 0 || startCos >= 0 && endCos >= 0 && startSin <= endSin || startCos <= 0 && endCos <= 0 && startSin >= endSin ? 1 : -_min(startSin, endSin, 0)
            }
        }
        var dxCircularGauge = dxGauge.inherit({
            _rootClass: "dxg-circular-gauge",
            _factoryMethods: {
                rangeContainer: "createCircularRangeContainer",
                indicator: "createCircularIndicator"
            },
            _gridSpacingFactor: 17,
            _scaleTypes: {
                type: "polarAxes",
                drawingType: "circular"
            },
            _initScaleTranslator: function(range) {
                return new polarTranslatorModule.PolarTranslator({
                    arg: range,
                    val: {}
                }, this._canvas, {})
            },
            _getScaleTranslatorComponent: function(name) {
                return this._scaleTranslator.getComponent(name)
            },
            _updateScaleTickIndent: function(scaleOptions) {
                var indentFromTick = scaleOptions.label.indentFromTick,
                    length = scaleOptions.tick.length,
                    textParams = this._scale.measureLabels(),
                    tickCorrection = length;
                if ("inside" === scaleOptions.orientation) {
                    tickCorrection = 0
                } else {
                    if ("center" === scaleOptions.orientation) {
                        tickCorrection = .5 * length
                    }
                }
                scaleOptions.label.indentFromAxis = indentFromTick >= 0 ? indentFromTick + tickCorrection : indentFromTick - tickCorrection - _max(textParams.width, textParams.height);
                this._scale.updateOptions(scaleOptions)
            },
            _updateScaleAngles: function() {
                var angles = this._translator.getCodomain();
                this._scaleTranslator.setAngles(SHIFT_ANGLE - angles[0], SHIFT_ANGLE - angles[1])
            },
            _setupCodomain: function() {
                var sides, that = this,
                    geometry = that.option("geometry") || {},
                    startAngle = geometry.startAngle,
                    endAngle = geometry.endAngle;
                startAngle = _isFinite(startAngle) ? _normalizeAngle(startAngle) : 225;
                endAngle = _isFinite(endAngle) ? _normalizeAngle(endAngle) : -45;
                if (_abs(startAngle - endAngle) < 1) {
                    endAngle -= 360;
                    sides = {
                        left: -1,
                        up: -1,
                        right: 1,
                        down: 1
                    }
                } else {
                    startAngle < endAngle && (endAngle -= 360);
                    sides = getSides(startAngle, endAngle)
                }
                that._area = {
                    x: 0,
                    y: 0,
                    radius: 100,
                    startCoord: startAngle,
                    endCoord: endAngle,
                    sides: sides
                };
                that._translator.setCodomain(startAngle, endAngle)
            },
            _shiftScale: function(layout) {
                var centerCoords, scaleTranslator = this._scaleTranslator,
                    scale = this._scale;
                scaleTranslator.setCanvasDimension(2 * layout.radius);
                scale.setTranslator(scaleTranslator.getComponent("arg"), scaleTranslator.getComponent("val"));
                scale.draw();
                centerCoords = scaleTranslator.getCenter();
                scale.shift(layout.x - centerCoords.x, layout.y - centerCoords.y)
            },
            _getScaleLayoutValue: function() {
                return this._area.radius
            },
            _getTicksOrientation: function(scaleOptions) {
                return scaleOptions.orientation
            },
            _getTicksCoefficients: function(options) {
                var coefs = {
                    inner: 0,
                    outer: 1
                };
                if ("inside" === options.orientation) {
                    coefs.inner = 1;
                    coefs.outer = 0
                } else {
                    if ("center" === options.orientation) {
                        coefs.inner = coefs.outer = .5
                    }
                }
                return coefs
            },
            _correctScaleIndents: function(result, indentFromTick, textParams) {
                if (indentFromTick >= 0) {
                    result.horizontalOffset = indentFromTick + textParams.width;
                    result.verticalOffset = indentFromTick + textParams.height
                } else {
                    result.horizontalOffset = result.verticalOffset = 0;
                    result.min -= -indentFromTick + _max(textParams.width, textParams.height)
                }
                result.inverseHorizontalOffset = textParams.width / 2;
                result.inverseVerticalOffset = textParams.height / 2
            },
            _measureMainElements: function(elements, scaleMeasurement) {
                var that = this,
                    radius = that._area.radius,
                    maxRadius = 0,
                    minRadius = 1 / 0,
                    maxHorizontalOffset = 0,
                    maxVerticalOffset = 0,
                    maxInverseHorizontalOffset = 0,
                    maxInverseVerticalOffset = 0,
                    scale = that._scale;
                _each(elements.concat(scale), function(_, element) {
                    var bounds = element.measure ? element.measure({
                        radius: radius - element.getOffset()
                    }) : scaleMeasurement;
                    bounds.min > 0 && (minRadius = _min(minRadius, bounds.min));
                    bounds.max > 0 && (maxRadius = _max(maxRadius, bounds.max));
                    bounds.horizontalOffset > 0 && (maxHorizontalOffset = _max(maxHorizontalOffset, bounds.max + bounds.horizontalOffset));
                    bounds.verticalOffset > 0 && (maxVerticalOffset = _max(maxVerticalOffset, bounds.max + bounds.verticalOffset));
                    bounds.inverseHorizontalOffset > 0 && (maxInverseHorizontalOffset = _max(maxInverseHorizontalOffset, bounds.inverseHorizontalOffset));
                    bounds.inverseVerticalOffset > 0 && (maxInverseVerticalOffset = _max(maxInverseVerticalOffset, bounds.inverseVerticalOffset))
                });
                maxHorizontalOffset = _max(maxHorizontalOffset - maxRadius, 0);
                maxVerticalOffset = _max(maxVerticalOffset - maxRadius, 0);
                return {
                    minRadius: minRadius,
                    maxRadius: maxRadius,
                    horizontalMargin: maxHorizontalOffset,
                    verticalMargin: maxVerticalOffset,
                    inverseHorizontalMargin: maxInverseHorizontalOffset,
                    inverseVerticalMargin: maxInverseVerticalOffset
                }
            },
            _applyMainLayout: function(elements, scaleMeasurement) {
                var x, y, measurements = this._measureMainElements(elements, scaleMeasurement),
                    area = this._area,
                    sides = area.sides,
                    margins = {
                        left: (sides.left < -.1 ? measurements.horizontalMargin : measurements.inverseHorizontalMargin) || 0,
                        right: (sides.right > .1 ? measurements.horizontalMargin : measurements.inverseHorizontalMargin) || 0,
                        top: (sides.up < -.1 ? measurements.verticalMargin : measurements.inverseVerticalMargin) || 0,
                        bottom: (sides.down > .1 ? measurements.verticalMargin : measurements.inverseVerticalMargin) || 0
                    },
                    rect = selectRectByAspectRatio(this._innerRect, (sides.down - sides.up) / (sides.right - sides.left), margins),
                    radius = _min(getWidth(rect) / (sides.right - sides.left), getHeight(rect) / (sides.down - sides.up));
                radius = radius - measurements.maxRadius + area.radius;
                x = rect.left - getWidth(rect) * sides.left / (sides.right - sides.left);
                y = rect.top - getHeight(rect) * sides.up / (sides.down - sides.up);
                area.x = _round(x);
                area.y = _round(y);
                area.radius = radius;
                rect.left -= margins.left;
                rect.right += margins.right;
                rect.top -= margins.top;
                rect.bottom += margins.bottom;
                this._innerRect = rect
            },
            _getElementLayout: function(offset) {
                return {
                    x: this._area.x,
                    y: this._area.y,
                    radius: _round(this._area.radius - offset)
                }
            },
            _getApproximateScreenRange: function() {
                var that = this,
                    area = that._area,
                    r = _min(that._canvas.width / (area.sides.right - area.sides.left), that._canvas.height / (area.sides.down - area.sides.up));
                r > area.totalRadius && (r = area.totalRadius);
                r = .8 * r;
                return -that._translator.getCodomainRange() * r * PI / 180
            },
            _getDefaultSize: function() {
                return {
                    width: 300,
                    height: 300
                }
            },
            _factory: objectUtils.clone(dxBaseGauge.prototype._factory)
        });

        function getWidth(rect) {
            return rect.right - rect.left
        }

        function getHeight(rect) {
            return rect.bottom - rect.top
        }

        function selectRectByAspectRatio(srcRect, aspectRatio, margins) {
            var selfAspectRatio, rect = $.extend({}, srcRect),
                width = 0,
                height = 0;
            margins = margins || {};
            if (aspectRatio > 0) {
                rect.left += margins.left || 0;
                rect.right -= margins.right || 0;
                rect.top += margins.top || 0;
                rect.bottom -= margins.bottom || 0;
                if (getWidth(rect) > 0 && getHeight(rect) > 0) {
                    selfAspectRatio = getHeight(rect) / getWidth(rect);
                    if (selfAspectRatio > 1) {
                        aspectRatio < selfAspectRatio ? width = getWidth(rect) : height = getHeight(rect)
                    } else {
                        aspectRatio > selfAspectRatio ? height = getHeight(rect) : width = getWidth(rect)
                    }
                    width > 0 || (width = height / aspectRatio);
                    height > 0 || (height = width * aspectRatio);
                    width = (getWidth(rect) - width) / 2;
                    height = (getHeight(rect) - height) / 2;
                    rect.left += width;
                    rect.right -= width;
                    rect.top += height;
                    rect.bottom -= height
                } else {
                    rect.left = rect.right = (rect.left + rect.right) / 2;
                    rect.top = rect.bottom = (rect.top + rect.bottom) / 2
                }
            }
            return rect
        }
        dxCircularGauge._TESTS_selectRectByAspectRatio = selectRectByAspectRatio;
        var indicators = dxCircularGauge.prototype._factory.indicators = {};
        dxCircularGauge.prototype._factory.createIndicator = createIndicatorCreator(indicators);
        indicators._default = circularIndicatorsModule._default;
        indicators.rectangleneedle = circularIndicatorsModule.rectangleneedle;
        indicators.triangleneedle = circularIndicatorsModule.triangleneedle;
        indicators.twocolorneedle = circularIndicatorsModule.twocolorneedle;
        indicators.trianglemarker = circularIndicatorsModule.trianglemarker;
        indicators.textcloud = circularIndicatorsModule.textcloud;
        indicators.rangebar = circularIndicatorsModule.rangebar;
        dxCircularGauge.prototype._factory.RangeContainer = CircularRangeContainer;
        dxCircularGauge.prototype._factory.ThemeManager = ThemeManager.inherit({
            _subTheme: "_circular"
        });
        registerComponent("dxCircularGauge", dxCircularGauge);
        module.exports = dxCircularGauge
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/gauges/circular_indicators.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var baseIndicatorsModule = __webpack_require__( /*! ./base_indicators */ 528),
            BaseIndicator = baseIndicatorsModule.BaseIndicator,
            BaseTextCloudMarker = baseIndicatorsModule.BaseTextCloudMarker,
            BaseRangeBar = baseIndicatorsModule.BaseRangeBar,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _Number = Number,
            _getCosAndSin = vizUtils.getCosAndSin,
            _convertAngleToRendererSpace = vizUtils.convertAngleToRendererSpace;
        var SimpleIndicator = BaseIndicator.inherit({
            _move: function() {
                var that = this,
                    options = that._options,
                    angle = _convertAngleToRendererSpace(that._actualPosition);
                that._rootElement.rotate(angle, options.x, options.y);
                that._trackerElement && that._trackerElement.rotate(angle, options.x, options.y)
            },
            _isEnabled: function() {
                return this._options.width > 0
            },
            _isVisible: function(layout) {
                return layout.radius - _Number(this._options.indentFromCenter) > 0
            },
            _getTrackerSettings: function() {
                var options = this._options,
                    x = options.x,
                    y = options.y - (options.radius + _Number(options.indentFromCenter)) / 2,
                    width = options.width / 2,
                    length = (options.radius - _Number(options.indentFromCenter)) / 2;
                width > 10 || (width = 10);
                length > 10 || (length = 10);
                return {
                    points: [x - width, y - length, x - width, y + length, x + width, y + length, x + width, y - length]
                }
            },
            _renderSpindle: function() {
                var gapSize, that = this,
                    options = that._options;
                if (options.spindleSize > 0) {
                    gapSize = _Number(options.spindleGapSize) || 0;
                    if (gapSize > 0) {
                        gapSize = gapSize <= options.spindleSize ? gapSize : _Number(options.spindleSize)
                    }
                    that._spindleOuter = that._spindleOuter || that._renderer.circle().append(that._rootElement);
                    that._spindleInner = that._spindleInner || that._renderer.circle().append(that._rootElement);
                    that._spindleOuter.attr({
                        "class": "dxg-spindle-border",
                        cx: options.x,
                        cy: options.y,
                        r: options.spindleSize / 2
                    });
                    that._spindleInner.attr({
                        "class": "dxg-spindle-hole",
                        cx: options.x,
                        cy: options.y,
                        r: gapSize / 2,
                        fill: options.containerBackgroundColor
                    })
                }
            },
            _render: function() {
                var that = this;
                that._renderPointer();
                that._renderSpindle()
            },
            _clearSpindle: function() {
                delete this._spindleOuter;
                delete this._spindleInner
            },
            _clearPointer: function() {
                delete this._element
            },
            _clear: function() {
                this._clearPointer();
                this._clearSpindle()
            },
            measure: function(layout) {
                var result = {
                    max: layout.radius
                };
                if (this._options.indentFromCenter < 0) {
                    result.inverseHorizontalOffset = result.inverseVerticalOffset = -_Number(this._options.indentFromCenter)
                }
                return result
            },
            getTooltipParameters: function() {
                var options = this._options,
                    cossin = _getCosAndSin(this._actualPosition),
                    r = (options.radius + _Number(options.indentFromCenter)) / 2;
                return {
                    x: options.x + cossin.cos * r,
                    y: options.y - cossin.sin * r,
                    value: this._currentValue,
                    color: options.color,
                    offset: options.width / 2
                }
            }
        });
        var rectangleneedle = SimpleIndicator.inherit({
            _renderPointer: function() {
                var that = this,
                    options = that._options,
                    y2 = options.y - options.radius,
                    y1 = options.y - _Number(options.indentFromCenter),
                    x1 = options.x - options.width / 2,
                    x2 = x1 + _Number(options.width);
                that._element = that._element || that._renderer.path([], "area").append(that._rootElement);
                that._element.attr({
                    points: [x1, y1, x1, y2, x2, y2, x2, y1]
                })
            }
        });
        var triangleneedle = SimpleIndicator.inherit({
            _renderPointer: function() {
                var that = this,
                    options = that._options,
                    y2 = options.y - options.radius,
                    y1 = options.y - _Number(options.indentFromCenter),
                    x1 = options.x - options.width / 2,
                    x2 = options.x + options.width / 2;
                that._element = that._element || that._renderer.path([], "area").append(that._rootElement);
                that._element.attr({
                    points: [x1, y1, options.x, y2, x2, y1]
                })
            }
        });
        var twocolorneedle = SimpleIndicator.inherit({
            _renderPointer: function() {
                var y2, y3, that = this,
                    options = that._options,
                    x1 = options.x - options.width / 2,
                    x2 = options.x + options.width / 2,
                    y4 = options.y - options.radius,
                    y1 = options.y - _Number(options.indentFromCenter),
                    fraction = _Number(options.secondFraction) || 0;
                if (fraction >= 1) {
                    y2 = y3 = y1
                } else {
                    if (fraction <= 0) {
                        y2 = y3 = y4
                    } else {
                        y3 = y4 + (y1 - y4) * fraction;
                        y2 = y3 + _Number(options.space)
                    }
                }
                that._firstElement = that._firstElement || that._renderer.path([], "area").append(that._rootElement);
                that._spaceElement = that._spaceElement || that._renderer.path([], "area").append(that._rootElement);
                that._secondElement = that._secondElement || that._renderer.path([], "area").append(that._rootElement);
                that._firstElement.attr({
                    points: [x1, y1, x1, y2, x2, y2, x2, y1]
                });
                that._spaceElement.attr({
                    points: [x1, y2, x1, y3, x2, y3, x2, y2],
                    "class": "dxg-hole",
                    fill: options.containerBackgroundColor
                });
                that._secondElement.attr({
                    points: [x1, y3, x1, y4, x2, y4, x2, y3],
                    "class": "dxg-part",
                    fill: options.secondColor
                })
            },
            _clearPointer: function() {
                delete this._firstElement;
                delete this._secondElement;
                delete this._spaceElement
            }
        });
        var trianglemarker = SimpleIndicator.inherit({
            _isEnabled: function() {
                return this._options.length > 0 && this._options.width > 0
            },
            _isVisible: function(layout) {
                return layout.radius > 0
            },
            _render: function() {
                var settings, that = this,
                    options = that._options,
                    x = options.x,
                    y1 = options.y - options.radius,
                    dx = options.width / 2 || 0,
                    y2 = y1 - _Number(options.length);
                that._element = that._element || that._renderer.path([], "area").append(that._rootElement);
                settings = {
                    points: [x, y1, x - dx, y2, x + dx, y2],
                    stroke: "none",
                    "stroke-width": 0,
                    "stroke-linecap": "square"
                };
                if (options.space > 0) {
                    settings["stroke-width"] = Math.min(options.space, options.width / 4) || 0;
                    settings.stroke = settings["stroke-width"] > 0 ? options.containerBackgroundColor || "none" : "none"
                }
                that._element.attr(settings).sharp()
            },
            _clear: function() {
                delete this._element
            },
            _getTrackerSettings: function() {
                var options = this._options,
                    x = options.x,
                    y = options.y - options.radius - options.length / 2,
                    width = options.width / 2,
                    length = options.length / 2;
                width > 10 || (width = 10);
                length > 10 || (length = 10);
                return {
                    points: [x - width, y - length, x - width, y + length, x + width, y + length, x + width, y - length]
                }
            },
            measure: function(layout) {
                return {
                    min: layout.radius,
                    max: layout.radius + _Number(this._options.length)
                }
            },
            getTooltipParameters: function() {
                var options = this._options,
                    cossin = _getCosAndSin(this._actualPosition),
                    r = options.radius + options.length / 2,
                    parameters = this.callBase();
                parameters.x = options.x + cossin.cos * r;
                parameters.y = options.y - cossin.sin * r;
                parameters.offset = options.length / 2;
                return parameters
            }
        });
        var textcloud = BaseTextCloudMarker.inherit({
            _isEnabled: function() {
                return true
            },
            _isVisible: function(layout) {
                return layout.radius > 0
            },
            _getTextCloudOptions: function() {
                var that = this,
                    cossin = _getCosAndSin(that._actualPosition),
                    nangle = vizUtils.normalizeAngle(that._actualPosition);
                return {
                    x: that._options.x + cossin.cos * that._options.radius,
                    y: that._options.y - cossin.sin * that._options.radius,
                    type: nangle > 270 ? "left-top" : nangle > 180 ? "top-right" : nangle > 90 ? "right-bottom" : "bottom-left"
                }
            },
            measure: function(layout) {
                var verticalOffset, horizontalOffset, that = this,
                    arrowLength = _Number(that._options.arrowLength) || 0;
                that._measureText();
                verticalOffset = that._textFullHeight + arrowLength;
                horizontalOffset = that._textFullWidth + arrowLength;
                return {
                    min: layout.radius,
                    max: layout.radius,
                    horizontalOffset: horizontalOffset,
                    verticalOffset: verticalOffset,
                    inverseHorizontalOffset: horizontalOffset,
                    inverseVerticalOffset: verticalOffset
                }
            }
        });
        var rangebar = BaseRangeBar.inherit({
            _isEnabled: function() {
                return this._options.size > 0
            },
            _isVisible: function(layout) {
                return layout.radius - _Number(this._options.size) > 0
            },
            _createBarItem: function() {
                return this._renderer.arc().attr({
                    "stroke-linejoin": "round"
                }).append(this._rootElement)
            },
            _createTracker: function() {
                return this._renderer.arc().attr({
                    "stroke-linejoin": "round"
                })
            },
            _setBarSides: function() {
                var that = this;
                that._maxSide = that._options.radius;
                that._minSide = that._maxSide - _Number(that._options.size)
            },
            _getSpace: function() {
                var options = this._options;
                return options.space > 0 ? 180 * options.space / options.radius / Math.PI : 0
            },
            _isTextVisible: function() {
                var options = this._options.text || {};
                return options.indent > 0
            },
            _setTextItemsSides: function() {
                var that = this,
                    options = that._options,
                    indent = _Number(options.text.indent);
                that._lineFrom = options.y - options.radius;
                that._lineTo = that._lineFrom - indent;
                that._textRadius = options.radius + indent
            },
            _getPositions: function() {
                var mainPosition1, mainPosition2, that = this,
                    basePosition = that._basePosition,
                    actualPosition = that._actualPosition;
                if (basePosition >= actualPosition) {
                    mainPosition1 = basePosition;
                    mainPosition2 = actualPosition
                } else {
                    mainPosition1 = actualPosition;
                    mainPosition2 = basePosition
                }
                return {
                    start: that._startPosition,
                    end: that._endPosition,
                    main1: mainPosition1,
                    main2: mainPosition2,
                    back1: Math.min(mainPosition1 + that._space, that._startPosition),
                    back2: Math.max(mainPosition2 - that._space, that._endPosition)
                }
            },
            _buildItemSettings: function(from, to) {
                var that = this;
                return {
                    x: that._options.x,
                    y: that._options.y,
                    innerRadius: that._minSide,
                    outerRadius: that._maxSide,
                    startAngle: to,
                    endAngle: from
                }
            },
            _updateTextPosition: function() {
                var that = this,
                    cossin = _getCosAndSin(that._actualPosition),
                    x = that._options.x + that._textRadius * cossin.cos,
                    y = that._options.y - that._textRadius * cossin.sin;
                x += cossin.cos * that._textWidth * .6;
                y -= cossin.sin * that._textHeight * .6;
                that._text.attr({
                    x: x,
                    y: y + that._textVerticalOffset
                })
            },
            _updateLinePosition: function() {
                var x1, x2, that = this,
                    x = that._options.x;
                if (that._basePosition > that._actualPosition) {
                    x1 = x - 2;
                    x2 = x
                } else {
                    if (that._basePosition < that._actualPosition) {
                        x1 = x;
                        x2 = x + 2
                    } else {
                        x1 = x - 1;
                        x2 = x + 1
                    }
                }
                that._line.attr({
                    points: [x1, that._lineFrom, x1, that._lineTo, x2, that._lineTo, x2, that._lineFrom]
                }).rotate(_convertAngleToRendererSpace(that._actualPosition), x, that._options.y).sharp()
            },
            _getTooltipPosition: function() {
                var that = this,
                    cossin = _getCosAndSin((that._basePosition + that._actualPosition) / 2),
                    r = (that._minSide + that._maxSide) / 2;
                return {
                    x: that._options.x + cossin.cos * r,
                    y: that._options.y - cossin.sin * r
                }
            },
            measure: function(layout) {
                var that = this,
                    result = {
                        min: layout.radius - _Number(that._options.size),
                        max: layout.radius
                    };
                that._measureText();
                if (that._hasText) {
                    result.max += _Number(that._options.text.indent);
                    result.horizontalOffset = that._textWidth;
                    result.verticalOffset = that._textHeight
                }
                return result
            }
        });
        exports._default = rectangleneedle;
        exports.rectangleneedle = rectangleneedle;
        exports.triangleneedle = triangleneedle;
        exports.twocolorneedle = twocolorneedle;
        exports.trianglemarker = trianglemarker;
        exports.textcloud = textcloud;
        exports.rangebar = rangebar
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/gauges/circular_range_container.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var BaseRangeContainer = __webpack_require__( /*! ./base_range_container */ 530),
            _Number = Number,
            _max = Math.max,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum;
        var CircularRangeContainer = BaseRangeContainer.inherit({
            _processOptions: function() {
                var that = this;
                that._inner = that._outer = 0;
                switch (_normalizeEnum(that._options.orientation)) {
                    case "inside":
                        that._inner = 1;
                        break;
                    case "center":
                        that._inner = that._outer = .5;
                        break;
                    default:
                        that._outer = 1
                }
            },
            _isVisible: function(layout) {
                var width = this._options.width;
                width = _Number(width) || _max(_Number(width.start), _Number(width.end));
                return layout.radius - this._inner * width > 0
            },
            _createRange: function(range, layout) {
                var that = this,
                    width = (range.startWidth + range.endWidth) / 2;
                return that._renderer.arc(layout.x, layout.y, layout.radius - that._inner * width, layout.radius + that._outer * width, that._translator.translate(range.end), that._translator.translate(range.start)).attr({
                    "stroke-linejoin": "round"
                })
            },
            measure: function(layout) {
                var width = this._options.width;
                width = _Number(width) || _max(_Number(width.start), _Number(width.end));
                return {
                    min: layout.radius - this._inner * width,
                    max: layout.radius + this._outer * width
                }
            }
        });
        module.exports = CircularRangeContainer
    },
    /*!**********************************!*\
      !*** ./Scripts/viz/bar_gauge.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./gauges/bar_gauge */ 537).dxBarGauge
    },
    /*!*****************************************!*\
      !*** ./Scripts/viz/gauges/bar_gauge.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var PI_DIV_180 = Math.PI / 180,
            _abs = Math.abs,
            _round = Math.round,
            _floor = Math.floor,
            _min = Math.min,
            _max = Math.max,
            $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            objectUtils = __webpack_require__( /*! ../../core/utils/object */ 37),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            baseGaugeModule = __webpack_require__( /*! ./base_gauge */ 524),
            dxBaseGauge = baseGaugeModule.dxBaseGauge,
            _getSampleText = baseGaugeModule.getSampleText,
            _formatValue = baseGaugeModule.formatValue,
            _compareArrays = baseGaugeModule.compareArrays,
            dxCircularGauge = __webpack_require__( /*! ./circular_gauge */ 533),
            BaseThemeManager = __webpack_require__( /*! ../core/base_theme_manager */ 485).BaseThemeManager,
            _isArray = commonUtils.isArray,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _convertAngleToRendererSpace = vizUtils.convertAngleToRendererSpace,
            _getCosAndSin = vizUtils.getCosAndSin,
            _patchFontOptions = vizUtils.patchFontOptions,
            _Number = Number,
            _isFinite = isFinite,
            _noop = $.noop,
            _extend = $.extend,
            OPTION_VALUES = "values";
        var dxBarGauge = dxBaseGauge.inherit({
            _rootClass: "dxbg-bar-gauge",
            _initCore: function() {
                var that = this;
                that.callBase.apply(that, arguments);
                that._barsGroup = that._renderer.g().attr({
                    "class": "dxbg-bars"
                }).linkOn(that._renderer.root, "bars");
                that._values = [];
                that._context = {
                    renderer: that._renderer,
                    translator: that._translator,
                    tracker: that._tracker,
                    group: that._barsGroup
                };
                that._animateStep = function(pos) {
                    var i, ii, bars = that._bars;
                    for (i = 0, ii = bars.length; i < ii; ++i) {
                        bars[i].animate(pos)
                    }
                };
                that._animateComplete = function() {
                    var i, ii, bars = that._bars;
                    for (i = 0, ii = bars.length; i < ii; ++i) {
                        bars[i].endAnimation()
                    }
                }
            },
            _disposeCore: function() {
                var that = this;
                that._barsGroup.linkOff();
                that._barsGroup = that._values = that._context = that._animateStep = that._animateComplete = null;
                that.callBase.apply(that, arguments)
            },
            _setupDomainCore: function() {
                var that = this,
                    startValue = that.option("startValue"),
                    endValue = that.option("endValue");
                _isFinite(startValue) || (startValue = 0);
                _isFinite(endValue) || (endValue = 100);
                that._translator.setDomain(startValue, endValue);
                that._baseValue = that._translator.adjust(that.option("baseValue"));
                _isFinite(that._baseValue) || (that._baseValue = startValue < endValue ? startValue : endValue)
            },
            _getDefaultSize: function() {
                return {
                    width: 300,
                    height: 300
                }
            },
            _setupCodomain: dxCircularGauge.prototype._setupCodomain,
            _getApproximateScreenRange: function() {
                var that = this,
                    sides = that._area.sides,
                    width = that._canvas.width / (sides.right - sides.left),
                    height = that._canvas.height / (sides.down - sides.up),
                    r = width < height ? width : height;
                return -that._translator.getCodomainRange() * r * PI_DIV_180
            },
            _setupAnimationSettings: function() {
                var that = this;
                that.callBase.apply(that, arguments);
                if (that._animationSettings) {
                    that._animationSettings.step = that._animateStep;
                    that._animationSettings.complete = that._animateComplete
                }
            },
            _cleanContent: function() {
                var i, ii, that = this;
                that._barsGroup.linkRemove();
                that._animationSettings && that._barsGroup.stopAnimation();
                for (i = 0, ii = that._bars ? that._bars.length : 0; i < ii; ++i) {
                    that._bars[i].dispose()
                }
                that._palette = that._bars = null
            },
            _renderContent: function() {
                var text, bbox, that = this,
                    labelOptions = that.option("label"),
                    context = that._context;
                that._barsGroup.linkAppend();
                context.textEnabled = void 0 === labelOptions || labelOptions && (!("visible" in labelOptions) || labelOptions.visible);
                if (context.textEnabled) {
                    context.textColor = labelOptions && labelOptions.font && labelOptions.font.color || null;
                    labelOptions = _extend(true, {}, that._themeManager.theme().label, labelOptions);
                    context.formatOptions = {
                        format: void 0 !== labelOptions.format ? labelOptions.format : that._defaultFormatOptions,
                        precision: labelOptions.precision,
                        customizeText: labelOptions.customizeText
                    };
                    context.textOptions = {
                        align: "center"
                    };
                    context.fontStyles = _patchFontOptions(_extend({}, that._themeManager.theme().label.font, labelOptions.font, {
                        color: null
                    }));
                    that._textIndent = labelOptions.indent > 0 ? _Number(labelOptions.indent) : 0;
                    context.lineWidth = labelOptions.connectorWidth > 0 ? _Number(labelOptions.connectorWidth) : 0;
                    context.lineColor = labelOptions.connectorColor || null;
                    text = that._renderer.text(_getSampleText(that._translator, context.formatOptions), 0, 0).attr(context.textOptions).css(context.fontStyles).append(that._barsGroup);
                    bbox = text.getBBox();
                    text.remove();
                    context.textVerticalOffset = -bbox.y - bbox.height / 2;
                    context.textWidth = bbox.width;
                    context.textHeight = bbox.height
                }
                dxCircularGauge.prototype._applyMainLayout.call(that);
                that._renderBars()
            },
            _measureMainElements: function() {
                var result = {
                    maxRadius: this._area.radius
                };
                if (this._context.textEnabled) {
                    result.horizontalMargin = this._context.textWidth;
                    result.verticalMargin = this._context.textHeight
                }
                return result
            },
            _renderBars: function() {
                var relativeInnerRadius, radius, that = this,
                    options = _extend({}, that._themeManager.theme(), that.option()),
                    area = that._area;
                that._palette = that._themeManager.createPalette(options.palette, {
                    useHighlight: true
                });
                relativeInnerRadius = options.relativeInnerRadius > 0 && options.relativeInnerRadius < 1 ? _Number(options.relativeInnerRadius) : .1;
                radius = area.radius;
                if (that._context.textEnabled) {
                    that._textIndent = _round(_min(that._textIndent, radius / 2));
                    radius -= that._textIndent
                }
                that._outerRadius = _floor(radius);
                that._innerRadius = _floor(radius * relativeInnerRadius);
                that._barSpacing = options.barSpacing > 0 ? _Number(options.barSpacing) : 0;
                _extend(that._context, {
                    backgroundColor: options.backgroundColor,
                    x: area.x,
                    y: area.y,
                    startAngle: area.startCoord,
                    endAngle: area.endCoord,
                    baseAngle: that._translator.translate(that._baseValue)
                });
                that._bars = [];
                that._updateValues(that.option(OPTION_VALUES))
            },
            _arrangeBars: function(count) {
                var spacing, _count, unitOffset, i, that = this,
                    radius = that._outerRadius - that._innerRadius,
                    context = that._context;
                context.barSize = count > 0 ? _max((radius - (count - 1) * that._barSpacing) / count, 1) : 0;
                spacing = count > 1 ? _max(_min((radius - count * context.barSize) / (count - 1), that._barSpacing), 0) : 0;
                _count = _min(_floor((radius + spacing) / context.barSize), count);
                that._setBarsCount(_count);
                radius = that._outerRadius;
                context.textRadius = radius + that._textIndent;
                that._palette.reset();
                unitOffset = context.barSize + spacing;
                for (i = 0; i < _count; ++i, radius -= unitOffset) {
                    that._bars[i].arrange({
                        radius: radius,
                        color: that._palette.getNextColor()
                    })
                }
            },
            _setBarsCount: function(count) {
                var i, ii, that = this;
                if (that._bars.length > count) {
                    for (i = count, ii = that._bars.length; i < ii; ++i) {
                        that._bars[i].dispose()
                    }
                    that._bars.splice(count, ii - count)
                } else {
                    if (that._bars.length < count) {
                        for (i = that._bars.length, ii = count; i < ii; ++i) {
                            that._bars.push(new BarWrapper(i, that._context))
                        }
                    }
                }
                if (that._bars.length > 0) {
                    if (that._dummyBackground) {
                        that._dummyBackground.dispose();
                        that._dummyBackground = null
                    }
                } else {
                    if (!that._dummyBackground) {
                        that._dummyBackground = that._renderer.arc().attr({
                            "stroke-linejoin": "round"
                        }).append(that._barsGroup)
                    }
                    that._dummyBackground.attr({
                        x: that._context.x,
                        y: that._context.y,
                        outerRadius: that._outerRadius,
                        innerRadius: that._innerRadius,
                        startAngle: that._context.endAngle,
                        endAngle: that._context.startAngle,
                        fill: that._context.backgroundColor
                    })
                }
            },
            _updateBars: function(values) {
                var i, ii, that = this;
                for (i = 0, ii = that._bars.length; i < ii; ++i) {
                    that._bars[i].setValue(values[i])
                }
            },
            _animateBars: function(values) {
                var i, that = this,
                    ii = that._bars.length;
                if (ii > 0) {
                    for (i = 0; i < ii; ++i) {
                        that._bars[i].beginAnimation(values[i])
                    }
                    that._barsGroup.animate({
                        _: 0
                    }, that._animationSettings)
                }
            },
            _updateValues: function(values) {
                var i, value, that = this,
                    list = _isArray(values) && values || _isFinite(values) && [values] || [],
                    ii = list.length,
                    barValues = [];
                that._values.length = ii;
                for (i = 0; i < ii; ++i) {
                    value = list[i];
                    that._values[i] = value = _Number(_isFinite(value) ? value : that._values[i]);
                    if (_isFinite(value)) {
                        barValues.push(value)
                    }
                }
                that._animationSettings && that._barsGroup.stopAnimation();
                that._beginValueChanging();
                if (that._bars) {
                    that._arrangeBars(barValues.length);
                    if (that._animationSettings && !that._noAnimation) {
                        that._animateBars(barValues)
                    } else {
                        that._updateBars(barValues)
                    }
                }
                if (!that._resizing) {
                    if (!_compareArrays(that._values, that.option(OPTION_VALUES))) {
                        that.option(OPTION_VALUES, that._values)
                    }
                }
                that._endValueChanging()
            },
            values: function(arg) {
                if (void 0 !== arg) {
                    this._updateValues(arg);
                    return this
                } else {
                    return this._values.slice(0)
                }
            },
            _optionChangesMap: {
                backgroundColor: "MOSTLY_TOTAL",
                relativeInnerRadius: "MOSTLY_TOTAL",
                barSpacing: "MOSTLY_TOTAL",
                label: "MOSTLY_TOTAL",
                palette: "MOSTLY_TOTAL",
                values: "VALUES"
            },
            _customChangesOrder: ["VALUES"],
            _change_VALUES: function() {
                this._updateValues(this.option(OPTION_VALUES))
            },
            _factory: objectUtils.clone(dxBaseGauge.prototype._factory)
        });
        var BarWrapper = function(index, context) {
            var that = this;
            that._context = context;
            that._background = context.renderer.arc().attr({
                "stroke-linejoin": "round",
                fill: context.backgroundColor
            }).append(context.group);
            that._bar = context.renderer.arc().attr({
                "stroke-linejoin": "round"
            }).append(context.group);
            if (context.textEnabled) {
                that._line = context.renderer.path([], "line").attr({
                    "stroke-width": context.lineWidth
                }).append(context.group);
                that._text = context.renderer.text().css(context.fontStyles).attr(context.textOptions).append(context.group)
            }
            that._tracker = context.renderer.arc().attr({
                "stroke-linejoin": "round"
            });
            context.tracker.attach(that._tracker, that, {
                index: index
            });
            that._index = index;
            that._angle = context.baseAngle;
            that._settings = {
                x: context.x,
                y: context.y,
                startAngle: context.baseAngle,
                endAngle: context.baseAngle
            }
        };
        _extend(BarWrapper.prototype, {
            dispose: function() {
                var that = this;
                that._background.dispose();
                that._bar.dispose();
                if (that._context.textEnabled) {
                    that._line.dispose();
                    that._text.dispose()
                }
                that._context.tracker.detach(that._tracker);
                that._context = that._settings = that._background = that._bar = that._line = that._text = that._tracker = null;
                return that
            },
            arrange: function(options) {
                var that = this,
                    context = that._context;
                that._settings.outerRadius = options.radius;
                that._settings.innerRadius = options.radius - context.barSize;
                that._background.attr(_extend({}, that._settings, {
                    startAngle: context.endAngle,
                    endAngle: context.startAngle
                }));
                that._bar.attr(that._settings);
                that._tracker.attr(that._settings);
                that._color = options.color;
                that._bar.attr({
                    fill: options.color
                });
                if (context.textEnabled) {
                    that._line.attr({
                        points: [context.x, context.y - that._settings.innerRadius, context.x, context.y - context.textRadius],
                        stroke: context.lineColor || options.color
                    }).sharp();
                    that._text.css({
                        fill: context.textColor || options.color
                    })
                }
                return that
            },
            getTooltipParameters: function() {
                var that = this,
                    cossin = _getCosAndSin((that._angle + that._context.baseAngle) / 2);
                return {
                    x: _round(that._context.x + (that._settings.outerRadius + that._settings.innerRadius) / 2 * cossin.cos),
                    y: _round(that._context.y - (that._settings.outerRadius + that._settings.innerRadius) / 2 * cossin.sin),
                    offset: 0,
                    color: that._color,
                    value: that._value
                }
            },
            setAngle: function(angle) {
                var cossin, that = this;
                that._angle = angle;
                setAngles(that._settings, that._context.baseAngle, that._angle);
                that._bar.attr(that._settings);
                that._tracker.attr(that._settings);
                if (that._context.textEnabled) {
                    that._line.rotate(_convertAngleToRendererSpace(that._angle), that._context.x, that._context.y);
                    cossin = _getCosAndSin(that._angle);
                    that._text.attr({
                        text: _formatValue(that._value, that._context.formatOptions, {
                            index: that._index
                        }),
                        x: that._context.x + (that._context.textRadius + .6 * that._context.textWidth) * cossin.cos,
                        y: that._context.y - (that._context.textRadius + .6 * that._context.textHeight) * cossin.sin + that._context.textVerticalOffset
                    })
                }
                return that
            },
            _processValue: function(value) {
                this._value = this._context.translator.adjust(value);
                return this._context.translator.translate(this._value)
            },
            setValue: function(value) {
                return this.setAngle(this._processValue(value))
            },
            beginAnimation: function(value) {
                var that = this,
                    angle = this._processValue(value);
                if (!compareFloats(that._angle, angle)) {
                    that._start = that._angle;
                    that._delta = angle - that._angle;
                    that._tracker.attr({
                        visibility: "hidden"
                    });
                    if (that._context.textEnabled) {
                        that._line.attr({
                            visibility: "hidden"
                        });
                        that._text.attr({
                            visibility: "hidden"
                        })
                    }
                } else {
                    that.animate = _noop;
                    that.setAngle(that._angle)
                }
            },
            animate: function(pos) {
                var that = this;
                that._angle = that._start + that._delta * pos;
                setAngles(that._settings, that._context.baseAngle, that._angle);
                that._bar.attr(that._settings)
            },
            endAnimation: function() {
                var that = this;
                if (void 0 !== that._delta) {
                    if (compareFloats(that._angle, that._start + that._delta)) {
                        that._tracker.attr({
                            visibility: null
                        });
                        if (that._context.textEnabled) {
                            that._line.attr({
                                visibility: null
                            });
                            that._text.attr({
                                visibility: null
                            })
                        }
                        that.setAngle(that._angle)
                    }
                } else {
                    delete that.animate
                }
                delete that._start;
                delete that._delta
            }
        });

        function setAngles(target, angle1, angle2) {
            target.startAngle = angle1 < angle2 ? angle1 : angle2;
            target.endAngle = angle1 < angle2 ? angle2 : angle1
        }

        function compareFloats(value1, value2) {
            return _abs(value1 - value2) < 1e-4
        }
        dxBarGauge.prototype._factory.ThemeManager = BaseThemeManager.inherit({
            _themeSection: "barGauge",
            _fontFields: ["label.font", "title.font", "tooltip.font", "loadingIndicator.font"]
        });
        registerComponent("dxBarGauge", dxBarGauge);
        exports.dxBarGauge = dxBarGauge;
        var __BarWrapper = BarWrapper;
        exports.BarWrapper = __BarWrapper;
        exports.stubBarWrapper = function(barWrapperType) {
            BarWrapper = barWrapperType
        };
        exports.restoreBarWrapper = function() {
            BarWrapper = __BarWrapper
        }
    },
    /*!***************************************!*\
      !*** ./Scripts/viz/range_selector.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./range_selector/range_selector */ 539)
    },
    /*!******************************************************!*\
      !*** ./Scripts/viz/range_selector/range_selector.js ***!
      \******************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            registerComponent = __webpack_require__( /*! ../../core/component_registrator */ 43),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            adjustValue = vizUtils.adjustValue,
            dateUtils = __webpack_require__( /*! ../../core/utils/date */ 52),
            addInterval = dateUtils.addInterval,
            dateToMilliseconds = dateUtils.dateToMilliseconds,
            getSequenceByInterval = dateUtils.getSequenceByInterval,
            rangeModule = __webpack_require__( /*! ../translators/range */ 503),
            translator2DModule = __webpack_require__( /*! ../translators/translator2d */ 497),
            axisModule = __webpack_require__( /*! ../axes/base_axis */ 506),
            patchFontOptions = vizUtils.patchFontOptions,
            parseUtils = __webpack_require__( /*! ../components/parse_utils */ 459),
            _normalizeEnum = vizUtils.normalizeEnum,
            formatHelper = __webpack_require__( /*! ../../format_helper */ 55),
            commonModule = __webpack_require__( /*! ./common */ 540),
            slidersControllerModule = __webpack_require__( /*! ./sliders_controller */ 541),
            trackerModule = __webpack_require__( /*! ./tracker */ 544),
            rangeViewModule = __webpack_require__( /*! ./range_view */ 545),
            seriesDataSourceModule = __webpack_require__( /*! ./series_data_source */ 546),
            themeManagerModule = __webpack_require__( /*! ./theme_manager */ 547),
            tickManagerModule = __webpack_require__( /*! ../axes/base_tick_manager */ 508),
            _isDefined = commonUtils.isDefined,
            _isNumber = commonUtils.isNumber,
            _isDate = commonUtils.isDate,
            _max = Math.max,
            _ceil = Math.ceil,
            _floor = Math.floor,
            START_VALUE = "startValue",
            END_VALUE = "endValue",
            DATETIME = "datetime",
            SELECTED_RANGE = "selectedRange",
            DISCRETE = "discrete",
            SEMIDISCRETE = "semidiscrete",
            STRING = "string",
            SELECTED_RANGE_CHANGED = SELECTED_RANGE + "Changed",
            CONTAINER_BACKGROUND_COLOR = "containerBackgroundColor",
            SLIDER_MARKER = "sliderMarker",
            OPTION_BACKGROUND = "background",
            LOGARITHMIC = "logarithmic",
            INVISIBLE_POS = -1e3,
            SEMIDISCRETE_GRID_SPACING_FACTOR = 50,
            logarithmBase = 10;

        function createTranslator() {
            return new translator2DModule.Translator2D({}, {})
        }

        function updateTranslator(translator, valueRange, screenRange, interval) {
            translator.update(valueRange, {
                left: screenRange[0],
                width: screenRange[1]
            }, {
                isHorizontal: true,
                interval: interval
            })
        }

        function calculateMarkerHeight(renderer, value, sliderMarkerOptions) {
            var formattedText = void 0 === value ? commonModule.consts.emptySliderMarkerText : commonModule.formatValue(value, sliderMarkerOptions),
                textBBox = getTextBBox(renderer, formattedText, sliderMarkerOptions.font);
            return _ceil(textBBox.height) + 2 * sliderMarkerOptions.paddingTopBottom + commonModule.consts.pointerSize
        }

        function calculateScaleLabelHalfWidth(renderer, value, scaleOptions) {
            var formattedText = commonModule.formatValue(value, scaleOptions.label),
                textBBox = getTextBBox(renderer, formattedText, scaleOptions.label.font);
            return _ceil(textBBox.width / 2)
        }

        function parseSliderMarkersPlaceholderSize(placeholderSize) {
            var placeholderWidthLeft, placeholderWidthRight, placeholderHeight;
            if (_isNumber(placeholderSize)) {
                placeholderWidthLeft = placeholderWidthRight = placeholderHeight = placeholderSize
            } else {
                if (placeholderSize) {
                    if (_isNumber(placeholderSize.height)) {
                        placeholderHeight = placeholderSize.height
                    }
                    if (_isNumber(placeholderSize.width)) {
                        placeholderWidthLeft = placeholderWidthRight = placeholderSize.width
                    } else {
                        if (placeholderSize.width) {
                            if (_isNumber(placeholderSize.width.left)) {
                                placeholderWidthLeft = placeholderSize.width.left
                            }
                            if (_isNumber(placeholderSize.width.right)) {
                                placeholderWidthRight = placeholderSize.width.right
                            }
                        }
                    }
                } else {
                    return null
                }
            }
            return {
                widthLeft: placeholderWidthLeft,
                widthRight: placeholderWidthRight,
                height: placeholderHeight
            }
        }

        function calculateIndents(renderer, scale, sliderMarkerOptions, indentOptions) {
            var leftMarkerHeight, rightMarkerHeight, placeholderHeight, parsedPlaceholderSize, leftScaleLabelWidth = 0,
                rightScaleLabelWidth = 0,
                placeholderWidthLeft = 0,
                placeholderWidthRight = 0;
            indentOptions = indentOptions || {};
            parsedPlaceholderSize = parseSliderMarkersPlaceholderSize(sliderMarkerOptions.placeholderSize);
            if (parsedPlaceholderSize && void 0 === indentOptions.left && void 0 === indentOptions.right) {
                placeholderWidthLeft = parsedPlaceholderSize.widthLeft;
                placeholderWidthRight = parsedPlaceholderSize.widthRight
            } else {
                placeholderWidthLeft = indentOptions.left;
                placeholderWidthRight = indentOptions.right
            }
            if (parsedPlaceholderSize && void 0 === sliderMarkerOptions.placeholderHeight) {
                placeholderHeight = parsedPlaceholderSize.height
            } else {
                placeholderHeight = sliderMarkerOptions.placeholderHeight
            }
            if (sliderMarkerOptions.visible) {
                leftMarkerHeight = calculateMarkerHeight(renderer, scale.startValue, sliderMarkerOptions);
                rightMarkerHeight = calculateMarkerHeight(renderer, scale.endValue, sliderMarkerOptions);
                if (void 0 === placeholderHeight) {
                    placeholderHeight = _max(leftMarkerHeight, rightMarkerHeight)
                }
            }
            if (scale.label.visible) {
                leftScaleLabelWidth = calculateScaleLabelHalfWidth(renderer, scale.startValue, scale);
                rightScaleLabelWidth = calculateScaleLabelHalfWidth(renderer, scale.endValue, scale)
            }
            placeholderWidthLeft = void 0 !== placeholderWidthLeft ? placeholderWidthLeft : leftScaleLabelWidth;
            placeholderWidthRight = (void 0 !== placeholderWidthRight ? placeholderWidthRight : rightScaleLabelWidth) || 1;
            return {
                left: placeholderWidthLeft,
                right: placeholderWidthRight,
                top: placeholderHeight || 0,
                bottom: 0
            }
        }

        function calculateValueType(firstValue, secondValue) {
            var typeFirstValue = $.type(firstValue),
                typeSecondValue = $.type(secondValue),
                validType = function(type) {
                    return typeFirstValue === type || typeSecondValue === type
                };
            return validType("date") ? DATETIME : validType("number") ? "numeric" : validType(STRING) ? STRING : ""
        }

        function showScaleMarkers(scaleOptions) {
            return scaleOptions.valueType === DATETIME && scaleOptions.marker.visible
        }

        function updateTranslatorRangeInterval(translatorRange, scaleOptions) {
            var intervalX = scaleOptions.minorTickInterval || scaleOptions.tickInterval;
            if ("datetime" === scaleOptions.valueType) {
                intervalX = dateUtils.dateToMilliseconds(intervalX)
            }
            translatorRange.addRange({
                interval: intervalX
            })
        }

        function checkLogarithmicOptions(options, defaultLogarithmBase, incidentOccurred) {
            var logarithmBase;
            if (!options) {
                return
            }
            logarithmBase = options.logarithmBase;
            if (options.type === LOGARITHMIC && logarithmBase <= 0 || logarithmBase && !_isNumber(logarithmBase)) {
                options.logarithmBase = defaultLogarithmBase;
                incidentOccurred("E2104")
            } else {
                if (options.type !== LOGARITHMIC) {
                    options.logarithmBase = void 0
                }
            }
        }

        function calculateScaleAreaHeight(renderer, scaleOptions, visibleMarkers) {
            var textBBox, value = "0",
                formatObject = {
                    value: 0,
                    valueText: value
                },
                labelScaleOptions = scaleOptions.label,
                markerScaleOptions = scaleOptions.marker,
                customizeText = labelScaleOptions.customizeText,
                placeholderHeight = scaleOptions.placeholderHeight,
                text = commonUtils.isFunction(customizeText) ? customizeText.call(formatObject, formatObject) : value,
                visibleLabels = labelScaleOptions.visible;
            if (placeholderHeight) {
                return placeholderHeight
            } else {
                textBBox = getTextBBox(renderer, text, labelScaleOptions.font);
                return (visibleLabels ? labelScaleOptions.topIndent + textBBox.height : 0) + (visibleMarkers ? markerScaleOptions.topIndent + markerScaleOptions.separatorHeight : 0)
            }
        }

        function getNextTickInterval(tickInterval, minorTickInterval, isDateType) {
            if (!tickInterval) {
                tickInterval = minorTickInterval
            } else {
                if (isDateType) {
                    tickInterval = dateUtils.getNextDateUnit(tickInterval)
                } else {
                    tickInterval += minorTickInterval
                }
            }
            return tickInterval
        }

        function calculateTickIntervalsForSemidiscreteScale(scaleOptions, min, max, screenDelta) {
            var interval, delta, minorTickInterval = scaleOptions.minorTickInterval,
                tickInterval = scaleOptions.tickInterval,
                isDateType = "datetime" === scaleOptions.valueType,
                gridSpacingFactor = scaleOptions.axisDivisionFactor || {};
            if (!tickInterval) {
                do {
                    interval = getNextTickInterval(tickInterval, minorTickInterval, isDateType);
                    if (tickInterval !== interval) {
                        tickInterval = interval
                    } else {
                        break
                    }
                    if (isDateType) {
                        interval = dateToMilliseconds(tickInterval)
                    }
                    delta = screenDelta / (_ceil((max - min) / interval) + 1)
                } while (interval && delta < (gridSpacingFactor[tickInterval] || SEMIDISCRETE_GRID_SPACING_FACTOR))
            }
            return {
                tickInterval: tickInterval,
                minorTickInterval: minorTickInterval,
                bounds: {
                    minVisible: min,
                    maxVisible: max
                },
                ticks: []
            }
        }

        function updateTickIntervals(scaleOptions, screenDelta, incidentOccurred, range) {
            var result, tickManager, ticks, min = _isDefined(range.minVisible) ? range.minVisible : range.min,
                max = _isDefined(range.maxVisible) ? range.maxVisible : range.max,
                categoriesInfo = scaleOptions._categoriesInfo;
            if (scaleOptions.type === SEMIDISCRETE) {
                result = calculateTickIntervalsForSemidiscreteScale(scaleOptions, min, max, screenDelta)
            } else {
                tickManager = new tickManagerModule.TickManager({
                    axisType: scaleOptions.type,
                    dataType: scaleOptions.valueType
                }, {
                    min: min,
                    max: max,
                    screenDelta: screenDelta,
                    customTicks: categoriesInfo && categoriesInfo.categories
                }, {
                    labelOptions: {},
                    boundCoef: 1,
                    minorTickInterval: scaleOptions.minorTickInterval,
                    tickInterval: scaleOptions.tickInterval,
                    incidentOccurred: incidentOccurred,
                    base: scaleOptions.logarithmBase,
                    showMinorTicks: true,
                    withMinorCorrection: true,
                    stick: false !== range.stick
                });
                ticks = tickManager.getTicks(true);
                result = {
                    tickInterval: tickManager.getTickInterval(),
                    minorTickInterval: tickManager.getMinorTickInterval(),
                    bounds: tickManager.getTickBounds(),
                    ticks: ticks
                }
            }
            return result
        }

        function calculateTranslatorRange(seriesDataSource, scaleOptions) {
            var minValue, maxValue, isEqualDates, categories, categoriesInfo, rangeForCategories, inverted = false,
                startValue = scaleOptions.startValue,
                endValue = scaleOptions.endValue,
                translatorRange = seriesDataSource ? seriesDataSource.getBoundRange().arg : new rangeModule.Range,
                isDate = "datetime" === scaleOptions.valueType,
                minRange = scaleOptions.minRange;
            if (scaleOptions.type === DISCRETE) {
                rangeForCategories = new rangeModule.Range({
                    minVisible: startValue,
                    maxVisible: endValue
                });
                rangeForCategories.addRange(translatorRange);
                translatorRange = rangeForCategories;
                categories = seriesDataSource ? seriesDataSource.argCategories : scaleOptions.categories || !seriesDataSource && startValue && endValue && [startValue, endValue];
                categories = categories || [];
                scaleOptions._categoriesInfo = categoriesInfo = vizUtils.getCategoriesInfo(categories, startValue || categories[0], endValue || categories[categories.length - 1])
            }
            if (scaleOptions.type === SEMIDISCRETE) {
                startValue = scaleOptions.startValue = correctValueByInterval(scaleOptions.startValue, isDate, minRange);
                endValue = scaleOptions.endValue = correctValueByInterval(scaleOptions.endValue, isDate, minRange);
                translatorRange.minVisible = correctValueByInterval(translatorRange.minVisible, isDate, minRange);
                translatorRange.maxVisible = correctValueByInterval(translatorRange.maxVisible, isDate, minRange);
                translatorRange.min = correctValueByInterval(translatorRange.min, isDate, minRange);
                translatorRange.max = correctValueByInterval(translatorRange.max, isDate, minRange)
            }
            if (_isDefined(startValue) && _isDefined(endValue)) {
                inverted = categoriesInfo ? categoriesInfo.inverted : startValue > endValue;
                minValue = categoriesInfo ? categoriesInfo.start : inverted ? endValue : startValue;
                maxValue = categoriesInfo ? categoriesInfo.end : inverted ? startValue : endValue
            } else {
                if (_isDefined(startValue) || _isDefined(endValue)) {
                    minValue = startValue;
                    maxValue = endValue
                } else {
                    if (categoriesInfo) {
                        minValue = categoriesInfo.start;
                        maxValue = categoriesInfo.end
                    }
                }
            }
            isEqualDates = _isDate(minValue) && _isDate(maxValue) && minValue.getTime() === maxValue.getTime();
            if (scaleOptions.type === SEMIDISCRETE || minValue !== maxValue && !isEqualDates) {
                translatorRange.addRange({
                    invert: inverted,
                    min: minValue,
                    max: maxValue,
                    minVisible: minValue,
                    maxVisible: maxValue,
                    dataType: scaleOptions.valueType
                })
            }
            translatorRange.addRange({
                categories: categories,
                base: scaleOptions.logarithmBase,
                axisType: scaleOptions.type
            });
            if (!translatorRange.isDefined()) {
                if (isEqualDates) {
                    scaleOptions.valueType = "numeric"
                }
                translatorRange.setStubData(scaleOptions.valueType)
            }
            return translatorRange
        }

        function startEndNotDefined(start, end) {
            return !_isDefined(start) || !_isDefined(end)
        }

        function getTextBBox(renderer, text, fontOptions) {
            var textElement = renderer.text(text, INVISIBLE_POS, INVISIBLE_POS).css(patchFontOptions(fontOptions)).append(renderer.root);
            var textBBox = textElement.getBBox();
            textElement.remove();
            return textBBox
        }

        function getDateMarkerVisibilityChecker(screenDelta) {
            return function(isDateScale, isMarkerVisible, min, max, tickInterval) {
                if (isMarkerVisible && isDateScale) {
                    if (tickInterval.years || tickInterval.months >= 6 || screenDelta / SEMIDISCRETE_GRID_SPACING_FACTOR < _ceil((max - min) / dateToMilliseconds("year")) + 1) {
                        isMarkerVisible = false
                    }
                }
                return isMarkerVisible
            }
        }

        function updateScaleOptions(scaleOptions, seriesDataSource, translatorRange, tickIntervalsInfo, checkDateMarkerVisibility) {
            var bounds, isEmptyInterval, intervals, categoriesInfo = scaleOptions._categoriesInfo,
                isDateTime = scaleOptions.valueType === DATETIME;
            if (seriesDataSource && !seriesDataSource.isEmpty() && !translatorRange.stubData) {
                bounds = tickIntervalsInfo.bounds;
                translatorRange.addRange(bounds);
                scaleOptions.startValue = translatorRange.invert ? bounds.maxVisible : bounds.minVisible;
                scaleOptions.endValue = translatorRange.invert ? bounds.minVisible : bounds.maxVisible
            }
            scaleOptions.marker.visible = checkDateMarkerVisibility(isDateTime && scaleOptions.type.indexOf(DISCRETE) === -1, scaleOptions.marker.visible, scaleOptions.startValue, scaleOptions.endValue, tickIntervalsInfo.tickInterval);
            if (categoriesInfo) {
                scaleOptions.startValue = categoriesInfo.start;
                scaleOptions.endValue = categoriesInfo.end
            }
            if (scaleOptions.type.indexOf(DISCRETE) === -1) {
                isEmptyInterval = _isDate(scaleOptions.startValue) && _isDate(scaleOptions.endValue) && scaleOptions.startValue.getTime() === scaleOptions.endValue.getTime() || scaleOptions.startValue === scaleOptions.endValue
            }
            scaleOptions.isEmpty = startEndNotDefined(scaleOptions.startValue, scaleOptions.endValue) || isEmptyInterval;
            if (scaleOptions.isEmpty) {
                scaleOptions.startValue = scaleOptions.endValue = void 0
            } else {
                scaleOptions.minorTickInterval = tickIntervalsInfo.minorTickInterval;
                scaleOptions.tickInterval = tickIntervalsInfo.tickInterval;
                if (isDateTime && (!_isDefined(scaleOptions.label.format) || scaleOptions.type === SEMIDISCRETE && scaleOptions.minorTickInterval !== scaleOptions.tickInterval)) {
                    if (scaleOptions.type === DISCRETE) {
                        scaleOptions.label.format = formatHelper.getDateFormatByTicks(tickIntervalsInfo.ticks)
                    } else {
                        if (!scaleOptions.marker.visible) {
                            scaleOptions.label.format = formatHelper.getDateFormatByTickInterval(scaleOptions.startValue, scaleOptions.endValue, scaleOptions.tickInterval)
                        } else {
                            scaleOptions.label.format = dateUtils.getDateFormatByTickInterval(scaleOptions.tickInterval)
                        }
                    }
                }
            }
            if (scaleOptions.type === SEMIDISCRETE) {
                intervals = getIntervalCustomTicks(scaleOptions);
                scaleOptions.customMinorTicks = intervals.altIntervals;
                scaleOptions.customTicks = intervals.intervals;
                scaleOptions.customBoundTicks = [scaleOptions.customTicks[0]]
            }
        }

        function prepareScaleOptions(scaleOption, seriesDataSource, incidentOccurred) {
            var parser, parsedValue = 0,
                valueType = parseUtils.correctValueType(_normalizeEnum(scaleOption.valueType)),
                validateStartEndValues = function(field, parser) {
                    var messageToIncidentOccurred = field === START_VALUE ? "start" : "end";
                    if (_isDefined(scaleOption[field])) {
                        parsedValue = parser(scaleOption[field]);
                        if (_isDefined(parsedValue)) {
                            scaleOption[field] = parsedValue
                        } else {
                            scaleOption[field] = void 0;
                            incidentOccurred("E2202", [messageToIncidentOccurred])
                        }
                    }
                };
            if (seriesDataSource) {
                valueType = seriesDataSource.getCalculatedValueType() || valueType
            }
            if (!valueType) {
                valueType = calculateValueType(scaleOption.startValue, scaleOption.endValue) || "numeric"
            }
            if (valueType === STRING || scaleOption.categories) {
                scaleOption.type = DISCRETE;
                valueType = STRING
            }
            scaleOption.valueType = valueType;
            parser = parseUtils.getParser(valueType);
            validateStartEndValues(START_VALUE, parser);
            validateStartEndValues(END_VALUE, parser);
            checkLogarithmicOptions(scaleOption, logarithmBase, incidentOccurred);
            if (!scaleOption.type) {
                scaleOption.type = "continuous"
            }
            void 0 === scaleOption.tickInterval && (scaleOption.tickInterval = scaleOption.majorTickInterval);
            scaleOption.minorTick.visible && (scaleOption.minorTick.visible = scaleOption.showMinorTicks);
            scaleOption.parser = parser;
            if (scaleOption.type === SEMIDISCRETE) {
                scaleOption.minorTick.visible = false;
                scaleOption.minorTickInterval = scaleOption.minRange;
                scaleOption.marker.visible = false;
                scaleOption.maxRange = void 0
            }
            return scaleOption
        }

        function correctValueByInterval(value, isDate, interval) {
            if (_isDefined(value)) {
                value = isDate ? dateUtils.correctDateWithUnitBeginning(new Date(value), interval) : adjustValue(_floor(value / interval) * interval)
            }
            return value
        }

        function getIntervalCustomTicks(options) {
            var min = options.startValue,
                max = options.endValue,
                isDate = "datetime" === options.valueType,
                tickInterval = options.tickInterval,
                res = {
                    intervals: []
                };
            if (!_isDefined(min) || !_isDefined(max)) {
                return res
            }
            res.intervals = getSequenceByInterval(min, max, options.minorTickInterval);
            if (tickInterval !== options.minorTickInterval) {
                res.altIntervals = res.intervals;
                min = correctValueByInterval(min, isDate, tickInterval);
                max = correctValueByInterval(max, isDate, tickInterval);
                res.intervals = getSequenceByInterval(min, max, tickInterval)
            }
            return res
        }
        var dxRangeSelector = __webpack_require__( /*! ../core/base_widget */ 448).inherit({
            _eventsMap: {
                onSelectedRangeChanged: {
                    name: SELECTED_RANGE_CHANGED
                }
            },
            _setDeprecatedOptions: function() {
                this.callBase.apply(this, arguments);
                $.extend(this._deprecatedOptions, {
                    "sliderMarker.padding": {
                        since: "15.1",
                        message: "Use the 'paddingTopBottom' and 'paddingLeftRight' options instead"
                    },
                    "sliderMarker.placeholderSize": {
                        since: "15.1",
                        message: "Use the 'placeholderHeight' and 'indent' options instead"
                    },
                    "scale.majorTickInterval": {
                        since: "15.2",
                        message: "Use the 'tickInterval' options instead"
                    },
                    "scale.showMinorTicks": {
                        since: "15.2",
                        message: "Use the 'minorTick.visible' options instead"
                    }
                })
            },
            _rootClassPrefix: "dxrs",
            _rootClass: "dxrs-range-selector",
            _dataIsReady: function() {
                return this._dataSource.isLoaded()
            },
            _initialChanges: ["DATA_SOURCE", "SELECTED_RANGE"],
            _themeDependentChanges: ["MOSTLY_TOTAL"],
            _initCore: function() {
                var rangeViewGroup, slidersGroup, scaleGroup, trackersGroup, that = this,
                    renderer = that._renderer,
                    root = renderer.root;
                root.css({
                    "touch-action": "pan-y",
                    "-ms-touch-action": "pan-y"
                });
                that._clipRect = renderer.clipRect();
                rangeViewGroup = renderer.g().attr({
                    "class": "dxrs-view"
                }).append(root);
                slidersGroup = renderer.g().attr({
                    "class": "dxrs-slidersContainer",
                    clipId: that._clipRect.id
                }).append(root);
                scaleGroup = renderer.g().attr({
                    "class": "dxrs-scale",
                    clipId: that._clipRect.id
                }).append(root);
                trackersGroup = renderer.g().attr({
                    "class": "dxrs-trackers"
                }).append(root);
                that._translator = createTranslator();
                that._rangeView = new rangeViewModule.RangeView({
                    renderer: renderer,
                    root: rangeViewGroup,
                    translator: that._translator
                });
                that._slidersController = new slidersControllerModule.SlidersController({
                    renderer: renderer,
                    root: slidersGroup,
                    trackersGroup: trackersGroup,
                    updateSelectedRange: function(range) {
                        if (!that._selectedRangeOption) {
                            that.option(SELECTED_RANGE, range)
                        }
                        that._eventTrigger(SELECTED_RANGE_CHANGED, {
                            startValue: range.startValue,
                            endValue: range.endValue
                        })
                    },
                    translator: that._translator
                });
                that._axis = new AxisWrapper({
                    renderer: renderer,
                    root: scaleGroup,
                    updateSelectedRange: function(range) {
                        that.setSelectedRange(range)
                    },
                    translator: that._translator
                });
                that._tracker = new trackerModule.Tracker({
                    renderer: renderer,
                    controller: that._slidersController
                })
            },
            _getDefaultSize: function() {
                return {
                    width: 400,
                    height: 160
                }
            },
            _disposeCore: function() {
                this._axis.dispose();
                this._slidersController.dispose();
                this._tracker.dispose()
            },
            _createThemeManager: function() {
                return new themeManagerModule.ThemeManager
            },
            _applySize: function(rect) {
                this._clientRect = rect.slice();
                this._change(["MOSTLY_TOTAL"])
            },
            _optionChangesMap: {
                scale: "SCALE",
                selectedRange: "SELECTED_RANGE",
                dataSource: "DATA_SOURCE"
            },
            _optionChangesOrder: ["SCALE", "DATA_SOURCE"],
            _change_SCALE: function() {
                this._change(["MOSTLY_TOTAL"])
            },
            _change_DATA_SOURCE: function() {
                if (this._initialized || this._options.dataSource) {
                    this._options[SELECTED_RANGE] = null;
                    this._updateDataSource()
                }
            },
            _customChangesOrder: ["MOSTLY_TOTAL", "SELECTED_RANGE"],
            _change_MOSTLY_TOTAL: function() {
                this._applyMostlyTotalChange()
            },
            _change_SELECTED_RANGE: function() {
                var that = this;
                if (that._selectedRangeOption) {
                    that._options[SELECTED_RANGE] = that._selectedRangeOption
                }
                that.setSelectedRange(that._options[SELECTED_RANGE])
            },
            _applyChanges: function() {
                var that = this;
                if (that._changes.has("SELECTED_RANGE") && that._options[SELECTED_RANGE]) {
                    that._selectedRangeOption = $.extend({}, that._options[SELECTED_RANGE])
                }
                that.callBase.apply(that, arguments);
                that._selectedRangeOption = null;
                that.__isResizing = false
            },
            _applyMostlyTotalChange: function() {
                var currentAnimationEnabled, that = this,
                    renderer = that._renderer,
                    rect = that._clientRect;
                if (that.__isResizing) {
                    currentAnimationEnabled = renderer.animationEnabled();
                    renderer.updateAnimationOptions({
                        enabled: false
                    })
                }
                that._clipRect.attr({
                    x: rect[0],
                    y: rect[1],
                    width: rect[2] - rect[0],
                    height: rect[3] - rect[1]
                });
                that._updateContent({
                    left: rect[0],
                    top: rect[1],
                    width: rect[2] - rect[0],
                    height: rect[3] - rect[1]
                });
                if (that.__isResizing) {
                    renderer.updateAnimationOptions({
                        enabled: currentAnimationEnabled
                    })
                }
                that._drawn()
            },
            _dataSourceChangedHandler: function() {
                this._requestChange(["MOSTLY_TOTAL"])
            },
            _updateContent: function(canvas) {
                var sliderMarkerOptions, indents, scaleLabelsAreaHeight, rangeContainerCanvas, that = this,
                    chartOptions = that.option("chart"),
                    seriesDataSource = that._createSeriesDataSource(chartOptions),
                    isCompactMode = !(seriesDataSource && seriesDataSource.isShowChart() || that.option("background.image.url")),
                    scaleOptions = prepareScaleOptions(that._getOption("scale"), seriesDataSource, that._incidentOccurred),
                    argTranslatorRange = calculateTranslatorRange(seriesDataSource, scaleOptions),
                    tickIntervalsInfo = updateTickIntervals(scaleOptions, canvas.width, that._incidentOccurred, argTranslatorRange),
                    chartThemeManager = seriesDataSource && seriesDataSource.isShowChart() && seriesDataSource.getThemeManager();
                if (chartThemeManager) {
                    checkLogarithmicOptions(chartOptions && chartOptions.valueAxis, chartThemeManager.getOptions("valueAxis").logarithmBase, that._incidentOccurred)
                }
                updateScaleOptions(scaleOptions, seriesDataSource, argTranslatorRange, tickIntervalsInfo, getDateMarkerVisibilityChecker(canvas.width));
                updateTranslatorRangeInterval(argTranslatorRange, scaleOptions);
                sliderMarkerOptions = that._prepareSliderMarkersOptions(scaleOptions, canvas.width, tickIntervalsInfo);
                indents = calculateIndents(that._renderer, scaleOptions, sliderMarkerOptions, that.option("indent"));
                scaleLabelsAreaHeight = calculateScaleAreaHeight(that._renderer, scaleOptions, showScaleMarkers(scaleOptions));
                rangeContainerCanvas = {
                    left: canvas.left + indents.left,
                    top: canvas.top + indents.top,
                    width: _max(canvas.width - indents.left - indents.right, 1),
                    height: _max(!isCompactMode ? canvas.height - indents.top - indents.bottom - scaleLabelsAreaHeight : commonModule.HEIGHT_COMPACT_MODE, 0)
                };
                updateTranslator(that._translator, argTranslatorRange, [rangeContainerCanvas.left, rangeContainerCanvas.left + rangeContainerCanvas.width], scaleOptions.minRange);
                scaleOptions.minorTickInterval = scaleOptions.isEmpty ? 0 : scaleOptions.minorTickInterval;
                that._updateElements(scaleOptions, sliderMarkerOptions, isCompactMode, rangeContainerCanvas, seriesDataSource);
                if (chartThemeManager) {
                    chartThemeManager.dispose()
                }
            },
            _updateElements: function(scaleOptions, sliderMarkerOptions, isCompactMode, canvas, seriesDataSource) {
                var that = this,
                    behavior = that._getOption("behavior"),
                    selectedRange = that.option(SELECTED_RANGE),
                    shutterOptions = that._getOption("shutter"),
                    isNotSemiDiscrete = scaleOptions.type !== SEMIDISCRETE;
                if (selectedRange) {
                    if (null !== selectedRange[START_VALUE] && !that._translator.isValid(selectedRange[START_VALUE])) {
                        that._incidentOccurred("E2203", [START_VALUE])
                    }
                    if (null !== selectedRange[END_VALUE] && !that._translator.isValid(selectedRange[END_VALUE])) {
                        that._incidentOccurred("E2203", [END_VALUE])
                    }
                }
                shutterOptions.color = shutterOptions.color || that._getOption(CONTAINER_BACKGROUND_COLOR, true);
                that._rangeView.update(that.option("background"), that._themeManager.theme("background"), canvas, isCompactMode, behavior.animationEnabled && that._renderer.animationEnabled(), seriesDataSource);
                that._axis.update(scaleOptions, isCompactMode, canvas);
                that._isUpdating = true;
                that._slidersController.update([canvas.top, canvas.top + canvas.height], behavior, isCompactMode, that._getOption("sliderHandle"), sliderMarkerOptions, shutterOptions, {
                    minRange: isNotSemiDiscrete ? that.option("scale.minRange") : void 0,
                    maxRange: isNotSemiDiscrete ? that.option("scale.maxRange") : void 0
                }, that._axis.getFullTicks(), that._getOption("selectedRangeColor", true));
                that._slidersController.setSelectedRange(selectedRange);
                that._isUpdating = false;
                that._tracker.update(!that._translator.isEmptyValueRange(), behavior)
            },
            _createSeriesDataSource: function(chartOptions) {
                var seriesDataSource, that = this,
                    dataSource = that._dataSource.items(),
                    scaleOptions = that._getOption("scale"),
                    valueType = scaleOptions.valueType || calculateValueType(scaleOptions.startValue, scaleOptions.endValue);
                if (dataSource || chartOptions && chartOptions.series) {
                    chartOptions = $.extend({}, chartOptions, {
                        theme: that.option("theme")
                    });
                    seriesDataSource = new seriesDataSourceModule.SeriesDataSource({
                        renderer: that._renderer,
                        dataSource: dataSource,
                        valueType: _normalizeEnum(valueType),
                        axisType: scaleOptions.type,
                        chart: chartOptions,
                        dataSourceField: that.option("dataSourceField"),
                        incidentOccurred: that._incidentOccurred,
                        categories: scaleOptions.categories
                    })
                }
                return seriesDataSource
            },
            _prepareSliderMarkersOptions: function(scaleOptions, screenDelta, tickIntervalsInfo) {
                var businessInterval, that = this,
                    minorTickInterval = tickIntervalsInfo.minorTickInterval,
                    tickInterval = tickIntervalsInfo.tickInterval,
                    endValue = scaleOptions.endValue,
                    startValue = scaleOptions.startValue,
                    sliderMarkerOptions = that._getOption(SLIDER_MARKER),
                    sliderMarkerUserOption = that.option(SLIDER_MARKER) || {},
                    isTypeDiscrete = scaleOptions.type === DISCRETE,
                    isValueTypeDatetime = scaleOptions.valueType === DATETIME;
                sliderMarkerOptions.borderColor = that._getOption(CONTAINER_BACKGROUND_COLOR, true);
                if (!sliderMarkerOptions.format) {
                    if (!that._getOption("behavior").snapToTicks && _isNumber(scaleOptions.startValue)) {
                        businessInterval = Math.abs(endValue - startValue);
                        sliderMarkerOptions.format = {
                            type: "fixedPoint",
                            precision: vizUtils.getSignificantDigitPosition(businessInterval / screenDelta)
                        }
                    }
                    if (isValueTypeDatetime && !isTypeDiscrete) {
                        if (!scaleOptions.marker.visible) {
                            if (_isDefined(startValue) && _isDefined(endValue)) {
                                sliderMarkerOptions.format = formatHelper.getDateFormatByTickInterval(startValue, endValue, _isDefined(minorTickInterval) && 0 !== minorTickInterval ? minorTickInterval : tickInterval)
                            }
                        } else {
                            sliderMarkerOptions.format = dateUtils.getDateFormatByTickInterval(_isDefined(minorTickInterval) && 0 !== minorTickInterval ? minorTickInterval : tickInterval)
                        }
                    }
                    if (isValueTypeDatetime && isTypeDiscrete && tickIntervalsInfo.ticks.length) {
                        sliderMarkerOptions.format = formatHelper.getDateFormatByTicks(tickIntervalsInfo.ticks)
                    }
                }
                if (void 0 !== sliderMarkerUserOption.padding && void 0 === sliderMarkerUserOption.paddingLeftRight && void 0 === sliderMarkerUserOption.paddingTopBottom) {
                    sliderMarkerOptions.paddingLeftRight = sliderMarkerOptions.paddingTopBottom = sliderMarkerUserOption.padding
                }
                return sliderMarkerOptions
            },
            getSelectedRange: function() {
                return this._slidersController.getSelectedRange()
            },
            setSelectedRange: function(range) {
                var current;
                if (!this._isUpdating && range) {
                    current = this._slidersController.getSelectedRange();
                    if (!current || current.startValue !== range.startValue || current.endValue !== range.endValue) {
                        this._slidersController.setSelectedRange(range)
                    }
                }
            },
            resetSelectedRange: function() {
                this.setSelectedRange({})
            },
            _setContentSize: function() {
                this.__isResizing = 2 === this._changes.count();
                this.callBase.apply(this, arguments)
            },
            render: function(isResizing) {
                this.__isResizing = isResizing;
                this.callBase.apply(this, arguments);
                this._requestChange(["MOSTLY_TOTAL"])
            }
        });
        $.each(["selectedRangeColor", "containerBackgroundColor", "sliderMarker", "sliderHandle", "shutter", OPTION_BACKGROUND, "behavior", "chart", "indent"], function(_, name) {
            dxRangeSelector.prototype._optionChangesMap[name] = "MOSTLY_TOTAL"
        });

        function prepareAxisOptions(scaleOptions, isCompactMode, height, axisPosition) {
            scaleOptions.label.overlappingBehavior = {
                mode: scaleOptions.useTicksAutoArrangement ? "enlargeTickInterval" : "ignore"
            };
            scaleOptions.marker.label.font = scaleOptions.label.font;
            scaleOptions.color = scaleOptions.marker.color = scaleOptions.tick.color;
            scaleOptions.opacity = scaleOptions.marker.opacity = scaleOptions.tick.opacity;
            scaleOptions.width = scaleOptions.marker.width = scaleOptions.tick.width;
            scaleOptions.placeholderSize = (scaleOptions.placeholderHeight || 0) + axisPosition;
            scaleOptions.argumentType = scaleOptions.valueType;
            scaleOptions.visible = isCompactMode;
            scaleOptions.minorTick.showCalculatedTicks = scaleOptions.isHorizontal = scaleOptions.withoutOverlappingBehavior = scaleOptions.stick = true;
            if (!isCompactMode) {
                scaleOptions.minorTick.length = scaleOptions.tick.length = height
            }
            scaleOptions.label.indentFromAxis = scaleOptions.label.topIndent + axisPosition;
            return scaleOptions
        }

        function createDateMarkersEvent(scaleOptions, markerTrackers, setSelectedRange) {
            $.each(markerTrackers, function(_, value) {
                value.on("dxpointerdown", onPointerDown)
            });

            function onPointerDown(e) {
                var range = e.target.range,
                    minRange = scaleOptions.minRange ? addInterval(range.startValue, scaleOptions.minRange) : void 0,
                    maxRange = scaleOptions.maxRange ? addInterval(range.startValue, scaleOptions.maxRange) : void 0;
                if (!(minRange && minRange > range.endValue || maxRange && maxRange < range.endValue)) {
                    setSelectedRange(range)
                }
            }
        }

        function AxisWrapper(params) {
            this._axis = new axisModule.Axis({
                renderer: params.renderer,
                axesContainerGroup: params.root,
                axisType: "xyAxes",
                drawingType: "linear",
                widgetClass: "dxrs",
                axisClass: "range-selector"
            });
            this._updateSelectedRangeCallback = params.updateSelectedRange;
            this._translator = params.translator
        }
        AxisWrapper.prototype = {
            constructor: AxisWrapper,
            dispose: function() {
                this._axis.dispose()
            },
            update: function(options, isCompactMode, canvas) {
                var axis = this._axis;
                axis.updateOptions(prepareAxisOptions(options, isCompactMode, canvas.height, canvas.height / 2 - Math.ceil(options.width / 2)));
                axis.delta = {
                    bottom: -canvas.height / 2
                };
                axis.setTranslator(this._translator, {
                    translateSpecialCase: function() {
                        return canvas.top + canvas.height
                    }
                });
                axis.draw();
                if (axis.getMarkerTrackers()) {
                    createDateMarkersEvent(options, axis.getMarkerTrackers(), this._updateSelectedRangeCallback)
                }
            },
            getFullTicks: function() {
                return this._axis.getFullTicks()
            }
        };
        registerComponent("dxRangeSelector", dxRangeSelector);
        module.exports = dxRangeSelector;
        dxRangeSelector.addPlugin(__webpack_require__( /*! ../core/data_source */ 493).plugin);
        dxRangeSelector.addPlugin(__webpack_require__( /*! ../core/export */ 444).plugin);
        dxRangeSelector.addPlugin(__webpack_require__( /*! ../core/title */ 494).plugin);
        dxRangeSelector.addPlugin(__webpack_require__( /*! ../core/loading_indicator */ 496).plugin)
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/range_selector/common.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var _format = __webpack_require__( /*! ../core/format */ 465),
            isFunction = __webpack_require__( /*! ../../core/utils/common */ 14).isFunction,
            HEIGHT_COMPACT_MODE = 24,
            POINTER_SIZE = 4,
            EMPTY_SLIDER_MARKER_TEXT = ". . .";
        var utils = {
            trackerSettings: {
                fill: "grey",
                stroke: "grey",
                opacity: 1e-4
            },
            animationSettings: {
                duration: 250
            }
        };
        var consts = {
            emptySliderMarkerText: EMPTY_SLIDER_MARKER_TEXT,
            pointerSize: POINTER_SIZE
        };
        var formatValue = function(value, formatOptions) {
            var formatObject = {
                value: value,
                valueText: _format(value, formatOptions)
            };
            return String(isFunction(formatOptions.customizeText) ? formatOptions.customizeText.call(formatObject, formatObject) : formatObject.valueText)
        };
        exports.utils = utils;
        exports.consts = consts;
        exports.formatValue = formatValue;
        exports.HEIGHT_COMPACT_MODE = HEIGHT_COMPACT_MODE
    },
    /*!**********************************************************!*\
      !*** ./Scripts/viz/range_selector/sliders_controller.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            commonModule = __webpack_require__( /*! ./common */ 540),
            animationSettings = commonModule.utils.animationSettings,
            emptySliderMarkerText = commonModule.consts.emptySliderMarkerText,
            Slider = __webpack_require__( /*! ./slider */ 542),
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum;

        function buildRectPoints(left, top, right, bottom) {
            return [left, top, right, top, right, bottom, left, bottom]
        }

        function valueOf(value) {
            return value && value.valueOf()
        }

        function isLess(a, b) {
            return a < b
        }

        function isGreater(a, b) {
            return a > b
        }

        function selectClosestValue(target, values) {
            var middle, start = 0,
                end = values ? values.length - 1 : 0,
                val = target;
            while (end - start > 1) {
                middle = start + end >> 1;
                val = values[middle];
                if (val === target) {
                    return target
                } else {
                    if (target < val) {
                        end = middle
                    } else {
                        start = middle
                    }
                }
            }
            if (values) {
                val = values[target - values[start] <= values[end] - target ? start : end]
            }
            return val
        }

        function dummyProcessSelectionChanged() {
            this._lastSelectedRange = this.getSelectedRange();
            delete this._processSelectionChanged
        }

        function suppressSetSelectedRange(controller) {
            controller.setSelectedRange = $.noop;
            if (controller._processSelectionChanged === dummyProcessSelectionChanged) {
                controller._processSelectionChanged()
            }
        }

        function restoreSetSelectedRange(controller) {
            delete controller.setSelectedRange
        }

        function SlidersController(params) {
            var that = this,
                sliderParams = {
                    renderer: params.renderer,
                    root: params.root,
                    trackersGroup: params.trackersGroup,
                    translator: params.translator
                };
            that._params = params;
            that._areaTracker = params.renderer.path(null, "area").attr({
                "class": "area-tracker",
                fill: "#000000",
                opacity: 1e-4
            }).append(params.trackersGroup);
            that._selectedAreaTracker = params.renderer.path(null, "area").attr({
                "class": "selected-area-tracker",
                fill: "#000000",
                opacity: 1e-4
            }).append(params.trackersGroup);
            that._shutter = params.renderer.path(null, "area").append(params.root);
            that._sliders = [new Slider(sliderParams, 0), new Slider(sliderParams, 1)];
            that._processSelectionChanged = dummyProcessSelectionChanged
        }
        SlidersController.prototype = {
            constructor: SlidersController,
            dispose: function() {
                this._sliders[0].dispose();
                this._sliders[1].dispose()
            },
            getTrackerTargets: function() {
                return {
                    area: this._areaTracker,
                    selectedArea: this._selectedAreaTracker,
                    sliders: this._sliders
                }
            },
            _processSelectionChanged: function() {
                var that = this,
                    selectedRange = that.getSelectedRange();
                if (valueOf(selectedRange.startValue) !== valueOf(that._lastSelectedRange.startValue) || valueOf(selectedRange.endValue) !== valueOf(that._lastSelectedRange.endValue)) {
                    that._lastSelectedRange = selectedRange;
                    that._params.updateSelectedRange(selectedRange)
                }
            },
            update: function(verticalRange, behavior, isCompactMode, sliderHandleOptions, sliderMarkerOptions, shutterOptions, rangeBounds, fullTicks, selectedRangeColor) {
                var that = this,
                    screenRange = that._params.translator.getScreenRange();
                that._verticalRange = verticalRange;
                that._minRange = rangeBounds.minRange;
                that._maxRange = rangeBounds.maxRange;
                that._animationEnabled = behavior.animationEnabled && that._params.renderer.animationEnabled();
                that._allowSlidersSwap = behavior.allowSlidersSwap;
                that._sliders[0].update(verticalRange, sliderHandleOptions, sliderMarkerOptions);
                that._sliders[1].update(verticalRange, sliderHandleOptions, sliderMarkerOptions);
                that._sliders[0]._position = that._sliders[1]._position = screenRange[0];
                that._values = !that._params.translator.isValueProlonged && behavior.snapToTicks ? fullTicks : null;
                that._areaTracker.attr({
                    points: buildRectPoints(screenRange[0], verticalRange[0], screenRange[1], verticalRange[1])
                });
                that._isCompactMode = isCompactMode;
                that._shutterOffset = sliderHandleOptions.width / 2;
                that._updateSelectedView(shutterOptions, selectedRangeColor);
                that._isOnMoving = "onmoving" === _normalizeEnum(behavior.callSelectedRangeChanged);
                that._updateSelectedRange();
                that._applyTotalPosition(false)
            },
            _updateSelectedView: function(shutterOptions, selectedRangeColor) {
                var settings = {
                    fill: null,
                    "fill-opacity": null,
                    stroke: null,
                    "stroke-width": null
                };
                if (this._isCompactMode) {
                    settings.stroke = selectedRangeColor;
                    settings["stroke-width"] = 3;
                    settings.sharp = "v"
                } else {
                    settings.fill = shutterOptions.color;
                    settings["fill-opacity"] = shutterOptions.opacity
                }
                this._shutter.attr(settings)
            },
            _updateSelectedRange: function() {
                var that = this,
                    sliders = that._sliders;
                sliders[0].cancelAnimation();
                sliders[1].cancelAnimation();
                that._shutter.stopAnimation();
                if (that._params.translator.isEmptyValueRange()) {
                    sliders[0]._setText(emptySliderMarkerText);
                    sliders[1]._setText(emptySliderMarkerText);
                    sliders[0]._value = sliders[1]._value = void 0;
                    sliders[0]._position = that._params.translator.getScreenRange()[0];
                    sliders[1]._position = that._params.translator.getScreenRange()[1];
                    that._applyTotalPosition(false);
                    suppressSetSelectedRange(that)
                } else {
                    restoreSetSelectedRange(that)
                }
            },
            _applyTotalPosition: function(isAnimated) {
                var areOverlapped, sliders = this._sliders;
                isAnimated = this._animationEnabled && isAnimated;
                sliders[0].applyPosition(isAnimated);
                sliders[1].applyPosition(isAnimated);
                areOverlapped = sliders[0].getCloudBorder() > sliders[1].getCloudBorder();
                sliders[0].setOverlapped(areOverlapped);
                sliders[1].setOverlapped(areOverlapped);
                this._applyAreaTrackersPosition();
                this._applySelectedRangePosition(isAnimated)
            },
            _applyAreaTrackersPosition: function() {
                var that = this,
                    position1 = that._sliders[0].getPosition(),
                    position2 = that._sliders[1].getPosition();
                that._selectedAreaTracker.attr({
                    points: buildRectPoints(position1, that._verticalRange[0], position2, that._verticalRange[1])
                }).css({
                    cursor: Math.abs(that._params.translator.getScreenRange()[1] - that._params.translator.getScreenRange()[0] - position2 + position1) < .001 ? "default" : "pointer"
                })
            },
            _applySelectedRangePosition: function(isAnimated) {
                var screenRange, points, that = this,
                    verticalRange = that._verticalRange,
                    pos1 = that._sliders[0].getPosition(),
                    pos2 = that._sliders[1].getPosition();
                if (that._isCompactMode) {
                    points = [pos1 + Math.ceil(that._shutterOffset), (verticalRange[0] + verticalRange[1]) / 2, pos2 - Math.floor(that._shutterOffset), (verticalRange[0] + verticalRange[1]) / 2]
                } else {
                    screenRange = that._params.translator.getScreenRange();
                    points = [buildRectPoints(screenRange[0], verticalRange[0], Math.max(pos1 - Math.floor(that._shutterOffset), screenRange[0]), verticalRange[1]), buildRectPoints(screenRange[1], verticalRange[0], Math.min(pos2 + Math.ceil(that._shutterOffset), screenRange[1]), verticalRange[1])]
                }
                if (isAnimated) {
                    that._shutter.animate({
                        points: points
                    }, animationSettings)
                } else {
                    that._shutter.attr({
                        points: points
                    })
                }
            },
            getSelectedRange: function() {
                return {
                    startValue: this._sliders[0].getValue(),
                    endValue: this._sliders[1].getValue()
                }
            },
            setSelectedRange: function(arg) {
                arg = arg || {};
                var that = this,
                    translator = that._params.translator,
                    startValue = translator.isValid(arg.startValue) ? translator.parse(arg.startValue) : translator.getRange()[0],
                    endValue = translator.isValid(arg.endValue) ? translator.parse(arg.endValue) : translator.getRange()[1],
                    values = translator.to(startValue, -1) < translator.to(endValue, 1) ? [startValue, endValue] : [endValue, startValue];
                that._sliders[0].setDisplayValue(values[0]);
                that._sliders[1].setDisplayValue(values[1]);
                that._sliders[0]._position = translator.to(values[0], -1);
                that._sliders[1]._position = translator.to(values[1], 1);
                that._applyTotalPosition(true);
                that._processSelectionChanged()
            },
            beginSelectedAreaMoving: function(initialPosition) {
                var that = this,
                    sliders = that._sliders,
                    offset = (sliders[0].getPosition() + sliders[1].getPosition()) / 2 - initialPosition,
                    currentPosition = initialPosition;
                move.complete = function() {
                    that._dockSelectedArea()
                };
                return move;

                function move(position) {
                    if (position !== currentPosition && position > currentPosition === position > (sliders[0].getPosition() + sliders[1].getPosition()) / 2 - offset) {
                        that._moveSelectedArea(position + offset, false)
                    }
                    currentPosition = position
                }
            },
            _dockSelectedArea: function() {
                var translator = this._params.translator,
                    sliders = this._sliders;
                sliders[0]._position = translator.to(sliders[0].getValue(), -1);
                sliders[1]._position = translator.to(sliders[1].getValue(), 1);
                this._applyTotalPosition(true);
                this._processSelectionChanged()
            },
            moveSelectedArea: function(screenPosition) {
                this._moveSelectedArea(screenPosition, true);
                this._dockSelectedArea()
            },
            _moveSelectedArea: function(screenPosition, isAnimated) {
                var startValue, endValue, that = this,
                    translator = that._params.translator,
                    sliders = that._sliders,
                    interval = sliders[1].getPosition() - sliders[0].getPosition(),
                    startPosition = screenPosition - interval / 2,
                    endPosition = screenPosition + interval / 2;
                if (startPosition < translator.getScreenRange()[0]) {
                    startPosition = translator.getScreenRange()[0];
                    endPosition = startPosition + interval
                }
                if (endPosition > translator.getScreenRange()[1]) {
                    endPosition = translator.getScreenRange()[1];
                    startPosition = endPosition - interval
                }
                startValue = translator.from(startPosition, -1);
                endValue = translator.from(endPosition, 1);
                sliders[0].setDisplayValue(selectClosestValue(startValue, that._values));
                sliders[1].setDisplayValue(selectClosestValue(endValue, that._values));
                sliders[0]._position = startPosition;
                sliders[1]._position = endPosition;
                that._applyTotalPosition(isAnimated);
                if (that._isOnMoving) {
                    that._processSelectionChanged()
                }
            },
            placeSliderAndBeginMoving: function(firstPosition, secondPosition) {
                var thresholdPosition, handler, that = this,
                    translator = that._params.translator,
                    sliders = that._sliders,
                    index = firstPosition < secondPosition ? 0 : 1,
                    dir = index > 0 ? 1 : -1,
                    compare = index > 0 ? isGreater : isLess,
                    antiCompare = index > 0 ? isLess : isGreater,
                    positions = [],
                    values = [];
                values[index] = translator.from(firstPosition, dir);
                values[1 - index] = translator.from(secondPosition, -dir);
                positions[1 - index] = secondPosition;
                if (translator.isValueProlonged) {
                    if (compare(firstPosition, translator.to(values[index], dir))) {
                        values[index] = translator.from(firstPosition, -dir)
                    }
                    if (compare(secondPosition, translator.to(values[index], -dir))) {
                        values[1 - index] = values[index]
                    }
                }
                if (that._minRange) {
                    thresholdPosition = translator.to(translator.add(selectClosestValue(values[index], that._values), that._minRange, -dir), -dir);
                    if (compare(secondPosition, thresholdPosition)) {
                        values[1 - index] = translator.add(values[index], that._minRange, -dir)
                    }
                    thresholdPosition = translator.to(translator.add(translator.getRange()[1 - index], that._minRange, dir), -dir);
                    if (antiCompare(firstPosition, thresholdPosition)) {
                        values[1 - index] = translator.getRange()[1 - index];
                        values[index] = translator.add(values[1 - index], that._minRange, dir);
                        positions[1 - index] = firstPosition
                    }
                }
                values[0] = selectClosestValue(values[0], that._values);
                values[1] = selectClosestValue(values[1], that._values);
                positions[index] = translator.to(values[index], dir);
                sliders[0].setDisplayValue(values[0]);
                sliders[1].setDisplayValue(values[1]);
                sliders[0]._position = positions[0];
                sliders[1]._position = positions[1];
                that._applyTotalPosition(true);
                if (that._isOnMoving) {
                    that._processSelectionChanged()
                }
                handler = that.beginSliderMoving(1 - index, secondPosition);
                sliders[1 - index]._sliderGroup.stopAnimation();
                that._shutter.stopAnimation();
                handler(secondPosition);
                return handler
            },
            beginSliderMoving: function(initialIndex, initialPosition) {
                var that = this,
                    translator = that._params.translator,
                    sliders = that._sliders,
                    minPosition = translator.getScreenRange()[0],
                    maxPosition = translator.getScreenRange()[1],
                    index = initialIndex,
                    staticPosition = sliders[1 - index].getPosition(),
                    currentPosition = initialPosition,
                    dir = index > 0 ? 1 : -1,
                    compareMin = index > 0 ? isLess : isGreater,
                    compareMax = index > 0 ? isGreater : isLess,
                    moveOffset = sliders[index].getPosition() - initialPosition,
                    swapOffset = compareMin(sliders[index].getPosition(), initialPosition) ? -moveOffset : moveOffset;
                move.complete = function() {
                    sliders[index]._setValid(true);
                    that._dockSelectedArea()
                };
                return move;

                function move(position) {
                    var isValid, temp, pos, slider, value;
                    if (position !== currentPosition) {
                        if (compareMin(position + swapOffset, staticPosition)) {
                            isValid = that._allowSlidersSwap;
                            if (isValid && !translator.isValueProlonged && that._minRange) {
                                isValid = translator.isValid(translator.add(sliders[1 - index].getValue(), that._minRange, -dir))
                            }
                            if (isValid) {
                                that._changeMovingSlider(index);
                                index = 1 - index;
                                dir = -dir;
                                temp = compareMin;
                                compareMin = compareMax;
                                compareMax = temp;
                                moveOffset = -dir * Math.abs(moveOffset);
                                swapOffset = -moveOffset
                            }
                        }
                        if (compareMax(position + moveOffset, staticPosition)) {
                            isValid = true;
                            slider = sliders[index];
                            value = sliders[1 - index].getValue();
                            pos = Math.max(Math.min(position + moveOffset, maxPosition), minPosition);
                            if (isValid && translator.isValueProlonged) {
                                isValid = !compareMin(pos, translator.to(value, dir))
                            }
                            if (isValid && that._minRange) {
                                isValid = !compareMin(pos, translator.to(translator.add(value, that._minRange, dir), dir))
                            }
                            if (isValid && that._maxRange) {
                                isValid = !compareMax(pos, translator.to(translator.add(value, that._maxRange, dir), dir))
                            }
                            slider._setValid(isValid);
                            slider.setDisplayValue(isValid ? selectClosestValue(translator.from(pos, dir), that._values) : slider.getValue());
                            slider._position = pos;
                            that._applyTotalPosition(false);
                            slider.toForeground();
                            if (that._isOnMoving) {
                                that._processSelectionChanged()
                            }
                        }
                    }
                    currentPosition = position
                }
            },
            _changeMovingSlider: function(index) {
                var newValue, that = this,
                    translator = that._params.translator,
                    sliders = that._sliders,
                    position = sliders[1 - index].getPosition(),
                    dir = index > 0 ? 1 : -1;
                sliders[index].setDisplayValue(selectClosestValue(translator.from(position, dir), that._values));
                newValue = translator.from(position, -dir);
                if (translator.isValueProlonged) {
                    newValue = translator.from(position, dir)
                } else {
                    if (that._minRange) {
                        newValue = translator.add(newValue, that._minRange, -dir)
                    }
                }
                sliders[1 - index].setDisplayValue(selectClosestValue(newValue, that._values));
                sliders[index]._setValid(true);
                sliders[index]._marker._update();
                sliders[0]._position = sliders[1]._position = position
            },
            foregroundSlider: function(index) {
                this._sliders[index].toForeground()
            }
        };
        exports.SlidersController = SlidersController
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/range_selector/slider.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var commonModule = __webpack_require__( /*! ./common */ 540),
            animationSettings = commonModule.utils.animationSettings,
            formatValue = commonModule.formatValue,
            SliderMarker = __webpack_require__( /*! ./slider_marker */ 543),
            support = __webpack_require__( /*! ../../core/utils/support */ 48),
            SPLITTER_WIDTH = 8,
            TOUCH_SPLITTER_WIDTH = 20;

        function getSliderTrackerWidth(sliderHandleWidth) {
            return support.touchEvents || support.pointer ? TOUCH_SPLITTER_WIDTH : SPLITTER_WIDTH < sliderHandleWidth ? sliderHandleWidth : SPLITTER_WIDTH
        }

        function Slider(params, index) {
            var that = this;
            that._translator = params.translator;
            that._sliderGroup = params.renderer.g().attr({
                "class": "slider"
            }).append(params.root);
            that._line = params.renderer.path(null, "line").append(that._sliderGroup);
            that._marker = new SliderMarker(params.renderer, that._sliderGroup, 1 === index);
            that._tracker = params.renderer.rect().attr({
                "class": "slider-tracker",
                fill: "#000000",
                opacity: 1e-4
            }).css({
                cursor: "w-resize"
            }).append(params.trackersGroup)
        }
        Slider.prototype = {
            constructor: Slider,
            cancelAnimation: function() {
                this._sliderGroup.stopAnimation();
                this._tracker.stopAnimation()
            },
            applyPosition: function(isAnimated) {
                var that = this,
                    slider = that._sliderGroup,
                    tracker = that._tracker,
                    attrs = {
                        translateX: that._position
                    };
                that._marker.setPosition(that._position);
                if (isAnimated) {
                    slider.animate(attrs, animationSettings);
                    tracker.animate(attrs, animationSettings)
                } else {
                    slider.attr(attrs);
                    tracker.attr(attrs)
                }
            },
            _setValid: function(isValid) {
                this._marker.setValid(isValid);
                this._line.attr({
                    stroke: this._colors[Number(isValid)]
                })
            },
            _setText: function(text) {
                this._marker.setText(text)
            },
            update: function(verticalRange, sliderHandleOptions, sliderMarkerOptions) {
                var that = this;
                that._formatOptions = {
                    format: sliderMarkerOptions.format,
                    precision: sliderMarkerOptions.precision,
                    customizeText: sliderMarkerOptions.customizeText
                };
                that._marker.applyOptions(sliderMarkerOptions, that._translator.getScreenRange());
                that._colors = [sliderMarkerOptions.invalidRangeColor, sliderHandleOptions.color];
                that._sliderGroup.attr({
                    translateY: verticalRange[0]
                });
                that._line.attr({
                    "stroke-width": sliderHandleOptions.width,
                    stroke: sliderHandleOptions.color,
                    "stroke-opacity": sliderHandleOptions.opacity,
                    sharp: "h",
                    points: [0, 0, 0, verticalRange[1] - verticalRange[0]]
                });
                var trackerWidth = getSliderTrackerWidth(sliderHandleOptions.width);
                that._tracker.attr({
                    x: -trackerWidth / 2,
                    y: 0,
                    width: trackerWidth,
                    height: verticalRange[1] - verticalRange[0],
                    translateY: verticalRange[0]
                })
            },
            toForeground: function() {
                this._sliderGroup.toForeground()
            },
            getSliderTracker: function() {
                return this._tracker
            },
            getPosition: function() {
                return this._position
            },
            setDisplayValue: function(value) {
                this._value = value;
                this._setText(formatValue(value, this._formatOptions))
            },
            setOverlapped: function(isOverlapped) {
                this._marker.setOverlapped(isOverlapped)
            },
            getValue: function() {
                return this._value
            },
            on: function(event, handler) {
                this._tracker.on(event, handler);
                this._marker.getTracker().on(event, handler)
            },
            getCloudBorder: function() {
                return this._marker.getBorderPosition()
            },
            dispose: function() {
                this._marker.dispose()
            }
        };
        module.exports = Slider
    },
    /*!*****************************************************!*\
      !*** ./Scripts/viz/range_selector/slider_marker.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var patchFontOptions = __webpack_require__( /*! ../core/utils */ 442).patchFontOptions,
            SLIDER_MARKER_UPDATE_DELAY = 75,
            POINTER_SIZE = __webpack_require__( /*! ./common */ 540).consts.pointerSize;

        function SliderMarker(renderer, root, isLeftPointer) {
            var that = this;
            that._isLeftPointer = isLeftPointer;
            that._isOverlapped = false;
            that._group = renderer.g().attr({
                "class": "slider-marker"
            }).append(root);
            that._area = renderer.path(null, "area").append(that._group);
            that._label = renderer.text().attr({
                align: "left"
            }).append(that._group);
            that._tracker = renderer.rect().attr({
                "class": "slider-marker-tracker",
                fill: "#000000",
                opacity: 1e-4
            }).css({
                cursor: "pointer"
            }).append(that._group);
            that._border = renderer.rect(0, 0, 1, 0)
        }
        SliderMarker.prototype = {
            constructor: SliderMarker,
            _getRectSize: function(textSize) {
                return {
                    width: Math.round(2 * this._paddingLeftRight + textSize.width),
                    height: Math.round(2 * this._paddingTopBottom + textSize.height)
                }
            },
            _getTextSize: function() {
                var textSize = this._label.getBBox();
                if (!this._textHeight && isFinite(textSize.height)) {
                    this._textHeight = textSize.height
                }
                return {
                    width: textSize.width,
                    height: this._textHeight,
                    y: textSize.y
                }
            },
            _getAreaPointsInfo: function(textSize) {
                var that = this,
                    rectSize = that._getRectSize(textSize),
                    rectWidth = rectSize.width,
                    rectHeight = rectSize.height,
                    rectLeftBorder = -rectWidth,
                    rectRightBorder = 0,
                    pointerRightPoint = POINTER_SIZE,
                    pointerCenterPoint = 0,
                    pointerLeftPoint = -POINTER_SIZE,
                    position = that._position,
                    isLeft = that._isLeftPointer,
                    correctCloudBorders = function() {
                        rectLeftBorder++;
                        rectRightBorder++;
                        pointerRightPoint++;
                        pointerCenterPoint++;
                        pointerLeftPoint++
                    },
                    checkPointerBorders = function() {
                        if (pointerRightPoint > rectRightBorder) {
                            pointerRightPoint = rectRightBorder
                        } else {
                            if (pointerLeftPoint < rectLeftBorder) {
                                pointerLeftPoint = rectLeftBorder
                            }
                        }
                        isLeft && correctCloudBorders()
                    },
                    borderPosition = position;
                if (isLeft) {
                    if (position > that._range[1] - rectWidth) {
                        rectRightBorder = -position + that._range[1];
                        rectLeftBorder = rectRightBorder - rectWidth;
                        checkPointerBorders();
                        borderPosition += rectLeftBorder
                    } else {
                        rectLeftBorder = pointerLeftPoint = 0;
                        rectRightBorder = rectWidth
                    }
                } else {
                    if (position - that._range[0] < rectWidth) {
                        rectLeftBorder = -(position - that._range[0]);
                        rectRightBorder = rectLeftBorder + rectWidth;
                        checkPointerBorders();
                        borderPosition += rectRightBorder
                    } else {
                        pointerRightPoint = 0;
                        correctCloudBorders()
                    }
                }
                that._borderPosition = borderPosition;
                return {
                    offset: rectLeftBorder,
                    isCutted: (!isLeft || pointerCenterPoint !== pointerLeftPoint) && (isLeft || pointerCenterPoint !== pointerRightPoint),
                    points: [rectLeftBorder, 0, rectRightBorder, 0, rectRightBorder, rectHeight, pointerRightPoint, rectHeight, pointerCenterPoint, rectHeight + POINTER_SIZE, pointerLeftPoint, rectHeight, rectLeftBorder, rectHeight]
                }
            },
            _update: function() {
                var textSize, currentTextSize, rectSize, that = this;
                clearTimeout(that._timeout);
                that._label.attr({
                    text: that._text || ""
                });
                currentTextSize = that._getTextSize();
                rectSize = that._getRectSize(currentTextSize);
                textSize = that._textSize || currentTextSize;
                textSize = that._textSize = currentTextSize.width > textSize.width || currentTextSize.height > textSize.height ? currentTextSize : textSize;
                that._timeout = setTimeout(function() {
                    updateSliderMarker(currentTextSize, rectSize);
                    that._textSize = currentTextSize
                }, SLIDER_MARKER_UPDATE_DELAY);

                function updateSliderMarker(size, rectSize) {
                    var points, pointsData, offset;
                    rectSize = rectSize || that._getRectSize(size);
                    that._group.attr({
                        translateY: -(rectSize.height + POINTER_SIZE)
                    });
                    pointsData = that._getAreaPointsInfo(size);
                    points = pointsData.points;
                    offset = pointsData.offset;
                    that._area.attr({
                        points: points
                    });
                    that._border.attr({
                        x: that._isLeftPointer ? points[0] - 1 : points[2],
                        height: pointsData.isCutted ? rectSize.height : rectSize.height + POINTER_SIZE
                    });
                    that._tracker.attr({
                        translateX: offset,
                        width: rectSize.width,
                        height: rectSize.height + POINTER_SIZE
                    });
                    that._label.attr({
                        translateX: that._paddingLeftRight + offset,
                        translateY: rectSize.height / 2 - (size.y + size.height / 2)
                    })
                }
                updateSliderMarker(textSize)
            },
            setText: function(value) {
                this._text = value
            },
            setPosition: function(position) {
                this._position = position;
                this._update()
            },
            applyOptions: function(options, screenRange) {
                var that = this;
                that._range = screenRange;
                that._paddingLeftRight = options.paddingLeftRight;
                that._paddingTopBottom = options.paddingTopBottom;
                that._textHeight = null;
                that._colors = [options.invalidRangeColor, options.color];
                that._area.attr({
                    fill: options.color
                });
                that._border.attr({
                    fill: options.borderColor
                });
                that._label.css(patchFontOptions(options.font));
                that._update()
            },
            getTracker: function() {
                return this._tracker
            },
            setValid: function(isValid) {
                this._area.attr({
                    fill: this._colors[Number(isValid)]
                })
            },
            setColor: function(color) {
                this._area.attr({
                    fill: color
                })
            },
            dispose: function() {
                clearTimeout(this._timeout)
            },
            setOverlapped: function(isOverlapped) {
                var that = this;
                if (that._isOverlapped !== isOverlapped) {
                    if (isOverlapped) {
                        that._border.append(that._group)
                    } else {
                        that._isOverlapped && that._border.remove()
                    }
                    that._isOverlapped = isOverlapped
                }
            },
            getBorderPosition: function() {
                return this._borderPosition
            }
        };
        module.exports = SliderMarker
    },
    /*!***********************************************!*\
      !*** ./Scripts/viz/range_selector/tracker.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            pointerEvents = __webpack_require__( /*! ../../events/pointer */ 65),
            msPointerEnabled = __webpack_require__( /*! ../../core/utils/support */ 48).pointer,
            MIN_MANUAL_SELECTING_WIDTH = 10;

        function isLeftButtonPressed(event) {
            var e = event || window.event,
                originalEvent = e.originalEvent,
                touches = e.touches,
                pointerType = originalEvent ? originalEvent.pointerType : false,
                eventTouches = originalEvent ? originalEvent.touches : false,
                isIE8LeftClick = void 0 === e.which && 1 === e.button,
                isMSPointerLeftClick = originalEvent && void 0 !== pointerType && (pointerType === (originalEvent.MSPOINTER_TYPE_TOUCH || "touch") || pointerType === (originalEvent.MSPOINTER_TYPE_MOUSE || "mouse") && 1 === originalEvent.buttons),
                isLeftClick = isIE8LeftClick || 1 === e.which,
                isTouches = touches && touches.length > 0 || eventTouches && eventTouches.length > 0;
            return isLeftClick || isMSPointerLeftClick || isTouches
        }

        function isMultiTouches(event) {
            var originalEvent = event.originalEvent,
                touches = event.touches,
                eventTouches = originalEvent && originalEvent.touches;
            return touches && touches.length > 1 || eventTouches && eventTouches.length > 1 || null
        }

        function preventDefault(e) {
            if (!isMultiTouches(e)) {
                e.preventDefault()
            }
        }

        function stopPropagationAndPreventDefault(e) {
            if (!isMultiTouches(e)) {
                e.stopPropagation();
                e.preventDefault()
            }
        }

        function isTouchEventArgs(e) {
            return e && e.type && 0 === e.type.indexOf("touch")
        }

        function getEventPageX(event) {
            var originalEvent = event.originalEvent,
                result = 0;
            if (event.pageX) {
                result = event.pageX
            } else {
                if (originalEvent && originalEvent.pageX) {
                    result = originalEvent.pageX
                }
            }
            if (originalEvent && originalEvent.touches) {
                if (originalEvent.touches.length > 0) {
                    result = originalEvent.touches[0].pageX
                } else {
                    if (originalEvent.changedTouches.length > 0) {
                        result = originalEvent.changedTouches[0].pageX
                    }
                }
            }
            return result
        }

        function initializeAreaEvents(controller, area, state, getRootOffsetLeft) {
            var isTouchEvent, initialPosition, isActive = false,
                movingHandler = null,
                docEvents = {};
            docEvents[pointerEvents.move] = function(e) {
                var position, offset;
                if (isTouchEvent !== isTouchEventArgs(e)) {
                    return
                }
                if (!isLeftButtonPressed(e)) {
                    cancel()
                }
                if (isActive) {
                    position = getEventPageX(e);
                    offset = getRootOffsetLeft();
                    if (movingHandler) {
                        movingHandler(position - offset)
                    } else {
                        if (state.manualRangeSelectionEnabled && Math.abs(initialPosition - position) >= MIN_MANUAL_SELECTING_WIDTH) {
                            movingHandler = controller.placeSliderAndBeginMoving(initialPosition - offset, position - offset)
                        }
                    }
                }
            };
            docEvents[pointerEvents.up] = function(e) {
                var position;
                if (isActive) {
                    position = getEventPageX(e);
                    if (!movingHandler && state.moveSelectedRangeByClick && Math.abs(initialPosition - position) < MIN_MANUAL_SELECTING_WIDTH) {
                        controller.moveSelectedArea(position - getRootOffsetLeft())
                    }
                    cancel()
                }
            };

            function cancel() {
                if (isActive) {
                    isActive = false;
                    if (movingHandler) {
                        movingHandler.complete();
                        movingHandler = null
                    }
                }
            }
            area.on(pointerEvents.down, function(e) {
                if (!state.enabled || !isLeftButtonPressed(e) || isActive) {
                    return
                }
                isActive = true;
                isTouchEvent = isTouchEventArgs(e);
                initialPosition = getEventPageX(e)
            });
            return docEvents
        }

        function initializeSelectedAreaEvents(controller, area, state, getRootOffsetLeft) {
            var isTouchEvent, isActive = false,
                movingHandler = null,
                docEvents = {};
            docEvents[pointerEvents.move] = function(e) {
                if (isTouchEvent !== isTouchEventArgs(e)) {
                    return
                }
                if (!isLeftButtonPressed(e)) {
                    cancel()
                }
                if (isActive) {
                    preventDefault(e);
                    movingHandler(getEventPageX(e) - getRootOffsetLeft())
                }
            };
            docEvents[pointerEvents.up] = cancel;

            function cancel() {
                if (isActive) {
                    isActive = false;
                    movingHandler.complete();
                    movingHandler = null
                }
            }
            area.on(pointerEvents.down, function(e) {
                if (!state.enabled || !isLeftButtonPressed(e) || isActive) {
                    return
                }
                isActive = true;
                isTouchEvent = isTouchEventArgs(e);
                movingHandler = controller.beginSelectedAreaMoving(getEventPageX(e) - getRootOffsetLeft());
                stopPropagationAndPreventDefault(e)
            });
            return docEvents
        }

        function initializeSliderEvents(controller, sliders, state, getRootOffsetLeft) {
            var isTouchEvent, isActive = false,
                movingHandler = null,
                docEvents = {};
            docEvents[pointerEvents.move] = function(e) {
                if (isTouchEvent !== isTouchEventArgs(e)) {
                    return
                }
                if (!isLeftButtonPressed(e)) {
                    cancel()
                }
                if (isActive) {
                    preventDefault(e);
                    movingHandler(getEventPageX(e) - getRootOffsetLeft())
                }
            };
            docEvents[pointerEvents.up] = cancel;
            $.each(sliders, function(i, slider) {
                var events = {};
                events[pointerEvents.down] = function(e) {
                    if (!state.enabled || !isLeftButtonPressed(e) || isActive) {
                        return
                    }
                    isActive = true;
                    isTouchEvent = isTouchEventArgs(e);
                    movingHandler = controller.beginSliderMoving(i, getEventPageX(e) - getRootOffsetLeft());
                    stopPropagationAndPreventDefault(e)
                };
                events[pointerEvents.move] = function() {
                    if (!movingHandler) {
                        controller.foregroundSlider(i)
                    }
                };
                slider.on(events)
            });

            function cancel() {
                if (isActive) {
                    isActive = false;
                    movingHandler.complete();
                    movingHandler = null
                }
            }
            return docEvents
        }

        function Tracker(params) {
            var state = this._state = {},
                targets = params.controller.getTrackerTargets();
            if (msPointerEnabled) {
                params.renderer.root.css({
                    msTouchAction: "pinch-zoom"
                })
            }
            this._docEvents = [initializeSelectedAreaEvents(params.controller, targets.selectedArea, state, getRootOffsetLeft), initializeAreaEvents(params.controller, targets.area, state, getRootOffsetLeft), initializeSliderEvents(params.controller, targets.sliders, state, getRootOffsetLeft)];
            $.each(this._docEvents, function(_, events) {
                $(document).on(events)
            });

            function getRootOffsetLeft() {
                return params.renderer.getRootOffset().left
            }
        }
        Tracker.prototype = {
            constructor: Tracker,
            dispose: function() {
                $.each(this._docEvents, function(_, events) {
                    $(document).off(events)
                })
            },
            update: function(enabled, behavior) {
                var state = this._state;
                state.enabled = enabled;
                state.moveSelectedRangeByClick = behavior.moveSelectedRangeByClick;
                state.manualRangeSelectionEnabled = behavior.manualRangeSelectionEnabled
            }
        };
        exports.Tracker = Tracker
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/range_selector/range_view.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var translator2DModule = __webpack_require__( /*! ../translators/translator2d */ 497);

        function createTranslator(valueRange, screenRange) {
            return new translator2DModule.Translator2D(valueRange, {
                top: screenRange[0],
                height: screenRange[1]
            })
        }

        function drawSeriesView(root, seriesDataSource, translator, screenRange, isAnimationEnabled) {
            var series, i, seriesList = seriesDataSource.getSeries(),
                ii = seriesList.length,
                translators = {
                    x: translator,
                    y: createTranslator(seriesDataSource.getBoundRange().val, screenRange)
                };
            seriesDataSource.adjustSeriesDimensions(translators);
            for (i = 0; i < ii; ++i) {
                series = seriesList[i];
                series._extGroups.seriesGroup = series._extGroups.labelsGroup = root;
                series.draw(translators, isAnimationEnabled)
            }
        }

        function merge(a, b) {
            return void 0 !== a ? a : b
        }

        function RangeView(params) {
            this._params = params;
            this._clipRect = params.renderer.clipRect();
            params.root.attr({
                clipId: this._clipRect.id
            })
        }
        RangeView.prototype = {
            constructor: RangeView,
            update: function(backgroundOption, backgroundTheme, canvas, isCompactMode, isAnimationEnabled, seriesDataSource) {
                var renderer = this._params.renderer,
                    root = this._params.root;
                backgroundOption = backgroundOption || {};
                root.clear();
                this._clipRect.attr({
                    x: canvas.left,
                    y: canvas.top,
                    width: canvas.width,
                    height: canvas.height
                });
                if (!isCompactMode) {
                    if (merge(backgroundOption.visible, backgroundTheme.visible)) {
                        if (backgroundOption.color) {
                            renderer.rect(canvas.left, canvas.top, canvas.width + 1, canvas.height).attr({
                                fill: merge(backgroundOption.color, backgroundTheme.color),
                                "class": "dx-range-selector-background"
                            }).append(root)
                        }
                        if (backgroundOption.image && backgroundOption.image.url) {
                            renderer.image(canvas.left, canvas.top, canvas.width + 1, canvas.height, backgroundOption.image.url, merge(backgroundOption.image.location, backgroundTheme.image.location)).append(root)
                        }
                    }
                    if (seriesDataSource && seriesDataSource.isShowChart()) {
                        drawSeriesView(root, seriesDataSource, this._params.translator, [canvas.top, canvas.top + canvas.height], isAnimationEnabled)
                    }
                }
            }
        };
        exports.RangeView = RangeView
    },
    /*!**********************************************************!*\
      !*** ./Scripts/viz/range_selector/series_data_source.js ***!
      \**********************************************************/
    function(module, exports, __webpack_require__) {
        var SeriesDataSource, $ = __webpack_require__( /*! jquery */ 9),
            seriesModule = __webpack_require__( /*! ../series/base_series */ 460),
            seriesFamilyModule = __webpack_require__( /*! ../core/series_family */ 515),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            rangeModule = __webpack_require__( /*! ../translators/range */ 503),
            dataValidatorModule = __webpack_require__( /*! ../components/data_validator */ 458),
            ChartThemeManager = __webpack_require__( /*! ../components/chart_theme_manager */ 484).ThemeManager;
        var createThemeManager = function(chartOptions) {
            return new ChartThemeManager(chartOptions, "rangeSelector.chart")
        };
        var processSeriesFamilies = function(series, equalBarWidth, minBubbleSize, maxBubbleSize, barWidth, negativesAsZeroes) {
            var families = [],
                types = [];
            $.each(series, function(i, item) {
                if ($.inArray(item.type, types) === -1) {
                    types.push(item.type)
                }
            });
            $.each(types, function(_, type) {
                var family = new seriesFamilyModule.SeriesFamily({
                    type: type,
                    equalBarWidth: equalBarWidth,
                    minBubbleSize: minBubbleSize,
                    maxBubbleSize: maxBubbleSize,
                    barWidth: barWidth,
                    negativesAsZeroes: negativesAsZeroes
                });
                family.add(series);
                family.adjustSeriesValues();
                families.push(family)
            });
            return families
        };
        var isStickType = function(type) {
            var nonStickTypes = ["bar", "candlestick", "stock", "bubble"],
                stickType = true;
            type = vizUtils.normalizeEnum(type);
            $.each(nonStickTypes, function(_, item) {
                if (type.indexOf(item) !== -1) {
                    stickType = false;
                    return false
                }
            });
            return stickType
        };

        function setTemplateFields(data, templateData, series) {
            $.each(data, function(_, data) {
                $.each(series.getTemplateFields(), function(_, field) {
                    data[field.templateField] = data[field.originalField]
                });
                templateData.push(data)
            });
            series.updateTemplateFieldNames()
        }
        SeriesDataSource = function(options) {
            var templatedSeries, seriesTemplate, topIndent, bottomIndent, negativesAsZeroes, negativesAsZeros, that = this,
                themeManager = that._themeManager = createThemeManager(options.chart);
            themeManager._fontFields = ["commonSeriesSettings.label.font"];
            themeManager.setTheme(options.chart.theme);
            topIndent = themeManager.getOptions("topIndent");
            bottomIndent = themeManager.getOptions("bottomIndent");
            that._indent = {
                top: topIndent >= 0 && topIndent < 1 ? topIndent : 0,
                bottom: bottomIndent >= 0 && bottomIndent < 1 ? bottomIndent : 0
            };
            that._valueAxis = themeManager.getOptions("valueAxisRangeSelector") || {};
            that._hideChart = false;
            seriesTemplate = themeManager.getOptions("seriesTemplate");
            if (options.dataSource && seriesTemplate) {
                templatedSeries = vizUtils.processSeriesTemplate(seriesTemplate, options.dataSource)
            }
            that._useAggregation = options.chart.useAggregation;
            that._series = that._calculateSeries(options, templatedSeries);
            negativesAsZeroes = themeManager.getOptions("negativesAsZeroes");
            negativesAsZeros = themeManager.getOptions("negativesAsZeros");
            that._seriesFamilies = processSeriesFamilies(that._series, themeManager.getOptions("equalBarWidth"), themeManager.getOptions("minBubbleSize"), themeManager.getOptions("maxBubbleSize"), themeManager.getOptions("barWidth"), commonUtils.isDefined(negativesAsZeroes) ? negativesAsZeroes : negativesAsZeros)
        };
        SeriesDataSource.prototype = {
            constructor: SeriesDataSource,
            _calculateSeries: function(options, templatedSeries) {
                var particularSeriesOptions, seriesTheme, data, parsedData, dataSourceField, i, newSeries, groupsData, that = this,
                    series = [],
                    chartThemeManager = that._themeManager,
                    hasSeriesTemplate = !!chartThemeManager.getOptions("seriesTemplate"),
                    allSeriesOptions = hasSeriesTemplate ? templatedSeries : options.chart.series,
                    seriesValueType = options.chart.valueAxis && options.chart.valueAxis.valueType;
                that.templateData = [];
                if (options.dataSource && !allSeriesOptions) {
                    dataSourceField = options.dataSourceField || "arg";
                    allSeriesOptions = {
                        argumentField: dataSourceField,
                        valueField: dataSourceField
                    };
                    that._hideChart = true
                }
                allSeriesOptions = $.isArray(allSeriesOptions) ? allSeriesOptions : allSeriesOptions ? [allSeriesOptions] : [];
                for (i = 0; i < allSeriesOptions.length; i++) {
                    particularSeriesOptions = $.extend(true, {
                        incidentOccurred: options.incidentOccurred
                    }, allSeriesOptions[i]);
                    particularSeriesOptions.rotated = false;
                    data = particularSeriesOptions.data || options.dataSource;
                    seriesTheme = chartThemeManager.getOptions("series", particularSeriesOptions);
                    seriesTheme.argumentField = seriesTheme.argumentField || options.dataSourceField;
                    if (data && data.length > 0) {
                        newSeries = new seriesModule.Series({
                            renderer: options.renderer
                        }, seriesTheme);
                        series.push(newSeries)
                    }
                    if (hasSeriesTemplate) {
                        setTemplateFields(data, that.templateData, newSeries)
                    }
                }
                data = hasSeriesTemplate ? that.templateData : data;
                if (series.length) {
                    groupsData = {
                        groups: [{
                            series: series,
                            valueOptions: {
                                valueType: dataSourceField ? options.valueType : seriesValueType
                            }
                        }],
                        argumentOptions: {
                            categories: options.categories,
                            argumentType: options.valueType,
                            type: options.axisType
                        }
                    };
                    parsedData = dataValidatorModule.validateData(data, groupsData, options.incidentOccurred, chartThemeManager.getOptions("dataPrepareSettings"));
                    that.argCategories = groupsData.categories;
                    for (i = 0; i < series.length; i++) {
                        series[i].updateData(parsedData[series[i].getArgumentField()])
                    }
                }
                return series
            },
            adjustSeriesDimensions: function(translators) {
                if (this._useAggregation) {
                    $.each(this._series, function(_, s) {
                        s.resamplePoints(translators.x)
                    })
                }
                $.each(this._seriesFamilies, function(_, family) {
                    family.adjustSeriesDimensions({
                        arg: translators.x,
                        val: translators.y
                    })
                })
            },
            getBoundRange: function() {
                var rangeData, rangeYSize, rangeVisibleSizeY, minIndent, maxIndent, that = this,
                    valueAxisMin = that._valueAxis.min,
                    valueAxisMax = that._valueAxis.max,
                    valRange = new rangeModule.Range({
                        min: valueAxisMin,
                        minVisible: valueAxisMin,
                        max: valueAxisMax,
                        maxVisible: valueAxisMax,
                        axisType: that._valueAxis.type,
                        base: that._valueAxis.logarithmBase
                    }),
                    argRange = new rangeModule.Range({});
                $.each(that._series, function(_, series) {
                    rangeData = series.getRangeData();
                    valRange.addRange(rangeData.val);
                    argRange.addRange(rangeData.arg);
                    if (!isStickType(series.type)) {
                        argRange.addRange({
                            stick: false
                        })
                    }
                });
                if (valRange.isDefined() && argRange.isDefined()) {
                    minIndent = that._valueAxis.inverted ? that._indent.top : that._indent.bottom;
                    maxIndent = that._valueAxis.inverted ? that._indent.bottom : that._indent.top;
                    rangeYSize = valRange.max - valRange.min;
                    rangeVisibleSizeY = ($.isNumeric(valRange.maxVisible) ? valRange.maxVisible : valRange.max) - ($.isNumeric(valRange.minVisible) ? valRange.minVisible : valRange.min);
                    if (commonUtils.isDate(valRange.min)) {
                        valRange.min = new Date(valRange.min.valueOf() - rangeYSize * minIndent)
                    } else {
                        valRange.min -= rangeYSize * minIndent
                    }
                    if (commonUtils.isDate(valRange.max)) {
                        valRange.max = new Date(valRange.max.valueOf() + rangeYSize * maxIndent)
                    } else {
                        valRange.max += rangeYSize * maxIndent
                    }
                    if ($.isNumeric(rangeVisibleSizeY)) {
                        valRange.maxVisible = valRange.maxVisible ? valRange.maxVisible + rangeVisibleSizeY * maxIndent : void 0;
                        valRange.minVisible = valRange.minVisible ? valRange.minVisible - rangeVisibleSizeY * minIndent : void 0
                    }
                    valRange.invert = that._valueAxis.inverted
                }
                return {
                    arg: argRange,
                    val: valRange
                }
            },
            getSeries: function() {
                return this._series
            },
            isEmpty: function() {
                return 0 === this.getSeries().length
            },
            isShowChart: function() {
                return !this._hideChart
            },
            getCalculatedValueType: function() {
                var series = this._series[0];
                return series && series.argumentType
            },
            getThemeManager: function() {
                return this._themeManager
            }
        };
        exports.SeriesDataSource = SeriesDataSource
    },
    /*!*****************************************************!*\
      !*** ./Scripts/viz/range_selector/theme_manager.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var BaseThemeManager = __webpack_require__( /*! ../core/base_theme_manager */ 485).BaseThemeManager;
        exports.ThemeManager = BaseThemeManager.inherit({
            _themeSection: "rangeSelector",
            _fontFields: ["scale.label.font", "sliderMarker.font", "loadingIndicator.font", "export.font", "title.font", "title.subtitle.font"]
        })
    },
    /*!***********************************!*\
      !*** ./Scripts/viz/vector_map.js ***!
      \***********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./vector_map/vector_map */ 549)
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/vector_map/vector_map.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _parseScalar = __webpack_require__( /*! ../core/utils */ 442).parseScalar,
            projectionModule = __webpack_require__( /*! ./projection.main */ 550),
            controlBarModule = __webpack_require__( /*! ./control_bar */ 552),
            gestureHandlerModule = __webpack_require__( /*! ./gesture_handler */ 553),
            trackerModule = __webpack_require__( /*! ./tracker */ 554),
            themeManagerModule = __webpack_require__( /*! ./theme_manager */ 555),
            dataExchangerModule = __webpack_require__( /*! ./data_exchanger */ 556),
            legendModule = __webpack_require__( /*! ./legend */ 557),
            layoutModule = __webpack_require__( /*! ./layout */ 558),
            mapLayerModule = __webpack_require__( /*! ./map_layer */ 559),
            tooltipViewerModule = __webpack_require__( /*! ./tooltip_viewer */ 560),
            _noop = $.noop,
            _extend = $.extend,
            DEFAULT_WIDTH = 800,
            DEFAULT_HEIGHT = 400,
            nextDataKey = 1,
            RE_STARTS_LAYERS = /^layers/,
            RE_ENDS_DATA_SOURCE = /\.(dataSource|data)$/;
        __webpack_require__( /*! ./projection */ 561);

        function generateDataKey() {
            return "vectormap-data-" + nextDataKey++
        }
        var dxVectorMap = __webpack_require__( /*! ../core/base_widget */ 448).inherit({
            _eventsMap: {
                onClick: {
                    name: "click"
                },
                onCenterChanged: {
                    name: "centerChanged"
                },
                onZoomFactorChanged: {
                    name: "zoomFactorChanged"
                },
                onAreaClick: {
                    name: "areaClick"
                },
                onAreaHoverChanged: {
                    name: "areaHoverChanged"
                },
                onAreaSelectionChanged: {
                    name: "areaSelectionChanged"
                },
                onMarkerClick: {
                    name: "markerClick"
                },
                onMarkerHoverChanged: {
                    name: "markerHoverChanged"
                },
                onMarkerSelectionChanged: {
                    name: "markerSelectionChanged"
                },
                onHoverChanged: {
                    name: "hoverChanged"
                },
                onSelectionChanged: {
                    name: "selectionChanged"
                }
            },
            _setDeprecatedOptions: function() {
                this.callBase.apply(this, arguments);
                _extend(this._deprecatedOptions, {
                    areaSettings: {
                        since: "15.2",
                        message: "Use the 'layers' option instead"
                    },
                    markerSettings: {
                        since: "15.2",
                        message: "Use the 'layers' option instead"
                    },
                    mapData: {
                        since: "15.2",
                        message: "Use the 'layers' option instead"
                    },
                    markers: {
                        since: "15.2",
                        message: "Use the 'layers' option instead"
                    },
                    onAreaClick: {
                        since: "15.2",
                        message: "Use the 'onClick' option instead"
                    },
                    onMarkerClick: {
                        since: "15.2",
                        message: "Use the 'onClick' option instead"
                    },
                    onAreaHoverChanged: {
                        since: "15.2",
                        message: "Use the 'onHoverChanged' option instead"
                    },
                    onMarkerHoverChanged: {
                        since: "15.2",
                        message: "Use the 'onHoverChanged' option instead"
                    },
                    onAreaSelectionChanged: {
                        since: "15.2",
                        message: "Use the 'onSelectionChanged' option instead"
                    },
                    onMarkerSelectionChanged: {
                        since: "15.2",
                        message: "Use the 'onSelectionChanged' option instead"
                    },
                    "layers.data": {
                        since: "15.2",
                        message: "Use the 'layers.dataSource' option instead"
                    }
                })
            },
            _rootClassPrefix: "dxm",
            _rootClass: "dxm-vector-map",
            _createThemeManager: function() {
                return new themeManagerModule.ThemeManager
            },
            _initLayerCollection: function(dataKey) {
                var that = this;
                that._layerCollection = new mapLayerModule.MapLayerCollection({
                    renderer: that._renderer,
                    projection: that._projection,
                    themeManager: that._themeManager,
                    tracker: that._tracker,
                    dataKey: dataKey,
                    eventTrigger: that._eventTrigger,
                    dataExchanger: that._dataExchanger,
                    tooltip: that._tooltip,
                    notifyDirty: that._notifyDirty,
                    notifyReady: that._notifyReady
                });
                if (void 0 === that._options.layers && (that._options.mapData || that._options.markers)) {
                    applyDeprecatedMode(that)
                } else {
                    suspendLayersData(that._layerCollection, that._options.layers)
                }
            },
            _initLegendsControl: function() {
                var that = this;
                that._legendsControl = new legendModule.LegendsControl({
                    renderer: that._renderer,
                    container: that._root,
                    layoutControl: that._layoutControl,
                    themeManager: that._themeManager,
                    dataExchanger: that._dataExchanger,
                    notifyDirty: that._notifyDirty,
                    notifyReady: that._notifyReady
                })
            },
            _initControlBar: function(dataKey) {
                var that = this;
                that._controlBar = new controlBarModule.ControlBar({
                    renderer: that._renderer,
                    container: that._root,
                    layoutControl: that._layoutControl,
                    projection: that._projection,
                    tracker: that._tracker,
                    dataKey: dataKey
                })
            },
            _initElements: function() {
                var that = this,
                    dataKey = generateDataKey(),
                    notifyCounter = 0;
                that._notifyDirty = function() {
                    that._resetIsReady();
                    ++notifyCounter
                };
                that._notifyReady = function() {
                    if (0 === --notifyCounter) {
                        that._drawn()
                    }
                };
                that._dataExchanger = new dataExchangerModule.DataExchanger;
                that._projection = new projectionModule.Projection({
                    centerChanged: function(value) {
                        if (that._initialized) {
                            that._eventTrigger("centerChanged", {
                                center: value
                            })
                        }
                    },
                    zoomChanged: function(value) {
                        if (that._initialized) {
                            that._eventTrigger("zoomFactorChanged", {
                                zoomFactor: value
                            })
                        }
                    }
                });
                that._tracker = new trackerModule.Tracker({
                    root: that._root,
                    projection: that._projection,
                    dataKey: dataKey
                });
                that._gestureHandler = new gestureHandlerModule.GestureHandler({
                    projection: that._projection,
                    renderer: that._renderer,
                    tracker: that._tracker
                });
                that._layoutControl = new layoutModule.LayoutControl;
                that._layoutControl.suspend();
                that._initLayerCollection(dataKey);
                that._initControlBar(dataKey);
                that._initLegendsControl();
                that._tooltipViewer = new tooltipViewerModule.TooltipViewer({
                    tracker: that._tracker,
                    tooltip: that._tooltip,
                    layerCollection: that._layerCollection
                })
            },
            _init: function() {
                this.callBase.apply(this, arguments);
                this._afterInit();
                this._layoutControl.resume()
            },
            _initialChanges: ["PROJECTION", "BOUNDS", "MAX_ZOOM_FACTOR", "ZOOM_FACTOR", "CENTER"],
            _afterInit: function() {
                resumeLayersData(this._layerCollection, this._options.layers, this._renderer)
            },
            _initCore: function() {
                this._root = this._renderer.root.attr({
                    align: "center",
                    cursor: "default"
                });
                this._initElements()
            },
            _disposeCore: function() {
                var that = this;
                that._controlBar.dispose();
                that._gestureHandler.dispose();
                that._tracker.dispose();
                that._legendsControl.dispose();
                that._layerCollection.dispose();
                that._layoutControl.dispose();
                that._tooltipViewer.dispose();
                that._dataExchanger.dispose();
                that._projection.dispose();
                that._dataExchanger = that._gestureHandler = that._projection = that._tracker = that._layoutControl = that._root = that._layerCollection = that._controlBar = that._legendsControl = null
            },
            _setupInteraction: function() {
                var options = {
                    centeringEnabled: !!_parseScalar(this._getOption("panningEnabled", true), true),
                    zoomingEnabled: !!_parseScalar(this._getOption("zoomingEnabled", true), true)
                };
                this._gestureHandler.setInteraction(options);
                this._controlBar.setInteraction(options)
            },
            _getDefaultSize: function() {
                return {
                    width: DEFAULT_WIDTH,
                    height: DEFAULT_HEIGHT
                }
            },
            _applySize: function(rect) {
                var layout = {
                    left: rect[0],
                    top: rect[1],
                    width: rect[2] - rect[0],
                    height: rect[3] - rect[1],
                    right: 0,
                    bottom: 0
                };
                this._projection.setSize(layout);
                this._layoutControl.setSize(layout);
                this._layerCollection.setRect([layout.left, layout.top, layout.width, layout.height])
            },
            _optionChanging: function(name, currentValue, nextValue) {
                if (currentValue && nextValue) {
                    if (RE_STARTS_LAYERS.test(name)) {
                        if (currentValue.dataSource && nextValue.dataSource && currentValue !== nextValue) {
                            currentValue.dataSource = null
                        } else {
                            if (currentValue.data && nextValue.data && currentValue !== nextValue) {
                                currentValue.data = null
                            } else {
                                if (RE_ENDS_DATA_SOURCE.test(name)) {
                                    this.option(name, null)
                                }
                            }
                        }
                    }
                    if ("mapData" === name) {
                        this._options.mapData = null
                    }
                    if ("markers" === name) {
                        this._options.markers = null
                    }
                }
            },
            _applyChanges: function() {
                this._notifyDirty();
                this.callBase.apply(this, arguments);
                this._notifyReady()
            },
            _optionChangesMap: {
                background: "BACKGROUND",
                layers: "LAYERS",
                areaSettings: "LAYERS",
                markerSettings: "LAYERS",
                mapData: "LAYERS",
                markers: "LAYERS",
                controlBar: "CONTROL_BAR",
                legends: "LEGENDS",
                touchEnabled: "TRACKER",
                wheelEnabled: "TRACKER",
                panningEnabled: "INTERACTION",
                zoomingEnabled: "INTERACTION",
                projection: "PROJECTION",
                bounds: "BOUNDS",
                maxZoomFactor: "MAX_ZOOM_FACTOR",
                zoomFactor: "ZOOM_FACTOR",
                center: "CENTER"
            },
            _optionChangesOrder: ["PROJECTION", "BOUNDS", "MAX_ZOOM_FACTOR", "ZOOM_FACTOR", "CENTER", "BACKGROUND", "LAYERS", "CONTROL_BAR", "LEGENDS", "TRACKER", "INTERACTION"],
            _change_PROJECTION: function() {
                this._setProjection()
            },
            _change_BOUNDS: function() {
                this._setBounds()
            },
            _change_MAX_ZOOM_FACTOR: function() {
                this._setMaxZoom()
            },
            _change_ZOOM_FACTOR: function() {
                this._setZoom()
            },
            _change_CENTER: function() {
                this._setCenter()
            },
            _change_BACKGROUND: function() {
                this._setBackgroundOptions()
            },
            _change_LAYERS: function() {
                this._setLayerCollectionOptions()
            },
            _change_CONTROL_BAR: function() {
                this._setControlBarOptions()
            },
            _change_LEGENDS: function() {
                this._setLegendsOptions()
            },
            _change_TRACKER: function() {
                this._setTrackerOptions()
            },
            _change_INTERACTION: function() {
                this._setupInteraction()
            },
            _themeDependentChanges: ["BACKGROUND", "LAYERS", "CONTROL_BAR", "LEGENDS", "TRACKER", "INTERACTION"],
            _setProjection: function() {
                this._projection.setEngine(this.option("projection"))
            },
            _setBounds: function() {
                this._projection.setBounds(this.option("bounds"))
            },
            _setMaxZoom: function() {
                this._projection.setMaxZoom(this.option("maxZoomFactor"))
            },
            _setZoom: function() {
                this._projection.setZoom(this.option("zoomFactor"))
            },
            _setCenter: function() {
                this._projection.setCenter(this.option("center"))
            },
            _setBackgroundOptions: function() {
                this._layerCollection.setBackgroundOptions(this._getOption("background"))
            },
            _setLayerCollectionOptions: function() {
                this._layerCollection.setOptions(this.option("layers"))
            },
            _setControlBarOptions: function() {
                this._controlBar.setOptions(this._getOption("controlBar"))
            },
            _setLegendsOptions: function() {
                this._legendsControl.setOptions(this.option("legends"))
            },
            _setTrackerOptions: function() {
                this._tracker.setOptions({
                    touchEnabled: this._getOption("touchEnabled", true),
                    wheelEnabled: this._getOption("wheelEnabled", true)
                })
            },
            getLayers: function() {
                var i, layers = this._layerCollection.items(),
                    list = [],
                    ii = list.length = layers.length;
                for (i = 0; i < ii; ++i) {
                    list[i] = layers[i].proxy
                }
                return list
            },
            getLayerByIndex: function(index) {
                var layer = this._layerCollection.byIndex(index);
                return layer ? layer.proxy : null
            },
            getLayerByName: function(name) {
                var layer = this._layerCollection.byName(name);
                return layer ? layer.proxy : null
            },
            clearSelection: function(_noEvent) {
                var i, layers = this._layerCollection.items(),
                    ii = layers.length;
                for (i = 0; i < ii; ++i) {
                    layers[i].clearSelection(_noEvent)
                }
                return this
            },
            getAreas: _noop,
            getMarkers: _noop,
            clearAreaSelection: _noop,
            clearMarkerSelection: _noop,
            center: function(value) {
                var that = this;
                if (void 0 === value) {
                    return that._projection.getCenter()
                } else {
                    that._projection.setCenter(value);
                    return that
                }
            },
            zoomFactor: function(value) {
                var that = this;
                if (void 0 === value) {
                    return that._projection.getZoom()
                } else {
                    that._projection.setZoom(value);
                    return that
                }
            },
            viewport: function(value) {
                var that = this;
                if (void 0 === value) {
                    return that._projection.getViewport()
                } else {
                    that._projection.setViewport(value);
                    return that
                }
            },
            convertCoordinates: function(coordinates) {
                coordinates = coordinates && coordinates.length ? coordinates : [arguments[0], arguments[1]];
                return this._projection.fromScreenPoint(coordinates)
            }
        });

        function suspendLayersData(layerCollection, options) {
            if (options) {
                layerCollection.__data = options.length ? $.map(options, patch) : patch(options)
            }

            function patch(ops) {
                var ret = {};
                swapData(ops || {}, ret);
                return ret
            }
        }

        function resumeLayersData(layerCollection, options, renderer) {
            var data = layerCollection.__data;
            if (data) {
                layerCollection.__data = void 0;
                if (data.length) {
                    $.each(data, function(i, item) {
                        swapData(item, options[i])
                    })
                } else {
                    swapData(data, options)
                }
                renderer.lock();
                layerCollection.setOptions(options);
                renderer.unlock()
            }
        }

        function swapData(source, target) {
            var name = !("dataSource" in source) && "data" in source ? "data" : "dataSource";
            target[name] = source[name];
            source[name] = void 0
        }

        function applyDeprecatedMode(map) {
            var log = __webpack_require__( /*! ../../core/errors */ 17).log,
                mapData = map._options.mapData,
                markers = map._options.markers;
            map._options.mapData = map._options.markers = void 0;
            map._afterInit = function() {
                this._options.mapData = mapData;
                this._options.markers = markers;
                this._renderer.lock();
                this._setLayerCollectionOptions();
                this._renderer.unlock();
                mapData = markers = void 0
            };
            map._setLayerCollectionOptions = function() {
                var options = this._options,
                    mapData = options.mapData,
                    markers = options.markers;
                mapData = mapData && mapData.features ? _extend({}, mapData) : mapData;
                markers = markers && markers.features ? _extend({}, markers) : markers;
                this._layerCollection.setOptions([_extend({}, options.areaSettings, {
                    name: "areas",
                    _deprecated: true,
                    dataSource: mapData,
                    type: "area"
                }), _extend({}, options.markerSettings, {
                    name: "markers",
                    _deprecated: true,
                    dataSource: markers,
                    type: "marker",
                    elementType: options.markerSettings && options.markerSettings.type
                })])
            };
            map.getAreas = function() {
                log("W0002", this.NAME, "getAreas", "15.2", "Use the 'getLayerByName('areas').getElements()' instead");
                return this.getLayerByName("areas").getElements()
            };
            map.getMarkers = function() {
                log("W0002", this.NAME, "getMarkers", "15.2", "Use the 'getLayerByName('markers').getElements()' instead");
                return this.getLayerByName("markers").getElements()
            };
            map.clearAreaSelection = function(_noEvent) {
                log("W0002", this.NAME, "clearAreaSelection", "15.2", "Use the 'getLayerByName('areas').clearSelection()' instead");
                this.getLayerByName("areas").clearSelection(_noEvent);
                return this
            };
            map.clearMarkerSelection = function(_noEvent) {
                log("W0002", this.NAME, "clearMarkerSelection", "15.2", "Use the 'getLayerByName('markers').clearSelection()' instead");
                this.getLayerByName("markers").clearSelection(_noEvent);
                return this
            };
            var clickMap = {
                    areas: "areaClick",
                    markers: "markerClick"
                },
                hoverChangedMap = {
                    areas: "areaHoverChanged",
                    markers: "markerHoverChanged"
                },
                selectionChangedMap = {
                    areas: "areaSelectionChanged",
                    markers: "markerSelectionChanged"
                };
            map.on("click", function(e) {
                if (e.target) {
                    this._eventTrigger(clickMap[e.target.layer.name], e)
                }
            });
            map.on("hoverChanged", function(e) {
                if (e.target) {
                    this._eventTrigger(hoverChangedMap[e.target.layer.name], e)
                }
            });
            map.on("selectionChanged", function(e) {
                if (e.target) {
                    this._eventTrigger(selectionChangedMap[e.target.layer.name], e)
                }
            })
        }
        __webpack_require__( /*! ../../core/component_registrator */ 43)("dxVectorMap", dxVectorMap);
        module.exports = dxVectorMap;
        module.exports._TESTS_resetDataKey = function() {
            nextDataKey = 1
        };
        dxVectorMap.addPlugin(__webpack_require__( /*! ../core/export */ 444).plugin);
        dxVectorMap.addPlugin(__webpack_require__( /*! ../core/title */ 494).plugin);
        dxVectorMap.addPlugin(__webpack_require__( /*! ../core/tooltip */ 495).plugin);
        dxVectorMap.addPlugin(__webpack_require__( /*! ../core/loading_indicator */ 496).plugin)
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/vector_map/projection.main.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            eventEmitterModule = __webpack_require__( /*! ./event_emitter */ 551);
        var _Number = Number,
            _min = Math.min,
            _max = Math.max,
            _abs = Math.abs,
            _round = Math.round,
            _ln = Math.log,
            _pow = Math.pow,
            TWO_TO_LN2 = 2 / Math.LN2,
            MIN_BOUNDS_RANGE = 1 / 3600 / 180 / 10,
            DEFAULT_MIN_ZOOM = 1,
            DEFAULT_MAX_ZOOM = 256,
            DEFAULT_CENTER = [NaN, NaN],
            DEFAULT_ENGINE_NAME = "mercator";

        function floatsEqual(f1, f2) {
            return _abs(f1 - f2) < 1e-8
        }

        function arraysEqual(a1, a2) {
            return floatsEqual(a1[0], a2[0]) && floatsEqual(a1[1], a2[1])
        }

        function parseAndClamp(value, minValue, maxValue, defaultValue) {
            var val = _Number(value);
            return isFinite(val) ? _min(_max(val, minValue), maxValue) : defaultValue
        }

        function parseAndClampArray(value, minValue, maxValue, defaultValue) {
            return [parseAndClamp(value[0], minValue[0], maxValue[0], defaultValue[0]), parseAndClamp(value[1], minValue[1], maxValue[1], defaultValue[1])]
        }

        function getEngine(engine) {
            return engine instanceof Engine && engine || projection.get(engine) || projection.get(DEFAULT_ENGINE_NAME)
        }

        function Projection(parameters) {
            var that = this;
            that._initEvents();
            that._params = parameters;
            that._engine = getEngine();
            that._center = that._engine.center();
            that._adjustCenter()
        }
        Projection.prototype = {
            constructor: Projection,
            _minZoom: DEFAULT_MIN_ZOOM,
            _maxZoom: DEFAULT_MAX_ZOOM,
            _zoom: DEFAULT_MIN_ZOOM,
            _center: DEFAULT_CENTER,
            _canvas: {},
            _scale: [],
            dispose: function() {
                this._disposeEvents()
            },
            setEngine: function(value) {
                var that = this,
                    engine = getEngine(value);
                if (that._engine !== engine) {
                    that._engine = engine;
                    that._fire("engine");
                    if (that._changeCenter(engine.center())) {
                        that._triggerCenterChanged()
                    }
                    if (that._changeZoom(that._minZoom)) {
                        that._triggerZoomChanged()
                    }
                    that._adjustCenter();
                    that._setupScreen()
                }
            },
            setBounds: function(bounds) {
                if (void 0 !== bounds) {
                    this.setEngine(this._engine.original().bounds(bounds))
                }
            },
            _setupScreen: function() {
                var that = this,
                    canvas = that._canvas,
                    width = canvas.width,
                    height = canvas.height,
                    aspectRatio = that._engine.ar();
                that._x0 = canvas.left + width / 2;
                that._y0 = canvas.top + height / 2;
                if (width / height <= aspectRatio) {
                    that._xradius = width / 2;
                    that._yradius = width / 2 / aspectRatio
                } else {
                    that._xradius = height / 2 * aspectRatio;
                    that._yradius = height / 2
                }
                that._fire("screen")
            },
            setSize: function(canvas) {
                var that = this;
                that._canvas = canvas;
                that._setupScreen()
            },
            _toScreen: function(coordinates) {
                return [this._x0 + this._xradius * coordinates[0], this._y0 + this._yradius * coordinates[1]]
            },
            _fromScreen: function(coordinates) {
                return [(coordinates[0] - this._x0) / this._xradius, (coordinates[1] - this._y0) / this._yradius]
            },
            _toTransformed: function(coordinates) {
                return [coordinates[0] * this._zoom + this._dxcenter, coordinates[1] * this._zoom + this._dycenter]
            },
            _toTransformedFast: function(coordinates) {
                return [coordinates[0] * this._zoom, coordinates[1] * this._zoom]
            },
            _fromTransformed: function(coordinates) {
                return [(coordinates[0] - this._dxcenter) / this._zoom, (coordinates[1] - this._dycenter) / this._zoom]
            },
            _adjustCenter: function() {
                var that = this,
                    center = that._engine.project(that._center);
                that._dxcenter = -center[0] * that._zoom || 0;
                that._dycenter = -center[1] * that._zoom || 0
            },
            project: function(coordinates) {
                return this._engine.project(coordinates)
            },
            transform: function(coordinates) {
                return this._toScreen(this._toTransformedFast(coordinates))
            },
            isInvertible: function() {
                return this._engine.isinv()
            },
            getSquareSize: function(size) {
                return [size[0] * this._zoom * this._xradius, size[1] * this._zoom * this._yradius]
            },
            getZoom: function() {
                return this._zoom
            },
            _changeZoom: function(value) {
                var that = this,
                    oldZoom = that._zoom,
                    newZoom = that._zoom = parseAndClamp(value, that._minZoom, that._maxZoom, that._minZoom),
                    isChanged = !floatsEqual(oldZoom, newZoom);
                if (isChanged) {
                    that._adjustCenter();
                    that._fire("zoom")
                }
                return isChanged
            },
            setZoom: function(value) {
                if (this._engine.isinv() && this._changeZoom(value)) {
                    this._triggerZoomChanged()
                }
            },
            getScaledZoom: function() {
                return _round((this._scale.length - 1) * _ln(this._zoom) / _ln(this._maxZoom))
            },
            setScaledZoom: function(scaledZoom) {
                this.setZoom(this._scale[_round(scaledZoom)])
            },
            changeScaledZoom: function(deltaZoom) {
                this.setZoom(this._scale[_max(_min(_round(this.getScaledZoom() + deltaZoom), this._scale.length - 1), 0)])
            },
            getZoomScalePartition: function() {
                return this._scale.length - 1
            },
            _setupScaling: function() {
                var step, zoom, that = this,
                    k = _round(TWO_TO_LN2 * _ln(that._maxZoom)),
                    i = 1;
                k = k > 4 ? k : 4;
                step = _pow(that._maxZoom, 1 / k);
                zoom = that._minZoom;
                that._scale = [zoom];
                for (; i <= k; ++i) {
                    that._scale.push(zoom *= step)
                }
            },
            setMaxZoom: function(maxZoom) {
                var that = this;
                that._minZoom = DEFAULT_MIN_ZOOM;
                that._maxZoom = parseAndClamp(maxZoom, that._minZoom, _Number.MAX_VALUE, DEFAULT_MAX_ZOOM);
                that._setupScaling();
                if (that._zoom > that._maxZoom) {
                    that.setZoom(that._maxZoom)
                }
                that._fire("max-zoom")
            },
            getCenter: function() {
                return this._center.slice()
            },
            setCenter: function(value) {
                if (this._engine.isinv() && this._changeCenter(value || [])) {
                    this._triggerCenterChanged()
                }
            },
            _changeCenter: function(value) {
                var that = this,
                    engine = that._engine,
                    oldCenter = that._center,
                    newCenter = that._center = parseAndClampArray(value, engine.min(), engine.max(), engine.center()),
                    isChanged = !arraysEqual(oldCenter, newCenter);
                if (isChanged) {
                    that._adjustCenter();
                    that._fire("center")
                }
                return isChanged
            },
            _triggerCenterChanged: function() {
                this._params.centerChanged(this.getCenter())
            },
            _triggerZoomChanged: function() {
                this._params.zoomChanged(this.getZoom())
            },
            setCenterByPoint: function(coordinates, screenPosition) {
                var that = this,
                    p = that._engine.project(coordinates),
                    q = that._fromScreen(screenPosition);
                that.setCenter(that._engine.unproject([-q[0] / that._zoom + p[0], -q[1] / that._zoom + p[1]]))
            },
            beginMoveCenter: function() {
                if (this._engine.isinv()) {
                    this._moveCenter = this._center
                }
            },
            endMoveCenter: function() {
                var that = this;
                if (that._moveCenter) {
                    if (!arraysEqual(that._moveCenter, that._center)) {
                        that._triggerCenterChanged()
                    }
                    that._moveCenter = null
                }
            },
            moveCenter: function(shift) {
                var current, center, that = this;
                if (that._moveCenter) {
                    current = that._toScreen(that._toTransformed(that._engine.project(that._center)));
                    center = that._engine.unproject(that._fromTransformed(that._fromScreen([current[0] + shift[0], current[1] + shift[1]])));
                    that._changeCenter(center)
                }
            },
            getViewport: function() {
                var that = this,
                    unproject = that._engine.unproject,
                    lt = unproject(that._fromTransformed([-1, -1])),
                    lb = unproject(that._fromTransformed([-1, 1])),
                    rt = unproject(that._fromTransformed([1, -1])),
                    rb = unproject(that._fromTransformed([1, 1])),
                    minmax = findMinMax([selectFarthestPoint(lt[0], lb[0], rt[0], rb[0]), selectFarthestPoint(lt[1], rt[1], lb[1], rb[1])], [selectFarthestPoint(rt[0], rb[0], lt[0], lb[0]), selectFarthestPoint(lb[1], rb[1], lt[1], rt[1])]);
                return [].concat(minmax.min, minmax.max)
            },
            setViewport: function(viewport) {
                var engine = this._engine,
                    data = viewport ? getZoomAndCenterFromViewport(engine.project, engine.unproject, viewport) : [this._minZoom, engine.center()];
                this.setZoom(data[0]);
                this.setCenter(data[1])
            },
            getTransform: function() {
                return {
                    translateX: this._dxcenter * this._xradius,
                    translateY: this._dycenter * this._yradius
                }
            },
            fromScreenPoint: function(coordinates) {
                return this._engine.unproject(this._fromTransformed(this._fromScreen(coordinates)))
            },
            _eventNames: ["engine", "screen", "center", "zoom", "max-zoom"]
        };
        eventEmitterModule.makeEventEmitter(Projection);

        function selectFarthestPoint(point1, point2, basePoint1, basePoint2) {
            var basePoint = (basePoint1 + basePoint2) / 2;
            return _abs(point1 - basePoint) > _abs(point2 - basePoint) ? point1 : point2
        }

        function selectClosestPoint(point1, point2, basePoint1, basePoint2) {
            var basePoint = (basePoint1 + basePoint2) / 2;
            return _abs(point1 - basePoint) < _abs(point2 - basePoint) ? point1 : point2
        }

        function getZoomAndCenterFromViewport(project, unproject, viewport) {
            var lt = project([viewport[0], viewport[3]]),
                lb = project([viewport[0], viewport[1]]),
                rt = project([viewport[2], viewport[3]]),
                rb = project([viewport[2], viewport[1]]),
                l = selectClosestPoint(lt[0], lb[0], rt[0], rb[0]),
                r = selectClosestPoint(rt[0], rb[0], lt[0], lb[0]),
                t = selectClosestPoint(lt[1], rt[1], lb[1], rb[1]),
                b = selectClosestPoint(lb[1], rb[1], lt[1], rt[1]);
            return [2 / _max(_abs(l - r), _abs(t - b)), unproject([(l + r) / 2, (t + b) / 2])]
        }

        function Engine(parameters, _original) {
            var that = this,
                aspectRatio = parameters.aspectRatio > 0 ? _Number(parameters.aspectRatio) : 1,
                project = createProjectMethod(parameters.to),
                unproject = parameters.from ? createUnprojectMethod(parameters.from) : returnValue(DEFAULT_CENTER),
                center = unproject([0, 0]),
                minmax = findMinMax([unproject([-1, 0])[0], unproject([0, 1])[1]], [unproject([1, 0])[0], unproject([0, -1])[1]]);
            that.project = project;
            that.unproject = unproject;
            that.original = returnValue(_original || that);
            that.source = function() {
                return $.extend({}, parameters)
            };
            that.isinv = returnValue(!!parameters.from);
            that.ar = returnValue(aspectRatio);
            that.center = returnArray(center);
            that.min = returnArray(minmax.min);
            that.max = returnArray(minmax.max)
        }
        Engine.prototype.aspectRatio = function(aspectRatio) {
            var parameters = this.source();
            parameters.aspectRatio = aspectRatio;
            return new Engine(parameters, this)
        };
        Engine.prototype.bounds = function(bounds) {
            bounds = bounds || [];
            var parameters = this.source(),
                min = this.min(),
                max = this.max(),
                p1 = parameters.to(parseAndClampArray([bounds[0], bounds[1]], min, max, min)),
                p2 = parameters.to(parseAndClampArray([bounds[2], bounds[3]], min, max, max)),
                delta = _min(_abs(p2[0] - p1[0]) > MIN_BOUNDS_RANGE ? _abs(p2[0] - p1[0]) : 2, _abs(p2[1] - p1[1]) > MIN_BOUNDS_RANGE ? _abs(p2[1] - p1[1]) : 2);
            if (delta < 2) {
                $.extend(parameters, createProjectUnprojectMethods(parameters.to, parameters.from, p1, p2, delta))
            }
            return new Engine(parameters, this)
        };

        function isEngine(engine) {
            return engine instanceof Engine
        }

        function invertVerticalAxis(pair) {
            return [pair[0], -pair[1]]
        }

        function createProjectMethod(method) {
            return function(arg) {
                return invertVerticalAxis(method(arg))
            }
        }

        function createUnprojectMethod(method) {
            return function(arg) {
                return method(invertVerticalAxis(arg))
            }
        }

        function returnValue(value) {
            return function() {
                return value
            }
        }

        function returnArray(value) {
            return function() {
                return value.slice()
            }
        }

        function projection(parameters) {
            return parameters && parameters.to ? new Engine(parameters) : null
        }

        function findMinMax(p1, p2) {
            return {
                min: [_min(p1[0], p2[0]), _min(p1[1], p2[1])],
                max: [_max(p1[0], p2[0]), _max(p1[1], p2[1])]
            }
        }
        var projectionsCache = {};
        projection.get = function(name) {
            return projectionsCache[name] || null
        };
        projection.add = function(name, engine) {
            if (!projectionsCache[name] && isEngine(engine)) {
                projectionsCache[name] = engine
            }
            return projection
        };

        function createProjectUnprojectMethods(project, unproject, p1, p2, delta) {
            var x0 = (p1[0] + p2[0]) / 2 - delta / 2,
                y0 = (p1[1] + p2[1]) / 2 - delta / 2,
                k = 2 / delta;
            return {
                to: function(coordinates) {
                    var p = project(coordinates);
                    return [-1 + (p[0] - x0) * k, -1 + (p[1] - y0) * k]
                },
                from: function(coordinates) {
                    var p = [x0 + (coordinates[0] + 1) / k, y0 + (coordinates[1] + 1) / k];
                    return unproject(p)
                }
            }
        }
        exports.Projection = Projection;
        exports.projection = projection;
        exports._TESTS_Engine = Engine
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/vector_map/event_emitter.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9);
        var eventEmitterMethods = {
            _initEvents: function() {
                var i, names = this._eventNames,
                    ii = names.length,
                    events = this._events = {};
                for (i = 0; i < ii; ++i) {
                    events[names[i]] = $.Callbacks()
                }
            },
            _disposeEvents: function() {
                var name, events = this._events;
                for (name in events) {
                    events[name].empty()
                }
                this._events = null
            },
            on: function(handlers) {
                var name, events = this._events;
                for (name in handlers) {
                    events[name].add(handlers[name])
                }
                return dispose;

                function dispose() {
                    for (name in handlers) {
                        events[name].remove(handlers[name])
                    }
                }
            },
            _fire: function(name, arg) {
                this._events[name].fire(arg)
            }
        };
        exports.makeEventEmitter = function(target) {
            var name, prot = target.prototype;
            for (name in eventEmitterMethods) {
                prot[name] = eventEmitterMethods[name]
            }
        };
        exports._TESTS_eventEmitterMethods = eventEmitterMethods
    },
    /*!***********************************************!*\
      !*** ./Scripts/viz/vector_map/control_bar.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var _math = Math,
            _min = _math.min,
            _max = _math.max,
            _round = _math.round,
            _floor = _math.floor,
            _sqrt = _math.sqrt,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _parseScalar = vizUtils.parseScalar,
            parseHorizontalAlignment = vizUtils.enumParser(["left", "center", "right"]),
            parseVerticalAlignment = vizUtils.enumParser(["top", "bottom"]),
            COMMAND_RESET = "command-reset",
            COMMAND_MOVE_UP = "command-move-up",
            COMMAND_MOVE_RIGHT = "command-move-right",
            COMMAND_MOVE_DOWN = "command-move-down",
            COMMAND_MOVE_LEFT = "command-move-left",
            COMMAND_ZOOM_IN = "command-zoom-in",
            COMMAND_ZOOM_OUT = "command-zoom-out",
            COMMAND_ZOOM_DRAG_LINE = "command-zoom-drag-line",
            COMMAND_ZOOM_DRAG = "command-zoom-drag",
            EVENT_TARGET_TYPE = "control-bar",
            FLAG_CENTERING = 1,
            FLAG_ZOOMING = 2,
            SIZE_OPTIONS = {
                bigCircleSize: 58,
                smallCircleSize: 28,
                buttonSize: 10,
                arrowButtonOffset: 20,
                incdecButtonSize: 11,
                incButtonOffset: 66,
                decButtonOffset: 227,
                sliderLineStartOffset: 88.5,
                sliderLineEndOffset: 205.5,
                sliderLength: 20,
                sliderWidth: 8,
                trackerGap: 4
            },
            OFFSET_X = 30.5,
            OFFSET_Y = 30.5,
            TOTAL_WIDTH = 61,
            TOTAL_HEIGHT = 274,
            COMMAND_TO_TYPE_MAP = {};
        COMMAND_TO_TYPE_MAP[COMMAND_RESET] = ResetCommand;
        COMMAND_TO_TYPE_MAP[COMMAND_MOVE_UP] = COMMAND_TO_TYPE_MAP[COMMAND_MOVE_RIGHT] = COMMAND_TO_TYPE_MAP[COMMAND_MOVE_DOWN] = COMMAND_TO_TYPE_MAP[COMMAND_MOVE_LEFT] = MoveCommand;
        COMMAND_TO_TYPE_MAP[COMMAND_ZOOM_IN] = COMMAND_TO_TYPE_MAP[COMMAND_ZOOM_OUT] = ZoomCommand;
        COMMAND_TO_TYPE_MAP[COMMAND_ZOOM_DRAG] = ZoomDragCommand;

        function ControlBar(parameters) {
            var that = this;
            that._params = parameters;
            that._createElements(parameters.renderer, parameters.container, parameters.dataKey);
            parameters.layoutControl.addItem(that);
            that._subscribeToProjection(parameters.projection);
            that._subscribeToTracker(parameters.tracker);
            that._createCallbacks(parameters.projection, parameters.renderer)
        }
        ControlBar.prototype = {
            constructor: ControlBar,
            _flags: 0,
            dispose: function() {
                var that = this;
                that._params.layoutControl.removeItem(that);
                that._root.linkRemove().linkOff();
                that._offProjection();
                that._offTracker();
                that._params = that._root = that._offProjection = that._offTracker = that._callbacks = null
            },
            _subscribeToProjection: function(projection) {
                var that = this;
                that._offProjection = projection.on({
                    engine: function() {
                        that._update()
                    },
                    zoom: updateZoom,
                    "max-zoom": function() {
                        that._zoomPartition = projection.getZoomScalePartition();
                        that._sliderUnitLength = that._sliderLineLength / that._zoomPartition;
                        updateZoom()
                    }
                });

                function updateZoom() {
                    that._adjustZoom(projection.getScaledZoom())
                }
            },
            _subscribeToTracker: function(tracker) {
                var that = this,
                    isActive = false;
                that._offTracker = tracker.on({
                    start: function(arg) {
                        isActive = arg.data.name === EVENT_TARGET_TYPE;
                        if (isActive) {
                            that._processStart(arg.data.index, arg)
                        }
                    },
                    move: function(arg) {
                        if (isActive) {
                            that._processMove(arg.data.index, arg)
                        }
                    },
                    end: function(arg) {
                        if (isActive) {
                            that._processEnd();
                            isActive = false
                        }
                    }
                })
            },
            _createCallbacks: function(projection, renderer) {
                var that = this;
                that._callbacks = {
                    reset: function(isCenter, isZoom) {
                        if (isCenter) {
                            projection.setCenter(null)
                        }
                        if (isZoom) {
                            projection.setZoom(null)
                        }
                    },
                    beginMove: function() {
                        projection.beginMoveCenter()
                    },
                    endMove: function() {
                        projection.endMoveCenter()
                    },
                    move: function(shift) {
                        projection.moveCenter(shift)
                    },
                    zoom: function(zoom) {
                        projection.setScaledZoom(zoom)
                    }
                }
            },
            _createElements: function(renderer, container, dataKey) {
                var buttonsGroups, trackersGroup, that = this;
                that._root = renderer.g().attr({
                    "class": "dxm-control-bar"
                }).linkOn(container, "control-bar");
                buttonsGroups = that._buttonsGroup = renderer.g().attr({
                    "class": "dxm-control-buttons"
                }).append(that._root);
                trackersGroup = renderer.g().attr({
                    stroke: "none",
                    "stroke-width": 0,
                    fill: "#000000",
                    opacity: 1e-4
                }).css({
                    cursor: "pointer"
                }).append(that._root);
                that._createButtons(renderer, dataKey, buttonsGroups);
                that._createTrackers(renderer, dataKey, trackersGroup)
            },
            _createButtons: function(renderer, dataKey, group) {
                var that = this,
                    options = SIZE_OPTIONS,
                    size = options.buttonSize / 2,
                    offset1 = options.arrowButtonOffset - size,
                    offset2 = options.arrowButtonOffset,
                    incdecButtonSize = options.incdecButtonSize / 2,
                    directionOptions = {
                        "stroke-linecap": "square",
                        fill: "none"
                    },
                    line = "line";
                renderer.circle(0, 0, options.bigCircleSize / 2).append(group);
                renderer.circle(0, 0, size).attr({
                    fill: "none"
                }).append(group);
                renderer.path([-size, -offset1, 0, -offset2, size, -offset1], line).attr(directionOptions).append(group);
                renderer.path([offset1, -size, offset2, 0, offset1, size], line).attr(directionOptions).append(group);
                renderer.path([size, offset1, 0, offset2, -size, offset1], line).attr(directionOptions).append(group);
                renderer.path([-offset1, size, -offset2, 0, -offset1, -size], line).attr(directionOptions).append(group);
                renderer.circle(0, options.incButtonOffset, options.smallCircleSize / 2).append(group);
                renderer.path([
                    [-incdecButtonSize, options.incButtonOffset, incdecButtonSize, options.incButtonOffset],
                    [0, options.incButtonOffset - incdecButtonSize, 0, options.incButtonOffset + incdecButtonSize]
                ], "area").append(group);
                renderer.circle(0, options.decButtonOffset, options.smallCircleSize / 2).append(group);
                renderer.path([-incdecButtonSize, options.decButtonOffset, incdecButtonSize, options.decButtonOffset], "area").append(group);
                that._zoomLine = renderer.path([], "line").append(group);
                that._zoomDrag = renderer.rect(_floor(-options.sliderLength / 2), _floor(options.sliderLineEndOffset - options.sliderWidth / 2), options.sliderLength, options.sliderWidth).append(group);
                that._sliderLineLength = options.sliderLineEndOffset - options.sliderLineStartOffset
            },
            _createTrackers: function(renderer, dataKey, group) {
                var options = SIZE_OPTIONS,
                    size = _round((options.arrowButtonOffset - options.trackerGap) / 2),
                    offset1 = options.arrowButtonOffset - size,
                    offset2 = _round(_sqrt(options.bigCircleSize * options.bigCircleSize / 4 - size * size)),
                    size2 = offset2 - offset1;
                renderer.rect(-size, -size, 2 * size, 2 * size).data(dataKey, {
                    index: COMMAND_RESET,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                renderer.rect(-size, -offset2, 2 * size, size2).data(dataKey, {
                    index: COMMAND_MOVE_UP,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                renderer.rect(offset1, -size, size2, 2 * size).data(dataKey, {
                    index: COMMAND_MOVE_RIGHT,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                renderer.rect(-size, offset1, 2 * size, size2).data(dataKey, {
                    index: COMMAND_MOVE_DOWN,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                renderer.rect(-offset2, -size, size2, 2 * size).data(dataKey, {
                    index: COMMAND_MOVE_LEFT,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                renderer.circle(0, options.incButtonOffset, options.smallCircleSize / 2).data(dataKey, {
                    index: COMMAND_ZOOM_IN,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                renderer.circle(0, options.decButtonOffset, options.smallCircleSize / 2).data(dataKey, {
                    index: COMMAND_ZOOM_OUT,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                renderer.rect(-2, options.sliderLineStartOffset - 2, 4, options.sliderLineEndOffset - options.sliderLineStartOffset + 4).css({
                    cursor: "default"
                }).data(dataKey, {
                    index: COMMAND_ZOOM_DRAG_LINE,
                    name: EVENT_TARGET_TYPE
                }).append(group);
                this._zoomDragTracker = renderer.rect(-options.sliderLength / 2, options.sliderLineEndOffset - options.sliderWidth / 2, options.sliderLength, options.sliderWidth).data(dataKey, {
                    index: COMMAND_ZOOM_DRAG,
                    name: EVENT_TARGET_TYPE
                }).append(group)
            },
            resize: function(size) {
                if (this._isActive) {
                    this._root.attr({
                        visibility: null !== size ? null : "hidden"
                    })
                }
            },
            getLayoutOptions: function() {
                return this._isActive ? this._layoutOptions : null
            },
            locate: function(x, y) {
                this._root.attr({
                    translateX: x + this._margin + OFFSET_X,
                    translateY: y + this._margin + OFFSET_Y
                })
            },
            _update: function() {
                var that = this;
                that._isActive = that._isEnabled && that._flags && that._params.projection.isInvertible();
                if (that._isActive) {
                    that._root.linkAppend()
                } else {
                    that._root.linkRemove()
                }
                that._processEnd();
                that.updateLayout()
            },
            setInteraction: function(interaction) {
                var that = this;
                if (_parseScalar(interaction.centeringEnabled, true)) {
                    that._flags |= FLAG_CENTERING
                } else {
                    that._flags &= ~FLAG_CENTERING
                }
                if (_parseScalar(interaction.zoomingEnabled, true)) {
                    that._flags |= FLAG_ZOOMING
                } else {
                    that._flags &= ~FLAG_ZOOMING
                }
                that._update()
            },
            setOptions: function(options) {
                var that = this;
                that._isEnabled = !!_parseScalar(options.enabled, true);
                that._margin = options.margin || 0;
                that._layoutOptions = {
                    width: 2 * that._margin + TOTAL_WIDTH,
                    height: 2 * that._margin + TOTAL_HEIGHT,
                    horizontalAlignment: parseHorizontalAlignment(options.horizontalAlignment, "left"),
                    verticalAlignment: parseVerticalAlignment(options.verticalAlignment, "top")
                };
                that._buttonsGroup.attr({
                    "stroke-width": options.borderWidth,
                    stroke: options.borderColor,
                    fill: options.color,
                    "fill-opacity": options.opacity
                });
                that._update()
            },
            _adjustZoom: function(zoom) {
                var transform, y, that = this,
                    start = SIZE_OPTIONS.sliderLineStartOffset,
                    end = SIZE_OPTIONS.sliderLineEndOffset,
                    h = SIZE_OPTIONS.sliderWidth;
                that._zoomFactor = _max(_min(_round(zoom), that._zoomPartition), 0);
                transform = {
                    translateY: -_round(that._zoomFactor * that._sliderUnitLength)
                };
                y = end - h / 2 + transform.translateY;
                that._zoomLine.attr({
                    points: [
                        [0, start, 0, _max(start, y)],
                        [0, _min(end, y + h), 0, end]
                    ]
                });
                that._zoomDrag.attr(transform);
                that._zoomDragTracker.attr(transform)
            },
            _applyZoom: function() {
                this._callbacks.zoom(this._zoomFactor)
            },
            _processStart: function(command, arg) {
                var commandType;
                if (this._isActive) {
                    commandType = COMMAND_TO_TYPE_MAP[command];
                    this._command = commandType && commandType.flags & this._flags ? new commandType(this, command, arg) : null
                }
            },
            _processMove: function(command, arg) {
                this._command && this._command.update(command, arg)
            },
            _processEnd: function() {
                this._command && this._command.finish();
                this._command = null
            }
        };

        function disposeCommand(command) {
            delete command._owner;
            command.update = function() {};
            command.finish = function() {}
        }

        function ResetCommand(owner, command) {
            this._owner = owner;
            this._command = command
        }
        ResetCommand.flags = FLAG_CENTERING | FLAG_ZOOMING;
        ResetCommand.prototype.update = function(command) {
            command !== this._command && disposeCommand(this)
        };
        ResetCommand.prototype.finish = function() {
            var flags = this._owner._flags;
            this._owner._callbacks.reset(!!(flags & FLAG_CENTERING), !!(flags & FLAG_ZOOMING));
            disposeCommand(this)
        };

        function MoveCommand(owner, command, arg) {
            this._command = command;
            var timeout = null,
                interval = 100,
                dx = 0,
                dy = 0;
            switch (this._command) {
                case COMMAND_MOVE_UP:
                    dy = -10;
                    break;
                case COMMAND_MOVE_RIGHT:
                    dx = 10;
                    break;
                case COMMAND_MOVE_DOWN:
                    dy = 10;
                    break;
                case COMMAND_MOVE_LEFT:
                    dx = -10
            }

            function callback() {
                owner._callbacks.move([dx, dy]);
                timeout = setTimeout(callback, interval)
            }
            this._stop = function() {
                clearTimeout(timeout);
                owner._callbacks.endMove();
                this._stop = owner = null;
                return this
            };
            arg = null;
            owner._callbacks.beginMove();
            callback()
        }
        MoveCommand.flags = FLAG_CENTERING;
        MoveCommand.prototype.update = function(command) {
            this._command !== command && this.finish()
        };
        MoveCommand.prototype.finish = function() {
            disposeCommand(this._stop())
        };

        function ZoomCommand(owner, command) {
            this._owner = owner;
            this._command = command;
            var timeout = null,
                interval = 150,
                dzoom = this._command === COMMAND_ZOOM_IN ? 1 : -1;

            function callback() {
                owner._adjustZoom(owner._zoomFactor + dzoom);
                timeout = setTimeout(callback, interval)
            }
            this._stop = function() {
                clearTimeout(timeout);
                this._stop = owner = null;
                return this
            };
            callback()
        }
        ZoomCommand.flags = FLAG_ZOOMING;
        ZoomCommand.prototype.update = function(command) {
            this._command !== command && this.finish()
        };
        ZoomCommand.prototype.finish = function() {
            this._owner._applyZoom();
            disposeCommand(this._stop())
        };

        function ZoomDragCommand(owner, command, arg) {
            this._owner = owner;
            this._zoomFactor = owner._zoomFactor;
            this._pos = arg.y
        }
        ZoomDragCommand.flags = FLAG_ZOOMING;
        ZoomDragCommand.prototype.update = function(command, arg) {
            var owner = this._owner;
            owner._adjustZoom(this._zoomFactor + owner._zoomPartition * (this._pos - arg.y) / owner._sliderLineLength)
        };
        ZoomDragCommand.prototype.finish = function() {
            this._owner._applyZoom();
            disposeCommand(this)
        };
        exports.ControlBar = ControlBar;
        var COMMAND_TO_TYPE_MAP__ORIGINAL = COMMAND_TO_TYPE_MAP;
        exports._TESTS_stubCommandToTypeMap = function(map) {
            COMMAND_TO_TYPE_MAP = map
        };
        exports._TESTS_restoreCommandToTypeMap = function() {
            COMMAND_TO_TYPE_MAP = COMMAND_TO_TYPE_MAP__ORIGINAL
        }
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/vector_map/gesture_handler.js ***!
      \***************************************************/
    function(module, exports) {
        var _ln = Math.log,
            _LN2 = Math.LN2;

        function GestureHandler(params) {
            var that = this;
            that._projection = params.projection;
            that._renderer = params.renderer;
            that._x = that._y = 0;
            that._subscribeToTracker(params.tracker)
        }
        GestureHandler.prototype = {
            constructor: GestureHandler,
            dispose: function() {
                this._offTracker();
                this._offTracker = null
            },
            _subscribeToTracker: function(tracker) {
                var that = this,
                    isActive = false;
                that._offTracker = tracker.on({
                    start: function(arg) {
                        isActive = "control-bar" !== arg.data.name;
                        if (isActive) {
                            that._processStart(arg)
                        }
                    },
                    move: function(arg) {
                        if (isActive) {
                            that._processMove(arg)
                        }
                    },
                    end: function(arg) {
                        if (isActive) {
                            that._processEnd()
                        }
                    },
                    zoom: function(arg) {
                        that._processZoom(arg)
                    }
                })
            },
            setInteraction: function(options) {
                this._processEnd();
                this._centeringEnabled = options.centeringEnabled;
                this._zoomingEnabled = options.zoomingEnabled
            },
            _processStart: function(arg) {
                if (this._centeringEnabled) {
                    this._x = arg.x;
                    this._y = arg.y;
                    this._projection.beginMoveCenter()
                }
            },
            _processMove: function(arg) {
                var that = this;
                if (that._centeringEnabled) {
                    that._renderer.root.attr({
                        cursor: "move"
                    });
                    that._projection.moveCenter([that._x - arg.x, that._y - arg.y]);
                    that._x = arg.x;
                    that._y = arg.y
                }
            },
            _processEnd: function() {
                if (this._centeringEnabled) {
                    this._renderer.root.attr({
                        cursor: "default"
                    });
                    this._projection.endMoveCenter()
                }
            },
            _processZoom: function(arg) {
                var delta, screenPosition, coords, that = this;
                if (that._zoomingEnabled) {
                    if (arg.delta) {
                        delta = arg.delta
                    } else {
                        if (arg.ratio) {
                            delta = _ln(arg.ratio) / _LN2
                        }
                    }
                    if (that._centeringEnabled) {
                        screenPosition = that._renderer.getRootOffset();
                        screenPosition = [arg.x - screenPosition.left, arg.y - screenPosition.top];
                        coords = that._projection.fromScreenPoint(screenPosition)
                    }
                    that._projection.changeScaledZoom(delta);
                    if (that._centeringEnabled) {
                        that._projection.setCenterByPoint(coords, screenPosition)
                    }
                }
            }
        };
        exports.GestureHandler = GestureHandler
    },
    /*!*******************************************!*\
      !*** ./Scripts/viz/vector_map/tracker.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _math = Math,
            _abs = _math.abs,
            _sqrt = _math.sqrt,
            _round = _math.round,
            eventEmitterModule = __webpack_require__( /*! ./event_emitter */ 551),
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            wheelEventName = __webpack_require__( /*! ../../events/core/wheel */ 77).name,
            _addNamespace = eventUtils.addNamespace,
            _parseScalar = __webpack_require__( /*! ../core/utils */ 442).parseScalar,
            _now = $.now,
            _NAME = "dxVectorMap",
            EVENTS = {};
        setupEvents();
        var EVENT_START = "start",
            EVENT_MOVE = "move",
            EVENT_END = "end",
            EVENT_ZOOM = "zoom",
            EVENT_HOVER_ON = "hover-on",
            EVENT_HOVER_OFF = "hover-off",
            EVENT_CLICK = "click",
            EVENT_FOCUS_ON = "focus-on",
            EVENT_FOCUS_MOVE = "focus-move",
            EVENT_FOCUS_OFF = "focus-off",
            CLICK_TIME_THRESHOLD = 500,
            CLICK_COORD_THRESHOLD_MOUSE = 5,
            CLICK_COORD_THRESHOLD_TOUCH = 20,
            DRAG_COORD_THRESHOLD_MOUSE = 5,
            DRAG_COORD_THRESHOLD_TOUCH = 10,
            FOCUS_ON_DELAY_MOUSE = 300,
            FOCUS_OFF_DELAY_MOUSE = 300,
            FOCUS_ON_DELAY_TOUCH = 300,
            FOCUS_OFF_DELAY_TOUCH = 400,
            FOCUS_COORD_THRESHOLD_MOUSE = 5,
            WHEEL_COOLDOWN = 50,
            WHEEL_DIRECTION_COOLDOWN = 300;

        function Tracker(parameters) {
            var that = this;
            that._root = parameters.root;
            that._createEventHandlers(parameters.dataKey);
            that._createProjectionHandlers(parameters.projection);
            that._initEvents();
            that._focus = new Focus(function(name, arg) {
                that._fire(name, arg)
            });
            that._attachHandlers()
        }
        Tracker.prototype = {
            constructor: Tracker,
            dispose: function() {
                var that = this;
                that._detachHandlers();
                that._disposeEvents();
                that._focus.dispose();
                that._root = that._focus = that._docHandlers = that._rootHandlers = null
            },
            _eventNames: [EVENT_START, EVENT_MOVE, EVENT_END, EVENT_ZOOM, EVENT_CLICK, EVENT_HOVER_ON, EVENT_HOVER_OFF, EVENT_FOCUS_ON, EVENT_FOCUS_OFF, EVENT_FOCUS_MOVE],
            _startClick: function(event, data) {
                if (!data) {
                    return
                }
                var coords = getEventCoords(event);
                this._clickState = {
                    x: coords.x,
                    y: coords.y,
                    threshold: isTouchEvent(event) ? CLICK_COORD_THRESHOLD_TOUCH : CLICK_COORD_THRESHOLD_MOUSE,
                    time: _now()
                }
            },
            _endClick: function(event, data) {
                var threshold, coords, state = this._clickState;
                if (!state) {
                    return
                }
                if (_now() - state.time <= CLICK_TIME_THRESHOLD) {
                    threshold = state.threshold;
                    coords = getEventCoords(event);
                    if (_abs(coords.x - state.x) <= threshold && _abs(coords.y - state.y) <= threshold) {
                        this._fire(EVENT_CLICK, {
                            data: data,
                            x: coords.x,
                            y: coords.y,
                            $event: event
                        })
                    }
                }
                this._clickState = null
            },
            _startDrag: function(event, data) {
                if (!data) {
                    return
                }
                var coords = getEventCoords(event),
                    state = this._dragState = {
                        x: coords.x,
                        y: coords.y,
                        data: data
                    };
                this._fire(EVENT_START, {
                    x: state.x,
                    y: state.y,
                    data: state.data
                })
            },
            _moveDrag: function(event, data) {
                var coords, threshold, state = this._dragState;
                if (!state) {
                    return
                }
                coords = getEventCoords(event);
                threshold = isTouchEvent(event) ? DRAG_COORD_THRESHOLD_TOUCH : DRAG_COORD_THRESHOLD_MOUSE;
                if (state.active || _abs(coords.x - state.x) > threshold || _abs(coords.y - state.y) > threshold) {
                    state.x = coords.x;
                    state.y = coords.y;
                    state.active = true;
                    state.data = data || {};
                    this._fire(EVENT_MOVE, {
                        x: state.x,
                        y: state.y,
                        data: state.data
                    })
                }
            },
            _endDrag: function() {
                var state = this._dragState;
                if (!state) {
                    return
                }
                this._dragState = null;
                this._fire(EVENT_END, {
                    x: state.x,
                    y: state.y,
                    data: state.data
                })
            },
            _wheelZoom: function(event, data) {
                if (!data) {
                    return
                }
                var delta, coords, that = this,
                    lock = that._wheelLock,
                    time = _now();
                if (time - lock.time <= WHEEL_COOLDOWN) {
                    return
                }
                if (time - lock.dirTime > WHEEL_DIRECTION_COOLDOWN) {
                    lock.dir = 0
                }
                delta = adjustWheelDelta(event.delta / 120 || 0, lock);
                if (0 === delta) {
                    return
                }
                coords = getEventCoords(event);
                that._fire(EVENT_ZOOM, {
                    delta: delta,
                    x: coords.x,
                    y: coords.y
                });
                lock.time = lock.dirTime = time
            },
            _startZoom: function(event, data) {
                if (!isTouchEvent(event) || !data) {
                    return
                }
                var coords, pointer2, state = this._zoomState = this._zoomState || {};
                if (state.pointer1 && state.pointer2) {
                    return
                }
                if (void 0 === state.pointer1) {
                    state.pointer1 = getPointerId(event) || 0;
                    coords = getMultitouchEventCoords(event, state.pointer1);
                    state.x1 = state.x1_0 = coords.x;
                    state.y1 = state.y1_0 = coords.y
                }
                if (void 0 === state.pointer2) {
                    pointer2 = getPointerId(event) || 1;
                    if (pointer2 !== state.pointer1) {
                        coords = getMultitouchEventCoords(event, pointer2);
                        if (coords) {
                            state.x2 = state.x2_0 = coords.x;
                            state.y2 = state.y2_0 = coords.y;
                            state.pointer2 = pointer2;
                            state.ready = true;
                            this._endDrag()
                        }
                    }
                }
            },
            _moveZoom: function(event) {
                var coords, state = this._zoomState;
                if (!state || !isTouchEvent(event)) {
                    return
                }
                if (void 0 !== state.pointer1) {
                    coords = getMultitouchEventCoords(event, state.pointer1);
                    if (coords) {
                        state.x1 = coords.x;
                        state.y1 = coords.y
                    }
                }
                if (void 0 !== state.pointer2) {
                    coords = getMultitouchEventCoords(event, state.pointer2);
                    if (coords) {
                        state.x2 = coords.x;
                        state.y2 = coords.y
                    }
                }
            },
            _endZoom: function(event) {
                var startDistance, currentDistance, state = this._zoomState;
                if (!state || !isTouchEvent(event)) {
                    return
                }
                if (state.ready) {
                    startDistance = getDistance(state.x1_0, state.y1_0, state.x2_0, state.y2_0);
                    currentDistance = getDistance(state.x1, state.y1, state.x2, state.y2);
                    this._fire(EVENT_ZOOM, {
                        ratio: currentDistance / startDistance,
                        x: (state.x1_0 + state.x2_0) / 2,
                        y: (state.y1_0 + state.y2_0) / 2
                    })
                }
                this._zoomState = null
            },
            _startHover: function(event, data) {
                this._doHover(event, data, true)
            },
            _moveHover: function(event, data) {
                this._doHover(event, data, false)
            },
            _doHover: function(event, data, isTouch) {
                var that = this;
                if (that._dragState && that._dragState.active || that._zoomState && that._zoomState.ready) {
                    that._cancelHover();
                    return
                }
                if (isTouchEvent(event) !== isTouch || that._hoverTarget === event.target || that._hoverState && that._hoverState.data === data) {
                    return
                }
                that._cancelHover();
                if (data) {
                    that._hoverState = {
                        data: data
                    };
                    that._fire(EVENT_HOVER_ON, {
                        data: data
                    })
                }
                that._hoverTarget = event.target
            },
            _cancelHover: function() {
                var state = this._hoverState;
                this._hoverState = this._hoverTarget = null;
                if (state) {
                    this._fire(EVENT_HOVER_OFF, {
                        data: state.data
                    })
                }
            },
            _startFocus: function(event, data) {
                this._doFocus(event, data, true)
            },
            _moveFocus: function(event, data) {
                this._doFocus(event, data, false)
            },
            _doFocus: function(event, data, isTouch) {
                var that = this;
                if (that._dragState && that._dragState.active || that._zoomState && that._zoomState.ready) {
                    that._cancelFocus();
                    return
                }
                if (isTouchEvent(event) !== isTouch) {
                    return
                }
                that._focus.turnOff(isTouch ? FOCUS_OFF_DELAY_TOUCH : FOCUS_OFF_DELAY_MOUSE);
                data && that._focus.turnOn(data, getEventCoords(event), isTouch ? FOCUS_ON_DELAY_TOUCH : FOCUS_ON_DELAY_MOUSE, isTouch)
            },
            _endFocus: function(event) {
                if (!isTouchEvent(event)) {
                    return
                }
                this._focus.cancelOn()
            },
            _cancelFocus: function() {
                this._focus.cancel()
            },
            _createEventHandlers: function(DATA_KEY) {
                var that = this;
                that._docHandlers = {};
                that._rootHandlers = {};
                that._rootHandlers[EVENTS.start] = that._docHandlers[EVENTS.start] = function(event) {
                    var isTouch = isTouchEvent(event),
                        data = getData(event);
                    if (isTouch && !that._isTouchEnabled) {
                        return
                    }
                    if (data) {
                        event.preventDefault();
                        event.stopPropagation()
                    }
                    that._startClick(event, data);
                    that._startDrag(event, data);
                    that._startZoom(event, data);
                    that._startHover(event, data);
                    that._startFocus(event, data)
                };
                that._docHandlers[EVENTS.move] = function(event) {
                    var isTouch = isTouchEvent(event),
                        data = getData(event);
                    if (isTouch && !that._isTouchEnabled) {
                        return
                    }
                    that._moveDrag(event, data);
                    that._moveZoom(event, data);
                    that._moveHover(event, data);
                    that._moveFocus(event, data)
                };
                that._docHandlers[EVENTS.end] = function(event) {
                    var isTouch = isTouchEvent(event),
                        data = getData(event);
                    if (isTouch && !that._isTouchEnabled) {
                        return
                    }
                    that._endClick(event, data);
                    that._endDrag(event, data);
                    that._endZoom(event, data);
                    that._endFocus(event, data)
                };
                that._rootHandlers[EVENTS.wheel] = function(event) {
                    that._cancelFocus();
                    if (!that._isWheelEnabled) {
                        return
                    }
                    var data = getData(event);
                    if (data) {
                        event.preventDefault();
                        event.stopPropagation();
                        that._wheelZoom(event, data)
                    }
                };
                that._wheelLock = {
                    dir: 0
                };

                function getData(event) {
                    var target = event.target;
                    return ("tspan" === target.tagName ? target.parentNode : target)[DATA_KEY]
                }
            },
            _createProjectionHandlers: function(projection) {
                var that = this;
                projection.on({
                    center: handler,
                    zoom: handler
                });

                function handler() {
                    that._cancelFocus()
                }
            },
            reset: function() {
                var that = this;
                that._clickState = null;
                that._endDrag();
                that._cancelHover();
                that._cancelFocus()
            },
            setOptions: function(options) {
                var that = this;
                that.reset();
                that._detachHandlers();
                that._isTouchEnabled = !!_parseScalar(options.touchEnabled, true);
                that._isWheelEnabled = !!_parseScalar(options.wheelEnabled, true);
                that._attachHandlers()
            },
            _detachHandlers: function() {
                var that = this;
                if (that._isTouchEnabled) {
                    that._root.css({
                        "touch-action": "",
                        "-ms-touch-action": "",
                        "-webkit-user-select": ""
                    }).off(_addNamespace("MSHoldVisual", _NAME)).off(_addNamespace("contextmenu", _NAME))
                }
                $(document).off(that._docHandlers);
                that._root.off(that._rootHandlers)
            },
            _attachHandlers: function() {
                var that = this;
                if (that._isTouchEnabled) {
                    that._root.css({
                        "touch-action": "none",
                        "-ms-touch-action": "none",
                        "-webkit-user-select": "none"
                    }).on(_addNamespace("MSHoldVisual", _NAME), function(event) {
                        event.preventDefault()
                    }).on(_addNamespace("contextmenu", _NAME), function(event) {
                        isTouchEvent(event) && event.preventDefault()
                    })
                }
                $(document).on(that._docHandlers);
                that._root.on(that._rootHandlers)
            }
        };
        var Focus = function(fire) {
            var _x, _y, that = this,
                _activeData = null,
                _data = null,
                _disabled = false,
                _onTimer = null,
                _offTimer = null;
            that.dispose = function() {
                clearTimeout(_onTimer);
                clearTimeout(_offTimer);
                that.turnOn = that.turnOff = that.cancel = that.cancelOn = that.dispose = that = fire = _activeData = _data = _onTimer = _offTimer = null
            };
            that.turnOn = function(data, coords, timeout, forceTimeout) {
                if (data === _data && _disabled) {
                    return
                }
                _disabled = false;
                _data = data;
                if (_activeData) {
                    _x = coords.x;
                    _y = coords.y;
                    clearTimeout(_onTimer);
                    _onTimer = setTimeout(function() {
                        _onTimer = null;
                        if (_data === _activeData) {
                            fire(EVENT_FOCUS_MOVE, {
                                data: _data,
                                x: _x,
                                y: _y
                            });
                            onCheck(true)
                        } else {
                            fire(EVENT_FOCUS_ON, {
                                data: _data,
                                x: _x,
                                y: _y,
                                done: onCheck
                            })
                        }
                    }, forceTimeout ? timeout : 0)
                } else {
                    if (!_onTimer || _abs(coords.x - _x) > FOCUS_COORD_THRESHOLD_MOUSE || _abs(coords.y - _y) > FOCUS_COORD_THRESHOLD_MOUSE || forceTimeout) {
                        _x = coords.x;
                        _y = coords.y;
                        clearTimeout(_onTimer);
                        _onTimer = setTimeout(function() {
                            _onTimer = null;
                            fire(EVENT_FOCUS_ON, {
                                data: _data,
                                x: _x,
                                y: _y,
                                done: onCheck
                            })
                        }, timeout)
                    }
                }

                function onCheck(result) {
                    _disabled = !result;
                    if (result) {
                        _activeData = _data;
                        clearTimeout(_offTimer);
                        _offTimer = null
                    }
                }
            };
            that.turnOff = function(timeout) {
                clearTimeout(_onTimer);
                _onTimer = null;
                _data = null;
                if (_activeData && !_disabled) {
                    _offTimer = _offTimer || setTimeout(function() {
                        _offTimer = null;
                        fire(EVENT_FOCUS_OFF, {
                            data: _activeData
                        });
                        _activeData = null
                    }, timeout)
                }
            };
            that.cancel = function() {
                clearTimeout(_onTimer);
                clearTimeout(_offTimer);
                if (_activeData) {
                    fire(EVENT_FOCUS_OFF, {
                        data: _activeData
                    })
                }
                _activeData = _data = _onTimer = _offTimer = null
            };
            that.cancelOn = function() {
                clearTimeout(_onTimer);
                _onTimer = null
            }
        };
        eventEmitterModule.makeEventEmitter(Tracker);
        exports.Tracker = Tracker;
        var originFocus = Focus;
        exports._DEBUG_forceEventMode = function(mode) {
            setupEvents(mode)
        };
        exports.Focus = Focus;
        exports._DEBUG_stubFocusType = function(focusType) {
            Focus = focusType
        };
        exports._DEBUG_restoreFocusType = function() {
            Focus = originFocus
        };

        function getDistance(x1, y1, x2, y2) {
            return _sqrt((x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2))
        }

        function isTouchEvent(event) {
            var type = event.originalEvent.type,
                pointerType = event.originalEvent.pointerType;
            return /^touch/.test(type) || /^MSPointer/.test(type) && 4 !== pointerType || /^pointer/.test(type) && "mouse" !== pointerType
        }

        function selectItem(flags, items) {
            var item, i = 0,
                ii = flags.length;
            for (; i < ii; ++i) {
                if (flags[i]) {
                    item = items[i];
                    break
                }
            }
            return _addNamespace(item || items[i], _NAME)
        }

        function setupEvents() {
            var flags = [navigator.pointerEnabled, navigator.msPointerEnabled, "ontouchstart" in window];
            if (arguments.length) {
                flags = ["pointer" === arguments[0], "MSPointer" === arguments[0], "touch" === arguments[0]]
            }
            EVENTS = {
                start: selectItem(flags, ["pointerdown", "MSPointerDown", "touchstart mousedown", "mousedown"]),
                move: selectItem(flags, ["pointermove", "MSPointerMove", "touchmove mousemove", "mousemove"]),
                end: selectItem(flags, ["pointerup", "MSPointerUp", "touchend mouseup", "mouseup"]),
                wheel: _addNamespace(wheelEventName, _NAME)
            }
        }

        function getEventCoords(event) {
            var originalEvent = event.originalEvent,
                touch = originalEvent.touches && originalEvent.touches[0] || {};
            return {
                x: touch.pageX || originalEvent.pageX || event.pageX,
                y: touch.pageY || originalEvent.pageY || event.pageY
            }
        }

        function getPointerId(event) {
            return event.originalEvent.pointerId
        }

        function getMultitouchEventCoords(event, pointerId) {
            var originalEvent = event.originalEvent;
            if (void 0 !== originalEvent.pointerId) {
                originalEvent = originalEvent.pointerId === pointerId ? originalEvent : null
            } else {
                originalEvent = originalEvent.touches[pointerId]
            }
            return originalEvent ? {
                x: originalEvent.pageX || event.pageX,
                y: originalEvent.pageY || event.pageY
            } : null
        }

        function adjustWheelDelta(delta, lock) {
            if (0 === delta) {
                return 0
            }
            var _delta = _abs(delta),
                sign = _round(delta / _delta);
            if (lock.dir && sign !== lock.dir) {
                return 0
            }
            lock.dir = sign;
            if (_delta < .1) {
                _delta = 0
            } else {
                if (_delta < 1) {
                    _delta = 1
                } else {
                    if (_delta > 4) {
                        _delta = 4
                    } else {
                        _delta = _round(_delta)
                    }
                }
            }
            return sign * _delta
        }
    },
    /*!*************************************************!*\
      !*** ./Scripts/viz/vector_map/theme_manager.js ***!
      \*************************************************/
    function(module, exports, __webpack_require__) {
        var BaseThemeManager = __webpack_require__( /*! ../core/base_theme_manager */ 485).BaseThemeManager;
        exports.ThemeManager = BaseThemeManager.inherit({
            _themeSection: "map",
            _fontFields: ["layer:area.label.font", "layer:marker:dot.label.font", "layer:marker:bubble.label.font", "layer:marker:pie.label.font", "layer:marker:image.label.font", "tooltip.font", "legend.font", "title.font", "title.subtitle.font", "loadingIndicator.font", "export.font"]
        })
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/vector_map/data_exchanger.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var _Callbacks = __webpack_require__( /*! jquery */ 9).Callbacks;

        function DataExchanger() {
            this._store = {}
        }
        DataExchanger.prototype = {
            constructor: DataExchanger,
            dispose: function() {
                this._store = null;
                return this
            },
            _get: function(category, name) {
                var store = this._store[category] || (this._store[category] = {});
                return store[name] || (store[name] = {
                    callbacks: _Callbacks()
                })
            },
            set: function(category, name, data) {
                var item = this._get(category, name);
                item.data = data;
                item.callbacks.fire(data);
                return this
            },
            bind: function(category, name, callback) {
                var item = this._get(category, name);
                item.callbacks.add(callback);
                item.data && callback(item.data);
                return this
            },
            unbind: function(category, name, callback) {
                var item = this._get(category, name);
                item.callbacks.remove(callback);
                return this
            }
        };
        exports.DataExchanger = DataExchanger
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/vector_map/legend.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _extend = $.extend,
            _each = $.each,
            legendModule = __webpack_require__( /*! ../components/legend */ 456),
            _BaseLegend = legendModule.Legend;
        var sourceMap = {
            areacolorgroups: {
                category: "areas",
                name: "color"
            },
            markercolorgroups: {
                category: "markers",
                name: "color"
            },
            markersizegroups: {
                category: "markers",
                name: "size"
            }
        };
        var unknownSource = {
            category: "UNKNOWN",
            name: "UNKNOWN"
        };

        function parseSource(source) {
            var ret;
            if ("string" === typeof source) {
                ret = sourceMap[source.toLowerCase()] || unknownSource
            } else {
                ret = {
                    category: source.layer,
                    name: source.grouping
                }
            }
            return ret
        }

        function Legend(parameters) {
            var that = this;
            that._params = parameters;
            that._root = parameters.renderer.g().attr({
                "class": "dxm-legend"
            }).linkOn(parameters.container, {
                name: "legend",
                after: "legend-base"
            }).linkAppend();
            parameters.layoutControl.addItem(that);
            _BaseLegend.call(that, {
                renderer: parameters.renderer,
                group: that._root,
                backgroundClass: null,
                itemsGroupClass: null,
                textField: "text",
                getFormatObject: function(data) {
                    return data
                }
            });
            that._onDataChanged = function(data) {
                that._updateData(data)
            }
        }

        function buildData(partition, values, field) {
            var i, item, ii = values.length,
                list = [];
            for (i = 0; i < ii; ++i) {
                list[i] = item = {
                    start: partition[i],
                    end: partition[i + 1],
                    index: i
                };
                item[field] = values[i];
                item.states = {
                    normal: {
                        fill: item.color
                    }
                }
            }
            return list
        }
        Legend.prototype = _extend(__webpack_require__( /*! ../../core/utils/object */ 37).clone(_BaseLegend.prototype), {
            constructor: Legend,
            dispose: function() {
                var that = this;
                that._params.layoutControl.removeItem(that);
                that._unbindData();
                that._root.linkRemove().linkOff();
                that._params = that._root = that._onDataChanged = null;
                return _BaseLegend.prototype.dispose.apply(that, arguments)
            },
            resize: function(size) {
                this._params.notifyDirty();
                if (null === size) {
                    this.erase()
                } else {
                    this.draw(size.width, size.height)
                }
                this._params.notifyReady()
            },
            locate: _BaseLegend.prototype.shift,
            _updateData: function(data) {
                this.update(data ? buildData(data.partition, data.values, this._dataName) : [], this._options);
                this.updateLayout()
            },
            _unbindData: function() {
                if (this._dataCategory) {
                    this._params.dataExchanger.unbind(this._dataCategory, this._dataName, this._onDataChanged)
                }
            },
            _bindData: function(arg) {
                this._params.dataExchanger.bind(this._dataCategory = arg.category, this._dataName = arg.name, this._onDataChanged)
            },
            setOptions: function(options) {
                var that = this;
                that.update(that._data, options);
                that._unbindData();
                that._bindData(options.source && parseSource(options.source) || unknownSource);
                that.updateLayout();
                return that
            }
        });

        function LegendsControl(parameters) {
            this._params = parameters;
            this._items = [];
            parameters.container.virtualLink("legend-base")
        }
        LegendsControl.prototype = {
            constructor: LegendsControl,
            dispose: function() {
                _each(this._items, function(_, item) {
                    item.dispose()
                });
                this._params = this._items = null
            },
            setOptions: function(options) {
                var i, optionList = options && options.length ? options : [],
                    items = this._items,
                    ii = optionList.length,
                    params = this._params,
                    theme = params.themeManager.theme("legend");
                for (i = items.length; i < ii; ++i) {
                    items[i] = new Legend(params)
                }
                for (i = items.length - 1; i >= ii; --i) {
                    items[i].dispose();
                    items.splice(i, 1)
                }
                params.layoutControl.suspend();
                for (i = 0; i < ii; ++i) {
                    items[i].setOptions(_extend(true, {}, theme, optionList[i]))
                }
                params.layoutControl.resume()
            }
        };
        exports.LegendsControl = LegendsControl;
        var originalLegend = Legend;
        exports._TESTS_Legend = Legend;
        exports._TESTS_stubLegendType = function(stub) {
            Legend = stub
        };
        exports._TESTS_restoreLegendType = function() {
            Legend = originalLegend
        }
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/vector_map/layout.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _round = Math.round,
            _min = Math.min,
            _max = Math.max,
            _each = $.each,
            _inArray = $.inArray,
            horizontalAlignmentMap = {
                left: 0,
                center: 1,
                right: 2
            },
            verticalAlignmentMap = {
                top: 0,
                bottom: 1
            };

        function getCellIndex(options) {
            return 3 * verticalAlignmentMap[options.verticalAlignment] + horizontalAlignmentMap[options.horizontalAlignment]
        }

        function createCells(canvas, items) {
            var hstep = (canvas.right - canvas.left) / 3,
                vstep = (canvas.bottom - canvas.top) / 2,
                h1 = canvas.left,
                h2 = _round(h1 + hstep),
                h3 = _round(h1 + hstep + hstep),
                h4 = canvas.right,
                v1 = canvas.top,
                v2 = _round(v1 + vstep),
                v3 = canvas.bottom,
                cells = [{
                    rect: [h1, v1, h2, v2]
                }, {
                    rect: [h2, v1, h3, v2],
                    center: true
                }, {
                    rect: [h3, v1, h4, v2],
                    horInv: true
                }, {
                    rect: [h1, v2, h2, v3],
                    verInv: true
                }, {
                    rect: [h2, v2, h3, v3],
                    center: true,
                    verInv: true
                }, {
                    rect: [h3, v2, h4, v3],
                    horInv: true,
                    verInv: true
                }],
                itemsList = [
                    [],
                    [],
                    [],
                    [],
                    [],
                    []
                ];
            _each(items, function(_, item) {
                var options = item.getLayoutOptions();
                if (options) {
                    itemsList[getCellIndex(options)].push({
                        item: item,
                        width: options.width,
                        height: options.height
                    })
                }
            });
            _each(cells, function(i, cell) {
                if (itemsList[i].length) {
                    cell.items = itemsList[i]
                } else {
                    if (cell.center) {
                        cell.rect[0] = cell.rect[2] = (cell.rect[0] + cell.rect[2]) / 2
                    } else {
                        cell.rect[cell.horInv ? 0 : 2] = cell.rect[cell.horInv ? 2 : 0]
                    }
                    cell.rect[cell.verInv ? 1 : 3] = cell.rect[cell.verInv ? 3 : 1]
                }
            });
            return cells
        }

        function adjustCellSizes(cells) {
            _each([0, 1, 2, 3, 4, 5], function(_, index) {
                var cell = cells[index],
                    otherCell = cells[(index + 3) % 6];
                if (cell.items) {
                    if (!otherCell.items) {
                        cell.rect[1] = _min(cell.rect[1], otherCell.rect[3]);
                        cell.rect[3] = _max(cell.rect[3], otherCell.rect[1])
                    }
                }
            });
            _each([1, 4], function(_, index) {
                var size1, size2, cell = cells[index],
                    otherCell1 = cells[index - 1],
                    otherCell2 = cells[index + 1];
                if (cell.items) {
                    if (!otherCell1.items && !otherCell2.items) {
                        size1 = cell.rect[0] - otherCell1.rect[2];
                        size2 = otherCell2.rect[0] - cell.rect[2];
                        if (size1 > size2) {
                            if (size1 / size2 >= 2) {
                                cell.rect[0] -= size1;
                                cell.right = true
                            } else {
                                cell.rect[0] -= size2;
                                cell.rect[2] += size2
                            }
                        } else {
                            if (size2 / size1 >= 2) {
                                cell.rect[2] += size2;
                                cell.center = null
                            } else {
                                cell.rect[0] -= size1;
                                cell.rect[2] += size1
                            }
                        }
                    }
                } else {
                    if (otherCell1.items) {
                        otherCell1.rect[2] = (cell.rect[0] + cell.rect[2]) / 2
                    }
                    if (otherCell2.items) {
                        otherCell2.rect[0] = (cell.rect[0] + cell.rect[2]) / 2
                    }
                }
            })
        }

        function adjustCellsAndApplyLayout(cells, forceMode) {
            var hasHiddenItems = false;
            adjustCellSizes(cells);
            _each(cells, function(_, cell) {
                if (cell.items) {
                    hasHiddenItems = applyCellLayout(cell, forceMode) || hasHiddenItems
                }
            });
            return hasHiddenItems
        }

        function applyCellLayout(cell, forceMode) {
            var cellRect = cell.rect,
                cellWidth = cellRect[2] - cellRect[0],
                cellHeight = cellRect[3] - cellRect[1],
                xoffset = 0,
                yoffset = 0,
                currentHeight = 0,
                totalL = cellRect[2],
                totalT = cellRect[3],
                totalR = cellRect[0],
                totalB = cellRect[1],
                moves = [],
                hasHiddenItems = false;
            _each(cell.items, function(_, item) {
                if (item.width > cellWidth || item.height > cellHeight) {
                    moves.push(null);
                    hasHiddenItems = true;
                    return forceMode || false
                }
                if (xoffset + item.width > cellWidth) {
                    yoffset += currentHeight;
                    xoffset = currentHeight = 0
                }
                if (yoffset + item.height > cellHeight) {
                    moves.push(null);
                    hasHiddenItems = true;
                    return forceMode || false
                }
                currentHeight = _max(currentHeight, item.height);
                var dx = cell.horInv ? cellRect[2] - item.width - xoffset : cellRect[0] + xoffset,
                    dy = cell.verInv ? cellRect[3] - item.height - yoffset : cellRect[1] + yoffset;
                xoffset += item.width;
                totalL = _min(totalL, dx);
                totalT = _min(totalT, dy);
                totalR = _max(totalR, dx + item.width);
                totalB = _max(totalB, dy + item.height);
                moves.push([dx, dy])
            });
            if (forceMode || !hasHiddenItems) {
                xoffset = 0;
                if (cell.right) {
                    xoffset = cellRect[2] - cellRect[0] - totalR + totalL
                } else {
                    if (cell.center) {
                        xoffset = _round((cellRect[2] - cellRect[0] - totalR + totalL) / 2)
                    }
                }
                _each(cell.items, function(i, item) {
                    var move = moves[i];
                    if (move) {
                        item.item.locate(move[0] + xoffset, move[1])
                    } else {
                        item.item.resize(null)
                    }
                });
                cell.rect = [totalL, totalT, totalR, totalB];
                cell.items = null
            }
            return hasHiddenItems
        }

        function applyLayout(canvas, items) {
            var cells = createCells(canvas, items);
            if (adjustCellsAndApplyLayout(cells)) {
                adjustCellsAndApplyLayout(cells, true)
            }
        }

        function LayoutControl() {
            var that = this;
            that._items = [];
            that._suspended = 0;
            that._updateLayout = function() {
                that._update()
            }
        }
        LayoutControl.prototype = {
            constructor: LayoutControl,
            dispose: function() {
                this._items = this._updateLayout = null
            },
            setSize: function(canvas) {
                this._canvas = canvas;
                this._update()
            },
            suspend: function() {
                ++this._suspended
            },
            resume: function() {
                if (0 === --this._suspended) {
                    this._update()
                }
            },
            addItem: function(item) {
                this._items.push(item);
                item.updateLayout = this._updateLayout
            },
            removeItem: function(item) {
                this._items.splice(_inArray(item, this._items), 1);
                item.updateLayout = null
            },
            _update: function() {
                var canvas;
                if (0 === this._suspended) {
                    canvas = this._canvas;
                    _each(this._items, function(_, item) {
                        item.resize(canvas)
                    });
                    applyLayout({
                        left: canvas.left,
                        top: canvas.top,
                        right: canvas.width + canvas.left,
                        bottom: canvas.height + canvas.top
                    }, this._items)
                }
            }
        };
        exports.LayoutControl = LayoutControl
    },
    /*!*********************************************!*\
      !*** ./Scripts/viz/vector_map/map_layer.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            _Number = Number,
            _String = String,
            _abs = Math.abs,
            _round = Math.round,
            _min = Math.min,
            _max = Math.max,
            _sqrt = Math.sqrt,
            _utils = __webpack_require__( /*! ../../core/utils/common */ 14),
            dataSourceModule = __webpack_require__( /*! ../core/data_source */ 493),
            _isFunction = _utils.isFunction,
            _isArray = _utils.isArray,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _parseScalar = vizUtils.parseScalar,
            _patchFontOptions = vizUtils.patchFontOptions,
            _normalizeEnum = vizUtils.normalizeEnum,
            _noop = $.noop,
            _extend = $.extend,
            _each = $.each,
            _concat = Array.prototype.concat,
            TYPE_AREA = "area",
            TYPE_LINE = "line",
            TYPE_MARKER = "marker",
            STATE_DEFAULT = 0,
            STATE_HOVERED = 1,
            STATE_SELECTED = 2,
            STATE_TO_INDEX = [0, 1, 2, 2],
            TOLERANCE = 1,
            SELECTIONS = {
                none: null,
                single: -1,
                multiple: NaN
            };

        function getSelection(selectionMode) {
            var selection = _normalizeEnum(selectionMode);
            selection = selection in SELECTIONS ? SELECTIONS[selection] : SELECTIONS.single;
            if (null !== selection) {
                selection = {
                    state: {},
                    single: selection
                }
            }
            return selection
        }

        function EmptySource() {}
        EmptySource.prototype.count = function() {
            return 0
        };

        function ArraySource(raw) {
            this.raw = raw
        }
        ArraySource.prototype = {
            constructor: ArraySource,
            count: function() {
                return this.raw.length
            },
            item: function(index) {
                return this.raw[index]
            },
            geometry: function(item) {
                return {
                    coordinates: item.coordinates
                }
            },
            attributes: function(item) {
                return item.attributes
            }
        };

        function GeoJsonSource(raw) {
            this.raw = raw
        }
        GeoJsonSource.prototype = {
            constructor: GeoJsonSource,
            count: function() {
                return this.raw.features.length
            },
            item: function(index) {
                return this.raw.features[index]
            },
            geometry: function(item) {
                return item.geometry
            },
            attributes: function(item) {
                return item.properties
            }
        };

        function isGeoJsonObject(obj) {
            return _isArray(obj.features)
        }

        function unwrapFromDataSource(source) {
            var sourceType;
            if (source) {
                if (isGeoJsonObject(source)) {
                    sourceType = GeoJsonSource
                } else {
                    if (1 === source.length && source[0] && isGeoJsonObject(source[0])) {
                        sourceType = GeoJsonSource;
                        source = source[0]
                    } else {
                        if (_isArray(source)) {
                            sourceType = ArraySource
                        }
                    }
                }
            }
            sourceType = sourceType || EmptySource;
            return new sourceType(source)
        }

        function wrapToDataSource(option) {
            return option ? isGeoJsonObject(option) ? [option] : option : []
        }

        function customizeHandles(proxies, callback, widget) {
            callback.call(widget, proxies)
        }

        function customizeHandles_deprecated(proxies, callback) {
            var i, proxy, settings, ii = proxies.length;
            for (i = 0; i < ii; ++i) {
                proxy = proxies[i];
                settings = callback.call(proxy, proxy) || {};
                proxy.applySettings(settings);
                if (settings.isSelected) {
                    proxy.selected(true)
                }
            }
        }

        function patchProxies(handles, name, data) {
            var i, dataItem, type = {
                    areas: "area",
                    markers: "marker"
                }[name],
                ii = handles.length;
            for (i = 0; i < ii; ++i) {
                handles[i].proxy.type = type
            }
            if ("marker" === type) {
                for (i = 0; i < ii; ++i) {
                    dataItem = data.item(i);
                    _extend(handles[i].proxy, {
                        text: dataItem.text,
                        value: dataItem.value,
                        values: dataItem.values,
                        url: dataItem.url
                    })
                }
            }
        }

        function setAreaLabelVisibility(label) {
            label.text.attr({
                visibility: label.size[0] / label.spaceSize[0] < TOLERANCE && label.size[1] / label.spaceSize[1] < TOLERANCE ? null : "hidden"
            })
        }

        function setLineLabelVisibility(label) {
            label.text.attr({
                visibility: label.size[0] / label.spaceSize[0] < TOLERANCE || label.size[1] / label.spaceSize[1] < TOLERANCE ? null : "hidden"
            })
        }

        function getDataValue(proxy, dataField, deprecatedField) {
            return proxy.attribute(dataField) || proxy[deprecatedField]
        }
        var TYPE_TO_TYPE_MAP = {
            Point: TYPE_MARKER,
            MultiPoint: TYPE_LINE,
            LineString: TYPE_LINE,
            MultiLineString: TYPE_LINE,
            Polygon: TYPE_AREA,
            MultiPolygon: TYPE_AREA
        };

        function guessTypeByData(sample) {
            var type = TYPE_TO_TYPE_MAP[sample.type],
                coordinates = sample.coordinates;
            if (!type) {
                if ("number" === typeof coordinates[0]) {
                    type = TYPE_MARKER
                } else {
                    if ("number" === typeof coordinates[0][0]) {
                        type = TYPE_LINE
                    } else {
                        type = TYPE_AREA
                    }
                }
            }
            return type
        }
        var selectStrategy = function(options, data) {
            var sample, type = _normalizeEnum(options.type),
                elementType = _normalizeEnum(options.elementType),
                strategy = _extend({}, emptyStrategy);
            if (data.count() > 0) {
                sample = data.geometry(data.item(0));
                type = strategiesByType[type] ? type : guessTypeByData(sample);
                _extend(strategy, strategiesByType[type]);
                strategy.fullType = strategy.type = type;
                if (strategiesByGeometry[type]) {
                    _extend(strategy, strategiesByGeometry[type](sample))
                }
                if (strategiesByElementType[type]) {
                    elementType = strategiesByElementType[type][elementType] ? elementType : strategiesByElementType[type]._default;
                    _extend(strategy, strategiesByElementType[type][elementType]);
                    strategy.elementType = elementType;
                    strategy.fullType += ":" + elementType
                }
            }
            return strategy
        };

        function applyElementState(figure, styles, state, field) {
            figure[field].attr(styles[field][state])
        }
        var emptyStrategy = {
            setup: _noop,
            reset: _noop,
            arrange: _noop,
            updateGrouping: _noop
        };
        var strategiesByType = {};
        strategiesByType[TYPE_AREA] = {
            projectLabel: projectAreaLabel,
            transform: transformPointList,
            transformLabel: transformAreaLabel,
            draw: function(context, figure, data) {
                figure.root = context.renderer.path([], "area").data(context.dataKey, data)
            },
            refresh: _noop,
            getLabelOffset: function(label) {
                setAreaLabelVisibility(label);
                return [0, 0]
            },
            getStyles: function(settings) {
                var color = settings.color || null,
                    borderColor = settings.borderColor || null,
                    borderWidth = settings.borderWidth || null,
                    opacity = settings.opacity || null;
                return {
                    root: [{
                        "class": "dxm-area",
                        stroke: borderColor,
                        "stroke-width": borderWidth,
                        fill: color,
                        opacity: opacity
                    }, {
                        "class": "dxm-area dxm-area-hovered",
                        stroke: settings.hoveredBorderColor || borderColor,
                        "stroke-width": settings.hoveredBorderWidth || borderWidth,
                        fill: settings.hoveredColor || color,
                        opacity: settings.hoveredOpacity || opacity
                    }, {
                        "class": "dxm-area dxm-area-selected",
                        stroke: settings.selectedBorderColor || borderColor,
                        "stroke-width": settings.selectedBorderWidth || borderWidth,
                        fill: settings.selectedColor || color,
                        opacity: settings.selectedOpacity || opacity
                    }]
                }
            },
            setState: function(figure, styles, state) {
                applyElementState(figure, styles, state, "root")
            },
            hasLabelsGroup: true,
            updateGrouping: function(context) {
                groupByColor(context)
            }
        };
        strategiesByType[TYPE_LINE] = {
            projectLabel: projectLineLabel,
            transform: transformPointList,
            transformLabel: transformLineLabel,
            draw: function(context, figure, data) {
                figure.root = context.renderer.path([], "line").data(context.dataKey, data)
            },
            refresh: _noop,
            getLabelOffset: function(label) {
                setLineLabelVisibility(label);
                return [0, 0]
            },
            getStyles: function(settings) {
                var color = settings.color || settings.borderColor || null,
                    width = settings.borderWidth || null,
                    opacity = settings.opacity || null;
                return {
                    root: [{
                        "class": "dxm-line",
                        stroke: color,
                        "stroke-width": width,
                        opacity: opacity
                    }, {
                        "class": "dxm-line dxm-line-hovered",
                        stroke: settings.hoveredColor || settings.hoveredBorderColor || color,
                        "stroke-width": settings.hoveredBorderWidth || width,
                        opacity: settings.hoveredOpacity || opacity
                    }, {
                        "class": "dxm-line dxm-line-selected",
                        stroke: settings.selectedColor || settings.selectedBorderColor || color,
                        "stroke-width": settings.selectedBorderWidth || width,
                        opacity: settings.selectedOpacity || opacity
                    }]
                }
            },
            setState: function(figure, styles, state) {
                applyElementState(figure, styles, state, "root")
            },
            hasLabelsGroup: true,
            updateGrouping: function(context) {
                groupByColor(context)
            }
        };
        strategiesByType[TYPE_MARKER] = {
            project: projectPoint,
            transform: transformPoint,
            draw: function(context, figure, data) {
                figure.root = context.renderer.g();
                this._draw(context, figure, data)
            },
            refresh: _noop,
            hasLabelsGroup: false,
            getLabelOffset: function(label, settings) {
                return [_round((label.size[0] + _max(settings.size || 0, 0)) / 2) + 2, 0]
            },
            getStyles: function(settings) {
                var styles = {
                    root: [{
                        "class": "dxm-marker"
                    }, {
                        "class": "dxm-marker dxm-marker-hovered"
                    }, {
                        "class": "dxm-marker dxm-marker-selected"
                    }]
                };
                this._getStyles(styles, settings);
                return styles
            },
            setState: function(figure, styles, state) {
                applyElementState(figure, styles, state, "root");
                this._setState(figure, styles, state)
            },
            updateGrouping: function(context) {
                groupByColor(context);
                groupBySize(context)
            }
        };
        var strategiesByGeometry = {};
        strategiesByGeometry[TYPE_AREA] = function(sample) {
            var coordinates = sample.coordinates;
            return {
                project: coordinates[0] && coordinates[0][0] && coordinates[0][0][0] && "number" === typeof coordinates[0][0][0][0] ? projectMultiPolygon : projectPolygon
            }
        };
        strategiesByGeometry[TYPE_LINE] = function(sample) {
            var coordinates = sample.coordinates;
            return {
                project: coordinates[0] && coordinates[0][0] && "number" === typeof coordinates[0][0][0] ? projectPolygon : projectLineString
            }
        };
        var strategiesByElementType = {};
        strategiesByElementType[TYPE_MARKER] = {
            _default: "dot",
            dot: {
                setup: function(context) {
                    context.filter = context.renderer.shadowFilter("-40%", "-40%", "180%", "200%", 0, 1, 1, "#000000", .2)
                },
                reset: function(context) {
                    context.filter.dispose();
                    context.filter = null
                },
                _draw: function(ctx, figure, data) {
                    figure.back = ctx.renderer.circle().sharp().data(ctx.dataKey, data).append(figure.root);
                    figure.dot = ctx.renderer.circle().sharp().data(ctx.dataKey, data).append(figure.root)
                },
                refresh: function(ctx, figure, data, proxy, settings) {
                    figure.dot.attr({
                        filter: settings.shadow ? ctx.filter.ref : null
                    })
                },
                _getStyles: function(styles, style) {
                    var size = style.size > 0 ? _Number(style.size) : 0,
                        hoveredSize = size,
                        selectedSize = size + (style.selectedStep > 0 ? _Number(style.selectedStep) : 0),
                        hoveredBackSize = hoveredSize + (style.backStep > 0 ? _Number(style.backStep) : 0),
                        selectedBackSize = selectedSize + (style.backStep > 0 ? _Number(style.backStep) : 0),
                        color = style.color || null,
                        borderColor = style.borderColor || null,
                        borderWidth = style.borderWidth || null,
                        opacity = style.opacity || null,
                        backColor = style.backColor || null,
                        backOpacity = style.backOpacity || null;
                    styles.dot = [{
                        r: size / 2,
                        stroke: borderColor,
                        "stroke-width": borderWidth,
                        fill: color,
                        opacity: opacity
                    }, {
                        r: hoveredSize / 2,
                        stroke: style.hoveredBorderColor || borderColor,
                        "stroke-width": style.hoveredBorderWidth || borderWidth,
                        fill: style.hoveredColor || color,
                        opacity: style.hoveredOpacity || opacity
                    }, {
                        r: selectedSize / 2,
                        stroke: style.selectedBorderColor || borderColor,
                        "stroke-width": style.selectedBorderWidth || borderWidth,
                        fill: style.selectedColor || color,
                        opacity: style.selectedOpacity || opacity
                    }];
                    styles.back = [{
                        r: size / 2,
                        stroke: "none",
                        "stroke-width": 0,
                        fill: backColor,
                        opacity: backOpacity
                    }, {
                        r: hoveredBackSize / 2,
                        stroke: "none",
                        "stroke-width": 0,
                        fill: backColor,
                        opacity: backOpacity
                    }, {
                        r: selectedBackSize / 2,
                        stroke: "none",
                        "stroke-width": 0,
                        fill: backColor,
                        opacity: backOpacity
                    }]
                },
                _setState: function(figure, styles, state) {
                    applyElementState(figure, styles, state, "dot");
                    applyElementState(figure, styles, state, "back")
                }
            },
            bubble: {
                _draw: function(ctx, figure, data) {
                    figure.bubble = ctx.renderer.circle().sharp().data(ctx.dataKey, data).append(figure.root)
                },
                refresh: function(ctx, figure, data, proxy, settings) {
                    figure.bubble.attr({
                        r: settings.size / 2
                    })
                },
                _getStyles: function(styles, style) {
                    var color = style.color || null,
                        borderColor = style.borderColor || null,
                        borderWidth = style.borderWidth || null,
                        opacity = style.opacity || null;
                    styles.bubble = [{
                        stroke: borderColor,
                        "stroke-width": borderWidth,
                        fill: color,
                        opacity: opacity
                    }, {
                        stroke: style.hoveredBorderColor || borderColor,
                        "stroke-width": style.hoveredBorderWidth || borderWidth,
                        fill: style.hoveredColor || style.color,
                        opacity: style.hoveredOpacity || opacity
                    }, {
                        stroke: style.selectedBorderColor || borderColor,
                        "stroke-width": style.selectedBorderWidth || borderWidth,
                        fill: style.selectedColor || style.color,
                        opacity: style.selectedOpacity || opacity
                    }]
                },
                _setState: function(figure, styles, state) {
                    applyElementState(figure, styles, state, "bubble")
                },
                arrange: function(context, handles) {
                    var i, minValue, maxValue, deltaValue, deltaSize, values = [],
                        ii = values.length = handles.length,
                        settings = context.settings,
                        dataField = settings.dataField,
                        minSize = settings.minSize > 0 ? _Number(settings.minSize) : 0,
                        maxSize = settings.maxSize > minSize ? _Number(settings.maxSize) : minSize;
                    if (settings.sizeGroups) {
                        return
                    }
                    for (i = 0; i < ii; ++i) {
                        values[i] = _max(getDataValue(handles[i].proxy, dataField, "value") || 0, 0)
                    }
                    minValue = _min.apply(null, values);
                    maxValue = _max.apply(null, values);
                    deltaValue = maxValue - minValue || 1;
                    deltaSize = maxSize - minSize;
                    for (i = 0; i < ii; ++i) {
                        handles[i]._settings.size = minSize + deltaSize * (values[i] - minValue) / deltaValue
                    }
                },
                updateGrouping: function(context) {
                    var dataField = context.settings.dataField;
                    strategiesByType[TYPE_MARKER].updateGrouping(context);
                    groupBySize(context, function(proxy) {
                        return getDataValue(proxy, dataField, "value")
                    })
                }
            },
            pie: {
                _draw: function(ctx, figure, data) {
                    figure.pie = ctx.renderer.g().append(figure.root);
                    figure.border = ctx.renderer.circle().sharp().data(ctx.dataKey, data).append(figure.root)
                },
                refresh: function(ctx, figure, data, proxy, settings) {
                    var i, values = getDataValue(proxy, ctx.settings.dataField, "values") || [],
                        ii = values.length || 0,
                        colors = settings._colors,
                        sum = 0,
                        pie = figure.pie,
                        renderer = ctx.renderer,
                        dataKey = ctx.dataKey,
                        r = (settings.size > 0 ? _Number(settings.size) : 0) / 2,
                        start = 90,
                        end = start;
                    for (i = 0; i < ii; ++i) {
                        sum += values[i] || 0
                    }
                    for (i = 0; i < ii; ++i) {
                        start = end;
                        end += (values[i] || 0) / sum * 360;
                        renderer.arc(0, 0, 0, r, start, end).attr({
                            "stroke-linejoin": "round",
                            fill: colors[i]
                        }).data(dataKey, data).append(pie)
                    }
                    figure.border.attr({
                        r: r
                    })
                },
                _getStyles: function(styles, style) {
                    var opacity = style.opacity || null,
                        borderColor = style.borderColor || null,
                        borderWidth = style.borderWidth || null;
                    styles.pie = [{
                        opacity: opacity
                    }, {
                        opacity: style.hoveredOpacity || opacity
                    }, {
                        opacity: style.selectedOpacity || opacity
                    }];
                    styles.border = [{
                        stroke: borderColor,
                        "stroke-width": borderWidth
                    }, {
                        stroke: style.hoveredBorderColor || borderColor,
                        "stroke-width": style.hoveredBorderWidth || borderWidth
                    }, {
                        stroke: style.selectedBorderColor || borderColor,
                        "stroke-width": style.selectedBorderWidth || borderWidth
                    }]
                },
                _setState: function(figure, styles, state) {
                    applyElementState(figure, styles, state, "pie");
                    applyElementState(figure, styles, state, "border")
                },
                arrange: function(context, handles) {
                    var i, values, palette, ii = handles.length,
                        dataField = context.settings.dataField,
                        count = 0;
                    for (i = 0; i < ii; ++i) {
                        values = getDataValue(handles[i].proxy, dataField, "values");
                        if (values && values.length > count) {
                            count = values.length
                        }
                    }
                    if (count > 0) {
                        values = [];
                        palette = context.params.themeManager.createPalette(context.settings.palette, {
                            useHighlight: true
                        });
                        for (i = 0; i < count; ++i) {
                            values.push(palette.getNextColor())
                        }
                        context.settings._colors = values;
                        context.grouping.color = {
                            callback: _noop,
                            field: "",
                            partition: [],
                            values: []
                        };
                        context.params.dataExchanger.set(context.name, "color", {
                            partition: [],
                            values: values
                        })
                    }
                }
            },
            image: {
                _draw: function(ctx, figure, data) {
                    figure.image = ctx.renderer.image().attr({
                        location: "center"
                    }).data(ctx.dataKey, data).append(figure.root)
                },
                refresh: function(ctx, figure, data, proxy, settings) {
                    figure.image.attr({
                        href: getDataValue(proxy, ctx.settings.dataField, "url")
                    })
                },
                _getStyles: function(styles, style) {
                    var size = style.size > 0 ? _Number(style.size) : 0,
                        hoveredSize = size + (style.hoveredStep > 0 ? _Number(style.hoveredStep) : 0),
                        selectedSize = size + (style.selectedStep > 0 ? _Number(style.selectedStep) : 0),
                        opacity = style.opacity || null;
                    styles.image = [{
                        x: -size / 2,
                        y: -size / 2,
                        width: size,
                        height: size,
                        opacity: opacity
                    }, {
                        x: -hoveredSize / 2,
                        y: -hoveredSize / 2,
                        width: hoveredSize,
                        height: hoveredSize,
                        opacity: style.hoveredOpacity || opacity
                    }, {
                        x: -selectedSize / 2,
                        y: -selectedSize / 2,
                        width: selectedSize,
                        height: selectedSize,
                        opacity: style.selectedOpacity || opacity
                    }]
                },
                _setState: function(figure, styles, state) {
                    applyElementState(figure, styles, state, "image")
                }
            }
        };

        function projectPoint(projection, coordinates) {
            return projection.project(coordinates)
        }

        function projectPointList(projection, coordinates) {
            var i, output = [],
                ii = output.length = coordinates.length;
            for (i = 0; i < ii; ++i) {
                output[i] = projection.project(coordinates[i])
            }
            return output
        }

        function projectLineString(projection, coordinates) {
            return [projectPointList(projection, coordinates)]
        }

        function projectPolygon(projection, coordinates) {
            var i, output = [],
                ii = output.length = coordinates.length;
            for (i = 0; i < ii; ++i) {
                output[i] = projectPointList(projection, coordinates[i])
            }
            return output
        }

        function projectMultiPolygon(projection, coordinates) {
            var i, output = [],
                ii = output.length = coordinates.length;
            for (i = 0; i < ii; ++i) {
                output[i] = projectPolygon(projection, coordinates[i])
            }
            return _concat.apply([], output)
        }

        function transformPoint(content, projection, coordinates) {
            var data = projection.transform(coordinates);
            content.root.attr({
                translateX: data[0],
                translateY: data[1]
            })
        }

        function transformList(projection, coordinates) {
            var i, item, output = [],
                ii = coordinates.length,
                k = 0;
            output.length = 2 * ii;
            for (i = 0; i < ii; ++i) {
                item = projection.transform(coordinates[i]);
                output[k++] = item[0];
                output[k++] = item[1]
            }
            return output
        }

        function transformPointList(content, projection, coordinates) {
            var i, output = [],
                ii = output.length = coordinates.length;
            for (i = 0; i < ii; ++i) {
                output[i] = transformList(projection, coordinates[i])
            }
            content.root.attr({
                points: output
            })
        }

        function transformAreaLabel(label, projection, coordinates) {
            var data = projection.transform(coordinates[0]);
            label.spaceSize = projection.getSquareSize(coordinates[1]);
            label.text.attr({
                translateX: data[0],
                translateY: data[1]
            });
            setAreaLabelVisibility(label)
        }

        function transformLineLabel(label, projection, coordinates) {
            var data = projection.transform(coordinates[0]);
            label.spaceSize = projection.getSquareSize(coordinates[1]);
            label.text.attr({
                translateX: data[0],
                translateY: data[1]
            });
            setLineLabelVisibility(label)
        }

        function getItemSettings(context, proxy, settings) {
            var result = combineSettings(context.settings, settings);
            proxy.text = proxy.text || settings.text;
            applyGrouping(context.grouping, proxy, result);
            if (void 0 === settings.color && settings.paletteIndex >= 0) {
                result.color = result._colors[settings.paletteIndex]
            }
            return result
        }

        function applyGrouping(grouping, proxy, settings) {
            _each(grouping, function(name, data) {
                var index = findGroupingIndex(data.callback(proxy, data.field), data.partition);
                if (index >= 0) {
                    settings[name] = data.values[index]
                }
            })
        }

        function findGroupingIndex(value, partition) {
            var middle, start = 0,
                end = partition.length - 1,
                index = -1;
            if (partition[start] <= value && value <= partition[end]) {
                if (value === partition[end]) {
                    index = end - 1
                } else {
                    while (end - start > 1) {
                        middle = start + end >> 1;
                        if (value < partition[middle]) {
                            end = middle
                        } else {
                            start = middle
                        }
                    }
                    index = start
                }
            }
            return index
        }

        function raiseChanged(context, handle, state, name) {
            context.params.eventTrigger(name, {
                target: handle.proxy,
                state: state
            })
        }

        function combineSettings(common, partial) {
            var obj = _extend({}, common, partial);
            obj.label = _extend({}, common.label, obj.label);
            obj.label.font = _extend({}, common.label.font, obj.label.font);
            return obj
        }

        function processCommonSettings(type, options, themeManager) {
            var colors, i, palette, settings = combineSettings(themeManager.theme("layer:" + type) || {
                label: {}
            }, options);
            if (settings.paletteSize > 0) {
                palette = themeManager.createDiscretePalette(settings.palette, settings.paletteSize);
                for (i = 0, colors = []; i < settings.paletteSize; ++i) {
                    colors.push(palette.getColor(i))
                }
                settings._colors = colors
            }
            return settings
        }

        function valueCallback(proxy, dataField) {
            return proxy.attribute(dataField)
        }
        var performGrouping = function(context, partition, settingField, dataField, valuesCallback) {
            var values;
            if (dataField && partition && partition.length > 1) {
                values = valuesCallback(partition.length - 1);
                context.grouping[settingField] = {
                    callback: _isFunction(dataField) ? dataField : valueCallback,
                    field: dataField,
                    partition: partition,
                    values: values
                };
                context.params.dataExchanger.set(context.name, settingField, {
                    partition: partition,
                    values: values
                })
            }
        };

        function dropGrouping(context) {
            var name = context.name,
                dataExchanger = context.params.dataExchanger;
            _each(context.grouping, function(field) {
                dataExchanger.set(name, field, null)
            });
            context.grouping = {}
        }
        var groupByColor = function(context) {
            performGrouping(context, context.settings.colorGroups, "color", context.settings.colorGroupingField, function(count) {
                var i, _palette = context.params.themeManager.createDiscretePalette(context.settings.palette, count),
                    list = [];
                for (i = 0; i < count; ++i) {
                    list.push(_palette.getColor(i))
                }
                return list
            })
        };
        var groupBySize = function(context, valueCallback) {
            var settings = context.settings;
            performGrouping(context, settings.sizeGroups, "size", valueCallback || settings.sizeGroupingField, function(count) {
                var minSize = settings.minSize > 0 ? _Number(settings.minSize) : 0,
                    maxSize = settings.maxSize >= minSize ? _Number(settings.maxSize) : 0,
                    i = 0,
                    sizes = [];
                if (count > 1) {
                    for (i = 0; i < count; ++i) {
                        sizes.push((minSize * (count - i - 1) + maxSize * i) / (count - 1))
                    }
                } else {
                    if (1 === count) {
                        sizes.push((minSize + maxSize) / 2)
                    }
                }
                return sizes
            })
        };

        function setFlag(flags, flag, state) {
            if (state) {
                flags |= flag
            } else {
                flags &= ~flag
            }
            return flags
        }

        function hasFlag(flags, flag) {
            return !!(flags & flag)
        }

        function createLayerProxy(layer, name, index) {
            var proxy = {
                index: index,
                name: name,
                getElements: function() {
                    return layer.getProxies()
                },
                clearSelection: function(_noEvent) {
                    layer.clearSelection(_noEvent);
                    return proxy
                }
            };
            return proxy
        }
        var MapLayer = function(params, container, name, index) {
            var that = this;
            that._params = params;
            that._onProjection();
            that.proxy = createLayerProxy(that, name, index);
            that._context = {
                name: name,
                layer: that.proxy,
                renderer: params.renderer,
                projection: params.projection,
                params: params,
                dataKey: params.dataKey,
                str: emptyStrategy,
                hover: false,
                selection: null,
                grouping: {},
                root: params.renderer.g().attr({
                    "class": "dxm-layer"
                }).linkOn(container, name).linkAppend()
            };
            that._container = container;
            that._dataSource = new dataSourceModule.DataSource(function() {
                that._data = unwrapFromDataSource(that._dataSource.items());
                that._update(true)
            });
            that._options = {};
            that._handles = [];
            that._data = new EmptySource
        };
        MapLayer.prototype = {
            constructor: MapLayer,
            _onProjection: function() {
                var that = this;
                that._removeHandlers = that._params.projection.on({
                    engine: function() {
                        that._project()
                    },
                    screen: function() {
                        that._transform()
                    },
                    center: function() {
                        that._transformCore()
                    },
                    zoom: function() {
                        that._transform()
                    }
                })
            },
            _offProjection: function() {
                this._removeHandlers();
                this._removeHandlers = null
            },
            dispose: function() {
                var that = this;
                that._dataSource.dispose();
                that._destroyHandles();
                dropGrouping(that._context);
                that._context.root.linkRemove().linkOff();
                that._context.labelRoot && that._context.labelRoot.linkRemove().linkOff();
                that._context.str.reset(that._context);
                that._offProjection();
                that._params = that._container = that._context = that._dataSource = that.proxy = null;
                return that
            },
            TESTS_getContext: function() {
                return this._context
            },
            setOptions: function(options) {
                var name, that = this;
                options = that._options = options || {};
                name = !("dataSource" in options) && "data" in options ? "data" : "dataSource";
                if (name in options && options[name] !== that._options_dataSource) {
                    that._options_dataSource = options[name];
                    that._params.notifyDirty();
                    that._dataSource.update(wrapToDataSource(options[name]))
                } else {
                    if (that._data.count() > 0) {
                        that._params.notifyDirty();
                        that._update(void 0 !== options.type && options.type !== that._context.str.type || void 0 !== options.elementType && options.elementType !== that._context.str.elementType)
                    }
                }
            },
            _update: function(isContextChanged) {
                var that = this,
                    context = that._context;
                if (isContextChanged) {
                    context.str.reset(context);
                    context.root.clear();
                    context.labelRoot && context.labelRoot.clear();
                    that._params.tracker.reset();
                    that._destroyHandles();
                    context.str = selectStrategy(that._options, that._data);
                    context.str.setup(context);
                    that.proxy.type = context.str.type;
                    that.proxy.elementType = context.str.elementType
                }
                context.settings = processCommonSettings(context.str.fullType, that._options, that._params.themeManager);
                context.hasSeparateLabel = !!(context.settings.label.enabled && context.str.hasLabelsGroup);
                context.hover = !!_parseScalar(context.settings.hoverEnabled, true);
                if (context.selection) {
                    _each(context.selection.state, function(_, handle) {
                        handle && handle.resetSelected()
                    })
                }
                context.selection = getSelection(context.settings.selectionMode);
                if (context.hasSeparateLabel) {
                    if (!context.labelRoot) {
                        context.labelRoot = context.renderer.g().attr({
                            "class": "dxm-layer-labels"
                        }).linkOn(that._container, {
                            name: context.name + "-labels",
                            after: context.name
                        }).linkAppend();
                        that._transformCore()
                    }
                } else {
                    if (context.labelRoot) {
                        context.labelRoot.linkRemove().linkOff();
                        context.labelRoot = null
                    }
                }
                if (isContextChanged) {
                    that._createHandles()
                }
                dropGrouping(context);
                context.str.arrange(context, that._handles);
                context.str.updateGrouping(context);
                that._updateHandles();
                that._params.notifyReady()
            },
            _destroyHandles: function() {
                var i, handles = this._handles,
                    ii = handles.length;
                for (i = 0; i < ii; ++i) {
                    handles[i].dispose()
                }
                if (this._context.selection) {
                    this._context.selection.state = {}
                }
                this._handles = []
            },
            _createHandles: function() {
                var i, handle, dataItem, that = this,
                    handles = that._handles = [],
                    data = that._data,
                    ii = handles.length = data.count(),
                    context = that._context,
                    geometry = data.geometry,
                    attributes = data.attributes;
                for (i = 0; i < ii; ++i) {
                    dataItem = data.item(i);
                    handles[i] = new MapLayerElement(context, i, geometry(dataItem), attributes(dataItem))
                }
                if (_isFunction(that._options.customize)) {
                    (that._options._deprecated ? customizeHandles_deprecated : customizeHandles)(that.getProxies(), that._options.customize, that._params.widget)
                }
                if (that._options._deprecated) {
                    patchProxies(handles, context.name, data)
                }
                for (i = 0; i < ii; ++i) {
                    handle = handles[i];
                    handle.project();
                    handle.draw();
                    handle.transform()
                }
                if (context.selection) {
                    _each(context.selection.state, function(_, handle) {
                        handle && handle.restoreSelected()
                    })
                }
            },
            _updateHandles: function() {
                var i, handles = this._handles,
                    ii = handles.length;
                for (i = 0; i < ii; ++i) {
                    handles[i].refresh()
                }
                if (this._context.settings.label.enabled) {
                    for (i = 0; i < ii; ++i) {
                        handles[i].measureLabel()
                    }
                    for (i = 0; i < ii; ++i) {
                        handles[i].adjustLabel()
                    }
                }
            },
            _transformCore: function() {
                var transform = this._params.projection.getTransform();
                this._context.root.attr(transform);
                this._context.labelRoot && this._context.labelRoot.attr(transform)
            },
            _project: function() {
                var i, handles = this._handles,
                    ii = handles.length;
                for (i = 0; i < ii; ++i) {
                    handles[i].project()
                }
            },
            _transform: function() {
                var i, handles = this._handles,
                    ii = handles.length;
                this._transformCore();
                for (i = 0; i < ii; ++i) {
                    handles[i].transform()
                }
            },
            getProxies: function() {
                var i, handles = this._handles,
                    proxies = [],
                    ii = proxies.length = handles.length;
                for (i = 0; i < ii; ++i) {
                    proxies[i] = handles[i].proxy
                }
                return proxies
            },
            getProxy: function(index) {
                return this._handles[index].proxy
            },
            raiseClick: function(i, jQueryEvent) {
                this._params.eventTrigger("click", {
                    target: this._handles[i].proxy,
                    jQueryEvent: jQueryEvent
                })
            },
            hoverItem: function(i, state) {
                this._handles[i].setHovered(state)
            },
            selectItem: function(i, state, _noEvent) {
                this._handles[i].setSelected(state, _noEvent)
            },
            clearSelection: function() {
                var selection = this._context.selection;
                if (selection) {
                    _each(selection.state, function(_, handle) {
                        handle && handle.setSelected(false)
                    });
                    selection.state = {}
                }
            }
        };

        function createProxy(handle, coords, attrs) {
            var proxy = {
                coordinates: function() {
                    return coords
                },
                attribute: function(name, value) {
                    if (arguments.length > 1) {
                        attrs[name] = value;
                        return proxy
                    } else {
                        return arguments.length > 0 ? attrs[name] : attrs
                    }
                },
                selected: function(state, _noEvent) {
                    if (arguments.length > 0) {
                        handle.setSelected(state, _noEvent);
                        return proxy
                    } else {
                        return handle.isSelected()
                    }
                },
                applySettings: function(settings) {
                    handle.update(settings);
                    return proxy
                }
            };
            return proxy
        }
        var MapLayerElement = function(context, index, geometry, attributes) {
            var that = this,
                proxy = that.proxy = createProxy(that, geometry.coordinates, _extend({}, attributes));
            that._ctx = context;
            that._idx = index;
            that._fig = that._lbl = null;
            that._state = STATE_DEFAULT;
            that._coordinates = geometry.coordinates;
            that._settings = {
                label: {}
            };
            proxy.index = index;
            proxy.layer = context.layer;
            that._data = {
                name: context.name,
                index: index
            }
        };
        MapLayerElement.prototype = {
            constructor: MapLayerElement,
            dispose: function() {
                var that = this;
                that._ctx = that.proxy = that._settings = that._fig = that._lbl = that.data = null;
                return that
            },
            project: function() {
                var context = this._ctx;
                this._prj = context.str.project(context.projection, this._coordinates);
                if (context.hasSeparateLabel && this._lbl) {
                    this._projectLabel()
                }
            },
            _projectLabel: function() {
                this._labelPrj = this._ctx.str.projectLabel(this._prj)
            },
            draw: function() {
                var that = this,
                    context = this._ctx;
                context.str.draw(context, that._fig = {}, that._data);
                that._fig.root.append(context.root)
            },
            transform: function() {
                var that = this,
                    context = that._ctx;
                context.str.transform(that._fig, context.projection, that._prj);
                if (context.hasSeparateLabel && that._lbl) {
                    that._transformLabel()
                }
            },
            _transformLabel: function() {
                this._ctx.str.transformLabel(this._lbl, this._ctx.projection, this._labelPrj)
            },
            refresh: function() {
                var that = this,
                    strategy = that._ctx.str,
                    settings = getItemSettings(that._ctx, that.proxy, that._settings);
                that._styles = strategy.getStyles(settings);
                strategy.refresh(that._ctx, that._fig, that._data, that.proxy, settings);
                that._refreshLabel(settings);
                that._setState()
            },
            _refreshLabel: function(settings) {
                var that = this,
                    context = that._ctx,
                    labelSettings = settings.label,
                    label = that._lbl;
                if (context.settings.label.enabled) {
                    if (!label) {
                        label = that._lbl = {
                            root: context.labelRoot || that._fig.root,
                            text: context.renderer.text().attr({
                                "class": "dxm-label"
                            }),
                            size: [0, 0]
                        };
                        if (context.hasSeparateLabel) {
                            that._projectLabel();
                            that._transformLabel()
                        }
                    }
                    label.value = _String(that.proxy.text || that.proxy.attribute(labelSettings.dataField) || "");
                    if (label.value) {
                        label.text.attr({
                            text: label.value,
                            x: 0,
                            y: 0
                        }).css(_patchFontOptions(labelSettings.font)).attr({
                            align: "center",
                            stroke: labelSettings.stroke,
                            "stroke-width": labelSettings["stroke-width"],
                            "stroke-opacity": labelSettings["stroke-opacity"]
                        }).data(context.dataKey, that._data).append(label.root);
                        label.settings = settings
                    }
                } else {
                    if (label) {
                        label.text.remove();
                        that._lbl = null
                    }
                }
            },
            measureLabel: function() {
                var bbox, label = this._lbl;
                if (label.value) {
                    bbox = label.text.getBBox();
                    label.size = [bbox.width, bbox.height, -bbox.y - bbox.height / 2]
                }
            },
            adjustLabel: function() {
                var offset, label = this._lbl;
                if (label.value) {
                    offset = this._ctx.str.getLabelOffset(label, label.settings);
                    label.settings = null;
                    label.text.attr({
                        x: offset[0],
                        y: offset[1] + label.size[2]
                    })
                }
            },
            update: function(settings) {
                var that = this;
                that._settings = combineSettings(that._settings, settings);
                if (that._fig) {
                    that.refresh();
                    if (that._lbl && that._lbl.value) {
                        that.measureLabel();
                        that.adjustLabel()
                    }
                }
            },
            _setState: function() {
                this._ctx.str.setState(this._fig, this._styles, STATE_TO_INDEX[this._state])
            },
            _setForeground: function() {
                var root = this._fig.root;
                this._state ? root.toForeground() : root.toBackground()
            },
            setHovered: function(state) {
                var that = this,
                    currentState = hasFlag(that._state, STATE_HOVERED),
                    newState = !!state;
                if (that._ctx.hover && currentState !== newState) {
                    that._state = setFlag(that._state, STATE_HOVERED, newState);
                    that._setState();
                    that._setForeground();
                    raiseChanged(that._ctx, that, newState, "hoverChanged")
                }
                return that
            },
            setSelected: function(state, _noEvent) {
                var tmp, that = this,
                    currentState = hasFlag(that._state, STATE_SELECTED),
                    newState = !!state,
                    selection = that._ctx.selection;
                if (selection && currentState !== newState) {
                    that._state = setFlag(that._state, STATE_SELECTED, newState);
                    tmp = selection.state[selection.single];
                    selection.state[selection.single] = null;
                    if (tmp) {
                        tmp.setSelected(false)
                    }
                    selection.state[selection.single || that._idx] = state ? that : null;
                    if (that._fig) {
                        that._setState();
                        that._setForeground();
                        if (!_noEvent) {
                            raiseChanged(that._ctx, that, newState, "selectionChanged")
                        }
                    }
                }
            },
            isSelected: function() {
                return hasFlag(this._state, STATE_SELECTED)
            },
            resetSelected: function() {
                this._state = setFlag(this._state, STATE_SELECTED, false)
            },
            restoreSelected: function() {
                this._fig.root.toForeground()
            }
        };

        function calculatePolygonCentroid(coordinates) {
            var i, v1, cross, length = coordinates.length,
                v2 = coordinates[length - 1],
                cx = 0,
                cy = 0,
                area = 0,
                minX = 1 / 0,
                maxX = -(1 / 0),
                minY = 1 / 0,
                maxY = -(1 / 0);
            for (i = 0; i < length; ++i) {
                v1 = v2;
                v2 = coordinates[i];
                cross = v1[0] * v2[1] - v2[0] * v1[1];
                area += cross;
                cx += (v1[0] + v2[0]) * cross;
                cy += (v1[1] + v2[1]) * cross;
                minX = _min(minX, v2[0]);
                maxX = _max(maxX, v2[0]);
                minY = _min(minY, v2[1]);
                maxY = _max(maxY, v2[1])
            }
            return {
                area: _abs(area) / 2,
                center: [2 * cx / 3 / area - (minX + maxX) / 2, 2 * cy / 3 / area - (minY + maxY) / 2]
            }
        }

        function calculateLineStringData(coordinates) {
            var i, v1, t, ii = coordinates.length,
                v2 = coordinates[0] || [],
                totalLength = 0,
                items = [0],
                min0 = v2[0],
                max0 = v2[0],
                min1 = v2[1],
                max1 = v2[1];
            for (i = 1; i < ii; ++i) {
                v1 = v2;
                v2 = coordinates[i];
                totalLength += _sqrt((v1[0] - v2[0]) * (v1[0] - v2[0]) + (v1[1] - v2[1]) * (v1[1] - v2[1]));
                items[i] = totalLength;
                min0 = _min(min0, v2[0]);
                max0 = _max(max0, v2[0]);
                min1 = _min(min1, v2[1]);
                max1 = _max(max1, v2[1])
            }
            i = findGroupingIndex(totalLength / 2, items);
            v1 = coordinates[i];
            v2 = coordinates[i + 1];
            t = (totalLength / 2 - items[i]) / (items[i + 1] - items[i]);
            return ii ? [
                [v1[0] * (1 - t) + v2[0] * t, v1[1] * (1 - t) + v2[1] * t],
                [max0 - min0, max1 - min1], totalLength
            ] : []
        }

        function projectAreaLabel(coordinates) {
            var i, centroid, resultCentroid, ii = coordinates.length,
                maxArea = 0;
            for (i = 0; i < ii; ++i) {
                centroid = calculatePolygonCentroid(coordinates[i]);
                if (centroid.area > maxArea) {
                    maxArea = centroid.area;
                    resultCentroid = centroid
                }
            }
            return resultCentroid ? [resultCentroid.center, [_sqrt(resultCentroid.area), _sqrt(resultCentroid.area)]] : [
                [],
                []
            ]
        }

        function projectLineLabel(coordinates) {
            var i, data, resultData, ii = coordinates.length,
                maxLength = 0;
            for (i = 0; i < ii; ++i) {
                data = calculateLineStringData(coordinates[i]);
                if (data[2] > maxLength) {
                    maxLength = data[2];
                    resultData = data
                }
            }
            return resultData || [
                [],
                []
            ]
        }

        function MapLayerCollection(params) {
            var that = this,
                renderer = params.renderer;
            that._params = params;
            that._layers = [];
            that._layerByName = {};
            that._rect = [0, 0, 0, 0];
            that._clip = renderer.clipRect();
            that._background = renderer.rect().attr({
                "class": "dxm-background"
            }).data(params.dataKey, {
                name: "background"
            }).append(renderer.root);
            that._container = renderer.g().attr({
                "class": "dxm-layers",
                clipId: that._clip.id
            }).append(renderer.root).enableLinks();
            that._subscribeToTracker(params.tracker, renderer, params.eventTrigger)
        }
        MapLayerCollection.prototype = {
            constructor: MapLayerCollection,
            dispose: function() {
                var that = this;
                that._clip.dispose();
                that._offTracker();
                that._params = that._offTracker = that._layers = that._layerByName = that._clip = that._background = that._container = null
            },
            _subscribeToTracker: function(tracker, renderer, eventTrigger) {
                var that = this;
                that._offTracker = tracker.on({
                    click: function(arg) {
                        var offset = renderer.getRootOffset(),
                            layer = that.byName(arg.data.name);
                        arg.$event.x = arg.x - offset.left;
                        arg.$event.y = arg.y - offset.top;
                        if (layer) {
                            layer.raiseClick(arg.data.index, arg.$event)
                        } else {
                            if ("background" === arg.data.name) {
                                eventTrigger("click", {
                                    jQueryEvent: arg.$event
                                })
                            }
                        }
                    },
                    "hover-on": function(arg) {
                        var layer = that.byName(arg.data.name);
                        if (layer) {
                            layer.hoverItem(arg.data.index, true)
                        }
                    },
                    "hover-off": function(arg) {
                        var layer = that.byName(arg.data.name);
                        if (layer) {
                            layer.hoverItem(arg.data.index, false)
                        }
                    }
                })
            },
            setOptions: function(options) {
                var name, layer, i, ii, optionList = options ? options.length ? options : [options] : [],
                    layers = this._layers,
                    layerByName = this._layerByName,
                    params = this._params,
                    container = this._container;
                for (i = optionList.length, ii = layers.length; i < ii; ++i) {
                    layer = layers[i];
                    delete layerByName[layer.proxy.name];
                    layer.dispose()
                }
                layers.splice(optionList.length, layers.length - optionList.length);
                for (i = layers.length, ii = optionList.length; i < ii; ++i) {
                    name = (optionList[i] || {}).name || "map-layer-" + i;
                    layer = layers[i] = new MapLayer(params, container, name, i);
                    layerByName[name] = layer
                }
                for (i = 0, ii = optionList.length; i < ii; ++i) {
                    name = optionList[i] && optionList[i].name;
                    layer = layers[i];
                    if (name && name !== layer.proxy.name) {
                        delete layerByName[layer.proxy.name];
                        layer.dispose();
                        layer = layers[i] = new MapLayer(params, container, name, i);
                        layerByName[name] = layer
                    }
                    layer.setOptions(optionList[i])
                }
            },
            _updateClip: function() {
                var rect = this._rect,
                    bw = this._bw;
                this._clip.attr({
                    x: rect[0] + bw,
                    y: rect[1] + bw,
                    width: _max(rect[2] - 2 * bw, 0),
                    height: _max(rect[3] - 2 * bw, 0)
                })
            },
            setBackgroundOptions: function(options) {
                this._background.attr({
                    stroke: options.borderColor,
                    "stroke-width": options.borderWidth,
                    fill: options.color
                });
                this._bw = _max(options.borderWidth, 0);
                this._updateClip()
            },
            setRect: function(rect) {
                this._rect = rect;
                this._background.attr({
                    x: rect[0],
                    y: rect[1],
                    width: rect[2],
                    height: rect[3]
                });
                this._updateClip()
            },
            byIndex: function(index) {
                return this._layers[index]
            },
            byName: function(name) {
                return this._layerByName[name]
            },
            items: function() {
                return this._layers
            }
        };
        exports.MapLayerCollection = MapLayerCollection;
        exports._TESTS_MapLayer = MapLayer;
        exports._TESTS_stub_MapLayer = function(stub) {
            MapLayer = stub
        };
        exports._TESTS_selectStrategy = selectStrategy;
        exports._TESTS_stub_selectStrategy = function(stub) {
            selectStrategy = stub
        };
        exports._TESTS_MapLayerElement = MapLayerElement;
        exports._TESTS_stub_MapLayerElement = function(stub) {
            MapLayerElement = stub
        };
        exports._TESTS_createProxy = createProxy;
        exports._TESTS_stub_performGrouping = function(stub) {
            performGrouping = stub
        };
        exports._TESTS_performGrouping = performGrouping;
        exports._TESTS_stub_groupByColor = function(stub) {
            groupByColor = stub
        };
        exports._TESTS_groupByColor = groupByColor;
        exports._TESTS_stub_groupBySize = function(stub) {
            groupBySize = stub
        };
        exports._TESTS_groupBySize = groupBySize;
        exports._TESTS_findGroupingIndex = findGroupingIndex
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/vector_map/tooltip_viewer.js ***!
      \**************************************************/
    function(module, exports) {
        var TOOLTIP_OFFSET = 12;

        function TooltipViewer(params) {
            this._subscribeToTracker(params.tracker, params.tooltip, params.layerCollection)
        }
        TooltipViewer.prototype = {
            constructor: TooltipViewer,
            dispose: function() {
                this._offTracker();
                this._offTracker = null
            },
            _subscribeToTracker: function(tracker, tooltip, layerCollection) {
                this._offTracker = tracker.on({
                    "focus-on": function(arg) {
                        var layer, proxy, result = false;
                        if (tooltip.isEnabled()) {
                            layer = layerCollection.byName(arg.data.name);
                            proxy = layer && layer.getProxy(arg.data.index);
                            if (proxy && tooltip.show(proxy, {
                                    x: 0,
                                    y: 0,
                                    offset: 0
                                }, {
                                    target: proxy
                                })) {
                                tooltip.move(arg.x, arg.y, TOOLTIP_OFFSET);
                                result = true
                            }
                        }
                        arg.done(result)
                    },
                    "focus-move": function(arg) {
                        tooltip.move(arg.x, arg.y, TOOLTIP_OFFSET)
                    },
                    "focus-off": function() {
                        tooltip.hide()
                    }
                })
            }
        };
        exports.TooltipViewer = TooltipViewer
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/vector_map/projection.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var projectionModule = __webpack_require__( /*! ./projection.main */ 550),
            projection = projectionModule.projection,
            _min = Math.min,
            _max = Math.max,
            _sin = Math.sin,
            _asin = Math.asin,
            _tan = Math.tan,
            _atan = Math.atan,
            _exp = Math.exp,
            _log = Math.log,
            PI = Math.PI,
            PI_DIV_4 = PI / 4,
            GEO_LON_BOUND = 180,
            GEO_LAT_BOUND = 90,
            RADIANS = PI / 180,
            MERCATOR_LAT_BOUND = (2 * _atan(_exp(PI)) - PI / 2) / RADIANS,
            MILLER_LAT_BOUND = (2.5 * _atan(_exp(.8 * PI)) - .625 * PI) / RADIANS;

        function clamp(value, threshold) {
            return _max(_min(value, +threshold), -threshold)
        }
        projection.add("mercator", projection({
            aspectRatio: 1,
            to: function(coordinates) {
                return [coordinates[0] / GEO_LON_BOUND, _log(_tan(PI_DIV_4 + clamp(coordinates[1], MERCATOR_LAT_BOUND) * RADIANS / 2)) / PI]
            },
            from: function(coordinates) {
                return [coordinates[0] * GEO_LON_BOUND, (2 * _atan(_exp(coordinates[1] * PI)) - PI / 2) / RADIANS]
            }
        }));
        projection.add("equirectangular", projection({
            aspectRatio: 2,
            to: function(coordinates) {
                return [coordinates[0] / GEO_LON_BOUND, coordinates[1] / GEO_LAT_BOUND]
            },
            from: function(coordinates) {
                return [coordinates[0] * GEO_LON_BOUND, coordinates[1] * GEO_LAT_BOUND]
            }
        }));
        projection.add("lambert", projection({
            aspectRatio: 2,
            to: function(coordinates) {
                return [coordinates[0] / GEO_LON_BOUND, _sin(clamp(coordinates[1], GEO_LAT_BOUND) * RADIANS)]
            },
            from: function(coordinates) {
                return [coordinates[0] * GEO_LON_BOUND, _asin(clamp(coordinates[1], 1)) / RADIANS]
            }
        }));
        projection.add("miller", projection({
            aspectRatio: 1,
            to: function(coordinates) {
                return [coordinates[0] / GEO_LON_BOUND, 1.25 * _log(_tan(PI_DIV_4 + clamp(coordinates[1], MILLER_LAT_BOUND) * RADIANS * .4)) / PI]
            },
            from: function(coordinates) {
                return [coordinates[0] * GEO_LON_BOUND, (2.5 * _atan(_exp(.8 * coordinates[1] * PI)) - .625 * PI) / RADIANS]
            }
        }));
        exports.projection = projection
    },
    /*!**********************************!*\
      !*** ./Scripts/viz/sparkline.js ***!
      \**********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./sparklines/sparkline */ 563)
    },
    /*!*********************************************!*\
      !*** ./Scripts/viz/sparklines/sparkline.js ***!
      \*********************************************/
    function(module, exports, __webpack_require__) {
        var BaseSparkline = __webpack_require__( /*! ./base_sparkline */ 564),
            commonUtils = __webpack_require__( /*! ../../core/utils/common */ 14),
            dataValidatorModule = __webpack_require__( /*! ../components/data_validator */ 458),
            seriesModule = __webpack_require__( /*! ../series/base_series */ 460),
            MIN_BAR_WIDTH = 1,
            MAX_BAR_WIDTH = 50,
            DEFAULT_BAR_INTERVAL = 4,
            DEFAULT_CANVAS_WIDTH = 250,
            DEFAULT_CANVAS_HEIGHT = 30,
            DEFAULT_HORIZONTAL_MARGIN = 5,
            DEFAULT_VERTICAL_MARGIN = 3,
            ALLOWED_TYPES = {
                line: true,
                spline: true,
                stepline: true,
                area: true,
                steparea: true,
                splinearea: true,
                bar: true,
                winloss: true
            },
            _math = Math,
            _abs = _math.abs,
            _round = _math.round,
            _max = _math.max,
            _min = _math.min,
            _isFinite = isFinite,
            vizUtils = __webpack_require__( /*! ../core/utils */ 442),
            _map = vizUtils.map,
            _normalizeEnum = vizUtils.normalizeEnum,
            _isDefined = commonUtils.isDefined,
            _Number = Number,
            _String = String;
        var dxSparkline = BaseSparkline.inherit({
            _rootClassPrefix: "dxsl",
            _rootClass: "dxsl-sparkline",
            _widgetType: "sparkline",
            _defaultSize: {
                width: DEFAULT_CANVAS_WIDTH,
                height: DEFAULT_CANVAS_HEIGHT,
                left: DEFAULT_HORIZONTAL_MARGIN,
                right: DEFAULT_HORIZONTAL_MARGIN,
                top: DEFAULT_VERTICAL_MARGIN,
                bottom: DEFAULT_VERTICAL_MARGIN
            },
            _initCore: function() {
                this.callBase();
                this._createSeries()
            },
            _initialChanges: ["DATA_SOURCE"],
            _dataSourceChangedHandler: function() {
                this._requestChange(["UPDATE"])
            },
            _updateWidgetElements: function() {
                this._updateSeries();
                this.callBase()
            },
            _disposeWidgetElements: function() {
                var that = this;
                that._series && that._series.dispose();
                that._series = that._seriesGroup = that._seriesLabelGroup = null
            },
            _cleanWidgetElements: function() {
                this._seriesGroup.remove();
                this._seriesLabelGroup.remove();
                this._seriesGroup.clear();
                this._seriesLabelGroup.clear()
            },
            _drawWidgetElements: function() {
                if (this._dataSource.isLoaded()) {
                    this._drawSeries();
                    this._drawn()
                }
            },
            _prepareOptions: function() {
                var that = this;
                that._allOptions = that.callBase();
                that._allOptions.type = _normalizeEnum(that._allOptions.type);
                if (!ALLOWED_TYPES[that._allOptions.type]) {
                    that._allOptions.type = "line"
                }
            },
            _createHtmlElements: function() {
                this._seriesGroup = this._renderer.g().attr({
                    "class": "dxsl-series"
                });
                this._seriesLabelGroup = this._renderer.g().attr({
                    "class": "dxsl-series-labels"
                })
            },
            _createSeries: function() {
                this._series = new seriesModule.Series({
                    renderer: this._renderer,
                    seriesGroup: this._seriesGroup,
                    labelsGroup: this._seriesLabelGroup
                }, {
                    widgetType: "chart",
                    type: "line"
                })
            },
            getSeriesOptions: function() {
                return this._series.getOptions()
            },
            _updateSeries: function() {
                var groupsData, seriesOptions, that = this,
                    singleSeries = that._series;
                that._prepareDataSource();
                seriesOptions = that._prepareSeriesOptions();
                singleSeries.updateOptions(seriesOptions);
                groupsData = {
                    groups: [{
                        series: [singleSeries]
                    }]
                };
                groupsData.argumentOptions = {
                    type: "bar" === seriesOptions.type ? "discrete" : void 0
                };
                that._simpleDataSource = dataValidatorModule.validateData(that._simpleDataSource, groupsData, that._incidentOccurred, {
                    checkTypeForAllData: false,
                    convertToAxisDataType: true,
                    sortingMethod: true
                })[singleSeries.getArgumentField()];
                singleSeries.updateData(that._simpleDataSource);
                that._groupsDataCategories = groupsData.categories
            },
            _optionChangesMap: {
                dataSource: "DATA_SOURCE"
            },
            _optionChangesOrder: ["DATA_SOURCE"],
            _change_DATA_SOURCE: function() {
                this._updateDataSource()
            },
            _parseNumericDataSource: function(data, argField, valField) {
                var ignoreEmptyPoints = this.option("ignoreEmptyPoints");
                return _map(data, function(dataItem, index) {
                    var isDataNumber, value, item = null;
                    if (void 0 !== dataItem) {
                        item = {};
                        isDataNumber = _isFinite(dataItem);
                        item[argField] = isDataNumber ? _String(index) : dataItem[argField];
                        value = isDataNumber ? dataItem : dataItem[valField];
                        item[valField] = null === value ? ignoreEmptyPoints ? void 0 : value : _Number(value);
                        item = void 0 !== item[argField] && void 0 !== item[valField] ? item : null
                    }
                    return item
                })
            },
            _parseWinlossDataSource: function(data, argField, valField) {
                var lowBarValue = -1,
                    zeroBarValue = 0,
                    highBarValue = 1,
                    delta = 1e-4,
                    target = this._allOptions.winlossThreshold;
                return _map(data, function(dataItem) {
                    var item = {};
                    item[argField] = dataItem[argField];
                    if (_abs(dataItem[valField] - target) < delta) {
                        item[valField] = zeroBarValue
                    } else {
                        if (dataItem[valField] > target) {
                            item[valField] = highBarValue
                        } else {
                            item[valField] = lowBarValue
                        }
                    }
                    return item
                })
            },
            _prepareDataSource: function() {
                var that = this,
                    options = that._allOptions,
                    argField = options.argumentField,
                    valField = options.valueField,
                    dataSource = that._dataSource.items() || [],
                    data = that._parseNumericDataSource(dataSource, argField, valField);
                if ("winloss" === options.type) {
                    that._winlossDataSource = data;
                    that._simpleDataSource = that._parseWinlossDataSource(data, argField, valField)
                } else {
                    that._simpleDataSource = data
                }
            },
            _prepareSeriesOptions: function() {
                var that = this,
                    options = that._allOptions,
                    type = "winloss" === options.type ? "bar" : options.type;
                return {
                    visible: true,
                    argumentField: options.argumentField,
                    valueField: options.valueField,
                    color: options.lineColor,
                    width: options.lineWidth,
                    widgetType: "chart",
                    type: type,
                    opacity: type.indexOf("area") !== -1 ? that._allOptions.areaOpacity : void 0,
                    customizePoint: that._getCustomizeFunction(),
                    point: {
                        size: options.pointSize,
                        symbol: options.pointSymbol,
                        border: {
                            visible: true,
                            width: 2
                        },
                        color: options.pointColor,
                        visible: false,
                        hoverStyle: {
                            border: {}
                        },
                        selectionStyle: {
                            border: {}
                        }
                    },
                    border: {
                        color: options.lineColor,
                        width: options.lineWidth,
                        visible: "bar" !== type
                    }
                }
            },
            _createBarCustomizeFunction: function(pointIndexes) {
                var that = this,
                    options = that._allOptions,
                    winlossData = that._winlossDataSource;
                return function() {
                    var color, index = this.index,
                        isWinloss = "winloss" === options.type,
                        target = isWinloss ? options.winlossThreshold : 0,
                        value = isWinloss ? winlossData[index][options.valueField] : this.value,
                        positiveColor = isWinloss ? options.winColor : options.barPositiveColor,
                        negativeColor = isWinloss ? options.lossColor : options.barNegativeColor;
                    if (value >= target) {
                        color = positiveColor
                    } else {
                        color = negativeColor
                    }
                    if (index === pointIndexes.first || index === pointIndexes.last) {
                        color = options.firstLastColor
                    }
                    if (index === pointIndexes.min) {
                        color = options.minColor
                    }
                    if (index === pointIndexes.max) {
                        color = options.maxColor
                    }
                    return {
                        color: color
                    }
                }
            },
            _createLineCustomizeFunction: function(pointIndexes) {
                var that = this,
                    options = that._allOptions;
                return function() {
                    var color, index = this.index;
                    if (index === pointIndexes.first || index === pointIndexes.last) {
                        color = options.firstLastColor
                    }
                    if (index === pointIndexes.min) {
                        color = options.minColor
                    }
                    if (index === pointIndexes.max) {
                        color = options.maxColor
                    }
                    return color ? {
                        visible: true,
                        border: {
                            color: color
                        }
                    } : {}
                }
            },
            _getCustomizeFunction: function() {
                var customizeFunction, that = this,
                    options = that._allOptions,
                    dataSource = that._winlossDataSource || that._simpleDataSource,
                    drawnPointIndexes = that._getExtremumPointsIndexes(dataSource);
                if ("winloss" === options.type || "bar" === options.type) {
                    customizeFunction = that._createBarCustomizeFunction(drawnPointIndexes)
                } else {
                    customizeFunction = that._createLineCustomizeFunction(drawnPointIndexes)
                }
                return customizeFunction
            },
            _getExtremumPointsIndexes: function(data) {
                var that = this,
                    options = that._allOptions,
                    lastIndex = data.length - 1,
                    indexes = {};
                that._minMaxIndexes = that._findMinMax(data);
                if (options.showFirstLast) {
                    indexes.first = 0;
                    indexes.last = lastIndex
                }
                if (options.showMinMax) {
                    indexes.min = that._minMaxIndexes.minIndex;
                    indexes.max = that._minMaxIndexes.maxIndex
                }
                return indexes
            },
            _findMinMax: function(data) {
                var value, i, that = this,
                    valField = that._allOptions.valueField,
                    firstItem = data[0] || {},
                    firstValue = firstItem[valField] || 0,
                    min = firstValue,
                    max = firstValue,
                    minIndex = 0,
                    maxIndex = 0,
                    dataLength = data.length;
                for (i = 1; i < dataLength; i++) {
                    value = data[i][valField];
                    if (value < min) {
                        min = value;
                        minIndex = i
                    }
                    if (value > max) {
                        max = value;
                        maxIndex = i
                    }
                }
                return {
                    minIndex: minIndex,
                    maxIndex: maxIndex
                }
            },
            _updateRange: function() {
                var valCoef, argCoef, that = this,
                    series = that._series,
                    type = series.type,
                    isBarType = "bar" === type,
                    isWinlossType = "winloss" === type,
                    DEFAULT_VALUE_RANGE_MARGIN = .15,
                    DEFAULT_ARGUMENT_RANGE_MARGIN = .1,
                    WINLOSS_MAX_RANGE = 1,
                    WINLOSS_MIN_RANGE = -1,
                    rangeData = series.getRangeData(),
                    minValue = that._allOptions.minValue,
                    hasMinY = _isDefined(minValue) && _isFinite(minValue),
                    maxValue = that._allOptions.maxValue,
                    hasMaxY = _isDefined(maxValue) && _isFinite(maxValue);
                valCoef = (rangeData.val.max - rangeData.val.min) * DEFAULT_VALUE_RANGE_MARGIN;
                if (isBarType || isWinlossType || "area" === type) {
                    if (0 !== rangeData.val.min) {
                        rangeData.val.min -= valCoef
                    }
                    if (0 !== rangeData.val.max) {
                        rangeData.val.max += valCoef
                    }
                } else {
                    rangeData.val.min -= valCoef;
                    rangeData.val.max += valCoef
                }
                if (hasMinY || hasMaxY) {
                    if (hasMinY && hasMaxY) {
                        rangeData.val.minVisible = _min(minValue, maxValue);
                        rangeData.val.maxVisible = _max(minValue, maxValue)
                    } else {
                        rangeData.val.minVisible = hasMinY ? _Number(minValue) : void 0;
                        rangeData.val.maxVisible = hasMaxY ? _Number(maxValue) : void 0
                    }
                    if (isWinlossType) {
                        rangeData.val.minVisible = hasMinY ? _max(rangeData.val.minVisible, WINLOSS_MIN_RANGE) : void 0;
                        rangeData.val.maxVisible = hasMaxY ? _min(rangeData.val.maxVisible, WINLOSS_MAX_RANGE) : void 0
                    }
                }
                if (series.getPoints().length > 1) {
                    if (isBarType) {
                        argCoef = (rangeData.arg.max - rangeData.arg.min) * DEFAULT_ARGUMENT_RANGE_MARGIN;
                        rangeData.arg.min = rangeData.arg.min - argCoef;
                        rangeData.arg.max = rangeData.arg.max + argCoef
                    } else {
                        rangeData.arg.stick = true
                    }
                }
                rangeData.arg.categories = that._groupsDataCategories;
                that._ranges = rangeData
            },
            _getBarWidth: function(pointsCount) {
                var that = this,
                    canvas = that._canvas,
                    intervalWidth = pointsCount * DEFAULT_BAR_INTERVAL,
                    rangeWidth = canvas.width - canvas.left - canvas.right - intervalWidth,
                    width = _round(rangeWidth / pointsCount);
                if (width < MIN_BAR_WIDTH) {
                    width = MIN_BAR_WIDTH
                }
                if (width > MAX_BAR_WIDTH) {
                    width = MAX_BAR_WIDTH
                }
                return width
            },
            _correctPoints: function() {
                var barWidth, i, that = this,
                    seriesType = that._allOptions.type,
                    seriesPoints = that._series.getPoints(),
                    pointsLength = seriesPoints.length;
                if ("bar" === seriesType || "winloss" === seriesType) {
                    barWidth = that._getBarWidth(pointsLength);
                    for (i = 0; i < pointsLength; i++) {
                        seriesPoints[i].correctCoordinates({
                            width: barWidth,
                            offset: 0
                        })
                    }
                }
            },
            _drawSeries: function() {
                var that = this;
                if (that._simpleDataSource.length > 0) {
                    that._correctPoints();
                    that._series.draw({
                        x: that._translatorX,
                        y: that._translatorY
                    });
                    that._seriesGroup.append(that._renderer.root)
                }
            },
            _isTooltipEnabled: function() {
                return !!this._simpleDataSource.length
            },
            _getTooltipData: function() {
                var that = this,
                    options = that._allOptions,
                    dataSource = that._winlossDataSource || that._simpleDataSource,
                    tooltip = that._tooltip;
                if (0 === dataSource.length) {
                    return {}
                }
                var minMax = that._minMaxIndexes,
                    valueField = options.valueField,
                    first = dataSource[0][valueField],
                    last = dataSource[dataSource.length - 1][valueField],
                    min = dataSource[minMax.minIndex][valueField],
                    max = dataSource[minMax.maxIndex][valueField],
                    formattedFirst = tooltip.formatValue(first),
                    formattedLast = tooltip.formatValue(last),
                    formattedMin = tooltip.formatValue(min),
                    formattedMax = tooltip.formatValue(max),
                    customizeObject = {
                        firstValue: formattedFirst,
                        lastValue: formattedLast,
                        minValue: formattedMin,
                        maxValue: formattedMax,
                        originalFirstValue: first,
                        originalLastValue: last,
                        originalMinValue: min,
                        originalMaxValue: max,
                        valueText: ["Start:", formattedFirst, "End:", formattedLast, "Min:", formattedMin, "Max:", formattedMax]
                    };
                if ("winloss" === options.type) {
                    customizeObject.originalThresholdValue = options.winlossThreshold;
                    customizeObject.thresholdValue = tooltip.formatValue(options.winlossThreshold)
                }
                return customizeObject
            }
        });
        _map(["lineColor", "lineWidth", "areaOpacity", "minColor", "maxColor", "barPositiveColor", "barNegativeColor", "winColor", "lessColor", "firstLastColor", "pointSymbol", "pointColor", "pointSize", "type", "argumentField", "valueField", "winlossThreshold", "showFirstLast", "showMinMax", "ignoreEmptyPoints", "minValue", "maxValue"], function(name) {
            dxSparkline.prototype._optionChangesMap[name] = "OPTIONS"
        });
        __webpack_require__( /*! ../../core/component_registrator */ 43)("dxSparkline", dxSparkline);
        module.exports = dxSparkline;
        dxSparkline.addPlugin(__webpack_require__( /*! ../core/data_source */ 493).plugin)
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/sparklines/base_sparkline.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseWidget = __webpack_require__( /*! ../core/base_widget */ 448),
            DEFAULT_LINE_SPACING = 2,
            DEFAULT_EVENTS_DELAY = 200,
            TOUCH_EVENTS_DELAY = 1e3,
            eventUtils = __webpack_require__( /*! ../../events/utils */ 62),
            wheelEvent = __webpack_require__( /*! ../../events/core/wheel */ 77),
            baseThemeManagerModule = __webpack_require__( /*! ../core/base_theme_manager */ 485),
            translator2DModule = __webpack_require__( /*! ../translators/translator2d */ 497),
            _abs = Math.abs,
            _extend = $.extend,
            _noop = $.noop;

        function generateDefaultCustomizeTooltipCallback(fontOptions, rtlEnabled) {
            var lineSpacing = fontOptions.lineSpacing,
                lineHeight = (void 0 !== lineSpacing && null !== lineSpacing ? lineSpacing : DEFAULT_LINE_SPACING) + fontOptions.size;
            return function(customizeObject) {
                var html = "",
                    vt = customizeObject.valueText;
                for (var i = 0; i < vt.length; i += 2) {
                    html += "<tr><td>" + vt[i] + "</td><td style='width: 15px'></td><td style='text-align: " + (rtlEnabled ? "left" : "right") + "'>" + vt[i + 1] + "</td></tr>"
                }
                return {
                    html: "<table style='border-spacing:0px; line-height: " + lineHeight + "px'>" + html + "</table>"
                }
            }
        }

        function generateCustomizeTooltipCallback(customizeTooltip, fontOptions, rtlEnabled) {
            var defaultCustomizeTooltip = generateDefaultCustomizeTooltipCallback(fontOptions, rtlEnabled);
            if ($.isFunction(customizeTooltip)) {
                return function(customizeObject) {
                    var res = customizeTooltip.call(customizeObject, customizeObject);
                    if (!("html" in res) && !("text" in res)) {
                        _extend(res, defaultCustomizeTooltip.call(customizeObject, customizeObject))
                    }
                    return res
                }
            } else {
                return defaultCustomizeTooltip
            }
        }
        var BaseSparkline = BaseWidget.inherit({
            _setDeprecatedOptions: function() {
                this.callBase();
                _extend(this._deprecatedOptions, {
                    "tooltip.verticalAlignment": {
                        since: "15.1",
                        message: "Now tootips are aligned automatically"
                    },
                    "tooltip.horizontalAlignment": {
                        since: "15.1",
                        message: "Now tootips are aligned automatically"
                    }
                })
            },
            _getLayoutItems: _noop,
            _useLinks: false,
            _themeDependentChanges: ["OPTIONS"],
            _initCore: function() {
                var that = this;
                that._tooltipTracker = that._renderer.root;
                that._tooltipTracker.attr({
                    "pointer-events": "visible"
                });
                that._createHtmlElements();
                that._initTooltipEvents()
            },
            _getDefaultSize: function() {
                return this._defaultSize
            },
            _disposeCore: function() {
                this._disposeWidgetElements();
                this._disposeTooltipEvents();
                this._ranges = null
            },
            _optionChangesOrder: ["OPTIONS"],
            _change_OPTIONS: function() {
                this._prepareOptions();
                this._change(["UPDATE"])
            },
            _customChangesOrder: ["UPDATE"],
            _change_UPDATE: function() {
                this._update()
            },
            _update: function() {
                var that = this;
                if (that._tooltipShown) {
                    that._tooltipShown = false;
                    that._tooltip.hide()
                }
                that._cleanWidgetElements();
                that._cleanTranslators();
                that._updateWidgetElements();
                that._drawWidgetElements()
            },
            _updateWidgetElements: function() {
                this._updateRange();
                this._updateTranslator()
            },
            _applySize: function(rect) {
                this._allOptions.size = {
                    width: rect[2] - rect[0],
                    height: rect[3] - rect[1]
                };
                this._change(["UPDATE"])
            },
            _cleanTranslators: function() {
                this._translatorX = null;
                this._translatorY = null
            },
            _setupResizeHandler: _noop,
            _prepareOptions: function() {
                return _extend(true, {}, this._themeManager.theme(), this.option())
            },
            _createThemeManager: function() {
                var themeManager = new baseThemeManagerModule.BaseThemeManager;
                themeManager._themeSection = this._widgetType;
                themeManager._fontFields = ["tooltip.font"];
                return themeManager
            },
            _getTooltipCoords: function() {
                var canvas = this._canvas,
                    rootOffset = this._renderer.getRootOffset();
                return {
                    x: canvas.width / 2 + rootOffset.left,
                    y: canvas.height / 2 + rootOffset.top
                }
            },
            _initTooltipEvents: function() {
                var that = this,
                    data = {
                        widget: that
                    };
                that._showTooltipCallback = function() {
                    var tooltip;
                    that._showTooltipTimeout = null;
                    if (!that._tooltipShown) {
                        that._tooltipShown = true;
                        tooltip = that._getTooltip();
                        tooltip.isEnabled() && that._tooltip.show(that._getTooltipData(), that._getTooltipCoords(), {})
                    }
                    that._DEBUG_showCallback && that._DEBUG_showCallback()
                };
                that._hideTooltipCallback = function() {
                    var tooltipWasShown = that._tooltipShown;
                    that._hideTooltipTimeout = null;
                    if (that._tooltipShown) {
                        that._tooltipShown = false;
                        that._tooltip.hide()
                    }
                    that._DEBUG_hideCallback && that._DEBUG_hideCallback(tooltipWasShown)
                };
                that._disposeCallbacks = function() {
                    that = that._showTooltipCallback = that._hideTooltipCallback = that._disposeCallbacks = null
                };
                that._tooltipTracker.on(mouseEvents, data).on(touchEvents, data).on(mouseWheelEvents, data);
                that._tooltipTracker.on(menuEvents)
            },
            _disposeTooltipEvents: function() {
                var that = this;
                clearTimeout(that._showTooltipTimeout);
                clearTimeout(that._hideTooltipTimeout);
                that._tooltipTracker.off();
                that._disposeCallbacks()
            },
            _updateTranslator: function() {
                var that = this,
                    canvas = this._canvas,
                    ranges = this._ranges;
                that._translatorX = new translator2DModule.Translator2D(ranges.arg, canvas, {
                    isHorizontal: true
                });
                that._translatorY = new translator2DModule.Translator2D(ranges.val, canvas)
            },
            _getTooltip: function() {
                var that = this;
                if (!that._tooltip) {
                    _initTooltip.apply(this, arguments);
                    that._setTooltipRendererOptions(that._tooltipRendererOptions);
                    that._tooltipRendererOptions = null;
                    that._setTooltipOptions()
                }
                return that._tooltip
            }
        });
        var menuEvents = {
            "contextmenu.sparkline-tooltip": function(event) {
                if (eventUtils.isTouchEvent(event) || eventUtils.isPointerEvent(event)) {
                    event.preventDefault()
                }
            },
            "MSHoldVisual.sparkline-tooltip": function(event) {
                event.preventDefault()
            }
        };
        var mouseEvents = {
            "mouseover.sparkline-tooltip": function(event) {
                isPointerDownCalled = false;
                var widget = event.data.widget;
                widget._x = event.pageX;
                widget._y = event.pageY;
                widget._tooltipTracker.off(mouseMoveEvents).on(mouseMoveEvents, event.data);
                widget._showTooltip(DEFAULT_EVENTS_DELAY)
            },
            "mouseout.sparkline-tooltip": function(event) {
                if (isPointerDownCalled) {
                    return
                }
                var widget = event.data.widget;
                widget._tooltipTracker.off(mouseMoveEvents);
                widget._hideTooltip(DEFAULT_EVENTS_DELAY)
            }
        };
        var mouseWheelEvents = {};
        mouseWheelEvents[wheelEvent.name + ".sparkline-tooltip"] = function(event) {
            event.data.widget._hideTooltip()
        };
        var mouseMoveEvents = {
            "mousemove.sparkline-tooltip": function(event) {
                var widget = event.data.widget;
                if (widget._showTooltipTimeout && (_abs(widget._x - event.pageX) > 3 || _abs(widget._y - event.pageY) > 3)) {
                    widget._x = event.pageX;
                    widget._y = event.pageY;
                    widget._showTooltip(DEFAULT_EVENTS_DELAY)
                }
            }
        };
        var active_touch_tooltip_widget = null,
            touchstartTooltipProcessing = function(event) {
                event.preventDefault();
                var widget = active_touch_tooltip_widget;
                if (widget && widget !== event.data.widget) {
                    widget._hideTooltip(DEFAULT_EVENTS_DELAY)
                }
                widget = active_touch_tooltip_widget = event.data.widget;
                widget._showTooltip(TOUCH_EVENTS_DELAY);
                widget._touch = true
            },
            touchstartDocumentProcessing = function() {
                var widget = active_touch_tooltip_widget;
                if (widget) {
                    if (!widget._touch) {
                        widget._hideTooltip(DEFAULT_EVENTS_DELAY);
                        active_touch_tooltip_widget = null
                    }
                    widget._touch = null
                }
            },
            touchendDocumentProcessing = function() {
                var widget = active_touch_tooltip_widget;
                if (widget) {
                    if (widget._showTooltipTimeout) {
                        widget._hideTooltip(DEFAULT_EVENTS_DELAY);
                        active_touch_tooltip_widget = null
                    }
                }
            },
            isPointerDownCalled = false;
        var touchEvents = {
            "pointerdown.sparkline-tooltip": touchstartTooltipProcessing,
            "touchstart.sparkline-tooltip": touchstartTooltipProcessing
        };
        $(document).on({
            "pointerdown.sparkline-tooltip": function() {
                isPointerDownCalled = true;
                touchstartDocumentProcessing()
            },
            "touchstart.sparkline-tooltip": touchstartDocumentProcessing,
            "pointerup.sparkline-tooltip": touchendDocumentProcessing,
            "touchend.sparkline-tooltip": touchendDocumentProcessing
        });
        module.exports = BaseSparkline;
        module.exports._DEBUG_reset = function() {
            active_touch_tooltip_widget = null
        };
        BaseSparkline.addPlugin(__webpack_require__( /*! ../core/tooltip */ 495).plugin);
        var _initTooltip = BaseSparkline.prototype._initTooltip;
        BaseSparkline.prototype._initTooltip = _noop;
        var _disposeTooltip = BaseSparkline.prototype._disposeTooltip;
        BaseSparkline.prototype._disposeTooltip = function() {
            if (this._tooltip) {
                _disposeTooltip.apply(this, arguments)
            }
        };
        BaseSparkline.prototype._setTooltipRendererOptions = function() {
            var options = this._getRendererOptions();
            if (this._tooltip) {
                this._tooltip.setRendererOptions(options)
            } else {
                this._tooltipRendererOptions = options
            }
        };
        BaseSparkline.prototype._setTooltipOptions = function() {
            var tooltip = this._tooltip,
                options = tooltip && this._getOption("tooltip");
            tooltip && tooltip.update(_extend({}, options, {
                customizeTooltip: generateCustomizeTooltipCallback(options.customizeTooltip, options.font, this.option("rtlEnabled")),
                enabled: options.enabled && this._isTooltipEnabled()
            }))
        };
        BaseSparkline.prototype._showTooltip = function(delay) {
            var that = this;
            ++that._DEBUG_clearHideTooltipTimeout;
            clearTimeout(that._hideTooltipTimeout);
            that._hideTooltipTimeout = null;
            clearTimeout(that._showTooltipTimeout);
            ++that._DEBUG_showTooltipTimeoutSet;
            that._showTooltipTimeout = setTimeout(that._showTooltipCallback, delay)
        };
        BaseSparkline.prototype._hideTooltip = function(delay) {
            var that = this;
            ++that._DEBUG_clearShowTooltipTimeout;
            clearTimeout(that._showTooltipTimeout);
            that._showTooltipTimeout = null;
            clearTimeout(that._hideTooltipTimeout);
            if (delay) {
                ++that._DEBUG_hideTooltipTimeoutSet;
                that._hideTooltipTimeout = setTimeout(that._hideTooltipCallback, delay)
            } else {
                that._hideTooltipCallback()
            }
        };
        var exportPlugin = $.extend(true, {}, __webpack_require__( /*! ../core/export */ 444).plugin, {
            init: _noop,
            dispose: _noop,
            customize: null,
            members: {
                _getExportMenuOptions: null
            }
        });
        BaseSparkline.addPlugin(exportPlugin)
    },
    /*!*******************************!*\
      !*** ./Scripts/viz/bullet.js ***!
      \*******************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./sparklines/bullet */ 566)
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/sparklines/bullet.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var $ = __webpack_require__( /*! jquery */ 9),
            BaseSparkline = __webpack_require__( /*! ./base_sparkline */ 564),
            TARGET_MIN_Y = .02,
            TARGET_MAX_Y = .98,
            BAR_VALUE_MIN_Y = .1,
            BAR_VALUE_MAX_Y = .9,
            DEFAULT_CANVAS_WIDTH = 300,
            DEFAULT_CANVAS_HEIGHT = 30,
            DEFAULT_HORIZONTAL_MARGIN = 1,
            DEFAULT_VERTICAL_MARGIN = 2,
            _Number = Number,
            _isFinite = isFinite;
        var dxBullet = BaseSparkline.inherit({
            _rootClassPrefix: "dxb",
            _rootClass: "dxb-bullet",
            _widgetType: "bullet",
            _defaultSize: {
                width: DEFAULT_CANVAS_WIDTH,
                height: DEFAULT_CANVAS_HEIGHT,
                left: DEFAULT_HORIZONTAL_MARGIN,
                right: DEFAULT_HORIZONTAL_MARGIN,
                top: DEFAULT_VERTICAL_MARGIN,
                bottom: DEFAULT_VERTICAL_MARGIN
            },
            _disposeWidgetElements: function() {
                delete this._zeroLevelPath;
                delete this._targetPath;
                delete this._barValuePath
            },
            _cleanWidgetElements: function() {
                this._zeroLevelPath.remove();
                this._targetPath.remove();
                this._barValuePath.remove()
            },
            _drawWidgetElements: function() {
                this._drawBullet();
                this._drawn()
            },
            _createHtmlElements: function() {
                var renderer = this._renderer;
                this._zeroLevelPath = renderer.path(void 0, "line").attr({
                    "class": "dxb-zero-level",
                    "stroke-linecap": "square"
                });
                this._targetPath = renderer.path(void 0, "line").attr({
                    "class": "dxb-target",
                    "stroke-linecap": "square"
                });
                this._barValuePath = renderer.path(void 0, "line").attr({
                    "class": "dxb-bar-value",
                    "stroke-linecap": "square"
                })
            },
            _prepareOptions: function() {
                var options, startScaleValue, endScaleValue, level, value, target, isValueUndefined, isTargetUndefined, that = this;
                that._allOptions = options = that.callBase();
                isValueUndefined = void 0 === that._allOptions.value;
                isTargetUndefined = void 0 === that._allOptions.target;
                that._tooltipEnabled = !(isValueUndefined && isTargetUndefined);
                if (isValueUndefined) {
                    that._allOptions.value = 0
                }
                if (isTargetUndefined) {
                    that._allOptions.target = 0
                }
                options.value = value = _Number(options.value);
                options.target = target = _Number(options.target);
                if (void 0 === that._allOptions.startScaleValue) {
                    that._allOptions.startScaleValue = target < value ? target : value;
                    that._allOptions.startScaleValue = that._allOptions.startScaleValue < 0 ? that._allOptions.startScaleValue : 0
                }
                if (void 0 === that._allOptions.endScaleValue) {
                    that._allOptions.endScaleValue = target > value ? target : value
                }
                options.startScaleValue = startScaleValue = _Number(options.startScaleValue);
                options.endScaleValue = endScaleValue = _Number(options.endScaleValue);
                if (endScaleValue < startScaleValue) {
                    level = endScaleValue;
                    that._allOptions.endScaleValue = startScaleValue;
                    that._allOptions.startScaleValue = level;
                    that._allOptions.inverted = true
                }
            },
            _updateRange: function() {
                var that = this,
                    options = that._allOptions;
                that._ranges = {
                    arg: {
                        invert: options.inverted,
                        min: options.startScaleValue,
                        max: options.endScaleValue,
                        axisType: "continuous",
                        dataType: "numeric"
                    },
                    val: {
                        min: 0,
                        max: 1,
                        axisType: "continuous",
                        dataType: "numeric"
                    }
                }
            },
            _drawBullet: function() {
                var that = this,
                    options = that._allOptions,
                    isValidBounds = options.startScaleValue !== options.endScaleValue,
                    isValidMin = _isFinite(options.startScaleValue),
                    isValidMax = _isFinite(options.endScaleValue),
                    isValidValue = _isFinite(options.value),
                    isValidTarget = _isFinite(options.target);
                if (isValidBounds && isValidMax && isValidMin && isValidTarget && isValidValue) {
                    this._drawBarValue();
                    this._drawTarget();
                    this._drawZeroLevel()
                }
            },
            _getTargetParams: function() {
                var that = this,
                    options = that._allOptions,
                    translatorY = that._translatorY,
                    x = that._translatorX.translate(options.target);
                return {
                    points: [x, translatorY.translate(TARGET_MIN_Y), x, translatorY.translate(TARGET_MAX_Y)],
                    stroke: options.targetColor,
                    "stroke-width": options.targetWidth
                }
            },
            _getBarValueParams: function() {
                var x1, x2, that = this,
                    options = that._allOptions,
                    translatorX = that._translatorX,
                    translatorY = that._translatorY,
                    startLevel = options.startScaleValue,
                    endLevel = options.endScaleValue,
                    value = options.value,
                    y2 = translatorY.translate(BAR_VALUE_MIN_Y),
                    y1 = translatorY.translate(BAR_VALUE_MAX_Y);
                if (value > 0) {
                    x1 = startLevel <= 0 ? 0 : startLevel;
                    x2 = value >= endLevel ? endLevel : value < x1 ? x1 : value
                } else {
                    x1 = endLevel >= 0 ? 0 : endLevel;
                    x2 = value < startLevel ? startLevel : value > x1 ? x1 : value
                }
                x1 = translatorX.translate(x1);
                x2 = translatorX.translate(x2);
                return {
                    points: [x1, y1, x2, y1, x2, y2, x1, y2],
                    fill: options.color
                }
            },
            _getZeroLevelParams: function() {
                var that = this,
                    translatorY = that._translatorY,
                    x = that._translatorX.translate(0);
                return {
                    points: [x, translatorY.translate(TARGET_MIN_Y), x, translatorY.translate(TARGET_MAX_Y)],
                    stroke: that._allOptions.targetColor,
                    "stroke-width": 1
                }
            },
            _drawZeroLevel: function() {
                var that = this,
                    options = that._allOptions;
                if (0 > options.endScaleValue || 0 < options.startScaleValue || !options.showZeroLevel) {
                    return
                }
                that._zeroLevelPath.attr(that._getZeroLevelParams()).sharp().append(that._renderer.root)
            },
            _drawTarget: function() {
                var that = this,
                    options = that._allOptions,
                    target = options.target;
                if (target > options.endScaleValue || target < options.startScaleValue || !options.showTarget) {
                    return
                }
                that._targetPath.attr(that._getTargetParams()).sharp().append(that._renderer.root)
            },
            _drawBarValue: function() {
                this._barValuePath.attr(this._getBarValueParams()).append(this._renderer.root)
            },
            _getTooltipCoords: function() {
                var canvas = this._canvas,
                    rootOffset = this._renderer.getRootOffset(),
                    bbox = this._barValuePath.getBBox();
                return {
                    x: bbox.x + bbox.width / 2 + rootOffset.left,
                    y: canvas.height / 2 + rootOffset.top
                }
            },
            _getTooltipData: function() {
                var that = this,
                    tooltip = that._tooltip,
                    options = that._allOptions,
                    value = options.value,
                    target = options.target,
                    valueText = tooltip.formatValue(value),
                    targetText = tooltip.formatValue(target);
                return {
                    originalValue: value,
                    originalTarget: target,
                    value: valueText,
                    target: targetText,
                    valueText: ["Actual Value:", valueText, "Target Value:", targetText]
                }
            },
            _isTooltipEnabled: function() {
                return this._tooltipEnabled
            }
        });
        $.each(["color", "targetColor", "targetWidth", "showTarget", "showZeroLevel", "value", "target", "startScaleValue", "endScaleValue"], function(_, name) {
            dxBullet.prototype._optionChangesMap[name] = "OPTIONS"
        });
        __webpack_require__( /*! ../../core/component_registrator */ 43)("dxBullet", dxBullet);
        module.exports = dxBullet
    },
    /*!*********************************!*\
      !*** ./Scripts/viz/tree_map.js ***!
      \*********************************/
    function(module, exports, __webpack_require__) {
        module.exports = __webpack_require__( /*! ./tree_map/tree_map */ 568)
    },
    /*!******************************************!*\
      !*** ./Scripts/viz/tree_map/tree_map.js ***!
      \******************************************/
    function(module, exports, __webpack_require__) {
        var dxTreeMap = module.exports = __webpack_require__( /*! ./tree_map.base */ 569);
        __webpack_require__( /*! ./tiling.squarified */ 574);
        __webpack_require__( /*! ./tiling.strip */ 577);
        __webpack_require__( /*! ./tiling.slice_and_dice */ 578);
        __webpack_require__( /*! ./colorizing.discrete */ 576);
        __webpack_require__( /*! ./colorizing.gradient */ 579);
        __webpack_require__( /*! ./colorizing.range */ 580);
        __webpack_require__( /*! ./api */ 581);
        __webpack_require__( /*! ./hover */ 582);
        __webpack_require__( /*! ./selection */ 584);
        __webpack_require__( /*! ./tooltip */ 585);
        __webpack_require__( /*! ./tracker */ 586);
        __webpack_require__( /*! ./drilldown */ 587);
        __webpack_require__( /*! ./plain_data_source */ 588);
        dxTreeMap.addPlugin(__webpack_require__( /*! ../core/export */ 444).plugin);
        dxTreeMap.addPlugin(__webpack_require__( /*! ../core/title */ 494).plugin);
        dxTreeMap.addPlugin(__webpack_require__( /*! ../core/loading_indicator */ 496).plugin)
    },
    /*!***********************************************!*\
      !*** ./Scripts/viz/tree_map/tree_map.base.js ***!
      \***********************************************/
    function(module, exports, __webpack_require__) {
        var common = __webpack_require__( /*! ./common */ 570),
            Node = __webpack_require__( /*! ./node */ 571),
            _getTilingAlgorithm = __webpack_require__( /*! ./tiling */ 572).getAlgorithm,
            _getColorizer = __webpack_require__( /*! ./colorizing */ 573).getColorizer,
            _patchFontOptions = __webpack_require__( /*! ../core/utils */ 442).patchFontOptions,
            _buildRectAppearance = common.buildRectAppearance,
            _buildTextAppearance = common.buildTextAppearance,
            _noop = __webpack_require__( /*! jquery */ 9).noop,
            _max = Math.max,
            directions = {
                lefttoprightbottom: [1, 1],
                leftbottomrighttop: [1, -1],
                righttopleftbottom: [-1, 1],
                rightbottomlefttop: [-1, -1]
            };
        __webpack_require__( /*! ./tiling.squarified */ 574);
        __webpack_require__( /*! ./tiling */ 572).setDefaultAlgorithm("squarified");
        __webpack_require__( /*! ./colorizing.discrete */ 576);
        __webpack_require__( /*! ./colorizing */ 573).setDefaultColorizer("discrete");

        function pickPositiveInteger(val) {
            return val > 0 ? Math.round(val) : 0
        }
        var dxTreeMap = __webpack_require__( /*! ../core/base_widget */ 448).inherit({
            _handlers: {
                beginBuildNodes: _noop,
                buildNode: _noop,
                endBuildNodes: _noop,
                setTrackerData: _noop,
                calculateState: function(options) {
                    return _buildRectAppearance(options)
                }
            },
            _rootClass: "dxtm-tree-map",
            _rootClassPrefix: "dxtm",
            _getDefaultSize: function() {
                return {
                    width: 400,
                    height: 400
                }
            },
            _createThemeManager: function() {
                return new ThemeManager
            },
            _init: function() {
                var that = this;
                that._rectOffsets = {};
                that._context = {
                    suspend: function() {
                        if (!that._applyingChanges) {
                            that._suspendChanges()
                        }
                    },
                    resume: function() {
                        if (!that._applyingChanges) {
                            that._resumeChanges()
                        }
                    },
                    change: function(codes) {
                        that._change(codes)
                    },
                    settings: [{}, {}],
                    calculateState: that._handlers.calculateState,
                    calculateLabelState: _buildTextAppearance
                };
                that._root = that._topNode = {
                    nodes: []
                };
                that.callBase.apply(that, arguments)
            },
            _initialChanges: ["DATA_SOURCE"],
            _initCore: function() {
                var that = this,
                    renderer = that._renderer;
                that._createProxyType();
                that._tilesGroup = renderer.g().linkOn(renderer.root, "tiles").linkAppend();
                that._labelsGroup = renderer.g().attr({
                    align: "left"
                }).linkOn(renderer.root, "labels").linkAppend()
            },
            _createProxyType: _noop,
            _disposeCore: function() {
                var that = this;
                that._filter && that._filter.dispose();
                that._labelsGroup.linkOff();
                that._tilesGroup.linkOff()
            },
            _applySize: function(rect) {
                this._tilingRect = rect.slice();
                this._change(["TILING"])
            },
            _optionChangesMap: {
                dataSource: "DATA_SOURCE",
                valueField: "NODES_CREATE",
                childrenField: "NODES_CREATE",
                colorField: "TILES",
                colorizer: "TILES",
                labelField: "LABELS",
                tile: "TILE_SETTINGS",
                group: "GROUP_SETTINGS",
                maxDepth: "MAX_DEPTH",
                layoutAlgorithm: "TILING",
                layoutDirection: "TILING"
            },
            _themeDependentChanges: ["TILE_SETTINGS", "GROUP_SETTINGS", "MAX_DEPTH"],
            _changeDataSource: function() {
                var that = this;
                that._isDataExpected = that._isSyncData = true;
                that._updateDataSource();
                that._isSyncData = false;
                if (that._isDataExpected) {
                    that._suspendChanges()
                }
            },
            _dataSourceChangedHandler: function() {
                var that = this;
                if (that._isDataExpected) {
                    that._isDataExpected = false;
                    that._change(["NODES_CREATE"]);
                    if (!that._isSyncData) {
                        that._resumeChanges()
                    }
                } else {
                    that._requestChange(["NODES_CREATE"])
                }
            },
            _optionChangesOrder: ["DATA_SOURCE", "TILE_SETTINGS", "GROUP_SETTINGS", "MAX_DEPTH"],
            _change_DATA_SOURCE: function() {
                this._changeDataSource()
            },
            _change_TILE_SETTINGS: function() {
                this._changeTileSettings()
            },
            _change_GROUP_SETTINGS: function() {
                this._changeGroupSettings()
            },
            _change_MAX_DEPTH: function() {
                this._changeMaxDepth()
            },
            _customChangesOrder: ["NODES_CREATE", "NODES_RESET", "TILES", "LABELS", "TILING", "LABELS_LAYOUT"],
            _change_NODES_CREATE: function() {
                this._buildNodes()
            },
            _change_NODES_RESET: function() {
                this._resetNodes()
            },
            _change_TILES: function() {
                this._applyTilesAppearance()
            },
            _change_LABELS: function() {
                this._applyLabelsAppearance()
            },
            _change_TILING: function() {
                this._performTiling()
            },
            _change_LABELS_LAYOUT: function() {
                this._performLabelsLayout()
            },
            _applyChanges: function() {
                var that = this;
                that.callBase.apply(that, arguments);
                if (!that._isDataExpected) {
                    that._drawn()
                }
                that._context.forceReset = false
            },
            _buildNodes: function() {
                var processedData, that = this,
                    root = that._root = that._topNode = new Node;
                root._id = 0;
                root.parent = {};
                root.data = {};
                root.level = root.index = -1;
                root.ctx = that._context;
                root.label = null;
                that._nodes = [root];
                that._handlers.beginBuildNodes();
                processedData = that._processDataSourceItems(that._dataSource.items() || []);
                traverseDataItems(root, processedData.items, 0, {
                    itemsField: !processedData.isPlain && that._getOption("childrenField", true) || "items",
                    valueField: that._getOption("valueField", true) || "value",
                    buildNode: that._handlers.buildNode,
                    ctx: that._context,
                    nodes: that._nodes
                });
                that._onNodesCreated();
                that._handlers.endBuildNodes();
                that._change(["NODES_RESET"])
            },
            _onNodesCreated: common.empty,
            _processDataSourceItems: function(items) {
                return {
                    items: items,
                    isPlain: false
                }
            },
            _changeTileSettings: function() {
                var that = this,
                    options = that._getOption("tile"),
                    offsets = that._rectOffsets,
                    borderWidth = pickPositiveInteger(options.border.width),
                    edgeOffset = borderWidth / 2,
                    innerOffset = 1 & borderWidth ? .5 : 0,
                    labelOptions = options.label,
                    settings = that._context.settings[0];
                that._change(["TILES", "LABELS"]);
                settings.state = that._handlers.calculateState(options);
                that._filter = that._filter || that._renderer.shadowFilter("-50%", "-50%", "200%", "200%");
                that._filter.attr(labelOptions.shadow);
                that._calculateLabelSettings(settings, labelOptions, that._filter.ref);
                if (offsets.tileEdge !== edgeOffset || offsets.tileInner !== innerOffset) {
                    offsets.tileEdge = edgeOffset;
                    offsets.tileInner = innerOffset;
                    that._change(["TILING"])
                }
            },
            _changeGroupSettings: function() {
                var that = this,
                    options = that._getOption("group"),
                    labelOptions = options.label,
                    offsets = that._rectOffsets,
                    borderWidth = pickPositiveInteger(options.border.width),
                    edgeOffset = borderWidth / 2,
                    innerOffset = 1 & borderWidth ? .5 : 0,
                    headerHeight = 0,
                    groupPadding = pickPositiveInteger(options.padding),
                    settings = that._context.settings[1];
                that._change(["TILES", "LABELS"]);
                settings.state = that._handlers.calculateState(options);
                that._calculateLabelSettings(settings, labelOptions);
                if (options.headerHeight >= 0) {
                    headerHeight = pickPositiveInteger(options.headerHeight)
                } else {
                    headerHeight = settings.labelParams.height + 2 * pickPositiveInteger(labelOptions.paddingTopBottom)
                }
                if (that._headerHeight !== headerHeight) {
                    that._headerHeight = headerHeight;
                    that._change(["TILING"])
                }
                if (that._groupPadding !== groupPadding) {
                    that._groupPadding = groupPadding;
                    that._change(["TILING"])
                }
                if (offsets.headerEdge !== edgeOffset || offsets.headerInner !== innerOffset) {
                    offsets.headerEdge = edgeOffset;
                    offsets.headerInner = innerOffset;
                    that._change(["TILING"])
                }
            },
            _calculateLabelSettings: function(settings, options, filter) {
                var bbox = this._getTextBBox(options.font),
                    paddingLeftRight = pickPositiveInteger(options.paddingLeftRight),
                    paddingTopBottom = pickPositiveInteger(options.paddingTopBottom);
                settings.labelState = _buildTextAppearance(options, filter);
                settings.labelState.visible = !("visible" in options) || !!options.visible;
                settings.labelParams = {
                    unitWidth: bbox.width,
                    height: bbox.height,
                    hOffset: paddingLeftRight,
                    vOffset: -bbox.y + paddingTopBottom,
                    rtlEnabled: this._getOption("rtlEnabled", true),
                    paddingTopBottom: paddingTopBottom,
                    paddingLeftRight: paddingLeftRight
                }
            },
            _changeMaxDepth: function() {
                var maxDepth = this._getOption("maxDepth", true);
                maxDepth = maxDepth >= 1 ? Math.round(maxDepth) : 1 / 0;
                if (this._maxDepth !== maxDepth) {
                    this._maxDepth = maxDepth;
                    this._change(["NODES_RESET"])
                }
            },
            _resetNodes: function() {
                var that = this;
                that._tilesGroup.clear();
                that._renderer.initHatching();
                that._context.forceReset = true;
                that._context.minLevel = that._topNode.level + 1;
                that._context.maxLevel = that._context.minLevel + that._maxDepth - 1;
                that._change(["TILES", "LABELS", "TILING"])
            },
            _processNodes: function(context, process) {
                processNodes(context, this._topNode, process)
            },
            _applyTilesAppearance: function() {
                var that = this,
                    colorizer = _getColorizer(that._getOption("colorizer"), that._themeManager, that._topNode);
                that._processNodes({
                    renderer: that._renderer,
                    group: that._tilesGroup,
                    setTrackerData: that._handlers.setTrackerData,
                    colorField: that._getOption("colorField", true) || "color",
                    getColor: colorizer
                }, processTileAppearance)
            },
            _applyLabelsAppearance: function() {
                var that = this;
                that._labelsGroup.clear();
                that._processNodes({
                    renderer: that._renderer,
                    group: that._labelsGroup,
                    setTrackerData: that._handlers.setTrackerData,
                    labelField: that._getOption("labelField", true) || "name"
                }, processLabelAppearance);
                that._change(["LABELS_LAYOUT"])
            },
            _performTiling: function() {
                var that = this,
                    context = {
                        algorithm: _getTilingAlgorithm(that._getOption("layoutAlgorithm", true)),
                        directions: directions[String(that._getOption("layoutDirection", true)).toLowerCase()] || directions.lefttoprightbottom,
                        headerHeight: that._headerHeight,
                        groupPadding: that._groupPadding,
                        rectOffsets: that._rectOffsets
                    };
                that._topNode.innerRect = that._tilingRect;
                calculateRects(context, that._topNode);
                that._processNodes(context, processTiling);
                that._change(["LABELS_LAYOUT"]);
                that._onTilingPerformed()
            },
            _onTilingPerformed: common.empty,
            _performLabelsLayout: function() {
                this._processNodes(null, processLabelsLayout)
            },
            _getTextBBox: function(fontOptions) {
                var bbox, renderer = this._renderer,
                    text = this._textForCalculations || renderer.text("0", 0, 0);
                this._textForCalculations = text;
                text.css(_patchFontOptions(fontOptions)).append(renderer.root);
                bbox = text.getBBox();
                text.remove();
                return bbox
            }
        });

        function traverseDataItems(root, dataItems, level, params) {
            var node, i, dataItem, items, nodes = [],
                allNodes = params.nodes,
                ii = dataItems.length,
                totalValue = 0;
            for (i = 0; i < ii; ++i) {
                dataItem = dataItems[i];
                node = new Node;
                node._id = allNodes.length;
                node.ctx = params.ctx;
                node.parent = root;
                node.level = level;
                node.index = nodes.length;
                node.data = dataItem;
                params.buildNode(node);
                allNodes.push(node);
                nodes.push(node);
                items = dataItem[params.itemsField];
                if (items && items.length) {
                    traverseDataItems(node, items, level + 1, params)
                }
                if (dataItem[params.valueField] > 0) {
                    node.value = Number(dataItem[params.valueField])
                }
                totalValue += node.value
            }
            root.nodes = nodes;
            root.value = totalValue
        }

        function processNodes(context, root, process) {
            var node, i, nodes = root.nodes,
                ii = nodes.length;
            for (i = 0; i < ii; ++i) {
                node = nodes[i];
                process(context, node);
                if (node.isNode()) {
                    processNodes(context, node, process)
                }
            }
        }

        function processTileAppearance(context, node) {
            node.color = node.data[context.colorField] || context.getColor(node) || node.parent.color;
            node.updateStyles();
            node.tile = !node.ctx.forceReset && node.tile || createTile[Number(node.isNode())](context, node);
            node.applyState()
        }
        var createTile = [createLeaf, createGroup];

        function createLeaf(context, node) {
            var tile = context.renderer.simpleRect().append(context.group);
            context.setTrackerData(node, tile);
            return tile
        }

        function createGroup(context, node) {
            var outer = context.renderer.simpleRect().append(context.group),
                inner = context.renderer.simpleRect().append(context.group);
            context.setTrackerData(node, inner);
            return {
                outer: outer,
                inner: inner
            }
        }

        function processLabelAppearance(context, node) {
            node.updateLabelStyle();
            if (node.labelState.visible) {
                createLabel(context, node, node.labelState, node.labelParams)
            }
        }

        function createLabel(context, currentNode, settings, params) {
            var textData = currentNode.data[context.labelField];
            currentNode.label = textData ? String(textData) : null;
            textData = currentNode.customLabel || currentNode.label;
            if (textData) {
                currentNode.text = context.renderer.text(textData).attr(settings.attr).css(settings.css).append(context.group);
                context.setTrackerData(currentNode, currentNode.text);
                currentNode.textWidth = params.unitWidth * textData.length
            }
        }
        var emptyRect = [0, 0, 0, 0];

        function calculateRects(context, root) {
            var i, nodes = root.nodes,
                items = [],
                rects = [],
                sum = 0,
                ii = items.length = rects.length = nodes.length;
            for (i = 0; i < ii; ++i) {
                sum += nodes[i].value;
                items[i] = {
                    value: nodes[i].value,
                    i: i
                }
            }
            if (sum > 0) {
                context.algorithm({
                    items: items.slice(),
                    sum: sum,
                    rect: root.innerRect.slice(),
                    isRotated: 1 & nodes[0].level,
                    directions: context.directions
                })
            }
            for (i = 0; i < ii; ++i) {
                rects[i] = items[i].rect || emptyRect
            }
            root.rects = rects
        }

        function processTiling(context, node) {
            var headerHeight, rect = node.parent.rects[node.index],
                rectOffsets = context.rectOffsets;
            if (node.isNode()) {
                setRectAttrs(node.tile.outer, buildTileRect(rect, node.parent.innerRect, rectOffsets.headerEdge, rectOffsets.headerInner));
                rect = marginateRect(rect, context.groupPadding);
                headerHeight = Math.min(context.headerHeight, rect[3] - rect[1]);
                node.rect = [rect[0], rect[1], rect[2], rect[1] + headerHeight];
                setRectAttrs(node.tile.inner, marginateRect(node.rect, rectOffsets.headerEdge));
                rect[1] += headerHeight;
                node.innerRect = rect;
                calculateRects(context, node)
            } else {
                node.rect = rect;
                setRectAttrs(node.tile, buildTileRect(rect, node.parent.innerRect, rectOffsets.tileEdge, rectOffsets.tileInner))
            }
        }

        function marginateRect(rect, margin) {
            return [rect[0] + margin, rect[1] + margin, rect[2] - margin, rect[3] - margin]
        }

        function buildTileRect(rect, outer, edgeOffset, innerOffset) {
            return [rect[0] + (rect[0] === outer[0] ? edgeOffset : +innerOffset), rect[1] + (rect[1] === outer[1] ? edgeOffset : +innerOffset), rect[2] - (rect[2] === outer[2] ? edgeOffset : -innerOffset), rect[3] - (rect[3] === outer[3] ? edgeOffset : -innerOffset)]
        }

        function setRectAttrs(element, rect) {
            element.attr({
                x: rect[0],
                y: rect[1],
                width: _max(rect[2] - rect[0], 0),
                height: _max(rect[3] - rect[1], 0)
            })
        }

        function processLabelsLayout(context, node) {
            if (node.text && node.labelState.visible) {
                layoutTextNode(node, node.labelParams)
            }
        }

        function layoutTextNode(node, params) {
            var rect = node.rect,
                hOffset = params.hOffset;
            node.text.attr({
                x: params.rtlEnabled ? rect[2] - hOffset : rect[0] + hOffset,
                y: rect[1] + params.vOffset,
                visibility: node.textWidth + params.paddingLeftRight < rect[2] - rect[0] && params.height + params.paddingTopBottom < rect[3] - rect[1] ? "visible" : "hidden"
            })
        }
        var ThemeManager = __webpack_require__( /*! ../core/base_theme_manager */ 485).BaseThemeManager.inherit({
            _themeSection: "treeMap",
            _fontFields: ["tile.label.font", "group.label.font", "loadingIndicator.font", "title.font", "title.subtitle.font", "tooltip.font"]
        });
        __webpack_require__( /*! ../../core/component_registrator */ 43)("dxTreeMap", dxTreeMap);
        module.exports = dxTreeMap;
        dxTreeMap.addPlugin(__webpack_require__( /*! ../core/data_source */ 493).plugin)
    },
    /*!****************************************!*\
      !*** ./Scripts/viz/tree_map/common.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var _patchFontOptions = __webpack_require__( /*! ../core/utils */ 442).patchFontOptions;

        function empty() {}
        exports.empty = empty;

        function createChainExecutor() {
            var chain = [];
            executeChain.add = function(item) {
                chain.push(item)
            };
            return executeChain;

            function executeChain() {
                var i, ii = chain.length;
                for (i = 0; i < ii; ++i) {
                    chain[i].apply(this, arguments)
                }
            }
        }
        exports.expand = function(target, name, expander) {
            var current = target[name];
            if (current.add) {
                current.add(expander)
            } else {
                if (current === empty) {
                    current = expander
                } else {
                    current = createChainExecutor();
                    current.add(target[name]);
                    current.add(expander)
                }
            }
            target[name] = current
        };
        exports.buildRectAppearance = function(option) {
            var border = option.border || {};
            return {
                fill: option.color,
                opacity: option.opacity,
                stroke: border.color,
                "stroke-width": border.width,
                "stroke-opacity": border.opacity,
                hatching: option.hatching
            }
        };
        exports.buildTextAppearance = function(options, filter) {
            return {
                attr: options["stroke-width"] ? {
                    stroke: options.stroke,
                    "stroke-width": options["stroke-width"],
                    "stroke-opacity": options["stroke-opacity"],
                    filter: filter
                } : {},
                css: _patchFontOptions(options.font)
            }
        }
    },
    /*!**************************************!*\
      !*** ./Scripts/viz/tree_map/node.js ***!
      \**************************************/
    function(module, exports, __webpack_require__) {
        var _extend = __webpack_require__( /*! jquery */ 9).extend;

        function Node() {}
        _extend(Node.prototype, {
            value: 0,
            isNode: function() {
                return !!(this.nodes && this.level < this.ctx.maxLevel)
            },
            isActive: function() {
                var ctx = this.ctx;
                return this.level >= ctx.minLevel && this.level <= ctx.maxLevel
            },
            updateStyles: function() {
                var that = this,
                    isNode = Number(that.isNode());
                that.state = that._buildState(that.ctx.settings[isNode].state, !isNode && that.color && {
                    fill: that.color
                })
            },
            _buildState: function(state, extra) {
                var base = _extend({}, state);
                return extra ? _extend(base, extra) : base
            },
            updateLabelStyle: function() {
                var settings = this.ctx.settings[Number(this.isNode())];
                this.labelState = settings.labelState;
                this.labelParams = settings.labelParams
            },
            _getState: function() {
                return this.state
            },
            applyState: function() {
                updateTile[Number(this.isNode())](this.tile, this._getState())
            }
        });
        var updateTile = [updateLeaf, updateGroup];

        function updateLeaf(content, attrs) {
            content.smartAttr(attrs)
        }

        function updateGroup(content, attrs) {
            content.outer.attr({
                stroke: attrs.stroke,
                "stroke-width": attrs["stroke-width"],
                "stroke-opacity": attrs["stroke-opacity"]
            });
            content.inner.smartAttr({
                fill: attrs.fill,
                opacity: attrs.opacity,
                hatching: attrs.hatching
            })
        }
        module.exports = Node
    },
    /*!****************************************!*\
      !*** ./Scripts/viz/tree_map/tiling.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var defaultAlgorithm, _isFunction = __webpack_require__( /*! ../../core/utils/common */ 14).isFunction,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            _round = Math.round,
            algorithms = {};
        exports.getAlgorithm = function(value) {
            return algorithms[_normalizeEnum(value)] || _isFunction(value) && value || defaultAlgorithm
        };
        exports.addAlgorithm = function(name, callback) {
            algorithms[name] = callback
        };
        exports.setDefaultAlgorithm = function(name) {
            defaultAlgorithm = algorithms[name]
        };
        var directionToIndexOffsets = {};
        directionToIndexOffsets[-1] = [2, 0];
        directionToIndexOffsets[1] = [0, 2];
        exports.buildSidesData = function(rect, directions, _staticSideIndex) {
            var sides = [rect[2] - rect[0], rect[3] - rect[1]],
                staticSideIndex = void 0 !== _staticSideIndex ? _staticSideIndex : sides[0] < sides[1] ? 0 : 1,
                variedSideIndex = 1 - staticSideIndex,
                staticSideDirection = directions[staticSideIndex],
                variedSideDirection = directions[variedSideIndex],
                staticSideIndexOffsets = directionToIndexOffsets[staticSideDirection],
                variedSideIndexOffsets = directionToIndexOffsets[variedSideDirection];
            return {
                staticSide: sides[staticSideIndex],
                variedSide: sides[variedSideIndex],
                static1: staticSideIndex + staticSideIndexOffsets[0],
                static2: staticSideIndex + staticSideIndexOffsets[1],
                varied1: variedSideIndex + variedSideIndexOffsets[0],
                varied2: variedSideIndex + variedSideIndexOffsets[1],
                staticDir: staticSideDirection,
                variedDir: variedSideDirection
            }
        };
        exports.calculateRectangles = function(nodes, head, totalRect, sidesData, rowData) {
            var i, ii, rect, delta, variedSidePart = [0, 0, 0, 0],
                static1 = sidesData.static1,
                static2 = sidesData.static2,
                position = totalRect[static1],
                dir = sidesData.staticDir,
                side = sidesData.staticSide,
                sum = rowData.sum;
            variedSidePart[sidesData.varied1] = totalRect[sidesData.varied1];
            variedSidePart[sidesData.varied2] = totalRect[sidesData.varied1] + sidesData.variedDir * rowData.side;
            for (i = head, ii = head + rowData.count; i < ii; ++i) {
                rect = variedSidePart.slice();
                rect[static1] = position;
                delta = _round(side * nodes[i].value / sum) || 0;
                sum -= nodes[i].value;
                side -= delta;
                position += dir * delta;
                rect[static2] = position;
                nodes[i].rect = rect
            }
            totalRect[sidesData.varied1] = variedSidePart[sidesData.varied2]
        }
    },
    /*!********************************************!*\
      !*** ./Scripts/viz/tree_map/colorizing.js ***!
      \********************************************/
    function(module, exports, __webpack_require__) {
        var defaultColorizerName, _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            _noop = __webpack_require__( /*! jquery */ 9).noop,
            colorizers = {};

        function wrapLeafColorGetter(getter) {
            return function(node) {
                return !node.isNode() ? getter(node) : void 0
            }
        }

        function wrapGroupColorGetter(getter) {
            return function(node) {
                var parent = !node.isNode() && node.parent;
                return parent ? parent._groupColor = parent._groupColor || getter(parent) : void 0
            }
        }
        exports.getColorizer = function(options, themeManager, root) {
            var type = _normalizeEnum(options.type || defaultColorizerName),
                colorizer = colorizers[type] && colorizers[type](options, themeManager, root);
            return colorizer ? (options.colorizeGroups ? wrapGroupColorGetter : wrapLeafColorGetter)(colorizer) : _noop
        };
        exports.addColorizer = function(name, colorizer) {
            colorizers[name] = colorizer
        };
        exports.setDefaultColorizer = function(name) {
            defaultColorizerName = name
        };

        function getValueAsColorCode(node) {
            return node.value
        }

        function createColorCodeGetter(colorCodeField) {
            return function(node) {
                return Number(node.data[colorCodeField])
            }
        }
        exports.createColorCodeGetter = function(options) {
            return options.colorCodeField ? createColorCodeGetter(options.colorCodeField) : getValueAsColorCode
        }
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/tree_map/tiling.squarified.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var _max = Math.max,
            _squarify = __webpack_require__( /*! ./tiling.squarified.base */ 575);

        function accumulate(total, current) {
            return _max(total, current)
        }

        function squarified(data) {
            return _squarify(data, accumulate, false)
        }
        __webpack_require__( /*! ./tiling */ 572).addAlgorithm("squarified", squarified);
        module.exports = squarified
    },
    /*!********************************************************!*\
      !*** ./Scripts/viz/tree_map/tiling.squarified.base.js ***!
      \********************************************************/
    function(module, exports, __webpack_require__) {
        var _max = Math.max,
            _round = Math.round,
            _calculateRectangles = __webpack_require__( /*! ./tiling */ 572).calculateRectangles,
            _buildSidesData = __webpack_require__( /*! ./tiling */ 572).buildSidesData;

        function compare(a, b) {
            return b.value - a.value
        }

        function getAspectRatio(value) {
            return _max(value, 1 / value)
        }

        function findAppropriateCollection(nodes, head, context) {
            var nextAspectRatio, nextSum, i, j, totalAspectRatio, bestAspectRatio = 1 / 0,
                sum = 0,
                ii = nodes.length,
                coeff = context.areaToValue / context.staticSide;
            for (i = head; i < ii;) {
                nextSum = sum + nodes[i].value;
                totalAspectRatio = context.staticSide / coeff / nextSum;
                nextAspectRatio = 0;
                for (j = head; j <= i; ++j) {
                    nextAspectRatio = context.accumulate(nextAspectRatio, getAspectRatio(totalAspectRatio * nodes[j].value / nextSum), j - head + 1)
                }
                if (nextAspectRatio < bestAspectRatio) {
                    bestAspectRatio = nextAspectRatio;
                    sum = nextSum;
                    ++i
                } else {
                    break
                }
            }
            return {
                sum: sum,
                count: i - head,
                side: _round(coeff * sum)
            }
        }

        function getArea(rect) {
            return (rect[2] - rect[0]) * (rect[3] - rect[1])
        }

        function doStep(nodes, head, context) {
            var sidesData = context.sides || _buildSidesData(context.rect, context.directions),
                rowData = sidesData.staticSide > 0 ? findAppropriateCollection(nodes, head, {
                    areaToValue: getArea(context.rect) / context.sum,
                    accumulate: context.accumulate,
                    staticSide: sidesData.staticSide
                }) : {
                    sum: 1,
                    side: sidesData.variedSide,
                    count: nodes.length - head
                };
            _calculateRectangles(nodes, head, context.rect, sidesData, rowData);
            context.sum -= rowData.sum;
            return head + rowData.count
        }
        module.exports = function(data, accumulate, isFixedStaticSide) {
            var i, items = data.items,
                ii = items.length,
                context = {
                    sum: data.sum,
                    rect: data.rect,
                    directions: data.directions,
                    accumulate: accumulate
                };
            if (isFixedStaticSide) {
                context.sides = _buildSidesData(context.rect, context.directions)
            }
            items.sort(compare);
            for (i = 0; i < ii;) {
                i = doStep(items, i, context)
            }
        }
    },
    /*!*****************************************************!*\
      !*** ./Scripts/viz/tree_map/colorizing.discrete.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        function discreteColorizer(options, themeManager, root) {
            var palette = themeManager.createPalette(options.palette, {
                useHighlight: true
            });
            return (options.colorizeGroups ? discreteGroupColorizer : discreteLeafColorizer)(palette, root)
        }

        function generateColors(palette, colors, count) {
            var i;
            for (i = colors.length; i < count; ++i) {
                colors.push(palette.getNextColor())
            }
        }

        function discreteLeafColorizer(palette) {
            var colors = [];
            generateColors(palette, colors, 4);
            return function(node) {
                if (node.index >= colors.length) {
                    generateColors(palette, colors, 2 * colors.length)
                }
                return colors[node.index]
            }
        }

        function prepareDiscreteGroupColors(palette, root) {
            var i, node, colors = {},
                allNodes = root.nodes.slice(),
                ii = allNodes.length;
            for (i = 0; i < ii; ++i) {
                node = allNodes[i];
                if (node.isNode()) {
                    allNodes = allNodes.concat(node.nodes);
                    ii = allNodes.length
                } else {
                    if (!colors[node.parent._id]) {
                        colors[node.parent._id] = palette.getNextColor()
                    }
                }
            }
            return colors
        }

        function discreteGroupColorizer(palette, root) {
            var colors = prepareDiscreteGroupColors(palette, root);
            return function(node) {
                return colors[node._id]
            }
        }
        __webpack_require__( /*! ./colorizing */ 573).addColorizer("discrete", discreteColorizer);
        module.exports = discreteColorizer
    },
    /*!**********************************************!*\
      !*** ./Scripts/viz/tree_map/tiling.strip.js ***!
      \**********************************************/
    function(module, exports, __webpack_require__) {
        var _squarify = __webpack_require__( /*! ./tiling.squarified.base */ 575);

        function accumulate(total, current, count) {
            return ((count - 1) * total + current) / count
        }

        function strip(data) {
            return _squarify(data, accumulate, true)
        }
        __webpack_require__( /*! ./tiling */ 572).addAlgorithm("strip", strip);
        module.exports = strip
    },
    /*!*******************************************************!*\
      !*** ./Scripts/viz/tree_map/tiling.slice_and_dice.js ***!
      \*******************************************************/
    function(module, exports, __webpack_require__) {
        var tiling = __webpack_require__( /*! ./tiling */ 572);

        function sliceAndDice(data) {
            var items = data.items,
                sidesData = tiling.buildSidesData(data.rect, data.directions, data.isRotated ? 1 : 0);
            tiling.calculateRectangles(items, 0, data.rect, sidesData, {
                sum: data.sum,
                count: items.length,
                side: sidesData.variedSide
            })
        }
        tiling.addAlgorithm("sliceanddice", sliceAndDice);
        module.exports = sliceAndDice
    },
    /*!*****************************************************!*\
      !*** ./Scripts/viz/tree_map/colorizing.gradient.js ***!
      \*****************************************************/
    function(module, exports, __webpack_require__) {
        var _createColorCodeGetter = __webpack_require__( /*! ./colorizing */ 573).createColorCodeGetter,
            _min = Math.min,
            _max = Math.max;

        function createSimpleColorizer(getColor, range) {
            return function(node) {
                return getColor(node, range)
            }
        }

        function getRangeData(range) {
            return [Number(range[0]) || 0, range[1] - range[0] || 1]
        }

        function calculateRange(nodes, getValue) {
            var i, code, ii = nodes.length,
                codes = [];
            for (i = 0; i < ii; ++i) {
                code = getValue(nodes[i]);
                if (isFinite(code)) {
                    codes.push(code)
                }
            }
            return getRangeData([_min.apply(null, codes), _max.apply(null, codes)])
        }

        function createGuessingColorizer(getColor, getValue) {
            var ranges = {};
            return function(node) {
                var parent = node.parent;
                return getColor(node, ranges[parent._id] || (ranges[parent._id] = calculateRange(parent.nodes, getValue)))
            }
        }

        function gradientColorizer(options, themeManager) {
            var palette = themeManager.createGradientPalette(options.palette),
                getValue = _createColorCodeGetter(options);
            return "range" in options ? createSimpleColorizer(getColor, getRangeData(options.range || [])) : createGuessingColorizer(getColor, getValue);

            function getColor(node, arg) {
                return palette.getColor((getValue(node) - arg[0]) / arg[1])
            }
        }
        __webpack_require__( /*! ./colorizing */ 573).addColorizer("gradient", gradientColorizer);
        module.exports = gradientColorizer
    },
    /*!**************************************************!*\
      !*** ./Scripts/viz/tree_map/colorizing.range.js ***!
      \**************************************************/
    function(module, exports, __webpack_require__) {
        var _createColorCodeGetter = __webpack_require__( /*! ./colorizing */ 573).createColorCodeGetter;

        function getPaletteIndex(value, items) {
            var middle, start = 0,
                end = items.length - 1,
                index = -1;
            if (items[start] <= value && value <= items[end]) {
                if (value === items[end]) {
                    index = end - 1
                } else {
                    while (end - start > 1) {
                        middle = start + end >> 1;
                        if (value < items[middle]) {
                            end = middle
                        } else {
                            start = middle
                        }
                    }
                    index = start
                }
            }
            return index
        }

        function rangeColorizer(options, themeManager) {
            var range = options.range || [],
                palette = themeManager.createDiscretePalette(options.palette, range.length - 1),
                getValue = _createColorCodeGetter(options);
            return function(node) {
                return palette.getColor(getPaletteIndex(getValue(node), range))
            }
        }
        __webpack_require__( /*! ./colorizing */ 573).addColorizer("range", rangeColorizer);
        module.exports = rangeColorizer
    },
    /*!*************************************!*\
      !*** ./Scripts/viz/tree_map/api.js ***!
      \*************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype,
            nodeProto = __webpack_require__( /*! ./node */ 571).prototype,
            _extend = __webpack_require__( /*! jquery */ 9).extend;
        proto._eventsMap.onNodesInitialized = {
            name: "nodesInitialized"
        };
        proto._eventsMap.onNodesRendering = {
            name: "nodesRendering"
        };
        proto._createProxyType = function() {
            var nodes, that = this;
            Proxy.prototype = {
                constructor: Proxy,
                getParent: function() {
                    return nodes[this._id].parent.proxy || null
                },
                getChild: function(index) {
                    var _nodes = nodes[this._id].nodes;
                    return _nodes ? _nodes[index].proxy : null
                },
                getChildrenCount: function() {
                    var _nodes = nodes[this._id].nodes;
                    return _nodes ? _nodes.length : 0
                },
                getAllChildren: function() {
                    var i, _nodes = nodes[this._id].nodes,
                        ii = _nodes && _nodes.length,
                        list = [];
                    for (i = 0; i < ii; ++i) {
                        list.push(_nodes[i].proxy)
                    }
                    return list
                },
                getAllNodes: function() {
                    var list = [];
                    collectNodes(nodes[this._id], list);
                    return list
                },
                isLeaf: function() {
                    return !nodes[this._id].isNode()
                },
                isActive: function() {
                    return nodes[this._id].isActive()
                },
                value: function(arg) {
                    var ret, node = nodes[this._id];
                    if (void 0 !== arg) {
                        updateValue(node, arg > 0 ? Number(arg) : 0);
                        change(node, ["TILING"]);
                        ret = this
                    } else {
                        ret = node.value
                    }
                    return ret
                },
                label: function(arg) {
                    var ret, node = nodes[this._id];
                    if (void 0 !== arg) {
                        node.customLabel = arg ? String(arg) : null;
                        change(node, ["LABELS"]);
                        ret = this
                    } else {
                        ret = node.customLabel || node.label
                    }
                    return ret
                },
                customize: function(settings) {
                    var node = nodes[this._id];
                    if (settings) {
                        node._custom = node._custom || {};
                        _extend(true, node._custom, settings);
                        node._partialState = node._partialLabelState = null
                    }
                    change(node, ["TILES", "LABELS"]);
                    return this
                },
                resetCustomization: function() {
                    var node = nodes[this._id];
                    node._custom = node._partialState = node._partialLabelState = null;
                    change(node, ["TILES", "LABELS"]);
                    return this
                }
            };
            that._extendProxyType(Proxy.prototype);

            function Proxy(node) {
                var that = this;
                node.proxy = that;
                that._id = node._id;
                that.level = node.level;
                that.index = node.index;
                that.data = node.data
            }
            that._handlers.beginBuildNodes = function() {
                nodes = that._nodes;
                new Proxy(that._root)
            };
            that._handlers.buildNode = function(node) {
                new Proxy(node)
            };
            that._handlers.endBuildNodes = function() {
                that._eventTrigger("nodesInitialized", {
                    root: that._root.proxy
                })
            }
        };

        function change(node, codes) {
            var ctx = node.ctx;
            ctx.suspend();
            ctx.change(codes);
            ctx.resume()
        }

        function collectNodes(node, list) {
            var i, nodes = node.nodes,
                ii = nodes && nodes.length;
            for (i = 0; i < ii; ++i) {
                list.push(nodes[i].proxy);
                collectNodes(nodes[i], list)
            }
        }

        function updateValue(node, value) {
            var delta = value - node.value;
            while (node) {
                node.value += delta;
                node = node.parent
            }
        }
        proto._extendProxyType = __webpack_require__( /*! ./common */ 570).empty;
        var _resetNodes = proto._resetNodes;
        proto._resetNodes = function() {
            _resetNodes.call(this);
            this._eventTrigger("nodesRendering", {
                node: this._topNode.proxy
            })
        };
        var _updateStyles = nodeProto.updateStyles;
        nodeProto.updateStyles = function() {
            var that = this;
            _updateStyles.call(that);
            if (that._custom) {
                that._partialState = !that.ctx.forceReset && that._partialState || that.ctx.calculateState(that._custom);
                _extend(true, that.state, that._partialState)
            }
        };
        var _updateLabelStyle = nodeProto.updateLabelStyle;
        nodeProto.updateLabelStyle = function() {
            var that = this,
                custom = that._custom;
            _updateLabelStyle.call(that);
            if (custom && custom.label) {
                that._partialLabelState = !that.ctx.forceReset && that._partialLabelState || calculatePartialLabelState(that, custom.label);
                that.labelState = _extend(true, {}, that.labelState, that._partialLabelState)
            }
        };

        function calculatePartialLabelState(node, settings) {
            var state = node.ctx.calculateLabelState(settings);
            if ("visible" in settings) {
                state.visible = !!settings.visible
            }
            return state
        }
        proto.getRootNode = function() {
            return this._root.proxy
        };
        proto.resetNodes = function() {
            var context = this._context;
            context.suspend();
            context.change(["NODES_CREATE"]);
            context.resume();
            return this
        }
    },
    /*!***************************************!*\
      !*** ./Scripts/viz/tree_map/hover.js ***!
      \***************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype,
            nodeProto = __webpack_require__( /*! ./node */ 571).prototype,
            common = __webpack_require__( /*! ./common */ 570),
            _parseScalar = __webpack_require__( /*! ../core/utils */ 442).parseScalar,
            _buildRectAppearance = common.buildRectAppearance,
            STATE_CODE = 1;
        __webpack_require__( /*! ./api */ 581);
        __webpack_require__( /*! ./states */ 583);
        proto._eventsMap.onHoverChanged = {
            name: "hoverChanged"
        };
        common.expand(proto._handlers, "calculateAdditionalStates", function(states, options) {
            states[1] = options.hoverStyle ? _buildRectAppearance(options.hoverStyle) : {}
        });
        __webpack_require__( /*! ./tree_map.base */ 569).addChange({
            code: "HOVER_ENABLED",
            handler: function() {
                var hoverEnabled = _parseScalar(this._getOption("hoverEnabled", true), true);
                if (!hoverEnabled) {
                    this.clearHover()
                }
                this._hoverEnabled = hoverEnabled
            },
            isThemeDependent: true,
            isOptionChange: true,
            option: "hoverEnabled"
        });
        nodeProto.statesMap[1] = 1;
        nodeProto.additionalStates.push(1);
        common.expand(proto, "_extendProxyType", function(proto) {
            var that = this;
            proto.setHover = function() {
                that._hoverNode(this._id)
            };
            proto.isHovered = function() {
                return that._hoverIndex === this._id
            }
        });
        common.expand(proto, "_onNodesCreated", function() {
            this._hoverIndex = -1
        });
        proto._applyHoverState = function(index, state) {
            setNodeStateRecursive(this._nodes[index], STATE_CODE, state);
            this._eventTrigger("hoverChanged", {
                node: this._nodes[index].proxy
            })
        };

        function setNodeStateRecursive(node, code, state) {
            var i, nodes = node.isNode() && node.nodes,
                ii = nodes && nodes.length;
            node.setState(code, state);
            for (i = 0; i < ii; ++i) {
                setNodeStateRecursive(nodes[i], code, state)
            }
        }
        proto._hoverNode = function(index) {
            var that = this,
                currentIndex = that._hoverIndex;
            if (that._hoverEnabled && currentIndex !== index) {
                that._context.suspend();
                that._hoverIndex = -1;
                if (currentIndex >= 0) {
                    that._applyHoverState(currentIndex, false)
                }
                that._hoverIndex = index;
                if (index >= 0) {
                    that._applyHoverState(index, true)
                }
                that._context.resume()
            }
        };
        proto.clearHover = function() {
            this._hoverNode(-1)
        }
    },
    /*!****************************************!*\
      !*** ./Scripts/viz/tree_map/states.js ***!
      \****************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype,
            nodeProto = __webpack_require__( /*! ./node */ 571).prototype,
            handlers = proto._handlers,
            _calculateState = handlers.calculateState,
            _buildState = nodeProto._buildState,
            _extend = __webpack_require__( /*! jquery */ 9).extend;
        handlers.calculateState = function(options) {
            var states = {
                0: _calculateState(options)
            };
            handlers.calculateAdditionalStates(states, options);
            return states
        };
        handlers.calculateAdditionalStates = __webpack_require__( /*! ./common */ 570).empty;
        nodeProto.code = 0;
        nodeProto.statesMap = {
            0: 0
        };
        nodeProto.additionalStates = [];
        nodeProto._buildState = function(state, extra) {
            var states = {
                0: _buildState(state[0], extra)
            };
            if (this.additionalStates.length) {
                buildAdditionalStates(states, states[0], state, this.additionalStates)
            }
            return states
        };
        nodeProto._getState = function() {
            return this.state[this.statesMap[this.code]]
        };
        nodeProto.setState = function(code, state) {
            if (state) {
                this.code |= code
            } else {
                this.code &= ~code
            }
            this.ctx.change(["TILES"])
        };

        function buildAdditionalStates(states, base, source, list) {
            var i, ii = list.length;
            for (i = 0; i < ii; ++i) {
                states[list[i]] = _extend({}, base, source[list[i]])
            }
        }
    },
    /*!*******************************************!*\
      !*** ./Scripts/viz/tree_map/selection.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype,
            nodeProto = __webpack_require__( /*! ./node */ 571).prototype,
            common = __webpack_require__( /*! ./common */ 570),
            _buildRectAppearance = common.buildRectAppearance,
            _normalizeEnum = __webpack_require__( /*! ../core/utils */ 442).normalizeEnum,
            _inArray = __webpack_require__( /*! jquery */ 9).inArray,
            MODE_NONE = 0,
            MODE_SINGLE = 1,
            MODE_MULTIPLE = 2,
            STATE_CODE = 2;
        __webpack_require__( /*! ./api */ 581);
        __webpack_require__( /*! ./states */ 583);
        proto._eventsMap.onSelectionChanged = {
            name: "selectionChanged"
        };
        common.expand(proto._handlers, "calculateAdditionalStates", function(states, options) {
            states[2] = options.selectionStyle ? _buildRectAppearance(options.selectionStyle) : {}
        });
        nodeProto.statesMap[2] = nodeProto.statesMap[3] = STATE_CODE;
        nodeProto.additionalStates.push(2);
        common.expand(proto, "_onNodesCreated", function() {
            this._selectionList.length = 0
        });
        common.expand(proto, "_extendProxyType", function(proto) {
            var that = this;
            proto.select = function(state) {
                that._selectNode(this._id, !!state)
            };
            proto.isSelected = function() {
                return _inArray(this._id, that._selectionList) >= 0
            };
            that._selectionList = []
        });
        __webpack_require__( /*! ./tree_map.base */ 569).addChange({
            code: "SELECTION_MODE",
            handler: function() {
                var mode, tmp, that = this,
                    option = _normalizeEnum(that._getOption("selectionMode", true)),
                    selectionList = that._selectionList;
                mode = "none" === option ? MODE_NONE : "multiple" === option ? MODE_MULTIPLE : MODE_SINGLE;
                if (mode === MODE_SINGLE && selectionList.length > 1) {
                    tmp = selectionList.pop();
                    that.clearSelection();
                    selectionList.push(tmp)
                } else {
                    if (mode === MODE_NONE) {
                        that.clearSelection()
                    }
                }
                that._selectionMode = mode
            },
            isThemeDependent: true,
            isOptionChange: true,
            option: "selectionMode"
        });
        common.expand(proto, "_applyTilesAppearance", function() {
            if (this._selectionList.length) {
                bringSelectedTilesToForeground(this._nodes, this._selectionList)
            }
        });

        function bringSelectedTilesToForeground(nodes, selectionList) {
            var i, node, ii = selectionList.length;
            for (i = 0; i < ii; ++i) {
                node = nodes[selectionList[i]];
                tileToFront[Number(node.isNode())](node.tile)
            }
        }
        var tileToFront = [leafToFront, groupToFront];

        function leafToFront(content) {
            content.toForeground()
        }

        function groupToFront(content) {
            content.outer.toForeground();
            content.inner.toForeground()
        }
        proto._applySelectionState = function(index, state) {
            var node = this._nodes[index];
            node.setState(STATE_CODE, state);
            this._eventTrigger("selectionChanged", {
                node: node.proxy
            })
        };
        proto._selectNode = function(index, state) {
            var selectionList, k, tmp, that = this;
            if (that._selectionMode !== MODE_NONE) {
                that._context.suspend();
                selectionList = that._selectionList;
                k = _inArray(index, selectionList);
                if (state && k === -1) {
                    if (that._selectionMode === MODE_SINGLE) {
                        if (selectionList.length) {
                            tmp = selectionList.pop();
                            that._applySelectionState(tmp, false)
                        }
                    }
                    selectionList.push(index);
                    that._applySelectionState(index, true)
                } else {
                    if (!state && k >= 0) {
                        selectionList.splice(k, 1);
                        that._applySelectionState(index, false)
                    }
                }
                that._context.resume()
            }
        };
        proto.clearSelection = function() {
            var i, that = this,
                selectionList = that._selectionList,
                ii = selectionList.length;
            if (that._selectionMode !== MODE_NONE) {
                that._context.suspend();
                for (i = 0; i < ii; ++i) {
                    that._applySelectionState(selectionList[i], false)
                }
                selectionList.length = 0;
                that._context.resume()
            }
        }
    },
    /*!*****************************************!*\
      !*** ./Scripts/viz/tree_map/tooltip.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype,
            common = __webpack_require__( /*! ./common */ 570);
        __webpack_require__( /*! ./api */ 581);
        common.expand(proto, "_extendProxyType", function(proto) {
            var that = this;
            proto.showTooltip = function(coords) {
                that._showTooltip(this._id, coords)
            }
        });
        common.expand(proto, "_onNodesCreated", function() {
            if (this._tooltipIndex >= 0) {
                this._tooltip.hide()
            }
            this._tooltipIndex = -1
        });
        common.expand(proto, "_onTilingPerformed", function() {
            if (this._tooltipIndex >= 0) {
                this._moveTooltip(this._nodes[this._tooltipIndex])
            }
        });

        function getCoords(rect, renderer) {
            var offset = renderer.getRootOffset();
            return [(rect[0] + rect[2]) / 2 + offset.left, (rect[1] + rect[3]) / 2 + offset.top]
        }
        proto._showTooltip = function(index, coords) {
            var node, state, that = this,
                tooltip = that._tooltip;
            if (tooltip.isEnabled()) {
                node = that._nodes[index];
                state = that._tooltipIndex === index || tooltip.show({
                    value: node.value,
                    valueText: tooltip.formatValue(node.value),
                    node: node.proxy
                }, {
                    x: 0,
                    y: 0,
                    offset: 0
                }, {
                    node: node.proxy
                });
                if (state) {
                    that._moveTooltip(node, coords)
                } else {
                    tooltip.hide()
                }
                that._tooltipIndex = state ? index : -1
            }
        };
        proto._moveTooltip = function(node, coords) {
            var xy = coords || node.rect && getCoords(node.rect, this._renderer) || [-1e3, -1e3];
            this._tooltip.move(xy[0], xy[1], 0)
        };
        proto.hideTooltip = function() {
            if (this._tooltipIndex >= 0) {
                this._tooltipIndex = -1;
                this._tooltip.hide()
            }
        };
        __webpack_require__( /*! ./tree_map.base */ 569).addPlugin(__webpack_require__( /*! ../core/tooltip */ 495).plugin)
    },
    /*!*****************************************!*\
      !*** ./Scripts/viz/tree_map/tracker.js ***!
      \*****************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype,
            common = __webpack_require__( /*! ./common */ 570),
            _eventData = __webpack_require__( /*! ../../events/utils */ 62).eventData,
            _parseScalar = __webpack_require__( /*! ../core/utils */ 442).parseScalar,
            clickEventName = __webpack_require__( /*! ../../events/click */ 64).name,
            downPointerEventName = __webpack_require__( /*! ../../events/pointer */ 65).down,
            movePointerEventName = __webpack_require__( /*! ../../events/pointer */ 65).move,
            $ = __webpack_require__( /*! jquery */ 9),
            $doc = $(document),
            DATA_KEY_BASE = "__treemap_data_",
            dataKeyModifier = 0;
        __webpack_require__( /*! ./api */ 581);
        __webpack_require__( /*! ./hover */ 582);
        __webpack_require__( /*! ./tooltip */ 585);
        proto._eventsMap.onClick = {
            name: "click"
        };
        common.expand(proto, "_initCore", function() {
            var that = this,
                dataKey = DATA_KEY_BASE + dataKeyModifier++;
            that._tracker = new Tracker({
                widget: that,
                root: that._renderer.root,
                eventTrigger: that._eventTrigger,
                getData: function(e) {
                    var target = e.target;
                    return ("tspan" === target.tagName ? target.parentNode : target)[dataKey]
                },
                getProxy: function(index) {
                    return that._nodes[index].proxy
                },
                getCoords: function(e) {
                    var data = _eventData(e),
                        offset = that._renderer.getRootOffset();
                    return [data.x - offset.left, data.y - offset.top]
                }
            });
            proto._handlers.setTrackerData = function(node, element) {
                element.data(dataKey, node._id)
            };
            exports._TESTS_dataKey = dataKey
        });
        common.expand(proto, "_disposeCore", function() {
            this._tracker.dispose()
        });
        __webpack_require__( /*! ./tree_map.base */ 569).addChange({
            code: "INTERACT_WITH_GROUP",
            handler: function() {
                this._tracker.setOptions({
                    interactWithGroup: _parseScalar(this._getOption("interactWithGroup", true), false)
                })
            },
            isThemeDependent: true,
            isOptionChange: true,
            option: "interactWithGroup"
        });

        function Tracker(parameters) {
            this._options = {};
            this._initHandlers(parameters, this._options)
        }
        Tracker.prototype = {
            constructor: Tracker,
            _initHandlers: function(parameters, options) {
                parameters.getNode = function(id) {
                    var proxy = parameters.getProxy(id);
                    return options.interactWithGroup && proxy.isLeaf() && proxy.getParent().isActive() ? proxy.getParent() : proxy
                };
                parameters.root.on(clickEventName, clickHandler);
                parameters.root.on(downPointerEventName, downHandler);
                $doc.on(downPointerEventName, downHandler);
                $doc.on(movePointerEventName, moveHandler);
                this._disposeHandlers = function() {
                    parameters.root.off(clickEventName, clickHandler);
                    parameters.root.off(downPointerEventName, downHandler);
                    $doc.off(downPointerEventName, downHandler);
                    $doc.off(movePointerEventName, moveHandler)
                };

                function clickHandler(e) {
                    processClick(e, parameters)
                }
                var isRootDown = false;

                function downHandler(e) {
                    if (isRootDown) {
                        isRootDown = false
                    } else {
                        if (void 0 !== parameters.getData(e)) {
                            e.preventDefault();
                            isRootDown = true
                        }
                        moveHandler(e)
                    }
                }

                function moveHandler(e) {
                    processHover(e, parameters);
                    processTooltip(e, parameters)
                }
            },
            dispose: function() {
                this._disposeHandlers()
            },
            setOptions: function(options) {
                $.extend(this._options, options)
            }
        };

        function processClick(e, params) {
            var id = params.getData(e);
            if (id >= 0) {
                params.eventTrigger("click", {
                    node: params.getNode(id),
                    coords: params.getCoords(e),
                    jQueryEvent: e
                })
            }
        }

        function processHover(e, params) {
            var id = params.getData(e);
            if (id >= 0) {
                params.getNode(id).setHover()
            } else {
                params.widget.clearHover()
            }
        }

        function processTooltip(e, params) {
            var coords, id = params.getData(e);
            if (id >= 0) {
                coords = _eventData(e);
                params.getNode(id).showTooltip([coords.x, coords.y])
            } else {
                params.widget.hideTooltip()
            }
        }
    },
    /*!*******************************************!*\
      !*** ./Scripts/viz/tree_map/drilldown.js ***!
      \*******************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype,
            _expand = __webpack_require__( /*! ./common */ 570).expand;
        __webpack_require__( /*! ./api */ 581);
        proto._eventsMap.onDrill = {
            name: "drill"
        };
        _expand(proto, "_extendProxyType", function(proto) {
            var that = this;
            proto.drillDown = function() {
                that._drillToNode(this._id)
            }
        });
        _expand(proto, "_onNodesCreated", function() {
            this._drilldownIndex = -1
        });
        proto._drillToNode = function(index) {
            var node, that = this;
            if (that._drilldownIndex !== index) {
                node = that._nodes[index] || that._root;
                if (node.nodes) {
                    that._drilldownIndex = index;
                    that._topNode = node;
                    that._context.suspend();
                    that._context.change(["MAX_DEPTH", "NODES_RESET"]);
                    that._context.resume();
                    that._eventTrigger("drill", {
                        node: node.proxy
                    })
                }
            }
        };
        proto.resetDrillDown = function() {
            this._drillToNode(-1);
            return this
        };
        proto.drillUp = function() {
            this._drillToNode(this._topNode.parent._id || -1);
            return this
        };
        proto.getCurrentNode = function() {
            return this._topNode.proxy
        }
    },
    /*!***************************************************!*\
      !*** ./Scripts/viz/tree_map/plain_data_source.js ***!
      \***************************************************/
    function(module, exports, __webpack_require__) {
        var proto = __webpack_require__( /*! ./tree_map.base */ 569).prototype;
        proto._optionChangesMap.idField = proto._optionChangesMap.parentField = "NODES_CREATE";
        proto._processDataSourceItems = function(items) {
            var i, currentItem, parentId, tmpItems, item, struct = {},
                idField = this._getOption("idField", true),
                parentField = this._getOption("parentField", true),
                rootNodes = [];
            if (!idField || !parentField || 0 === items.length) {
                return {
                    items: items,
                    isPlain: true
                }
            }
            for (i = 0; i < items.length; i++) {
                currentItem = items[i];
                parentId = currentItem[parentField];
                if (!!parentId) {
                    struct[parentId] = struct[parentId] || {
                        items: []
                    };
                    tmpItems = struct[parentId].items
                } else {
                    tmpItems = rootNodes
                }
                tmpItems.push(currentItem)
            }
            treeFiller({
                struct: struct,
                idField: idField
            }, rootNodes);
            for (item in struct) {
                struct[item] && rootNodes.push(struct[item])
            }
            return {
                items: rootNodes,
                isPlain: true
            }
        };

        function treeFiller(context, items) {
            var currentItem, i, id, struct = context.struct;
            for (i = 0; i < items.length; i++) {
                currentItem = items[i];
                id = currentItem[context.idField];
                if (struct[id]) {
                    currentItem.items = struct[id].items;
                    struct[id] = null;
                    treeFiller(context, currentItem.items)
                }
            }
        }
    }
]);
