@antv/l7-component 2.9.32-alpha.4 → 2.9.32-alpha.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/es/control/baseControl/buttonControl.d.ts +1 -1
  2. package/es/control/baseControl/control.d.ts +4 -5
  3. package/es/control/baseControl/control.js +18 -5
  4. package/es/control/baseControl/popperControl.d.ts +1 -1
  5. package/es/control/baseControl/selectControl.d.ts +2 -2
  6. package/es/control/baseControl/selectControl.js +5 -0
  7. package/es/control/zoom.d.ts +3 -2
  8. package/lib/assets/iconfont/iconfont.js +46 -30
  9. package/lib/constants/index.js +34 -56
  10. package/lib/control/baseControl/buttonControl.js +194 -105
  11. package/lib/control/baseControl/control.js +317 -156
  12. package/lib/control/baseControl/index.js +57 -22
  13. package/lib/control/baseControl/popperControl.js +136 -102
  14. package/lib/control/baseControl/selectControl.js +230 -130
  15. package/lib/control/exportImage.js +175 -81
  16. package/lib/control/fullscreen.js +157 -102
  17. package/lib/control/geoLocate.js +143 -67
  18. package/lib/control/layerControl.js +162 -116
  19. package/lib/control/logo.js +101 -70
  20. package/lib/control/mapTheme.js +144 -85
  21. package/lib/control/mouseLocation.js +112 -71
  22. package/lib/control/scale.js +180 -127
  23. package/lib/control/zoom.js +154 -111
  24. package/lib/index.js +251 -48
  25. package/lib/interface.js +4 -16
  26. package/lib/marker-layer.js +367 -249
  27. package/lib/marker.js +419 -277
  28. package/lib/popup/layerPopup.js +305 -188
  29. package/lib/popup/popup.js +602 -339
  30. package/lib/utils/anchor.js +37 -55
  31. package/lib/utils/icon.js +13 -32
  32. package/lib/utils/popper.js +268 -180
  33. package/lib/utils/screenfull.js +110 -103
  34. package/package.json +5 -5
@@ -1,78 +1,154 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __export = (target, all) => {
8
- for (var name in all)
9
- __defProp(target, name, { get: all[name], enumerable: true });
10
- };
11
- var __copyProps = (to, from, except, desc) => {
12
- if (from && typeof from === "object" || typeof from === "function") {
13
- for (let key of __getOwnPropNames(from))
14
- if (!__hasOwnProp.call(to, key) && key !== except)
15
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
- }
17
- return to;
18
- };
19
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, mod));
20
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
21
-
22
- // src/control/geoLocate.ts
23
- var geoLocate_exports = {};
24
- __export(geoLocate_exports, {
25
- GeoLocate: () => GeoLocate,
26
- default: () => GeoLocate
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
27
7
  });
