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 = 803);
/******/ })
/************************************************************************/
/******/ ({

/***/ 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
  }
}


/***/ }),

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

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

/***/ }),

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

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

/***/ }),

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

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

/***/ }),

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

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

/***/ }),

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

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

/***/ }),

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

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

/***/ }),

/***/ 344:
/***/ (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_vue_loader_lib_index_js_vue_loader_options_MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(345);
/* harmony import */ var _node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_MiniMap_vue_vue_type_script_lang_js___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_vue_loader_lib_index_js_vue_loader_options_MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
 /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default.a); 

/***/ }),

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

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _Theme = _interopRequireDefault(__webpack_require__(4));
var _MiniMapViewModel = _interopRequireDefault(__webpack_require__(805));
var _control = _interopRequireDefault(__webpack_require__(17));
var _mapGetter = _interopRequireDefault(__webpack_require__(7));
var _Card = _interopRequireDefault(__webpack_require__(22));
var _Spin = _interopRequireDefault(__webpack_require__(35));
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
var _default = exports.default = {
  name: 'SmMiniMap',
  components: {
    SmSpin: _Spin.default
  },
  mixins: [_mapGetter.default, _control.default, _Card.default, _Theme.default],
  props: {
    iconClass: {
      type: String,
      default: 'sm-components-icon-arrow-left'
    },
    autoRotate: {
      type: Boolean,
      default: true
    }
  },
  data: function data() {
    return {
      spinning: true
    };
  },
  created: function created() {
    this.miniMap && this.miniMap.remove();
    this.viewModel = new _MiniMapViewModel.default();
    this.viewModel.on('minimaploaded', this.minimapLoadedFn);
  },
  beforeDestory: function beforeDestory() {
    this.viewModel.off('minimaploaded', this.minimapLoadedFn);
  },
  loaded: function loaded() {
    this.viewModel && this.viewModel.setContainer(this.$el.querySelector('#miniMap') || this.$el);
  },
  methods: {
    handleMinimapResize: function handleMinimapResize(state) {
      var _this = this;
      this.$nextTick(function () {
        state && _this.resize();
      });
    },
    resize: function resize() {
      if (this.viewModel && this.viewModel.resize) {
        this.viewModel.resize();
      }
    },
    minimapLoadedFn: function minimapLoadedFn(e) {
      this.miniMap = e.miniMap;
      this.spinning = false;
    }
  }
};

/***/ }),

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

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

/***/ }),

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

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

/***/ }),

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

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, "a", function() { return /* reexport */ render; });
__webpack_require__.d(__webpack_exports__, "b", function() { return /* reexport */ staticRenderFns; });

// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./src/mapboxgl/web-map/control/mini-map/MiniMap.vue?vue&type=template&id=1f91ca8e&
var render = function () {
  var _vm = this
  var _h = _vm.$createElement
  var _c = _vm._self._c || _h
  return _c(
    "sm-collapse-card",
    {
      staticClass: "sm-component-minimap",
      attrs: {
        "icon-class": _vm.iconClass,
        "icon-position": _vm.position,
        "header-name": _vm.headerName,
        "auto-rotate": _vm.autoRotate,
        collapsed: _vm.collapsed,
        background: _vm.background,
        textColor: _vm.textColor,
        "split-line": _vm.splitLine,
      },
      on: { "content-show-state": _vm.handleMinimapResize },
    },
    [
      _c(
        "div",
        { staticClass: "miniMap", attrs: { id: "miniMap" } },
        [
          _vm.spinning
            ? _c("sm-spin", {
                attrs: {
                  size: "small",
                  tip: _vm.$t("info.loading"),
                  spinning: _vm.spinning,
                },
              })
            : _vm._e(),
        ],
        1
      ),
    ]
  )
}
var staticRenderFns = []
render._withStripped = true


// CONCATENATED MODULE: ./src/mapboxgl/web-map/control/mini-map/MiniMap.vue?vue&type=template&id=1f91ca8e&


/***/ }),

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

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

/***/ }),

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

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

/***/ }),

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

"use strict";


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

