@appbaseio/reactivesearch-vue 2.0.0-alpha.3 → 3.0.0-alpha.0

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 (108) hide show
  1. package/dist/@appbaseio/reactivesearch-vue.umd.js +17405 -25231
  2. package/dist/@appbaseio/reactivesearch-vue.umd.js.map +1 -1
  3. package/dist/@appbaseio/reactivesearch-vue.umd.min.js +6 -15
  4. package/dist/@appbaseio/reactivesearch-vue.umd.min.js.map +1 -1
  5. package/dist/cjs/Button-ad042719.js +59 -0
  6. package/dist/cjs/Card-f5ab024a.js +27 -0
  7. package/dist/cjs/{ComponentWrapper-ad3dad02.js → ComponentWrapper-75f88599.js} +42 -56
  8. package/dist/cjs/Container-29f049b2.js +12 -0
  9. package/dist/cjs/DropDown-6cf84c47.js +698 -0
  10. package/dist/cjs/DynamicRangeSlider.js +103 -155
  11. package/dist/cjs/Flex-d5675ea6.js +48 -0
  12. package/dist/cjs/FormControlList-fadd792f.js +42 -0
  13. package/dist/cjs/Input-4b434436.js +74 -0
  14. package/dist/cjs/ListItem-d57d648d.js +42 -0
  15. package/dist/cjs/MultiDropdownList.js +124 -240
  16. package/dist/cjs/MultiList.js +123 -261
  17. package/dist/cjs/MultiRange.js +87 -133
  18. package/dist/cjs/{Pagination-71e85fa9.js → Pagination-b5ddc906.js} +70 -83
  19. package/dist/cjs/PreferencesConsumer-eb265924.js +75 -0
  20. package/dist/cjs/RangeInput.js +163 -171
  21. package/dist/cjs/RangeSlider.js +81 -109
  22. package/dist/cjs/ReactiveBase.js +139 -157
  23. package/dist/cjs/ReactiveComponent-eb8db4c1.js +2189 -0
  24. package/dist/cjs/ReactiveComponent.js +46 -340
  25. package/dist/cjs/ReactiveGoogleMap.js +445 -655
  26. package/dist/cjs/ReactiveList.js +179 -304
  27. package/dist/cjs/ResultCard.js +36 -36
  28. package/dist/cjs/ResultList.js +48 -56
  29. package/dist/cjs/SelectedFilters.js +62 -69
  30. package/dist/cjs/SingleDropdownList.js +117 -177
  31. package/dist/cjs/SingleList.js +121 -205
  32. package/dist/cjs/SingleRange.js +78 -105
  33. package/dist/cjs/StateProvider.js +74 -47
  34. package/dist/cjs/Title-8802a218.js +12 -0
  35. package/dist/cjs/ToggleButton.js +72 -119
  36. package/dist/cjs/{_rollupPluginBabelHelpers-c705cbe6.js → _rollupPluginBabelHelpers-f8b843f8.js} +0 -15
  37. package/dist/cjs/{index-6a167fe0.js → index-d8d8f291.js} +38 -108
  38. package/dist/cjs/index.js +44 -41
  39. package/dist/cjs/initReactivesearch.js +69 -152
  40. package/dist/cjs/install.js +47 -43
  41. package/dist/cjs/ssr-6907ada3.js +66 -0
  42. package/dist/cjs/{utils-d6a52588.js → utils-83fd01e9.js} +7 -16
  43. package/dist/cjs/version.js +1 -1
  44. package/dist/cjs/{vueTypes-727b7c63.js → vueTypes-1bf00978.js} +8 -19
  45. package/dist/es/Button-474510e3.js +53 -0
  46. package/dist/es/{Card-450683f1.js → Card-38cbe652.js} +3 -3
  47. package/dist/es/{ComponentWrapper-424e86fd.js → ComponentWrapper-5166c76a.js} +42 -56
  48. package/dist/es/{Container-ba826e96.js → Container-d00219f7.js} +2 -2
  49. package/dist/es/DropDown-8764360c.js +688 -0
  50. package/dist/es/DynamicRangeSlider.js +103 -155
  51. package/dist/es/Flex-a08e22d7.js +46 -0
  52. package/dist/es/FormControlList-fe6eaee4.js +38 -0
  53. package/dist/es/Input-4a8ef1f3.js +69 -0
  54. package/dist/es/{ListItem-cad14c5e.js → ListItem-16756c02.js} +7 -8
  55. package/dist/es/MultiDropdownList.js +124 -240
  56. package/dist/es/MultiList.js +123 -261
  57. package/dist/es/MultiRange.js +87 -133
  58. package/dist/es/{Pagination-784bf143.js → Pagination-72bd1d9e.js} +70 -83
  59. package/dist/es/PreferencesConsumer-c276709c.js +73 -0
  60. package/dist/es/RangeInput.js +163 -170
  61. package/dist/es/RangeSlider.js +81 -109
  62. package/dist/es/ReactiveBase.js +138 -155
  63. package/dist/es/ReactiveComponent-f9fa5780.js +2183 -0
  64. package/dist/es/ReactiveComponent.js +42 -337
  65. package/dist/es/ReactiveGoogleMap.js +440 -649
  66. package/dist/es/ReactiveList.js +177 -301
  67. package/dist/es/ResultCard.js +36 -36
  68. package/dist/es/ResultList.js +48 -56
  69. package/dist/es/SelectedFilters.js +62 -69
  70. package/dist/es/SingleDropdownList.js +117 -177
  71. package/dist/es/SingleList.js +121 -205
  72. package/dist/es/SingleRange.js +78 -105
  73. package/dist/es/StateProvider.js +75 -48
  74. package/dist/es/{Title-3342664a.js → Title-863dfa42.js} +2 -2
  75. package/dist/es/ToggleButton.js +72 -119
  76. package/dist/es/{_rollupPluginBabelHelpers-76660dab.js → _rollupPluginBabelHelpers-ded08042.js} +0 -15
  77. package/dist/es/{index-7788a843.js → index-4520a598.js} +39 -107
  78. package/dist/es/index.js +30 -32
  79. package/dist/es/initReactivesearch.js +69 -152
  80. package/dist/es/install.js +49 -41
  81. package/dist/es/{ssr-b2c0b401.js → ssr-af398f0c.js} +36 -7
  82. package/dist/es/{utils-9e68acee.js → utils-9e5a16a1.js} +7 -16
  83. package/dist/es/version.js +1 -1
  84. package/dist/es/{vueTypes-b8146772.js → vueTypes-f1923c72.js} +8 -19
  85. package/package.json +10 -9
  86. package/dist/cjs/Button-446f819e.js +0 -68
  87. package/dist/cjs/CancelSvg-9f258f4f.js +0 -449
  88. package/dist/cjs/Card-642547a8.js +0 -30
  89. package/dist/cjs/Container-daf30918.js +0 -15
  90. package/dist/cjs/DataSearch-6cf29cf0.js +0 -2323
  91. package/dist/cjs/DataSearch.js +0 -30
  92. package/dist/cjs/DropDown-c479bbb0.js +0 -328
  93. package/dist/cjs/Flex-aa517a13.js +0 -52
  94. package/dist/cjs/FormControlList-c195a592.js +0 -47
  95. package/dist/cjs/Input-e6603a7e.js +0 -79
  96. package/dist/cjs/ListItem-8c9e0d68.js +0 -46
  97. package/dist/cjs/Title-1de7d0f4.js +0 -15
  98. package/dist/cjs/install-42ba1d44.js +0 -1409
  99. package/dist/cjs/ssr-3027b848.js +0 -39
  100. package/dist/es/Button-d8bc15ea.js +0 -59
  101. package/dist/es/CancelSvg-4cfae5fd.js +0 -440
  102. package/dist/es/DataSearch-4888aa43.js +0 -2308
  103. package/dist/es/DataSearch.js +0 -22
  104. package/dist/es/DropDown-05a644a5.js +0 -322
  105. package/dist/es/Flex-1f0795c3.js +0 -47
  106. package/dist/es/FormControlList-c22d64f6.js +0 -40
  107. package/dist/es/Input-7a2a9fac.js +0 -71
  108. package/dist/es/install-80bc2764.js +0 -1402
@@ -1,38 +1,41 @@
1
1
  import { Actions, helper } from '@appbaseio/reactivecore';
2
- import { a as _extends, b as _objectWithoutPropertiesLoose, c as _toPropertyKey, d as _inheritsLoose, _ as _taggedTemplateLiteralLoose } from './_rollupPluginBabelHelpers-76660dab.js';
3
- import VueTypes from 'vue-types';
4
2
  import { componentTypes } from '@appbaseio/reactivecore/lib/utils/constants';
5
- import 'emotion';
6
- import styled, { css } from '@appbaseio/vue-emotion';
3
+ import _transformOn from '@vue/babel-helper-vue-transform-on';
4
+ import { a as _extends, b as _objectWithoutPropertiesLoose, c as _toPropertyKey, d as _inheritsLoose, _ as _taggedTemplateLiteralLoose } from './_rollupPluginBabelHelpers-ded08042.js';
5
+ import { createVNode, mergeProps } from 'vue';
6
+ import VueTypes from 'vue-types';
7
+ import { styled } from '@appbaseio/vue-emotion';
8
+ import { css } from 'emotion';
7
9
  import 'polished';
8
- import './Button-d8bc15ea.js';
9
- import { t as types } from './vueTypes-b8146772.js';
10
- import { P as Pagination } from './Pagination-784bf143.js';
10
+ import './Button-474510e3.js';
11
+ import { t as types } from './vueTypes-f1923c72.js';
12
+ import { P as Pagination } from './Pagination-72bd1d9e.js';
11
13
  import '@appbaseio/reactivecore/lib/utils/transform';
12
14
  import 'redux';
13
- import { h as hasCustomRenderer, i as isQueryIdentical, g as getComponent, a as isFunction, c as connect } from './index-7788a843.js';
14
- import { C as ComponentWrapper } from './ComponentWrapper-424e86fd.js';
15
- import _mergeJSXProps from '@vue/babel-helper-vue-jsx-merge-props';
16
- import { C as Checkbox } from './FormControlList-c22d64f6.js';
17
- import GmapVue, { components } from 'gmap-vue';
15
+ import { h as hasCustomRenderer, i as isQueryIdentical, g as getComponent, a as isFunction, c as connect } from './index-4520a598.js';
16
+ import { C as ComponentWrapper } from './ComponentWrapper-5166c76a.js';
17
+ import { P as PreferencesConsumer } from './PreferencesConsumer-c276709c.js';
18
+ import { C as Checkbox } from './FormControlList-fe6eaee4.js';
19
+ import VueGoogleMaps, { InfoWindow, MapElementMixin, Marker, GMapCluster, Map } from 'vue-google-maps-community-fork';
18
20
  import geohash from 'ngeohash';
19
21
 
20
22
  var setStreaming = Actions.setStreaming,
21
- setQueryOptions = Actions.setQueryOptions,
22
- updateQuery = Actions.updateQuery,
23
- loadMore = Actions.loadMore,
24
- setValue = Actions.setValue,
25
- updateComponentProps = Actions.updateComponentProps,
26
- setDefaultQuery = Actions.setDefaultQuery,
27
- recordResultClick = Actions.recordResultClick,
28
- setMapData = Actions.setMapData;
23
+ setQueryOptions = Actions.setQueryOptions,
24
+ updateQuery = Actions.updateQuery,
25
+ loadMore = Actions.loadMore,
26
+ setValue = Actions.setValue,
27
+ updateComponentProps = Actions.updateComponentProps,
28
+ setDefaultQuery = Actions.setDefaultQuery,
29
+ recordResultClick = Actions.recordResultClick,
30
+ setMapData = Actions.setMapData;
29
31
  var isEqual = helper.isEqual,
30
- getQueryOptions = helper.getQueryOptions,
31
- getClassName = helper.getClassName,
32
- parseHits = helper.parseHits,
33
- getOptionsFromQuery = helper.getOptionsFromQuery,
34
- getResultStats = helper.getResultStats; // default map center
32
+ getQueryOptions = helper.getQueryOptions,
33
+ getClassName = helper.getClassName,
34
+ parseHits = helper.parseHits,
35
+ getOptionsFromQuery = helper.getOptionsFromQuery,
36
+ getResultStats = helper.getResultStats;
35
37
 
