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

/***/ 0:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/helpers/interopRequireDefault");

/***/ }),

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

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

// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
// This module is a runtime utility for cleaner component module output and will
// be included in the final webpack user bundle.

function normalizeComponent(
  scriptExports,
  render,
  staticRenderFns,
  functionalTemplate,
  injectStyles,
  scopeId,
  moduleIdentifier /* server only */,
  shadowMode /* vue-cli only */
) {
  // Vue.extend constructor export interop
  var options =
    typeof scriptExports === 'function' ? scriptExports.options : scriptExports

  // render functions
  if (render) {
    options.render = render
    options.staticRenderFns = staticRenderFns
    options._compiled = true
  }

  // functional template
  if (functionalTemplate) {
    options.functional = true
  }

  // scopedId
  if (scopeId) {
    options._scopeId = 'data-v-' + scopeId
  }

  var hook
  if (moduleIdentifier) {
    // server build
    hook = function (context) {
      // 2.3 injection
      context =
        context || // cached call
        (this.$vnode && this.$vnode.ssrContext) || // stateful
        (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
      // 2.2 with runInNewContext: true
      if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
        context = __VUE_SSR_CONTEXT__
      }
      // inject component styles
      if (injectStyles) {
        injectStyles.call(this, context)
      }
      // register component module identifier for async chunk inferrence
      if (context && context._registeredComponents) {
        context._registeredComponents.add(moduleIdentifier)
      }
    }
    // used by ssr in case component is cached and beforeCreate
    // never gets called
    options._ssrRegister = hook
  } else if (injectStyles) {
    hook = shadowMode
      ? function () {
          injectStyles.call(
            this,
            (options.functional ? this.parent : this).$root.$options.shadowRoot
          )
        }
      : injectStyles
  }

  if (hook) {
    if (options.functional) {
      // for template-only hot-reload because in that case the render fn doesn't
      // go through the normalizer
      options._injectStyles = hook
      // register for functional component in vue file
      var originalRender = options.render
      options.render = function renderWithStyleInjection(h, context) {
        hook.call(context)
        return originalRender(h, context)
      }
    } else {
      // inject component registration as beforeCreate hook
      var existing = options.beforeCreate
      options.beforeCreate = existing ? [].concat(existing, hook) : [hook]
    }
  }

  return {
    exports: scriptExports,
    options: options
  }
}


/***/ }),

/***/ 13:
/***/ (function(module, exports) {

module.exports = require("vue");

/***/ }),

/***/ 14:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/helpers/createClass");

/***/ }),

/***/ 2:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/init.js");

/***/ }),

/***/ 25:
/***/ (function(module, exports) {

module.exports = require("lodash.debounce");

/***/ }),

/***/ 276:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(277);
/* harmony import */ var _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
 /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0___default.a); 

/***/ }),