/***/ }),

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

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _MiniMap_vue_vue_type_template_id_1f91ca8e___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(460);
/* harmony import */ var _MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(344);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/* harmony import */ var _node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);





/* normalize component */

var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"])(
  _MiniMap_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"],
  _MiniMap_vue_vue_type_template_id_1f91ca8e___WEBPACK_IMPORTED_MODULE_0__[/* render */ "a"],
  _MiniMap_vue_vue_type_template_id_1f91ca8e___WEBPACK_IMPORTED_MODULE_0__[/* staticRenderFns */ "b"],
  false,
  null,
  null,
  null
  
)

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

/***/ }),

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

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _inheritsLoose2 = _interopRequireDefault(__webpack_require__(3));
var _mapboxGlEnhance = _interopRequireDefault(__webpack_require__(5));
var _lodash = _interopRequireDefault(__webpack_require__(19));
var _lodash2 = _interopRequireDefault(__webpack_require__(25));
/**
 * @class MiniMapViewModel
 * @description mini map viewModel.
 * @param {Object} parentMap - 外层 Map。
 * @param {Object} miniMap - 内层 Map。
 * @fires MiniMapViewModel#minimapmousedown
 * @fires MiniMapViewModel#minimapmousemove
 * @fires MiniMapViewModel#minimapmouseup
 * @fires MiniMapViewModel#minimapupdated
 * @extends mapboxgl.Evented
 */