28
- module.exports = __toCommonJS(geoLocate_exports);
29
- var import_lodash = require("lodash");
30
- var import_icon = require("../utils/icon");
31
- var import_buttonControl = __toESM(require("./baseControl/buttonControl"));
32
- var GeoLocate = class extends import_buttonControl.default {
33
- constructor(option) {
34
- super(option);
35
- this.getGeoLocation = () => {
36
- return new Promise((resolve, reject) => {
37
- window.navigator.geolocation.getCurrentPosition(({ coords }) => {
38
- const { longitude, latitude } = coords ?? {};
39
- if (!(0, import_lodash.isNaN)(longitude) && !(0, import_lodash.isNaN)(latitude)) {
8
+ exports.default = exports.GeoLocate = void 0;
9
+
10
+ var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
11
+
12
+ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
13
+
14
+ var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
15
+
16
+ var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
17
+
18
+ var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
19
+
20
+ var _assertThisInitialized2 = _interopRequireDefault(require("@babel/runtime/helpers/assertThisInitialized"));
21
+
22
+ var _get2 = _interopRequireDefault(require("@babel/runtime/helpers/get"));
23
+
24
+ var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
25
+
26
+ var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
27
+
28
+ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
29
+
30
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
31
+
32
+ var _lodash = require("lodash");
33
+
34
+ var _icon = require("../utils/icon");
35
+
36
+ var _buttonControl = _interopRequireDefault(require("./baseControl/buttonControl"));
37
+
38
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
39
+
40
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
41
+
42
+ var GeoLocate = /*#__PURE__*/function (_ButtonControl) {
43
+ (0, _inherits2.default)(GeoLocate, _ButtonControl);
44
+
45
+ var _super = _createSuper(GeoLocate);
46
+
47
+ function GeoLocate(option) {
48
+ var _this;
49
+
50
+ (0, _classCallCheck2.default)(this, GeoLocate);
51
+ _this = _super.call(this, option);
52
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "getGeoLocation", function () {
53
+ return new Promise(function (resolve, reject) {
54
+ window.navigator.geolocation.getCurrentPosition(function (_ref) {
55
+ var coords = _ref.coords;
56
+
57
+ var _ref2 = coords !== null && coords !== void 0 ? coords : {},
58
+ longitude = _ref2.longitude,
59
+ latitude = _ref2.latitude;
60
+
61
+ if (!(0, _lodash.isNaN)(longitude) && !(0, _lodash.isNaN)(latitude)) {
40
62
  resolve([longitude, latitude]);
41
63
  } else {
42
64
  reject();
43
65
  }
44
- }, (e) => {
66
+ }, function (e) {
45
67
  reject(e);
46
68
  });
47
69
  });
48
- };
49
- this.onClick = async () => {
50
- if (!window.navigator.geolocation) {
51
- return;
52
- }
53
- const { transform } = this.controlOption;
54
- const position = await this.getGeoLocation();
55
- const currentZoom = this.mapsService.getZoom();
56
- this.mapsService.setZoomAndCenter(currentZoom > 15 ? currentZoom : 15, transform ? await transform(position) : position);
57
- };
70
+ });
71
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onClick", /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
72
+ var transform, position, currentZoom;
73
+ return _regenerator.default.wrap(function _callee$(_context) {
74
+ while (1) {
75
+ switch (_context.prev = _context.next) {
76
+ case 0:
77
+ if (window.navigator.geolocation) {
78
+ _context.next = 2;
79
+ break;
80
+ }
81
+
82
+ return _context.abrupt("return");
83
+
84
+ case 2:
85
+ transform = _this.controlOption.transform;
86
+ _context.next = 5;
87
+ return _this.getGeoLocation();
88
+
89
+ case 5:
90
+ position = _context.sent;
91
+ currentZoom = _this.mapsService.getZoom();
92
+ _context.t0 = _this.mapsService;
93
+ _context.t1 = currentZoom > 15 ? currentZoom : 15;
94
+
95
+ if (!transform) {
96
+ _context.next = 15;
97
+ break;
98
+ }
99
+
100
+ _context.next = 12;
101
+ return transform(position);
102
+
103
+ case 12:
104
+ _context.t2 = _context.sent;
105
+ _context.next = 16;
106
+ break;
107
+
108
+ case 15:
109
+ _context.t2 = position;
110
+
111
+ case 16:
112
+ _context.t3 = _context.t2;
113
+
114
+ _context.t0.setZoomAndCenter.call(_context.t0, _context.t1, _context.t3);
115
+
116
+ case 18:
117
+ case "end":
118
+ return _context.stop();
119
+ }
120
+ }
121
+ }, _callee);
122
+ })));
123
+
58
124
  if (!window.navigator.geolocation) {
59
- console.warn("\u5F53\u524D\u6D4F\u89C8\u5668\u73AF\u5883\u4E0D\u652F\u6301\u83B7\u53D6\u5730\u7406\u5B9A\u4F4D");
125
+ console.warn('当前浏览器环境不支持获取地理定位');
60
126
  }
127
+
128
+ return _this;
61
129
  }
62
- getDefault(option) {
63
- return {
64
- ...super.getDefault(option),
65
- title: "\u5B9A\u4F4D",
66
- btnIcon: (0, import_icon.createL7Icon)("l7-icon-reposition")
67
- };
68
- }
69
- onAdd() {
70
- const button = super.onAdd();
71
- button.addEventListener("click", this.onClick);
72
- return button;
73
- }
74
- };
75
- // Annotate the CommonJS export names for ESM import in node:
76
- 0 && (module.exports = {
77
- GeoLocate
78
- });
130
+
131
+ (0, _createClass2.default)(GeoLocate, [{
132
+ key: "getDefault",
133
+ value: function getDefault(option) {
134
+ return (0, _objectSpread2.default)((0, _objectSpread2.default)({}, (0, _get2.default)((0, _getPrototypeOf2.default)(GeoLocate.prototype), "getDefault", this).call(this, option)), {}, {
135
+ title: '定位',
136
+ btnIcon: (0, _icon.createL7Icon)('l7-icon-reposition')
137
+ });
138
+ }
139
+ }, {
140
+ key: "onAdd",
141
+ value: function onAdd() {
142
+ var button = (0, _get2.default)((0, _getPrototypeOf2.default)(GeoLocate.prototype), "onAdd", this).call(this);
143
+ button.addEventListener('click', this.onClick);
144
+ return button;
145
+ }
146
+ /**
147
+ * 通过浏览器 API 获取当前所在经纬度
148
+ */
149
+
150
+ }]);
151
+ return GeoLocate;
152
+ }(_buttonControl.default);
153
+
154
+ exports.default = exports.GeoLocate = GeoLocate;
@@ -1,136 +1,182 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __export = (target, all) => {
8
- for (var name in all)
9
- __defProp(target, name, { get: all[name], enumerable: true });
10
- };
11
- var __copyProps = (to, from, except, desc) => {
12
- if (from && typeof from === "object" || typeof from === "function") {
13
- for (let key of __getOwnPropNames(from))
14
- if (!__hasOwnProp.call(to, key) && key !== except)
15
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
- }
17
- return to;
18
- };
19
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, mod));
20
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
21
-
22
- // src/control/layerControl.ts
23
- var layerControl_exports = {};
24
- __export(layerControl_exports, {
25
- LayerControl: () => LayerControl,
26
- default: () => LayerControl
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
27
7
  });