/***/ 277:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _createClass2 = _interopRequireDefault(__webpack_require__(14));
var _inheritsLoose2 = _interopRequireDefault(__webpack_require__(3));
var _vue = _interopRequireDefault(__webpack_require__(13));
var _vuePropertyDecorator = __webpack_require__(9);
var _Theme = _interopRequireDefault(__webpack_require__(4));
var _CompareViewModel = _interopRequireDefault(__webpack_require__(677));
var _lodash = _interopRequireDefault(__webpack_require__(25));
var _resizeDetector = __webpack_require__(29);
__webpack_require__(679);
var __decorate = void 0 && (void 0).__decorate || function (decorators, target, key, desc) {
  var c = arguments.length,
    r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc,
    d;
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
  return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var Compare = /*#__PURE__*/function (_Mixins) {
  (0, _inheritsLoose2.default)(Compare, _Mixins);
  function Compare() {
    return _Mixins.apply(this, arguments) || this;
  }
  var _proto = Compare.prototype;
  _proto.additionalOptionsWatcher = function additionalOptionsWatcher() {
    this.handleOptionsChange();
  };
  _proto.compareSwipeLineStyleWatcher = function compareSwipeLineStyleWatcher(next, prev) {
    var style = this.diffStyle(next, prev);
    style && this.setSwipeLineStyle();
  };
  _proto.compareSwipeSlideStyleWatcher = function compareSwipeSlideStyleWatcher(next, prev) {
    var style = this.diffStyle(next, prev);
    style && this.setSwipeStyle(style);
  };
  _proto.created = function created() {
    this.viewModel = new _CompareViewModel.default();
  };
  _proto.mounted = function mounted() {
    this.$on('theme-style-changed', this.handleThemeStyleChanged);
    if (this.autoresize) {
      this.resizeHandler = (0, _lodash.default)(this.resize, 300, {
        leading: true
      });
      (0, _resizeDetector.addListener)(this.$el, this.resizeHandler);
    }
  };
  _proto.beforeDestroy = function beforeDestroy() {
    this.viewModel.removed();
    if (this.autoresize) {
      (0, _resizeDetector.removeListener)(this.$el, this.resizeHandler);
    }
  };
  _proto.initSwipeStyle = function initSwipeStyle() {
    this.setSwipeLineStyle();
    this.setSwipeStyle();
  };
  _proto.resize = function resize() {
    this.handleOptionsChange();
  };
  _proto.diffStyle = function diffStyle(nextStyle, prevStyle) {
    var diff;
    for (var key in nextStyle) {
      if (nextStyle[key] !== prevStyle[key]) {
        diff = diff || {};
        diff[key] = nextStyle[key];
      }
    }
    return diff;
  };
  _proto.setSwipeStyle = function setSwipeStyle(style) {
    if (style === void 0) {
      style = this.compareSwipeSlideStyle;
    }
    var swipeDom = this.$el.querySelector('.mapboxgl-compare > div');
    this.setStyle(swipeDom, style);
  };
  _proto.setSwipeLineStyle = function setSwipeLineStyle(style) {
    if (style === void 0) {
      style = this.compareSwipeLineStyle;
    }
    var swipeLineDom = this.$el.querySelector('.mapboxgl-compare');
    this.setStyle(swipeLineDom, style);
  };
  _proto.setStyle = function setStyle(dom, style) {
    if (dom) {
      for (var key in style) {
        var value = style[key];
        dom.style[key] = value;
      }
    }
  };
  _proto.handleThemeStyleChanged = function handleThemeStyleChanged() {
    this.setSwipeStyle({
      backgroundColor: this.colorGroupsData && this.colorGroupsData[0]
    });
  };
  _proto.handleOptionsChange = function handleOptionsChange() {
    var options = {
      beforeMap: this.beforeMapInstance,
      afterMap: this.afterMapInstance,
      target: this.target,
      options: {
        orientation: this.orientation,
        mousemove: this.mousemove
      }
    };
    if (options.beforeMap && options.afterMap) {
      var beforeZoom = options.beforeMap.getZoom();
      var beforeCenter = options.beforeMap.getCenter();
      var beforeBearing = options.beforeMap.getBearing();
      var beforePitch = options.beforeMap.getPitch();
      if (beforeZoom !== options.afterMap.getZoom()) {
        options.afterMap.setZoom(beforeZoom);
      }
      if (beforeCenter.toString() !== options.afterMap.getCenter().toString()) {
        options.afterMap.setCenter(beforeCenter);
      }
      if (beforeBearing !== options.afterMap.getBearing()) {
        options.afterMap.setBearing(beforeBearing);
      }
      if (beforePitch !== options.afterMap.getPitch()) {
        options.afterMap.setPitch(beforePitch);
      }
      this.viewModel.init(options);
      this.$nextTick(this.initSwipeStyle);
    }
  };
  _proto.setBeforeMap = function setBeforeMap(params) {
    this.beforeMapInstance = params.map;
    this.handleOptionsChange();
  };
  _proto.setAfterMap = function setAfterMap(params) {
    this.afterMapInstance = params.map;
    this.handleOptionsChange();
  };
  _proto.refreshRect = function refreshRect() {
    var _a;
    (_a = this.viewModel) === null || _a === void 0 ? void 0 : _a.refreshRect();
  };
  _proto.render = function render(h) {
    var children;
    if (this.beforeMapOptions && this.afterMapOptions) {
      children = [h(_vue.default.component('SmWebMap'), {
        props: this.beforeMapOptions,
        on: {
          load: this.setBeforeMap
        }
      }), h(_vue.default.component('SmWebMap'), {
        props: this.afterMapOptions,
        on: {
          load: this.setAfterMap
        }
      })];
    } else if (this.$slots.beforeMap && this.$slots.afterMap) {
      var beforePrevListeners = this.$slots.beforeMap[0].componentOptions.listeners;
      this.$slots.beforeMap[0].componentOptions.listeners = Object.assign({}, beforePrevListeners, {
        load: this.setBeforeMap
      });
      var afterPrevListeners = this.$slots.afterMap[0].componentOptions.listeners;
      this.$slots.afterMap[0].componentOptions.listeners = Object.assign({}, afterPrevListeners, {
        load: this.setAfterMap
      });
      children = [this.$slots.beforeMap, this.$slots.afterMap];
    }
    return h('div', {
      class: 'sm-component-compare',
      attrs: {
        id: this.target
      }
    }, children);
  };
  (0, _createClass2.default)(Compare, [{
    key: "additionalOptions",
    get: function get() {
      return {
        orientation: this.orientation,
        mousemove: this.mousemove
      };
    }
  }, {
    key: "compareSwipeLineStyle",
    get: function get() {
      var style = {
        backgroundColor: this.textColor
      };
      var sizeFieldName = 'width';
      if (this.orientation === 'horizontal') {
        sizeFieldName = 'height';
      }
      style[sizeFieldName] = this.lineSize + "px";
      return style;
    }
  }, {
    key: "compareSwipeSlideStyle",
    get: function get() {
      return {
        backgroundColor: this.slideBackground,
        color: this.textColor,
        width: this.slideSize + "px",
        height: this.slideSize + "px",
        borderWidth: this.lineSize + "px"
      };
    }
  }]);
  return Compare;
}((0, _vuePropertyDecorator.Mixins)(_Theme.default));
__decorate([(0, _vuePropertyDecorator.Prop)({
  default: 'comparison-container'
})], Compare.prototype, "target", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)({
  default: 'vertical'
})], Compare.prototype, "orientation", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)({
  default: false
})], Compare.prototype, "mousemove", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)()], Compare.prototype, "beforeMapOptions", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)()], Compare.prototype, "afterMapOptions", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)({
  default: 2
})], Compare.prototype, "lineSize", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)({
  default: 60
})], Compare.prototype, "slideSize", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)()], Compare.prototype, "slideBackground", void 0);
__decorate([(0, _vuePropertyDecorator.Prop)({
  default: true
})], Compare.prototype, "autoresize", void 0);
__decorate([(0, _vuePropertyDecorator.Watch)('additionalOptions')], Compare.prototype, "additionalOptionsWatcher", null);
__decorate([(0, _vuePropertyDecorator.Watch)('compareSwipeLineStyle')], Compare.prototype, "compareSwipeLineStyleWatcher", null);
__decorate([(0, _vuePropertyDecorator.Watch)('compareSwipeSlideStyle')], Compare.prototype, "compareSwipeSlideStyleWatcher", null);
Compare = __decorate([(0, _vuePropertyDecorator.Component)({
  name: 'SmCompare'
})], Compare);
var _default = exports.default = Compare;