var MiniMapViewModel = exports.default = /*#__PURE__*/function (_mapboxgl$Evented) {
  (0, _inheritsLoose2.default)(MiniMapViewModel, _mapboxgl$Evented);
  function MiniMapViewModel() {
    var _this2;
    _this2 = _mapboxgl$Evented.call(this) || this;
    _this2.options = {
      id: 'mapboxgl-minimap',
      zoomAdjust: null,
      bounds: 'parent',
      lineColor: '#08F',
      lineWidth: 1,
      lineOpacity: 1,
      fillColor: '#F80',
      fillOpacity: 0.25,
      dragPan: false,
      scrollZoom: false,
      boxZoom: false,
      dragRotate: false,
      keyboard: false,
      doubleClickZoom: false,
      touchZoomRotate: false
    };
    _this2._ticking = false;
    _this2._lastMouseMoveEvent = null;
    _this2._isDragging = false;
    _this2._isCursorOverFeature = false;
    _this2._previousPoint = [0, 0];
    _this2._currentPoint = [0, 0];
    _this2._trackingRectCoordinates = [[[], [], [], [], []]];
    return _this2;
  }
  var _proto = MiniMapViewModel.prototype;
  _proto.setMap = function setMap(mapInfo) {
    var map = mapInfo.map;
    this._parentMap = map;
  };
  _proto.setContainer = function setContainer(container) {
    this._container = container;
    this._updateFn = this._update.bind(this);
    this._setStyleFn = (0, _lodash2.default)(this._setStyle, 200, {
      trailing: true
    }).bind(this);
    this._mouseMoveFn = this._mouseMove.bind(this);
    this._mouseDownFn = this._mouseDown.bind(this);
    this._mouseUpFn = this._mouseUp.bind(this);
    this.initializeMiniMap();
  };
  _proto.initializeMiniMap = function initializeMiniMap() {
    var _this3 = this;
    var _this = this;
    this._miniMap = new _mapboxGlEnhance.default.Map({
      attributionControl: false,
      container: _this._container,
      style: (0, _lodash.default)(_this._parentMap.getStyle()),
      zoom: 1,
      crs: this._parentMap.getCRS(),
      center: [0, 0],
      renderWorldCopies: false,
      localIdeographFontFamily: this._parentMap._localIdeographFontFamily
    });
    this._miniMap.on('load', function () {
      _this3.fire('minimaploaded', {
        miniMap: _this3._miniMap
      });
      _this3._miniMap.resize();
      _this3.loadMiniMap();
    });
  };
  _proto.loadMiniMap = function loadMiniMap() {
    var opts = this.options;
    var parentMap = this._parentMap;
    var miniMap = this._miniMap;
    var interactions = ['dragPan', 'scrollZoom', 'boxZoom', 'dragRotate', 'keyboard', 'doubleClickZoom', 'touchZoomRotate'];
    interactions.forEach(function (i) {
      if (opts[i] !== true) {
        miniMap[i].disable();
      }
    });
    if (typeof opts.zoomAdjust === 'function') {
      this.options.zoomAdjust = opts.zoomAdjust.bind(this);
    } else if (opts.zoomAdjust === null) {
      this.options.zoomAdjust = this._zoomAdjust.bind(this);
    }
    if (opts.bounds === 'parent') {
      opts.bounds = parentMap.getBounds();
    }
    if (typeof opts.bounds === 'object') {
      miniMap.fitBounds(opts.bounds, {
        duration: 50
      });
    }
    var bounds = miniMap.getBounds();
    this._convertBoundsToPoints(bounds);
    this._addRectLayers();
    this._update();
    parentMap.on('move', this._updateFn);
    parentMap.on('styledata', this._setStyleFn);
    miniMap.on('mousemove', this._mouseMoveFn);
    miniMap.on('mousedown', this._mouseDownFn);
    miniMap.on('mouseup', this._mouseUpFn);
    this._miniMapCanvas = miniMap.getCanvasContainer();
    this._miniMapCanvas.addEventListener('wheel', this._preventDefault);
    this._miniMapCanvas.addEventListener('mousewheel', this._preventDefault);
  };
  _proto.resize = function resize() {
    this._miniMap && this._miniMap.resize();
  };
  _proto._mouseDown = function _mouseDown(e) {
    if (this._isCursorOverFeature) {
      this._isDragging = true;
      this._previousPoint = this._currentPoint;
      this._currentPoint = [e.lngLat.lng, e.lngLat.lat];
    }
    /**
     * @event MiniMapViewModel#minimapmouseuped
     * @description 鹰眼图按下后触发。
     * @property {Object} result - 返回的数据。
     */
    this.fire('minimapmousedown', {
      result: e
    });
  };
  _proto._mouseMove = function _mouseMove(e) {
    this._ticking = false;
    var miniMap = this._miniMap;
    var features = miniMap.queryRenderedFeatures(e.point, {
      layers: ['trackingRectFill']
    });
    if (!(this._isCursorOverFeature && features.length > 0)) {
      this._isCursorOverFeature = features.length > 0;
      this._miniMapCanvas.style.cursor = this._isCursorOverFeature ? 'move' : '';
    }
    if (this._isDragging) {
      this._previousPoint = this._currentPoint;
      this._currentPoint = [e.lngLat.lng, e.lngLat.lat];
      var offset = [this._previousPoint[0] - this._currentPoint[0], this._previousPoint[1] - this._currentPoint[1]];
      var newBounds = this._moveTrackingRect(offset);
      this._parentMap.fitBounds(newBounds, {
        duration: 80,
        noMoveStart: true
      });
    }
    /**
     * @event MiniMapViewModel#minimapmousemove
     * @description 鹰眼图移动后触发。
     * @property {Object} result - 返回的数据。
     */
    this.fire('minimapmousemoved', {
      result: e
    });
  };
  _proto._mouseUp = function _mouseUp(e) {
    this._isDragging = false;
    this._ticking = false;
    /**
     * @event MiniMapViewModel#minimapmouseup
     * @description 鹰眼图点击后触发。
     * @property {Object} result - 返回的数据。
     */
    this.fire('minimapmouseup', {
      result: e
    });
  };
  _proto._moveTrackingRect = function _moveTrackingRect(offset) {
    var source = this._trackingRect;
    var data = source._data;
    var bounds = data.properties.bounds;
    if (bounds) {
      bounds._ne.lat -= offset[1];
      bounds._ne.lng -= offset[0];
      bounds._sw.lat -= offset[1];
      bounds._sw.lng -= offset[0];
      this._convertBoundsToPoints(bounds);
      source.setData(data);
      return bounds;
    }
  };
  _proto._setTrackingRectBounds = function _setTrackingRectBounds(bounds) {
    var source = this._trackingRect;
    var data = source._data;
    data.properties.bounds = bounds;
    this._convertBoundsToPoints(bounds);
    source.setData(data);
  };
  _proto._convertBoundsToPoints = function _convertBoundsToPoints(bounds) {
    var ne = bounds._ne;
    var sw = bounds._sw;
    var trc = this._trackingRectCoordinates;
    ne = this._handleBounds(ne);
    sw = this._handleBounds(sw);
    trc[0][0][0] = ne.lng;
    trc[0][0][1] = ne.lat;
    trc[0][1][0] = sw.lng;
    trc[0][1][1] = ne.lat;
    trc[0][2][0] = sw.lng;
    trc[0][2][1] = sw.lat;
    trc[0][3][0] = ne.lng;
    trc[0][3][1] = sw.lat;
    trc[0][4][0] = ne.lng;
    trc[0][4][1] = ne.lat;
  };
  _proto._update = function _update(e) {
    if (this._isDragging) {
      return;
    }
    var parentBounds = this._parentMap.getBounds();
    this._setTrackingRectBounds(parentBounds);
    if (typeof this.options.zoomAdjust === 'function') {
      this.options.zoomAdjust();
    }
    /**
     * @event MiniMapViewModel#minimapmouseuped
     * @description 鹰眼图更新后触发。
     * @property {Object} result - 返回的数据。
     */
    this.fire('minimapupdated', {
      result: e
    });
  };
  _proto._zoomAdjust = function _zoomAdjust() {
    var miniMap = this._miniMap;
    var parentMap = this._parentMap;
    var parentZoom = parseFloat(parentMap.getZoom());
    miniMap.setCenter(parentMap.getCenter());
    var targetZoom = parentZoom - 5 > 0 ? parentZoom - 5 : 1;
    miniMap.setZoom(targetZoom);
  };
  _proto._preventDefault = function _preventDefault(e) {
    e.preventDefault();
  };
  _proto._handleBounds = function _handleBounds(latlng) {
    if (latlng.lng > 180) {
      latlng.lng = 180;
    } else if (latlng.lng < -180) {
      latlng.lng = -180;
    }
    if (latlng.lat > 90) {
      latlng.lat = 90;
    } else if (latlng.lat < -90) {
      latlng.lat = -90;
    }
    return latlng;
  };
  _proto._setStyle = function _setStyle() {
    this._miniMap.setStyle(this._parentMap.getStyle(), {
      localIdeographFontFamily: this._parentMap._localIdeographFontFamily
    });
    this._addRectLayers();
    this._update();
  };
  _proto._addRectLayers = function _addRectLayers() {
    var opts = this.options;
    this._miniMap.addSource('trackingRect', {
      type: 'geojson',
      data: {
        type: 'Feature',
        properties: {
          name: 'trackingRect'
        },
        geometry: {
          type: 'Polygon',
          coordinates: this._trackingRectCoordinates
        }
      }
    });
    this._miniMap.addLayer({
      id: 'trackingRectOutline',
      type: 'line',
      source: 'trackingRect',
      layout: {},
      paint: {
        'line-color': opts.lineColor,
        'line-width': opts.lineWidth,
        'line-opacity': opts.lineOpacity
      }
    });
    this._miniMap.addLayer({
      id: 'trackingRectFill',
      type: 'fill',
      source: 'trackingRect',
      layout: {},
      paint: {
        'fill-color': opts.fillColor,
        'fill-opacity': opts.fillOpacity
      }
    });
    this._trackingRect = this._miniMap.getSource('trackingRect');
  };
  _proto.removed = function removed() {
    var parentMap = this._parentMap;
    var miniMap = this._miniMap;
    parentMap && parentMap.off('move', this._updateFn);
    parentMap && parentMap.off('styledata', this._setStyleFn);
    miniMap && miniMap.off('mousemove', this._mouseMoveFn);
    miniMap && miniMap.off('mousedown', this._mouseDownFn);
    miniMap && miniMap.off('mouseup', this._mouseUpFn);
    miniMap && miniMap.remove();
  };
  return MiniMapViewModel;
}(_mapboxGlEnhance.default.Evented);

/***/ })

/******/ });