28
- module.exports = __toCommonJS(layerControl_exports);
29
- var import_icon = require("../utils/icon");
30
- var import_selectControl = __toESM(require("./baseControl/selectControl"));
31
- var LayerControl = class extends import_selectControl.default {
32
- constructor() {
33
- super(...arguments);
34
- this.bindLayerVisibleCallback = () => {
35
- this.layers.forEach((layer) => {
36
- layer.on("show", this.onLayerVisibleChane);
37
- layer.on("hide", this.onLayerVisibleChane);
8
+ exports.default = exports.LayerControl = void 0;
9
+
10
+ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
11
+
12
+ var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
13
+
14
+ var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
15
+
16
+ var _assertThisInitialized2 = _interopRequireDefault(require("@babel/runtime/helpers/assertThisInitialized"));
17
+
18
+ var _get2 = _interopRequireDefault(require("@babel/runtime/helpers/get"));
19
+
20
+ var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
21
+
22
+ var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
23
+
24
+ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
25
+
26
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
27
+
28
+ var _icon = require("../utils/icon");
29
+
30
+ var _selectControl = _interopRequireDefault(require("./baseControl/selectControl"));
31
+
32
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
33
+
34
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
35
+
36
+ var LayerControl = /*#__PURE__*/function (_SelectControl) {
37
+ (0, _inherits2.default)(LayerControl, _SelectControl);
38
+
39
+ var _super = _createSuper(LayerControl);
40
+
41
+ function LayerControl() {
42
+ var _this;
43
+
44
+ (0, _classCallCheck2.default)(this, LayerControl);
45
+
46
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
47
+ args[_key] = arguments[_key];
48
+ }
49
+
50
+ _this = _super.call.apply(_super, [this].concat(args));
51
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "bindLayerVisibleCallback", function () {
52
+ _this.layers.forEach(function (layer) {
53
+ layer.on('show', _this.onLayerVisibleChane);
54
+ layer.on('hide', _this.onLayerVisibleChane);
38
55
  });
39
- };
40
- this.unbindLayerVisibleCallback = () => {
41
- this.layers.forEach((layer) => {
42
- layer.off("show", this.onLayerVisibleChane);
43
- layer.off("hide", this.onLayerVisibleChane);
56
+ });
57
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "unbindLayerVisibleCallback", function () {
58
+ _this.layers.forEach(function (layer) {
59
+ layer.off('show', _this.onLayerVisibleChane);
60
+ layer.off('hide', _this.onLayerVisibleChane);
44
61
  });
45
- };
46
- this.onLayerChange = () => {
47
- var _a;
48
- if ((_a = this.controlOption.layers) == null ? void 0 : _a.length) {
62
+ });
63
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onLayerChange", function () {
64
+ var _this$controlOption$l;
65
+
66
+ if ((_this$controlOption$l = _this.controlOption.layers) !== null && _this$controlOption$l !== void 0 && _this$controlOption$l.length) {
49
67
  return;
50
68
  }
51
- this.selectValue = this.getLayerVisible();
52
- this.setOptions({
53
- options: this.getLayerOptions()
69
+
70
+ _this.selectValue = _this.getLayerVisible();
71
+
72
+ _this.setOptions({
73
+ options: _this.getLayerOptions()
54
74
  });
55
- };
56
- this.onLayerVisibleChane = () => {
57
- this.setSelectValue(this.getLayerVisible());
58
- };
59
- this.onSelectChange = () => {
60
- this.layers.forEach((layer) => {
61
- const needShow = this.selectValue.includes(layer.name);
62
- const isShow = layer.isVisible();
75
+ });
76
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onLayerVisibleChane", function () {
77
+ _this.setSelectValue(_this.getLayerVisible());
78
+ });
79
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "onSelectChange", function () {
80
+ _this.layers.forEach(function (layer) {
81
+ var needShow = _this.selectValue.includes(layer.name);
82
+
83
+ var isShow = layer.isVisible();
84
+
63
85
  if (needShow && !isShow) {
64
86
  layer.show();
65
87
  }
88
+
66
89
  if (!needShow && isShow) {
67
90
  layer.hide();
68
91
  }
69
92
  });
70
- };
71
- }
72
- get layers() {
73
- return this.controlOption.layers || this.layerService.getLayers() || [];
74
- }
75
- getDefault(option) {
76
- return {
77
- ...super.getDefault(option),
78
- title: "\u56FE\u5C42\u63A7\u5236",
79
- btnIcon: (0, import_icon.createL7Icon)("l7-icon-layer"),
80
- options: []
81
- };
82
- }
83
- getLayerVisible() {
84
- return this.layers.filter((layer) => {
85
- return layer.isVisible();
86
- }).map((layer) => {
87
- return layer.name;
88
93
  });
94
+ return _this;
89
95
  }
90
- getLayerOptions() {
91
- return this.layers.map((layer) => {
92
- return {
93
- text: layer.name,
94
- value: layer.name
95
- };
96
- });
97
- }
98
- setOptions(option) {
99
- const isLayerChange = this.checkUpdateOption(option, ["layers"]);
100
- if (isLayerChange) {
101
- this.unbindLayerVisibleCallback();
96
+
97
+ (0, _createClass2.default)(LayerControl, [{
98
+ key: "layers",
99
+ get: function get() {
100
+ return this.controlOption.layers || this.layerService.getLayers() || [];
101
+ }
102
+ }, {
103
+ key: "getDefault",
104
+ value: function getDefault(option) {
105
+ return (0, _objectSpread2.default)((0, _objectSpread2.default)({}, (0, _get2.default)((0, _getPrototypeOf2.default)(LayerControl.prototype), "getDefault", this).call(this, option)), {}, {
106
+ title: '图层控制',
107
+ btnIcon: (0, _icon.createL7Icon)('l7-icon-layer'),
108
+ options: []
109
+ });
110
+ }
111
+ }, {
112
+ key: "getLayerVisible",
113
+ value: function getLayerVisible() {
114
+ return this.layers.filter(function (layer) {
115
+ return layer.isVisible();
116
+ }).map(function (layer) {
117
+ return layer.name;
118
+ });
119
+ }
120
+ }, {
121
+ key: "getLayerOptions",
122
+ value: function getLayerOptions() {
123
+ return this.layers.map(function (layer) {
124
+ return {
125
+ text: layer.name,
126
+ value: layer.name
127
+ };
128
+ });
129
+ }
130
+ }, {
131
+ key: "setOptions",
132
+ value: function setOptions(option) {
133
+ var isLayerChange = this.checkUpdateOption(option, ['layers']);
134
+
135
+ if (isLayerChange) {
136
+ this.unbindLayerVisibleCallback();
137
+ }
138
+
139
+ (0, _get2.default)((0, _getPrototypeOf2.default)(LayerControl.prototype), "setOptions", this).call(this, option);
140
+
141
+ if (isLayerChange) {
142
+ this.bindLayerVisibleCallback();
143
+ this.selectValue = this.getLayerVisible();
144
+ this.controlOption.options = this.getLayerOptions();
145
+ this.popper.setContent(this.getPopperContent(this.controlOption.options));
146
+ }
102
147
  }
103
- super.setOptions(option);
104
- if (isLayerChange) {
148
+ }, {
149
+ key: "onAdd",
150
+ value: function onAdd() {
151
+ var _this$controlOption$o;
152
+
153
+ if (!((_this$controlOption$o = this.controlOption.options) !== null && _this$controlOption$o !== void 0 && _this$controlOption$o.length)) {
154
+ this.controlOption.options = this.getLayerOptions();
155
+ }
156
+
157
+ if (!this.controlOption.defaultValue) {
158
+ this.controlOption.defaultValue = this.getLayerVisible();
159
+ }
160
+
161
+ this.on('selectChange', this.onSelectChange);
162
+ this.layerService.on('layerChange', this.onLayerChange);
105
163
  this.bindLayerVisibleCallback();
106
- this.selectValue = this.getLayerVisible();
107
- this.controlOption.options = this.getLayerOptions();
108
- this.popper.setContent(this.getPopperContent(this.controlOption.options));
164
+ return (0, _get2.default)((0, _getPrototypeOf2.default)(LayerControl.prototype), "onAdd", this).call(this);
109
165
  }
110
- }
111
- onAdd() {
112
- var _a;
113
- if (!((_a = this.controlOption.options) == null ? void 0 : _a.length)) {
114
- this.controlOption.options = this.getLayerOptions();
166
+ }, {
167
+ key: "onRemove",
168
+ value: function onRemove() {
169
+ this.off('selectChange', this.onSelectChange);
170
+ this.layerService.off('layerChange', this.onLayerChange);
171
+ this.unbindLayerVisibleCallback();
115
172
  }
116
- if (!this.controlOption.defaultValue) {
117
- this.controlOption.defaultValue = this.getLayerVisible();
173
+ }, {
174
+ key: "getIsMultiple",
175
+ value: function getIsMultiple() {
176
+ return true;
118
177
  }
119
- this.on("selectChange", this.onSelectChange);
120
- this.layerService.on("layerChange", this.onLayerChange);
121
- this.bindLayerVisibleCallback();
122
- return super.onAdd();
123
- }
124
- onRemove() {
125
- this.off("selectChange", this.onSelectChange);
126
- this.layerService.off("layerChange", this.onLayerChange);
127
- this.unbindLayerVisibleCallback();
128
- }
129
- getIsMultiple() {
130
- return true;
131
- }
132
- };
133
- // Annotate the CommonJS export names for ESM import in node:
134
- 0 && (module.exports = {
135
- LayerControl
136
- });
178
+ }]);
179
+ return LayerControl;
180
+ }(_selectControl.default);
181
+
182
+ exports.default = exports.LayerControl = LayerControl;