/***/ }),

/***/ 29:
/***/ (function(module, exports) {

module.exports = require("resize-detector");

/***/ }),

/***/ 3:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/helpers/inheritsLoose");

/***/ }),

/***/ 4:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_mixin/Theme.js");

/***/ }),

/***/ 5:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/static/libs/mapboxgl/mapbox-gl-enhance.js");

/***/ }),

/***/ 675:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _Compare = _interopRequireDefault(__webpack_require__(676));
var _init = _interopRequireDefault(__webpack_require__(2));
_Compare.default.install = function (Vue, opts) {
  (0, _init.default)(Vue, opts);
  Vue.component(_Compare.default.options ? _Compare.default.options.name : _Compare.default.name, _Compare.default);
};
var _default = exports.default = _Compare.default;

/***/ }),

/***/ 676:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(276);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/* harmony import */ var _node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
var render, staticRenderFns




/* normalize component */

var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"])(
  _Compare_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__["default"],
  render,
  staticRenderFns,
  false,
  null,
  null,
  null
  
)

/* harmony default export */ __webpack_exports__["default"] = (component.exports);

/***/ }),

/***/ 677:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
__webpack_require__(5);
__webpack_require__(678);
var CompareViewModel = exports.default = /*#__PURE__*/function () {
  function CompareViewModel(options) {
    this.init(options);
  }
  var _proto = CompareViewModel.prototype;
  _proto.init = function init(nextOptions) {
    if (!nextOptions) {
      return;
    }
    this.removed();
    var beforeMap = nextOptions.beforeMap,
      afterMap = nextOptions.afterMap,
      target = nextOptions.target,
      options = nextOptions.options;
    if (beforeMap && afterMap && target) {
      var $window = window;
      var mapboxgl = $window.mapboxgl;
      this.compare = new mapboxgl.Compare(beforeMap, afterMap, "#" + target, options);
    }
  };
  _proto.removed = function removed() {
    if (this.compare) {
      this.compare.remove();
      this.compare = null;
    }
  };
  _proto.refreshRect = function refreshRect() {
    if (this.compare) {
      this.compare._bounds = this.compare._mapB.getContainer().getBoundingClientRect();
    }
  };
  return CompareViewModel;
}();

/***/ }),

/***/ 678:
/***/ (function(module, exports) {

module.exports = require("mapbox-gl-compare");

/***/ }),

/***/ 679:
/***/ (function(module, exports) {

module.exports = require("mapbox-gl-compare/dist/mapbox-gl-compare.css");

/***/ }),

/***/ 9:
/***/ (function(module, exports) {

module.exports = require("vue-property-decorator");

/***/ })

/******/ });