38
+ // default map center
36
39
  var MAP_CENTER = {
37
40
  lat: 37.7749,
38
41
  lng: 122.4194
@@ -42,37 +45,28 @@ var style = {
42
45
  height: '100vh',
43
46
  position: 'relative'
44
47
  };
45
-
46
48
  function getPrecision(a) {
47
49
  if (isNaN(a)) return 0; // eslint-disable-line
48
-
49
50
  var e = 1;
50
51
  var p = 0;
51
-
52
52
  while (Math.round(a * e) / e !== a) {
53
53
  e *= 10;
54
54
  p += 1;
55
55
  }
56
-
57
56
  return p;
58
57
  }
59
-
60
58
  function withDistinctLat(loc, count) {
61
59
  var length = getPrecision(loc.lat);
62
- var noiseFactor = length >= 6 ? 4 : length - 2; // eslint-disable-next-line
63
-
60
+ var noiseFactor = length >= 6 ? 4 : length - 2;
61
+ // eslint-disable-next-line
64
62
  var suffix = 1 / Math.pow(10, noiseFactor) * count;
65
-
66
63
  var location = _extends({}, loc, {
67
64
  lat: parseFloat((loc.lat + suffix).toFixed(length))
68
65
  });
69
-
70
66
  return location;
71
67
  }
72
-
73
68
  function getLocationObject(location) {
74
69
  var resultType = Array.isArray(location) ? 'array' : typeof location;
75
-
76
70
  switch (resultType) {
77
71
  case 'string':
78
72
  {
@@ -83,14 +77,12 @@ function getLocationObject(location) {
83
77
  lng: parseFloat(locationSplit[1])
84
78
  };
85
79
  }
86
-
87
80
  var locationDecode = geohash.decode(location);
88
81
  return {
89
82
  lat: locationDecode.latitude,
90
83
  lng: locationDecode.longitude
91
84
  };
92
85
  }
93
-
94
86
  case 'array':
95
87
  {
96
88
  return {
@@ -98,14 +90,12 @@ function getLocationObject(location) {
98
90
  lng: location[0]
99
91
  };
100
92
  }
101
-
102
93
  default:
103
94
  {
104
95
  return location;
105
96
  }
106
97
  }
107
98
  }
108
-
109
99
  var ReactiveMap = {
110
100
  name: 'ReactiveMap',
111
101
  props: {
@@ -146,11 +136,9 @@ var ReactiveMap = {
146
136
  data: function data() {
147
137
  var props = this.$props;
148
138
  var currentPageState = 0;
149
-
150
139
  if (props.currentPage) {
151
140
  currentPageState = Math.max(props.currentPage - 1, 0);
152
141
  }
153
-
154
142
  this.__state = {
155
143
  from: currentPageState * props.size,
156
144
  zoom: props.defaultZoom,
@@ -167,8 +155,7 @@ var ReactiveMap = {
167
155
  },
168
156
  stats: function stats() {
169
157
  var _this$getAllData = this.getAllData(),
170
- resultsToRender = _this$getAllData.resultsToRender;
171
-
158
+ resultsToRender = _this$getAllData.resultsToRender;
172
159
  return _extends({}, getResultStats(this), {
173
160
  currentPage: this.currentPageState,
174
161
  displayedResults: resultsToRender.length
@@ -192,26 +179,21 @@ var ReactiveMap = {
192
179
  var options = getQueryOptions(this.$props);
193
180
  options.from = 0;
194
181
  this.$defaultQuery = newVal(null, this.$props);
195
-
196
182
  var _ref = this.$defaultQuery || {},
197
- sort = _ref.sort,
198
- query = _ref.query;
199
-
183
+ sort = _ref.sort,
184
+ query = _ref.query;
200
185
  if (sort) {
201
186
  options.sort = this.$defaultQuery.sort;
202
187
  }
203
-
204
188
  var queryOptions = getOptionsFromQuery(this.$defaultQuery);
205
-
206
189
  if (queryOptions) {
207
190
  options = _extends({}, options, getOptionsFromQuery(this.$defaultQuery));
208
- } // Update calculated default query in store
209
-
210
-
191
+ }
192
+ // Update calculated default query in store
211
193
  this.setQueryOptions(this.$props.componentId, options, false);
212
194
  var persistMapQuery = true;
213
- var forceExecute = true; // Update default query to include the geo bounding box query
214
-
195
+ var forceExecute = true;
196
+ // Update default query to include the geo bounding box query
215
197
  this.setDefaultQueryForRSAPI();
216
198
  var meta = {
217
199
  mapBoxBounds: this.mapBoxBounds
@@ -238,7 +220,6 @@ var ReactiveMap = {
238
220
  },
239
221
  hits: function hits(newVal, oldVal) {
240
222
  this.$emit('data', this.getData());
241
-
242
223
  if (this.pagination) {
243
224
  // called when page is changed
244
225
  if (this.isLoading && (oldVal || newVal)) {
@@ -248,54 +229,46 @@ var ReactiveMap = {
248
229
  },
249
230
  rawData: function rawData(newVal, oldVal) {
250
231
  var _this = this;
251
-
252
232
  if (!isEqual(newVal, oldVal)) {
253
233
  var promotedResults = this.promotedResults,
254
- hits = this.hits;
234
+ hits = this.hits;
255
235
  var results = parseHits(hits) || [];
256
236
  var parsedPromotedResults = parseHits(promotedResults) || [];
257
237
  var filteredResults = results;
258
-
259
238
  if (parsedPromotedResults.length) {
260
239
  var ids = parsedPromotedResults.map(function (item) {
261
240
  return item._id;
262
241
  }).filter(Boolean);
263
-
264
242
  if (ids) {
265
243
  filteredResults = filteredResults.filter(function (item) {
266
244
  return !ids.includes(item._id);
267
245
  });
268
246
  }
269
-
270
247
  filteredResults = [].concat(parsedPromotedResults, filteredResults);
271
248
  }
272
-
273
249
  filteredResults = filteredResults.filter(function (item) {
274
250
  return !!item[_this.dataField];
275
251
  }).map(function (item) {
276
252
  var _extends2;
277
-
278
253
  return _extends({}, item, (_extends2 = {}, _extends2[_this.dataField] = getLocationObject(item[_this.dataField]), _extends2));
279
254
  });
280
255
  this.filteredResults = this.addNoise(filteredResults);
281
-
282
256
  if (this.calculateMarkers) {
283
257
  this.markersData = this.calculateMarkers({
284
258
  data: this.filteredResults,
285
259
  rawData: this.rawData
286
260
  }) || [];
287
261
  }
288
-
289
262
  this.$emit('data', this.getData());
290
263
  }
291
264
  },
292
265
  center: function center(newVal, oldVal) {
293
266
  if (!isEqual(newVal, oldVal)) {
294
- var persistMapQuery = !!this.center; // we need to forceExecute the query because the center has changed
295
-
267
+ var persistMapQuery = !!this.center;
268
+ // we need to forceExecute the query because the center has changed
296
269
  var forceExecute = true;
297
- var geoQuery = this.getGeoQuery(this.$props); // Update default query for RS API
298
-
270
+ var geoQuery = this.getGeoQuery(this.$props);
271
+ // Update default query for RS API
299
272
  this.setDefaultQueryForRSAPI();
300
273
  var meta = {
301
274
  mapBoxBounds: this.mapBoxBounds
@@ -312,7 +285,6 @@ var ReactiveMap = {
312
285
  lng: Number(location[1])
313
286
  };
314
287
  }
315
-
316
288
  return {
317
289
  lat: location ? Number(location.lat) : this.defaultCenter.lat,
318
290
  lng: location ? Number(location.lon === undefined ? location.lng : location.lon) : this.defaultCenter.lng
@@ -324,14 +296,11 @@ var ReactiveMap = {
324
296
  },
325
297
  addNoise: function addNoise(hits) {
326
298
  var _this2 = this;
327
-
328
299
  var hitMap = {};
329
300
  var updatedHits = [];
330
301
  hits.forEach(function (item) {
331
302
  var updatedItem = _extends({}, item);
332
-
333
303
  var location = _this2.parseLocation(item[_this2.dataField]);
334
-
335
304
  var key = JSON.stringify(location);
336
305
  var count = hitMap[key] || 0;
337
306
  updatedItem[_this2.dataField] = count ? withDistinctLat(location, count) : location;
@@ -344,16 +313,13 @@ var ReactiveMap = {
344
313
  if (result) {
345
314
  return this.parseLocation(result[this.dataField]);
346
315
  }
347
-
348
316
  return null;
349
317
  },
350
318
  getHitsCenter: function getHitsCenter(hits) {
351
319
  var _this3 = this;
352
-
353
320
  var data = hits.map(function (hit) {
354
321
  return hit[_this3.dataField];
355
322
  });
356
-
357
323
  if (data.length) {
358
324
  var numCoords = data.length;
359
325
  var X = 0.0;
@@ -377,8 +343,8 @@ var ReactiveMap = {
377
343
  X /= numCoords;
378
344
  Y /= numCoords;
379
345
  Z /= numCoords;
380
- var lng = Math.atan2(Y, X); // eslint-disable-next-line
381
-
346
+ var lng = Math.atan2(Y, X);
347
+ // eslint-disable-next-line
382
348
  var hyp = Math.sqrt(X * X + Y * Y);
383
349
  var lat = Math.atan2(Z, hyp);
384
350
  var newX = lat * 180 / Math.PI;
@@ -388,18 +354,14 @@ var ReactiveMap = {
388
354
  lng: newY
389
355
  };
390
356
  }
391
-
392
357
  return false;
393
358
  },
394
359
  getCenter: function getCenter(hits) {
395
360
  var _this4 = this;
396
-
397
361
  if (this.center) {
398
362
  return this.parseLocation(this.center);
399
363
  }
400
-
401
364
  var mapRef = this.getMapRef();
402
-
403
365
  if (mapRef && typeof mapRef.getCenter === 'function' && this.$options.preserveCenter) {
404
366
  var currentCenter = mapRef.getCenter();
405
367
  setTimeout(function () {
@@ -410,21 +372,17 @@ var ReactiveMap = {
410
372
  lng: currentCenter.lng()
411
373
  });
412
374
  }
413
-
414
375
  if (hits && hits.length) {
415
376
  if (this.autoCenter) {
416
377
  return this.getHitsCenter(hits) || this.getDefaultCenter();
417
378
  }
418
-
419
379
  return hits[0] && hits[0][this.dataField] ? this.getPosition(hits[0]) : this.getDefaultCenter();
420
380
  }
421
-
422
381
  return this.getDefaultCenter();
423
382
  },
424
383
  handleZoomChange: function handleZoomChange(zoom) {
425
384
  if (zoom) {
426
385
  var prevZoom = this.zoom;
427
-
428
386
  if (this.searchAsMove) {
429
387
  this.zoom = zoom;
430
388
  this.$options.preserveCenter = true;
@@ -432,7 +390,6 @@ var ReactiveMap = {
432
390
  } else {
433
391
  this.zoom = zoom;
434
392
  }
435
-
436
393
  if (prevZoom !== zoom) {
437
394
  this.$emit('zoom-changed', zoom);
438
395
  }
@@ -443,7 +400,6 @@ var ReactiveMap = {
443
400
  this.$options.preserveCenter = true;
444
401
  this.setGeoQuery(true);
445
402
  }
446
-
447
403
  this.$emit('drag-end');
448
404
  },
449
405
  handlePreserveCenter: function handlePreserveCenter(preserveCenter) {
@@ -457,14 +413,12 @@ var ReactiveMap = {
457
413
  var executeUpdate = !!this.center;
458
414
  this.setGeoQuery(executeUpdate);
459
415
  }
460
-
461
416
  this.$emit('idle');
462
417
  },
463
418
  setGeoQuery: function setGeoQuery(executeUpdate) {
464
419
  if (executeUpdate === void 0) {
465
420
  executeUpdate = false;
466
421
  }
467
-
468
422
  // execute a new query on the initial mount
469
423
  // or whenever searchAsMove is true and the map is dragged
470
424
  if (executeUpdate || !this.skipBoundingBox && !this.mapBoxBounds) {
@@ -476,18 +430,16 @@ var ReactiveMap = {
476
430
  };
477
431
  this.setMapData(this.componentId, this.$defaultQuery, persistMapQuery, forceExecute, meta);
478
432
  }
479
-
480
433
  this.skipBoundingBox = false;
481
434
  },
482
435
  getMapParams: function getMapParams() {
483
436
  var _this$getData = this.getData(),
484
- data = _this$getData.data;
485
-
437
+ data = _this$getData.data;
486
438
  var showMarkers = this.showMarkers,
487
- defaultPin = this.defaultPin,
488
- renderPopover = this.renderPopover,
489
- autoClosePopover = this.autoClosePopover,
490
- renderItem = this.renderItem;
439
+ defaultPin = this.defaultPin,
440
+ renderPopover = this.renderPopover,
441
+ autoClosePopover = this.autoClosePopover,
442
+ renderItem = this.renderItem;
491
443
  return {
492
444
  resultsToRender: data,
493
445
  center: this.getCenter(data),
@@ -508,19 +460,17 @@ var ReactiveMap = {
508
460
  },
509
461
  getAllData: function getAllData() {
510
462
  var size = this.size,
511
- promotedResults = this.promotedResults,
512
- customData = this.customData,
513
- currentPage = this.currentPage,
514
- hits = this.hits;
463
+ promotedResults = this.promotedResults,
464
+ customData = this.customData,
465
+ currentPage = this.currentPage,
466
+ hits = this.hits;
515
467
  var results = parseHits(hits) || [];
516
468
  var parsedPromotedResults = parseHits(promotedResults) || [];
517
469
  var base = currentPage * size;
518
470
  var resultsToRender = this.filteredResults || [];
519
-
520
471
  if (this.markersData) {
521
472
  resultsToRender = this.markersData;
522
473
  }
523
-
524
474
  return {
525
475
  results: results,
526
476
  resultsToRender: resultsToRender,
@@ -533,11 +483,10 @@ var ReactiveMap = {
533
483
  },
534
484
  getData: function getData() {
535
485
  var _this$getAllData2 = this.getAllData(),
536
- promotedResults = _this$getAllData2.promotedResults,
537
- aggregationData = _this$getAllData2.aggregationData,
538
- customData = _this$getAllData2.customData,
539
- resultsToRender = _this$getAllData2.resultsToRender;
540
-
486
+ promotedResults = _this$getAllData2.promotedResults,
487
+ aggregationData = _this$getAllData2.aggregationData,
488
+ customData = _this$getAllData2.customData,
489
+ resultsToRender = _this$getAllData2.resultsToRender;
541
490
  return {
542
491
  data: this.withClickIds(resultsToRender),
543
492
  aggregationData: this.withClickIds(aggregationData || []),
@@ -549,8 +498,7 @@ var ReactiveMap = {
549
498
  },
550
499
  getComponent: function getComponent$1() {
551
500
  var error = this.error,
552
- isLoading = this.isLoading;
553
-
501
+ isLoading = this.isLoading;
554
502
  var data = _extends({
555
503
  error: error,
556
504
  loading: isLoading,
@@ -558,7 +506,6 @@ var ReactiveMap = {
558
506
  triggerClickAnalytics: this.triggerClickAnalytics,
559
507
  setPage: this.setPage
560
508
  }, this.getData());
561
-
562
509
  return getComponent(data, this);
563
510
  },
564
511
  setPage: function setPage(page) {
@@ -574,7 +521,6 @@ var ReactiveMap = {
574
521
  this.loadMoreAction(this.componentId, _extends({}, options, {
575
522
  from: value
576
523
  }), false);
577
-
578
524
  if (this.URLParams) {
579
525
  this.setPageURL(this.componentId, page + 1, this.componentId, false, true);
580
526
  }
@@ -596,7 +542,6 @@ var ReactiveMap = {
596
542
  if (props === void 0) {
597
543
  props = this.$props;
598
544
  }
599
-
600
545
  this.$defaultQuery = props.defaultQuery ? props.defaultQuery() : null;
601
546
  var mapRef = this.getMapRef();
602
547
  var mapBounds = mapRef && typeof mapRef.getBounds === 'function' ? mapRef.getBounds() : false;
@@ -604,10 +549,8 @@ var ReactiveMap = {
604
549
  var south;
605
550
  var east;
606
551
  var west;
607
-
608
552
  if (mapBounds) {
609
553
  var _geo_bounding_box;
610
-
611
554
  north = mapBounds.getNorthEast().lat();
612
555
  south = mapBounds.getSouthWest().lat();
613
556
  east = mapBounds.getNorthEast().lng();
@@ -620,31 +563,27 @@ var ReactiveMap = {
620
563
  var geoQuery = {
621
564
  geo_bounding_box: (_geo_bounding_box = {}, _geo_bounding_box[this.dataField] = boundingBoxCoordinates, _geo_bounding_box)
622
565
  };
623
-
624
566
  if (this.$defaultQuery) {
625
567
  var query = this.$defaultQuery.query;
626
-
627
568
  if (query) {
628
569
  // adds defaultQuery's query to geo-query
629
570
  // to generate a map query
571
+
630
572
  return {
631
573
  must: [geoQuery, query]
632
574
  };
633
575
  }
634
576
  }
635
-
636
577
  return geoQuery;
637
- } // return the defaultQuery (if set) or null when map query not available
638
-
578
+ }
639
579
 
580
+ // return the defaultQuery (if set) or null when map query not available
640
581
  return this.$defaultQuery ? this.$defaultQuery.query : null;
641
582
  },
642
583
  getGeoDistanceQuery: function getGeoDistanceQuery() {
643
584
  var center = this.center || this.defaultCenter;
644
-
645
585
  if (center && this.defaultRadius) {
646
586
  var _geo_distance;
647
-
648
587
  // skips geo bounding box query on initial load
649
588
  this.skipBoundingBox = true;
650
589
  return {
@@ -653,7 +592,6 @@ var ReactiveMap = {
653
592
  }, _geo_distance[this.dataField] = this.getArrPosition(center), _geo_distance)
654
593
  };
655
594
  }
656
-
657
595
  return null;
658
596
  },
659
597
  loadMore: function loadMore() {
@@ -668,26 +606,21 @@ var ReactiveMap = {
668
606
  },
669
607
  triggerClickAnalytics: function triggerClickAnalytics(searchPosition, documentId) {
670
608
  var docId = documentId;
671
-
672
609
  if (!docId) {
673
610
  var _this$getData2 = this.getData(),
674
- data = _this$getData2.data;
675
-
611
+ data = _this$getData2.data;
676
612
  var hitData = data.find(function (hit) {
677
613
  return hit._click_id === searchPosition;
678
614
  });
679
-
680
615
  if (hitData && hitData._id) {
681
616
  docId = hitData._id;
682
617
  }
683
618
  }
684
-
685
619
  this.recordResultClick(searchPosition, docId);
686
620
  },
687
621
  withClickIds: function withClickIds(results) {
688
622
  var _this$getAllData3 = this.getAllData(),
689
- base = _this$getAllData3.base;
690
-
623
+ base = _this$getAllData3.base;
691
624
  return results.map(function (result, index) {
692
625
  return _extends({}, result, {
693
626
  _click_id: base + index
@@ -699,19 +632,15 @@ var ReactiveMap = {
699
632
  this.$emit('search-as-move', this.searchAsMove);
700
633
  },
701
634
  renderErrorComponent: function renderErrorComponent() {
702
- var renderError = this.$scopedSlots.renderError || this.$props.renderError;
703
-
635
+ var renderError = this.$slots.renderError || this.$props.renderError;
704
636
  if (renderError && this.error && !this.isLoading) {
705
637
  return isFunction(renderError) ? renderError(this.error) : renderError;
706
638
  }
707
-
708
639
  return null;
709
640
  },
710
641
  renderSearchAsMove: function renderSearchAsMove() {
711
- var h = this.$createElement;
712
-
713
642
  if (this.showSearchAsMove) {
714
- return h("div", {
643
+ return createVNode("div", {
715
644
  "style": {
716
645
  position: 'absolute',
717
646
  bottom: '30px',
@@ -723,41 +652,29 @@ var ReactiveMap = {
723
652
  borderRadius: 2,
724
653
  zIndex: 10000
725
654
  },
726
- "attrs": {
727
- "className": getClassName(this.innerClass, 'checkboxContainer') || null
728
- }
729
- }, [h(Checkbox, {
730
- "attrs": {
731
- "type": "checkbox",
732
- "id": this.$props.componentId + "-searchasmove",
733
- "checked": this.searchAsMove,
734
- "show": true
735
- },
655
+ "className": getClassName(this.innerClass, 'checkboxContainer') || null
656
+ }, [createVNode(Checkbox, {
657
+ "type": "checkbox",
736
658
  "class": getClassName(this.$props.innerClass, 'checkbox'),
737
- "on": {
738
- "click": this.toggleSearchAsMove
739
- }
740
- }), h("label", {
741
- "attrs": {
742
- "className": getClassName(this.innerClass, 'label') || null,
743
- "for": this.$props.componentId + "-searchasmove"
744
- }
659
+ "id": this.$props.componentId + "-searchasmove",
660
+ "onClick": this.toggleSearchAsMove,
661
+ "checked": this.searchAsMove,
662
+ "show": true
663
+ }, null), createVNode("label", {
664
+ "className": getClassName(this.innerClass, 'label') || null,
665
+ "for": this.$props.componentId + "-searchasmove"
745
666
  }, [this.searchAsMoveLabel])]);
746
667
  }
747
-
748
668
  return null;
749
669
  },
750
670
  renderPagination: function renderPagination() {
751
- var h = this.$createElement;
752
- return h(Pagination, {
753
- "attrs": {
754
- "pages": this.pages,
755
- "totalPages": this.totalPages,
756
- "currentPage": this.currentPageState,
757
- "setPage": this.setPage,
758
- "innerClass": this.innerClass
759
- }
760
- });
671
+ return createVNode(Pagination, {
672
+ "pages": this.pages,
673
+ "totalPages": this.totalPages,
674
+ "currentPage": this.currentPageState,
675
+ "setPage": this.setPage,
676
+ "innerClass": this.innerClass
677
+ }, null);
761
678
  }
762
679
  },
763
680
  created: function created() {
@@ -765,7 +682,6 @@ var ReactiveMap = {
765
682
  this.currentPageState = this.defaultPage;
766
683
  this.from = this.currentPageState * this.$props.size;
767
684
  }
768
-
769
685
  this.internalComponent = this.$props.componentId + "__internal";
770
686
  this.updateComponentProps(this.componentId, {
771
687
  from: this.from
@@ -780,35 +696,31 @@ var ReactiveMap = {
780
696
  this.setPageURL(this.$props.componentId, this.currentPage, this.$props.componentId, false, true);
781
697
  }
782
698
  }
783
-
784
699
  var options = getQueryOptions(this.$props);
785
700
  options.from = this.$data.from;
786
-
787
701
  if (this.$props.sortBy) {
788
702
  var _ref2;
789
-
790
703
  options.sort = [(_ref2 = {}, _ref2[this.$props.dataField] = {
791
704
  order: this.$props.sortBy
792
705
  }, _ref2)];
793
706
  }
794
-
795
707
  this.$defaultQuery = null;
796
-
797
708
  if (this.$props.defaultQuery) {
798
709
  this.$defaultQuery = this.$props.defaultQuery();
799
- options = _extends({}, options, getOptionsFromQuery(this.$defaultQuery)); // Override sort query with defaultQuery's sort if defined
710
+ options = _extends({}, options, getOptionsFromQuery(this.$defaultQuery));
800
711
 
712
+ // Override sort query with defaultQuery's sort if defined
801
713
  if (this.$defaultQuery.sort) {
802
714
  options.sort = this.$defaultQuery.sort;
803
- } // since we want defaultQuery to be executed anytime
715
+ }
716
+ // since we want defaultQuery to be executed anytime
804
717
  // map component's query is being executed
805
-
806
-
807
- var persistMapQuery = true; // no need to forceExecute because setReact() will capture the main query
718
+ var persistMapQuery = true;
719
+ // no need to forceExecute because setReact() will capture the main query
808
720
  // and execute the defaultQuery along with it
721
+ var forceExecute = false;
809
722
 
810
- var forceExecute = false; // Update default query for RS API
811
-
723
+ // Update default query for RS API
812
724
  this.setDefaultQueryForRSAPI();
813
725
  var meta = {
814
726
  mapBoxBounds: this.mapBoxBounds
@@ -817,20 +729,19 @@ var ReactiveMap = {
817
729
  } else {
818
730
  // only apply geo-distance when defaultQuery prop is not set
819
731
  var query = this.getGeoDistanceQuery();
820
-
821
732
  if (query) {
822
733
  // - only persist the map query if center prop is set
823
734
  // - ideally, persist the map query if you want to keep executing it
824
735
  // whenever there is a change (due to subscription) in the component query
825
- var _persistMapQuery = !!this.center; // - forceExecute will make sure that the component query + Map query gets executed
736
+ var _persistMapQuery = !!this.center;
737
+
738
+ // - forceExecute will make sure that the component query + Map query gets executed
826
739
  // irrespective of the changes in the component query
827
740
  // - forceExecute will only come into play when searchAsMove is true
828
741
  // - kindly note that forceExecute may result in one additional network request
829
742
  // since it bypasses the gatekeeping
830
-
831
-
832
- var _forceExecute = this.searchAsMove; // Set meta for `distance` and `coordinates` in selected value
833
-
743
+ var _forceExecute = this.searchAsMove;
744
+ // Set meta for `distance` and `coordinates` in selected value
834
745
  var center = this.center || this.defaultCenter;
835
746
  var coordinatesObject = this.getArrPosition(center);
836
747
  var _meta = {
@@ -840,19 +751,16 @@ var ReactiveMap = {
840
751
  this.setMapData(this.componentId, query, _persistMapQuery, _forceExecute, _meta);
841
752
  }
842
753
  }
843
-
844
754
  this.setQueryOptions(this.componentId, options, !(this.$defaultQuery && this.$defaultQuery.query));
845
755
  },
846
756
  render: function render() {
847
- var h = arguments[0];
848
- var loader = this.$scopedSlots.loader || this.$props.loader;
849
- return h("div", {
757
+ var loader = this.$slots.loader || this.$props.loader;
758
+ return createVNode("div", {
850
759
  "style": _extends({}, style, this.$props.style),
851
760
  "class": this.$props.className
852
761
  }, [this.renderErrorComponent(), this.isLoading && loader, this.hasCustomRender ? this.getComponent() : null, this.renderMap(this.getMapParams()), this.pagination ? this.renderPagination() : null]);
853
762
  }
854
763
  };
855
-
856
764
  var mapStateToProps = function mapStateToProps(state, props) {
857
765
  return {
858
766
  defaultPage: state.selectedValues[props.componentId] && state.selectedValues[props.componentId].value - 1 || -1,
@@ -867,7 +775,6 @@ var mapStateToProps = function mapStateToProps(state, props) {
867
775
  hidden: state.hits[props.componentId] && state.hits[props.componentId].hidden
868
776
  };
869
777
  };
870
-
871
778
  var mapDispatchToProps = {
872
779
  loadMoreAction: loadMore,
873
780
  setPageURL: setValue,
@@ -879,16 +786,14 @@ var mapDispatchToProps = {
879
786
  recordResultClick: recordResultClick,
880
787
  setMapData: setMapData
881
788
  };
882
- var RMConnected = ComponentWrapper(connect(mapStateToProps, mapDispatchToProps)(ReactiveMap), {
789
+ var RMConnected = PreferencesConsumer(ComponentWrapper(connect(mapStateToProps, mapDispatchToProps)(ReactiveMap), {
883
790
  componentType: componentTypes.reactiveMap,
884
791
  internalComponent: true
885
- });
886
-
792
+ }));
887
793
  ReactiveMap.install = function (Vue) {
888
794
  Vue.component(ReactiveMap.name, RMConnected);
889
- }; // Add componentType for SSR
890
-
891
-
795
+ };
796
+ // Add componentType for SSR
892
797
  ReactiveMap.componentType = componentTypes.reactiveMap;
893
798
 
894
799
  var infoWindowMappedProps = {
@@ -920,26 +825,26 @@ var infoWindowMappedProps = {
920
825
  * @param {string[]} events an array of string with all events that you want to bind
921
826
  * @returns {void}
922
827
  */
923
-
924
828
  function bindEvents(vueInst, googleMapsInst, events) {
925
829
  events.forEach(function (eventName) {
926
- if (vueInst.$gmapOptions.autoBindAllEvents || vueInst.$listeners[eventName]) {
830
+ if (vueInst.$gmapOptions.autoBindAllEvents || vueInst.$attrs[eventName]) {
927
831
  googleMapsInst.addListener(eventName, function (ev) {
928
832
  vueInst.$emit(eventName, ev);
929
833
  });
930
834
  }
931
835
  });
932
836
  }
837
+
933
838
  /**
934
839
  * Function that helps you to capitalize the first letter on a word
935
840
  *
936
841
  * @param {string} text the text that you want to capitalize
937
842
  * @returns {string}
938
843
  */
939
-
940
844
  function capitalizeFirstLetter(text) {
941
845
  return text.charAt(0).toUpperCase() + text.slice(1);
942
846
  }
847
+
943
848
  /**
944
849
  * Function that helps you to get all non nullable props from a component
945
850
  *
@@ -947,16 +852,15 @@ function capitalizeFirstLetter(text) {
947
852
  * @param {Object} props the props object
948
853
  * @returns {Object}
949
854
  */
950
-
951
855
  function getPropsValues(vueInst, props) {
952
856
  return Object.keys(props).reduce(function (acc, prop) {
953
857
  if (vueInst[prop] !== undefined) {
954
858
  acc[prop] = vueInst[prop];
955
859
  }
956
-
957
860
  return acc;
958
861
  }, {});
959
862
  }
863
+
960
864
  /**
961
865
  * Watch the individual properties of a PoD object, instead of the object
962
866
  * per se. This is different from a deep watch where both the reference
@@ -970,19 +874,17 @@ function getPropsValues(vueInst, props) {
970
874
  * @param {boolean} immediate=false
971
875
  * @returns {void}
972
876
  */
973
-
974
877
  function watchPrimitiveProperties(vueInst, propertiesToTrack, handler, immediate) {
975
878
  if (immediate === void 0) {
976
879
  immediate = false;
977
880
  }
978
-
979
881
  var isHandled = false;
882
+
980
883
  /**
981
884
  * Function in charge to execute the handler function if it was not fired
982
885
  *
983
886
  * @returns void
984
887
  */
985
-
986
888
  function requestHandle() {
987
889
  if (!isHandled) {
988
890
  isHandled = true;
@@ -992,13 +894,13 @@ function watchPrimitiveProperties(vueInst, propertiesToTrack, handler, immediate
992
894
  });
993
895
  }
994
896
  }
995
-
996
897
  propertiesToTrack.forEach(function (prop) {
997
898
  vueInst.$watch(prop, requestHandle, {
998
899
  immediate: immediate
999
900
  });
1000
901
  });
1001
902
  }
903
+
1002
904
  /**
1003
905
  * Binds the properties defined in props to the google maps instance.
1004
906
  * If the prop is an Object type, and we wish to track the properties
@@ -1011,30 +913,27 @@ function watchPrimitiveProperties(vueInst, propertiesToTrack, handler, immediate
1011
913
  * @param {Object} props object with the component props tha should be synched with the Google Maps instances props
1012
914
  * @returns {void}
1013
915
  */
1014
-
1015
916
  function bindProps(vueInst, googleMapsInst, props) {
1016
917
  Object.keys(props).forEach(function (attribute) {
1017
918
  var _props$attribute = props[attribute],
1018
- twoWay = _props$attribute.twoWay,
1019
- type = _props$attribute.type,
1020
- trackProperties = _props$attribute.trackProperties,
1021
- noBind = _props$attribute.noBind;
1022
-
919
+ twoWay = _props$attribute.twoWay,
920
+ type = _props$attribute.type,
921
+ trackProperties = _props$attribute.trackProperties,
922
+ noBind = _props$attribute.noBind;
1023
923
  if (!noBind) {
1024
924
  var setMethodName = "set" + capitalizeFirstLetter(attribute);
1025
925
  var getMethodName = "get" + capitalizeFirstLetter(attribute);
1026
926
  var eventName = attribute.toLowerCase() + "_changed";
1027
927
  var initialValue = vueInst[attribute];
1028
-
1029
928
  if (typeof googleMapsInst[setMethodName] === 'undefined') {
1030
929
  throw new Error( // TODO: Analyze all disabled rules in the file
1031
930
  // eslint-disable-next-line no-underscore-dangle -- old code should be analyzed
1032
931
  setMethodName + " is not a method of (the Maps object corresponding to) " + vueInst.$options._componentTag);
1033
- } // We need to avoid an endless
932
+ }
933
+
934
+ // We need to avoid an endless
1034
935
  // propChanged -> event emitted -> propChanged -> event emitted loop
1035
936
  // although this may really be the user's responsibility
1036
-
1037
-
1038
937
  if (type !== Object || !trackProperties) {
1039
938
  // Track the object deeply
1040
939
  vueInst.$watch(attribute, function () {
@@ -1051,8 +950,7 @@ function bindProps(vueInst, googleMapsInst, props) {
1051
950
  googleMapsInst[setMethodName](vueInst[attribute]);
1052
951
  }, vueInst[attribute] !== undefined);
1053
952
  }
1054
-
1055
- if (twoWay && (vueInst.$gmapOptions.autoBindAllEvents || vueInst.$listeners[eventName])) {
953
+ if (twoWay && (vueInst.$gmapOptions.autoBindAllEvents || vueInst.$attrs[eventName])) {
1056
954
  googleMapsInst.addListener(eventName, function () {
1057
955
  vueInst.$emit(eventName, googleMapsInst[getMethodName]());
1058
956
  });
@@ -1072,47 +970,39 @@ var InfoWindowClusterManager = {
1072
970
  },
1073
971
  provide: function provide() {
1074
972
  var _this = this;
1075
-
1076
- var events = ['domready', 'closeclick', 'content_changed']; // Infowindow needs this to be immediately available
1077
-
973
+ var events = ['domready', 'closeclick', 'content_changed'];
974
+ // Infowindow needs this to be immediately available
1078
975
  var promise = this.$mapPromise.then(function (map) {
1079
- _this.$map = map; // Initialize the maps with the given options
1080
-
976
+ _this.$map = map;
977
+ // Initialize the maps with the given options
1081
978
  var initialOptions = _extends({}, _this.options, {
1082
979
  map: map
1083
980
  }, getPropsValues(_this, infoWindowMappedProps));
1084
-
1085
981
  var extraOptions = initialOptions.options,
1086
- position = initialOptions.position,
1087
- finalOptions = _objectWithoutPropertiesLoose(initialOptions, _excluded);
1088
-
982
+ position = initialOptions.position,
983
+ finalOptions = _objectWithoutPropertiesLoose(initialOptions, _excluded);
1089
984
  finalOptions.content = _this.$refs.flyaway;
1090
-
1091
985
  if (_this.$markerPromise) {
1092
986
  _this.$markerPromise.then(function (markerObject) {
1093
- _this.$markerObject = markerObject; // eslint-disable-next-line
1094
-
987
+ _this.$markerObject = markerObject;
988
+ // eslint-disable-next-line
1095
989
  _this.$infoWindowObject = new google.maps.InfoWindow(finalOptions);
1096
990
  bindProps(_this, _this.$infoWindowObject, infoWindowMappedProps);
1097
- bindEvents(_this, _this.$infoWindowObject, events); // TODO: This function names should be analyzed
1098
-
991
+ bindEvents(_this, _this.$infoWindowObject, events);
992
+ // TODO: This function names should be analyzed
1099
993
  /* eslint-disable no-underscore-dangle -- old style */
1100
-
1101
994
  _this._openInfoWindow();
1102
-
1103
995
  _this.$watch('opened', function () {
1104
996
  _this._openInfoWindow();
1105
997
  });
1106
998
  /* eslint-enable no-underscore-dangle */
1107
-
1108
-
1109
999
  return _this.$infoWindowObject;
1110
1000
  });
1111
1001
  }
1112
1002
  })["catch"](function (error) {
1113
1003
  throw error;
1114
- }); // TODO: analyze the efects of only returns the instance and remove completely the promise
1115
-
1004
+ });
1005
+ // TODO: analyze the efects of only returns the instance and remove completely the promise
1116
1006
  this.$infoWindowPromise = promise;
1117
1007
  return {
1118
1008
  $infoWindowPromise: promise
@@ -1129,7 +1019,6 @@ var InfoWindowClusterManager = {
1129
1019
  type: [String, Object],
1130
1020
  "default": undefined
1131
1021
  },
1132
-
1133
1022
  /**
1134
1023
  * Determines if the info-window is open or not
1135
1024
  */
@@ -1137,7 +1026,6 @@ var InfoWindowClusterManager = {
1137
1026
  type: Boolean,
1138
1027
  "default": true
1139
1028
  },
1140
-
1141
1029
  /**
1142
1030
  * Contains the LatLng at which this info window is anchored.
1143
1031
  * Note: An InfoWindow may be attached either to a Marker object
@@ -1153,7 +1041,6 @@ var InfoWindowClusterManager = {
1153
1041
  type: Object,
1154
1042
  "default": undefined
1155
1043
  },
1156
-
1157
1044
  /**
1158
1045
  * All InfoWindows are displayed on the map in order of their zIndex, with higher values displaying in front of InfoWindows with lower values. By default, InfoWindows are displayed according to their latitude, with InfoWindows of lower latitudes appearing in front of InfoWindows at higher latitudes. InfoWindows are always displayed in front of markers.
1159
1046
  * @value 0
@@ -1163,7 +1050,6 @@ var InfoWindowClusterManager = {
1163
1050
  type: Number,
1164
1051
  "default": 0
1165
1052
  },
1166
-
1167
1053
  /**
1168
1054
  * Extra options that you want to pass to the component
1169
1055
  */
@@ -1199,10 +1085,9 @@ var InfoWindowClusterManager = {
1199
1085
  }
1200
1086
  },
1201
1087
  render: function render() {
1202
- var h = arguments[0];
1203
- return h("div", [h("div", {
1088
+ return createVNode("div", null, [createVNode("div", {
1204
1089
  "ref": "flyaway"
1205
- }, [this.$scopedSlots["default"]()])]);
1090
+ }, [this.$slots["default"]()])]);
1206
1091
  }
1207
1092
  };
1208
1093
 
@@ -1234,14 +1119,19 @@ var InfoWindowWrapper = {
1234
1119
  }
1235
1120
  },
1236
1121
  render: function render() {
1237
- var h = arguments[0];
1122
+ var _this = this;
1238
1123
  var renderPopover = this.renderPopover,
1239
- events = this.events;
1240
- return h(InfoWindowClusterManager, {
1241
- "ref": this.id + "-Info-Window",
1242
- "props": _extends({}, this.infoWindowProps),
1243
- "on": _extends({}, events)
1244
- }, [h("div", [renderPopover(this.handleClose)])]);
1124
+ events = this.events;
1125
+ return createVNode(InfoWindowClusterManager, mergeProps({
1126
+ "ref": this.id + "-Info-Window"
1127
+ }, {
1128
+ props: this.infoWindowProps,
1129
+ on: events
1130
+ }), {
1131
+ "default": function _default() {
1132
+ return [createVNode("div", null, [renderPopover(_this.handleClose)])];
1133
+ }
1134
+ });
1245
1135
  }
1246
1136
  };
1247
1137
 
@@ -1295,14 +1185,12 @@ var ClusterMarkers = {
1295
1185
  },
1296
1186
  closeMarker: function closeMarker(marker) {
1297
1187
  var _this$$props = this.$props,
1298
- autoClosePopover = _this$$props.autoClosePopover,
1299
- handlePreserveCenter = _this$$props.handlePreserveCenter;
1188
+ autoClosePopover = _this$$props.autoClosePopover,
1189
+ handlePreserveCenter = _this$$props.handlePreserveCenter;
1300
1190
  var id = marker.metaData && marker.metaData._id;
1301
-
1302
1191
  var _this$openMarkers = this.openMarkers,
1303
- del = _this$openMarkers[id],
1304
- activeMarkers = _objectWithoutPropertiesLoose(_this$openMarkers, [id].map(_toPropertyKey));
1305
-
1192
+ del = _this$openMarkers[id],
1193
+ activeMarkers = _objectWithoutPropertiesLoose(_this$openMarkers, [id].map(_toPropertyKey));
1306
1194
  var newOpenMarkers = autoClosePopover ? {} : activeMarkers;
1307
1195
  this.setOpenMarkers(newOpenMarkers);
1308
1196
  handlePreserveCenter(true);
@@ -1310,15 +1198,14 @@ var ClusterMarkers = {
1310
1198
  },
1311
1199
  openMarker: function openMarker(marker, index) {
1312
1200
  var _ref, _extends2;
1313
-
1314
1201
  var autoClosePopover = this.autoClosePopover,
1315
- handlePreserveCenter = this.handlePreserveCenter;
1202
+ handlePreserveCenter = this.handlePreserveCenter;
1316
1203
  var id = marker.metaData && marker.metaData._id;
1317
1204
  var newOpenMarkers = autoClosePopover ? (_ref = {}, _ref[id] = marker, _ref) : _extends({}, this.openMarkers, (_extends2 = {}, _extends2[id] = marker, _extends2));
1318
1205
  this.setOpenMarkers(newOpenMarkers);
1319
1206
  handlePreserveCenter(true);
1320
1207
  this.triggerAnalytics(id, index);
1321
- this.$emit('open-marker-popover', marker.metaData);
1208
+ this.$emit('open-marker-popover', marker);
1322
1209
  },
1323
1210
  removeMarkers: function removeMarkers() {
1324
1211
  if (this.$clusterObject) {
@@ -1329,23 +1216,22 @@ var ClusterMarkers = {
1329
1216
  },
1330
1217
  buildMarkers: function buildMarkers(markersToRender) {
1331
1218
  var _this = this;
1332
-
1333
1219
  this.$mapPromise.then(function (map) {
1334
1220
  if (_this.$clusterPromise) {
1335
1221
  _this.$clusterPromise.then(function (clusterObject) {
1336
1222
  // Detect changed markers
1337
1223
  var markersToAdd = [];
1338
- var markersToRemove = []; // A map of marker id to active status, `true` means marker is active
1224
+ var markersToRemove = [];
1225
+ // A map of marker id to active status, `true` means marker is active
1339
1226
  // `false` means marker is stale and should be removed
1340
-
1341
1227
  var oldMarkersIdMap = {};
1342
1228
  (_this.$markers || []).forEach(function (marker) {
1343
1229
  if (marker.metaData && marker.metaData._id) {
1344
1230
  // mark all old markers as stale
1345
1231
  oldMarkersIdMap[marker.metaData._id] = false;
1346
1232
  }
1347
- }); // build map markers
1348
-
1233
+ });
1234
+ // build map markers
1349
1235
  markersToRender.forEach(function (marker, index) {
1350
1236
  // Avoid if a marker is already rendered
1351
1237
  if (marker._id && oldMarkersIdMap[marker._id] !== undefined) {
@@ -1358,14 +1244,11 @@ var ClusterMarkers = {
1358
1244
  map: map,
1359
1245
  position: _this.getPosition(marker)
1360
1246
  });
1361
-
1362
1247
  if (_this.renderItem) {
1363
1248
  var data = _this.renderItem(marker);
1364
-
1365
1249
  if ('label' in data) {
1366
1250
  initialOptions.label = data.label;
1367
1251
  }
1368
-
1369
1252
  if ('icon' in data) {
1370
1253
  initialOptions.icon = data.icon;
1371
1254
  }
@@ -1374,23 +1257,20 @@ var ClusterMarkers = {
1374
1257
  url: _this.defaultPin
1375
1258
  };
1376
1259
  }
1377
-
1378
1260
  var extraOptions = initialOptions.options,
1379
- finalOptions = _objectWithoutPropertiesLoose(initialOptions, _excluded$1);
1380
-
1261
+ finalOptions = _objectWithoutPropertiesLoose(initialOptions, _excluded$1);
1381
1262
  if (_this.$clusterPromise) {
1382
1263
  finalOptions.map = null;
1383
- } // eslint-disable-next-line
1384
-
1385
-
1264
+ }
1265
+ // eslint-disable-next-line
1386
1266
  var markerObject = new google.maps.Marker(finalOptions);
1387
1267
  markerObject.addListener('click', function () {
1388
1268
  _this.openMarker(markerObject, index);
1389
1269
  });
1390
1270
  markersToAdd.push(markerObject);
1391
1271
  }
1392
- }); // Current active markers
1393
-
1272
+ });
1273
+ // Current active markers
1394
1274
  var currentMarkers = [];
1395
1275
  markersToAdd.forEach(function (marker) {
1396
1276
  currentMarkers.push(marker);
@@ -1404,10 +1284,10 @@ var ClusterMarkers = {
1404
1284
  currentMarkers.push(marker);
1405
1285
  }
1406
1286
  }
1407
- }); // Remove old markers
1408
-
1409
- clusterObject.removeMarkers(markersToRemove); // Add inital markers at once
1410
-
1287
+ });
1288
+ // Remove old markers
1289
+ clusterObject.removeMarkers(markersToRemove);
1290
+ // Add inital markers at once
1411
1291
  clusterObject.addMarkers(markersToAdd);
1412
1292
  _this.$clusterObject = clusterObject;
1413
1293
  _this.$map = map;
@@ -1421,41 +1301,34 @@ var ClusterMarkers = {
1421
1301
  },
1422
1302
  render: function render() {
1423
1303
  var _this2 = this;
1424
-
1425
- var h = arguments[0];
1426
-
1427
1304
  if (!this.renderPopover) {
1428
1305
  return null;
1429
1306
  }
1430
-
1431
- return h("div", [Object.keys(this.openMarkers).map(function (markerId) {
1307
+ return createVNode("div", null, [Object.keys(this.openMarkers).map(function (markerId) {
1432
1308
  var marker = _this2.openMarkers[markerId];
1433
1309
  var item = marker.metaData;
1434
- return h(InfoWindowWrapper, {
1310
+ return createVNode(InfoWindowWrapper, {
1435
1311
  "key": markerId + "-InfoWindow",
1436
- "attrs": {
1437
- "id": markerId,
1438
- "renderPopover": function renderPopover(_handleClose) {
1439
- return _this2.renderPopover({
1440
- item: item,
1441
- handleClose: function handleClose() {
1442
- _handleClose();
1443
-
1444
- _this2.closeMarker(item);
1445
- }
1446
- });
1447
- },
1448
- "marker": marker,
1449
- "infoWindowProps": {
1450
- zIndex: 500
1451
- },
1452
- "events": {
1453
- closeclick: function closeclick() {
1454
- return _this2.closeMarker(marker);
1312
+ "id": markerId,
1313
+ "renderPopover": function renderPopover(_handleClose) {
1314
+ return _this2.renderPopover({
1315
+ item: item,
1316
+ handleClose: function handleClose() {
1317
+ _handleClose();
1318
+ _this2.closeMarker(item);
1455
1319
  }
1320
+ });
1321
+ },
1322
+ "marker": marker,
1323
+ "infoWindowProps": {
1324
+ zIndex: 500
1325
+ },
1326
+ "events": {
1327
+ closeclick: function closeclick() {
1328
+ return _this2.closeMarker(marker);
1456
1329
  }
1457
1330
  }
1458
- });
1331
+ }, null);
1459
1332
  })]);
1460
1333
  }
1461
1334
  };
@@ -1466,7 +1339,6 @@ var ClusterManager = connect(function () {
1466
1339
  return null;
1467
1340
  }, mapDispatchToProps$1)(ClusterMarkers);
1468
1341
 
1469
- var InfoWindow = components.InfoWindow;
1470
1342
  var InfoWindowWrapper$1 = {
1471
1343
  name: 'InfoWindowWrapper',
1472
1344
  props: {
@@ -1489,19 +1361,21 @@ var InfoWindowWrapper$1 = {
1489
1361
  }
1490
1362
  },
1491
1363
  render: function render() {
1492
- var h = arguments[0];
1364
+ var _this = this;
1493
1365
  var renderPopover = this.renderPopover,
1494
- events = this.events;
1495
- return h(InfoWindow, {
1496
- "ref": this.id + "-Info-Window",
1497
- "props": _extends({}, this.infoWindowProps),
1498
- "on": _extends({}, events)
1499
- }, [h("div", [renderPopover(this.handleClose)])]);
1366
+ events = this.events;
1367
+ return createVNode(InfoWindow, mergeProps({
1368
+ "closeclick": "true",
1369
+ "ref": this.id + "-Info-Window"
1370
+ }, this.infoWindowProps, _transformOn(events)), {
1371
+ "default": function _default() {
1372
+ return [createVNode("div", null, [renderPopover(_this.handleClose)])];
1373
+ }
1374
+ });
1500
1375
  }
1501
1376
  };
1502
1377
 
1503
- var MapElementMixin = components.MapElementMixin; // Note: This file has been taken from https://github.com/eregnier/vue2-gmap-custom-marker/blob/master/gmap-custom-marker.vue
1504
-
1378
+ // Note: This file has been taken from https://github.com/eregnier/vue2-gmap-custom-marker/blob/master/gmap-custom-marker.vue
1505
1379
  var MarkerWithLabel = {
1506
1380
  name: 'MarkerWithLabel',
1507
1381
  props: {
@@ -1562,14 +1436,12 @@ var MarkerWithLabel = {
1562
1436
  if (this.marker instanceof window.google.maps.LatLng) {
1563
1437
  return this.marker;
1564
1438
  }
1565
-
1566
1439
  return new window.google.maps.LatLng(this.lat, this.lng);
1567
1440
  }
1568
1441
  },
1569
1442
  watch: {
1570
1443
  marker: function marker() {
1571
1444
  var _this = this;
1572
-
1573
1445
  this.$mapPromise.then(function () {
1574
1446
  return _this.$overlay.setPosition();
1575
1447
  });
@@ -1585,7 +1457,6 @@ var MarkerWithLabel = {
1585
1457
  // eslint-disable-next-line
1586
1458
  options.map = null;
1587
1459
  }
1588
-
1589
1460
  return this.$clusterPromise;
1590
1461
  },
1591
1462
  destroyed: function destroyed() {
@@ -1598,111 +1469,87 @@ var MarkerWithLabel = {
1598
1469
  },
1599
1470
  provide: function provide() {
1600
1471
  var _this2 = this;
1601
-
1602
1472
  var self = this;
1603
1473
  return this.$mapPromise.then(function (map) {
1604
1474
  var Overlay = /*#__PURE__*/function (_window$google$maps$O) {
1605
1475
  _inheritsLoose(Overlay, _window$google$maps$O);
1606
-
1607
1476
  function Overlay(map2) {
1608
1477
  var _this3;
1609
-
1610
1478
  _this3 = _window$google$maps$O.call(this) || this;
1611
1479
  _this3.metaData = self.metaData;
1612
-
1613
1480
  _this3.setMap(map2);
1614
-
1615
1481
  _this3.draw = function () {
1616
1482
  return _this3.repaint();
1617
1483
  };
1618
-
1619
1484
  _this3.setPosition = function () {
1620
1485
  return _this3.repaint();
1621
1486
  };
1622
-
1623
1487
  _this3.getVisible = function () {
1624
1488
  return true;
1625
1489
  };
1626
-
1627
1490
  return _this3;
1628
1491
  }
1629
-
1630
1492
  var _proto = Overlay.prototype;
1631
-
1632
1493
  _proto.repaint = function repaint() {
1633
1494
  var div = self.$el;
1634
1495
  var projection = this.getProjection();
1635
-
1636
1496
  if (projection && div) {
1637
1497
  var posPixel = projection.fromLatLngToDivPixel(self.latLng);
1638
1498
  var x;
1639
1499
  var y;
1640
-
1641
1500
  switch (self.alignment) {
1642
1501
  case 'top':
1643
1502
  x = posPixel.x - div.offsetWidth / 2;
1644
1503
  y = posPixel.y - div.offsetHeight;
1645
1504
  break;
1646
-
1647
1505
  case 'bottom':
1648
1506
  x = posPixel.x - div.offsetWidth / 2;
1649
1507
  y = posPixel.y;
1650
1508
  break;
1651
-
1652
1509
  case 'left':
1653
1510
  x = posPixel.x - div.offsetWidth;
1654
1511
  y = posPixel.y - div.offsetHeight / 2;
1655
1512
  break;
1656
-
1657
1513
  case 'right':
1658
1514
  x = posPixel.x;
1659
1515
  y = posPixel.y - div.offsetHeight / 2;
1660
1516
  break;
1661
-
1662
1517
  case 'center':
1663
1518
  x = posPixel.x - div.offsetWidth / 2;
1664
1519
  y = posPixel.y - div.offsetHeight / 2;
1665
1520
  break;
1666
-
1667
1521
  case 'topleft':
1668
1522
  case 'lefttop':
1669
1523
  x = posPixel.x - div.offsetWidth;
1670
1524
  y = posPixel.y - div.offsetHeight;
1671
1525
  break;
1672
-
1673
1526
  case 'topright':
1674
1527
  case 'righttop':
1675
1528
  x = posPixel.x;
1676
1529
  y = posPixel.y - div.offsetHeight;
1677
1530
  break;
1678
-
1679
1531
  case 'bottomleft':
1680
1532
  case 'leftop':
1681
1533
  x = posPixel.x - div.offsetWidth;
1682
1534
  y = posPixel.y;
1683
1535
  break;
1684
-
1685
1536
  case 'bottomright':
1686
1537
  case 'rightbottom':
1687
1538
  x = posPixel.x;
1688
1539
  y = posPixel.y;
1689
1540
  break;
1690
-
1691
1541
  default:
1692
1542
  throw new Error('Invalid alignment type of custom marker!');
1693
1543
  }
1694
-
1695
1544
  if (self.cssPosition) {
1696
1545
  div.style.transform = "translate(" + (x + self.offsetX) + "px, " + (y + self.offsetY) + "px)";
1697
1546
  } else {
1698
1547
  div.style.left = x + self.offsetX + "px";
1699
1548
  div.style.top = y + self.offsetY + "px";
1700
1549
  }
1701
-
1702
1550
  div.style['z-index'] = self.zIndex;
1703
1551
  }
1704
1552
  };
1705
-
1706
1553
  _proto.onAdd = function onAdd() {
1707
1554
  if (this.$clusterObject) {
1708
1555
  this.$clusterObject.removeMarker(this.$overlay, true);
@@ -1710,7 +1557,6 @@ var MarkerWithLabel = {
1710
1557
  this.$overlay.setMap(null);
1711
1558
  this.$overlay = undefined;
1712
1559
  }
1713
-
1714
1560
  var div = self.$el;
1715
1561
  var panes = this.getPanes();
1716
1562
  div.style.position = 'absolute';
@@ -1718,24 +1564,21 @@ var MarkerWithLabel = {
1718
1564
  div.style.zIndex = self.zIndex;
1719
1565
  panes.overlayLayer.appendChild(div);
1720
1566
  panes.overlayMouseTarget.appendChild(div);
1721
-
1722
1567
  this.getDraggable = function () {
1723
1568
  return false;
1724
1569
  };
1725
-
1726
1570
  this.getPosition = function () {
1727
1571
  return new window.google.maps.LatLng(self.lat, self.lng);
1728
1572
  };
1729
-
1730
1573
  self.afterCreate(this);
1731
- } // eslint-disable-next-line
1574
+ }
1575
+ // eslint-disable-next-line
1732
1576
  ;
1733
-
1734
1577
  _proto.onRemove = function onRemove() {
1735
1578
  if (self.$el) {
1736
1579
  var ua = window.navigator.userAgent;
1737
- var msie = ua.indexOf('MSIE '); // eslint-disable-next-line
1738
-
1580
+ var msie = ua.indexOf('MSIE ');
1581
+ // eslint-disable-next-line
1739
1582
  if (msie > 0 || !!ua.match(/Trident.*rv\:11\./)) {
1740
1583
  self.$el.parentNode.removeChild(self.$el);
1741
1584
  } else {
@@ -1743,15 +1586,12 @@ var MarkerWithLabel = {
1743
1586
  }
1744
1587
  }
1745
1588
  };
1746
-
1747
1589
  return Overlay;
1748
1590
  }(window.google.maps.OverlayView);
1749
-
1750
1591
  _this2.$overlay = new Overlay(map);
1751
1592
  setTimeout(function () {
1752
1593
  if (_this2.$overlay) {
1753
1594
  _this2.$overlay.repaint();
1754
-
1755
1595
  _this2.opacity = 1;
1756
1596
  }
1757
1597
  }, 100);
@@ -1760,7 +1600,6 @@ var MarkerWithLabel = {
1760
1600
  methods: {
1761
1601
  afterCreate: function afterCreate(inst) {
1762
1602
  var _this4 = this;
1763
-
1764
1603
  if (this.$clusterPromise && !this.isMarkerAdded) {
1765
1604
  this.$clusterPromise.then(function (co) {
1766
1605
  co.addMarker(inst);
@@ -1771,16 +1610,13 @@ var MarkerWithLabel = {
1771
1610
  }
1772
1611
  },
1773
1612
  render: function render() {
1774
- var h = arguments[0];
1775
- return h("div", {
1613
+ return createVNode("div", {
1776
1614
  "style": {
1777
1615
  opacity: this.opacity
1778
1616
  },
1779
- "on": {
1780
- "mouseover": this.handleMouseOver,
1781
- "mouseout": this.handleMouseOut,
1782
- "click": this.handleClick
1783
- }
1617
+ "onmouseover": this.handleMouseOver,
1618
+ "onmouseout": this.handleMouseOut,
1619
+ "onclick": this.handleClick
1784
1620
  }, [this.renderMarker()]);
1785
1621
  }
1786
1622
  };
@@ -1790,7 +1626,6 @@ var MapPin = styled('div')(_templateObject || (_templateObject = _taggedTemplate
1790
1626
  var MapPinArrow = styled('div')(_templateObject2 || (_templateObject2 = _taggedTemplateLiteralLoose(["\n\tborder-color: rgba(0, 0, 0, 0.2);\n\tborder-style: solid;\n\tborder-width: 0 1px 1px 0;\n\tmargin-left: -6px;\n\tbackground-color: #fff;\n\tmargin-top: -6px;\n\twidth: 12px;\n\theight: 12px;\n\t-webkit-transform: rotate(45deg);\n\t-ms-transform: rotate(45deg);\n\ttransform: rotate(45deg);\n"])));
1791
1627
  var mapPinWrapper = css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteralLoose(["\n\t&:hover,\n\t&:focus {\n\t\tz-index: 200;\n\t}\n"])));
1792
1628
 
1793
- var Marker = components.Marker;
1794
1629
  var recordResultClick$2 = Actions.recordResultClick;
1795
1630
  var GoogleMapMarker = {
1796
1631
  name: 'GoogleMapMarker',
@@ -1814,211 +1649,180 @@ var GoogleMapMarker = {
1814
1649
  };
1815
1650
  },
1816
1651
  methods: {
1652
+ setIcon: function setIcon(icon) {
1653
+ this.markerIcon = icon;
1654
+ },
1817
1655
  increaseMarkerZIndex: function increaseMarkerZIndex() {
1818
1656
  var handlePreserveCenter = this.$props.handlePreserveCenter;
1819
-
1820
1657
  if (this.highlightMarkerOnHover) {
1821
1658
  this.zIndex += 1;
1822
1659
  }
1823
-
1824
1660
  handlePreserveCenter(true);
1825
1661
  },
1826
1662
  removeMarkerZIndex: function removeMarkerZIndex() {
1827
1663
  var handlePreserveCenter = this.$props.handlePreserveCenter;
1828
-
1829
1664
  if (this.highlightMarkerOnHover) {
1830
1665
  this.zIndex -= 1;
1831
1666
  }
1832
-
1833
1667
  handlePreserveCenter(true);
1834
1668
  },
1835
1669
  openMarker: function openMarker() {
1836
1670
  var _ref, _extends2;
1837
-
1838
1671
  var _this$$props = this.$props,
1839
- handleOpenMarkers = _this$$props.setOpenMarkers,
1840
- openMarkers = _this$$props.openMarkers,
1841
- marker = _this$$props.marker,
1842
- autoClosePopover = _this$$props.autoClosePopover,
1843
- handlePreserveCenter = _this$$props.handlePreserveCenter;
1672
+ handleOpenMarkers = _this$$props.setOpenMarkers,
1673
+ openMarkers = _this$$props.openMarkers,
1674
+ marker = _this$$props.marker,
1675
+ autoClosePopover = _this$$props.autoClosePopover,
1676
+ handlePreserveCenter = _this$$props.handlePreserveCenter;
1844
1677
  var id = marker._id;
1845
1678
  var newOpenMarkers = autoClosePopover ? (_ref = {}, _ref[id] = true, _ref) : _extends({}, openMarkers, (_extends2 = {}, _extends2[id] = true, _extends2));
1846
1679
  handleOpenMarkers(newOpenMarkers);
1847
1680
  handlePreserveCenter(true);
1848
1681
  this.triggerAnalytics();
1682
+ marker.setIcon = this.setIcon;
1849
1683
  this.$emit('open-marker-popover', marker);
1850
1684
  },
1851
1685
  closeMarker: function closeMarker() {
1852
1686
  var _this$$props2 = this.$props,
1853
- handleOpenMarkers = _this$$props2.setOpenMarkers,
1854
- marker = _this$$props2.marker,
1855
- autoClosePopover = _this$$props2.autoClosePopover,
1856
- handlePreserveCenter = _this$$props2.handlePreserveCenter,
1857
- openMarkers = _this$$props2.openMarkers;
1687
+ handleOpenMarkers = _this$$props2.setOpenMarkers,
1688
+ marker = _this$$props2.marker,
1689
+ autoClosePopover = _this$$props2.autoClosePopover,
1690
+ handlePreserveCenter = _this$$props2.handlePreserveCenter,
1691
+ openMarkers = _this$$props2.openMarkers;
1858
1692
  var id = marker._id;
1859
-
1860
1693
  var del = openMarkers[id],
1861
- activeMarkers = _objectWithoutPropertiesLoose(openMarkers, [id].map(_toPropertyKey));
1862
-
1694
+ activeMarkers = _objectWithoutPropertiesLoose(openMarkers, [id].map(_toPropertyKey));
1863
1695
  var newOpenMarkers = autoClosePopover ? {} : activeMarkers;
1864
1696
  handleOpenMarkers(newOpenMarkers);
1865
1697
  handlePreserveCenter(true);
1698
+ marker.setIcon = this.setIcon;
1866
1699
  this.$emit('close-marker-popover', marker);
1867
1700
  },
1868
1701
  triggerAnalytics: function triggerAnalytics() {
1869
1702
  this.recordResultClick(this.index, this.marker._id);
1870
1703
  },
1871
- renderPopoverClick: function renderPopoverClick(item, includeExternalSettings) {
1704
+ renderPopoverClick: function renderPopoverClick(item) {
1872
1705
  var _this = this;
1873
-
1874
- if (includeExternalSettings === void 0) {
1875
- includeExternalSettings = false;
1876
- }
1877
-
1878
- var h = this.$createElement;
1879
1706
  var additionalProps = {};
1880
1707
  var _this$$props3 = this.$props,
1881
- getPosition = _this$$props3.getPosition,
1882
- _renderPopover = _this$$props3.renderPopover,
1883
- openMarkers = _this$$props3.openMarkers;
1884
-
1885
- if (includeExternalSettings) {
1886
- // to render pop-over correctly with MarkerWithLabel
1887
- additionalProps = {
1888
- position: getPosition(item),
1889
- defaultOptions: {
1890
- pixelOffset: new window.google.maps.Size(0, -30)
1891
- }
1892
- };
1893
- }
1894
-
1708
+ getPosition = _this$$props3.getPosition,
1709
+ _renderPopover = _this$$props3.renderPopover,
1710
+ openMarkers = _this$$props3.openMarkers;
1711
+ additionalProps = {
1712
+ position: getPosition(item),
1713
+ defaultOptions: {
1714
+ pixelOffset: new window.google.maps.Size(0, -30)
1715
+ }
1716
+ };
1895
1717
  if (item._id in openMarkers) {
1896
- return h(InfoWindowWrapper$1, {
1718
+ return createVNode(InfoWindowWrapper$1, {
1897
1719
  "key": item._id + "-InfoWindow",
1898
- "attrs": {
1899
- "id": item._id,
1900
- "renderPopover": function renderPopover(_handleClose) {
1901
- return _renderPopover({
1902
- item: item,
1903
- handleClose: function handleClose() {
1904
- _handleClose();
1905
-
1906
- _this.closeMarker();
1907
- }
1908
- });
1909
- },
1910
- "infoWindowProps": {
1911
- zIndex: 500,
1912
- position: additionalProps.position,
1913
- options: additionalProps.defaultOptions
1914
- },
1915
- "events": {
1916
- closeclick: function closeclick() {
1917
- return _this.closeMarker();
1720
+ "id": item._id,
1721
+ "renderPopover": function renderPopover(_handleClose) {
1722
+ return _renderPopover({
1723
+ item: item,
1724
+ handleClose: function handleClose() {
1725
+ _handleClose();
1726
+ _this.closeMarker();
1918
1727
  }
1728
+ });
1729
+ },
1730
+ "infoWindowProps": {
1731
+ zIndex: 500,
1732
+ position: additionalProps.position,
1733
+ options: additionalProps.defaultOptions
1734
+ },
1735
+ "events": {
1736
+ closeclick: function closeclick() {
1737
+ return _this.closeMarker();
1919
1738
  }
1920
1739
  }
1921
- });
1740
+ }, null);
1922
1741
  }
1923
-
1924
1742
  return null;
1925
1743
  }
1926
1744
  },
1927
1745
  render: function render() {
1928
1746
  var _this2 = this;
1929
-
1930
- var h = arguments[0];
1931
1747
  var _this$$props4 = this.$props,
1932
- getPosition = _this$$props4.getPosition,
1933
- renderItem = _this$$props4.renderItem,
1934
- defaultPin = _this$$props4.defaultPin,
1935
- renderPopover = _this$$props4.renderPopover,
1936
- customMarkerProps = _this$$props4.markerProps,
1937
- marker = _this$$props4.marker;
1748
+ getPosition = _this$$props4.getPosition,
1749
+ renderItem = _this$$props4.renderItem,
1750
+ defaultPin = _this$$props4.defaultPin,
1751
+ renderPopover = _this$$props4.renderPopover,
1752
+ customMarkerProps = _this$$props4.markerProps,
1753
+ marker = _this$$props4.marker;
1938
1754
  var markerProps = {};
1939
-
1940
1755
  if (this.zIndex) {
1941
1756
  markerProps.zIndex = window.google.maps.Marker.MAX_ZINDEX + this.zIndex;
1942
1757
  }
1943
-
1944
1758
  if (renderItem) {
1945
- marker.setIcon = function (icon) {
1946
- _this2.markerIcon = icon;
1947
- };
1948
-
1759
+ marker.setIcon = this.setIcon;
1949
1760
  var data = renderItem(marker);
1950
-
1951
1761
  if ('label' in data) {
1952
- return h(MarkerWithLabel, {
1762
+ return createVNode(MarkerWithLabel, mergeProps({
1953
1763
  "key": marker._id,
1954
- "attrs": {
1955
- "metaData": marker,
1956
- "marker": getPosition(marker),
1957
- "labelAnchor": new window.google.maps.Point(0, 30),
1958
- "handleMouseOver": this.increaseMarkerZIndex,
1959
- "handleMouseOut": this.removeMarkerZIndex,
1960
- "handleClick": this.openMarker,
1961
- "zIndex": markerProps.zIndex,
1962
- "renderMarker": function renderMarker() {
1963
- return h("div", {
1964
- "attrs": {
1965
- "css": mapPinWrapper
1966
- }
1967
- }, [h(MapPin, [data.label]), h(MapPinArrow), renderPopover ? _this2.renderPopoverClick(marker, true) : null]);
1968
- }
1969
- },
1970
- "props": _extends({}, customMarkerProps)
1971
- });
1764
+ "metaData": marker,
1765
+ "marker": getPosition(marker),
1766
+ "labelAnchor": new window.google.maps.Point(0, 30),
1767
+ "handleMouseOver": this.increaseMarkerZIndex,
1768
+ "handleMouseOut": this.removeMarkerZIndex,
1769
+ "handleClick": this.openMarker,
1770
+ "zIndex": markerProps.zIndex
1771
+ }, customMarkerProps, {
1772
+ "renderMarker": function renderMarker() {
1773
+ return createVNode("div", {
1774
+ "css": mapPinWrapper
1775
+ }, [createVNode(MapPin, null, {
1776
+ "default": function _default() {
1777
+ return [data.label];
1778
+ }
1779
+ }), createVNode(MapPinArrow, null, null), renderPopover ? _this2.renderPopoverClick(marker, true) : null]);
1780
+ }
1781
+ }), null);
1972
1782
  }
1973
-
1974
1783
  if ('icon' in data) {
1975
1784
  markerProps.icon = data.icon;
1976
1785
  } else {
1977
- return h(MarkerWithLabel, {
1786
+ return createVNode(MarkerWithLabel, mergeProps({
1978
1787
  "key": marker._id,
1979
- "attrs": {
1980
- "metaData": marker,
1981
- "marker": getPosition(marker),
1982
- "handleClick": this.openMarker,
1983
- "handleMouseOver": this.increaseMarkerZIndex,
1984
- "handleMouseOut": this.removeMarkerZIndex,
1985
- "zIndex": markerProps.zIndex,
1986
- "renderMarker": function renderMarker() {
1987
- return h("div", {
1988
- "attrs": {
1989
- "css": mapPinWrapper
1990
- }
1991
- }, [typeof data.custom === 'function' ? data.custom(marker) : data.custom, renderPopover ? _this2.renderPopoverClick(marker, true) : null]);
1992
- }
1993
- },
1994
- "props": _extends({}, customMarkerProps)
1995
- });
1788
+ "metaData": marker,
1789
+ "marker": getPosition(marker),
1790
+ "handleClick": this.openMarker,
1791
+ "handleMouseOver": this.increaseMarkerZIndex,
1792
+ "handleMouseOut": this.removeMarkerZIndex,
1793
+ "zIndex": markerProps.zIndex
1794
+ }, customMarkerProps, {
1795
+ "renderMarker": function renderMarker() {
1796
+ return createVNode("div", {
1797
+ "css": mapPinWrapper
1798
+ }, [typeof data.custom === 'function' ? data.custom(marker) : data.custom, renderPopover ? _this2.renderPopoverClick(marker, true) : null]);
1799
+ }
1800
+ }), null);
1996
1801
  }
1997
1802
  } else if (defaultPin) {
1998
1803
  markerProps.icon = {
1999
1804
  url: defaultPin
2000
1805
  };
2001
1806
  }
2002
-
2003
- return h(Marker, {
1807
+ return createVNode(Marker, mergeProps({
2004
1808
  "key": marker._id,
2005
- "attrs": {
2006
- "zIndex": markerProps.zIndex,
2007
- "position": getPosition(marker),
2008
- "options": {
2009
- metaData: marker
2010
- },
2011
- "icon": this.markerIcon || markerProps.icon
1809
+ "zIndex": markerProps.zIndex,
1810
+ "onClick": function onClick() {
1811
+ return _this2.openMarker();
2012
1812
  },
2013
- "on": {
2014
- "click": function click() {
2015
- return _this2.openMarker();
2016
- },
2017
- "mouseover": this.increaseMarkerZIndex,
2018
- "mouseout": this.removeMarkerZIndex
1813
+ "onMouseover": this.increaseMarkerZIndex,
1814
+ "onMouseout": this.removeMarkerZIndex
1815
+ }, customMarkerProps, {
1816
+ "position": getPosition(marker),
1817
+ "options": {
1818
+ metaData: marker
2019
1819
  },
2020
- "props": _extends({}, customMarkerProps)
2021
- }, [renderPopover ? this.renderPopoverClick(marker) : null]);
1820
+ "icon": this.markerIcon || markerProps.icon
1821
+ }), {
1822
+ "default": function _default() {
1823
+ return [renderPopover ? _this2.renderPopoverClick(marker) : null];
1824
+ }
1825
+ });
2022
1826
  }
2023
1827
  };
2024
1828
  var mapDispatchToProps$2 = {
@@ -2028,7 +1832,6 @@ var GoogleMapMarker$1 = connect(function () {
2028
1832
  return null;
2029
1833
  }, mapDispatchToProps$2)(GoogleMapMarker);
2030
1834
 
2031
- var Cluster = components.Cluster;
2032
1835
  var GoogleMapMarkers = {
2033
1836
  name: 'GoogleMapMarkers',
2034
1837
  props: {
@@ -2075,8 +1878,6 @@ var GoogleMapMarkers = {
2075
1878
  },
2076
1879
  render: function render() {
2077
1880
  var _this = this;
2078
-
2079
- var h = arguments[0];
2080
1881
  var resultsToRender = this.$props.resultsToRender;
2081
1882
  var openMarkers = this.openMarkers;
2082
1883
  var markerProps = {
@@ -2093,75 +1894,65 @@ var GoogleMapMarkers = {
2093
1894
  showMarkerClusters: this.showMarkerClusters,
2094
1895
  highlightMarkerOnHover: this.highlightMarkerOnHover
2095
1896
  };
2096
-
2097
1897
  if (this.showMarkerClusters) {
2098
- return h("div", [h(Cluster, {
2099
- "props": _extends({}, this.clusterProps),
2100
- "on": {
2101
- "click": function click(cluster) {
2102
- var markers = cluster.markers.map(function (i) {
2103
- return i.metaData;
2104
- });
2105
- _this.clickedCluster = cluster;
2106
- _this.clusterMarkers = markers;
2107
-
2108
- _this.$emit('open-cluster-popover', _this.clusterMarkers);
2109
- }
1898
+ return createVNode("div", null, [createVNode(GMapCluster, mergeProps(this.clusterProps, {
1899
+ "onclick": function onclick(cluster) {
1900
+ var markers = cluster.markers.map(function (i) {
1901
+ return i.metaData;
1902
+ });
1903
+ _this.clickedCluster = cluster;
1904
+ _this.clusterMarkers = markers;
1905
+ _this.$emit('open-cluster-popover', _this.clusterMarkers);
2110
1906
  },
2111
1907
  "ref": "clusterRef"
2112
- }, [h(ClusterManager, {
2113
- "attrs": {
2114
- "getPosition": markerProps.getPosition,
2115
- "markers": resultsToRender,
2116
- "defaultPin": markerProps.defaultPin,
2117
- "renderItem": markerProps.renderItem,
2118
- "markerProps": markerProps.markerProps,
2119
- "handlePreserveCenter": markerProps.handlePreserveCenter,
2120
- "autoClosePopover": markerProps.autoClosePopover,
2121
- "renderPopover": markerProps.renderPopover,
2122
- "highlightMarkerOnHover": markerProps.highlightMarkerOnHover
1908
+ }), {
1909
+ "default": function _default() {
1910
+ return [createVNode(ClusterManager, mergeProps({
1911
+ "getPosition": markerProps.getPosition,
1912
+ "markers": resultsToRender,
1913
+ "defaultPin": markerProps.defaultPin,
1914
+ "renderItem": markerProps.renderItem,
1915
+ "markerProps": markerProps.markerProps,
1916
+ "handlePreserveCenter": markerProps.handlePreserveCenter,
1917
+ "autoClosePopover": markerProps.autoClosePopover,
1918
+ "renderPopover": markerProps.renderPopover,
1919
+ "highlightMarkerOnHover": markerProps.highlightMarkerOnHover
1920
+ }, {
1921
+ on: _this.$attrs
1922
+ }), null)];
1923
+ }
1924
+ }), this.clickedCluster && this.renderClusterPopover ? createVNode(InfoWindowWrapper$1, {
1925
+ "id": "cluster",
1926
+ "infoWindowProps": {
1927
+ zIndex: 500,
1928
+ position: this.getAdditionalProps().position,
1929
+ options: this.getAdditionalProps().defaultOptions
2123
1930
  },
2124
- "on": _extends({}, this.$listeners)
2125
- })]), this.clickedCluster && this.renderClusterPopover ? h(InfoWindowWrapper$1, {
2126
- "attrs": {
2127
- "id": "cluster",
2128
- "infoWindowProps": {
2129
- zIndex: 500,
2130
- position: this.getAdditionalProps().position,
2131
- options: this.getAdditionalProps().defaultOptions
2132
- },
2133
- "renderPopover": function renderPopover(_handleClose) {
2134
- return _this.renderClusterPopover({
2135
- markers: _this.clusterMarkers,
2136
- cluster: _this.clickedCluster,
2137
- handleClose: function handleClose() {
2138
- _handleClose();
2139
-
2140
- _this.closeMarker();
2141
- }
2142
- });
2143
- },
2144
- "events": {
2145
- closeclick: this.closeMarker
2146
- }
1931
+ "renderPopover": function renderPopover(_handleClose) {
1932
+ return _this.renderClusterPopover({
1933
+ markers: _this.clusterMarkers,
1934
+ cluster: _this.clickedCluster,
1935
+ handleClose: function handleClose() {
1936
+ _handleClose();
1937
+ _this.closeMarker();
1938
+ }
1939
+ });
1940
+ },
1941
+ "events": {
1942
+ closeclick: this.closeMarker
2147
1943
  }
2148
- }) : null]);
1944
+ }, null) : null]);
2149
1945
  }
2150
-
2151
- return h("div", [resultsToRender.map(function (marker, index) {
2152
- return h(GoogleMapMarker$1, {
2153
- "attrs": {
2154
- "index": index,
2155
- "marker": marker
2156
- },
2157
- "props": _extends({}, markerProps),
2158
- "on": _extends({}, _this.$listeners)
2159
- });
1946
+ return createVNode("div", null, [resultsToRender.map(function (marker, index) {
1947
+ return createVNode(GoogleMapMarker$1, mergeProps({
1948
+ "index": index,
1949
+ "marker": marker
1950
+ }, markerProps, _this.$attrs), null);
2160
1951
  })]);
2161
1952
  }
2162
1953
  };
2163
1954
 
2164
- var Map = components.MapLayer;
1955
+ var _templateObject$1;
2165
1956
  var ReactiveGoogleMap = {
2166
1957
  name: 'ReactiveGoogleMap',
2167
1958
  props: {
@@ -2196,69 +1987,78 @@ var ReactiveGoogleMap = {
2196
1987
  calculateMarkers: VueTypes.func,
2197
1988
  highlightMarkerOnHover: VueTypes.bool.def(true)
2198
1989
  },
1990
+ computed: {
1991
+ listeners: function listeners() {
1992
+ var onRE = /^on[^a-z]/;
1993
+ var listeners = {};
1994
+ var $attrs = this.$attrs;
1995
+ Object.keys($attrs).forEach(function (property) {
1996
+ if (onRE.test(property)) {
1997
+ listeners[property] = $attrs[property];
1998
+ }
1999
+ });
2000
+ return listeners;
2001
+ }
2002
+ },
2199
2003
  methods: {
2200
2004
  renderMap: function renderMap(_ref) {
2201
2005
  var _this = this;
2202
-
2203
2006
  var resultsToRender = _ref.resultsToRender,
2204
- center = _ref.center,
2205
- zoom = _ref.zoom,
2206
- handleZoomChange = _ref.handleZoomChange,
2207
- handleOnDragEnd = _ref.handleOnDragEnd,
2208
- handleOnIdle = _ref.handleOnIdle,
2209
- renderSearchAsMove = _ref.renderSearchAsMove,
2210
- handlePreserveCenter = _ref.handlePreserveCenter,
2211
- getPosition = _ref.getPosition,
2212
- autoClosePopover = _ref.autoClosePopover,
2213
- defaultPin = _ref.defaultPin;
2214
- var h = this.$createElement;
2007
+ center = _ref.center,
2008
+ zoom = _ref.zoom,
2009
+ handleZoomChange = _ref.handleZoomChange,
2010
+ handleOnDragEnd = _ref.handleOnDragEnd,
2011
+ handleOnIdle = _ref.handleOnIdle,
2012
+ renderSearchAsMove = _ref.renderSearchAsMove,
2013
+ handlePreserveCenter = _ref.handlePreserveCenter,
2014
+ getPosition = _ref.getPosition,
2015
+ autoClosePopover = _ref.autoClosePopover,
2016
+ defaultPin = _ref.defaultPin;
2215
2017
  var style = {
2216
2018
  width: '100%',
2217
2019
  height: '100%',
2218
2020
  position: 'relative'
2219
2021
  };
2220
- return h("div", {
2022
+ return createVNode("div", {
2221
2023
  "style": style
2222
- }, [h(Map, {
2024
+ }, [createVNode(Map, mergeProps({
2223
2025
  "ref": "mapRef",
2224
- "attrs": {
2225
- "map-type-id": "terrain",
2226
- "options": {
2227
- zoomControl: true
2228
- },
2229
- "center": center,
2230
- "zoom": zoom
2231
- },
2026
+ "map-type-id": "terrain",
2232
2027
  "style": {
2233
2028
  height: '100%'
2234
2029
  },
2235
- "props": _extends({}, this.mapProps),
2236
- "on": {
2237
- "zoom_changed": handleZoomChange,
2238
- "dragend": handleOnDragEnd,
2239
- "idle": handleOnIdle
2240
- }
2241
- }, [this.showMarkers ? h(GoogleMapMarkers, {
2242
- "attrs": {
2243
- "resultsToRender": resultsToRender,
2244
- "getPosition": getPosition,
2245
- "markerProps": this.markerProps,
2246
- "clusterProps": this.clusterProps,
2247
- "handlePreserveCenter": handlePreserveCenter,
2248
- "highlightMarkerOnHover": this.highlightMarkerOnHover,
2249
- "renderItem": this.$scopedSlots.renderItem ? function () {
2250
- return {
2251
- custom: _this.$scopedSlots.renderItem
2252
- };
2253
- } : this.renderItem,
2254
- "defaultPin": defaultPin,
2255
- "autoClosePopover": autoClosePopover,
2256
- "renderPopover": this.$scopedSlots.renderPopover,
2257
- "renderClusterPopover": this.$scopedSlots.renderClusterPopover,
2258
- "showMarkerClusters": this.showMarkerClusters
2030
+ "class": css(_templateObject$1 || (_templateObject$1 = _taggedTemplateLiteralLoose(["\n\t\t\t\t\t\t\theight: 100%;\n\t\t\t\t\t\t"]))),
2031
+ "options": {
2032
+ zoomControl: true
2259
2033
  },
2260
- "on": _extends({}, this.$listeners)
2261
- }) : null]), renderSearchAsMove()]);
2034
+ "center": center,
2035
+ "zoom": zoom
2036
+ }, this.mapProps, {
2037
+ "onzoom_changed": handleZoomChange,
2038
+ "ondragend": handleOnDragEnd,
2039
+ "onidle": handleOnIdle
2040
+ }), {
2041
+ "default": function _default() {
2042
+ return [_this.showMarkers ? createVNode(GoogleMapMarkers, mergeProps({
2043
+ "resultsToRender": resultsToRender,
2044
+ "getPosition": getPosition,
2045
+ "markerProps": _this.markerProps,
2046
+ "clusterProps": _this.clusterProps,
2047
+ "handlePreserveCenter": handlePreserveCenter,
2048
+ "highlightMarkerOnHover": _this.highlightMarkerOnHover,
2049
+ "renderItem": _this.$slots.renderItem ? function () {
2050
+ return {
2051
+ custom: _this.$slots.renderItem
2052
+ };
2053
+ } : _this.renderItem,
2054
+ "defaultPin": defaultPin,
2055
+ "autoClosePopover": autoClosePopover,
2056
+ "renderPopover": _this.$slots.renderPopover,
2057
+ "renderClusterPopover": _this.$slots.renderClusterPopover,
2058
+ "showMarkerClusters": _this.showMarkerClusters
2059
+ }, _this.listeners), null) : null];
2060
+ }
2061
+ }), renderSearchAsMove()]);
2262
2062
  },
2263
2063
  getMapRef: function getMapRef() {
2264
2064
  return this.mapRef;
@@ -2266,11 +2066,11 @@ var ReactiveGoogleMap = {
2266
2066
  removeMarkers: function removeMarkers() {
2267
2067
  var clusterManagerInstance;
2268
2068
  var currentInstance = this;
2269
-
2270
2069
  while (currentInstance) {
2271
- if (currentInstance && currentInstance._name === '<ConnectClusterMarkers>') {
2070
+ if (currentInstance && currentInstance.$options && currentInstance.$options.name === 'connect-ClusterMarkers') {
2272
2071
  clusterManagerInstance = currentInstance;
2273
2072
  currentInstance = null;
2073
+ // TODO: Check if $children works in vue 3
2274
2074
  } else if (currentInstance.$children) {
2275
2075
  var _currentInstance$$chi = currentInstance.$children;
2276
2076
  currentInstance = _currentInstance$$chi[0];
@@ -2278,7 +2078,6 @@ var ReactiveGoogleMap = {
2278
2078
  currentInstance = null;
2279
2079
  }
2280
2080
  }
2281
-
2282
2081
  if (clusterManagerInstance && clusterManagerInstance.removeMarkers) {
2283
2082
  clusterManagerInstance.removeMarkers();
2284
2083
  }
@@ -2286,7 +2085,6 @@ var ReactiveGoogleMap = {
2286
2085
  },
2287
2086
  mounted: function mounted() {
2288
2087
  var _this2 = this;
2289
-
2290
2088
  if (this.$refs.mapRef) {
2291
2089
  this.$refs.mapRef.$mapPromise.then(function (map) {
2292
2090
  _this2.mapRef = map;
@@ -2294,61 +2092,54 @@ var ReactiveGoogleMap = {
2294
2092
  }
2295
2093
  },
2296
2094
  render: function render() {
2297
- var h = arguments[0];
2298
- return h(RMConnected, _mergeJSXProps([{
2299
- "attrs": {
2300
- "getMapRef": this.getMapRef,
2301
- "renderMap": this.renderMap,
2302
- "componentId": this.componentId,
2303
- "className": this.className,
2304
- "dataField": this.dataField,
2305
- "defaultZoom": this.defaultZoom,
2306
- "react": this.react,
2307
- "size": this.size,
2308
- "sortBy": this.sortBy,
2309
- "pagination": this.pagination,
2310
- "uRLParams": this.URLParams,
2311
- "defaultSearchAsMove": this.searchAsMove,
2312
- "showSearchAsMove": this.showSearchAsMove,
2313
- "searchAsMoveLabel": this.searchAsMoveLabel,
2314
- "showMarkers": this.showMarkers,
2315
- "markerProps": this.markerProps,
2316
- "autoClosePopover": this.autoClosePopover,
2317
- "defaultPin": this.defaultPin,
2318
- "defaultQuery": this.defaultQuery,
2319
- "autoCenter": this.autoCenter,
2320
- "defaultCenter": this.defaultCenter,
2321
- "defaultRadius": this.defaultRadius,
2322
- "unit": this.unit,
2323
- "pages": this.pages,
2324
- "center": this.center,
2325
- "loader": this.loader,
2326
- "calculateMarkers": this.calculateMarkers
2327
- }
2095
+ return createVNode(RMConnected, mergeProps({
2096
+ "getMapRef": this.getMapRef,
2097
+ "renderMap": this.renderMap,
2098
+ "componentId": this.componentId,
2099
+ "className": this.className,
2100
+ "dataField": this.dataField,
2101
+ "defaultZoom": this.defaultZoom,
2102
+ "react": this.react,
2103
+ "size": this.size,
2104
+ "sortBy": this.sortBy,
2105
+ "pagination": this.pagination,
2106
+ "URLParams": this.URLParams,
2107
+ "defaultSearchAsMove": this.searchAsMove,
2108
+ "showSearchAsMove": this.showSearchAsMove,
2109
+ "searchAsMoveLabel": this.searchAsMoveLabel,
2110
+ "showMarkers": this.showMarkers,
2111
+ "markerProps": this.markerProps,
2112
+ "autoClosePopover": this.autoClosePopover,
2113
+ "defaultPin": this.defaultPin,
2114
+ "defaultQuery": this.defaultQuery,
2115
+ "autoCenter": this.autoCenter,
2116
+ "defaultCenter": this.defaultCenter,
2117
+ "defaultRadius": this.defaultRadius,
2118
+ "unit": this.unit,
2119
+ "pages": this.pages,
2120
+ "center": this.center,
2121
+ "loader": this.loader,
2122
+ "calculateMarkers": this.calculateMarkers
2328
2123
  }, {
2329
- scopedSlots: this.$scopedSlots,
2330
- on: this.$listeners
2331
- }]));
2124
+ on: this.$attrs
2125
+ }), null);
2332
2126
  }
2333
2127
  };
2334
-
2335
2128
  ReactiveGoogleMap.install = function (Vue, options) {
2336
2129
  Vue.component(ReactiveGoogleMap.name, ReactiveGoogleMap);
2337
-
2338
2130
  if (!options || !options.key) {
2339
2131
  console.error('ReactiveSearch: map key is required to use ReactiveGoogleMap component');
2340
2132
  }
2341
-
2342
- Vue.use(GmapVue, {
2133
+ Vue.use(VueGoogleMaps, {
2343
2134
  load: {
2344
2135
  key: options.key,
2345
2136
  libraries: 'places'
2346
2137
  },
2347
2138
  installComponents: false
2348
2139
  });
2349
- }; // Add componentType for SSR
2350
-
2140
+ };
2351
2141
 
2142
+ // Add componentType for SSR
2352
2143
  ReactiveGoogleMap.componentType = componentTypes.reactiveMap;
2353
2144
 
2354
2145
  export default ReactiveGoogleMap;