WP Google Maps - Version 9.0.2

Version Description

  • 2022-06-24 =
  • Added ability to skip installer. Will be reminded 1 day after to complete installation
  • Added improvements to admin marker addition autocomplete system tools
  • Fixed issue where installations running PHP 7.2.X would be unstable in some cases
  • Fixed issue with spelling on support pages
  • Fixed issue with writrsblock reset delegation (Atlas Novus)
Download this release

Release Info

Developer DylanAuty
Plugin Icon 128x128 WP Google Maps
Version 9.0.2
Comparing to
See all releases

Code changes from version 9.0.1 to 9.0.2

css/atlas-novus/wp-google-maps-admin.css CHANGED
@@ -3956,6 +3956,8 @@
3956
  min-width: 100%;
3957
  max-width: 100%;
3958
  max-height: 140px;
 
 
3959
  }
3960
 
3961
  .wpgmza-wrap #wpgmza_autocomplete_search_results .wpgmza_ac_result {
3956
  min-width: 100%;
3957
  max-width: 100%;
3958
  max-height: 140px;
3959
+
3960
+ z-index: 9999;
3961
  }
3962
 
3963
  .wpgmza-wrap #wpgmza_autocomplete_search_results .wpgmza_ac_result {
css/wp-google-maps-admin.css CHANGED
@@ -3028,6 +3028,9 @@ div#wpgmza_autocomplete_search_results {
3028
  padding: 5px;
3029
  max-width: 96%;
3030
  min-width: 96%;
 
 
 
3031
  }
3032
  .wpgmza_ac_result {
3033
  height: fit-content;
3028
  padding: 5px;
3029
  max-width: 96%;
3030
  min-width: 96%;
3031
+
3032
+ z-index: 9999;
3033
+
3034
  }
3035
  .wpgmza_ac_result {
3036
  height: fit-content;
html/atlas-novus/installer-page.html.php CHANGED
@@ -8,6 +8,11 @@
8
  <h1><?php _e("Welcome", "wp-google-maps"); ?>, <?php echo ucfirst($currentUser->display_name); ?></h2>
9
  <h2><?php _e("What map engine would you like to use?", "wp-google-maps"); ?></h2>
10
 
 
 
 
 
 
11
  <hr>
12
 
13
  <div class="wpgmza-row">
@@ -352,6 +357,13 @@
352
  </div>
353
  </div>
354
  </div>
355
-
 
 
 
 
 
 
 
356
  </div>
357
  </div>
8
  <h1><?php _e("Welcome", "wp-google-maps"); ?>, <?php echo ucfirst($currentUser->display_name); ?></h2>
9
  <h2><?php _e("What map engine would you like to use?", "wp-google-maps"); ?></h2>
10
 
11
+ <br>
12
+ <a href="#" class='wpgmza-installer-skip' title="<?php _e("We'll remind you in a day or two to finish up", "wp-google-maps"); ?>">
13
+ <?php _e("Not ready? Skip for now!", "wp-google-maps"); ?>
14
+ </a>
15
+
16
  <hr>
17
 
18
  <div class="wpgmza-row">
357
  </div>
358
  </div>
359
  </div>
360
+ </div>
361
+
362
+ <div class="wpgmza-row">
363
+ <div class="wpgmza-col">
364
+ <a href="#" class='wpgmza-installer-skip' title="<?php _e("We'll remind you in a day or two to finish up", "wp-google-maps"); ?>">
365
+ <?php _e("Skip installation, and finish up later?", "wp-google-maps"); ?>
366
+ </a>
367
+ </div>
368
  </div>
369
  </div>
html/atlas-novus/map-edit-page/bulk-marker-editor-dialog.html.php CHANGED
@@ -14,7 +14,7 @@
14
  'Bulk edit markers with the <a href="%s" target="_BLANK">Pro version</a>.',
15
  "wp-google-maps"
16
  ),
17
- esc_attr("https://www.wpgmaps.com/purchase-professional-version/?utm_source=plugin&utm_medium=link&utm_campaign=bulkedit-atlas-novus"),
18
  );
19
  ?>
20
  </div>
14
  'Bulk edit markers with the <a href="%s" target="_BLANK">Pro version</a>.',
15
  "wp-google-maps"
16
  ),
17
+ esc_attr("https://www.wpgmaps.com/purchase-professional-version/?utm_source=plugin&utm_medium=link&utm_campaign=bulkedit-atlas-novus")
18
  );
19
  ?>
20
  </div>
html/atlas-novus/map-edit-page/imageoverlay-panel.html.php CHANGED
@@ -36,7 +36,7 @@
36
  <?php
37
  echo sprintf(
38
  __('Add image overlays with the <a href="%s" target="_BLANK">Pro version</a>.', "wp-google-maps"),
39
- esc_attr("https://www.wpgmaps.com/purchase-professional-version/?utm_source=plugin&utm_medium=link&utm_campaign=imvageoverlayseditor-atlas-novus"),
40
  );
41
  ?>
42
  </div>
36
  <?php
37
  echo sprintf(
38
  __('Add image overlays with the <a href="%s" target="_BLANK">Pro version</a>.', "wp-google-maps"),
39
+ esc_attr("https://www.wpgmaps.com/purchase-professional-version/?utm_source=plugin&utm_medium=link&utm_campaign=imvageoverlayseditor-atlas-novus")
40
  );
41
  ?>
42
  </div>
html/atlas-novus/map-edit-page/marker-panel.html.php CHANGED
@@ -54,7 +54,7 @@
54
  <legend class="wpgmza-hide-in-adjust-mode"><?php esc_html_e('Address/GPS', 'wp-google-maps'); ?></legend>
55
 
56
  <div class="wpgmza-input-button__line wpgmza-hide-in-adjust-mode" style='display:block'>
57
- <input id="wpgmza_add_address_map_editor" type="text" data-ajax-name="address" class="wpgmza-address"/>
58
  <div id='wpgmza_autoc_disabled' style='display:none;'></div>
59
 
60
  <button
54
  <legend class="wpgmza-hide-in-adjust-mode"><?php esc_html_e('Address/GPS', 'wp-google-maps'); ?></legend>
55
 
56
  <div class="wpgmza-input-button__line wpgmza-hide-in-adjust-mode" style='display:block'>
57
+ <input id="wpgmza_add_address_map_editor" type="text" data-ajax-name="address" class="wpgmza-address" autocomplete="off"/>
58
  <div id='wpgmza_autoc_disabled' style='display:none;'></div>
59
 
60
  <button
html/atlas-novus/support.html.php CHANGED
@@ -110,7 +110,7 @@
110
  </div>
111
 
112
  <div class="hint">
113
- <?php _e("Our support team may ask for the following information to provie you with better support", "wp-google-maps"); ?>
114
  </div>
115
 
116
  <div class="tab-row">
110
  </div>
111
 
112
  <div class="hint">
113
+ <?php _e("Our support team may ask for the following information to provide you with better support", "wp-google-maps"); ?>
114
  </div>
115
 
116
  <div class="tab-row">
html/installer-page.html.php CHANGED
@@ -8,6 +8,11 @@
8
  <h1><?php _e("Welcome", "wp-google-maps"); ?>, <?php echo ucfirst($currentUser->display_name); ?></h2>
9
  <h2><?php _e("What map engine would you like to use?", "wp-google-maps"); ?></h2>
10
 
 
 
 
 
 
11
  <br><br>
12
 
13
  <div class="wpgmza-flex">
@@ -249,6 +254,14 @@
249
  </div>
250
  </div>
251
  </div>
 
 
 
 
 
 
 
 
252
 
253
  </div>
254
  </div>
8
  <h1><?php _e("Welcome", "wp-google-maps"); ?>, <?php echo ucfirst($currentUser->display_name); ?></h2>
9
  <h2><?php _e("What map engine would you like to use?", "wp-google-maps"); ?></h2>
10
 
11
+ <br>
12
+ <a href="#" class='wpgmza-installer-skip' title="<?php _e("We'll remind you in a day or two to finish up", "wp-google-maps"); ?>">
13
+ <?php _e("Not ready? Skip for now!", "wp-google-maps"); ?>
14
+ </a>
15
+
16
  <br><br>
17
 
18
  <div class="wpgmza-flex">
254
  </div>
255
  </div>
256
  </div>
257
+
258
+ <div class="wpgmza-row">
259
+ <div class="wpgmza-col">
260
+ <a href="#" class='wpgmza-installer-skip' title="<?php _e("We'll remind you in a day or two to finish up", "wp-google-maps"); ?>">
261
+ <?php _e("Skip installation, and finish up later?", "wp-google-maps"); ?>
262
+ </a>
263
+ </div>
264
+ </div>
265
 
266
  </div>
267
  </div>
html/map-edit-page/marker-panel.html.php CHANGED
@@ -67,7 +67,7 @@
67
  </legend>
68
  <div class="wpgmza-input-button__line wpgmza-hide-in-adjust-mode" style='display:block'>
69
  <div id='wpgmza_autoc_disabled' style='display:none;'></div>
70
- <input id="wpgmza_add_address_map_editor" type="text" data-ajax-name="address" class="wpgmza-address"/>
71
 
72
  <button
73
  type="button"
67
  </legend>
68
  <div class="wpgmza-input-button__line wpgmza-hide-in-adjust-mode" style='display:block'>
69
  <div id='wpgmza_autoc_disabled' style='display:none;'></div>
70
+ <input id="wpgmza_add_address_map_editor" type="text" data-ajax-name="address" class="wpgmza-address" autocomplete="off"/>
71
 
72
  <button
73
  type="button"
html/support.html.php CHANGED
@@ -103,7 +103,7 @@
103
  <div class='wpgmza_row_col wpgmza-support__col'>
104
  <div class="wpgmza-card">
105
  <h2><i class="fa fa-bullhorn "></i> <?php _e("System Info","wp-google-maps"); ?></h2>
106
- <p><?php _e("Our support team may ask for the following information to provie you with better support", "wp-google-maps"); ?></p>
107
  <pre class="system-info"></pre>
108
  <div>
109
  <div class="wpgmza button wpgmza-copy-sysinfo"><?php _e("Copy Info", "wp-google-maps"); ?></div>
103
  <div class='wpgmza_row_col wpgmza-support__col'>
104
  <div class="wpgmza-card">
105
  <h2><i class="fa fa-bullhorn "></i> <?php _e("System Info","wp-google-maps"); ?></h2>
106
+ <p><?php _e("Our support team may ask for the following information to provide you with better support", "wp-google-maps"); ?></p>
107
  <pre class="system-info"></pre>
108
  <div>
109
  <div class="wpgmza button wpgmza-copy-sysinfo"><?php _e("Copy Info", "wp-google-maps"); ?></div>
includes/class.installer-page.php CHANGED
@@ -39,26 +39,35 @@ class InstallerPage extends Page {
39
  exit;
40
  }
41
 
42
- if(!empty($wpgmza) && !empty($wpgmza->settings)){
43
- if(!empty($_POST['wpgmza_maps_engine'])){
44
- $wpgmza->settings->set('wpgmza_maps_engine', sanitize_text_field($_POST['wpgmza_maps_engine']));
45
- $wpgmza->settings->set('wpgmza_maps_engine_dialog_done', true);
46
- }
47
-
48
- if(!empty($_POST['api_key'])){
49
- $wpgmza->settings->set('wpgmza_google_maps_api_key', sanitize_text_field($_POST['api_key']));
50
- update_option('wpgmza_google_maps_api_key', $_POST['api_key']);
51
- }
 
 
 
 
 
 
 
 
 
 
 
 
52
 
53
- if(!empty($_POST['tile_server_url'])){
54
- $wpgmza->settings->set('tile_server_url', sanitize_text_field($_POST['tile_server_url']));
55
  }
56
 
 
 
57
  }
58
 
59
- /* Developer Hook (Action) - Handle storage from the installer page */
60
- do_action("wpgmza_installer_page_on_post");
61
-
62
  wp_send_json(array('success' => 1));
63
  exit;
64
  }
@@ -69,3 +78,4 @@ add_action('wpgmza_installer_page_create_instance', function() {
69
  });
70
 
71
  add_action('wp_ajax_wpgmza_installer_page_save_options', array('WPGMZA\\InstallerPage', 'post'));
 
39
  exit;
40
  }
41
 
42
+ if($_POST['action'] === 'wpgmza_installer_page_skip'){
43
+ /* Chosen to skip installation for now */
44
+ $nextReminder = date('Y-m-d', strtotime('+1 day'));
45
+ update_option('wpgmza-installer-paused', $nextReminder);
46
+ } else {
47
+ /* Completed the installation flow */
48
+ if(!empty($wpgmza) && !empty($wpgmza->settings)){
49
+ if(!empty($_POST['wpgmza_maps_engine'])){
50
+ $wpgmza->settings->set('wpgmza_maps_engine', sanitize_text_field($_POST['wpgmza_maps_engine']));
51
+ $wpgmza->settings->set('wpgmza_maps_engine_dialog_done', true);
52
+ }
53
+
54
+ if(!empty($_POST['api_key'])){
55
+ $wpgmza->settings->set('wpgmza_google_maps_api_key', sanitize_text_field($_POST['api_key']));
56
+ update_option('wpgmza_google_maps_api_key', $_POST['api_key']);
57
+ }
58
+
59
+ if(!empty($_POST['tile_server_url'])){
60
+ $wpgmza->settings->set('tile_server_url', sanitize_text_field($_POST['tile_server_url']));
61
+ }
62
+
63
+ delete_option('wpgmza-installer-paused');
64
 
 
 
65
  }
66
 
67
+ /* Developer Hook (Action) - Handle storage from the installer page */
68
+ do_action("wpgmza_installer_page_on_post");
69
  }
70
 
 
 
 
71
  wp_send_json(array('success' => 1));
72
  exit;
73
  }
78
  });
79
 
80
  add_action('wp_ajax_wpgmza_installer_page_save_options', array('WPGMZA\\InstallerPage', 'post'));
81
+ add_action('wp_ajax_wpgmza_installer_page_skip', array('WPGMZA\\InstallerPage', 'post'));
includes/class.plugin.php CHANGED
@@ -403,6 +403,14 @@ class Plugin extends Factory
403
  'buildCode' => $wpgmza->internalEngine->getBuildVersion(),
404
  ));
405
 
 
 
 
 
 
 
 
 
406
  if($post)
407
  $result['postID'] = $post->ID;
408
 
403
  'buildCode' => $wpgmza->internalEngine->getBuildVersion(),
404
  ));
405
 
406
+ $installationSkipDate = get_option('wpgmza-installer-paused');
407
+ if(!empty($installationSkipDate)){
408
+ if(strtotime(date('Y-m-d')) <= strtotime($installationSkipDate)){
409
+ /* The user skipped installation, we should not redirect them forcefully */
410
+ $result['ignoreInstallerRedirect'] = 'true';
411
+ }
412
+ }
413
+
414
  if($post)
415
  $result['postID'] = $post->ID;
416
 
js/v8/address-input.js CHANGED
@@ -28,7 +28,13 @@ jQuery(function($) {
28
 
29
  if(WPGMZA.isGoogleAutocompleteSupported()) {
30
  // only apply Google Places Autocomplete if they are usig their own API key. If not, they will use our Cloud API Complete Service
31
- if (this.id != 'wpgmza_add_address_map_editor' && WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
 
 
 
 
 
 
32
  element.googleAutoComplete = new google.maps.places.Autocomplete(element, options);
33
 
34
  if(options.country)
28
 
29
  if(WPGMZA.isGoogleAutocompleteSupported()) {
30
  // only apply Google Places Autocomplete if they are usig their own API key. If not, they will use our Cloud API Complete Service
31
+
32
+ /**
33
+ * Updated 2022-06-23
34
+ *
35
+ * This logic was incorrect and meant no place completions were happening in admin area, this was a maor value point for users
36
+ */
37
+ if (this.element.id != 'wpgmza_add_address_map_editor' && WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
38
  element.googleAutoComplete = new google.maps.places.Autocomplete(element, options);
39
 
40
  if(options.country)
js/v8/installer.js CHANGED
@@ -19,6 +19,7 @@ jQuery(function($) {
19
  WPGMZA.EventDispatcher.apply(this);
20
 
21
  this.element = $(document.body).find('.wpgmza-installer-steps');
 
22
 
23
  if(this.element.length <= 0){
24
  return;
@@ -30,6 +31,8 @@ jQuery(function($) {
30
  this.max = 0;
31
  this.findMax();
32
 
 
 
33
  $(this.element).on('click', '.next-step-button', function(event){
34
  self.next();
35
  });
@@ -69,6 +72,11 @@ jQuery(function($) {
69
  }
70
  });
71
 
 
 
 
 
 
72
  let defaultEngine = (WPGMZA && WPGMZA.settings && WPGMZA.settings.engine) ? WPGMZA.settings.engine : 'google-maps';
73
  $(this.element).find('input[name="wpgmza_maps_engine"][value="' + defaultEngine + '"]').prop('checked', true).trigger('change');
74
 
@@ -501,6 +509,31 @@ jQuery(function($) {
501
  }
502
  }
503
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
504
  $(document).ready(function(event) {
505
  WPGMZA.installer = WPGMZA.Installer.createInstance();
506
  });
19
  WPGMZA.EventDispatcher.apply(this);
20
 
21
  this.element = $(document.body).find('.wpgmza-installer-steps');
22
+ this.skipButton = $(document.body).find('.wpgmza-installer-skip');
23
 
24
  if(this.element.length <= 0){
25
  return;
31
  this.max = 0;
32
  this.findMax();
33
 
34
+
35
+
36
  $(this.element).on('click', '.next-step-button', function(event){
37
  self.next();
38
  });
72
  }
73
  });
74
 
75
+ this.skipButton.on('click', function(event){
76
+ event.preventDefault();
77
+ self.skip();
78
+ });
79
+
80
  let defaultEngine = (WPGMZA && WPGMZA.settings && WPGMZA.settings.engine) ? WPGMZA.settings.engine : 'google-maps';
81
  $(this.element).find('input[name="wpgmza_maps_engine"][value="' + defaultEngine + '"]').prop('checked', true).trigger('change');
82
 
509
  }
510
  }
511
 
512
+ WPGMZA.Installer.prototype.skip = function(){
513
+ const self = this;
514
+
515
+ $(this.element).find('.step').removeClass('active');
516
+ $(this.element).find('.step-controller').addClass('wpgmza-hidden');
517
+ $(this.element).find('.step-loader').removeClass('wpgmza-hidden');
518
+
519
+ $(this.element).find('.step-loader .progress-finish').removeClass('wpgmza-hidden');
520
+
521
+ this.skipButton.addClass('wpgmza-hidden');
522
+
523
+ const options = {
524
+ action: "wpgmza_installer_page_skip",
525
+ nonce: this.element.attr("data-ajax-nonce")
526
+ };
527
+
528
+ $.ajax(WPGMZA.ajaxurl, {
529
+ method: "POST",
530
+ data: options,
531
+ success: function(response, status, xhr) {
532
+ window.location.href = self.redirectUrl;
533
+ }
534
+ });
535
+ }
536
+
537
  $(document).ready(function(event) {
538
  WPGMZA.installer = WPGMZA.Installer.createInstance();
539
  });
js/v8/map-edit-page/feature-panel.js CHANGED
@@ -270,6 +270,11 @@ jQuery(function($) {
270
  if(!WPGMZA.InternalEngine.isLegacy()){
271
  if(typeof WritersBlock !== 'undefined' && this.writersblock != false && this.writersblock.ready){
272
  this.writersblock.setContent("");
 
 
 
 
 
273
  } else {
274
  $("#wpgmza-description-editor").val("");
275
  }
270
  if(!WPGMZA.InternalEngine.isLegacy()){
271
  if(typeof WritersBlock !== 'undefined' && this.writersblock != false && this.writersblock.ready){
272
  this.writersblock.setContent("");
273
+
274
+ if(this.writersblock.elements && this.writersblock.elements._codeEditor){
275
+ /* We have an HTML code block */
276
+ this.writersblock.elements._codeEditor.value = "";
277
+ }
278
  } else {
279
  $("#wpgmza-description-editor").val("");
280
  }
js/v8/map-edit-page/map-edit-page.js CHANGED
@@ -110,18 +110,19 @@ jQuery(function($) {
110
  var wpgmzaIdentifiedTypingSpeed = false;
111
 
112
  $('body').on('keypress', '.wpgmza-address', function(e) {
113
-
114
  if (this.id == 'wpgmza_add_address_map_editor') {
115
  if (wpgmza_autoCompleteDisabled) { return; }
116
 
117
 
118
-
119
- // if user is using their own API key then use the normal Google AutoComplete
120
  var wpgmza_apikey = false;
121
  if (WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
122
  wpgmza_apikey = WPGMZA_localized_data.settings.googleMapsApiKey;
123
- return;
124
- } else {
 
 
125
 
126
  if(e.key === "Escape" || e.key === "Alt" || e.key === "Control" || e.key === "Option" || e.key === "Shift" || e.key === "ArrowLeft" || e.key === "ArrowRight" || e.key === "ArrowUp" || e.key === "ArrowDown") {
127
  $('#wpgmza_autocomplete_search_results').hide();
@@ -250,7 +251,10 @@ jQuery(function($) {
250
 
251
 
252
 
253
- }
 
 
 
254
  });
255
  },(wpgmzaIdentifiedTypingSpeed*2));
256
 
@@ -260,7 +264,7 @@ jQuery(function($) {
260
  } else {
261
  $('#wpgmza_autocomplete_search_results').hide();
262
  }
263
- }
264
  }
265
  });
266
 
110
  var wpgmzaIdentifiedTypingSpeed = false;
111
 
112
  $('body').on('keypress', '.wpgmza-address', function(e) {
 
113
  if (this.id == 'wpgmza_add_address_map_editor') {
114
  if (wpgmza_autoCompleteDisabled) { return; }
115
 
116
 
117
+ // if user is using their own API key then use the normal Google AutoComplete
118
+ // Since 2022-06-23 this is not true, instead they use ours with their key, this adds more features
119
  var wpgmza_apikey = false;
120
  if (WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
121
  wpgmza_apikey = WPGMZA_localized_data.settings.googleMapsApiKey;
122
+ }
123
+ /* Don't return because we want this to initialize */
124
+ /* return;
125
+ } else { */
126
 
127
  if(e.key === "Escape" || e.key === "Alt" || e.key === "Control" || e.key === "Option" || e.key === "Shift" || e.key === "ArrowLeft" || e.key === "ArrowRight" || e.key === "ArrowUp" || e.key === "ArrowDown") {
128
  $('#wpgmza_autocomplete_search_results').hide();
251
 
252
 
253
 
254
+ },
255
+ error: function(){
256
+ $('#wpgmza_autocomplete_search_results').hide();
257
+ }
258
  });
259
  },(wpgmzaIdentifiedTypingSpeed*2));
260
 
264
  } else {
265
  $('#wpgmza_autocomplete_search_results').hide();
266
  }
267
+ //}
268
  }
269
  });
270
 
js/v8/maps-engine-dialog.js CHANGED
@@ -88,6 +88,11 @@ jQuery(function($) {
88
  if(WPGMZA.settings.wpgmza_google_maps_api_key && WPGMZA.settings.wpgmza_google_maps_api_key.length)
89
  return;
90
 
 
 
 
 
 
91
  WPGMZA.mapsEngineDialog = new WPGMZA.MapsEngineDialog(element);
92
 
93
  });
88
  if(WPGMZA.settings.wpgmza_google_maps_api_key && WPGMZA.settings.wpgmza_google_maps_api_key.length)
89
  return;
90
 
91
+ if(WPGMZA.ignoreInstallerRedirect){
92
+ /* We are still in paused installer mode */
93
+ return;
94
+ }
95
+
96
  WPGMZA.mapsEngineDialog = new WPGMZA.MapsEngineDialog(element);
97
 
98
  });
js/v8/wp-google-maps.combined.js CHANGED
@@ -1795,7 +1795,13 @@ jQuery(function($) {
1795
 
1796
  if(WPGMZA.isGoogleAutocompleteSupported()) {
1797
  // only apply Google Places Autocomplete if they are usig their own API key. If not, they will use our Cloud API Complete Service
1798
- if (this.id != 'wpgmza_add_address_map_editor' && WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
 
 
 
 
 
 
1799
  element.googleAutoComplete = new google.maps.places.Autocomplete(element, options);
1800
 
1801
  if(options.country)
@@ -5211,6 +5217,7 @@ jQuery(function($) {
5211
  WPGMZA.EventDispatcher.apply(this);
5212
 
5213
  this.element = $(document.body).find('.wpgmza-installer-steps');
 
5214
 
5215
  if(this.element.length <= 0){
5216
  return;
@@ -5222,6 +5229,8 @@ jQuery(function($) {
5222
  this.max = 0;
5223
  this.findMax();
5224
 
 
 
5225
  $(this.element).on('click', '.next-step-button', function(event){
5226
  self.next();
5227
  });
@@ -5261,6 +5270,11 @@ jQuery(function($) {
5261
  }
5262
  });
5263
 
 
 
 
 
 
5264
  let defaultEngine = (WPGMZA && WPGMZA.settings && WPGMZA.settings.engine) ? WPGMZA.settings.engine : 'google-maps';
5265
  $(this.element).find('input[name="wpgmza_maps_engine"][value="' + defaultEngine + '"]').prop('checked', true).trigger('change');
5266
 
@@ -5693,6 +5707,31 @@ jQuery(function($) {
5693
  }
5694
  }
5695
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5696
  $(document).ready(function(event) {
5697
  WPGMZA.installer = WPGMZA.Installer.createInstance();
5698
  });
@@ -8976,6 +9015,11 @@ jQuery(function($) {
8976
  if(WPGMZA.settings.wpgmza_google_maps_api_key && WPGMZA.settings.wpgmza_google_maps_api_key.length)
8977
  return;
8978
 
 
 
 
 
 
8979
  WPGMZA.mapsEngineDialog = new WPGMZA.MapsEngineDialog(element);
8980
 
8981
  });
@@ -17090,6 +17134,11 @@ jQuery(function($) {
17090
  if(!WPGMZA.InternalEngine.isLegacy()){
17091
  if(typeof WritersBlock !== 'undefined' && this.writersblock != false && this.writersblock.ready){
17092
  this.writersblock.setContent("");
 
 
 
 
 
17093
  } else {
17094
  $("#wpgmza-description-editor").val("");
17095
  }
@@ -18172,18 +18221,19 @@ jQuery(function($) {
18172
  var wpgmzaIdentifiedTypingSpeed = false;
18173
 
18174
  $('body').on('keypress', '.wpgmza-address', function(e) {
18175
-
18176
  if (this.id == 'wpgmza_add_address_map_editor') {
18177
  if (wpgmza_autoCompleteDisabled) { return; }
18178
 
18179
 
18180
-
18181
- // if user is using their own API key then use the normal Google AutoComplete
18182
  var wpgmza_apikey = false;
18183
  if (WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
18184
  wpgmza_apikey = WPGMZA_localized_data.settings.googleMapsApiKey;
18185
- return;
18186
- } else {
 
 
18187
 
18188
  if(e.key === "Escape" || e.key === "Alt" || e.key === "Control" || e.key === "Option" || e.key === "Shift" || e.key === "ArrowLeft" || e.key === "ArrowRight" || e.key === "ArrowUp" || e.key === "ArrowDown") {
18189
  $('#wpgmza_autocomplete_search_results').hide();
@@ -18312,7 +18362,10 @@ jQuery(function($) {
18312
 
18313
 
18314
 
18315
- }
 
 
 
18316
  });
18317
  },(wpgmzaIdentifiedTypingSpeed*2));
18318
 
@@ -18322,7 +18375,7 @@ jQuery(function($) {
18322
  } else {
18323
  $('#wpgmza_autocomplete_search_results').hide();
18324
  }
18325
- }
18326
  }
18327
  });
18328
 
1795
 
1796
  if(WPGMZA.isGoogleAutocompleteSupported()) {
1797
  // only apply Google Places Autocomplete if they are usig their own API key. If not, they will use our Cloud API Complete Service
1798
+
1799
+ /**
1800
+ * Updated 2022-06-23
1801
+ *
1802
+ * This logic was incorrect and meant no place completions were happening in admin area, this was a maor value point for users
1803
+ */
1804
+ if (this.element.id != 'wpgmza_add_address_map_editor' && WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
1805
  element.googleAutoComplete = new google.maps.places.Autocomplete(element, options);
1806
 
1807
  if(options.country)
5217
  WPGMZA.EventDispatcher.apply(this);
5218
 
5219
  this.element = $(document.body).find('.wpgmza-installer-steps');
5220
+ this.skipButton = $(document.body).find('.wpgmza-installer-skip');
5221
 
5222
  if(this.element.length <= 0){
5223
  return;
5229
  this.max = 0;
5230
  this.findMax();
5231
 
5232
+
5233
+
5234
  $(this.element).on('click', '.next-step-button', function(event){
5235
  self.next();
5236
  });
5270
  }
5271
  });
5272
 
5273
+ this.skipButton.on('click', function(event){
5274
+ event.preventDefault();
5275
+ self.skip();
5276
+ });
5277
+
5278
  let defaultEngine = (WPGMZA && WPGMZA.settings && WPGMZA.settings.engine) ? WPGMZA.settings.engine : 'google-maps';
5279
  $(this.element).find('input[name="wpgmza_maps_engine"][value="' + defaultEngine + '"]').prop('checked', true).trigger('change');
5280
 
5707
  }
5708
  }
5709
 
5710
+ WPGMZA.Installer.prototype.skip = function(){
5711
+ const self = this;
5712
+
5713
+ $(this.element).find('.step').removeClass('active');
5714
+ $(this.element).find('.step-controller').addClass('wpgmza-hidden');
5715
+ $(this.element).find('.step-loader').removeClass('wpgmza-hidden');
5716
+
5717
+ $(this.element).find('.step-loader .progress-finish').removeClass('wpgmza-hidden');
5718
+
5719
+ this.skipButton.addClass('wpgmza-hidden');
5720
+
5721
+ const options = {
5722
+ action: "wpgmza_installer_page_skip",
5723
+ nonce: this.element.attr("data-ajax-nonce")
5724
+ };
5725
+
5726
+ $.ajax(WPGMZA.ajaxurl, {
5727
+ method: "POST",
5728
+ data: options,
5729
+ success: function(response, status, xhr) {
5730
+ window.location.href = self.redirectUrl;
5731
+ }
5732
+ });
5733
+ }
5734
+
5735
  $(document).ready(function(event) {
5736
  WPGMZA.installer = WPGMZA.Installer.createInstance();
5737
  });
9015
  if(WPGMZA.settings.wpgmza_google_maps_api_key && WPGMZA.settings.wpgmza_google_maps_api_key.length)
9016
  return;
9017
 
9018
+ if(WPGMZA.ignoreInstallerRedirect){
9019
+ /* We are still in paused installer mode */
9020
+ return;
9021
+ }
9022
+
9023
  WPGMZA.mapsEngineDialog = new WPGMZA.MapsEngineDialog(element);
9024
 
9025
  });
17134
  if(!WPGMZA.InternalEngine.isLegacy()){
17135
  if(typeof WritersBlock !== 'undefined' && this.writersblock != false && this.writersblock.ready){
17136
  this.writersblock.setContent("");
17137
+
17138
+ if(this.writersblock.elements && this.writersblock.elements._codeEditor){
17139
+ /* We have an HTML code block */
17140
+ this.writersblock.elements._codeEditor.value = "";
17141
+ }
17142
  } else {
17143
  $("#wpgmza-description-editor").val("");
17144
  }
18221
  var wpgmzaIdentifiedTypingSpeed = false;
18222
 
18223
  $('body').on('keypress', '.wpgmza-address', function(e) {
 
18224
  if (this.id == 'wpgmza_add_address_map_editor') {
18225
  if (wpgmza_autoCompleteDisabled) { return; }
18226
 
18227
 
18228
+ // if user is using their own API key then use the normal Google AutoComplete
18229
+ // Since 2022-06-23 this is not true, instead they use ours with their key, this adds more features
18230
  var wpgmza_apikey = false;
18231
  if (WPGMZA_localized_data.settings.googleMapsApiKey && WPGMZA_localized_data.settings.googleMapsApiKey !== '') {
18232
  wpgmza_apikey = WPGMZA_localized_data.settings.googleMapsApiKey;
18233
+ }
18234
+ /* Don't return because we want this to initialize */
18235
+ /* return;
18236
+ } else { */
18237
 
18238
  if(e.key === "Escape" || e.key === "Alt" || e.key === "Control" || e.key === "Option" || e.key === "Shift" || e.key === "ArrowLeft" || e.key === "ArrowRight" || e.key === "ArrowUp" || e.key === "ArrowDown") {
18239
  $('#wpgmza_autocomplete_search_results').hide();
18362
 
18363
 
18364
 
18365
+ },
18366
+ error: function(){
18367
+ $('#wpgmza_autocomplete_search_results').hide();
18368
+ }
18369
  });
18370
  },(wpgmzaIdentifiedTypingSpeed*2));
18371
 
18375
  } else {
18376
  $('#wpgmza_autocomplete_search_results').hide();
18377
  }
18378
+ //}
18379
  }
18380
  });
18381
 
js/v8/wp-google-maps.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(function($){var core={MARKER_PULL_DATABASE:"0",MARKER_PULL_XML:"1",PAGE_MAP_LIST:"map-list",PAGE_MAP_EDIT:"map-edit",PAGE_SETTINGS:"map-settings",PAGE_STYLING:"map-styling",PAGE_SUPPORT:"map-support",PAGE_INSTALLER:"installer",PAGE_CATEGORIES:"categories",PAGE_ADVANCED:"advanced",PAGE_CUSTOM_FIELDS:"custom-fields",maps:[],events:null,settings:null,restAPI:null,localized_strings:null,loadingHTML:'<div class="wpgmza-preloader"><div class="wpgmza-loader">...</div></div>',preloaderHTML:"<div class='wpgmza-preloader'><div></div><div></div><div></div><div></div></div>",getCurrentPage:function(){switch(WPGMZA.getQueryParamValue("page")){case"wp-google-maps-menu":return window.location.href.match(/action=edit/)&&window.location.href.match(/map_id=\d+/)?WPGMZA.PAGE_MAP_EDIT:window.location.href.match(/action=installer/)?WPGMZA.PAGE_INSTALLER:WPGMZA.PAGE_MAP_LIST;case"wp-google-maps-menu-settings":return WPGMZA.PAGE_SETTINGS;case"wp-google-maps-menu-styling":return WPGMZA.PAGE_STYLING;case"wp-google-maps-menu-support":return WPGMZA.PAGE_SUPPORT;case"wp-google-maps-menu-categories":return WPGMZA.PAGE_CATEGORIES;case"wp-google-maps-menu-advanced":return WPGMZA.PAGE_ADVANCED;case"wp-google-maps-menu-custom-fields":return WPGMZA.PAGE_CUSTOM_FIELDS;default:return null}},getScrollAnimationOffset:function(){return(WPGMZA.settings.scroll_animation_offset||0)+($("#wpadminbar").height()||0)},getScrollAnimationDuration:function(){return WPGMZA.settings.scroll_animation_milliseconds||500},animateScroll:function(element,milliseconds){var offset=WPGMZA.getScrollAnimationOffset();milliseconds=milliseconds||WPGMZA.getScrollAnimationDuration(),$("html, body").animate({scrollTop:$(element).offset().top-offset},milliseconds)},extend:function(child,parent){var constructor=child;child.prototype=Object.create(parent.prototype),child.prototype.constructor=constructor},guid:function(){var d=(new Date).getTime();return"undefined"!=typeof performance&&"function"==typeof performance.now&&(d+=performance.now()),"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(c){var r=(d+16*Math.random())%16|0;return d=Math.floor(d/16),("x"===c?r:3&r|8).toString(16)})},hexOpacityToRGBA:function(colour,opacity){colour=parseInt(colour.replace(/^#/,""),16);return[(16711680&colour)>>16,(65280&colour)>>8,255&colour,parseFloat(opacity)]},hexOpacityToString:function(colour,opacity){colour=WPGMZA.hexOpacityToRGBA(colour,opacity);return"rgba("+colour[0]+", "+colour[1]+", "+colour[2]+", "+colour[3]+")"},hexToRgba:function(hex){return/^#([A-Fa-f0-9]{3}){1,2}$/.test(hex)?{r:(hex="0x"+(hex=3==(hex=hex.substring(1).split("")).length?[hex[0],hex[0],hex[1],hex[1],hex[2],hex[2]]:hex).join(""))>>16&255,g:hex>>8&255,b:255&hex,a:1}:0},rgbaToString:function(rgba){return"rgba("+rgba.r+", "+rgba.g+", "+rgba.b+", "+rgba.a+")"},latLngRegexp:/^(\-?\d+(\.\d+)?),\s*(\-?\d+(\.\d+)?)$/,isLatLngString:function(str){if("string"!=typeof str)return null;str=(str=str.match(/^\(.+\)$/)?str.replace(/^\(|\)$/,""):str).match(WPGMZA.latLngRegexp);return str?new WPGMZA.LatLng({lat:parseFloat(str[1]),lng:parseFloat(str[3])}):null},stringToLatLng:function(str){str=WPGMZA.isLatLngString(str);if(str)return str;throw new Error("Not a valid latLng")},isHexColorString:function(str){return"string"==typeof str&&!!str.match(/#[0-9A-F]{6}/i)},imageDimensionsCache:{},getImageDimensions:function(src,callback){var img;WPGMZA.imageDimensionsCache[src]?callback(WPGMZA.imageDimensionsCache[src]):((img=document.createElement("img")).onload=function(event){var result={width:img.width,height:img.height};WPGMZA.imageDimensionsCache[src]=result,callback(result)},img.src=src)},decodeEntities:function(input){return input.replace(/&(nbsp|amp|quot|lt|gt);/g,function(m,e){return m[e]}).replace(/&#(\d+);/gi,function(m,e){return String.fromCharCode(parseInt(e,10))})},isDeveloperMode:function(){return this.settings.developer_mode||window.Cookies&&window.Cookies.get("wpgmza-developer-mode")},isProVersion:function(){return"1"==this._isProVersion},openMediaDialog:function(callback,config){var file_frame;if(file_frame)return file_frame.uploader.uploader.param("post_id",set_to_post_id),void file_frame.open();(file_frame=wp.media.frames.file_frame=config?wp.media(config):wp.media({title:"Select a image to upload",button:{text:"Use this image"},multiple:!1})).on("select",function(){attachment=file_frame.state().get("selection").first().toJSON(),callback(attachment.id,attachment.url,attachment)}),file_frame.open()},getCurrentPosition:function(callback,error,watch){var options,nativeFunction="getCurrentPosition";WPGMZA.userLocationDenied?error&&error({code:1,message:"Location unavailable"}):(watch&&(nativeFunction="watchPosition"),navigator.geolocation?(options={enableHighAccuracy:!0},navigator.geolocation[nativeFunction]?navigator.geolocation[nativeFunction](function(position){callback&&callback(position),WPGMZA.events.trigger("userlocationfound")},function(err){options.enableHighAccuracy=!1,navigator.geolocation[nativeFunction](function(position){callback&&callback(position),WPGMZA.events.trigger("userlocationfound")},function(err){console.warn(err.code,err.message),1==err.code&&(WPGMZA.userLocationDenied=!0),error&&error(err)},options)},options):console.warn(nativeFunction+" is not available")):console.warn("No geolocation available on this device"))},watchPosition:function(callback,error){return WPGMZA.getCurrentPosition(callback,error,!0)},runCatchableTask:function(callback,friendlyErrorContainer){if(WPGMZA.isDeveloperMode())callback();else try{callback()}catch(e){callback=new WPGMZA.FriendlyError(e);$(friendlyErrorContainer).html(""),$(friendlyErrorContainer).append(callback.element),$(friendlyErrorContainer).show()}},capitalizeWords:function(string){return(string+"").replace(/^(.)|\s+(.)/g,function(m){return m.toUpperCase()})},pluralize:function(string){return WPGMZA.singularize(string)+"s"},singularize:function(string){return string.replace(/s$/,"")},assertInstanceOf:function(instance,instanceName){var pro=WPGMZA.isProVersion()?"Pro":"",engine="open-layers"===WPGMZA.settings.engine?"OL":"Google",pro=WPGMZA[engine+pro+instanceName]&&engine+instanceName!="OLFeature"?engine+pro+instanceName:WPGMZA[pro+instanceName]?pro+instanceName:WPGMZA[engine+instanceName]&&WPGMZA[engine+instanceName].prototype?engine+instanceName:instanceName;if("OLFeature"!=pro&&!(instance instanceof WPGMZA[pro]))throw new Error("Object must be an instance of "+pro+" (did you call a constructor directly, rather than createInstance?)")},getMapByID:function(id){for(var i=0;i<WPGMZA.maps.length;i++)if(WPGMZA.maps[i].id==id)return WPGMZA.maps[i];return null},isGoogleAutocompleteSupported:function(){return!!window.google&&(!!google.maps&&(!!google.maps.places&&(!!google.maps.places.Autocomplete&&(!WPGMZA.CloudAPI||!WPGMZA.CloudAPI.isBeingUsed))))},googleAPIStatus:window.wpgmza_google_api_status,isSafari:function(){var ua=navigator.userAgent.toLowerCase();return ua.match(/safari/i)&&!ua.match(/chrome/i)},isTouchDevice:function(){return"ontouchstart"in window},isDeviceiOS:function(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream||!!navigator.platform&&/iPad|iPhone|iPod/.test(navigator.platform)},isModernComponentStyleAllowed:function(){return!WPGMZA.settings.user_interface_style||"legacy"==WPGMZA.settings.user_interface_style||"modern"==WPGMZA.settings.user_interface_style},isElementInView:function(element){var pageTop=$(window).scrollTop(),pageBottom=pageTop+$(window).height(),elementTop=$(element).offset().top,element=elementTop+$(element).height();return elementTop<pageTop&&pageBottom<element||(pageTop<=elementTop&&elementTop<=pageBottom||pageTop<=element&&element<=pageBottom)},isFullScreen:function(){return wpgmzaisFullScreen},getQueryParamValue:function(name){var name=new RegExp(name+"=([^&#]*)");return(name=window.location.href.match(name))?decodeURIComponent(name[1]):null},notification:function(text,time){switch(arguments.length){case 0:text="",time=4e3;break;case 1:time=4e3}var html='<div class="wpgmza-popup-notification">'+text+"</div>";jQuery("body").append(html),setTimeout(function(){jQuery("body").find(".wpgmza-popup-notification").remove()},time)},initMaps:function(){$(document.body).find(".wpgmza_map:not(.wpgmza-initialized)").each(function(index,el){if(el.wpgmzaMap)console.warn("Element missing class wpgmza-initialized but does have wpgmzaMap property. No new instance will be created");else try{el.wpgmzaMap=WPGMZA.Map.createInstance(el)}catch(ex){console.warn("Map initalization: "+ex)}}),WPGMZA.Map.nextInitTimeoutID=setTimeout(WPGMZA.initMaps,3e3)},initCapsules:function(){WPGMZA.capsuleModules=WPGMZA.CapsuleModules.createInstance()},onScroll:function(){$(".wpgmza_map").each(function(index,el){var isInView=WPGMZA.isElementInView(el);el.wpgmzaScrollIntoViewTriggerFlag?isInView||(el.wpgmzaScrollIntoViewTriggerFlag=!1):isInView&&($(el).trigger("mapscrolledintoview.wpgmza"),el.wpgmzaScrollIntoViewTriggerFlag=!0)})},initInstallerRedirect:function(url){$(".wpgmza-wrap").hide(),window.location.href=url}},wpgmzaisFullScreen=!1;for(key in[]){console.warn("It appears that the built in JavaScript Array has been extended, this can create issues with for ... in loops, which may cause failure.");break}for(key in window.WPGMZA?window.WPGMZA=$.extend(window.WPGMZA,core):window.WPGMZA=core,window.uc&&window.uc.reloadOnOptIn&&(window.uc.reloadOnOptIn("S1pcEj_jZX"),window.uc.reloadOnOptOut("S1pcEj_jZX")),WPGMZA_localized_data){var value=WPGMZA_localized_data[key];WPGMZA[key]=value}var key,wpgmzaisFullScreen=!1;for(key in[]){console.warn("It appears that the built in JavaScript Array has been extended, this can create issues with for ... in loops, which may cause failure.");break}for(key in window.WPGMZA?window.WPGMZA=$.extend(window.WPGMZA,core):window.WPGMZA=core,window.uc&&window.uc.reloadOnOptIn&&(window.uc.reloadOnOptIn("S1pcEj_jZX"),window.uc.reloadOnOptOut("S1pcEj_jZX")),WPGMZA_localized_data){value=WPGMZA_localized_data[key];WPGMZA[key]=value}WPGMZA.settings.useLegacyGlobals=!0,$(document).on("fullscreenchange mozfullscreenchange webkitfullscreenchange",function(){wpgmzaisFullScreen=!!document.fullscreenElement,$(document.body).trigger("fullscreenchange.wpgmza")}),$("body").on("click","#wpgmzaCloseChat",function(e){e.preventDefault(),$.ajax(WPGMZA.ajaxurl,{method:"POST",data:{action:"wpgmza_hide_chat",nonce:WPGMZA_localized_data.ajaxnonce}}),$(".wpgmza-chat-help").remove()}),$(window).on("scroll",WPGMZA.onScroll),$(document.body).on("click","button.wpgmza-api-consent",function(event){Cookies.set("wpgmza-api-consent-given",!0),window.location.reload()}),$(document.body).on("keydown",function(event){event.altKey&&(WPGMZA.altKeyDown=!0)}),$(document.body).on("keyup",function(event){event.altKey||(WPGMZA.altKeyDown=!1)}),$(document.body).on("preinit.wpgmza",function(){$(window).trigger("ready.wpgmza"),$(document.body).trigger("ready.body.wpgmza"),$("script[src*='wp-google-maps.combined.js'], script[src*='wp-google-maps-pro.combined.js']").length&&console.warn("Minified script is out of date, using combined script instead.");var key,elements=$("script[src]").filter(function(){return this.src.match(/(^|\/)jquery\.(min\.)?js(\?|$)/i)});1<elements.length&&console.warn("Multiple jQuery versions detected: ",elements);for(key in[]){console.warn("The Array object has been extended incorrectly by your theme or another plugin. This can cause issues with functionality.");break}"https:"!=window.location.protocol&&(elements='<div class="'+(WPGMZA.InternalEngine.isLegacy()?"":"wpgmza-shadow wpgmza-card wpgmza-pos-relative ")+'notice notice-warning"><p>'+WPGMZA.localized_strings.unsecure_geolocation+"</p></div>",$(".wpgmza-geolocation-setting").first().after($(elements))),WPGMZA.googleAPIStatus&&"USER_CONSENT_NOT_GIVEN"==WPGMZA.googleAPIStatus.code&&jQuery(".wpgmza-gdpr-compliance").length<=0&&($(".wpgmza-inner-stack").hide(),$("button.wpgmza-api-consent").on("click",function(event){Cookies.set("wpgmza-api-consent-given",!0),window.location.reload()}))}),function($){$(function(){WPGMZA.restAPI=WPGMZA.RestAPI.createInstance(),WPGMZA.CloudAPI&&(WPGMZA.cloudAPI=WPGMZA.CloudAPI.createInstance()),$(document.body).trigger("preinit.wpgmza"),WPGMZA.initMaps(),WPGMZA.onScroll(),WPGMZA.initCapsules(),$(document.body).trigger("postinit.wpgmza")})}($)}),jQuery(function($){WPGMZA.Compatibility=function(){this.preventDocumentWriteGoogleMapsAPI()},WPGMZA.Compatibility.prototype.preventDocumentWriteGoogleMapsAPI=function(){var old=document.write;document.write=function(content){content.match&&content.match(/maps\.google/)||old.call(document,content)}},WPGMZA.compatiblityModule=new WPGMZA.Compatibility}),!function(root,factory){"object"==typeof exports?module.exports=factory(root):"function"==typeof define&&define.amd?define([],factory.bind(root,root)):factory(root)}("undefined"!=typeof global?global:this,function(root){if(root.CSS&&root.CSS.escape)return root.CSS.escape;function cssEscape(value){if(0==arguments.length)throw new TypeError("`CSS.escape` requires an argument.");for(var codeUnit,string=String(value),length=string.length,index=-1,result="",firstCodeUnit=string.charCodeAt(0);++index<length;)0==(codeUnit=string.charCodeAt(index))?result+="�":result+=1<=codeUnit&&codeUnit<=31||127==codeUnit||0==index&&48<=codeUnit&&codeUnit<=57||1==index&&48<=codeUnit&&codeUnit<=57&&45==firstCodeUnit?"\\"+codeUnit.toString(16)+" ":(0!=index||1!=length||45!=codeUnit)&&(128<=codeUnit||45==codeUnit||95==codeUnit||48<=codeUnit&&codeUnit<=57||65<=codeUnit&&codeUnit<=90||97<=codeUnit&&codeUnit<=122)?string.charAt(index):"\\"+string.charAt(index);return result}return root.CSS||(root.CSS={}),root.CSS.escape=cssEscape}),jQuery(function($){Math.PI;function deg2rad(deg){return deg*(Math.PI/180)}WPGMZA.Distance={MILES:!0,KILOMETERS:!1,MILES_PER_KILOMETER:.621371,KILOMETERS_PER_MILE:1.60934,uiToMeters:function(uiDistance){return parseFloat(uiDistance)/(WPGMZA.settings.distance_units==WPGMZA.Distance.MILES?WPGMZA.Distance.MILES_PER_KILOMETER:1)*1e3},uiToKilometers:function(uiDistance){return.001*WPGMZA.Distance.uiToMeters(uiDistance)},uiToMiles:function(uiDistance){return WPGMZA.Distance.uiToKilometers(uiDistance)*WPGMZA.Distance.MILES_PER_KILOMETER},kilometersToUI:function(km){return WPGMZA.settings.distance_units==WPGMZA.Distance.MILES?km*WPGMZA.Distance.MILES_PER_KILOMETER:km},between:function(a,b){if(!(a instanceof WPGMZA.LatLng||"lat"in a&&"lng"in a))throw new Error("First argument must be an instance of WPGMZA.LatLng or a literal");if(!(b instanceof WPGMZA.LatLng||"lat"in b&&"lng"in b))throw new Error("Second argument must be an instance of WPGMZA.LatLng or a literal");if(a===b)return 0;var lat1=a.lat,lon1=a.lng,lat2=b.lat,b=b.lng,dLat=deg2rad(lat2-lat1),b=deg2rad(b-lon1),a=Math.sin(dLat/2)*Math.sin(dLat/2)+Math.cos(deg2rad(lat1))*Math.cos(deg2rad(lat2))*Math.sin(b/2)*Math.sin(b/2);return 6371*(2*Math.atan2(Math.sqrt(a),Math.sqrt(1-a)))}}}),jQuery(function($){WPGMZA.EliasFano=function(){if(!WPGMZA.EliasFano.isSupported)throw new Error("Elias Fano encoding is not supported on browsers without Uint8Array");WPGMZA.EliasFano.decodingTablesInitialised||WPGMZA.EliasFano.createDecodingTable()},WPGMZA.EliasFano.isSupported="Uint8Array"in window,WPGMZA.EliasFano.decodingTableHighBits=[],WPGMZA.EliasFano.decodingTableDocIDNumber=null,WPGMZA.EliasFano.decodingTableHighBitsCarryover=null,WPGMZA.EliasFano.createDecodingTable=function(){WPGMZA.EliasFano.decodingTableDocIDNumber=new Uint8Array(256),WPGMZA.EliasFano.decodingTableHighBitsCarryover=new Uint8Array(256);for(var decodingTableHighBits=WPGMZA.EliasFano.decodingTableHighBits,decodingTableDocIDNumber=WPGMZA.EliasFano.decodingTableDocIDNumber,decodingTableHighBitsCarryover=WPGMZA.EliasFano.decodingTableHighBitsCarryover,i=0;i<256;i++){var zeroCount=0;decodingTableHighBits[i]=[];for(var j=7;0<=j;j--)zeroCount=0<(i&1<<j)?(decodingTableHighBits[i][decodingTableDocIDNumber[i]]=zeroCount,decodingTableDocIDNumber[i]++,0):(zeroCount+1)%255;decodingTableHighBitsCarryover[i]=zeroCount}WPGMZA.EliasFano.decodingTablesInitialised=!0},WPGMZA.EliasFano.prototype.encode=function(list){var lastDocID=0,buffer1=0,bufferLength1=0,buffer2=0,bufferLength2=0;if(0==list.length)return result;var compressedBufferPointer1=0,compressedBufferPointer2=0,averageDelta=list[list.length-1]/list.length,averageDeltaLog=Math.log2(averageDelta),lowBitsLength=Math.floor(averageDeltaLog),lowBitsMask=(1<<lowBitsLength)-1,prev=null,averageDeltaLog=Math.floor((2+Math.ceil(Math.log2(averageDelta)))*list.length/8)+6,compressedBuffer=new Uint8Array(averageDeltaLog),result=(lowBitsLength<0&&(lowBitsLength=0),compressedBufferPointer2=Math.floor(lowBitsLength*list.length/8+6),compressedBuffer[compressedBufferPointer1++]=255&list.length,compressedBuffer[compressedBufferPointer1++]=255&list.length>>8,compressedBuffer[compressedBufferPointer1++]=255&list.length>>16,compressedBuffer[compressedBufferPointer1++]=255&list.length>>24,compressedBuffer[compressedBufferPointer1++]=255&lowBitsLength,list.forEach(function(docID){var docIDDelta=docID-lastDocID-1;if(!$.isNumeric(docID))throw new Error("Value is not numeric");if(docID=parseInt(docID),null!==prev&&docID<=prev)throw new Error("Elias Fano encoding can only be used on a sorted, ascending list of unique integers.");for(prev=docID,buffer1=buffer1<<lowBitsLength|docIDDelta&lowBitsMask,bufferLength1+=lowBitsLength;7<bufferLength1;)bufferLength1-=8,compressedBuffer[compressedBufferPointer1++]=255&buffer1>>bufferLength1;docIDDelta=1+(docIDDelta>>lowBitsLength);for(buffer2=buffer2<<docIDDelta|1,bufferLength2+=docIDDelta;7<bufferLength2;)bufferLength2-=8,compressedBuffer[compressedBufferPointer2++]=255&buffer2>>bufferLength2;lastDocID=docID}),0<bufferLength1&&(compressedBuffer[compressedBufferPointer1++]=255&buffer1<<8-bufferLength1),0<bufferLength2&&(compressedBuffer[compressedBufferPointer2++]=255&buffer2<<8-bufferLength2),new Uint8Array(compressedBuffer));return result.pointer=compressedBufferPointer2,result},WPGMZA.EliasFano.prototype.decode=function(compressedBuffer){for(var resultPointer=0,list=[],decodingTableHighBits=WPGMZA.EliasFano.decodingTableHighBits,decodingTableDocIDNumber=WPGMZA.EliasFano.decodingTableDocIDNumber,decodingTableHighBitsCarryover=WPGMZA.EliasFano.decodingTableHighBitsCarryover,lowBitsPointer=0,lastDocID=0,docID=0,listCount=compressedBuffer[lowBitsPointer++],lowBitsLength=(listCount=(listCount=(listCount|=compressedBuffer[lowBitsPointer++]<<8)|compressedBuffer[lowBitsPointer++]<<16)|compressedBuffer[lowBitsPointer++]<<24,compressedBuffer[lowBitsPointer++]),lowBitsCount=0,lowBits=0,cb=1,highBitsPointer=Math.floor(lowBitsLength*listCount/8+6);highBitsPointer<compressedBuffer.pointer;highBitsPointer++){docID+=decodingTableHighBitsCarryover[cb];for(var docIDNumber=decodingTableDocIDNumber[cb=compressedBuffer[highBitsPointer]],i=0;i<docIDNumber;i++){for(docID=docID<<lowBitsCount|lowBits&(1<<lowBitsCount)-1;lowBitsCount<lowBitsLength;)docID=(docID<<=8)|(lowBits=compressedBuffer[lowBitsPointer++]),lowBitsCount+=8;docID=(docID>>=lowBitsCount-=lowBitsLength)+((decodingTableHighBits[cb][i]<<lowBitsLength)+lastDocID+1),lastDocID=list[resultPointer++]=docID,docID=0}}return list}}),jQuery(function($){WPGMZA.EventDispatcher=function(){WPGMZA.assertInstanceOf(this,"EventDispatcher"),this._listenersByType={}},WPGMZA.EventDispatcher.prototype.addEventListener=function(type,listener,thisObject,useCapture){var types=type.split(/\s+/);if(1<types.length)for(var i=0;i<types.length;i++)this.addEventListener(types[i],listener,thisObject,useCapture);else{if(!(listener instanceof Function))throw new Error("Listener must be a function");type=this._listenersByType.hasOwnProperty(type)?this._listenersByType[type]:this._listenersByType[type]=[];type.push({listener:listener,thisObject:thisObject||this,useCapture:!!useCapture})}},WPGMZA.EventDispatcher.prototype.on=WPGMZA.EventDispatcher.prototype.addEventListener,WPGMZA.EventDispatcher.prototype.removeEventListener=function(type,listener,thisObject,useCapture){var arr,obj;if(arr=this._listenersByType[type]){thisObject=thisObject||this,useCapture=!!useCapture;for(var i=0;i<arr.length;i++)if(obj=arr[i],(1==arguments.length||obj.listener==listener)&&obj.thisObject==thisObject&&obj.useCapture==useCapture)return void arr.splice(i,1)}},WPGMZA.EventDispatcher.prototype.off=WPGMZA.EventDispatcher.prototype.removeEventListener,WPGMZA.EventDispatcher.prototype.hasEventListener=function(type){return!!_listenersByType[type]},WPGMZA.EventDispatcher.prototype.dispatchEvent=function(event){if(!(event instanceof WPGMZA.Event))if("string"==typeof event)event=new WPGMZA.Event(event);else{var name,src=event;for(name in event=new WPGMZA.Event,src)event[name]=src[name]}for(var path=[],obj=(event.target=this).parent;null!=obj;obj=obj.parent)path.unshift(obj);event.phase=WPGMZA.Event.CAPTURING_PHASE;for(var i=0;i<path.length&&!event._cancelled;i++)path[i]._triggerListeners(event);if(!event._cancelled){for(event.phase=WPGMZA.Event.AT_TARGET,this._triggerListeners(event),event.phase=WPGMZA.Event.BUBBLING_PHASE,i=path.length-1;0<=i&&!event._cancelled;i--)path[i]._triggerListeners(event);for(var topMostElement=this.element,obj=this.parent;null!=obj;obj=obj.parent)obj.element&&(topMostElement=obj.element);if(topMostElement){var key,customEvent={};for(key in event){var value=event[key];"type"==key&&(value+=".wpgmza"),customEvent[key]=value}$(topMostElement).trigger(customEvent)}}},WPGMZA.EventDispatcher.prototype.trigger=WPGMZA.EventDispatcher.prototype.dispatchEvent,WPGMZA.EventDispatcher.prototype._triggerListeners=function(event){var arr,obj;if(arr=this._listenersByType[event.type])for(var i=0;i<arr.length;i++)obj=arr[i],event.phase==WPGMZA.Event.CAPTURING_PHASE&&!obj.useCapture||obj.listener.call(arr[i].thisObject,event)},WPGMZA.events=new WPGMZA.EventDispatcher}),jQuery(function($){WPGMZA.AddressInput=function(element,map){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=element;var json,options={fields:["name","formatted_address"],types:["geocode","establishment"]};(json=$(element).attr("data-autocomplete-options"))&&(options=$.extend(options,JSON.parse(json))),map&&map.settings.wpgmza_store_locator_restrict&&(options.country=map.settings.wpgmza_store_locator_restrict),WPGMZA.isGoogleAutocompleteSupported()?"wpgmza_add_address_map_editor"!=this.id&&WPGMZA_localized_data.settings.googleMapsApiKey&&""!==WPGMZA_localized_data.settings.googleMapsApiKey&&(element.googleAutoComplete=new google.maps.places.Autocomplete(element,options),options.country&&element.googleAutoComplete.setComponentRestrictions({country:options.country})):WPGMZA.CloudAPI&&WPGMZA.CloudAPI.isBeingUsed&&(element.cloudAutoComplete=new WPGMZA.CloudAutocomplete(element,options))},WPGMZA.extend(WPGMZA.AddressInput,WPGMZA.EventDispatcher),WPGMZA.AddressInput.createInstance=function(element,map){return new WPGMZA.AddressInput(element,map)}}),jQuery(function($){WPGMZA.CapsuleModules=function(){WPGMZA.EventDispatcher.call(this),this.proxies={},this.capsules=[],this.prepareCapsules(),this.flagCapsules()},WPGMZA.extend(WPGMZA.CapsuleModules,WPGMZA.EventDispatcher),WPGMZA.CapsuleModules.getConstructor=function(){return WPGMZA.isProVersion()?WPGMZA.ProCapsuleModules:WPGMZA.CapsuleModules},WPGMZA.CapsuleModules.createInstance=function(){const constructor=WPGMZA.CapsuleModules.getConstructor();return new constructor},WPGMZA.CapsuleModules.prototype.proxyMap=function(id,settings){return this.proxies[id]||(this.proxies[id]=Object.create(this),this.proxies[id].id=id,this.proxies[id].markers=[],this.proxies[id].showPreloader=function(){},this.proxies[id].getMarkerByID=function(){return{}},this.proxies[id].markerFilter=WPGMZA.MarkerFilter.createInstance(this.proxies[id])),settings&&(this.proxies[id].settings=settings),this.proxies[id]},WPGMZA.CapsuleModules.prototype.flagCapsules=function(){if(this.capsules)for(var i in this.capsules)this.capsules[i].element&&$(this.capsules[i].element).addClass("wpgmza-capsule-module")},WPGMZA.CapsuleModules.prototype.prepareCapsules=function(){this.registerStoreLocator()},WPGMZA.CapsuleModules.prototype.registerStoreLocator=function(){$(".wpgmza-store-locator").each((index,element)=>{var mapId=$(element).data("map-id"),url=$(element).data("url");if(mapId&&!WPGMZA.getMapByID(mapId))if(url){var settings=$(element).data("map-settings"),settings=this.proxyMap(mapId,settings);const capsule={type:"store_locator",element:element,instance:WPGMZA.StoreLocator.createInstance(settings,element)};capsule.instance.isCapsule=!0,capsule.instance.redirectUrl=url,this.capsules.push(capsule)}else console.warn('WPGMZA: You seem to have added a stadalone store locator without a map page URL. Please add a URL to your shortcode [wpgmza_store_locator id="'+mapId+'" url="{URL}"] and try again')})}}),jQuery(function($){WPGMZA.ColorInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={format:"hex",anchor:"left",container:!1,autoClose:!0,autoOpen:!1,supportAlpha:!0,supportPalette:!0,wheelBorderWidth:10,wheelPadding:6,wheelBorderColor:"rgb(255,255,255)"},this.parseOptions(options),this.state={initialized:!1,sliderInvert:!1,lockSlide:!1,lockPicker:!1,open:!1,mouse:{down:!1}},this.color={h:0,s:0,l:100,a:1},this.wrap(),this.renderControls(),this.parseColor(this.value)},WPGMZA.extend(WPGMZA.ColorInput,WPGMZA.EventDispatcher),WPGMZA.ColorInput.createInstance=function(element){return new WPGMZA.ColorInput(element)},WPGMZA.ColorInput.prototype.clamp=function(min,max,value){return isNaN(value)&&(value=0),Math.min(Math.max(value,min),max)},WPGMZA.ColorInput.prototype.degreesToRadians=function(degrees){return degrees*(Math.PI/180)},WPGMZA.ColorInput.prototype.hueToRgb=function(p,q,t){return t<0&&(t+=1),1<t&&--t,t<1/6?p+6*(q-p)*t:t<.5?q:t<2/3?p+(q-p)*(2/3-t)*6:p},WPGMZA.ColorInput.prototype.getMousePositionInCanvas=function(canvas,event){canvas=canvas.getBoundingClientRect();return{x:event.clientX-canvas.left,y:event.clientY-canvas.top}},WPGMZA.ColorInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.ColorInput.prototype.getColor=function(override,format){var hsl=Object.assign({},this.color);if(override)for(var i in override)hsl[i]=override[i];format=format||this.options.format;var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l,hsl.a);switch(format){case"hsl":return"hsl("+hsl.h+", "+hsl.s+"%, "+hsl.l+"%)";case"hsla":return"hsla("+hsl.h+", "+hsl.s+"%, "+hsl.l+"%, "+hsl.a+")";case"rgb":return"rgb("+rgb.r+", "+rgb.g+", "+rgb.b+")";case"rgba":return"rgba("+rgb.r+", "+rgb.g+", "+rgb.b+", "+rgb.a+")"}return this.rgbToHex(rgb.r,rgb.g,rgb.b,rgb.a)},WPGMZA.ColorInput.prototype.setColor=function(hsl){for(var i in hsl)this.color[i]=hsl[i];this.options.supportAlpha||(this.color.a=1),this.updatePreview(),this.commit(),this.state.initialized&&this.update()},WPGMZA.ColorInput.prototype.parseColor=function(value){var hsl;"string"==typeof value&&(-1!==(value=""===(value=value.trim().toLowerCase().replace(/ /g,""))?"rgb(255,255,255)":value).indexOf("rgb")?(value=value.replace(/[a-z\(\)%]/g,""),parts=value.split(","),this.setColor(this.rgbToHsl(parts[0],parts[1],parts[2],parts[3]))):-1!==value.indexOf("hsl")?(value=value.replace(/[a-z\(\)%]/g,""),hsl={h:(parts=value.split(","))[0]?parseInt(parts[0]):0,s:parts[1]?parseInt(parts[1]):0,l:parts[2]?parseInt(parts[2]):100,a:parts[3]?parseFloat(parts[3]):1},this.setColor(hsl)):(hsl=this.hexToRgb(value),this.setColor(this.rgbToHsl(hsl.r,hsl.g,hsl.b,hsl.a))))},WPGMZA.ColorInput.prototype.rgbToHsl=function(r,g,b,a){var rgb={r:0<=r?r/255:255,g:0<=g?g/255:255,b:0<=b?b/255:255,a:0<=a?a:1},r=Math.min(rgb.r,rgb.g,rgb.b),g=Math.max(rgb.r,rgb.g,rgb.b),delta=g-r,hsl={h:(g+r)/2,s:(g+r)/2,l:(g+r)/2,a:rgb.a};if(0!=delta){switch(hsl.s=.5<hsl.l?delta/(2-g-r):delta/(g+r),g){case rgb.r:hsl.h=(rgb.g-rgb.b)/delta+(rgb.g<rgb.b?6:0);break;case rgb.g:hsl.h=(rgb.b-rgb.r)/delta+2;break;case rgb.b:hsl.h=(rgb.r-rgb.g)/delta+4}hsl.h=hsl.h/6}else hsl.h=0,hsl.s=0;return hsl.h=parseInt(360*hsl.h),hsl.s=parseInt(100*hsl.s),hsl.l=parseInt(100*hsl.l),hsl},WPGMZA.ColorInput.prototype.hexToRgb=function(hex){return(hex=hex.trim().toLowerCase().replace(/ /g,"").replace(/[^A-Za-z0-9\s]/g,"")).length<6&&(hex+=hex.charAt(hex.length-1).repeat(6-hex.length)),{r:parseInt(hex.slice(0,2),16),g:parseInt(hex.slice(2,4),16),b:parseInt(hex.slice(4,6),16),a:6<hex.length?this.floatToPrecision(parseInt(hex.slice(6,8),16)/255,2):1}},WPGMZA.ColorInput.prototype.hslToRgb=function(h,s,l,a){var h={h:0<=h?h:0,s:0<=s?s/100:0,l:0<=l?l/100:0,a:0<=a?a:1},s={r:0,g:0,b:0,a:h.a},l=(1-Math.abs(2*h.l-1))*h.s,a=l*(1-Math.abs(h.h/60%2-1)),diff=h.l-l/2;return 0<=h.h&&h.h<60?(s.r=l,s.g=a,s.b=0):60<=h.h&&h.h<120?(s.r=a,s.g=l,s.b=0):120<=h.h&&h.h<180?(s.r=0,s.g=l,s.b=a):180<=h.h&&h.h<240?(s.r=0,s.g=a,s.b=l):240<=h.h&&h.h<300?(s.r=a,s.g=0,s.b=l):300<=h.h&&h.h<360&&(s.r=l,s.g=0,s.b=a),s.r=Math.round(255*(s.r+diff)),s.g=Math.round(255*(s.g+diff)),s.b=Math.round(255*(s.b+diff)),s},WPGMZA.ColorInput.prototype.rgbToHex=function(r,g,b,a){var i,rgb={r:0<=r?r:255,g:0<=g?g:255,b:0<=b?b:255,a:0<=a?a:1};for(i in rgb.r=rgb.r.toString(16),rgb.g=rgb.g.toString(16),rgb.b=rgb.b.toString(16),rgb.a<1?rgb.a=Math.round(255*rgb.a).toString(16):rgb.a="",rgb)1===rgb[i].length&&(rgb[i]="0"+rgb[i]);return"#"+rgb.r+rgb.g+rgb.b+rgb.a},WPGMZA.ColorInput.prototype.floatToPrecision=function(float,precision){return float=parseFloat(float),parseFloat(float.toFixed(precision))},WPGMZA.ColorInput.prototype.wrap=function(){var self=this;if(!this.element||"text"!==this.type)throw new Error("WPGMZA.ColorInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-color-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element),this.options.autoClose&&($(document.body).on("click",function(){self.state.open&&(self.state.mouse.down=!1,self.onTogglePicker())}),$(document.body).on("colorpicker.open.wpgmza",function(event){event.instance!==self&&self.state.open&&self.onTogglePicker()}))},WPGMZA.ColorInput.prototype.renderControls=function(){var self=this;this.container&&(this.preview=$("<div class='wpgmza-color-preview wpgmza-shadow' />"),this.swatch=$("<div class='swatch' />"),this.picker=$("<div class='wpgmza-color-picker wpgmza-card wpgmza-shadow' />"),this.preview.append(this.swatch),this.picker.addClass("anchor-"+this.options.anchor),this.preview.addClass("anchor-"+this.options.anchor),this.preview.on("click",function(event){event.stopPropagation(),self.onTogglePicker()}),this.picker.on("click",function(event){event.stopPropagation()}),this.container.append(this.preview),this.options.container&&0<$(this.options.container).length?($(this.options.container).append(this.picker),$(this.options.container).addClass("wpgmza-color-input-host")):this.container.append(this.picker),this.options.autoOpen&&this.preview.trigger("click"))},WPGMZA.ColorInput.prototype.renderPicker=function(){this.state.initialized||(this.renderWheel(),this.renderFields(),this.renderPalette(),this.state.initialized=!0)},WPGMZA.ColorInput.prototype.renderWheel=function(){var self=this;this.wheel={wrap:$("<div class='canvas-wrapper' />"),element:$("<canvas class='color-wheel' />"),handle:$("<div class='canvas-handle' />"),slider:$("<div class='canvas-slider' />")},this.wheel.target=this.wheel.element.get(0),this.wheel.target.height=256,this.wheel.target.width=256,this.wheel.radius=(this.wheel.target.width-2*(this.options.wheelBorderWidth+this.options.wheelPadding))/2,this.wheel.degreeStep=1/this.wheel.radius,this.wheel.context=this.wheel.target.getContext("2d"),this.wheel.context.clearRect(0,0,this.wheel.target.width,this.wheel.target.height),this.wheel.grid={canvas:document.createElement("canvas")},this.wheel.grid.canvas.width=20,this.wheel.grid.canvas.height=20,this.wheel.grid.context=this.wheel.grid.canvas.getContext("2d"),this.wheel.grid.context.fillStyle="rgb(255,255,255)",this.wheel.grid.context.fillRect(0,0,this.wheel.grid.canvas.width,this.wheel.grid.canvas.height),this.wheel.grid.context.fillStyle="rgb(180,180,180)",this.wheel.grid.context.fillRect(0,0,this.wheel.grid.canvas.width/2,this.wheel.grid.canvas.height/2),this.wheel.grid.context.fillRect(this.wheel.grid.canvas.width/2,this.wheel.grid.canvas.height/2,this.wheel.grid.canvas.width/2,this.wheel.grid.canvas.height/2),this.wheel.element.on("mousedown",function(event){self.state.mouse.down=!0,self.onPickerMouseSelect(event)}),this.wheel.element.on("mousemove",function(event){self.state.mouse.down&&self.onPickerMouseSelect(event)}),this.wheel.element.on("mouseup",function(event){self.clearStates()}),this.wheel.element.on("mouseleave",function(event){self.clearStates()}),this.wheel.wrap.append(this.wheel.element),this.wheel.wrap.append(this.wheel.handle),this.wheel.wrap.append(this.wheel.slider),this.picker.append(this.wheel.wrap)},WPGMZA.ColorInput.prototype.renderFields=function(){var group,self=this;for(group in this.fields={wrap:$("<div class='wpgmza-color-field-wrapper' />"),toggle:$("<div class='color-field-toggle' />"),blocks:{hsla:{keys:["h","s","l","a"]},rgba:{keys:["r","g","b","a"]},hex:{keys:["hex"]}}},this.fields.toggle.on("click",function(){var view=self.fields.view;switch(view){case"hex":view="hsla";break;case"hsla":view="rgba";break;case"rgba":view="hex"}self.updateFieldView(view)}),this.fields.wrap.append(this.fields.toggle),this.fields.blocks){var index,keys=this.fields.blocks[group].keys;for(index in this.fields.blocks[group].wrap=$("<div class='field-block' data-type='"+group+"'/>"),this.fields.blocks[group].rows={labels:$("<div class='labels' />"),controls:$("<div class='controls' />")},this.fields.blocks[group].wrap.append(this.fields.blocks[group].rows.controls),this.fields.blocks[group].wrap.append(this.fields.blocks[group].rows.labels),this.options.supportAlpha||-1===keys.indexOf("a")||this.fields.blocks[group].wrap.addClass("alpha-disabled"),keys){var name=keys[index],label=$("<div class='inner-label' />");label.text(name),this.fields.blocks[group][name]=$("<input type='text'/>"),this.fields.blocks[group].rows.controls.append(this.fields.blocks[group][name]),this.fields.blocks[group].rows.labels.append(label),this.fields.blocks[group][name].on("keydown",function(event){const originalEvent=event.originalEvent;"Enter"===originalEvent.key&&(originalEvent.preventDefault(),originalEvent.stopPropagation(),$(event.currentTarget).trigger("change"))}),this.fields.blocks[group][name].on("change",function(){self.onFieldChange(this)})}this.fields.wrap.append(this.fields.blocks[group].wrap)}this.picker.append(this.fields.wrap),this.updateFieldView()},WPGMZA.ColorInput.prototype.renderPalette=function(){var self=this;if(this.options.supportPalette){for(var i in this.palette={wrap:$("<div class='wpgmza-color-palette-wrap' />"),variations:[{s:-10,l:-10},{h:15},{h:30},{h:-15},{h:-30},{h:100,s:10},{h:-100,s:-10},{h:180}],controls:[]},this.palette.variations){var mutator,variation=this.palette.variations[i],control=$("<div class='palette-swatch' />");for(mutator in variation)control.attr("data-"+mutator,variation[mutator]);control.on("click",function(){var elem=$(this);self.parseColor(elem.css("background-color")),self.element.trigger("input")}),this.palette.wrap.append(control),this.palette.controls.push(control)}this.picker.append(this.palette.wrap)}},WPGMZA.ColorInput.prototype.updateWheel=function(){this.wheel.center={x:this.wheel.radius+this.options.wheelBorderWidth+this.options.wheelPadding,y:this.wheel.radius+this.options.wheelBorderWidth+this.options.wheelPadding},this.color.a<1&&(this.wheel.grid.pattern=this.wheel.context.createPattern(this.wheel.grid.canvas,"repeat"),this.wheel.context.fillStyle=this.wheel.grid.pattern,this.wheel.context.beginPath(),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius,0,2*Math.PI,!0),this.wheel.context.closePath(),this.wheel.context.fill());for(var i=0;i<360;i++){var startAngle=(i-1)*Math.PI/180,endAngle=(i+1)*Math.PI/180;this.wheel.context.beginPath(),this.wheel.context.moveTo(this.wheel.center.x,this.wheel.center.y),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius,startAngle,endAngle),this.wheel.context.closePath(),this.wheel.context.fillStyle="hsla("+i+", 100%, 50%, "+this.color.a+")",this.wheel.context.fill()}var gradient=this.wheel.context.createRadialGradient(this.wheel.center.x,this.wheel.center.y,0,this.wheel.center.x,this.wheel.center.y,this.wheel.radius),gradient=(gradient.addColorStop(0,"rgba(255, 255, 255, 1)"),gradient.addColorStop(1,"rgba(255, 255, 255, 0)"),this.wheel.context.fillStyle=gradient,this.wheel.context.beginPath(),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius,0,2*Math.PI,!0),this.wheel.context.closePath(),this.wheel.context.fill(),this.wheel.context.lineWidth=2,this.wheel.context.strokeStyle=this.options.wheelBorderColor,this.wheel.context.stroke(),this.wheel.context.createLinearGradient(this.wheel.center.x,0,this.wheel.center.x,this.wheel.target.height)),gradient=(gradient.addColorStop(0,this.getColor({l:95},"hsl")),gradient.addColorStop(.5,this.getColor({l:50},"hsl")),gradient.addColorStop(1,this.getColor({l:5},"hsl")),this.wheel.context.beginPath(),this.wheel.context.lineWidth=this.options.wheelBorderWidth,this.wheel.context.strokeStyle=gradient,this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius+this.options.wheelPadding+this.options.wheelBorderWidth/2,0,2*Math.PI),this.wheel.context.stroke(),this.wheel.context.beginPath(),this.wheel.context.lineWidth=1,this.wheel.context.strokeStyle=this.options.wheelBorderColor,this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius+this.options.wheelPadding+this.options.wheelBorderWidth,0,2*Math.PI),this.wheel.context.stroke(),this.wheel.context.beginPath(),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius+this.options.wheelPadding,0,2*Math.PI),this.wheel.context.stroke(),this.wheel.context.createRadialGradient(this.wheel.center.x,this.wheel.center.y,0,this.wheel.center.x,this.wheel.center.y,this.wheel.radius));gradient.addColorStop(0,"rgba(80, 80, 80, 0)"),gradient.addColorStop(.95,"rgba(80, 80, 80, 0.0)"),gradient.addColorStop(1,"rgba(80, 80, 80, 0.1)"),this.wheel.context.beginPath(),this.wheel.context.lineWidth=6,this.wheel.context.strokeStyle=gradient,this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius-3,0,2*Math.PI),this.wheel.context.stroke()},WPGMZA.ColorInput.prototype.update=function(){this.updateHandles(),this.updateWheel(),this.updateFields(),this.updatePalette()},WPGMZA.ColorInput.prototype.updateHandles=function(){var localRadius=this.wheel.element.width()/2,localHandleOffset=(localRadius-this.options.wheelBorderWidth-this.options.wheelPadding)/100*this.color.s,localHandleOffset={left:localRadius+localHandleOffset*Math.cos(this.degreesToRadians(this.color.h))+"px",top:localRadius+localHandleOffset*Math.sin(this.degreesToRadians(this.color.h))+"px"},localHandleOffset=(this.wheel.handle.css(localHandleOffset),this.color.l/100*360/2),localRadius=(this.state.sliderInvert&&(localHandleOffset=360-localHandleOffset),{left:localRadius+(localRadius-this.options.wheelBorderWidth/2)*Math.cos(this.degreesToRadians(localHandleOffset+90))+"px",top:localRadius+(localRadius-this.options.wheelBorderWidth/2)*Math.sin(this.degreesToRadians(localHandleOffset+90))+"px"});this.wheel.slider.css(localRadius)},WPGMZA.ColorInput.prototype.updatePreview=function(){this.swatch.css({background:this.getColor(!1,"rgba")})},WPGMZA.ColorInput.prototype.updateFields=function(){var group,hsl=Object.assign({},this.color);for(group in this.fields.blocks)switch(group){case"hsla":this.fields.blocks[group].h.val(hsl.h),this.fields.blocks[group].s.val(hsl.s),this.fields.blocks[group].l.val(hsl.l),this.fields.blocks[group].a.val(hsl.a);break;case"rgba":var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l,hsl.a);this.fields.blocks[group].r.val(rgb.r),this.fields.blocks[group].g.val(rgb.g),this.fields.blocks[group].b.val(rgb.b),this.fields.blocks[group].a.val(rgb.a);break;case"hex":var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l,hsl.a),hex=this.rgbToHex(rgb.r,rgb.g,rgb.b,rgb.a);this.fields.blocks[group].hex.val(hex)}},WPGMZA.ColorInput.prototype.updatePalette=function(){if(this.options.supportPalette)for(var i in this.palette.controls){var mutator,hsl=Object.assign({},this.color),i=this.palette.controls[i],data=i.data();for(mutator in 0===hsl.l?(data.h&&(hsl.l+=Math.abs(data.h)/360*100),hsl.l+=10):100===hsl.l&&(data.h&&(hsl.l-=Math.abs(data.h)/360*100),hsl.l-=10),data)hsl[mutator]+=data[mutator];hsl.h<0?hsl.h+=360:360<hsl.h&&(hsl.h-=360),hsl.h=this.clamp(0,360,hsl.h),hsl.s=this.clamp(0,100,hsl.s),hsl.l=this.clamp(0,100,hsl.l);var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l);i.css("background","rgb("+rgb.r+", "+rgb.g+", "+rgb.b+")")}},WPGMZA.ColorInput.prototype.updateFieldView=function(view){switch(view=view||this.options.format||"hex"){case"rgb":view="rgba";break;case"hsl":view="hsla"}for(var group in this.fields.view=view,this.fields.blocks)group===this.fields.view?this.fields.blocks[group].wrap.show():this.fields.blocks[group].wrap.hide()},WPGMZA.ColorInput.prototype.onPickerMouseSelect=function(event){var localRadius=this.wheel.element.width()/2,event=this.getMousePositionInCanvas(this.wheel.target,event),event={x:event.x-localRadius,y:event.y-localRadius},angle=360*Math.atan2(event.y,event.x)/(2*Math.PI),event=(angle<0&&(angle+=360),Math.sqrt(event.x*event.x+event.y*event.y)),range={pickerScaler:localRadius/this.wheel.radius};range.pickerEdge=range.pickerScaler*localRadius,(event<=range.pickerEdge||this.state.lockPicker)&&!this.state.lockSlide?(this.setColor({h:parseInt(angle),s:Math.min(parseInt(event/range.pickerEdge*100),100)}),this.state.lockPicker=!0):((angle-=90)<0&&(angle+=360),this.state.sliderInvert=!1,180<angle&&(angle=180-(angle-180),this.state.sliderInvert=!0),this.setColor({l:parseInt(angle/180*100)}),this.state.lockSlide=!0),this.element.trigger("input")},WPGMZA.ColorInput.prototype.onFieldChange=function(field){if(field&&""!==$(field).val().trim()){var field=$(field).closest(".field-block"),type=field.data("type"),raw=[];if(field.find("input").each(function(){raw.push($(this).val())}),("hsla"===type||"rgba"===type)&&raw[3]){field=raw[3];if("."===field.trim().charAt(field.trim().length-1))return}switch(type){case"hsla":(hsl={h:raw[0]?parseInt(raw[0]):0,s:raw[1]?parseInt(raw[1]):0,l:raw[2]?parseInt(raw[2]):100,a:raw[3]?parseFloat(raw[3]):1}).h=this.clamp(0,360,hsl.h),hsl.s=this.clamp(0,100,hsl.s),hsl.l=this.clamp(0,100,hsl.l),hsl.a=this.clamp(0,1,hsl.a),this.setColor(hsl);break;case"rgba":(rgb={r:raw[0]?parseInt(raw[0]):255,g:raw[1]?parseInt(raw[1]):255,b:raw[2]?parseInt(raw[2]):255,a:raw[3]?parseFloat(raw[3]):1}).r=this.clamp(0,255,rgb.r),rgb.g=this.clamp(0,255,rgb.g),rgb.b=this.clamp(0,255,rgb.b),rgb.a=this.clamp(0,1,rgb.a);var hsl=this.rgbToHsl(rgb.r,rgb.g,rgb.b,rgb.a);this.setColor(hsl);break;case"hex":var rgb=this.hexToRgb(raw[0]||"#ffffff");this.setColor(this.rgbToHsl(rgb.r,rgb.g,rgb.b,rgb.a))}this.element.trigger("input")}},WPGMZA.ColorInput.prototype.onTogglePicker=function(){this.renderPicker(),this.picker.toggleClass("active"),this.update(),this.state.open=this.picker.hasClass("active"),this.state.open&&$(document.body).trigger({type:"colorpicker.open.wpgmza",instance:this})},WPGMZA.ColorInput.prototype.clearStates=function(){this.state.mouse.down=!1,this.state.lockSlide=!1,this.state.lockPicker=!1},WPGMZA.ColorInput.prototype.commit=function(){var syncValue=this.getColor();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-color-input").each(function(index,el){el.wpgmzaColorInput=WPGMZA.ColorInput.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSBackdropFilterInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={},this.parseOptions(options),this.state={initialized:!1},this.filters={blur:{enable:!1,value:0,unit:"px"},brightness:{enable:!1,value:0,unit:"%"},contrast:{enable:!1,value:0,unit:"%"},grayscale:{enable:!1,value:0,unit:"%"},hue_rotate:{enable:!1,value:0,unit:"deg"},invert:{enable:!1,value:0,unit:"%"},sepia:{enable:!1,value:0,unit:"%"},saturate:{enable:!1,value:0,unit:"%"}},this.wrap(),this.renderControls(),this.parseFilters(this.value)},WPGMZA.extend(WPGMZA.CSSBackdropFilterInput,WPGMZA.EventDispatcher),WPGMZA.CSSBackdropFilterInput.FILTER_PATTERN=/(\S+)/g,WPGMZA.CSSBackdropFilterInput.VALUE_PATTERN=/(\(\S*\))/g,WPGMZA.CSSBackdropFilterInput.createInstance=function(element){return new WPGMZA.CSSBackdropFilterInput(element)},WPGMZA.CSSBackdropFilterInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.CSSBackdropFilterInput.prototype.getFilters=function(override,format){let filters=[];for(var type in this.filters){var data=this.filters[type];data.enable&&(type=type.replace("_","-"),filters.push(type+"("+data.value+data.unit+")"))}return 0<filters.length?filters.join(" "):"none"},WPGMZA.CSSBackdropFilterInput.prototype.setFilters=function(filters){if(this.clearFilters(),filters instanceof Object)for(var type in filters){var value;!this.filters[type]||(value=filters[type])&&(this.filters[type].enable=!0,this.filters[type].value=value)}this.commit(),this.state.initialized&&this.update()},WPGMZA.CSSBackdropFilterInput.prototype.clearFilters=function(){for(var i in this.filters)this.filters[i].enable=!1,this.filters[i].value=0},WPGMZA.CSSBackdropFilterInput.prototype.parseFilters=function(value){if("string"==typeof value){let filters={};if("none"!==(value=""===(value=value.trim().toLowerCase())?"none":value)){value=value.match(WPGMZA.CSSBackdropFilterInput.FILTER_PATTERN);if(value&&value instanceof Array)for(var match of value){let valueArg=match.match(WPGMZA.CSSBackdropFilterInput.VALUE_PATTERN);valueArg=valueArg instanceof Array&&0<valueArg.length?valueArg[0]:"";var numericValue,match=match.replace(valueArg,"").replace("-","_");let value=null;0<valueArg.length&&((numericValue=valueArg.match(/(\d+)/g))instanceof Array&&0<numericValue.length&&(value=parseFloat(numericValue[0]))),filters[match]=value}}this.setFilters(filters)}},WPGMZA.CSSBackdropFilterInput.prototype.wrap=function(){if(!this.element||"text"!==this.type)throw new Error("WPGMZA.CSSUnitInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-styling-backdrop-filter-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element)},WPGMZA.CSSBackdropFilterInput.prototype.renderControls=function(){if(this.container)for(var type in this.itemWrappers={},this.filters){var data=this.filters[type],printType=type.replace("_"," ");const wrapper=$("<div class='backdrop-filter-item-wrap' data-type='"+type+"' />"),toggleWrap=$("<div class='backdrop-filter-toggle-wrap' />"),toggleInput=$("<input type='checkbox' class='backdrop-filter-item-toggle' />"),toggleLabel=$("<label />"),controlWrap=$("<div class='backdrop-filter-control-wrap' />");controlAttributes="data-min='1' data-max='100'","deg"===data.unit?controlAttributes="data-min='1' data-max='360'":"px"===data.unit&&(controlAttributes="data-min='1' data-max='200'");const controlInput=$("<input class='backdrop-filter-item-input' type='text' "+controlAttributes+" value='"+data.value+"' />"),controlLabel=$("<small />"),slider=(controlLabel.append("<span>"+data.value+"</span>"+data.unit),$("<div class='backdrop-filter-item-slider' />"));toggleLabel.append(toggleInput),toggleLabel.append(printType),toggleWrap.append(toggleLabel),controlWrap.append(controlInput),controlWrap.append(controlLabel),controlWrap.append(slider),wrapper.append(toggleWrap),wrapper.append(controlWrap),this.itemWrappers[type]=wrapper,this.container.append(wrapper),this.state.initialized=!0,slider.slider({range:"max",min:controlInput.data("min"),max:controlInput.data("max"),value:controlInput.val(),slide:function(event,ui){controlInput.val(ui.value),controlLabel.find("span").text(ui.value),controlInput.trigger("change")},change:function(event,ui){}}),controlInput.wpgmzaRelativeSlider=slider,toggleInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".backdrop-filter-item-wrap");event=parent.data("type");target.is(":checked")?(parent.addClass("enabled"),this.setFilterState(event,!0)):(parent.removeClass("enabled"),this.setFilterState(event,!1))}),controlInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".backdrop-filter-item-wrap");event=parent.data("type");this.setFilterValue(event,target.val())})}},WPGMZA.CSSBackdropFilterInput.prototype.setFilterState=function(type,state){this.filters[type]&&(this.filters[type].enable=state),this.commit()},WPGMZA.CSSBackdropFilterInput.prototype.setFilterValue=function(type,value){this.filters[type]&&(this.filters[type].value=parseFloat(value)),this.commit()},WPGMZA.CSSBackdropFilterInput.prototype.update=function(){if(this.container)for(var type in this.filters){var data=this.filters[type];const row=this.container.find('.backdrop-filter-item-wrap[data-type="'+type+'"]');row.find(".backdrop-filter-item-toggle").prop("checked",data.enable).trigger("change"),row.find(".backdrop-filter-item-input").val(data.value).trigger("change"),row.find(".backdrop-filter-item-slider").slider("value",data.value),row.find(".backdrop-filter-control-wrap").find("small span").text(data.value)}},WPGMZA.CSSBackdropFilterInput.prototype.commit=function(){var syncValue=this.getFilters();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-styling-backdrop-filter-input").each(function(index,el){el.wpgmzaCSSBackdropFilterInput=WPGMZA.CSSBackdropFilterInput.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSFilterInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={},this.parseOptions(options),this.state={initialized:!1},this.filters={blur:{enable:!1,value:0,unit:"px"},brightness:{enable:!1,value:0,unit:"%"},contrast:{enable:!1,value:0,unit:"%"},grayscale:{enable:!1,value:0,unit:"%"},hue_rotate:{enable:!1,value:0,unit:"deg"},invert:{enable:!1,value:0,unit:"%"},sepia:{enable:!1,value:0,unit:"%"},saturate:{enable:!1,value:0,unit:"%"}},this.wrap(),this.renderControls(),this.parseFilters(this.value)},WPGMZA.extend(WPGMZA.CSSFilterInput,WPGMZA.EventDispatcher),WPGMZA.CSSFilterInput.FILTER_PATTERN=/(\S+)/g,WPGMZA.CSSFilterInput.VALUE_PATTERN=/(\(\S*\))/g,WPGMZA.CSSFilterInput.createInstance=function(element){return new WPGMZA.CSSFilterInput(element)},WPGMZA.CSSFilterInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.CSSFilterInput.prototype.getFilters=function(override,format){let filters=[];for(var type in this.filters){var data=this.filters[type];data.enable&&(type=type.replace("_","-"),filters.push(type+"("+data.value+data.unit+")"))}return 0<filters.length?filters.join(" "):"none"},WPGMZA.CSSFilterInput.prototype.setFilters=function(filters){if(this.clearFilters(),filters instanceof Object)for(var type in filters){var value;!this.filters[type]||(value=filters[type])&&(this.filters[type].enable=!0,this.filters[type].value=value)}this.commit(),this.state.initialized&&this.update()},WPGMZA.CSSFilterInput.prototype.clearFilters=function(){for(var i in this.filters)this.filters[i].enable=!1,this.filters[i].value=0},WPGMZA.CSSFilterInput.prototype.parseFilters=function(value){if("string"==typeof value){let filters={};if("none"!==(value=""===(value=value.trim().toLowerCase())?"none":value)){value=value.match(WPGMZA.CSSFilterInput.FILTER_PATTERN);if(value&&value instanceof Array)for(var match of value){let valueArg=match.match(WPGMZA.CSSFilterInput.VALUE_PATTERN);valueArg=valueArg instanceof Array&&0<valueArg.length?valueArg[0]:"";var numericValue,match=match.replace(valueArg,"").replace("-","_");let value=null;0<valueArg.length&&((numericValue=valueArg.match(/(\d+)/g))instanceof Array&&0<numericValue.length&&(value=parseFloat(numericValue[0]))),filters[match]=value}}this.setFilters(filters)}},WPGMZA.CSSFilterInput.prototype.wrap=function(){if(!this.element||"text"!==this.type)throw new Error("WPGMZA.CSSFilterInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-css-filter-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element)},WPGMZA.CSSFilterInput.prototype.renderControls=function(){if(this.container)for(var type in this.itemWrappers={},this.filters){var data=this.filters[type],printType=type.replace("_"," ");const wrapper=$("<div class='css-filter-item-wrap' data-type='"+type+"' />"),toggleWrap=$("<div class='css-filter-toggle-wrap' />"),toggleInput=$("<input type='checkbox' class='css-filter-item-toggle' />"),toggleLabel=$("<label />"),controlWrap=$("<div class='css-filter-control-wrap' />");controlAttributes="data-min='1' data-max='100'","deg"===data.unit?controlAttributes="data-min='1' data-max='360'":"px"===data.unit&&(controlAttributes="data-min='1' data-max='200'");const controlInput=$("<input class='css-filter-item-input' type='text' "+controlAttributes+" value='"+data.value+"' />"),controlLabel=$("<small />"),slider=(controlLabel.append("<span>"+data.value+"</span>"+data.unit),$("<div class='css-filter-item-slider' />"));toggleLabel.append(toggleInput),toggleLabel.append(printType),toggleWrap.append(toggleLabel),controlWrap.append(controlInput),controlWrap.append(controlLabel),controlWrap.append(slider),wrapper.append(toggleWrap),wrapper.append(controlWrap),this.itemWrappers[type]=wrapper,this.container.append(wrapper),this.state.initialized=!0,slider.slider({range:"max",min:controlInput.data("min"),max:controlInput.data("max"),value:controlInput.val(),slide:function(event,ui){controlInput.val(ui.value),controlLabel.find("span").text(ui.value),controlInput.trigger("change")},change:function(event,ui){}}),controlInput.wpgmzaRelativeSlider=slider,toggleInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".css-filter-item-wrap");event=parent.data("type");target.is(":checked")?(parent.addClass("enabled"),this.setFilterState(event,!0)):(parent.removeClass("enabled"),this.setFilterState(event,!1))}),controlInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".css-filter-item-wrap");event=parent.data("type");this.setFilterValue(event,target.val())})}},WPGMZA.CSSFilterInput.prototype.setFilterState=function(type,state){this.filters[type]&&(this.filters[type].enable=state),this.commit()},WPGMZA.CSSFilterInput.prototype.setFilterValue=function(type,value){this.filters[type]&&(this.filters[type].value=parseFloat(value)),this.commit()},WPGMZA.CSSFilterInput.prototype.update=function(){if(this.container)for(var type in this.filters){var data=this.filters[type];const row=this.container.find('.css-filter-item-wrap[data-type="'+type+'"]');row.find(".css-filter-item-toggle").prop("checked",data.enable).trigger("change"),row.find(".css-filter-item-input").val(data.value).trigger("change"),row.find(".css-filter-item-slider").slider("value",data.value),row.find(".css-filter-control-wrap").find("small span").text(data.value)}},WPGMZA.CSSFilterInput.prototype.commit=function(){var syncValue=this.getFilters();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-css-filter-input").each(function(index,el){el.wpgmzaCSSFilterInput=WPGMZA.CSSFilterInput.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSStateBlock=function(element,options){if(!(element instanceof HTMLElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.tabs=this.element.find(".wpgmza-css-state-block-item"),this.items=this.element.find(".wpgmza-css-state-block-content"),this.items.removeClass("active"),this.bindEvents(),this.element.find(".wpgmza-css-state-block-item:first-child").click()},WPGMZA.extend(WPGMZA.CSSStateBlock,WPGMZA.EventDispatcher),WPGMZA.CSSStateBlock.createInstance=function(element){return new WPGMZA.CSSStateBlock(element)},WPGMZA.CSSStateBlock.prototype.bindEvents=function(){let self=this;this.tabs.on("click",function(event){self.onClick($(this))})},WPGMZA.CSSStateBlock.prototype.onClick=function(item){var type=item.data("type");type&&(this.tabs.removeClass("active"),item.addClass("active"),this.items.removeClass("active"),this.element.find('.wpgmza-css-state-block-content[data-type="'+type+'"]').addClass("active"))},$(document.body).ready(function(){$(".wpgmza-css-state-block").each(function(index,el){el.wpgmzaCSSStateBlock=WPGMZA.CSSStateBlock.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSUnitInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={},this.parseOptions(options),this.state={initialized:!1},this.unit={value:0,suffix:"px"},this.wrap(),this.renderControls(),this.parseUnits(this.value)},WPGMZA.extend(WPGMZA.CSSUnitInput,WPGMZA.EventDispatcher),WPGMZA.CSSUnitInput.VALID_TYPES=["px","%","rem","em"],WPGMZA.CSSUnitInput.createInstance=function(element){return new WPGMZA.CSSUnitInput(element)},WPGMZA.CSSUnitInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.CSSUnitInput.prototype.getUnits=function(override,format){return this.unit.value+this.unit.suffix},WPGMZA.CSSUnitInput.prototype.setUnits=function(value,suffix){this.unit.value=value?parseFloat(value):this.unit.value,this.unit.suffix=suffix?suffix.trim():this.unit.suffix,0<this.unit.value-parseInt(this.unit.value)&&(this.unit.value=parseFloat(this.unit.value.toFixed(2))),this.unit.value<=0&&(this.unit.value=0),this.validateSuffix(),this.commit(),this.state.initialized&&this.update()},WPGMZA.CSSUnitInput.prototype.parseUnits=function(value){if("string"==typeof value){let unit=(value=""===(value=value.trim().toLowerCase().replace(/ /g,""))?"0px":value).match(/((\d+\.\d+)|(\d+))/),suffix=(unit=unit&&unit[0]?parseFloat(unit[0]):this.unit.value,value.match(/(([a-z]+)|(%))/));suffix=suffix&&suffix[0]?suffix[0]:this.unit.suffix,this.setUnits(unit,suffix)}},WPGMZA.CSSUnitInput.prototype.wrap=function(){if(!this.element||"text"!==this.type)throw new Error("WPGMZA.CSSUnitInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-styling-unit-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element)},WPGMZA.CSSUnitInput.prototype.renderControls=function(){this.container&&(this.unitValueInput=$("<input type='text' class='unit-value-input' />"),this.unitSuffixToggle=$("<div class='unit-suffix-toggle' />"),this.unitValueStepDownBtn=$("<div class='unit-stepper-button' data-mode='down' />"),this.unitValueStepUpBtn=$("<div class='unit-stepper-button' data-mode='up' />"),this.unitValueStepperWrap=$("<div class='unit-stepper-wrapper' />"),this.unitInnerWrap=$("<div class='unit-input-inner-wrap' />"),this.unitValueStepperWrap.append(this.unitValueStepUpBtn),this.unitValueStepperWrap.append(this.unitValueStepDownBtn),this.unitInnerWrap.append(this.unitValueStepperWrap),this.unitInnerWrap.append(this.unitValueInput),this.unitInnerWrap.append(this.unitSuffixToggle),this.container.append(this.unitInnerWrap),this.state.initialized=!0,this.unitValueInput.on("keydown",event=>{const originalEvent=event.originalEvent;originalEvent.key&&1===originalEvent.key.length?(0===originalEvent.key.trim().length||"."!==originalEvent.key&&isNaN(parseInt(originalEvent.key)))&&this.unitSuffixToggle.hide():"ArrowUp"===originalEvent.key?this.increment():"ArrowDown"===originalEvent.key?this.decrement():"Enter"===originalEvent.key&&(originalEvent.preventDefault(),originalEvent.stopPropagation(),$(event.currentTarget).trigger("change"))}),this.unitValueInput.on("change",event=>{const input=$(event.currentTarget);this.parseUnits(input.val())}),this.unitValueStepUpBtn.on("click",event=>{this.increment()}),this.unitValueStepDownBtn.on("click",event=>{this.decrement()}))},WPGMZA.CSSUnitInput.prototype.validateSuffix=function(){(!this.unit.suffix||-1===WPGMZA.CSSUnitInput.VALID_TYPES.indexOf(this.unit.suffix))&&(this.unit.suffix=this.options.defaultSuffix)},WPGMZA.CSSUnitInput.prototype.increment=function(){this.parseUnits(this.unitValueInput.val());let value=this.unit.value;0<value-parseInt(value)?value+=.1:value+=1,this.setUnits(value,this.unit.suffix)},WPGMZA.CSSUnitInput.prototype.decrement=function(){this.parseUnits(this.unitValueInput.val());let value=this.unit.value;0<value-parseInt(value)?value-=.1:--value,this.setUnits(this.unit.value-1,this.unit.suffix)},WPGMZA.CSSUnitInput.prototype.update=function(){this.unitValueInput&&this.unitSuffixToggle&&(this.unitValueInput.val(this.unit.value),this.unitSuffixToggle.text(this.unit.suffix),this.unitSuffixToggle.show())},WPGMZA.CSSUnitInput.prototype.commit=function(){var syncValue=this.getUnits();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-stylig-unit-input").each(function(index,el){el.wpgmzaCSSUnitInput=WPGMZA.CSSUnitInput.createInstance(el)})})}),jQuery(function($){WPGMZA.DrawingManager=function(map){WPGMZA.assertInstanceOf(this,"DrawingManager"),WPGMZA.EventDispatcher.call(this);var self=this;this.map=map,this.mode=WPGMZA.DrawingManager.MODE_NONE,this.map.on("click rightclick",function(event){self.onMapClick(event)})},WPGMZA.DrawingManager.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.DrawingManager.prototype.constructor=WPGMZA.DrawingManager,WPGMZA.DrawingManager.MODE_NONE=null,WPGMZA.DrawingManager.MODE_MARKER="marker",WPGMZA.DrawingManager.MODE_POLYGON="polygon",WPGMZA.DrawingManager.MODE_POLYLINE="polyline",WPGMZA.DrawingManager.MODE_CIRCLE="circle",WPGMZA.DrawingManager.MODE_RECTANGLE="rectangle",WPGMZA.DrawingManager.MODE_HEATMAP="heatmap",WPGMZA.DrawingManager.MODE_POINTLABEL="pointlabel",WPGMZA.DrawingManager.MODE_IMAGEOVERLAY="imageoverlay",WPGMZA.DrawingManager.getConstructor=function(){return"google-maps"!==WPGMZA.settings.engine?WPGMZA.OLDrawingManager:WPGMZA.GoogleDrawingManager},WPGMZA.DrawingManager.createInstance=function(map){return new(WPGMZA.DrawingManager.getConstructor())(map)},WPGMZA.DrawingManager.prototype.setDrawingMode=function(mode){this.mode=mode,this.trigger("drawingmodechanged")},WPGMZA.DrawingManager.prototype.onMapClick=function(event){event.target instanceof WPGMZA.Map&&(this.mode!==WPGMZA.DrawingManager.MODE_POINTLABEL||this.pointlabel||(this.pointlabel=WPGMZA.Pointlabel.createInstance({center:new WPGMZA.LatLng({lat:event.latLng.lat,lng:event.latLng.lng}),map:this.map}),this.map.addPointlabel(this.pointlabel),this.pointlabel.setEditable(!0),this.onPointlabelComplete(this.pointlabel),this.pointlabel=!1))},WPGMZA.DrawingManager.prototype.onPointlabelComplete=function(pointlabel){var event=new WPGMZA.Event("pointlabelcomplete");event.enginePointlabel=pointlabel,this.dispatchEvent(event)}}),jQuery(function($){WPGMZA.EmbeddedMedia=function(element,container){if(!(element instanceof HTMLElement))throw new Error("Element is not an instance of HTMLInputElement");if(!(container instanceof HTMLElement))throw new Error("Container is not an instance of HTMLInputElement");const self=this;WPGMZA.EventDispatcher.apply(this),this.element=$(element),this.container=$(container),this.corners=["southEast"],this.handles=null,this.activeCorner=!1,this.container.on("mousemove",function(event){self.onMoveHandle(event)}),this.container.on("mouseup",function(event){self.activeCorner&&self.onDeactivateHandle(self.activeCorner)}),this.container.on("mouseleave",function(event){self.activeCorner&&(self.onDeactivateHandle(self.activeCorner),self.onDetach())}),this.container.on("mousedown",function(event){self.onDetach()})},WPGMZA.extend(WPGMZA.EmbeddedMedia,WPGMZA.EventDispatcher),WPGMZA.EmbeddedMedia.createInstance=function(element,container){return new WPGMZA.EmbeddedMedia(element,container)},WPGMZA.EmbeddedMedia.detatchAll=function(){var element;for(element of document.querySelectorAll(".wpgmza-embedded-media"))element.wpgmzaEmbeddedMedia&&element.wpgmzaEmbeddedMedia.onDetach();$(".wpgmza-embedded-media").removeClass("selected"),$(".wpgmza-embedded-media-handle").remove()},WPGMZA.EmbeddedMedia.prototype.onSelect=function(){this.element.addClass("selected"),this.updateHandles()},WPGMZA.EmbeddedMedia.prototype.onDetach=function(){this.element.removeClass("selected"),this.destroyHandles(),this.container.trigger("media_resized")},WPGMZA.EmbeddedMedia.prototype.onActivateHandle=function(corner){this.activeCorner=corner},WPGMZA.EmbeddedMedia.prototype.onDeactivateHandle=function(corner){this.activeCorner=!1,this.updateHandles()},WPGMZA.EmbeddedMedia.prototype.onMoveHandle=function(event){if(this.activeCorner&&this.handles[this.activeCorner]){const mouse=this.getMousePosition(event);this.handles[this.activeCorner].element&&(event=this.getAnchorPosition().y+this.element.height(),mouse.y>event&&(mouse.y=event),this.handles[this.activeCorner].element.css({left:mouse.x-3+"px",top:mouse.y-3+"px"}),this.applyResize(mouse))}},WPGMZA.EmbeddedMedia.prototype.createHandles=function(){if(!this.handles){this.handles={};for(var corner of this.corners)this.handles[corner]={element:$("<div/>"),mutating:!1},this.handles[corner].element.addClass("wpgmza-embedded-media-handle"),this.handles[corner].element.attr("data-corner",corner),this.container.append(this.handles[corner].element),this.bindHandle(corner)}},WPGMZA.EmbeddedMedia.prototype.destroyHandles=function(){if(this.handles&&this.handles instanceof Object){for(var i in this.handles){const handle=this.handles[i];handle.element&&handle.element.remove()}this.handles=null}},WPGMZA.EmbeddedMedia.prototype.updateHandles=function(){this.createHandles();var anchor=this.getAnchorPosition();if(this.handles&&this.handles instanceof Object)for(var corner in this.handles){const handle=this.handles[corner].element,position={top:0,left:0};"southEast"===corner&&(position.left=anchor.x+this.element.width(),position.top=anchor.y+this.element.height()),handle.css({left:position.left-3+"px",top:position.top-3+"px"})}},WPGMZA.EmbeddedMedia.prototype.bindHandle=function(corner){const self=this;this.handles&&this.handles[corner]&&(this.handles[corner].element.on("mousedown",function(event){event.preventDefault(),event.stopPropagation(),self.onActivateHandle(corner)}),this.handles[corner].element.on("mouseup",function(event){event.preventDefault(),event.stopPropagation(),self.onDeactivateHandle(corner)}))},WPGMZA.EmbeddedMedia.prototype.applyResize=function(mouse){var anchor=this.getAnchorPosition(),padding=parseInt(this.container.css("padding").replace("px","")),mouse=Math.abs(mouse.x-anchor.x),mouse=this.clamp(padding,this.container.width()-padding,mouse);this.element.css("width",parseInt(mouse)+"px"),this.element.attr("width",parseInt(mouse)),this.container.trigger("media_resized")},WPGMZA.EmbeddedMedia.prototype.getMousePosition=function(event){event=event.originalEvent||event;const pos={x:parseInt(event.pageX-this.container.offset().left),y:parseInt(event.pageY-this.container.offset().top)};event=parseInt(this.container.css("padding").replace("px",""));return pos.x=this.clamp(event,this.container.width()-event,pos.x),pos.y=this.clamp(event,this.container.height()-event,pos.y),pos},WPGMZA.EmbeddedMedia.prototype.getAnchorPosition=function(){return{x:parseInt(this.element.offset().left-this.container.offset().left),y:parseInt(this.element.offset().top-this.container.offset().top)}},WPGMZA.EmbeddedMedia.prototype.clamp=function(min,max,value){return isNaN(value)&&(value=0),Math.min(Math.max(value,min),max)}}),jQuery(function($){WPGMZA.Event=function(options){if("string"==typeof options&&(this.type=options),this.bubbles=!0,this.cancelable=!0,this.phase=WPGMZA.Event.PHASE_CAPTURE,this.target=null,this._cancelled=!1,"object"==typeof options)for(var name in options)this[name]=options[name]},WPGMZA.Event.CAPTURING_PHASE=0,WPGMZA.Event.AT_TARGET=1,WPGMZA.Event.BUBBLING_PHASE=2,WPGMZA.Event.prototype.stopPropagation=function(){this._cancelled=!0}}),jQuery(function($){WPGMZA.FancyControls={formatToggleSwitch:function(el){var div=$("<div class='switch'></div>"),input=el,el=el.parentNode,text=$(el).text().trim(),label=$("<label></label>");$(input).addClass("cmn-toggle cmn-toggle-round-flat"),$(input).attr("id",$(input).attr("name")),$(label).attr("for",$(input).attr("name")),$(div).append(input),$(div).append(label),$(el).replaceWith(div),$(div).wrap($("<div></div>")),$(div).after(text)},formatToggleButton:function(el){var div=$("<div class='switch'></div>"),input=el,el=el.parentNode,text=$(el).text().trim(),label=$("<label></label>");$(input).addClass("cmn-toggle cmn-toggle-yes-no"),$(input).attr("id",$(input).attr("name")),$(label).attr("for",$(input).attr("name")),$(label).attr("data-on",WPGMZA.localized_strings.yes),$(label).attr("data-off",WPGMZA.localized_strings.no),$(div).append(input),$(div).append(label),$(el).replaceWith(div),$(div).wrap($("<div></div>")),$(div).after(text)}},$(".wpgmza-fancy-toggle-switch").each(function(index,el){WPGMZA.FancyControls.formatToggleSwitch(el)}),$(".wpgmza-fancy-toggle-button").each(function(index,el){WPGMZA.FancyControls.formatToggleButton(el)})}),jQuery(function($){WPGMZA.Feature=function(options){for(var key in WPGMZA.assertInstanceOf(this,"Feature"),WPGMZA.EventDispatcher.call(this),this.id=-1,options)this[key]=options[key]},WPGMZA.extend(WPGMZA.Feature,WPGMZA.EventDispatcher),WPGMZA.MapObject=WPGMZA.Feature,WPGMZA.Feature.prototype.parseGeometry=function(subject){if("string"==typeof subject&&subject.match(/^\[/))try{subject=JSON.parse(subject)}catch(e){}if("object"==typeof subject){for(var arr=subject,i=0;i<arr.length;i++)arr[i].lat=parseFloat(arr[i].lat),arr[i].lng=parseFloat(arr[i].lng);return arr}if("string"!=typeof subject)throw new Error("Invalid geometry");for(var coords,results=[],pairs=subject.replace(/[^ ,\d\.\-+e]/g,"").split(","),i=0;i<pairs.length;i++)coords=pairs[i].split(" "),results.push({lat:parseFloat(coords[1]),lng:parseFloat(coords[0])});return results},WPGMZA.Feature.prototype.setOptions=function(options){for(var key in options)this[key]=options[key];this.updateNativeFeature()},WPGMZA.Feature.prototype.setEditable=function(editable){this.setOptions({editable:editable})},WPGMZA.Feature.prototype.setDraggable=function(draggable){this.setOptions({draggable:draggable})},WPGMZA.Feature.prototype.getScalarProperties=function(){var key,options={};for(key in this)switch(typeof this[key]){case"number":options[key]=parseFloat(this[key]);break;case"boolean":case"string":options[key]=this[key]}return options},WPGMZA.Feature.prototype.updateNativeFeature=function(){var props=this.getScalarProperties();"open-layers"===WPGMZA.settings.engine?this.layer&&this.layer.setStyle(WPGMZA.OLFeature.getOLStyle(props)):this.googleFeature.setOptions(props)}}),jQuery(function($){WPGMZA.FriendlyError=function(){}}),jQuery(function($){WPGMZA.GenericModal=function(element,complete,cancel){this.element=$(element),this._onComplete=complete||!1,this._onCancel=cancel||!1,this.bindEvents()},WPGMZA.extend(WPGMZA.GenericModal,WPGMZA.EventDispatcher),WPGMZA.GenericModal.createInstance=function(element,complete,cancel){return new(WPGMZA.isProVersion()?WPGMZA.ProGenericModal:WPGMZA.GenericModal)(element,complete,cancel)},WPGMZA.GenericModal.prototype.bindEvents=function(){const self=this;this.element.on("click",".wpgmza-button",function(){"complete"===$(this).data("action")?self.onComplete():self.onCancel()})},WPGMZA.GenericModal.prototype.getData=function(){const data={};return this.element.find("input,select").each(function(){$(this).data("ajax-name")&&(data[$(this).data("ajax-name")]=$(this).val())}),data},WPGMZA.GenericModal.prototype.onComplete=function(){this.hide(),"function"==typeof this._onComplete&&this._onComplete(this.getData())},WPGMZA.GenericModal.prototype.onCancel=function(){this.hide(),"function"==typeof this._onCancel&&this._onCancel()},WPGMZA.GenericModal.prototype.show=function(complete,cancel){this._onComplete=complete||this._onComplete,this._onCancel=cancel||this._onCancel,this.element.addClass("pending")},WPGMZA.GenericModal.prototype.hide=function(){this.element.removeClass("pending")}}),jQuery(function($){WPGMZA.Geocoder=function(){WPGMZA.assertInstanceOf(this,"Geocoder")},WPGMZA.Geocoder.SUCCESS="success",WPGMZA.Geocoder.ZERO_RESULTS="zero-results",WPGMZA.Geocoder.FAIL="fail",WPGMZA.Geocoder.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.GoogleGeocoder:WPGMZA.OLGeocoder},WPGMZA.Geocoder.createInstance=function(){return new(WPGMZA.Geocoder.getConstructor())},WPGMZA.Geocoder.prototype.getLatLngFromAddress=function(options,callback){WPGMZA.isLatLngString(options.address)&&(options=options.address.split(/,\s*/),callback([(callback=new WPGMZA.LatLng({lat:parseFloat(options[0]),lng:parseFloat(options[1])})).latLng=callback],WPGMZA.Geocoder.SUCCESS))},WPGMZA.Geocoder.prototype.getAddressFromLatLng=function(options,callback){callback([new WPGMZA.LatLng(options.latLng).toString()],WPGMZA.Geocoder.SUCCESS)},WPGMZA.Geocoder.prototype.geocode=function(options,callback){if("address"in options)return this.getLatLngFromAddress(options,callback);if("latLng"in options)return this.getAddressFromLatLng(options,callback);throw new Error("You must supply either a latLng or address")}}),jQuery(function($){WPGMZA.GoogleAPIErrorHandler=function(){var _error,self=this;"google-maps"==WPGMZA.settings.engine&&("map-edit"==WPGMZA.currentPage||0==WPGMZA.is_admin&&1==WPGMZA.userCanAdministrator)&&(this.element=$(WPGMZA.html.googleMapsAPIErrorDialog),1==WPGMZA.is_admin&&this.element.find(".wpgmza-front-end-only").remove(),this.errorMessageList=this.element.find(".wpgmza-google-api-error-list"),this.templateListItem=this.element.find("li.template").remove(),this.messagesAlreadyDisplayed={},_error=console.error,console.error=function(message){self.onErrorMessage(message),_error.apply(this,arguments)},"google-maps"!=WPGMZA.settings.engine||WPGMZA.settings.wpgmza_google_maps_api_key&&WPGMZA.settings.wpgmza_google_maps_api_key.length||WPGMZA.getCurrentPage()==WPGMZA.PAGE_MAP_EDIT||this.addErrorMessage(WPGMZA.localized_strings.no_google_maps_api_key,["https://www.wpgmaps.com/documentation/creating-a-google-maps-api-key/"]))},WPGMZA.GoogleAPIErrorHandler.prototype.onErrorMessage=function(message){var m,urls;message&&((m=message.match(/You have exceeded your (daily )?request quota for this API/))||(m=message.match(/This API project is not authorized to use this API/))||(m=message.match(/^Geocoding Service: .+/))?(urls=message.match(/http(s)?:\/\/[^\s]+/gm),this.addErrorMessage(m[0],urls)):(m=message.match(/^Google Maps.+error: (.+)\s+(http(s?):\/\/.+)/m))&&this.addErrorMessage(m[1].replace(/([A-Z])/g," $1"),[m[2]]))},WPGMZA.GoogleAPIErrorHandler.prototype.addErrorMessage=function(message,urls){var self=this;if(!this.messagesAlreadyDisplayed[message]){var li=this.templateListItem.clone(),buttonContainer=($(li).find(".wpgmza-message").html(message),$(li).find(".wpgmza-documentation-buttons")),buttonTemplate=$(li).find(".wpgmza-documentation-buttons>a");if(buttonTemplate.remove(),urls&&urls.length){for(var i=0;i<urls.length;i++){urls[i];var button=buttonTemplate.clone(),text=WPGMZA.localized_strings.documentation;button.attr("href",urls[i]),$(button).find("i").addClass("fa-external-link"),$(button).append(text)}buttonContainer.append(button)}$(this.errorMessageList).append(li),$("#wpgmza_map, .wpgmza_map").each(function(index,el){var container=$(el).find(".wpgmza-google-maps-api-error-overlay");0==container.length&&(container=$("<div class='wpgmza-google-maps-api-error-overlay'></div>")).html(self.element.html()),setTimeout(function(){$(el).append(container)},1e3)}),$(".gm-err-container").parent().css({"z-index":1}),this.messagesAlreadyDisplayed[message]=!0}},WPGMZA.googleAPIErrorHandler=new WPGMZA.GoogleAPIErrorHandler}),jQuery(function($){WPGMZA.InfoWindow=function(feature){var self=this;WPGMZA.EventDispatcher.call(this),WPGMZA.assertInstanceOf(this,"InfoWindow"),this.on("infowindowopen",function(event){self.onOpen(event)}),feature&&(this.feature=feature,this.state=WPGMZA.InfoWindow.STATE_CLOSED,feature.map?setTimeout(function(){self.onFeatureAdded(event)},100):feature.addEventListener("added",function(event){self.onFeatureAdded(event)}))},WPGMZA.InfoWindow.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.InfoWindow.prototype.constructor=WPGMZA.InfoWindow,WPGMZA.InfoWindow.OPEN_BY_CLICK=1,WPGMZA.InfoWindow.OPEN_BY_HOVER=2,WPGMZA.InfoWindow.STATE_OPEN="open",WPGMZA.InfoWindow.STATE_CLOSED="closed",WPGMZA.InfoWindow.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProInfoWindow:WPGMZA.GoogleInfoWindow:WPGMZA.isProVersion()?WPGMZA.OLProInfoWindow:WPGMZA.OLInfoWindow},WPGMZA.InfoWindow.createInstance=function(feature){return new(this.getConstructor())(feature)},Object.defineProperty(WPGMZA.InfoWindow.prototype,"content",{get:function(){return this.getContent()},set:function(value){this.contentHtml=value}}),WPGMZA.InfoWindow.prototype.addEditButton=function(){return"map-edit"==WPGMZA.currentPage&&this.feature instanceof WPGMZA.Marker?' <a title="Edit this marker" style="width:15px;" class="wpgmza_edit_btn" data-edit-marker-id="'+this.feature.id+'"><i class="fa fa-edit"></i></a>':""},WPGMZA.InfoWindow.prototype.workOutDistanceBetweenTwoMarkers=function(location1,location2){if(location1&&location2)return location1=WPGMZA.Distance.between(location1,location2),this.distanceUnits==WPGMZA.Distance.MILES&&(location1/=WPGMZA.Distance.KILOMETERS_PER_MILE),Math.round(location1,2)},WPGMZA.InfoWindow.prototype.getContent=function(callback){var currentLatLng,html="",extra_html="";return this.feature instanceof WPGMZA.Marker&&(this.feature.map.settings.store_locator_show_distance&&this.feature.map.storeLocator&&this.feature.map.storeLocator.state==WPGMZA.StoreLocator.STATE_APPLIED&&(currentLatLng=this.feature.getPosition(),currentLatLng=this.workOutDistanceBetweenTwoMarkers(this.feature.map.storeLocator.center,currentLatLng),extra_html+="<p>"+(this.feature.map.settings.store_locator_distance==WPGMZA.Distance.KILOMETERS?currentLatLng+WPGMZA.localized_strings.kilometers_away:currentLatLng+" "+WPGMZA.localized_strings.miles_away)+"</p>"),html=this.feature.address+extra_html),this.contentHtml&&(html=this.contentHtml),callback&&callback(html),html},WPGMZA.InfoWindow.prototype.open=function(map,feature){return this.feature=feature,!WPGMZA.settings.disable_infowindows&&"1"!=WPGMZA.settings.wpgmza_settings_disable_infowindows&&(!this.feature.disableInfoWindow&&(this.state=WPGMZA.InfoWindow.STATE_OPEN,!0))},WPGMZA.InfoWindow.prototype.close=function(){this.state!=WPGMZA.InfoWindow.STATE_CLOSED&&(this.state=WPGMZA.InfoWindow.STATE_CLOSED,this.trigger("infowindowclose"))},WPGMZA.InfoWindow.prototype.setContent=function(options){},WPGMZA.InfoWindow.prototype.setOptions=function(options){},WPGMZA.InfoWindow.prototype.onFeatureAdded=function(){1==this.feature.settings.infoopen&&this.open()},WPGMZA.InfoWindow.prototype.onOpen=function(){}}),jQuery(function($){"installer"==WPGMZA.currentPage&&(WPGMZA.Installer=function(){var defaultEngine,self=this;WPGMZA.EventDispatcher.apply(this),this.element=$(document.body).find(".wpgmza-installer-steps"),this.element.length<=0||(this.redirectUrl=this.element.data("redirect"),this.step=0,this.max=0,this.findMax(),$(this.element).on("click",".next-step-button",function(event){self.next()}),$(this.element).on("click",".prev-step-button",function(event){self.prev()}),$(this.element).on("click",".sub-step-trigger",function(event){self.triggerSubStep($(this))}),$(this.element).on("change",'input[name="wpgmza_maps_engine"]',function(event){self.setEngine($(this).val())}),$(this.element).on("keyup change",'input[name="api_key"]',function(event){self.setApiKey($(this).val())}),$(this.element).on("change",'select[name="tile_server_url"]',function(event){self.setTileServer($(this).val())}),$(this.element).on("click",".google-maps-auto-key-form-wrapper .wpgmza-button",function(event){self.getAutoKey()}),$(this.element).on("click",".launcher-trigger",function(event){var launcher=$(this).data("launcher");launcher&&"google-maps-quick-start-launcher"===launcher&&self.launchQuickStart()}),defaultEngine=WPGMZA&&WPGMZA.settings&&WPGMZA.settings.engine?WPGMZA.settings.engine:"google-maps",$(this.element).find('input[name="wpgmza_maps_engine"][value="'+defaultEngine+'"]').prop("checked",!0).trigger("change"),defaultEngine=WPGMZA&&WPGMZA.settings&&WPGMZA.settings.googleMapsApiKey?WPGMZA.settings.googleMapsApiKey:"",this.element.find('input[name="api_key"]').val(defaultEngine).trigger("change"),this.trigger("init.installer.admin"),this.loadStep(this.step))},WPGMZA.extend(WPGMZA.Installer,WPGMZA.EventDispatcher),WPGMZA.Installer.NODE_SERVER="https://wpgmaps.us-3.evennode.com/api/v1/",WPGMZA.Installer.createInstance=function(){return new WPGMZA.Installer},WPGMZA.Installer.prototype.findMax=function(){var self=this;$(this.element).find(".step").each(function(){parseInt($(this).data("step"))>self.max&&(self.max=parseInt($(this).data("step")))})},WPGMZA.Installer.prototype.prepareAddressFields=function(){$(this.element).find("input.wpgmza-address").each(function(index,el){el.addressInput=WPGMZA.AddressInput.createInstance(el,null)})},WPGMZA.Installer.prototype.next=function(){this.step<this.max?this.loadStep(this.step+1):this.complete()},WPGMZA.Installer.prototype.prev=function(){0<this.step&&this.loadStep(this.step-1)},WPGMZA.Installer.prototype.loadStep=function(index){this.loadSubSteps(index),$(this.element).find(".step").removeClass("active"),$(this.element).find('.step[data-step="'+index+'"]').addClass("active"),this.step=index,0===this.step?$(this.element).find(".prev-step-button").addClass("wpgmza-hidden"):$(this.element).find(".prev-step-button").removeClass("wpgmza-hidden"),this.step===this.max?$(this.element).find(".next-step-button span").text($(this.element).find(".next-step-button").data("final")):$(this.element).find(".next-step-button span").text($(this.element).find(".next-step-button").data("next")),this.autoFocus(),this.applyStepConditionState(),$(window).scrollTop(0),this.trigger("step.installer.admin")},WPGMZA.Installer.prototype.loadSubSteps=function(index){const stepWrapper=$(this.element).find('.step[data-step="'+index+'"]');stepWrapper.find(".sub-step-container").length&&(stepWrapper.find(".sub-step").addClass("wpgmza-hidden"),stepWrapper.find(".sub-step-container").removeClass("wpgmza-hidden"))},WPGMZA.Installer.prototype.triggerSubStep=function(context){const stepWrapper=$(this.element).find('.step[data-step="'+this.step+'"]');if(stepWrapper.find(".sub-step-container").length){context=context.data("sub-step");if(stepWrapper.find('.sub-step[data-sub-step="'+context+'"]').length&&(stepWrapper.find(".sub-step-container").addClass("wpgmza-hidden"),stepWrapper.find(".sub-step").addClass("wpgmza-hidden"),stepWrapper.find('.sub-step[data-sub-step="'+context+'"]').removeClass("wpgmza-hidden"),"google-maps-auto-key"===context))try{if(WPGMZA.getCurrentPosition(function(data){if(data.coords){data=data.coords;if($('.google-maps-auto-key-form-wrapper input[name="address"]').attr("placeholder","Fetching..."),data.latitude&&data.longitude){const geocoder=WPGMZA.Geocoder.createInstance();geocoder.getAddressFromLatLng({latLng:new WPGMZA.LatLng({lat:data.latitude,lng:data.longitude})},function(address){$('.google-maps-auto-key-form-wrapper input[name="address"]').attr("placeholder",""),address&&$('.google-maps-auto-key-form-wrapper input[name="address"]').val(address)})}else $('.google-maps-auto-key-form-wrapper input[name="address"]').attr("placeholder","")}}),$('.google-maps-auto-key-form-wrapper input[name="site_url"]').val().trim().length<=0){var domain=window.location.hostname;if("localhost"===domain)try{var paths=window.location.pathname.match(/\/(.*?)\//);paths&&2<=paths.length&&paths[1]&&(domain+="-"+paths[1])}catch(ex){}$('.google-maps-auto-key-form-wrapper input[name="site_url"]').val(domain),$('.google-maps-auto-key-form-wrapper input[name="site_url"]').attr("data-predicted-domain",domain)}}catch(ex){}}},WPGMZA.Installer.prototype.getActiveBlock=function(){return $(this.element).find('.step[data-step="'+this.step+'"]')},WPGMZA.Installer.prototype.autoFocus=function(){var block=this.getActiveBlock();block&&(0<block.find("input").length?block.find("input")[0].focus():0<block.find("select").length&&block.find("select")[0].focus())},WPGMZA.Installer.prototype.complete=function(){$(this.element).find(".step").removeClass("active"),$(this.element).find(".step-controller").addClass("wpgmza-hidden"),$(this.element).find(".step-loader").removeClass("wpgmza-hidden"),$(this.element).find(".step-loader .progress-finish").removeClass("wpgmza-hidden"),this.saveOptions()},WPGMZA.Installer.prototype.getData=function(){var data={};return $(this.element).find(".step").each(function(){$(this).find("input,select").each(function(){var value,name=$(this).attr("name");name&&""!==name.trim()&&""!==(value=$(this).val()).trim()&&(data[name.trim()]=value.trim())})}),data},WPGMZA.Installer.prototype.setEngine=function(engine){this.engine=engine,$(this.element).attr("data-engine",engine)},WPGMZA.Installer.prototype.setApiKey=function(apiKey){this.apiKey=apiKey.trim(),this.applyStepConditionState()},WPGMZA.Installer.prototype.setTileServer=function(server){let previewLink=this.tileServer=server;previewLink=(previewLink=previewLink.replace("{a-c}","a")).replace("{z}/{x}/{y}","7/20/49"),$(this.element).find(".open_layers_sample_tile").attr("src",previewLink)},WPGMZA.Installer.prototype.applyStepConditionState=function(){const stepWrapper=this.getActiveBlock();var condition=stepWrapper.data("conditional");const continueButton=$(this.element).find(".next-step-button");!condition||this.hasSatisfiedStepCondition(condition)?continueButton.removeClass("wpgmza-hidden"):continueButton.addClass("wpgmza-hidden")},WPGMZA.Installer.prototype.hasSatisfiedStepCondition=function(condition){let satisfied=!1;return satisfied="engine-set-up"===condition?!this.engine||"google-maps"!==this.engine||!!this.apiKey:satisfied},WPGMZA.Installer.prototype.getAutoKey=function(){return!1},WPGMZA.Installer.prototype.launchQuickStart=function(){const popupDimensions={width:570,height:700};popupDimensions.left=(screen.width-popupDimensions.width)/2,popupDimensions.top=(screen.height-popupDimensions.height)/2,$("#adminmenuwrap").length&&(popupDimensions.left+=$("#adminmenuwrap").width()/2);let attributes=[];attributes.push("resizable=yes"),attributes.push("width="+popupDimensions.width),attributes.push("height="+popupDimensions.height),attributes.push("left="+popupDimensions.left),attributes.push("top="+popupDimensions.top),attributes=attributes.join(","),window.open("https://console.cloud.google.com/google/maps-hosted","WP Go Maps - Create API Key",attributes)},WPGMZA.Installer.prototype.saveOptions=function(){const self=this;var formData=this.getData(),formData={action:"wpgmza_installer_page_save_options",nonce:this.element.attr("data-ajax-nonce"),wpgmza_maps_engine:this.engine,tile_server_url:formData.tile_server_url,api_key:formData.api_key};$(event.target).prop("disabled",!0),$.ajax(WPGMZA.ajaxurl,{method:"POST",data:formData,success:function(response,status,xhr){window.location.href=self.redirectUrl}})},WPGMZA.Installer.prototype.hideAutoKeyError=function(){$(".auto-key-error").addClass("wpgmza-hidden")},WPGMZA.Installer.prototype.showAutoKeyError=function(codeOrMsg){let message="";(message=-1===codeOrMsg.indexOf(" ")?$(".auto-key-error").data(codeOrMsg)||codeOrMsg:codeOrMsg).length?($(".auto-key-error").find(".notice").text(message),$(".auto-key-error").removeClass("wpgmza-hidden")):this.hideAutoKeyError()},$(document).ready(function(event){WPGMZA.installer=WPGMZA.Installer.createInstance()}))}),jQuery(function($){WPGMZA.InternalEngine={LEGACY:"legacy",ATLAS_NOVUS:"atlast-novus",isLegacy:function(){return WPGMZA.settings.internalEngine===WPGMZA.InternalEngine.LEGACY},getEngine:function(){return WPGMZA.settings.internalEngine}}}),jQuery(function($){WPGMZA.InternalViewport=function(map){WPGMZA.EventDispatcher.apply(this),this.map=map,this.limits={},this.element=this.getContainer(),this.update(),$(window).on("resize",event=>{this.trigger("resize.internalviewport"),this.update()})},WPGMZA.extend(WPGMZA.InternalViewport,WPGMZA.EventDispatcher),WPGMZA.InternalViewport.RECT_TYPE_LARGE=0,WPGMZA.InternalViewport.RECT_TYPE_MEDIUM=1,WPGMZA.InternalViewport.RECT_TYPE_SMALL=2,WPGMZA.InternalViewport.CONTAINER_THRESHOLD_MEDIUM=960,WPGMZA.InternalViewport.CONTAINER_THRESHOLD_SMALL=760,WPGMZA.InternalViewport.createInstance=function(map){return new WPGMZA.InternalViewport(map)},WPGMZA.InternalViewport.prototype.getContainer=function(){return this.map&&this.map.element?this.map.element:document.body||!1},WPGMZA.InternalViewport.prototype.getRectType=function(){let type=WPGMZA.InternalViewport.RECT_TYPE_LARGE;return this.limits.container&&this.limits.container.width.value&&(this.limits.container.width.value<=WPGMZA.InternalViewport.CONTAINER_THRESHOLD_SMALL?type=WPGMZA.InternalViewport.RECT_TYPE_SMALL:this.limits.container.width.value<=WPGMZA.InternalViewport.CONTAINER_THRESHOLD_MEDIUM&&(type=WPGMZA.InternalViewport.RECT_TYPE_MEDIUM)),type},WPGMZA.InternalViewport.prototype.wrapMeasurement=function(value,suffix){return{value:value,suffix:suffix||"px"}},WPGMZA.InternalViewport.prototype.update=function(){this.trace(),this.localize(),this.addClass(),this.trigger("update.internalviewport")},WPGMZA.InternalViewport.prototype.trace=function(){this.traceLimits(),this.trigger("trace.internalviewport")},WPGMZA.InternalViewport.prototype.traceLimits=function(){this.limits={container:{},overlays:{},panels:{}},this.getContainer()&&(this.limits.container.width=this.wrapMeasurement(parseInt(this.map.element.offsetWidth)),this.limits.container.height=this.wrapMeasurement(parseInt(this.map.element.offsetHeight)),mode=this.getRectType(),this.limits.container.width&&(this.limits.overlays.max_width=this.wrapMeasurement(100*[.5,.7,1][mode],"%"),this.limits.panels.max_width=this.wrapMeasurement(100*[.3,.5,1][mode],"%")))},WPGMZA.InternalViewport.prototype.localize=function(){const localized={};for(var tag in this.limits)if(this.limits[tag])for(var name in this.limits[tag]){var prop=this.limits[tag][name];name=name.replaceAll("_","-"),name="--wpgmza--viewport-"+tag+"-"+name,localized[name]=prop.value+prop.suffix}var container=this.getContainer();container&&$(container).css(localized),this.trigger("localize.internalviewport")},WPGMZA.InternalViewport.prototype.addClass=function(){var mode,classes=["wpgmza-viewport-large","wpgmza-viewport-medium","wpgmza-viewport-small"],container=this.getContainer();container&&($(container).removeClass(classes),mode=this.getRectType(),$(container).addClass(classes[mode]))}}),jQuery(function($){WPGMZA.LatLng=function(arg,lng){if(this._lat=0,(this._lng=0)!=arguments.length)if(1==arguments.length){if("string"==typeof arg){var m;if(!(m=arg.match(WPGMZA.LatLng.REGEXP)))throw new Error("Invalid LatLng string");arg={lat:m[1],lng:m[3]}}if("object"!=typeof arg||!("lat"in arg&&"lng"in arg))throw new Error("Argument must be a LatLng literal");this.lat=arg.lat,this.lng=arg.lng}else this.lat=arg,this.lng=lng},WPGMZA.LatLng.REGEXP=/^(\-?\d+(\.\d+)?),\s*(\-?\d+(\.\d+)?)$/,WPGMZA.LatLng.isValid=function(obj){return"object"==typeof obj&&("lat"in obj&&"lng"in obj)},WPGMZA.LatLng.isLatLngString=function(str){return"string"==typeof str&&!!str.match(WPGMZA.LatLng.REGEXP)},Object.defineProperty(WPGMZA.LatLng.prototype,"lat",{get:function(){return this._lat},set:function(val){if(!$.isNumeric(val))throw new Error("Latitude must be numeric");this._lat=parseFloat(val)}}),Object.defineProperty(WPGMZA.LatLng.prototype,"lng",{get:function(){return this._lng},set:function(val){if(!$.isNumeric(val))throw new Error("Longitude must be numeric");this._lng=parseFloat(val)}}),WPGMZA.LatLng.fromString=function(string){if(!WPGMZA.LatLng.isLatLngString(string))throw new Error("Not a valid latlng string");string=string.match(WPGMZA.LatLng.REGEXP);return new WPGMZA.LatLng({lat:parseFloat(string[1]),lng:parseFloat(string[3])})},WPGMZA.LatLng.prototype.toString=function(){return this._lat+", "+this._lng},WPGMZA.LatLng.fromCurrentPosition=function(callback,options){options=options||{},callback&&WPGMZA.getCurrentPosition(function(position){var latLng=new WPGMZA.LatLng({lat:position.coords.latitude,lng:position.coords.longitude});options.geocodeAddress?WPGMZA.Geocoder.createInstance().getAddressFromLatLng({latLng:latLng},function(results){results.length&&(latLng.address=results[0]),callback(latLng)}):callback(latLng)})},WPGMZA.LatLng.fromGoogleLatLng=function(googleLatLng){return new WPGMZA.LatLng(googleLatLng.lat(),googleLatLng.lng())},WPGMZA.LatLng.toGoogleLatLngArray=function(arr){var result=[];return arr.forEach(function(nativeLatLng){if(!(nativeLatLng instanceof WPGMZA.LatLng||"lat"in nativeLatLng&&"lng"in nativeLatLng))throw new Error("Unexpected input");result.push(new google.maps.LatLng({lat:parseFloat(nativeLatLng.lat),lng:parseFloat(nativeLatLng.lng)}))}),result},WPGMZA.LatLng.prototype.toGoogleLatLng=function(){return new google.maps.LatLng({lat:this.lat,lng:this.lng})},WPGMZA.LatLng.prototype.toLatLngLiteral=function(){return{lat:this.lat,lng:this.lng}},WPGMZA.LatLng.prototype.moveByDistance=function(kilometers,heading){var kilometers=parseFloat(kilometers)/6371,heading=parseFloat(heading)/180*Math.PI,phi1=this.lat/180*Math.PI,lambda1=this.lng/180*Math.PI,sinPhi1=Math.sin(phi1),phi1=Math.cos(phi1),sinDelta=Math.sin(kilometers),kilometers=Math.cos(kilometers),sinTheta=Math.sin(heading),heading=sinPhi1*kilometers+phi1*sinDelta*Math.cos(heading),phi2=Math.asin(heading),lambda1=lambda1+Math.atan2(sinTheta*sinDelta*phi1,kilometers-sinPhi1*heading);this.lat=180*phi2/Math.PI,this.lng=180*lambda1/Math.PI},WPGMZA.LatLng.prototype.getGreatCircleDistance=function(arg1,arg2){var lat1=this.lat,lon1=this.lng;if(1==arguments.length)other=new WPGMZA.LatLng(arg1);else{if(2!=arguments.length)throw new Error("Invalid number of arguments");other=new WPGMZA.LatLng(arg1,arg2)}var lat2=other.lat,other=other.lng,phi1=lat1.toRadians(),phi2=lat2.toRadians(),lat2=(lat2-lat1).toRadians(),lat1=(other-lon1).toRadians(),other=Math.sin(lat2/2)*Math.sin(lat2/2)+Math.cos(phi1)*Math.cos(phi2)*Math.sin(lat1/2)*Math.sin(lat1/2);return 6371*(2*Math.atan2(Math.sqrt(other),Math.sqrt(1-other)))}}),jQuery(function($){WPGMZA.LatLngBounds=function(southWest,northEast){var other;southWest instanceof WPGMZA.LatLngBounds?(this.south=(other=southWest).south,this.north=other.north,this.west=other.west,this.east=other.east):southWest&&northEast&&(this.south=southWest.lat,this.north=northEast.lat,this.west=southWest.lng,this.east=northEast.lng)},WPGMZA.LatLngBounds.fromGoogleLatLngBounds=function(googleLatLngBounds){if(!(googleLatLngBounds instanceof google.maps.LatLngBounds))throw new Error("Argument must be an instance of google.maps.LatLngBounds");var result=new WPGMZA.LatLngBounds,southWest=googleLatLngBounds.getSouthWest(),googleLatLngBounds=googleLatLngBounds.getNorthEast();return result.north=googleLatLngBounds.lat(),result.south=southWest.lat(),result.west=southWest.lng(),result.east=googleLatLngBounds.lng(),result},WPGMZA.LatLngBounds.fromGoogleLatLngBoundsLiteral=function(obj){var result=new WPGMZA.LatLngBounds,southWest=obj.southwest,obj=obj.northeast;return result.north=obj.lat,result.south=southWest.lat,result.west=southWest.lng,result.east=obj.lng,result},WPGMZA.LatLngBounds.prototype.isInInitialState=function(){return null==this.north&&null==this.south&&null==this.west&&null==this.east},WPGMZA.LatLngBounds.prototype.extend=function(latLng){if(latLng instanceof WPGMZA.LatLng||(latLng=new WPGMZA.LatLng(latLng)),this.isInInitialState())return this.north=this.south=latLng.lat,void(this.west=this.east=latLng.lng);latLng.lat<this.north&&(this.north=latLng.lat),latLng.lat>this.south&&(this.south=latLng.lat),latLng.lng<this.west&&(this.west=latLng.lng),latLng.lng>this.east&&(this.east=latLng.lng)},WPGMZA.LatLngBounds.prototype.extendByPixelMargin=function(map,x,arg){var y=x;if(!(map instanceof WPGMZA.Map))throw new Error("First argument must be an instance of WPGMZA.Map");if(this.isInInitialState())throw new Error("Cannot extend by pixels in initial state");3<=arguments.length&&(y=arg);var southWest=new WPGMZA.LatLng(this.south,this.west),northEast=new WPGMZA.LatLng(this.north,this.east),southWest=map.latLngToPixels(southWest),northEast=map.latLngToPixels(northEast);southWest.x-=x,southWest.y+=y,northEast.x+=x,northEast.y-=y,southWest=map.pixelsToLatLng(southWest.x,southWest.y),northEast=map.pixelsToLatLng(northEast.x,northEast.y),this.toString();this.north=northEast.lat,this.south=southWest.lat,this.west=southWest.lng,this.east=northEast.lng},WPGMZA.LatLngBounds.prototype.contains=function(latLng){if(latLng instanceof WPGMZA.LatLng)return!(latLng.lat<Math.min(this.north,this.south))&&(!(latLng.lat>Math.max(this.north,this.south))&&(this.west<this.east?latLng.lng>=this.west&&latLng.lng<=this.east:latLng.lng<=this.west||latLng.lng>=this.east));throw new Error("Argument must be an instance of WPGMZA.LatLng")},WPGMZA.LatLngBounds.prototype.toString=function(){return this.north+"N "+this.south+"S "+this.west+"W "+this.east+"E"},WPGMZA.LatLngBounds.prototype.toLiteral=function(){return{north:this.north,south:this.south,west:this.west,east:this.east}}}),jQuery(function($){var key,legacyGlobals={marker_pull:"0",marker_array:[],MYMAP:[],infoWindow_poly:[],markerClusterer:[],heatmap:[],WPGM_Path:[],WPGM_Path_Polygon:[],WPGM_PathLine:[],WPGM_PathLineData:[],WPGM_PathData:[],original_iw:null,wpgmza_user_marker:null,wpgmaps_localize_marker_data:[],wpgmaps_localize_polygon_settings:[],wpgmaps_localize_heatmap_settings:[],wpgmaps_localize_polyline_settings:[],wpgmza_cirtcle_data_array:[],wpgmza_rectangle_data_array:[],wpgmzaForceLegacyMarkerClusterer:!1};for(key in legacyGlobals)!function(key){key in window?console.warn("Cannot redefine legacy global "+key):Object.defineProperty(window,key,{get:function(){return console.warn("This property is deprecated and should no longer be used"),legacyGlobals[key]},set:function(value){console.warn("This property is deprecated and should no longer be used"),legacyGlobals[key]=value}})}(key);WPGMZA.legacyGlobals=legacyGlobals,window.InitMap=window.resetLocations=window.searchLocations=window.fillInAddress=window.searchLocationsNear=function(){console.warn("This function is deprecated and should no longer be used")}}),jQuery(function($){WPGMZA.MapListPage=function(){$("body").on("click",".wpgmza_copy_shortcode",function(){var $temp=jQuery("<input>");jQuery('<span id="wpgmza_tmp" style="display:none; width:100%; text-align:center;">');jQuery("body").append($temp),$temp.val(jQuery(this).val()).select(),document.execCommand("copy"),$temp.remove(),WPGMZA.notification("Shortcode Copied")})},WPGMZA.MapListPage.createInstance=function(){return new WPGMZA.MapListPage},$(document).ready(function(event){WPGMZA.getCurrentPage()==WPGMZA.PAGE_MAP_LIST&&(WPGMZA.mapListPage=WPGMZA.MapListPage.createInstance())})}),jQuery(function($){WPGMZA.MapSettings=function(element){var json,self=this,element=element.getAttribute("data-settings");try{json=JSON.parse(element)}catch(e){element=(element=element.replace(/\\%/g,"%")).replace(/\\\\"/g,'\\"');try{json=JSON.parse(element)}catch(e){json={},console.warn("Failed to parse map settings JSON")}}function addSettings(input){if(input)for(var key in input){var value;"other_settings"!=key&&(value=input[key],String(value).match(/^-?\d+$/)&&(value=parseInt(value)),self[key]=value)}}WPGMZA.assertInstanceOf(this,"MapSettings"),addSettings(WPGMZA.settings),addSettings(json),json&&json.other_settings&&addSettings(json.other_settings)},WPGMZA.MapSettings.prototype.toOLViewOptions=function(){var coords,self=this,options={center:ol.proj.fromLonLat([-119.4179,36.7783]),zoom:4};function empty(name){return"object"!=typeof self[name]&&(!self[name]||!self[name].length)}return"string"==typeof this.start_location&&(coords=this.start_location.replace(/^\(|\)$/g,"").split(","),WPGMZA.isLatLngString(this.start_location)?options.center=ol.proj.fromLonLat([parseFloat(coords[1]),parseFloat(coords[0])]):console.warn("Invalid start location")),this.center&&(options.center=ol.proj.fromLonLat([parseFloat(this.center.lng),parseFloat(this.center.lat)])),empty("map_start_lat")||empty("map_start_lng")||(options.center=ol.proj.fromLonLat([parseFloat(this.map_start_lng),parseFloat(this.map_start_lat)])),this.zoom&&(options.zoom=parseInt(this.zoom)),this.start_zoom&&(options.zoom=parseInt(this.start_zoom)),this.map_start_zoom&&(options.zoom=parseInt(this.map_start_zoom)),this.map_min_zoom&&this.map_max_zoom&&(options.minZoom=Math.min(this.map_min_zoom,this.map_max_zoom),options.maxZoom=Math.max(this.map_min_zoom,this.map_max_zoom)),options},WPGMZA.MapSettings.prototype.toGoogleMapsOptions=function(){var self=this,latLngCoords=this.start_location&&this.start_location.length?this.start_location.split(","):[36.7783,-119.4179];function empty(name){return"object"!=typeof self[name]&&(!self[name]||!self[name].length)}function formatCoord(coord){return $.isNumeric(coord)?coord:parseFloat(String(coord).replace(/[\(\)\s]/,""))}var latLngCoords=new google.maps.LatLng(formatCoord(latLngCoords[0]),formatCoord(latLngCoords[1])),zoom=this.start_zoom?parseInt(this.start_zoom):4,options=(!this.start_zoom&&this.zoom&&(zoom=parseInt(this.zoom)),{zoom:zoom=this.map_start_zoom?parseInt(this.map_start_zoom):zoom,center:latLngCoords});function isSettingDisabled(value){return"yes"===value||!!value}switch(empty("center")||(options.center=new google.maps.LatLng({lat:parseFloat(this.center.lat),lng:parseFloat(this.center.lng)})),empty("map_start_lat")||empty("map_start_lng")||(options.center=new google.maps.LatLng({lat:parseFloat(this.map_start_lat),lng:parseFloat(this.map_start_lng)})),this.map_min_zoom&&this.map_max_zoom&&(options.minZoom=Math.min(this.map_min_zoom,this.map_max_zoom),options.maxZoom=Math.max(this.map_min_zoom,this.map_max_zoom)),options.zoomControl=!isSettingDisabled(this.wpgmza_settings_map_zoom),options.panControl=!isSettingDisabled(this.wpgmza_settings_map_pan),options.mapTypeControl=!isSettingDisabled(this.wpgmza_settings_map_type),options.streetViewControl=!isSettingDisabled(this.wpgmza_settings_map_streetview),options.fullscreenControl=!isSettingDisabled(this.wpgmza_settings_map_full_screen_control),options.draggable=!isSettingDisabled(this.wpgmza_settings_map_draggable),options.disableDoubleClickZoom=isSettingDisabled(this.wpgmza_settings_map_clickzoom),isSettingDisabled(this.wpgmza_settings_map_tilt_controls)&&(options.rotateControl=!1,options.tilt=0),this.wpgmza_settings_map_scroll&&(options.scrollwheel=!1),"greedy"==this.wpgmza_force_greedy_gestures||"yes"==this.wpgmza_force_greedy_gestures||1==this.wpgmza_force_greedy_gestures?(options.gestureHandling="greedy",!this.wpgmza_settings_map_scroll&&"scrollwheel"in options&&delete options.scrollwheel):options.gestureHandling="cooperative",parseInt(this.type)){case 2:options.mapTypeId=google.maps.MapTypeId.SATELLITE;break;case 3:options.mapTypeId=google.maps.MapTypeId.HYBRID;break;case 4:options.mapTypeId=google.maps.MapTypeId.TERRAIN;break;default:options.mapTypeId=google.maps.MapTypeId.ROADMAP}return this.wpgmza_theme_data&&this.wpgmza_theme_data.length&&(options.styles=WPGMZA.GoogleMap.parseThemeData(this.wpgmza_theme_data)),options}}),jQuery(function($){WPGMZA.Map=function(element,options){var self=this;if(WPGMZA.assertInstanceOf(this,"Map"),WPGMZA.EventDispatcher.call(this),!(element instanceof HTMLElement||window.elementor))throw new Error("Argument must be a HTMLElement");if(element.hasAttribute("data-map-id")?this.id=element.getAttribute("data-map-id"):this.id=1,!/\d+/.test(this.id))throw new Error("Map ID must be an integer");if(WPGMZA.maps.push(this),this.element=element,this.element.wpgmzaMap=this,$(this.element).addClass("wpgmza-initialized"),this.engineElement=element,this.markers=[],this.polygons=[],this.polylines=[],this.circles=[],this.rectangles=[],this.pointlabels=[],WPGMZA.googleAPIStatus&&"USER_CONSENT_NOT_GIVEN"==WPGMZA.googleAPIStatus.code)return $(element).append($(WPGMZA.api_consent_html)),void $(element).css({height:"auto"});if(this.loadSettings(options),this.loadStyling(),this.shortcodeAttributes={},$(this.element).attr("data-shortcode-attributes"))try{this.shortcodeAttributes=JSON.parse($(this.element).attr("data-shortcode-attributes")),this.shortcodeAttributes.zoom&&(this.settings.map_start_zoom=parseInt(this.shortcodeAttributes.zoom))}catch(e){console.warn("Error parsing shortcode attributes")}this.innerStack=$(this.element).find(".wpgmza-inner-stack"),this.setDimensions(),this.setAlignment(),this.initInternalViewport(),this.markerFilter=WPGMZA.MarkerFilter.createInstance(this),this.on("init",function(event){self.onInit(event)}),this.on("click",function(event){self.onClick(event)}),$(document.body).on("fullscreenchange.wpgmza",function(event){var fullscreen=self.isFullScreen();self.onFullScreenChange(fullscreen)}),WPGMZA.useLegacyGlobals&&(wpgmzaLegacyGlobals.MYMAP[this.id]={map:null,bounds:null,mc:null},wpgmzaLegacyGlobals.MYMAP.init=wpgmzaLegacyGlobals.MYMAP[this.id].init=wpgmzaLegacyGlobals.MYMAP.placeMarkers=wpgmzaLegacyGlobals.MYMAP[this.id].placeMarkers=function(){console.warn("This function is deprecated and should no longer be used")})},WPGMZA.Map.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.Map.prototype.constructor=WPGMZA.Map,WPGMZA.Map.nightTimeThemeData=[{elementType:"geometry",stylers:[{color:"#242f3e"}]},{elementType:"labels.text.fill",stylers:[{color:"#746855"}]},{elementType:"labels.text.stroke",stylers:[{color:"#242f3e"}]},{featureType:"administrative.locality",elementType:"labels.text.fill",stylers:[{color:"#d59563"}]},{featureType:"landscape",elementType:"geometry.fill",stylers:[{color:"#575663"}]},{featureType:"poi",elementType:"labels.text.fill",stylers:[{color:"#d59563"}]},{featureType:"poi.park",elementType:"geometry",stylers:[{color:"#263c3f"}]},{featureType:"poi.park",elementType:"labels.text.fill",stylers:[{color:"#6b9a76"}]},{featureType:"road",elementType:"geometry",stylers:[{color:"#38414e"}]},{featureType:"road",elementType:"geometry.stroke",stylers:[{color:"#212a37"}]},{featureType:"road",elementType:"labels.text.fill",stylers:[{color:"#9ca5b3"}]},{featureType:"road.highway",elementType:"geometry",stylers:[{color:"#746855"}]},{featureType:"road.highway",elementType:"geometry.fill",stylers:[{color:"#80823e"}]},{featureType:"road.highway",elementType:"geometry.stroke",stylers:[{color:"#1f2835"}]},{featureType:"road.highway",elementType:"labels.text.fill",stylers:[{color:"#f3d19c"}]},{featureType:"transit",elementType:"geometry",stylers:[{color:"#2f3948"}]},{featureType:"transit.station",elementType:"labels.text.fill",stylers:[{color:"#d59563"}]},{featureType:"water",elementType:"geometry",stylers:[{color:"#17263c"}]},{featureType:"water",elementType:"geometry.fill",stylers:[{color:"#1b737a"}]},{featureType:"water",elementType:"labels.text.fill",stylers:[{color:"#515c6d"}]},{featureType:"water",elementType:"labels.text.stroke",stylers:[{color:"#17263c"}]}],WPGMZA.Map.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProMap:WPGMZA.GoogleMap:WPGMZA.isProVersion()?WPGMZA.OLProMap:WPGMZA.OLMap},WPGMZA.Map.createInstance=function(element,options){return new(WPGMZA.Map.getConstructor())(element,options)},Object.defineProperty(WPGMZA.Map.prototype,"markersPlaced",{get:function(){return this._markersPlaced},set:function(value){throw new Error("Value is read only")}}),Object.defineProperty(WPGMZA.Map.prototype,"lat",{get:function(){return this.getCenter().lat},set:function(value){var center=this.getCenter();center.lat=value,this.setCenter(center)}}),Object.defineProperty(WPGMZA.Map.prototype,"lng",{get:function(){return this.getCenter().lng},set:function(value){var center=this.getCenter();center.lng=value,this.setCenter(center)}}),Object.defineProperty(WPGMZA.Map.prototype,"zoom",{get:function(){return this.getZoom()},set:function(value){this.setZoom(value)}}),WPGMZA.Map.prototype.onInit=function(event){this.initPreloader(),0<this.innerStack.length&&$(this.element).append(this.innerStack),WPGMZA.getCurrentPage()!=WPGMZA.PAGE_MAP_EDIT&&this.initStoreLocator(),"autoFetchFeatures"in this.settings&&!1===this.settings.autoFetchFeatures||this.fetchFeatures()},WPGMZA.Map.prototype.initPreloader=function(){this.preloader=$(WPGMZA.preloaderHTML),$(this.preloader).hide(),$(this.element).append(this.preloader)},WPGMZA.Map.prototype.showPreloader=function(show){show?$(this.preloader).show():$(this.preloader).hide()},WPGMZA.Map.prototype.loadSettings=function(options){var settings=new WPGMZA.MapSettings(this.element);settings.other_settings;if(delete settings.other_settings,options)for(var key in options)settings[key]=options[key];this.settings=settings},WPGMZA.Map.prototype.loadStyling=function(){if(!WPGMZA.InternalEngine.isLegacy()){if(WPGMZA.stylingSettings&&WPGMZA.stylingSettings instanceof Object&&0<Object.keys(WPGMZA.stylingSettings).length)for(var name in WPGMZA.stylingSettings){var value;-1===name.indexOf("--")||(value=WPGMZA.stylingSettings[name])&&$(this.element).css(name,value)}var tileFilter;this.settings&&this.settings.wpgmza_ol_tile_filter&&((tileFilter=this.settings.wpgmza_ol_tile_filter.trim())&&$(this.element).css("--wpgmza-ol-tile-filter",tileFilter))}},WPGMZA.Map.prototype.initInternalViewport=function(){"1"!=WPGMZA.is_admin&&(this.internalViewport=WPGMZA.InternalViewport.createInstance(this))},WPGMZA.Map.prototype.initStoreLocator=function(){var storeLocatorElement=$(".wpgmza_sl_main_div,.wpgmza-store-locator");storeLocatorElement.length&&(this.storeLocator=WPGMZA.StoreLocator.createInstance(this,storeLocatorElement[0]))},WPGMZA.Map.prototype.getFeatureArrays=function(){var arrays=WPGMZA.Map.prototype.getFeatureArrays.call(this);return arrays.heatmaps=this.heatmaps,arrays.imageoverlays=this.imageoverlays,arrays},WPGMZA.Map.prototype.setOptions=function(options){for(var name in options)this.settings[name]=options[name]},WPGMZA.Map.prototype.getRESTParameters=function(options){var defaults={};return options&&options.filter||(defaults.filter=JSON.stringify(this.markerFilter.getFilteringParameters())),$.extend(!0,defaults,options)},WPGMZA.Map.prototype.fetchFeaturesViaREST=function(){var data,offset,limit,self=this,filter=this.markerFilter.getFilteringParameters();"1"==WPGMZA.is_admin&&(filter.includeUnapproved=!0,filter.excludeIntegrated=!0),this.shortcodeAttributes.acf_post_id&&(filter.acfPostID=this.shortcodeAttributes.acf_post_id),this.showPreloader(!0),this.fetchFeaturesXhr&&this.fetchFeaturesXhr.abort(),WPGMZA.settings.fetchMarkersBatchSize&&WPGMZA.settings.enable_batch_loading?(offset=0,limit=parseInt(WPGMZA.settings.fetchMarkersBatchSize),function fetchNextBatch(){filter.offset=offset,filter.limit=limit,data=self.getRESTParameters({filter:JSON.stringify(filter)}),self.fetchFeaturesXhr=WPGMZA.restAPI.call("/markers/",{useCompressedPathVariable:!0,data:data,success:function(result,status,xhr){result.length?(self.onMarkersFetched(result,!0),offset+=limit,fetchNextBatch()):(self.onMarkersFetched(result),data.exclude="markers",WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:data,success:function(result,status,xhr){self.onFeaturesFetched(result)}}))}})}()):(data=this.getRESTParameters({filter:JSON.stringify(filter)}),this.fetchFeaturesXhr=WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:data,success:function(result,status,xhr){self.onFeaturesFetched(result)}}))},WPGMZA.Map.prototype.fetchFeaturesViaXML=function(){var self=this,urls=[WPGMZA.markerXMLPathURL+this.id+"markers.xml"];function fetchFeaturesExcludingMarkersViaREST(){var filter={map_id:this.id,mashup_ids:this.mashupIDs},filter={filter:JSON.stringify(filter),exclude:"markers"};WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:filter,success:function(result,status,xhr){self.onFeaturesFetched(result)}})}if(this.mashupIDs&&this.mashupIDs.forEach(function(id){urls.push(WPGMZA.markerXMLPathURL+id+"markers.xml")}),urls=urls.filter(function(item,index){return urls.indexOf(item)==index}),window.Worker&&window.Blob&&window.URL&&WPGMZA.settings.enable_asynchronous_xml_parsing){var source=WPGMZA.loadXMLAsWebWorker.toString().replace(/function\(\)\s*{([\s\S]+)}/,"$1"),source=new Blob([source],{type:"text/javascript"}),source=new Worker(URL.createObjectURL(source));source.onmessage=function(event){self.onMarkersFetched(event.data),fetchFeaturesExcludingMarkersViaREST()},source.postMessage({command:"load",protocol:window.location.protocol,urls:urls})}else for(var filesLoaded=0,converter=new WPGMZA.XMLCacheConverter,converted=[],i=0;i<urls.length;i++)$.ajax(urls[i],{success:function(response,status,xhr){converted=converted.concat(converter.convert(response)),++filesLoaded==urls.length&&(self.onMarkersFetched(converted),fetchFeaturesExcludingMarkersViaREST())}})},WPGMZA.Map.prototype.fetchFeatures=function(){WPGMZA.settings.wpgmza_settings_marker_pull!=WPGMZA.MARKER_PULL_XML||"1"==WPGMZA.is_admin?this.fetchFeaturesViaREST():this.fetchFeaturesViaXML()},WPGMZA.Map.prototype.onFeaturesFetched=function(data){for(var type in data.markers&&this.onMarkersFetched(data.markers),data)if("markers"!=type)for(var module=type.substr(0,1).toUpperCase()+type.substr(1).replace(/s$/,""),i=0;i<data[type].length;i++){var instance=WPGMZA[module].createInstance(data[type][i]);this["add"+module](instance)}},WPGMZA.Map.prototype.onMarkersFetched=function(data,expectMoreBatches){for(var self=this,startFiltered=this.shortcodeAttributes.cat&&this.shortcodeAttributes.cat.length,i=0;i<data.length;i++){var obj=data[i],marker=WPGMZA.Marker.createInstance(obj);startFiltered&&(marker.isFiltered=!0,marker.setVisible(!1)),this.addMarker(marker)}if(!expectMoreBatches){this.showPreloader(!1);var triggerEvent=function(){self._markersPlaced=!0,self.trigger("markersplaced"),self.off("filteringcomplete",triggerEvent)};if(this.shortcodeAttributes.cat){for(var categories=this.shortcodeAttributes.cat.split(","),select=$("select[mid='"+this.id+"'][name='wpgmza_filter_select']"),i=0;i<categories.length;i++)$("input[type='checkbox'][mid='"+this.id+"'][value='"+categories[i]+"']").prop("checked",!0),select.val(categories[i]);this.on("filteringcomplete",triggerEvent),this.markerFilter.update({categories:categories})}else triggerEvent();if(this.shortcodeAttributes.markers){for(var arr=this.shortcodeAttributes.markers.split(","),markers=[],i=0;i<arr.length;i++){var id=(id=arr[i]).replace(" ",""),marker=this.getMarkerByID(id);markers.push(marker)}this.fitMapBoundsToMarkers(markers)}}},WPGMZA.Map.prototype.fetchFeaturesViaXML=function(){var self=this,urls=[WPGMZA.markerXMLPathURL+this.id+"markers.xml"];function fetchFeaturesExcludingMarkersViaREST(){var filter={map_id:this.id,mashup_ids:this.mashupIDs},filter={filter:JSON.stringify(filter),exclude:"markers"};WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:filter,success:function(result,status,xhr){self.onFeaturesFetched(result)}})}if(this.mashupIDs&&this.mashupIDs.forEach(function(id){urls.push(WPGMZA.markerXMLPathURL+id+"markers.xml")}),urls=urls.filter(function(item,index){return urls.indexOf(item)==index}),window.Worker&&window.Blob&&window.URL&&WPGMZA.settings.enable_asynchronous_xml_parsing){var source=WPGMZA.loadXMLAsWebWorker.toString().replace(/function\(\)\s*{([\s\S]+)}/,"$1"),source=new Blob([source],{type:"text/javascript"}),source=new Worker(URL.createObjectURL(source));source.onmessage=function(event){self.onMarkersFetched(event.data),fetchFeaturesExcludingMarkersViaREST()},source.postMessage({command:"load",protocol:window.location.protocol,urls:urls})}else for(var filesLoaded=0,converter=new WPGMZA.XMLCacheConverter,converted=[],i=0;i<urls.length;i++)$.ajax(urls[i],{success:function(response,status,xhr){converted=converted.concat(converter.convert(response)),++filesLoaded==urls.length&&(self.onMarkersFetched(converted),fetchFeaturesExcludingMarkersViaREST())}})},WPGMZA.Map.prototype.fetchFeatures=function(){WPGMZA.settings.wpgmza_settings_marker_pull!=WPGMZA.MARKER_PULL_XML||"1"==WPGMZA.is_admin?this.fetchFeaturesViaREST():this.fetchFeaturesViaXML()},WPGMZA.Map.prototype.onFeaturesFetched=function(data){for(var type in data.markers&&this.onMarkersFetched(data.markers),data)if("markers"!=type)for(var module=type.substr(0,1).toUpperCase()+type.substr(1).replace(/s$/,""),i=0;i<data[type].length;i++){var instance=WPGMZA[module].createInstance(data[type][i]);this["add"+module](instance)}},WPGMZA.Map.prototype.onMarkersFetched=function(data,expectMoreBatches){for(var self=this,startFiltered=this.shortcodeAttributes.cat&&this.shortcodeAttributes.cat.length,i=0;i<data.length;i++){var obj=data[i],marker=WPGMZA.Marker.createInstance(obj);startFiltered&&(marker.isFiltered=!0,marker.setVisible(!1)),this.addMarker(marker)}if(!expectMoreBatches){this.showPreloader(!1);var triggerEvent=function(){self._markersPlaced=!0,self.trigger("markersplaced"),self.off("filteringcomplete",triggerEvent)};if(this.shortcodeAttributes.cat){for(var categories=this.shortcodeAttributes.cat.split(","),select=$("select[mid='"+this.id+"'][name='wpgmza_filter_select']"),i=0;i<categories.length;i++)$("input[type='checkbox'][mid='"+this.id+"'][value='"+categories[i]+"']").prop("checked",!0),select.val(categories[i]);this.on("filteringcomplete",triggerEvent),this.markerFilter.update({categories:categories})}else triggerEvent();if(this.shortcodeAttributes.markers){for(var arr=this.shortcodeAttributes.markers.split(","),markers=[],i=0;i<arr.length;i++){var id=(id=arr[i]).replace(" ",""),marker=this.getMarkerByID(id);markers.push(marker)}this.fitMapBoundsToMarkers(markers)}}};Math.PI;function deg2rad(deg){return deg*(Math.PI/180)}WPGMZA.Map.getGeographicDistance=function(lat1,lon1,lat2,lon2){var dLat=deg2rad(lat2-lat1),lon2=deg2rad(lon2-lon1),lon1=Math.sin(dLat/2)*Math.sin(dLat/2)+Math.cos(deg2rad(lat1))*Math.cos(deg2rad(lat2))*Math.sin(lon2/2)*Math.sin(lon2/2);return 6371*(2*Math.atan2(Math.sqrt(lon1),Math.sqrt(1-lon1)))},WPGMZA.Map.prototype.setCenter=function(latLng){if(!("lat"in latLng&&"lng"in latLng))throw new Error("Argument is not an object with lat and lng")},WPGMZA.Map.prototype.setDimensions=function(width,height){0==arguments.length&&(width=this.settings.map_width||"100",this.settings.map_width_type?width+=this.settings.map_width_type.replace("\\",""):width+="%",height=this.settings.map_height||"400",this.settings.map_height_type?height+=this.settings.map_height_type.replace("\\",""):height+="px"),$(this.engineElement).css({width:width,height:height})},WPGMZA.Map.prototype.setAlignment=function(){switch(parseInt(this.settings.wpgmza_map_align)){case 1:case 2:$(this.element).addClass("wpgmza-auto-left");break;case 3:$(this.element).addClass("wpgmza-auto-right")}},WPGMZA.Map.prototype.addMarker=function(marker){if(!(marker instanceof WPGMZA.Marker))throw new Error("Argument must be an instance of WPGMZA.Marker");marker.map=this,(marker.parent=this).markers.push(marker),this.dispatchEvent({type:"markeradded",marker:marker}),marker.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removeMarker=function(marker){if(!(marker instanceof WPGMZA.Marker))throw new Error("Argument must be an instance of WPGMZA.Marker");if(marker.map!==this)throw new Error("Wrong map error");marker.infoWindow&&marker.infoWindow.close(),marker.map=null,marker.parent=null;var index=this.markers.indexOf(marker);if(-1==index)throw new Error("Marker not found in marker array");this.markers.splice(index,1),this.dispatchEvent({type:"markerremoved",marker:marker}),marker.dispatchEvent({type:"removed"})},WPGMZA.Map.prototype.removeAllMarkers=function(options){for(var i=this.markers.length-1;0<=i;i--)this.removeMarker(this.markers[i])},WPGMZA.Map.prototype.getMarkerByID=function(id){for(var i=0;i<this.markers.length;i++)if(this.markers[i].id==id)return this.markers[i];return null},WPGMZA.Map.prototype.getMarkerByTitle=function(title){if("string"==typeof title){for(var i=0;i<this.markers.length;i++)if(this.markers[i].title==title)return this.markers[i]}else{if(!(title instanceof RegExp))throw new Error("Invalid argument");for(i=0;i<this.markers.length;i++)if(title.test(this.markers[i].title))return this.markers[i]}return null},WPGMZA.Map.prototype.removeMarkerByID=function(id){id=this.getMarkerByID(id);id&&this.removeMarker(id)},WPGMZA.Map.prototype.addPolygon=function(polygon){if(!(polygon instanceof WPGMZA.Polygon))throw new Error("Argument must be an instance of WPGMZA.Polygon");(polygon.map=this).polygons.push(polygon),this.dispatchEvent({type:"polygonadded",polygon:polygon}),polygon.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removePolygon=function(polygon){if(!(polygon instanceof WPGMZA.Polygon))throw new Error("Argument must be an instance of WPGMZA.Polygon");if(polygon.map!==this)throw new Error("Wrong map error");polygon.map=null,this.polygons.splice(this.polygons.indexOf(polygon),1),this.dispatchEvent({type:"polygonremoved",polygon:polygon})},WPGMZA.Map.prototype.getPolygonByID=function(id){for(var i=0;i<this.polygons.length;i++)if(this.polygons[i].id==id)return this.polygons[i];return null},WPGMZA.Map.prototype.removePolygonByID=function(id){id=this.getPolygonByID(id);id&&this.removePolygon(id)},WPGMZA.Map.prototype.getPolylineByID=function(id){for(var i=0;i<this.polylines.length;i++)if(this.polylines[i].id==id)return this.polylines[i];return null},WPGMZA.Map.prototype.addPolyline=function(polyline){if(!(polyline instanceof WPGMZA.Polyline))throw new Error("Argument must be an instance of WPGMZA.Polyline");(polyline.map=this).polylines.push(polyline),this.dispatchEvent({type:"polylineadded",polyline:polyline}),polyline.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removePolyline=function(polyline){if(!(polyline instanceof WPGMZA.Polyline))throw new Error("Argument must be an instance of WPGMZA.Polyline");if(polyline.map!==this)throw new Error("Wrong map error");polyline.map=null,this.polylines.splice(this.polylines.indexOf(polyline),1),this.dispatchEvent({type:"polylineremoved",polyline:polyline})},WPGMZA.Map.prototype.getPolylineByID=function(id){for(var i=0;i<this.polylines.length;i++)if(this.polylines[i].id==id)return this.polylines[i];return null},WPGMZA.Map.prototype.removePolylineByID=function(id){id=this.getPolylineByID(id);id&&this.removePolyline(id)},WPGMZA.Map.prototype.addCircle=function(circle){if(!(circle instanceof WPGMZA.Circle))throw new Error("Argument must be an instance of WPGMZA.Circle");(circle.map=this).circles.push(circle),this.dispatchEvent({type:"circleadded",circle:circle}),circle.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removeCircle=function(circle){if(!(circle instanceof WPGMZA.Circle))throw new Error("Argument must be an instance of WPGMZA.Circle");if(circle.map!==this)throw new Error("Wrong map error");circle.map=null,this.circles.splice(this.circles.indexOf(circle),1),this.dispatchEvent({type:"circleremoved",circle:circle})},WPGMZA.Map.prototype.getCircleByID=function(id){for(var i=0;i<this.circles.length;i++)if(this.circles[i].id==id)return this.circles[i];return null},WPGMZA.Map.prototype.removeCircleByID=function(id){id=this.getCircleByID(id);id&&this.removeCircle(id)},WPGMZA.Map.prototype.addRectangle=function(rectangle){if(!(rectangle instanceof WPGMZA.Rectangle))throw new Error("Argument must be an instance of WPGMZA.Rectangle");(rectangle.map=this).rectangles.push(rectangle),this.dispatchEvent({type:"rectangleadded",rectangle:rectangle}),rectangle.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removeRectangle=function(rectangle){if(!(rectangle instanceof WPGMZA.Rectangle))throw new Error("Argument must be an instance of WPGMZA.Rectangle");if(rectangle.map!==this)throw new Error("Wrong map error");rectangle.map=null,this.rectangles.splice(this.rectangles.indexOf(rectangle),1),this.dispatchEvent({type:"rectangleremoved",rectangle:rectangle})},WPGMZA.Map.prototype.getRectangleByID=function(id){for(var i=0;i<this.rectangles.length;i++)if(this.rectangles[i].id==id)return this.rectangles[i];return null},WPGMZA.Map.prototype.removeRectangleByID=function(id){id=this.getRectangleByID(id);id&&this.removeRectangle(id)},WPGMZA.Map.prototype.addPointlabel=function(pointlabel){if(!(pointlabel instanceof WPGMZA.Pointlabel))throw new Error("Argument must be an instance of WPGMZA.Pointlabel");(pointlabel.map=this).pointlabels.push(pointlabel),this.dispatchEvent({type:"pointlabeladded",pointlabel:pointlabel})},WPGMZA.Map.prototype.removePointlabel=function(pointlabel){if(!(pointlabel instanceof WPGMZA.Pointlabel))throw new Error("Argument must be an instance of WPGMZA.Pointlabel");if(pointlabel.map!==this)throw new Error("Wrong map error");pointlabel.map=null,this.pointlabels.splice(this.pointlabels.indexOf(pointlabel),1),this.dispatchEvent({type:"pointlabelremoved",pointlabel:pointlabel})},WPGMZA.Map.prototype.getPointlabelByID=function(id){for(var i=0;i<this.pointlabels.length;i++)if(this.pointlabels[i].id==id)return this.pointlabels[i];return null},WPGMZA.Map.prototype.removePointlabelByID=function(id){id=this.getPointlabelByID(id);id&&this.removePointlabel(id)},WPGMZA.Map.prototype.resetBounds=function(){var latlng=new WPGMZA.LatLng(this.settings.map_start_lat,this.settings.map_start_lng);this.panTo(latlng),this.setZoom(this.settings.map_start_zoom)},WPGMZA.Map.prototype.nudge=function(x,y){x=this.nudgeLatLng(this.getCenter(),x,y);this.setCenter(x)},WPGMZA.Map.prototype.nudgeLatLng=function(latLng,x,y){latLng=this.latLngToPixels(latLng);if(latLng.x+=parseFloat(x),latLng.y+=parseFloat(y),isNaN(latLng.x)||isNaN(latLng.y))throw new Error("Invalid coordinates supplied");return this.pixelsToLatLng(latLng)},WPGMZA.Map.prototype.animateNudge=function(x,y,origin,milliseconds){if(origin){if(!(origin instanceof WPGMZA.LatLng))throw new Error("Origin must be an instance of WPGMZA.LatLng")}else origin=this.getCenter();origin=this.nudgeLatLng(origin,x,y),milliseconds=milliseconds||WPGMZA.getScrollAnimationDuration(),$(this).animate({lat:origin.lat,lng:origin.lng},milliseconds)},WPGMZA.Map.prototype.onWindowResize=function(event){},WPGMZA.Map.prototype.onElementResized=function(event){},WPGMZA.Map.prototype.onBoundsChanged=function(event){this.trigger("boundschanged"),this.trigger("bounds_changed")},WPGMZA.Map.prototype.onIdle=function(event){this.trigger("idle")},WPGMZA.Map.prototype.onClick=function(event){},WPGMZA.Map.prototype.onFullScreenChange=function(fullscreen){this.trigger("fullscreenchange.map")},WPGMZA.Map.prototype.hasVisibleMarkers=function(){for(var marker,length=this.markers.length,i=0;i<length;i++)if((marker=this.markers[i]).isFilterable&&marker.getVisible())return!0;return!1},WPGMZA.Map.prototype.isFullScreen=function(){return!(!WPGMZA.isFullScreen()||parseInt(window.screen.height)!==parseInt(this.element.offsetHeight))},WPGMZA.Map.prototype.closeAllInfoWindows=function(){this.markers.forEach(function(marker){marker.infoWindow&&marker.infoWindow.close()})},WPGMZA.Map.prototype.openStreetView=function(options){},WPGMZA.Map.prototype.closeStreetView=function(options){},$(document).ready(function(event){var invisibleMaps;WPGMZA.visibilityWorkaroundIntervalID||(invisibleMaps=jQuery(".wpgmza_map:hidden"),WPGMZA.visibilityWorkaroundIntervalID=setInterval(function(){jQuery(invisibleMaps).each(function(index,el){var id;jQuery(el).is(":visible")&&(id=jQuery(el).attr("data-map-id"),WPGMZA.getMapByID(id).onElementResized(),invisibleMaps.splice(invisibleMaps.toArray().indexOf(el),1))})},1e3))})}),jQuery(function($){WPGMZA.MapsEngineDialog=function(element){var self=this;this.element=element,window.wpgmzaUnbindSaveReminder&&window.wpgmzaUnbindSaveReminder(),$(this.element).data("installer-link")?WPGMZA.initInstallerRedirect($(this.element).data("installer-link")):($(element).remodal().open(),$(element).show(),$(element).find("input:radio").on("change",function(event){$("#wpgmza-confirm-engine").prop("disabled",!1),$("#wpgmza-confirm-engine").click()}),$("#wpgmza-confirm-engine").on("click",function(event){self.onButtonClicked(event)}))},WPGMZA.MapsEngineDialog.prototype.onButtonClicked=function(event){$(event.target).prop("disabled",!0),$.ajax(WPGMZA.ajaxurl,{method:"POST",data:{action:"wpgmza_maps_engine_dialog_set_engine",engine:$("[name='wpgmza_maps_engine']:checked").val(),nonce:$("#wpgmza-maps-engine-dialog").attr("data-ajax-nonce")},success:function(response,status,xhr){window.location.reload()}})},$(document).ready(function(event){var element=$("#wpgmza-maps-engine-dialog");!element.length||WPGMZA.settings.wpgmza_maps_engine_dialog_done||WPGMZA.settings.wpgmza_google_maps_api_key&&WPGMZA.settings.wpgmza_google_maps_api_key.length||(WPGMZA.mapsEngineDialog=new WPGMZA.MapsEngineDialog(element))})}),jQuery(function($){WPGMZA.MarkerFilter=function(map){WPGMZA.EventDispatcher.call(this),this.map=map},WPGMZA.MarkerFilter.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.MarkerFilter.prototype.constructor=WPGMZA.MarkerFilter,WPGMZA.MarkerFilter.createInstance=function(map){return new WPGMZA.MarkerFilter(map)},WPGMZA.MarkerFilter.prototype.getFilteringParameters=function(){var params={map_id:this.map.id};return params=this.map.storeLocator?$.extend(params,this.map.storeLocator.getFilteringParameters()):params},WPGMZA.MarkerFilter.prototype.update=function(params,source){var self=this;function dispatchEvent(result){var event=new WPGMZA.Event("filteringcomplete");event.map=self.map,event.source=source,event.filteredMarkers=result,event.filteringParams=params,self.onFilteringComplete(event),self.trigger(event),self.map.trigger(event)}this.updateTimeoutID||(params=params||{},this.xhr&&(this.xhr.abort(),delete this.xhr),this.updateTimeoutID=setTimeout(function(){if((params=$.extend(self.getFilteringParameters(),params)).center instanceof WPGMZA.LatLng&&(params.center=params.center.toLatLngLiteral()),params.hideAll)return dispatchEvent([]),void delete self.updateTimeoutID;self.map.showPreloader(!0),self.xhr=WPGMZA.restAPI.call("/markers",{data:{fields:["id"],filter:JSON.stringify(params)},success:function(result,status,xhr){self.map.showPreloader(!1),dispatchEvent(result)},useCompressedPathVariable:!0}),delete self.updateTimeoutID},0))},WPGMZA.MarkerFilter.prototype.onFilteringComplete=function(event){var map=[];event.filteredMarkers.forEach(function(data){map[data.id]=!0}),this.map.markers.forEach(function(marker){var allowByFilter;marker.isFilterable&&(allowByFilter=!!map[marker.id],marker.isFiltered=!allowByFilter,marker.setVisible(allowByFilter))})}}),jQuery(function($){WPGMZA.Marker=function(row){var self=this;this._offset={x:0,y:0},WPGMZA.assertInstanceOf(this,"Marker"),this.lat="36.778261",this.lng="-119.4179323999",this.address="California",this.title=null,this.description="",this.link="",this.icon="",this.approved=1,this.pic=null,this.isFilterable=!0,this.disableInfoWindow=!1,WPGMZA.Feature.apply(this,arguments),row&&row.heatmap||(row&&this.on("init",function(event){row.position&&this.setPosition(row.position),row.map&&row.map.addMarker(this)}),this.addEventListener("added",function(event){self.onAdded(event)}),this.handleLegacyGlobals(row))},WPGMZA.Marker.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Marker.prototype.constructor=WPGMZA.Marker,WPGMZA.Marker.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProMarker:WPGMZA.GoogleMarker:WPGMZA.isProVersion()?WPGMZA.OLProMarker:WPGMZA.OLMarker},WPGMZA.Marker.createInstance=function(row){return new(WPGMZA.Marker.getConstructor())(row)},WPGMZA.Marker.ANIMATION_NONE="0",WPGMZA.Marker.ANIMATION_BOUNCE="1",WPGMZA.Marker.ANIMATION_DROP="2",Object.defineProperty(WPGMZA.Marker.prototype,"offsetX",{get:function(){return this._offset.x},set:function(value){this._offset.x=value,this.updateOffset()}}),Object.defineProperty(WPGMZA.Marker.prototype,"offsetY",{get:function(){return this._offset.y},set:function(value){this._offset.y=value,this.updateOffset()}}),WPGMZA.Marker.prototype.onAdded=function(event){var self=this;this.addEventListener("click",function(event){self.onClick(event)}),this.addEventListener("mouseover",function(event){self.onMouseOver(event)}),this.addEventListener("select",function(event){self.onSelect(event)}),this.map.settings.marker==this.id&&self.trigger("select"),"1"==this.infoopen&&(this._osDisableAutoPan=!0,this.openInfoWindow(!0))},WPGMZA.Marker.prototype.handleLegacyGlobals=function(row){var m;WPGMZA.settings.useLegacyGlobals&&this.map_id&&this.id&&(WPGMZA.pro_version&&(m=WPGMZA.pro_version.match(/\d+/))&&m[0]<=7||(WPGMZA.legacyGlobals.marker_array[this.map_id]||(WPGMZA.legacyGlobals.marker_array[this.map_id]=[]),WPGMZA.legacyGlobals.marker_array[this.map_id][this.id]=this,WPGMZA.legacyGlobals.wpgmaps_localize_marker_data[this.map_id]||(WPGMZA.legacyGlobals.wpgmaps_localize_marker_data[this.map_id]=[]),m=$.extend({marker_id:this.id},row),WPGMZA.legacyGlobals.wpgmaps_localize_marker_data[this.map_id][this.id]=m))},WPGMZA.Marker.prototype.initInfoWindow=function(){this.infoWindow||(this.infoWindow=WPGMZA.InfoWindow.createInstance())},WPGMZA.Marker.prototype.openInfoWindow=function(autoOpen){this.map?(autoOpen||(this.map.lastInteractedMarker&&this.map.lastInteractedMarker.infoWindow.close(),this.map.lastInteractedMarker=this),this.initInfoWindow(),this.infoWindow.open(this.map,this)):console.warn("Cannot open infowindow for marker with no map")},WPGMZA.Marker.prototype.onClick=function(event){},WPGMZA.Marker.prototype.onSelect=function(event){this.openInfoWindow()},WPGMZA.Marker.prototype.onMouseOver=function(event){WPGMZA.settings.wpgmza_settings_map_open_marker_by==WPGMZA.InfoWindow.OPEN_BY_HOVER&&this.openInfoWindow()},WPGMZA.Marker.prototype.getIcon=function(){function stripProtocol(url){return"string"!=typeof url?url:url.replace(/^http(s?):/,"")}return WPGMZA.defaultMarkerIcon?stripProtocol(WPGMZA.defaultMarkerIcon):stripProtocol(WPGMZA.settings.default_marker_icon)},WPGMZA.Marker.prototype.getPosition=function(){return new WPGMZA.LatLng({lat:parseFloat(this.lat),lng:parseFloat(this.lng)})},WPGMZA.Marker.prototype.setPosition=function(latLng){latLng instanceof WPGMZA.LatLng?(this.lat=latLng.lat,this.lng=latLng.lng):(this.lat=parseFloat(latLng.lat),this.lng=parseFloat(latLng.lng))},WPGMZA.Marker.prototype.setOffset=function(x,y){this._offset.x=x,this._offset.y=y,this.updateOffset()},WPGMZA.Marker.prototype.updateOffset=function(){},WPGMZA.Marker.prototype.getAnimation=function(){return this.anim},WPGMZA.Marker.prototype.setAnimation=function(animation){},WPGMZA.Marker.prototype.getVisible=function(){},WPGMZA.Marker.prototype.setVisible=function(visible){!visible&&this.infoWindow&&this.infoWindow.close()},WPGMZA.Marker.prototype.getMap=function(){return this.map},WPGMZA.Marker.prototype.setMap=function(map){map?map.addMarker(this):this.map&&this.map.removeMarker(this),this.map=map},WPGMZA.Marker.prototype.getDraggable=function(){},WPGMZA.Marker.prototype.setDraggable=function(draggable){},WPGMZA.Marker.prototype.setOptions=function(options){},WPGMZA.Marker.prototype.setOpacity=function(opacity){},WPGMZA.Marker.prototype.panIntoView=function(){if(!this.map)throw new Error("Marker hasn't been added to a map");this.map.setCenter(this.getPosition())},WPGMZA.Marker.prototype.toJSON=function(){var result=WPGMZA.Feature.prototype.toJSON.call(this),position=this.getPosition();return $.extend(result,{lat:position.lat,lng:position.lng,address:this.address,title:this.title,description:this.description,link:this.link,icon:this.icon,pic:this.pic,approved:this.approved}),result}}),jQuery(function($){WPGMZA.ModernStoreLocatorCircle=function(map_id,settings){var map=WPGMZA.isProVersion()?this.map=WPGMZA.getMapByID(map_id):this.map=WPGMZA.maps[0];this.map_id=map_id,this.mapElement=map.element,this.mapSize={width:$(this.mapElement).width(),height:$(this.mapElement).height()},this.initCanvasLayer(),this.settings={center:new WPGMZA.LatLng(0,0),radius:1,color:"#ff0000",shadowColor:"white",shadowBlur:4,centerRingRadius:10,centerRingLineWidth:3,numInnerRings:9,innerRingLineWidth:1,innerRingFade:!0,numOuterRings:7,ringLineWidth:1,mainRingLineWidth:2,numSpokes:6,spokesStartAngle:Math.PI/2,numRadiusLabels:6,radiusLabelsStartAngle:Math.PI/2,radiusLabelFont:"13px sans-serif",visible:!1},settings&&this.setOptions(settings)},WPGMZA.ModernStoreLocatorCircle.createInstance=function(map,settings){return new("google-maps"==WPGMZA.settings.engine?WPGMZA.GoogleModernStoreLocatorCircle:WPGMZA.OLModernStoreLocatorCircle)(map,settings)},WPGMZA.ModernStoreLocatorCircle.prototype.initCanvasLayer=function(){},WPGMZA.ModernStoreLocatorCircle.prototype.onResize=function(event){this.draw()},WPGMZA.ModernStoreLocatorCircle.prototype.onUpdate=function(event){this.draw()},WPGMZA.ModernStoreLocatorCircle.prototype.setOptions=function(options){for(var name in options){var functionName="set"+name.substr(0,1).toUpperCase()+name.substr(1);"function"==typeof this[functionName]?this[functionName](options[name]):this.settings[name]=options[name]}},WPGMZA.ModernStoreLocatorCircle.prototype.getResolutionScale=function(){return window.devicePixelRatio||1},WPGMZA.ModernStoreLocatorCircle.prototype.getCenter=function(){return this.getPosition()},WPGMZA.ModernStoreLocatorCircle.prototype.setCenter=function(value){this.setPosition(value)},WPGMZA.ModernStoreLocatorCircle.prototype.getPosition=function(){return this.settings.center},WPGMZA.ModernStoreLocatorCircle.prototype.setPosition=function(position){this.settings.center=position},WPGMZA.ModernStoreLocatorCircle.prototype.getRadius=function(){return this.settings.radius},WPGMZA.ModernStoreLocatorCircle.prototype.setRadius=function(radius){if(isNaN(radius))throw new Error("Invalid radius");this.settings.radius=radius},WPGMZA.ModernStoreLocatorCircle.prototype.getVisible=function(){return this.settings.visible},WPGMZA.ModernStoreLocatorCircle.prototype.setVisible=function(visible){this.settings.visible=visible},WPGMZA.ModernStoreLocatorCircle.prototype.getTransformedRadius=function(km){throw new Error("Abstract function called")},WPGMZA.ModernStoreLocatorCircle.prototype.getContext=function(type){throw new Error("Abstract function called")},WPGMZA.ModernStoreLocatorCircle.prototype.getCanvasDimensions=function(){throw new Error("Abstract function called")},WPGMZA.ModernStoreLocatorCircle.prototype.validateSettings=function(){WPGMZA.isHexColorString(this.settings.color)||(this.settings.color="#ff0000")},WPGMZA.ModernStoreLocatorCircle.prototype.draw=function(){this.validateSettings();var settings=this.settings,canvasDimensions=this.getCanvasDimensions(),canvasWidth=canvasDimensions.width,canvasDimensions=canvasDimensions.height;this.map,this.getResolutionScale();if((context=this.getContext("2d")).clearRect(0,0,canvasWidth,canvasDimensions),settings.visible){context.shadowColor=settings.shadowColor,context.shadowBlur=settings.shadowBlur,context.setTransform(1,0,0,1,0,0);var end,scale=this.getScale(),canvasWidth=(context.scale(scale,scale),this.getWorldOriginOffset()),worldPoint=(context.translate(canvasWidth.x,canvasWidth.y),new WPGMZA.LatLng(this.settings.center),this.getCenterPixels()),rgba=WPGMZA.hexToRgba(settings.color),ringSpacing=this.getTransformedRadius(settings.radius)/(settings.numInnerRings+1),radius=(context.strokeStyle=settings.color,context.lineWidth=1/scale*settings.centerRingLineWidth,context.beginPath(),context.arc(worldPoint.x,worldPoint.y,this.getTransformedRadius(settings.centerRingRadius)/scale,0,2*Math.PI),context.stroke(),context.closePath(),this.getTransformedRadius(settings.radius)+ringSpacing*settings.numOuterRings+1),canvasDimensions=context.createRadialGradient(0,0,0,0,0,radius),rgba=WPGMZA.hexToRgba(settings.color),canvasWidth=WPGMZA.rgbaToString(rgba);rgba.a=0,end=WPGMZA.rgbaToString(rgba),canvasDimensions.addColorStop(0,canvasWidth),canvasDimensions.addColorStop(1,end),context.save(),context.translate(worldPoint.x,worldPoint.y),context.strokeStyle=canvasDimensions,context.lineWidth=2/scale;for(var i=0;i<settings.numSpokes;i++)spokeAngle=settings.spokesStartAngle+2*Math.PI*(i/settings.numSpokes),x=Math.cos(spokeAngle)*radius,y=Math.sin(spokeAngle)*radius,context.setLineDash([2/scale,15/scale]),context.beginPath(),context.moveTo(0,0),context.lineTo(x,y),context.stroke();context.setLineDash([]),context.restore(),context.lineWidth=1/scale*settings.innerRingLineWidth;for(i=1;i<=settings.numInnerRings;i++){radius=i*ringSpacing;settings.innerRingFade&&(rgba.a=1-(i-1)/settings.numInnerRings),context.strokeStyle=WPGMZA.rgbaToString(rgba),context.beginPath(),context.arc(worldPoint.x,worldPoint.y,radius,0,2*Math.PI),context.stroke(),context.closePath()}context.strokeStyle=settings.color,context.lineWidth=1/scale*settings.centerRingLineWidth,context.beginPath(),context.arc(worldPoint.x,worldPoint.y,this.getTransformedRadius(settings.radius),0,2*Math.PI),context.stroke(),context.closePath();for(radius=radius+ringSpacing,i=0;i<settings.numOuterRings;i++)settings.innerRingFade&&(rgba.a=1-i/settings.numOuterRings),context.strokeStyle=WPGMZA.rgbaToString(rgba),context.beginPath(),context.arc(worldPoint.x,worldPoint.y,radius,0,2*Math.PI),context.stroke(),context.closePath(),radius+=ringSpacing;if(0<settings.numRadiusLabels){var x,y,radius=this.getTransformedRadius(settings.radius);(canvasWidth=settings.radiusLabelFont.match(/(\d+)px/))&&parseInt(canvasWidth[1]),context.font=settings.radiusLabelFont,context.textAlign="center",context.textBaseline="middle",context.fillStyle=settings.color,context.save(),context.translate(worldPoint.x,worldPoint.y);for(i=0;i<settings.numRadiusLabels;i++){var spokeAngle,textAngle=(spokeAngle=settings.radiusLabelsStartAngle+2*Math.PI*(i/settings.numRadiusLabels))+Math.PI/2,text=settings.radiusString;0<Math.sin(spokeAngle)&&(textAngle-=Math.PI),x=Math.cos(spokeAngle)*radius,y=Math.sin(spokeAngle)*radius,context.save(),context.translate(x,y),context.rotate(textAngle),context.scale(1/scale,1/scale),textAngle=context.measureText(text).width,height=textAngle/2,context.clearRect(-textAngle,-height,2*textAngle,2*height),context.fillText(settings.radiusString,0,0),context.restore()}context.restore()}}}}),jQuery(function($){WPGMZA.ModernStoreLocator=function(map_id){var original,inner,addressInput,placeholder,container,titleSearch,numCategories,icons,self=this,map=WPGMZA.getMapByID(map_id);WPGMZA.assertInstanceOf(this,"ModernStoreLocator"),(original=(WPGMZA.isProVersion()?$(".wpgmza_sl_search_button[mid='"+map_id+"'], .wpgmza_sl_search_button_"+map_id):$(".wpgmza_sl_search_button")).closest(".wpgmza_sl_main_div")).length&&(this.element=$("<div class='wpgmza-modern-store-locator'><div class='wpgmza-inner wpgmza-modern-hover-opaque'/></div>")[0],inner=$(this.element).find(".wpgmza-inner"),addressInput=WPGMZA.isProVersion()?$(original).find(".addressInput"):$(original).find("#addressInput"),map.settings.store_locator_query_string&&map.settings.store_locator_query_string.length&&addressInput.attr("placeholder",map.settings.store_locator_query_string),inner.append(addressInput),(titleSearch=$(original).find("[id='nameInput_"+map_id+"']")).length&&((placeholder=map.settings.store_locator_name_string)&&placeholder.length&&titleSearch.attr("placeholder",placeholder),inner.append(titleSearch)),(placeholder=$(original).find("button.wpgmza-use-my-location"))&&inner.append(placeholder),$(addressInput).on("keydown keypress",function(event){13==event.keyCode&&self.searchButton.is(":visible")&&self.searchButton.trigger("click")}),$(addressInput).on("input",function(event){self.searchButton.show(),self.resetButton.hide()}),inner.append($(original).find("select.wpgmza_sl_radius_select")),this.searchButton=$(original).find(".wpgmza_sl_search_button, .wpgmza_sl_search_button_div"),inner.append(this.searchButton),this.resetButton=$(original).find(".wpgmza_sl_reset_button_div"),inner.append(this.resetButton),this.resetButton.on("click",function(event){resetLocations(map_id)}),this.resetButton.hide(),WPGMZA.isProVersion()&&(this.searchButton.on("click",function(event){0!=$("addressInput_"+map_id).val()&&(self.searchButton.hide(),self.resetButton.show(),map.storeLocator.state=WPGMZA.StoreLocator.STATE_APPLIED)}),this.resetButton.on("click",function(event){self.resetButton.hide(),self.searchButton.show(),map.storeLocator.state=WPGMZA.StoreLocator.STATE_INITIAL})),inner.append($("#wpgmza_distance_type_"+map_id)),container=$(original).find(".wpgmza_cat_checkbox_holder"),$(container).children("ul"),titleSearch=$(container).find("li"),numCategories=0,icons=[],titleSearch.each(function(index,el){var category_id,id=$(el).attr("class").match(/\d+/);for(category_id in wpgmza_category_data)if(id==category_id){var src=wpgmza_category_data[category_id].image,icon=$('<div class="wpgmza-chip-icon"/>');icon.css({"background-image":"url('"+src+"')",width:$("#wpgmza_cat_checkbox_"+category_id+" + label").height()+"px"}),icons.push(icon),null!=src&&""!=src&&$("#wpgmza_cat_checkbox_"+category_id+" + label").prepend(icon),numCategories++;break}}),$(this.element).append(container),numCategories&&(this.optionsButton=$('<span class="wpgmza_store_locator_options_button"><i class="fa fa-list"></i></span>'),$(this.searchButton).before(this.optionsButton)),setInterval(function(){icons.forEach(function(icon){var height=$(icon).height();$(icon).css({width:height+"px"}),$(icon).closest("label").css({"padding-left":height+8+"px"})}),$(container).css("width",$(self.element).find(".wpgmza-inner").outerWidth()+"px")},1e3),$(this.element).find(".wpgmza_store_locator_options_button").on("click",function(event){container.hasClass("wpgmza-open")?container.removeClass("wpgmza-open"):container.addClass("wpgmza-open")}),$(original).remove(),$(this.element).find("input, select").on("focus",function(){$(inner).addClass("active")}),$(this.element).find("input, select").on("blur",function(){$(inner).removeClass("active")}),$(this.element).on("mouseover","li.wpgmza_cat_checkbox_item_holder",function(event){self.onMouseOverCategory(event)}),$(this.element).on("mouseleave","li.wpgmza_cat_checkbox_item_holder",function(event){self.onMouseLeaveCategory(event)}),$("body").on("click",".wpgmza_store_locator_options_button",function(event){setTimeout(function(){var p_cat,$p_map;$(".wpgmza_cat_checkbox_holder").hasClass("wpgmza-open")&&(p_cat=(p_cat=$(".wpgmza_cat_checkbox_holder")).position().top+p_cat.outerHeight(!0)+$(".wpgmza-modern-store-locator").height(),($p_map=$(".wpgmza_map")).position().top+$p_map.outerHeight(!0)<=p_cat&&($(".wpgmza_cat_ul").css("overflow","scroll "),$(".wpgmza_cat_ul").css("height","100%"),$(".wpgmza-modern-store-locator").css("height","100%"),$(".wpgmza_cat_checkbox_holder.wpgmza-open").css({"padding-bottom":"50px",height:"100%"})))},500)}))},WPGMZA.ModernStoreLocator.createInstance=function(map_id){return new("open-layers"!==WPGMZA.settings.engine?WPGMZA.GoogleModernStoreLocator:WPGMZA.OLModernStoreLocator)(map_id)},WPGMZA.ModernStoreLocator.prototype.onMouseOverCategory=function(event){event=event.currentTarget;$(event).children("ul.wpgmza_cat_checkbox_item_holder").stop(!0,!1).fadeIn()},WPGMZA.ModernStoreLocator.prototype.onMouseLeaveCategory=function(event){event=event.currentTarget;$(event).children("ul.wpgmza_cat_checkbox_item_holder").stop(!0,!1).fadeOut()}}),jQuery(function($){WPGMZA.NativeMapsAppIcon=function(){navigator.userAgent.match(/^Apple|iPhone|iPad|iPod/)?(this.type="apple",this.element=$('<span><i class="fab fa fa-apple" aria-hidden="true"></i></span>')):(this.type="google",this.element=$('<span><i class="fab fa fa-google" aria-hidden="true"></i></span>'))}}),jQuery(function($){WPGMZA.PersistentAdminNotice=function(element,options){if(!(element instanceof HTMLElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dismissButton=this.element.find(".notice-dismiss"),this.ajaxActionButton=this.element.find("a[data-ajax]"),this.bindEvents()},WPGMZA.extend(WPGMZA.PersistentAdminNotice,WPGMZA.EventDispatcher),WPGMZA.PersistentAdminNotice.createInstance=function(element){return new WPGMZA.PersistentAdminNotice(element)},WPGMZA.PersistentAdminNotice.prototype.bindEvents=function(){let self=this;this.dismissButton.on("click",function(event){self.onDismiss($(this))}),this.ajaxActionButton.on("click",function(event){event.preventDefault(),self.onAjaxAction($(this))})},WPGMZA.PersistentAdminNotice.prototype.onDismiss=function(item){var data={action:"wpgmza_dismiss_persistent_notice",slug:this.element.data("slug"),wpgmza_security:WPGMZA.ajaxnonce};$.ajax(WPGMZA.ajaxurl,{method:"POST",data:data,success:function(response,status,xhr){},error:function(){}})},WPGMZA.PersistentAdminNotice.prototype.onAjaxAction=function(item){var action;item.data("disabled")||(action=item.data("ajax-action"),item.attr("data-disabled","true"),item.css("opacity","0.5"),action&&(item={action:"wpgmza_persisten_notice_quick_action",relay:action,wpgmza_security:WPGMZA.ajaxnonce},$.ajax(WPGMZA.ajaxurl,{method:"POST",data:item,success:function(response){window.location.reload()},error:function(){}})))},$(document.body).ready(function(){$(".wpgmza-persistent-notice").each(function(index,el){el.wpgmzaPersistentAdminNotice=WPGMZA.PersistentAdminNotice.createInstance(el)})})}),jQuery(function($){WPGMZA.Pointlabel=function(options,pointlabel){var map;WPGMZA.assertInstanceOf(this,"Pointlabel"),(options=options||{}).map?this.map=options.map:!options.map&&options.map_id&&(map=WPGMZA.getMapByID(options.map_id))&&(this.map=map),this.center=new WPGMZA.LatLng,WPGMZA.Feature.apply(this,arguments),pointlabel&&(this.setPosition(pointlabel.getPosition()),pointlabel.marker&&(this.marker=pointlabel.marker))},WPGMZA.Pointlabel.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Pointlabel.prototype.constructor=WPGMZA.Pointlabel,Object.defineProperty(WPGMZA.Pointlabel.prototype,"map",{enumerable:!0,get:function(){return this._map||null},set:function(a){this.textFeature&&!a&&this.textFeature.remove(),this._map=a}}),WPGMZA.Pointlabel.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProPointlabel:WPGMZA.GooglePointlabel:WPGMZA.isProVersion()?WPGMZA.OLProPointlabel:WPGMZA.OLPointlabel},WPGMZA.Pointlabel.createInstance=function(options,pointlabel){return new(WPGMZA.Pointlabel.getConstructor())(options,pointlabel)},WPGMZA.Pointlabel.createEditableMarker=function(options){function callback(){try{marker.setIcon(WPGMZA.labelpointIcon)}catch(ex){}marker.off("added",callback)}(options=$.extend({draggable:!0,disableInfoWindow:!0},options)).pointlabel&&(latLng=options.pointlabel.getPosition(),options.lat=latLng.lat,options.lng=latLng.lng);var latLng,marker=WPGMZA.Marker.createInstance(options);return marker.on("added",callback),marker},WPGMZA.Pointlabel.prototype.setEditable=function(editable){var self=this;this.marker&&(this.marker.map.removeMarker(this.marker),delete this.marker),this._prevMap&&delete this._prevMap,editable&&(this.marker=WPGMZA.Pointlabel.createEditableMarker({pointlabel:this}),this.map.addMarker(this.marker),this._dragEndCallback=function(event){self.onDragEnd(event)},editable=this.map,this.marker.on("dragend",this._dragEndCallback),editable.on("pointlabelremoved",function(event){event.pointlabel}))},WPGMZA.Pointlabel.prototype.onDragEnd=function(event){event.target instanceof WPGMZA.Marker&&this.marker&&(event.latLng&&this.setPosition(event.latLng),this.trigger("change"))},WPGMZA.Pointlabel.prototype.onMapMouseDown=function(event){if(0==event.button)return this._mouseDown=!0,event.preventDefault(),!1},WPGMZA.Pointlabel.prototype.onWindowMouseUp=function(event){0==event.button&&(this._mouseDown=!1)},WPGMZA.Pointlabel.prototype.onMapMouseMove=function(event){this._mouseDown&&(event={x:event.pageX-$(this.map.element).offset().left,y:event.pageY+30-$(this.map.element).offset().top},(event=this.map.pixelsToLatLng(event))&&this.setPosition(event),this.trigger("change"))},WPGMZA.Pointlabel.prototype.getPosition=function(){return this.center?new WPGMZA.LatLng({lat:this.center.lat,lng:this.center.lng}):null},WPGMZA.Pointlabel.prototype.setPosition=function(position){this.center={},this.center.lat=position.lat,this.center.lng=position.lng,this.textFeature&&this.textFeature.setPosition(this.getPosition())},WPGMZA.Pointlabel.prototype.getMap=function(){return this.map},WPGMZA.Pointlabel.prototype.setMap=function(map){this.map&&this.map.removePointlabel(this),map&&map.addPointlabel(this)}}),jQuery(function($){Uint8Array.prototype.slice||Object.defineProperty(Uint8Array.prototype,"slice",{value:function(begin,end){return new Uint8Array(Array.prototype.slice.call(this,begin,end))}}),WPGMZA.isSafari()&&!window.external&&(window.external={})}),jQuery(function($){WPGMZA.Polygon=function(row,enginePolygon){var self=this;WPGMZA.assertInstanceOf(this,"Polygon"),this.paths=null,WPGMZA.Feature.apply(this,arguments),this.addEventListener("added",function(event){self.onAdded()})},WPGMZA.Polygon.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Polygon.prototype.constructor=WPGMZA.Polygon,Object.defineProperty(WPGMZA.Polygon.prototype,"fillColor",{enumerable:!0,get:function(){return this.fillcolor&&this.fillcolor.length?"#"+this.fillcolor.replace(/^#/,""):"#ff0000"},set:function(a){this.fillcolor=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"fillOpacity",{enumerable:!0,get:function(){return this.opacity&&this.opacity.length?this.opacity:.6},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"strokeColor",{enumerable:!0,get:function(){return this.linecolor&&this.linecolor.length?"#"+this.linecolor.replace(/^#/,""):"#ff0000"},set:function(a){this.linecolor=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.lineopacity&&this.lineopacity.length?this.lineopacity:.6},set:function(a){this.lineopacity=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"strokeWeight",{enumerable:!0,get:function(){return this.linethickness&&this.linethickness.length?parseInt(this.linethickness):3}}),WPGMZA.Polygon.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProPolygon:WPGMZA.GooglePolygon:WPGMZA.isProVersion()?WPGMZA.OLProPolygon:WPGMZA.OLPolygon},WPGMZA.Polygon.createInstance=function(row,engineObject){return new(WPGMZA.Polygon.getConstructor())(row,engineObject)},WPGMZA.Polygon.prototype.onAdded=function(){}}),jQuery(function($){WPGMZA.Polyline=function(options,googlePolyline){var self=this;WPGMZA.assertInstanceOf(this,"Polyline"),WPGMZA.Feature.apply(this,arguments),this.addEventListener("added",function(event){self.onAdded()})},WPGMZA.Polyline.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Polyline.prototype.constructor=WPGMZA.Polyline,Object.defineProperty(WPGMZA.Polyline.prototype,"strokeColor",{enumerable:!0,get:function(){return this.linecolor&&this.linecolor.length?"#"+this.linecolor.replace(/^#/,""):"#ff0000"},set:function(a){this.linecolor=a}}),Object.defineProperty(WPGMZA.Polyline.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.opacity&&this.opacity.length?this.opacity:.6},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Polyline.prototype,"strokeWeight",{enumerable:!0,get:function(){return this.linethickness&&this.linethickness.length?parseInt(this.linethickness):1},set:function(a){this.linethickness=a}}),Object.defineProperty(WPGMZA.Polyline.prototype,"layergroup",{enumerable:!0,get:function(){return this._layergroup||0},set:function(value){parseInt(value)&&(this._layergroup=parseInt(value)+WPGMZA.Shape.BASE_LAYER_INDEX)}}),WPGMZA.Polyline.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.GooglePolyline:WPGMZA.OLPolyline},WPGMZA.Polyline.createInstance=function(options,engineObject){return new(WPGMZA.Polyline.getConstructor())(options,engineObject)},WPGMZA.Polyline.prototype.getPoints=function(){return this.toJSON().points},WPGMZA.Polyline.prototype.onAdded=function(){this.layergroup&&this.setLayergroup(this.layergroup)},WPGMZA.Polyline.prototype.toJSON=function(){var result=WPGMZA.Feature.prototype.toJSON.call(this);return result.title=this.title,result},WPGMZA.Polyline.prototype.setLayergroup=function(layergroup){this.layergroup=layergroup,this.layergroup&&this.setOptions({zIndex:this.layergroup})}}),jQuery(function($){WPGMZA.PopoutPanel=function(element){this.element=element},WPGMZA.PopoutPanel.prototype.open=function(){$(this.element).addClass("wpgmza-open")},WPGMZA.PopoutPanel.prototype.close=function(){$(this.element).removeClass("wpgmza-open")}}),jQuery(function($){function sendAJAXFallbackRequest(route,params){if((params=$.extend({},params)).data||(params.data={}),"route"in params.data)throw new Error("Cannot send route through this method");if("action"in params.data)throw new Error("Cannot send action through this method");return params.data.route=route,params.data.action="wpgmza_rest_api_request",WPGMZA.restAPI.addNonce(route,params,WPGMZA.RestAPI.CONTEXT_AJAX),$.ajax(WPGMZA.ajaxurl,params)}WPGMZA.RestAPI=function(){WPGMZA.RestAPI.URL=WPGMZA.resturl,this.useAJAXFallback=!1,$(document.body).trigger("init.restapi.wpgmza")},WPGMZA.RestAPI.CONTEXT_REST="REST",WPGMZA.RestAPI.CONTEXT_AJAX="AJAX",WPGMZA.RestAPI.createInstance=function(){return new WPGMZA.RestAPI},Object.defineProperty(WPGMZA.RestAPI.prototype,"isCompressedPathVariableSupported",{get:function(){return WPGMZA.serverCanInflate&&"Uint8Array"in window&&"TextEncoder"in window}}),Object.defineProperty(WPGMZA.RestAPI.prototype,"isCompressedPathVariableAllowed",{get:function(){return!WPGMZA.pro_version||WPGMZA.Version.compare(WPGMZA.pro_version,"8.0.0")>=WPGMZA.Version.EQUAL_TO?!WPGMZA.settings.disable_compressed_path_variables:WPGMZA.settings.enable_compressed_path_variables}}),Object.defineProperty(WPGMZA.RestAPI.prototype,"maxURLLength",{get:function(){return 2083}}),WPGMZA.RestAPI.prototype.compressParams=function(params){var suffix="",string=(!params.markerIDs||1<(markerIDs=params.markerIDs.split(",")).length&&(markerIDs=(new WPGMZA.EliasFano).encode(markerIDs),compressed=pako.deflate(markerIDs),string=Array.prototype.map.call(compressed,function(ch){return String.fromCharCode(ch)}).join(""),suffix="/"+btoa(string).replace(/\//g,"-").replace(/=+$/,""),params.midcbp=markerIDs.pointer,delete params.markerIDs),JSON.stringify(params)),markerIDs=(new TextEncoder).encode(string),compressed=pako.deflate(markerIDs),params=Array.prototype.map.call(compressed,function(ch){return String.fromCharCode(ch)}).join("");return btoa(params).replace(/\//g,"-").replace(/=+$/,"")+suffix},WPGMZA.RestAPI.prototype.getNonce=function(route){var pattern,matches=[];for(pattern in WPGMZA.restnoncetable){var regex=new RegExp(pattern);route.match(regex)&&matches.push({pattern:pattern,nonce:WPGMZA.restnoncetable[pattern],length:pattern.length})}if(matches.length)return matches.sort(function(a,b){return b.length-a.length}),matches[0].nonce;throw new Error("No nonce found for route")},WPGMZA.RestAPI.prototype.addNonce=function(route,params,context){function setRESTNonce(xhr){context==WPGMZA.RestAPI.CONTEXT_REST&&self.shouldAddNonce(route)&&xhr.setRequestHeader("X-WP-Nonce",WPGMZA.restnonce),params&&params.method&&!params.method.match(/^GET$/i)&&xhr.setRequestHeader("X-WPGMZA-Action-Nonce",self.getNonce(route))}var base,self=this;params.beforeSend?(base=params.beforeSend,params.beforeSend=function(xhr){base(xhr),setRESTNonce(xhr)}):params.beforeSend=setRESTNonce},WPGMZA.RestAPI.prototype.shouldAddNonce=function(route){route=route.replace(/\//g,"");var isAdmin=!1;WPGMZA.is_admin&&1===parseInt(WPGMZA.is_admin)&&(isAdmin=!0);return!(route&&["markers","features","marker-listing","datatables"].includes(route)&&!isAdmin)},WPGMZA.RestAPI.prototype.call=function(route,params){if(this.useAJAXFallback)return sendAJAXFallbackRequest(route,params);var compressedParams,data,attemptedCompressedPathVariable=!1,fallbackRoute=route,fallbackParams=$.extend({},params);if("string"!=typeof route||!route.match(/^\//)&&!route.match(/^http/))throw new Error("Invalid route");WPGMZA.RestAPI.URL.match(/\/$/)&&(route=route.replace(/^\//,"")),params=params||{},this.addNonce(route,params,WPGMZA.RestAPI.CONTEXT_REST),params.error||(params.error=function(xhr,status,message){if("abort"!=status){switch(xhr.status){case 401:case 403:case 405:return($.post(WPGMZA.ajaxurl,{action:"wpgmza_report_rest_api_blocked"},function(response){}),console.warn("The REST API was blocked. This is usually due to security plugins blocking REST requests for non-authenticated users."),"DELETE"===params.method)?(console.warn("The REST API rejected a DELETE request, attempting again with POST fallback"),params.method="POST",params.data||(params.data={}),params.data.simulateDelete="yes",WPGMZA.restAPI.call(route,params)):(this.useAJAXFallback=!0,sendAJAXFallbackRequest(fallbackRoute,fallbackParams));case 414:if(attemptedCompressedPathVariable)return fallbackParams.method="POST",fallbackParams.useCompressedPathVariable=!1,WPGMZA.restAPI.call(fallbackRoute,fallbackParams)}throw new Error(message)}}),params.useCompressedPathVariable&&this.isCompressedPathVariableSupported&&this.isCompressedPathVariableAllowed&&(compressedParams=$.extend({},params),data=params.data,data=this.compressParams(data),WPGMZA.isServerIIS&&(data=data.replace(/\+/g,"%20")),data=route.replace(/\/$/,"")+"/base64"+data,WPGMZA.RestAPI.URL,compressedParams.method="GET",delete compressedParams.data,!1===params.cache&&(compressedParams.data={skip_cache:1}),data.length<this.maxURLLength?(attemptedCompressedPathVariable=!0,route=data,params=compressedParams):(WPGMZA.RestAPI.compressedPathVariableURLLimitWarningDisplayed||console.warn("Compressed path variable route would exceed URL length limit"),WPGMZA.RestAPI.compressedPathVariableURLLimitWarningDisplayed=!0));var onSuccess=null;return params.success&&(onSuccess=params.success),params.success=function(result,status,xhr){if("object"!=typeof result){var rawResult=result;try{result=JSON.parse(result)}catch(parseExc){result=rawResult}}onSuccess&&"function"==typeof onSuccess&&onSuccess(result,status,xhr)},WPGMZA.RestAPI.URL.match(/\?/)&&(route=route.replace(/\?/,"&")),$.ajax(WPGMZA.RestAPI.URL+route,params)};var nativeCallFunction=WPGMZA.RestAPI.call;WPGMZA.RestAPI.call=function(){console.warn("WPGMZA.RestAPI.call was called statically, did you mean to call the function on WPGMZA.restAPI?"),nativeCallFunction.apply(this,arguments)},$(document.body).on("click","#wpgmza-rest-api-blocked button.notice-dismiss",function(event){WPGMZA.restAPI.call("/rest-api/",{method:"POST",data:{dismiss_blocked_notice:!0}})})});var $_GET={};if(-1!==document.location.toString().indexOf("?"))for(var query=document.location.toString().replace(/^.*?\?/,"").replace(/#.*$/,"").split("&"),wpgmza_i=0,wpgmza_l=query.length;wpgmza_i<wpgmza_l;wpgmza_i++){var aux=decodeURIComponent(query[wpgmza_i]).split("=");$_GET[aux[0]]=aux[1]}jQuery(function($){WPGMZA.SettingsPage=function(){var self=this;this._keypressHistory=[],this._codemirrors={},this.updateEngineSpecificControls(),this.updateStorageControls(),this.updateBatchControls(),this.updateGDPRControls(),this.updateWooControls(),$(window).on("keypress",function(event){self.onKeyPress(event)}),jQuery("body").on("click",".wpgmza_destroy_data",function(e){e.preventDefault();var ttype=jQuery(this).attr("danger"),e="wpgmza_destroy_all_data"==ttype?"Are you sure? This will delete ALL data and settings for WP Go Maps!":"Are you sure?";window.confirm(e)&&jQuery.ajax(WPGMZA.ajaxurl,{method:"POST",data:{action:"wpgmza_maps_settings_danger_zone_delete_data",type:ttype,nonce:wpgmza_dz_nonce},success:function(response,status,xhr){"wpgmza_destroy_all_data"==ttype?window.location.replace("admin.php?page=wp-google-maps-menu&action=welcome_page"):"wpgmza_reset_all_settings"==ttype?window.location.reload():alert("Complete.")}})}),$("select[name='wpgmza_maps_engine']").on("change",function(event){self.updateEngineSpecificControls()}),$('[name="wpgmza_settings_marker_pull"]').on("click",function(event){self.updateStorageControls()}),$('input[name="enable_batch_loading"]').on("change",function(event){self.updateBatchControls()}),$("input[name='wpgmza_gdpr_require_consent_before_load'], input[name='wpgmza_gdpr_require_consent_before_vgm_submit'], input[name='wpgmza_gdpr_override_notice']").on("change",function(event){self.updateGDPRControls()}),$('input[name="woo_checkout_map_enabled"]').on("change",function(event){self.updateWooControls()}),$('select[name="tile_server_url"]').on("change",function(event){"custom_override"===$('select[name="tile_server_url"]').val()?$(".wpgmza_tile_server_override_component").removeClass("wpgmza-hidden"):$(".wpgmza_tile_server_override_component").addClass("wpgmza-hidden")}),$('select[name="tile_server_url"]').trigger("change"),jQuery("#wpgmza_flush_cache_btn").on("click",function(){jQuery(this).attr("disabled","disabled"),WPGMZA.settingsPage.flushGeocodeCache()}),$("#wpgmza-global-settings").tabs({create:function(event,ui){var elmnt,y;void 0!==$_GET.highlight&&((elmnt=document.getElementById($_GET.highlight)).classList.add("highlight-item"),setTimeout(function(){elmnt.classList.add("highlight-item-step-2")},1e3),y=elmnt.getBoundingClientRect().top+window.pageYOffset+-100,window.scrollTo({top:y,behavior:"smooth"}))},activate:function(){for(var i in self._codemirrors)self._codemirrors[i].refresh()}}),$("#wpgmza-global-setting").bind("create",function(event,ui){alert("now")}),$("#wpgmza-global-settings fieldset").each(function(index,el){$(el).children(":not(legend)").wrapAll("<span class='settings-group'></span>")}),$("textarea[name^='wpgmza_custom_']").each(function(){var name=$(this).attr("name"),type="js"===name.replace("wpgmza_custom_","")?"javascript":"css";self._codemirrors[name]=wp.CodeMirror.fromTextArea(this,{lineNumbers:!0,mode:type,theme:"wpgmza"}),self._codemirrors[name].on("change",function(instance){instance.save()}),self._codemirrors[name].refresh()}),$(".wpgmza-integration-tool-button").on("click",function(event){event.preventDefault();event=$(this).data("tool-type");if(event){event={type:event};const button=$(this);button.attr("disabled","disabled"),WPGMZA.restAPI.call("/integration-tools/",{method:"POST",data:event,success:function(data,status,xhr){if(button.removeAttr("disabled"),data&&data.type)switch(data.type){case"test_collation":data.success||($('.wpgmza-integration-tool-button[data-tool-type="test_collation"]').addClass("wpgmza-hidden"),$('.wpgmza-integration-tool-button[data-tool-type="resolve_collation"]').removeClass("wpgmza-hidden")),data.message&&window.alert(data.message);break;case"resolve_collation":data.success||($('.wpgmza-integration-tool-button[data-tool-type="test_collation"]').removeClass("wpgmza-hidden"),$('.wpgmza-integration-tool-button[data-tool-type="resolve_collation"]').addClass("wpgmza-hidden")),data.message&&window.alert(data.message);break;default:data.message&&window.alert(data.message)}}})}})},WPGMZA.SettingsPage.createInstance=function(){return new WPGMZA.SettingsPage},WPGMZA.SettingsPage.prototype.updateEngineSpecificControls=function(){var engine=$("select[name='wpgmza_maps_engine']").val();$("[data-required-maps-engine][data-required-maps-engine!='"+engine+"']").hide(),$("[data-required-maps-engine='"+engine+"']").show()},WPGMZA.SettingsPage.prototype.updateStorageControls=function(){$("input[name='wpgmza_settings_marker_pull'][value='1']").is(":checked")?$("#xml-cache-settings").show():$("#xml-cache-settings").hide()},WPGMZA.SettingsPage.prototype.updateBatchControls=function(){$("input[name='enable_batch_loading']").is(":checked")?$("#batch-loader-settings").show():$("#batch-loader-settings").hide()},WPGMZA.SettingsPage.prototype.updateGDPRControls=function(){var showNoticeControls=$("input[name='wpgmza_gdpr_require_consent_before_load']").prop("checked"),vgmCheckbox=$("input[name='wpgmza_gdpr_require_consent_before_vgm_submit']"),vgmCheckbox=(showNoticeControls=vgmCheckbox.length?showNoticeControls||vgmCheckbox.prop("checked"):showNoticeControls)&&$("input[name='wpgmza_gdpr_override_notice']").prop("checked");showNoticeControls?$("#wpgmza-gdpr-compliance-notice").show(!!WPGMZA.InternalEngine.isLegacy()&&"slow"):$("#wpgmza-gdpr-compliance-notice").hide(!!WPGMZA.InternalEngine.isLegacy()&&"slow"),vgmCheckbox?$("#wpgmza_gdpr_override_notice_text").show(!!WPGMZA.InternalEngine.isLegacy()&&"slow"):$("#wpgmza_gdpr_override_notice_text").hide(!!WPGMZA.InternalEngine.isLegacy()&&"slow")},WPGMZA.SettingsPage.prototype.updateWooControls=function(){$("input[name='woo_checkout_map_enabled']").prop("checked")?$(".woo-checkout-maps-select-row").show():$(".woo-checkout-maps-select-row").hide()},WPGMZA.SettingsPage.prototype.flushGeocodeCache=function(){(new WPGMZA.OLGeocoder).clearCache(function(response){jQuery("#wpgmza_flush_cache_btn").removeAttr("disabled")})},WPGMZA.SettingsPage.prototype.onKeyPress=function(event){this._keypressHistory.push(event.key),9<this._keypressHistory.length&&(this._keypressHistory=this._keypressHistory.slice(this._keypressHistory.length-9)),"codecabin"!=this._keypressHistory.join("")||this._developerModeRevealed||($("fieldset#wpgmza-developer-mode").show(),this._developerModeRevealed=!0)},$(document).ready(function(event){WPGMZA.getCurrentPage()&&(WPGMZA.settingsPage=WPGMZA.SettingsPage.createInstance())})}),jQuery(function($){var Parent=WPGMZA.Feature;WPGMZA.Shape=function(options,engineFeature){var self=this;WPGMZA.assertInstanceOf(this,"Shape"),Parent.apply(this,arguments),this.addEventListener("added",function(event){self.onAdded()})},WPGMZA.extend(WPGMZA.Shape,WPGMZA.Feature),WPGMZA.Shape.BASE_LAYER_INDEX=99999,WPGMZA.Shape.prototype.onAdded=function(){}}),jQuery(function($){var Parent=WPGMZA.Shape;WPGMZA.Circle=function(options,engineCircle){WPGMZA.assertInstanceOf(this,"Circle"),this.center=new WPGMZA.LatLng,this.radius=100,Parent.apply(this,arguments)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProShape),WPGMZA.extend(WPGMZA.Circle,Parent),Object.defineProperty(WPGMZA.Circle.prototype,"fillColor",{enumerable:!0,get:function(){return this.color&&this.color.length?this.color:"#ff0000"},set:function(a){this.color=a}}),Object.defineProperty(WPGMZA.Circle.prototype,"fillOpacity",{enumerable:!0,get:function(){return this.opacity||0==this.opacity?parseFloat(this.opacity):.5},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Circle.prototype,"strokeColor",{enumerable:!0,get:function(){return this.lineColor||"#000000"},set:function(a){this.lineColor=a}}),Object.defineProperty(WPGMZA.Circle.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.lineOpacity||0==this.lineOpacity?parseFloat(this.lineOpacity):0},set:function(a){this.lineOpacity=a}}),WPGMZA.Circle.createInstance=function(options,engineCircle){var constructor;switch(WPGMZA.settings.engine){case"open-layers":if(WPGMZA.isProVersion()){constructor=WPGMZA.OLProCircle;break}constructor=WPGMZA.OLCircle;break;default:if(WPGMZA.isProVersion()){constructor=WPGMZA.GoogleProCircle;break}constructor=WPGMZA.GoogleCircle}return new constructor(options,engineCircle)},WPGMZA.Circle.prototype.getCenter=function(){return this.center.clone()},WPGMZA.Circle.prototype.setCenter=function(latLng){this.center.lat=latLng.lat,this.center.lng=latLng.lng},WPGMZA.Circle.prototype.getRadius=function(){return this.radius},WPGMZA.Circle.prototype.setRadius=function(radius){this.radius=radius},WPGMZA.Circle.prototype.getMap=function(){return this.map},WPGMZA.Circle.prototype.setMap=function(map){this.map&&this.map.removeCircle(this),map&&map.addCircle(this)}}),jQuery(function($){var Parent=WPGMZA.Shape;WPGMZA.Rectangle=function(options,engineRectangle){WPGMZA.assertInstanceOf(this,"Rectangle"),this.name="",this.cornerA=new WPGMZA.LatLng,this.cornerB=new WPGMZA.LatLng,this.color="#ff0000",this.opacity=.5,Parent.apply(this,arguments)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProShape),WPGMZA.extend(WPGMZA.Rectangle,Parent),Object.defineProperty(WPGMZA.Rectangle.prototype,"fillColor",{enumerable:!0,get:function(){return this.color&&this.color.length?this.color:"#ff0000"},set:function(a){this.color=a}}),Object.defineProperty(WPGMZA.Rectangle.prototype,"fillOpacity",{enumerable:!0,get:function(){return this.opacity||0==this.opacity?parseFloat(this.opacity):.5},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Rectangle.prototype,"strokeColor",{enumerable:!0,get:function(){return this.lineColor||"#000000"},set:function(a){this.lineColor=a}}),Object.defineProperty(WPGMZA.Rectangle.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.lineOpacity||0==this.lineOpacity?parseFloat(this.lineOpacity):0},set:function(a){this.lineOpacity=a}}),WPGMZA.Rectangle.createInstance=function(options,engineRectangle){var constructor;switch(WPGMZA.settings.engine){case"open-layers":if(WPGMZA.isProVersion()){constructor=WPGMZA.OLProRectangle;break}constructor=WPGMZA.OLRectangle;break;default:if(WPGMZA.isProVersion()){constructor=WPGMZA.GoogleProRectangle;break}constructor=WPGMZA.GoogleRectangle}return new constructor(options,engineRectangle)}}),jQuery(function($){WPGMZA.SidebarGroupings=function(){var self=this;this.element=document.body,this.actionBar={element:$(this.element).find(".action-bar"),dynamicAction:null,dynamicLabel:""},$(this.element).on("click",".grouping .item",function(event){self.openTab(event)}),$(".quick-actions .actions").on("click",".icon",function(event){var feature=$(this).data("type");feature&&(self.openTabByFeatureType(feature),$(".quick-actions #qa-add-datasets").prop("checked",!1))}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-edit",function(event){event.feature&&self.openTabByFeatureType(event.feature)}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-saved",function(event){event.feature&&self.closeCurrent()}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-busy",function(event){self.resetScroll()}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-created",function(event){}),$(this.element).find(".fieldset-toggle").on("click",function(event){$(this).toggleClass("toggled")}),$(this.element).on("click",".wpgmza-toolbar .wpgmza-toolbar-list > *",function(event){$(this).parent().parent().find("label").click()}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-feature-caption-loaded",function(event){self.actionBar.dynamicAction&&(self.actionBar.dynamicLabel=self.actionBar.dynamicAction.text(),self.actionBar.element.find(".dynamic-action").removeClass("wpgmza-hidden").text(self.actionBar.dynamicLabel))}),this.actionBar.element.find(".dynamic-action").on("click",function(event){self.actionBar.dynamicAction&&self.actionBar.dynamicAction.click()}),this.initUpsellBlocks()},WPGMZA.extend(WPGMZA.SidebarGroupings,WPGMZA.EventDispatcher),WPGMZA.SidebarGroupings.createInstance=function(){return new WPGMZA.SidebarGroupings},WPGMZA.SidebarGroupings.prototype.openTab=function(event){event=event.currentTarget,event=$(event).data("group");this.openTabByGroupId(event),WPGMZA.mapEditPage&&WPGMZA.mapEditPage.map&&WPGMZA.mapEditPage.map.onElementResized()},WPGMZA.SidebarGroupings.prototype.openTabByFeatureType=function(feature){0<$(this.element).find('.grouping[data-feature="'+feature+'"]').length&&(feature=$(this.element).find('.grouping[data-feature="'+feature+'"]').data("group"),this.openTabByGroupId(feature))},WPGMZA.SidebarGroupings.prototype.openTabByGroupId=function(groupId){var element;groupId&&this.hasGroup(groupId)&&(this.closeAll(),(element=$(this.element).find('.grouping[data-group="'+groupId+'"]')).addClass("open"),element.data("feature-discard")&&$(element).trigger("feature-block-closed"),0<$(".wpgmza-map-settings-form").find(element).length?$(".wpgmza-map-settings-form").removeClass("wpgmza-hidden"):$(".wpgmza-map-settings-form").addClass("wpgmza-hidden"),element.hasClass("auto-expand")?$(".sidebar").addClass("expanded"):$(".sidebar").removeClass("expanded"),element.data("feature")&&$(element).trigger("feature-block-opened"),$(element).trigger("grouping-opened",[groupId]),this.updateActionBar(element))},WPGMZA.SidebarGroupings.prototype.hasGroup=function(groupId){return 0<$(this.element).find('.grouping[data-group="'+groupId+'"]').length},WPGMZA.SidebarGroupings.prototype.closeAll=function(){var self=this;$(this.element).find(".grouping.open").each(function(){var group=$(this).data("group");group&&$(self.element).trigger("grouping-closed",[group])}),$(this.element).find(".grouping").removeClass("open")},WPGMZA.SidebarGroupings.prototype.closeCurrent=function(){0<$(this.element).find(".grouping.open").length&&$(this.element).find(".grouping.open").find(".heading.has-back .item").click()},WPGMZA.SidebarGroupings.prototype.updateActionBar=function(element){this.actionBar.dynamicAction=null,element&&element.data("feature")&&0<element.find(".wpgmza-save-feature").length&&(this.actionBar.dynamicAction=element.find(".wpgmza-save-feature").first(),this.actionBar.dynamicLabel=this.actionBar.dynamicAction.text().trim()),this.actionBar.dynamicAction&&this.actionBar.dynamicAction.addClass("wpgmza-hidden"),this.actionBar.dynamicAction&&this.actionBar.dynamicLabel?(this.actionBar.element.find(".dynamic-action").removeClass("wpgmza-hidden").text(this.actionBar.dynamicLabel),this.actionBar.element.find(".static-action").addClass("wpgmza-hidden")):(this.actionBar.element.find(".static-action").removeClass("wpgmza-hidden"),this.actionBar.element.find(".dynamic-action").addClass("wpgmza-hidden").text(""))},WPGMZA.SidebarGroupings.prototype.resetScroll=function(){0<$(this.element).find(".grouping.open").length&&$(this.element).find(".grouping.open .settings").scrollTop(0)},WPGMZA.SidebarGroupings.prototype.initUpsellBlocks=function(){var upsellWrappers=$(this.element).find(".upsell-block.auto-rotate");if(upsellWrappers&&0<upsellWrappers.length)for(var currentWrapper of upsellWrappers)1<(currentWrapper=$(currentWrapper)).find(".upsell-block-card").length?(currentWrapper.addClass("rotate"),currentWrapper.on("wpgmza-upsell-rotate-card",function(){var cardLength=$(this).find(".upsell-block-card").length;$(this).find(".upsell-block-card").hide();let nextCard=parseInt(Math.random()*cardLength),nextCardElem=(nextCard<0?nextCard=0:nextCard>=cardLength&&(nextCard=cardLength-1),$(this).find(".upsell-block-card:nth-child("+(nextCard+1)+")"));0<nextCardElem.length&&!nextCardElem.hasClass("active")?($(this).find(".upsell-block-card").removeClass("active"),nextCardElem.addClass("active"),nextCardElem.fadeIn(200)):nextCardElem.show(),setTimeout(()=>{$(this).trigger("wpgmza-upsell-rotate-card")},1e4)}),currentWrapper.trigger("wpgmza-upsell-rotate-card")):currentWrapper.addClass("static")}}),jQuery(function($){WPGMZA.StoreLocator=function(map,element){var self=this;WPGMZA.EventDispatcher.call(this),this._center=null,this.map=map,this.element=element,this.state=WPGMZA.StoreLocator.STATE_INITIAL,this.distanceUnits=this.map.settings.store_locator_distance,this.addressInput=WPGMZA.AddressInput.createInstance(this.addressElement,this.map),$(element).find(".wpgmza-not-found-msg").hide(),this.radiusElement&&this.map.settings.wpgmza_store_locator_default_radius&&(this.radiusElement.data("default-override")||0<this.radiusElement.find("option[value='"+this.map.settings.wpgmza_store_locator_default_radius+"']").length&&this.radiusElement.val(this.map.settings.wpgmza_store_locator_default_radius)),this.map.on("storelocatorgeocodecomplete",function(event){self.onGeocodeComplete(event)}),this.map.on("init",function(event){self.map.markerFilter.on("filteringcomplete",function(event){self.onFilteringComplete(event)}),!WPGMZA.InternalEngine.isLegacy()||void 0!==self.map.settings.store_locator_style&&"modern"!=self.map.settings.store_locator_style&&"modern"!==WPGMZA.settings.user_interface_style||"default"!==WPGMZA.settings.user_interface_style&&"modern"!=WPGMZA.settings.user_interface_style&&"legacy"!=WPGMZA.settings.user_interface_style||(self.legacyModernAdapter=WPGMZA.ModernStoreLocator.createInstance(map.id))}),WPGMZA.InternalEngine.isLegacy()?($(document.body).on("click",".wpgmza_sl_search_button_"+map.id+", [data-map-id='"+map.id+"'] .wpgmza_sl_search_button",function(event){self.onSearch(event)}),$(document.body).on("click",".wpgmza_sl_reset_button_"+map.id+", [data-map-id='"+map.id+"'] .wpgmza_sl_reset_button_div",function(event){self.onReset(event)})):($(this.searchButton).on("click",function(event){self.onSearch(event)}),$(this.resetButton).on("click",function(event){self.onReset(event)})),$(this.addressElement).on("keypress",function(event){13==event.which&&self.onSearch(event)}),this.onQueryParamSearch(),self.trigger("init.storelocator")},WPGMZA.StoreLocator.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.StoreLocator.prototype.constructor=WPGMZA.StoreLocator,WPGMZA.StoreLocator.STATE_INITIAL="initial",WPGMZA.StoreLocator.STATE_APPLIED="applied",WPGMZA.StoreLocator.createInstance=function(map,element){return new WPGMZA.StoreLocator(map,element)},Object.defineProperty(WPGMZA.StoreLocator.prototype,"address",{get:function(){return $(this.addressElement).val()}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"addressElement",{get:function(){return(this.legacyModernAdapter?$(this.legacyModernAdapter.element):$(this.element)).find("input.wpgmza-address")[0]}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"countryRestriction",{get:function(){return this.map.settings.wpgmza_store_locator_restrict}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"radiusElement",{get:function(){return WPGMZA.InternalEngine.isLegacy()?$("#radiusSelect, #radiusSelect_"+this.map.id):$(this.element).find("select.wpgmza-radius")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"searchButton",{get:function(){return $(this.element).find(".wpgmza-search")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"resetButton",{get:function(){return $(this.element).find(".wpgmza-reset")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"errorElement",{get:function(){return $(this.element).find(".wpgmza-error")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"radius",{get:function(){return parseFloat(this.radiusElement.val())}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"center",{get:function(){return this._center}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"bounds",{get:function(){return this._bounds}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"marker",{get:function(){if(1!=this.map.settings.store_locator_bounce)return null;if(this._marker)return this._marker;return this._marker=WPGMZA.Marker.createInstance({visible:!1}),this._marker.disableInfoWindow=!0,this._marker.isFilterable=!1,this._marker.setAnimation(WPGMZA.Marker.ANIMATION_BOUNCE),this._marker}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"circle",{get:function(){return this._circle||("modern"!=this.map.settings.wpgmza_store_locator_radius_style||WPGMZA.isDeviceiOS()?this._circle=WPGMZA.Circle.createInstance({strokeColor:"#ff0000",strokeOpacity:"0.25",strokeWeight:2,fillColor:"#ff0000",fillOpacity:"0.15",visible:!1,clickable:!1,center:new WPGMZA.LatLng}):(this._circle=WPGMZA.ModernStoreLocatorCircle.createInstance(this.map.id),this._circle.settings.color=this.circleStrokeColor),this._circle)}}),WPGMZA.StoreLocator.prototype.onGeocodeComplete=function(event){if(!event.results||!event.results.length)return this._center=null,void(this._bounds=null);event.results[0].latLng?this._center=new WPGMZA.LatLng(event.results[0].latLng):event.results[0]instanceof WPGMZA.LatLng&&(this._center=new WPGMZA.LatLng(event.results[0])),this._bounds=new WPGMZA.LatLngBounds(event.results[0].bounds),this.isCapsule?this.redirectUrl&&this.onRedirectSearch():this.map.markerFilter.update({},this)},WPGMZA.StoreLocator.prototype.onSearch=function(event){var geocoder,options,self=this;return this.state=WPGMZA.StoreLocator.STATE_APPLIED,this.address&&this.address.length?(WPGMZA.InternalEngine.isLegacy()&&void 0!==this.map.settings.store_locator_style&&"modern"!==this.map.settings.store_locator_style&&"modern"!==WPGMZA.settings.user_interface_style&&"default"===WPGMZA.settings.user_interface_style&&WPGMZA.animateScroll(this.map.element),$(this.element).find(".wpgmza-not-found-msg").hide(),$(this.element).find(".wpgmza-error").removeClass("visible"),this.setVisualState("busy"),WPGMZA.LatLng.isLatLngString(this.address)?callback([WPGMZA.LatLng.fromString(this.address)],WPGMZA.Geocoder.SUCCESS):(geocoder=WPGMZA.Geocoder.createInstance(),options={address:this.address},this.countryRestriction&&(options.country=this.countryRestriction),geocoder.geocode(options,function(results,status){status==WPGMZA.Geocoder.SUCCESS?callback(results,status):WPGMZA.InternalEngine.isLegacy()?alert(WPGMZA.localized_strings.address_not_found):(self.showError(WPGMZA.localized_strings.address_not_found),self.setVisualState(!1))})),self.trigger("search.storelocator"),!0):(this.addressElement.focus(),!1);function callback(results,status){self.map.trigger({type:"storelocatorgeocodecomplete",results:results,status:status}),self.setVisualState("complete")}},WPGMZA.StoreLocator.prototype.onReset=function(event){this.state=WPGMZA.StoreLocator.STATE_INITIAL,this._center=null,this._bounds=null,this.map.setZoom(this.map.settings.map_start_zoom),$(this.element).find(".wpgmza-not-found-msg").hide(),this.circle&&this.circle.setVisible(!1),this.marker&&this.marker.map&&this.map.removeMarker(this.marker),this.map.markerFilter.update({},this),this.setVisualState(!1),WPGMZA.InternalEngine.isLegacy()||$(this.addressElement).val("").focus(),this.trigger("reset.storelocator")},WPGMZA.StoreLocator.prototype.onRedirectSearch=function(){if(this.redirectUrl)try{var data={radius:this.radius,center:this.center.lat+","+this.center.lng};const params=new URLSearchParams(data);window.location.href=this.redirectUrl+"?"+params.toString(),this.setVisualState("busy")}catch(ex){console.warn(ex)}},WPGMZA.StoreLocator.prototype.getFilteringParameters=function(){return this.center?{center:this.center,radius:this.radius}:{}},WPGMZA.StoreLocator.prototype.getZoomFromRadius=function(radius){return this.distanceUnits==WPGMZA.Distance.MILES&&(radius*=WPGMZA.Distance.KILOMETERS_PER_MILE),Math.round(14-Math.log(radius)/Math.LN2)},WPGMZA.StoreLocator.prototype.onFilteringComplete=function(event){var factor,params=event.filteringParams,marker=this.marker,marker=(marker&&marker.setVisible(!1),params.center&&(this.map.setCenter(params.center),marker&&(marker.setPosition(params.center),marker.setVisible(!0),marker.map!=this.map&&this.map.addMarker(marker))),params.radius&&this.map.setZoom(this.getZoomFromRadius(params.radius)),this.circle);marker&&(marker.setVisible(!1),factor=this.distanceUnits==WPGMZA.Distance.MILES?WPGMZA.Distance.KILOMETERS_PER_MILE:1,params.center&&params.radius&&(marker.setRadius(params.radius*factor),marker.setCenter(params.center),marker.setVisible(!0),marker instanceof WPGMZA.ModernStoreLocatorCircle||marker.map==this.map||this.map.addCircle(marker)),marker instanceof WPGMZA.ModernStoreLocatorCircle&&(marker.settings.radiusString=this.radius)),0==event.filteredMarkers.length&&this.state===WPGMZA.StoreLocator.STATE_APPLIED&&(WPGMZA.InternalEngine.isLegacy()?0<$(this.element).find(".wpgmza-no-results").length&&"legacy"===WPGMZA.settings.user_interface_style?$(this.element).find(".wpgmza-no-results").show():alert(this.map.settings.store_locator_not_found_message||WPGMZA.localized_strings.zero_results):this.showError(this.map.settings.store_locator_not_found_message||WPGMZA.localized_strings.zero_results))},WPGMZA.StoreLocator.prototype.onQueryParamSearch=function(){var queryCenter=WPGMZA.getQueryParamValue("center"),queryCenter=(queryCenter&&$(this.addressElement).val(queryCenter),WPGMZA.getQueryParamValue("radius"));queryCenter&&$(this.radiusElement).val(queryCenter),this.isCapsule||this.map.on("init",()=>{this.onSearch()})},WPGMZA.StoreLocator.prototype.setVisualState=function(state){!1!==state?$(this.element).attr("data-state",state):$(this.element).removeAttr("data-state")},WPGMZA.StoreLocator.prototype.showError=function(error){var self=this;WPGMZA.InternalEngine.isLegacy()||($(this.errorElement).text(error).addClass("visible"),setTimeout(function(){$(self.errorElement).text("").removeClass("visible")},3e3))}}),jQuery(function($){WPGMZA.StylingPage=function(){var self=this;this.element=document.body,this.styleGuide={wrapper:$(this.element).find(".wpgmza-styling-map-preview .wpgmza-style-guide-wrapper")},this.controls={},$(this.element).find(".wpgmza-styling-editor fieldset").each(function(){self.prepareControl(this)}),$(this.element).find(".wpgmza-styling-preset-select").on("change",function(){self.applyPreset(this)}),this.bindEvents(),this.parseUserPreset()},WPGMZA.StylingPage.PRESETS={},WPGMZA.StylingPage.PRESETS.default={"--wpgmza-component-color":"#ffffff","--wpgmza-component-text-color":"#000000","--wpgmza-component-color-accent":"#1A73E8","--wpgmza-component-text-color-accent":"#ffffff","--wpgmza-color-grey-500":"#bfbfbf","--wpgmza-component-border-radius":"2px","--wpgmza-component-font-size":"15px","--wpgmza-component-backdrop-filter":"none"},WPGMZA.StylingPage.PRESETS.glass={"--wpgmza-component-color":"rgba(255, 255, 255, 0.3)","--wpgmza-component-text-color":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color"],"--wpgmza-component-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-color-accent"],"--wpgmza-component-text-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color-accent"],"--wpgmza-color-grey-500":WPGMZA.StylingPage.PRESETS.default["--wpgmza-color-grey-500"],"--wpgmza-component-border-radius":"8px","--wpgmza-component-font-size":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-font-size"],"--wpgmza-component-backdrop-filter":"blur(20px)"},WPGMZA.StylingPage.PRESETS.rounded={"--wpgmza-component-color":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-color"],"--wpgmza-component-text-color":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color"],"--wpgmza-component-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-color-accent"],"--wpgmza-component-text-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color-accent"],"--wpgmza-color-grey-500":WPGMZA.StylingPage.PRESETS.default["--wpgmza-color-grey-500"],"--wpgmza-component-border-radius":"20px","--wpgmza-component-font-size":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-font-size"],"--wpgmza-component-backdrop-filter":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-backdrop-filter"]},WPGMZA.StylingPage.createInstance=function(){return new WPGMZA.StylingPage},WPGMZA.StylingPage.prototype.prepareControl=function(element){var element=$(element),input=element.find("input"),name=input.attr("name");if(""!==name.trim()){this.controls[name]={container:element,input:input};element=0<this.controls[name].input.length&&this.controls[name].input.get(0);if(element)if(element.wpgmzaColorInput){const colorInput=element.wpgmzaColorInput;colorInput.container&&(this.controls[name].resetButton=$("<div class='wpgmza-styling-editor-reset-btn' data-reset-control-name='"+name+"' />"),colorInput.container.prepend(this.controls[name].resetButton),colorInput.container.addClass("wpgmza-styling-editor-contains-reset"))}else if(element.wpgmzaCSSUnitInput){const unitInput=element.wpgmzaCSSUnitInput;unitInput.container&&(this.controls[name].resetButton=$("<div class='wpgmza-styling-editor-reset-btn' data-reset-control-name='"+name+"' />"),unitInput.container.prepend(this.controls[name].resetButton),unitInput.container.addClass("wpgmza-styling-editor-contains-reset"))}this.resetControl(this.controls[name])}},WPGMZA.StylingPage.prototype.bindEvents=function(){var name,self=this;for(name in this.controls)this.controls[name].input.on("change",function(){self.updateControl(this)});this.styleGuide.steps=this.styleGuide.wrapper.find(".wpgmza-style-guide-step").length,this.styleGuide.index=0,this.styleGuide.wrapper.find(".wpgmza-style-guide-nav .prev-btn").on("click",function(){--self.styleGuide.index,self.styleGuide.index<0&&(self.styleGuide.index=self.styleGuide.steps-1),self.styleGuide.wrapper.trigger("update-view")}),this.styleGuide.wrapper.find(".wpgmza-style-guide-nav .next-btn").on("click",function(){self.styleGuide.index+=1,self.styleGuide.index>=self.styleGuide.steps&&(self.styleGuide.index=0),self.styleGuide.wrapper.trigger("update-view")}),this.styleGuide.wrapper.on("update-view",function(){self.styleGuide.wrapper.find(".wpgmza-style-guide-step").removeClass("active"),self.styleGuide.wrapper.find(".wpgmza-style-guide-step:nth-child("+(self.styleGuide.index+1)+")").addClass("active")}),$(document.body).on("click",".wpgmza-styling-editor-reset-btn",function(){$(this);var field=$(this).data("reset-control-name");field&&self.controls[field]&&self.resetControl(self.controls[field])})},WPGMZA.StylingPage.prototype.updateControl=function(input){var name=$(input).attr("name");name&&-1!==name.indexOf("--")&&$(".wpgmza-styling-preview-wrap .wpgmza_map").css(name,$(input).val())},WPGMZA.StylingPage.prototype.resetControl=function(control){var name=control.input.attr("name");if(name&&-1!==name.indexOf("--")&&(name=$(":root").css(name))){var name=name.trim(),activeInput=0<control.input.length&&control.input.get(0);if(activeInput)if(activeInput.wpgmzaColorInput){const colorInput=activeInput.wpgmzaColorInput;colorInput.parseColor(name)}else if(activeInput.wpgmzaCSSUnitInput){const unitInput=activeInput.wpgmzaCSSUnitInput;unitInput.parseUnits(name)}else if(activeInput.wpgmzaCSSBackdropFilterInput){const backdropInput=activeInput.wpgmzaCSSBackdropFilterInput;backdropInput.parseFilters(name)}else control.input.val(name)}},WPGMZA.StylingPage.prototype.parseUserPreset=function(){WPGMZA.stylingSettings&&WPGMZA.stylingSettings instanceof Object&&0<Object.keys(WPGMZA.stylingSettings).length&&(WPGMZA.StylingPage.PRESETS.user=WPGMZA.stylingSettings,$(".wpgmza-styling-preset-select").append("<option value='user'>User Defined</option>"),$(".wpgmza-styling-preset-select").val("user").trigger("change"))},WPGMZA.StylingPage.prototype.applyPreset=function(element){element=(element=$(element)).val();if(element&&WPGMZA.StylingPage.PRESETS[element]){var fieldName,preset=WPGMZA.StylingPage.PRESETS[element];for(fieldName in preset){var fieldValue=preset[fieldName];let field=$(this.element).find('input[name="'+fieldName+'"]');0<field.length&&((field=field.get(0)).wpgmzaColorInput?field.wpgmzaColorInput.parseColor(fieldValue):field.wpgmzaCSSUnitInput?field.wpgmzaCSSUnitInput.parseUnits(fieldValue):field.wpgmzaCSSBackdropFilterInput?field.wpgmzaCSSBackdropFilterInput.parseFilters(fieldValue):($(field).val(fieldValue),$(field).trigger("change")))}}},$(document).ready(function(event){WPGMZA.getCurrentPage()&&(WPGMZA.stylingPage=WPGMZA.StylingPage.createInstance())})}),jQuery(function($){WPGMZA.SupportPage=function(){$(".support-page").tabs(),$(".wpgmza-copy-sysinfo").on("click",function(){var info=$(".system-info").text();if(info.length){const temp=jQuery("<textarea>");$(document.body).append(temp),temp.val(info).select(),document.execCommand("copy"),temp.remove(),WPGMZA.notification("Info Copied")}})},WPGMZA.SupportPage.createInstance=function(){return new WPGMZA.SupportPage},$(document).ready(function(event){WPGMZA.getCurrentPage()===WPGMZA.PAGE_SUPPORT&&(WPGMZA.supportPage=WPGMZA.SupportPage.createInstance())})}),jQuery(function($){WPGMZA.Text=function(options){if(options)for(var name in options)this[name]=options[name]},WPGMZA.Text.createInstance=function(options){return new("open-layers"!==WPGMZA.settings.engine?WPGMZA.GoogleText:WPGMZA.OLText)(options)},WPGMZA.Text.prototype.setPosition=function(position){this.overlay&&this.overlay.setPosition(position)},WPGMZA.Text.prototype.setText=function(text){this.overlay&&this.overlay.setText(text)},WPGMZA.Text.prototype.setFontSize=function(size){this.overlay&&this.overlay.setFontSize(size)},WPGMZA.Text.prototype.setFillColor=function(color){this.overlay&&this.overlay.setFillColor(color)},WPGMZA.Text.prototype.setLineColor=function(color){this.overlay&&this.overlay.setLineColor(color)},WPGMZA.Text.prototype.setOpacity=function(opacity){this.overlay&&this.overlay.setOpacity(opacity)},WPGMZA.Text.prototype.remove=function(){this.overlay&&this.overlay.remove()},WPGMZA.Text.prototype.refresh=function(){}}),jQuery(function($){WPGMZA.ThemeEditor=function(){if(WPGMZA.EventDispatcher.call(this),this.element=$("#wpgmza-theme-editor"),"open-layers"==WPGMZA.settings.engine)return this.element.remove(),void(this.olThemeEditor=new WPGMZA.OLThemeEditor);this.element.length?(this.json=[{}],this.mapElement=WPGMZA.maps[0].element,this.element.appendTo("#wpgmza-map-theme-editor__holder"),$(window).on("scroll",function(event){}),setInterval(function(){},200),this.initHTML(),WPGMZA.themeEditor=this):console.warn("No element to initialise theme editor on")},WPGMZA.extend(WPGMZA.ThemeEditor,WPGMZA.EventDispatcher),WPGMZA.ThemeEditor.prototype.updatePosition=function(){},WPGMZA.ThemeEditor.features={all:[],administrative:["country","land_parcel","locality","neighborhood","province"],landscape:["man_made","natural","natural.landcover","natural.terrain"],poi:["attraction","business","government","medical","park","place_of_worship","school","sports_complex"],road:["arterial","highway","highway.controlled_access","local"],transit:["line","station","station.airport","station.bus","station.rail"],water:[]},WPGMZA.ThemeEditor.elements={all:[],geometry:["fill","stroke"],labels:["icon","text","text.fill","text.stroke"]},WPGMZA.ThemeEditor.prototype.parse=function(){$("#wpgmza_theme_editor_feature option, #wpgmza_theme_editor_element option").css("font-weight","normal"),$("#wpgmza_theme_editor_error").hide(),$("#wpgmza_theme_editor").show(),$("#wpgmza_theme_editor_do_hue").prop("checked",!1),$("#wpgmza_theme_editor_hue").val("#000000"),$("#wpgmza_theme_editor_lightness").val(""),$("#wpgmza_theme_editor_saturation").val(""),$("#wpgmza_theme_editor_gamma").val(""),$("#wpgmza_theme_editor_do_invert_lightness").prop("checked",!1),$("#wpgmza_theme_editor_visibility").val("inherit"),$("#wpgmza_theme_editor_do_color").prop("checked",!1),$("#wpgmza_theme_editor_color").val("#000000"),$("#wpgmza_theme_editor_weight").val("");var textarea=$('textarea[name="wpgmza_theme_data"]');if(this.refreshColorInputs(),!textarea.val()||textarea.val().length<1)this.json=[{}];else{try{this.json=$.parseJSON($('textarea[name="wpgmza_theme_data"]').val())}catch(e){return this.json=[{}],$("#wpgmza_theme_editor").hide(),void $("#wpgmza_theme_editor_error").show()}$.isArray(this.json)||(textarea=this.json,this.json=[],this.json.push(textarea)),this.highlightFeatures(),this.highlightElements(),this.loadElementStylers()}},WPGMZA.ThemeEditor.prototype.highlightFeatures=function(){$("#wpgmza_theme_editor_feature option").css("font-weight","normal"),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")?$('#wpgmza_theme_editor_feature option[value="'+v.featureType+'"]'):$('#wpgmza_theme_editor_feature option[value="all"]')).css("font-weight","bold")})},WPGMZA.ThemeEditor.prototype.highlightElements=function(){var feature=$("#wpgmza_theme_editor_feature").val();$("#wpgmza_theme_editor_element option").css("font-weight","normal"),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")&&v.featureType==feature||"all"==feature&&!v.hasOwnProperty("featureType"))&&(v.hasOwnProperty("elementType")?$('#wpgmza_theme_editor_element option[value="'+v.elementType+'"]'):$('#wpgmza_theme_editor_element option[value="all"]')).css("font-weight","bold")})},WPGMZA.ThemeEditor.prototype.loadElementStylers=function(){var feature=$("#wpgmza_theme_editor_feature").val(),element=$("#wpgmza_theme_editor_element").val();$("#wpgmza_theme_editor_do_hue").prop("checked",!1),$("#wpgmza_theme_editor_hue").val("#000000"),$("#wpgmza_theme_editor_lightness").val(""),$("#wpgmza_theme_editor_saturation").val(""),$("#wpgmza_theme_editor_gamma").val(""),$("#wpgmza_theme_editor_do_invert_lightness").prop("checked",!1),$("#wpgmza_theme_editor_visibility").val("inherit"),$("#wpgmza_theme_editor_do_color").prop("checked",!1),$("#wpgmza_theme_editor_color").val("#000000"),$("#wpgmza_theme_editor_weight").val(""),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")&&v.featureType==feature||"all"==feature&&!v.hasOwnProperty("featureType"))&&(v.hasOwnProperty("elementType")&&v.elementType==element||"all"==element&&!v.hasOwnProperty("elementType"))&&v.hasOwnProperty("stylers")&&$.isArray(v.stylers)&&0<v.stylers.length&&$.each(v.stylers,function(ii,vv){vv.hasOwnProperty("hue")&&($("#wpgmza_theme_editor_do_hue").prop("checked",!0),$("#wpgmza_theme_editor_hue").val(vv.hue)),vv.hasOwnProperty("lightness")&&$("#wpgmza_theme_editor_lightness").val(vv.lightness),vv.hasOwnProperty("saturation")&&$("#wpgmza_theme_editor_saturation").val(vv.xaturation),vv.hasOwnProperty("gamma")&&$("#wpgmza_theme_editor_gamma").val(vv.gamma),vv.hasOwnProperty("invert_lightness")&&$("#wpgmza_theme_editor_do_invert_lightness").prop("checked",!0),vv.hasOwnProperty("visibility")&&$("#wpgmza_theme_editor_visibility").val(vv.visibility),vv.hasOwnProperty("color")&&($("#wpgmza_theme_editor_do_color").prop("checked",!0),$("#wpgmza_theme_editor_color").val(vv.color)),vv.hasOwnProperty("weight")&&$("#wpgmza_theme_editor_weight").val(vv.weight)})}),this.refreshColorInputs()},WPGMZA.ThemeEditor.prototype.writeElementStylers=function(){var new_feature_element_stylers,feature=$("#wpgmza_theme_editor_feature").val(),element=$("#wpgmza_theme_editor_element").val(),indexJSON=null,stylers=[];"inherit"!=$("#wpgmza_theme_editor_visibility").val()&&stylers.push({visibility:$("#wpgmza_theme_editor_visibility").val()}),!0===$("#wpgmza_theme_editor_do_color").prop("checked")&&stylers.push({color:$("#wpgmza_theme_editor_color").val()}),!0===$("#wpgmza_theme_editor_do_hue").prop("checked")&&stylers.push({hue:$("#wpgmza_theme_editor_hue").val()}),0<$("#wpgmza_theme_editor_gamma").val().length&&stylers.push({gamma:parseFloat($("#wpgmza_theme_editor_gamma").val())}),0<$("#wpgmza_theme_editor_weight").val().length&&stylers.push({weight:parseFloat($("#wpgmza_theme_editor_weight").val())}),0<$("#wpgmza_theme_editor_saturation").val().length&&stylers.push({saturation:parseFloat($("#wpgmza_theme_editor_saturation").val())}),0<$("#wpgmza_theme_editor_lightness").val().length&&stylers.push({lightness:parseFloat($("#wpgmza_theme_editor_lightness").val())}),!0===$("#wpgmza_theme_editor_do_invert_lightness").prop("checked")&&stylers.push({invert_lightness:!0}),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")&&v.featureType==feature||"all"==feature&&!v.hasOwnProperty("featureType"))&&(v.hasOwnProperty("elementType")&&v.elementType==element||"all"==element&&!v.hasOwnProperty("elementType"))&&(indexJSON=i)}),null===indexJSON?0<stylers.length&&(new_feature_element_stylers={},"all"!=feature&&(new_feature_element_stylers.featureType=feature),"all"!=element&&(new_feature_element_stylers.elementType=element),new_feature_element_stylers.stylers=stylers,this.json.push(new_feature_element_stylers)):0<stylers.length?this.json[indexJSON].stylers=stylers:this.json.splice(indexJSON,1),$('textarea[name="wpgmza_theme_data"]').val(JSON.stringify(this.json).replace(/:/g,": ").replace(/,/g,", ")),this.highlightFeatures(),this.highlightElements(),WPGMZA.themePanel.updateMapTheme()},WPGMZA.ThemeEditor.prototype.initHTML=function(){var self=this;$.each(WPGMZA.ThemeEditor.features,function(i,v){$("#wpgmza_theme_editor_feature").append('<option value="'+i+'">'+i+"</option>"),0<v.length&&$.each(v,function(ii,vv){$("#wpgmza_theme_editor_feature").append('<option value="'+i+"."+vv+'">'+i+"."+vv+"</option>")})}),$.each(WPGMZA.ThemeEditor.elements,function(i,v){$("#wpgmza_theme_editor_element").append('<option value="'+i+'">'+i+"</option>"),0<v.length&&$.each(v,function(ii,vv){$("#wpgmza_theme_editor_element").append('<option value="'+i+"."+vv+'">'+i+"."+vv+"</option>")})}),this.parse(),$('textarea[name="wpgmza_theme_data"]').on("input selectionchange propertychange",function(){self.parse()}),$(".wpgmza_theme_selection").click(function(){setTimeout(function(){$('textarea[name="wpgmza_theme_data"]').trigger("input")},1e3)}),$("#wpgmza-theme-editor__toggle").click(function(){$("#wpgmza-theme-editor").removeClass("active")}),$("#wpgmza_theme_editor_feature").on("change",function(){self.highlightElements(),self.loadElementStylers()}),$("#wpgmza_theme_editor_element").on("change",function(){self.loadElementStylers()}),$("#wpgmza_theme_editor_do_hue, #wpgmza_theme_editor_hue, #wpgmza_theme_editor_lightness, #wpgmza_theme_editor_saturation, #wpgmza_theme_editor_gamma, #wpgmza_theme_editor_do_invert_lightness, #wpgmza_theme_editor_visibility, #wpgmza_theme_editor_do_color, #wpgmza_theme_editor_color, #wpgmza_theme_editor_weight").on("input selectionchange propertychange",function(){self.writeElementStylers()}),"open-layers"==WPGMZA.settings.engine&&$("#wpgmza_theme_editor :input").prop("disabled",!0)},WPGMZA.ThemeEditor.prototype.refreshColorInputs=function(){$("input#wpgmza_theme_editor_hue,input#wpgmza_theme_editor_color").each(function(){this.wpgmzaColorInput&&this.wpgmzaColorInput.parseColor(this.value)})}}),jQuery(function($){WPGMZA.ThemePanel=function(){var self=this;if(this.element=$("#wpgmza-theme-panel"),this.map=WPGMZA.maps[0],"open-layers"==WPGMZA.settings.engine)return this.element.remove(),void(this.olThemePanel=new WPGMZA.OLThemePanel);this.element.length?($("#wpgmza-theme-presets").owlCarousel({items:6,dots:!0}),this.element.on("click","#wpgmza-theme-presets label, .theme-selection-panel label",function(event){self.onThemePresetClick(event)}),$("#wpgmza-open-theme-editor").on("click",function(event){$("#wpgmza-map-theme-editor__holder").addClass("active"),$("#wpgmza-theme-editor").addClass("active"),WPGMZA.animateScroll($("#wpgmza-theme-editor"))}),WPGMZA.themePanel=this):console.warn("No element to initialise theme panel on")},WPGMZA.ThemePanel.previewImageCenter={lat:33.701806462148646,lng:-118.15949896058983},WPGMZA.ThemePanel.previewImageZoom=11,WPGMZA.ThemePanel.prototype.onThemePresetClick=function(event){var event=$(event.currentTarget).find("[data-theme-json]").attr("data-theme-json"),textarea=$("textarea[name='wpgmza_theme_data']"),existingData=textarea.val(),allPresetData=[];$(this.element).find("[data-theme-json]").each(function(index,el){allPresetData.push($(el).attr("data-theme-json"))}),existingData.length&&-1==allPresetData.indexOf(existingData)&&!confirm(WPGMZA.localized_strings.overwrite_theme_data)||(textarea.val(event),this.updateMapTheme(),WPGMZA.themeEditor.parse())},WPGMZA.ThemePanel.prototype.updateMapTheme=function(){var data;try{data=JSON.parse($("textarea[name='wpgmza_theme_data']").val())}catch(e){return void alert(WPGMZA.localized_strings.invalid_theme_data)}this.map.setOptions({styles:data})}}),jQuery(function($){WPGMZA.Version=function(){},WPGMZA.Version.GREATER_THAN=1,WPGMZA.Version.EQUAL_TO=0,WPGMZA.Version.LESS_THAN=-1,WPGMZA.Version.compare=function(v1,v2){for(var v1parts=v1.match(/\d+/g),v2parts=v2.match(/\d+/g),i=0;i<v1parts.length;++i){if(v2parts.length===i)return 1;if(v1parts[i]!==v2parts[i])return v1parts[i]>v2parts[i]?1:-1}return v1parts.length!=v2parts.length?-1:0}}),jQuery(function($){WPGMZA.XMLCacheConverter=function(){},WPGMZA.XMLCacheConverter.prototype.convert=function(xml){var markers=[],remap={marker_id:"id",linkd:"link"};return $(xml).find("marker").each(function(index,el){var data={};$(el).children().each(function(j,child){var key=child.nodeName;remap[key]&&(key=remap[key]),child.hasAttribute("data-json")?data[key]=JSON.parse($(child).text()):data[key]=$(child).text()}),markers.push(data)}),markers}}),jQuery(function($){WPGMZA.loadXMLAsWebWorker=function(){function tXml(a,d){function c(){for(var l=[];a[b];){if(60==a.charCodeAt(b)){if(47===a.charCodeAt(b+1)){b=a.indexOf(">",b);break}if(33===a.charCodeAt(b+1)){if(45==a.charCodeAt(b+2)){for(;62!==a.charCodeAt(b)||45!=a.charCodeAt(b-1)||45!=a.charCodeAt(b-2)||-1==b;)b=a.indexOf(">",b+1);-1===b&&(b=a.length)}else for(b+=2;62!==a.charCodeAt(b);)b++;b++;continue}var c=f();l.push(c)}else c=b,-2===(b=a.indexOf("<",b)-1)&&(b=a.length),0<(c=a.slice(c,b+1)).trim().length&&l.push(c);b++}return l}function l(){for(var c=b;-1===g.indexOf(a[b]);)b++;return a.slice(c,b)}function f(){var d={};b++,d.tagName=l();for(var f=!1;62!==a.charCodeAt(b);){if(64<(e=a.charCodeAt(b))&&e<91||96<e&&e<123){for(var h,g=l(),e=a.charCodeAt(b);39!==e&&34!==e&&!(64<e&&e<91||96<e&&e<123)&&62!==e;)b++,e=a.charCodeAt(b);f||(d.attributes={},f=!0),39===e||34===e?(e=a[b],h=++b,b=a.indexOf(e,h),e=a.slice(h,b)):(e=null,b--),d.attributes[g]=e}b++}return 47!==a.charCodeAt(b-1)&&("script"==d.tagName?(f=b+1,b=a.indexOf("<\/script>",b),d.children=[a.slice(f,b-1)],b+=8):"style"==d.tagName?(f=b+1,b=a.indexOf("</style>",b),d.children=[a.slice(f,b-1)],b+=7):-1==k.indexOf(d.tagName)&&(b++,d.children=c())),d}var b,g="\n\t>/= ",k=["img","br","input","meta","link"],h=null;return(d=d||{}).searchId?(-1===(b=new RegExp("s*ids*=s*['\"]"+d.searchId+"['\"]").exec(a).index)||-1!==(b=a.lastIndexOf("<",b))&&(h=f()),b):(b=0,h=c(),d.filter&&(h=tXml.filter(h,d.filter)),d.simplify?tXml.simplefy(h):h)}tXml.simplify=function(a){var c,d={};if(1===a.length&&"string"==typeof a[0])return a[0];for(c in a.forEach(function(a){var c;d[a.tagName]||(d[a.tagName]=[]),"object"==typeof a?(c=tXml.simplefy(a.children),d[a.tagName].push(c),a.attributes&&(c._attributes=a.attributes)):d[a.tagName].push(a)}),d)1==d[c].length&&(d[c]=d[c][0]);return d},tXml.filter=function(a,d){var c=[];return a.forEach(function(a){"object"==typeof a&&d(a)&&c.push(a),a.children&&(a=tXml.filter(a.children,d),c=c.concat(a))}),c},tXml.domToXml=function(a){var c="";return function d(a){if(a)for(var f=0;f<a.length;f++)if("string"==typeof a[f])c+=a[f].trim();else{var g=a[f],k=void(c+="<"+g.tagName);for(k in g.attributes)c=-1===g.attributes[k].indexOf('"')?c+(" "+k+'="'+g.attributes[k].trim())+'"':c+(" "+k+"='"+g.attributes[k].trim())+"'";c+=">",d(g.children),c+="</"+g.tagName+">"}}(O),c},"object"!=typeof window&&(module.exports=tXml);var inputData,totalFiles,worker=self,dataForMainThread=[],filesLoaded=0;function onXMLLoaded(request){4==request.readyState&&200==request.status&&((new Date).getTime(),function(xml){for(var markers=xml[0].children[0],remap={marker_id:"id",linkd:"link"},i=0;i<markers.children.length;i++){var data={};markers.children[i].children.forEach(function(node){var key=node.tagName;remap[key]&&(key=remap[key]),node.attributes["data-json"]?data[key]=JSON.parse(node.children[0]):node.children.length?data[key]=node.children[0]:data[key]=""}),dataForMainThread.push(data)}}(tXml(request.responseText)),++filesLoaded>=totalFiles?worker.postMessage(dataForMainThread):loadNextFile())}function loadNextFile(){var url=inputData.urls[filesLoaded],request=new XMLHttpRequest;request.onreadystatechange=function(){onXMLLoaded(this)},request.open("GET",inputData.protocol+url,!0),request.send()}self.addEventListener("message",function(event){event=event.data;if("load"!==event.command)throw new Error("Unknown command");dataForMainThread=[],filesLoaded=0,totalFiles=(inputData=event).urls.length,loadNextFile()},!1)}}),jQuery(function($){WPGMZA.Integration={},WPGMZA.integrationModules={},WPGMZA.Integration.Blocks={},WPGMZA.Integration.Blocks.instances={}}),jQuery(function($){var __,registerBlockType,InspectorControls,_wp$editor,Dashicon,PanelBody;window.wp&&wp.i18n&&wp.blocks&&wp.editor&&wp.components&&(__=wp.i18n.__,registerBlockType=wp.blocks.registerBlockType,_wp$editor=wp.editor,InspectorControls=_wp$editor.InspectorControls,_wp$editor.BlockControls,_wp$editor=wp.components,Dashicon=_wp$editor.Dashicon,_wp$editor.Toolbar,_wp$editor.Button,_wp$editor.Tooltip,PanelBody=_wp$editor.PanelBody,_wp$editor.TextareaControl,_wp$editor.CheckboxControl,_wp$editor.TextControl,_wp$editor.SelectControl,_wp$editor.RichText,WPGMZA.Integration.Gutenberg=function(){registerBlockType("gutenberg-wpgmza/block",this.getBlockDefinition())},WPGMZA.Integration.Gutenberg.prototype.getBlockTitle=function(){return __("WP Go Maps")},WPGMZA.Integration.Gutenberg.prototype.getBlockInspectorControls=function(props){return React.createElement(InspectorControls,{key:"inspector"},React.createElement(PanelBody,{title:__("Map Settings")},React.createElement("p",{class:"map-block-gutenberg-button-container"},React.createElement("a",{href:WPGMZA.adminurl+"admin.php?page=wp-google-maps-menu&action=edit&map_id=1",target:"_blank",class:"button button-primary"},React.createElement("i",{class:"fa fa-pencil-square-o","aria-hidden":"true"}),__("Go to Map Editor"))),React.createElement("p",{class:"map-block-gutenberg-button-container"},React.createElement("a",{href:"https://www.wpgmaps.com/documentation/creating-your-first-map/",target:"_blank",class:"button button-primary"},React.createElement("i",{class:"fa fa-book","aria-hidden":"true"}),__("View Documentation")))))},WPGMZA.Integration.Gutenberg.prototype.getBlockAttributes=function(){return{}},WPGMZA.Integration.Gutenberg.prototype.getBlockDefinition=function(props){var _this=this;return{title:WPGMZA.InternalEngine.isLegacy()?__("WP Go Maps"):__("Map"),description:__("The easiest to use Google Maps plugin! Create custom Google Maps with high quality markers containing locations, descriptions, images and links. Add your customized map to your WordPress posts and/or pages quickly and easily with the supplied shortcode. No fuss."),category:!WPGMZA.InternalEngine.isLegacy()&&this.verifyCategory("wpgmza-gutenberg")?"wpgmza-gutenberg":"common",icon:"location-alt",keywords:[__("Map"),__("Maps"),__("Google")],attributes:this.getBlockAttributes(),edit:function(props){return[!!props.isSelected&&_this.getBlockInspectorControls(props),React.createElement("div",{className:props.className+" wpgmza-gutenberg-block"},React.createElement(Dashicon,{icon:"location-alt"}),React.createElement("span",{class:"wpgmza-gutenberg-block-title"},__("Your map will appear here on your websites front end")))]},save:function(props){return null}}},WPGMZA.Integration.Gutenberg.prototype.verifyCategory=function(category){if(wp.blocks&&wp.blocks.getCategories){var i,categories=wp.blocks.getCategories();for(i in categories)if(categories[i].slug===category)return!0}return!1},WPGMZA.Integration.Gutenberg.getConstructor=function(){return WPGMZA.Integration.Gutenberg},WPGMZA.Integration.Gutenberg.createInstance=function(){return new(WPGMZA.Integration.Gutenberg.getConstructor())},WPGMZA.isProVersion()||/^6/.test(WPGMZA.pro_version)||(WPGMZA.integrationModules.gutenberg=WPGMZA.Integration.Gutenberg.createInstance()))}),jQuery(function($){$(document).ready(function(event){var parent=document.body.onclick;parent&&(document.body.onclick=function(event){event.target instanceof WPGMZA.Marker||parent(event)})})}),jQuery(function($){WPGMZA.GoogleUICompatibility=function(){var style;navigator.vendor&&-1<navigator.vendor.indexOf("Apple")&&navigator.userAgent&&-1==navigator.userAgent.indexOf("CriOS")&&-1==navigator.userAgent.indexOf("FxiOS")||((style=$("<style id='wpgmza-google-ui-compatiblity-fix'/>")).html(".wpgmza_map img:not(button img) { padding:0 !important; }"),$(document.head).append(style))},WPGMZA.googleUICompatibility=new WPGMZA.GoogleUICompatibility}),jQuery(function($){var Parent=WPGMZA.Circle;WPGMZA.GoogleCircle=function(options,googleCircle){var self=this;Parent.call(this,options,googleCircle),googleCircle?(this.googleCircle=googleCircle,options&&(options.center=WPGMZA.LatLng.fromGoogleLatLng(googleCircle.getCenter()),options.radius=googleCircle.getRadius()/1e3)):(this.googleCircle=new google.maps.Circle,this.googleCircle.wpgmzaCircle=this),this.googleFeature=this.googleCircle,options&&this.setOptions(options),google.maps.event.addListener(this.googleCircle,"click",function(){self.dispatchEvent({type:"click"})})},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProCircle),WPGMZA.GoogleCircle.prototype=Object.create(Parent.prototype),WPGMZA.GoogleCircle.prototype.constructor=WPGMZA.GoogleCircle,WPGMZA.GoogleCircle.prototype.getCenter=function(){return WPGMZA.LatLng.fromGoogleLatLng(this.googleCircle.getCenter())},WPGMZA.GoogleCircle.prototype.setCenter=function(center){WPGMZA.Circle.prototype.setCenter.apply(this,arguments),this.googleCircle.setCenter(center)},WPGMZA.GoogleCircle.prototype.getRadius=function(){return this.googleCircle.getRadius()/1e3},WPGMZA.GoogleCircle.prototype.setRadius=function(radius){WPGMZA.Circle.prototype.setRadius.apply(this,arguments),this.googleCircle.setRadius(1e3*parseFloat(radius))},WPGMZA.GoogleCircle.prototype.setVisible=function(visible){this.googleCircle.setVisible(!!visible)},WPGMZA.GoogleCircle.prototype.setDraggable=function(value){this.googleCircle.setDraggable(!!value)},WPGMZA.GoogleCircle.prototype.setEditable=function(value){var self=this;this.googleCircle.setOptions({editable:value}),value&&(google.maps.event.addListener(this.googleCircle,"center_changed",function(event){self.center=WPGMZA.LatLng.fromGoogleLatLng(self.googleCircle.getCenter()),self.trigger("change")}),google.maps.event.addListener(this.googleCircle,"radius_changed",function(event){self.radius=self.googleCircle.getRadius()/1e3,self.trigger("change")}))},WPGMZA.GoogleCircle.prototype.setOptions=function(options){WPGMZA.Circle.prototype.setOptions.apply(this,arguments),options.center&&(this.center=new WPGMZA.LatLng(options.center))},WPGMZA.GoogleCircle.prototype.updateNativeFeature=function(){var googleOptions=this.getScalarProperties(),center=new WPGMZA.LatLng(this.center);googleOptions.radius*=1e3,googleOptions.center=center.toGoogleLatLng(),this.googleCircle.setOptions(googleOptions)}}),jQuery(function($){WPGMZA.GoogleDrawingManager=function(map){var self=this;WPGMZA.DrawingManager.call(this,map),this.mode=null,this.googleDrawingManager=new google.maps.drawing.DrawingManager({drawingControl:!1,polygonOptions:{editable:!0},polylineOptions:{editable:!0},circleOptions:{editable:!0},rectangleOptions:{draggable:!0,editable:!0,strokeWeight:1,fillOpacity:0}}),this.googleDrawingManager.setMap(map.googleMap),google.maps.event.addListener(this.googleDrawingManager,"polygoncomplete",function(polygon){self.onPolygonClosed(polygon)}),google.maps.event.addListener(this.googleDrawingManager,"polylinecomplete",function(polyline){self.onPolylineComplete(polyline)}),google.maps.event.addListener(this.googleDrawingManager,"circlecomplete",function(circle){self.onCircleComplete(circle)}),google.maps.event.addListener(this.googleDrawingManager,"rectanglecomplete",function(rectangle){self.onRectangleComplete(rectangle)})},WPGMZA.GoogleDrawingManager.prototype=Object.create(WPGMZA.DrawingManager.prototype),WPGMZA.GoogleDrawingManager.prototype.constructor=WPGMZA.GoogleDrawingManager,WPGMZA.GoogleDrawingManager.prototype.setDrawingMode=function(mode){var googleMode;switch(WPGMZA.DrawingManager.prototype.setDrawingMode.call(this,mode),mode){case WPGMZA.DrawingManager.MODE_NONE:case WPGMZA.DrawingManager.MODE_MARKER:googleMode=null;break;case WPGMZA.DrawingManager.MODE_POLYGON:googleMode=google.maps.drawing.OverlayType.POLYGON;break;case WPGMZA.DrawingManager.MODE_POLYLINE:googleMode=google.maps.drawing.OverlayType.POLYLINE;break;case WPGMZA.DrawingManager.MODE_CIRCLE:googleMode=google.maps.drawing.OverlayType.CIRCLE;break;case WPGMZA.DrawingManager.MODE_RECTANGLE:googleMode=google.maps.drawing.OverlayType.RECTANGLE;break;case WPGMZA.DrawingManager.MODE_HEATMAP:case WPGMZA.DrawingManager.MODE_POINTLABEL:googleMode=null;break;case WPGMZA.DrawingManager.MODE_IMAGEOVERLAY:googleMode=google.maps.drawing.OverlayType.RECTANGLE;break;default:throw new Error("Invalid drawing mode")}this.googleDrawingManager.setDrawingMode(googleMode)},WPGMZA.GoogleDrawingManager.prototype.setOptions=function(options){this.googleDrawingManager.setOptions({polygonOptions:options,polylineOptions:options})},WPGMZA.GoogleDrawingManager.prototype.onVertexClicked=function(event){},WPGMZA.GoogleDrawingManager.prototype.onPolygonClosed=function(googlePolygon){var event=new WPGMZA.Event("polygonclosed");event.enginePolygon=googlePolygon,this.dispatchEvent(event)},WPGMZA.GoogleDrawingManager.prototype.onPolylineComplete=function(googlePolyline){var event=new WPGMZA.Event("polylinecomplete");event.enginePolyline=googlePolyline,this.dispatchEvent(event)},WPGMZA.GoogleDrawingManager.prototype.onCircleComplete=function(googleCircle){var event=new WPGMZA.Event("circlecomplete");event.engineCircle=googleCircle,this.dispatchEvent(event)},WPGMZA.GoogleDrawingManager.prototype.onRectangleComplete=function(googleRectangle){var event;this.mode===WPGMZA.DrawingManager.MODE_IMAGEOVERLAY?this.onImageoverlayComplete(googleRectangle):((event=new WPGMZA.Event("rectanglecomplete")).engineRectangle=googleRectangle,this.dispatchEvent(event))},WPGMZA.GoogleDrawingManager.prototype.onHeatmapPointAdded=function(googleMarker){var position=WPGMZA.LatLng.fromGoogleLatLng(googleMarker.getPosition()),googleMarker=(googleMarker.setMap(null),WPGMZA.Marker.createInstance()),image=(googleMarker.setPosition(position),{url:WPGMZA.imageFolderURL+"heatmap-point.png",origin:new google.maps.Point(0,0),anchor:new google.maps.Point(13,13)}),image=(googleMarker.googleMarker.setIcon(image),this.map.addMarker(googleMarker),new WPGMZA.Event("heatmappointadded"));image.position=position,this.trigger(image)},WPGMZA.GoogleDrawingManager.prototype.onImageoverlayComplete=function(rectangle){var event=new WPGMZA.Event("imageoverlaycomplete");event.engineImageoverlay={googleRectangle:rectangle},this.dispatchEvent(event)}}),jQuery(function($){WPGMZA.GoogleGeocoder=function(){},WPGMZA.GoogleGeocoder.prototype=Object.create(WPGMZA.Geocoder.prototype),WPGMZA.GoogleGeocoder.prototype.constructor=WPGMZA.GoogleGeocoder,WPGMZA.GoogleGeocoder.prototype.getLatLngFromAddress=function(options,callback){if(options&&options.address)return options.lat&&options.lng&&(latLng={lat:options.lat,lng:options.lng},callback([{geometry:{location:latLng},latLng:latLng,lat:latLng.lat,lng:latLng.lng,bounds:null}],WPGMZA.Geocoder.SUCCESS)),WPGMZA.isLatLngString(options.address)?WPGMZA.Geocoder.prototype.getLatLngFromAddress.call(this,options,callback):(options.country&&(options.componentRestrictions={country:options.country}),void(new google.maps.Geocoder).geocode(options,function(results,status){var bounds,location;status==google.maps.GeocoderStatus.OK?(location={lat:(location=results[0].geometry.location).lat(),lng:location.lng()},bounds=null,results[0].geometry.bounds&&(bounds=WPGMZA.LatLngBounds.fromGoogleLatLngBounds(results[0].geometry.bounds)),callback(results=[{geometry:{location:location},latLng:location,lat:location.lat,lng:location.lng,bounds:bounds}],WPGMZA.Geocoder.SUCCESS)):(location=WPGMZA.Geocoder.FAIL,status==google.maps.GeocoderStatus.ZERO_RESULTS&&(location=WPGMZA.Geocoder.ZERO_RESULTS),callback(null,location))}));var latLng;nativeStatus=WPGMZA.Geocoder.NO_ADDRESS,callback(null,nativeStatus)},WPGMZA.GoogleGeocoder.prototype.getAddressFromLatLng=function(options,callback){if(!options||!options.latLng)throw new Error("No latLng specified");var latLng=new WPGMZA.LatLng(options.latLng),geocoder=new google.maps.Geocoder,options=$.extend(options,{location:{lat:latLng.lat,lng:latLng.lng}});let fullResult=!1;options.fullResult&&(fullResult=!0,delete options.fullResult),delete options.latLng,geocoder.geocode(options,function(results,status){"OK"!==status&&callback(null,WPGMZA.Geocoder.FAIL),results&&results.length||callback([],WPGMZA.Geocoder.NO_RESULTS),fullResult?callback([results[0]],WPGMZA.Geocoder.SUCCESS):callback([results[0].formatted_address],WPGMZA.Geocoder.SUCCESS)})}}),jQuery(function($){WPGMZA.settings.engine&&"google-maps"!=WPGMZA.settings.engine||window.google&&window.google.maps&&(WPGMZA.GoogleHTMLOverlay=function(map){this.element=$("<div class='wpgmza-google-html-overlay'></div>"),this.visible=!0,this.position=new WPGMZA.LatLng,this.setMap(map.googleMap),this.wpgmzaMap=map},WPGMZA.GoogleHTMLOverlay.prototype=new google.maps.OverlayView,WPGMZA.GoogleHTMLOverlay.prototype.onAdd=function(){this.getPanes().overlayMouseTarget.appendChild(this.element[0])},WPGMZA.GoogleHTMLOverlay.prototype.onRemove=function(){this.element&&$(this.element).parent().length&&($(this.element).remove(),this.element=null)},WPGMZA.GoogleHTMLOverlay.prototype.draw=function(){this.updateElementPosition()},WPGMZA.GoogleHTMLOverlay.prototype.updateElementPosition=function(){var projection=this.getProjection();projection&&(projection=projection.fromLatLngToDivPixel(this.position.toGoogleLatLng()),$(this.element).css({left:projection.x,top:projection.y}))})}),jQuery(function($){var Parent;WPGMZA.GoogleInfoWindow=function(feature){Parent.call(this,feature),this.setFeature(feature)},WPGMZA.GoogleInfoWindow.Z_INDEX=99,Parent=WPGMZA.isProVersion()?WPGMZA.ProInfoWindow:WPGMZA.InfoWindow,WPGMZA.GoogleInfoWindow.prototype=Object.create(Parent.prototype),WPGMZA.GoogleInfoWindow.prototype.constructor=WPGMZA.GoogleInfoWindow,WPGMZA.GoogleInfoWindow.prototype.setFeature=function(feature){(this.feature=feature)instanceof WPGMZA.Marker?this.googleObject=feature.googleMarker:feature instanceof WPGMZA.Polygon?this.googleObject=feature.googlePolygon:feature instanceof WPGMZA.Polyline&&(this.googleObject=feature.googlePolyline)},WPGMZA.GoogleInfoWindow.prototype.createGoogleInfoWindow=function(){var self=this;this.googleInfoWindow||(this.googleInfoWindow=new google.maps.InfoWindow,this.googleInfoWindow.setZIndex(WPGMZA.GoogleInfoWindow.Z_INDEX),google.maps.event.addListener(this.googleInfoWindow,"domready",function(event){self.trigger("domready")}),google.maps.event.addListener(this.googleInfoWindow,"closeclick",function(event){self.state!=WPGMZA.InfoWindow.STATE_CLOSED&&(self.state=WPGMZA.InfoWindow.STATE_CLOSED,self.feature.map.trigger("infowindowclose"))}))},WPGMZA.GoogleInfoWindow.prototype.open=function(map,feature){var self=this;if(!Parent.prototype.open.call(this,map,feature))return!1;this.parent=map,this.createGoogleInfoWindow(),this.setFeature(feature),void 0!==feature._osDisableAutoPan&&(feature._osDisableAutoPan?(this.googleInfoWindow.setOptions({disableAutoPan:!0}),feature._osDisableAutoPan=!1):this.googleInfoWindow.setOptions({disableAutoPan:!1})),this.googleInfoWindow.open(this.feature.map.googleMap,this.googleObject);var intervalID,guid=WPGMZA.guid(),map=WPGMZA.isProVersion()?"":this.addEditButton(),feature="<div id='"+guid+"'>"+map+" "+this.content+"</div>";return this.googleInfoWindow.setContent(feature),intervalID=setInterval(function(event){(div=$("#"+guid)).length&&(clearInterval(intervalID),div[0].wpgmzaFeature=self.feature,div.addClass("wpgmza-infowindow"),self.element=div[0],self.trigger("infowindowopen"))},50),!0},WPGMZA.GoogleInfoWindow.prototype.close=function(){this.googleInfoWindow&&(WPGMZA.InfoWindow.prototype.close.call(this),this.googleInfoWindow.close())},WPGMZA.GoogleInfoWindow.prototype.setContent=function(html){Parent.prototype.setContent.call(this,html),this.content=html,this.createGoogleInfoWindow(),this.googleInfoWindow.setContent(html)},WPGMZA.GoogleInfoWindow.prototype.setOptions=function(options){Parent.prototype.setOptions.call(this,options),this.createGoogleInfoWindow(),this.googleInfoWindow.setOptions(options)}}),jQuery(function($){var Parent;WPGMZA.GoogleMap=function(element,options){var self=this;Parent.call(this,element,options),this.loadGoogleMap(),options?this.setOptions(options,!0):this.setOptions({},!0),google.maps.event.addListener(this.googleMap,"click",function(event){var wpgmzaEvent=new WPGMZA.Event("click");wpgmzaEvent.latLng={lat:event.latLng.lat(),lng:event.latLng.lng()},self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap,"rightclick",function(event){var wpgmzaEvent=new WPGMZA.Event("rightclick");wpgmzaEvent.latLng={lat:event.latLng.lat(),lng:event.latLng.lng()},self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap,"dragend",function(event){self.dispatchEvent("dragend")}),google.maps.event.addListener(this.googleMap,"zoom_changed",function(event){self.dispatchEvent("zoom_changed"),self.dispatchEvent("zoomchanged")}),google.maps.event.addListener(this.googleMap,"idle",function(event){self.onIdle(event)}),this.googleMap.getStreetView()&&(google.maps.event.addListener(this.googleMap.getStreetView(),"visible_changed",function(){var wpgmzaEvent=new WPGMZA.Event("streetview_visible_changed");wpgmzaEvent.visible=this.getVisible(),self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap.getStreetView(),"position_changed",function(){var wpgmzaEvent=new WPGMZA.Event("streetview_position_changed");const position=this.getPosition();position&&(wpgmzaEvent.latLng={lat:position.lat(),lng:position.lng()}),wpgmzaEvent.visible=this.getVisible(),self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap.getStreetView(),"pov_changed",function(){var wpgmzaEvent=new WPGMZA.Event("streetview_pov_changed"),pov=this.getPov();pov&&(wpgmzaEvent.pov={heading:pov.heading,pitch:pov.pitch}),wpgmzaEvent.visible=this.getVisible(),self.dispatchEvent(wpgmzaEvent)})),WPGMZA.isProVersion()||(this.trigger("init"),this.dispatchEvent("created"),WPGMZA.events.dispatchEvent({type:"mapcreated",map:this}),$(this.element).trigger("wpgooglemaps_loaded"))},WPGMZA.isProVersion()?(Parent=WPGMZA.ProMap,WPGMZA.GoogleMap.prototype=Object.create(WPGMZA.ProMap.prototype)):(Parent=WPGMZA.Map,WPGMZA.GoogleMap.prototype=Object.create(WPGMZA.Map.prototype)),WPGMZA.GoogleMap.prototype.constructor=WPGMZA.GoogleMap,WPGMZA.GoogleMap.parseThemeData=function(raw){var json;try{json=JSON.parse(raw)}catch(e){try{json=eval(raw)}catch(e){var str=raw,str=str.replace(/\\'/g,"'");str=str.replace(/\\"/g,'"'),str=str.replace(/\\0/g,"\0"),str=str.replace(/\\\\/g,"\\");try{json=eval(str)}catch(e){return console.warn("Couldn't parse theme data"),[]}}}return json},WPGMZA.GoogleMap.prototype.loadGoogleMap=function(){var self=this,options=this.settings.toGoogleMapsOptions();this.googleMap=new google.maps.Map(this.engineElement,options),google.maps.event.addListener(this.googleMap,"bounds_changed",function(){self.onBoundsChanged()}),1==this.settings.bicycle&&this.enableBicycleLayer(!0),1==this.settings.traffic&&this.enableTrafficLayer(!0),this.settings.transport_layer&&this.enablePublicTransportLayer(!0),this.showPointsOfInterest(this.settings.wpgmza_show_point_of_interest),$(this.engineElement).append($(this.element).find(".wpgmza-loader"))},WPGMZA.GoogleMap.prototype.setOptions=function(options,initializing){Parent.prototype.setOptions.call(this,options),options.scrollwheel&&delete options.scrollwheel,initializing?(initializing=$.extend(options,this.settings.toGoogleMapsOptions()),!(initializing=$.extend({},initializing)).center instanceof google.maps.LatLng&&(initializing.center instanceof WPGMZA.LatLng||"object"==typeof initializing.center)&&(initializing.center={lat:parseFloat(initializing.center.lat),lng:parseFloat(initializing.center.lng)}),this.settings.hide_point_of_interest&&(initializing.styles||(initializing.styles=[]),initializing.styles.push({featureType:"poi",elementType:"labels",stylers:[{visibility:"off"}]})),this.googleMap.setOptions(initializing)):this.googleMap.setOptions(options)},WPGMZA.GoogleMap.prototype.addMarker=function(marker){marker.googleMarker.setMap(this.googleMap),Parent.prototype.addMarker.call(this,marker)},WPGMZA.GoogleMap.prototype.removeMarker=function(marker){marker.googleMarker.setMap(null),Parent.prototype.removeMarker.call(this,marker)},WPGMZA.GoogleMap.prototype.addPolygon=function(polygon){polygon.googlePolygon.setMap(this.googleMap),Parent.prototype.addPolygon.call(this,polygon)},WPGMZA.GoogleMap.prototype.removePolygon=function(polygon){polygon.googlePolygon.setMap(null),Parent.prototype.removePolygon.call(this,polygon)},WPGMZA.GoogleMap.prototype.addPolyline=function(polyline){polyline.googlePolyline.setMap(this.googleMap),Parent.prototype.addPolyline.call(this,polyline)},WPGMZA.GoogleMap.prototype.removePolyline=function(polyline){polyline.googlePolyline.setMap(null),Parent.prototype.removePolyline.call(this,polyline)},WPGMZA.GoogleMap.prototype.addCircle=function(circle){circle.googleCircle.setMap(this.googleMap),Parent.prototype.addCircle.call(this,circle)},WPGMZA.GoogleMap.prototype.removeCircle=function(circle){circle.googleCircle.setMap(null),Parent.prototype.removeCircle.call(this,circle)},WPGMZA.GoogleMap.prototype.addRectangle=function(rectangle){rectangle.googleRectangle.setMap(this.googleMap),Parent.prototype.addRectangle.call(this,rectangle)},WPGMZA.GoogleMap.prototype.removeRectangle=function(rectangle){rectangle.googleRectangle.setMap(null),Parent.prototype.removeRectangle.call(this,rectangle)},WPGMZA.GoogleMap.prototype.getCenter=function(){var latLng=this.googleMap.getCenter();return{lat:latLng.lat(),lng:latLng.lng()}},WPGMZA.GoogleMap.prototype.setCenter=function(latLng){WPGMZA.Map.prototype.setCenter.call(this,latLng),latLng instanceof WPGMZA.LatLng?this.googleMap.setCenter({lat:latLng.lat,lng:latLng.lng}):this.googleMap.setCenter(latLng)},WPGMZA.GoogleMap.prototype.panTo=function(latLng){latLng instanceof WPGMZA.LatLng?this.googleMap.panTo({lat:latLng.lat,lng:latLng.lng}):this.googleMap.panTo(latLng)},WPGMZA.GoogleMap.prototype.getZoom=function(){return this.googleMap.getZoom()},WPGMZA.GoogleMap.prototype.setZoom=function(value){if(isNaN(value))throw new Error("Value must not be NaN");return this.googleMap.setZoom(parseInt(value))},WPGMZA.GoogleMap.prototype.getBounds=function(){var nativeBounds=new WPGMZA.LatLngBounds({});try{var bounds=this.googleMap.getBounds(),northEast=bounds.getNorthEast(),southWest=bounds.getSouthWest();nativeBounds.north=northEast.lat(),nativeBounds.south=southWest.lat(),nativeBounds.west=southWest.lng(),nativeBounds.east=northEast.lng(),nativeBounds.topLeft={lat:northEast.lat(),lng:southWest.lng()},nativeBounds.bottomRight={lat:southWest.lat(),lng:northEast.lng()}}catch(ex){}return nativeBounds},WPGMZA.GoogleMap.prototype.fitBounds=function(southWest,northEast){southWest instanceof WPGMZA.LatLng&&(southWest={lat:southWest.lat,lng:southWest.lng}),northEast instanceof WPGMZA.LatLng?northEast={lat:northEast.lat,lng:northEast.lng}:southWest instanceof WPGMZA.LatLngBounds&&(southWest={lat:(bounds=southWest).south,lng:bounds.west},northEast={lat:bounds.north,lng:bounds.east});var bounds=new google.maps.LatLngBounds(southWest,northEast);this.googleMap.fitBounds(bounds)},WPGMZA.GoogleMap.prototype.fitBoundsToVisibleMarkers=function(){for(var bounds=new google.maps.LatLngBounds,i=0;i<this.markers.length;i++)markers[i].getVisible()&&bounds.extend(markers[i].getPosition());this.googleMap.fitBounds(bounds)},WPGMZA.GoogleMap.prototype.enableBicycleLayer=function(enable){this.bicycleLayer||(this.bicycleLayer=new google.maps.BicyclingLayer),this.bicycleLayer.setMap(enable?this.googleMap:null)},WPGMZA.GoogleMap.prototype.enableTrafficLayer=function(enable){this.trafficLayer||(this.trafficLayer=new google.maps.TrafficLayer),this.trafficLayer.setMap(enable?this.googleMap:null)},WPGMZA.GoogleMap.prototype.enablePublicTransportLayer=function(enable){this.publicTransportLayer||(this.publicTransportLayer=new google.maps.TransitLayer),this.publicTransportLayer.setMap(enable?this.googleMap:null)},WPGMZA.GoogleMap.prototype.showPointsOfInterest=function(show){var text=$("textarea[name='theme_data']").val();text&&((text=JSON.parse(text)).push({featureType:"poi",stylers:[{visibility:show?"on":"off"}]}),this.googleMap.setOptions({styles:text}))},WPGMZA.GoogleMap.prototype.getMinZoom=function(){return parseInt(this.settings.min_zoom)},WPGMZA.GoogleMap.prototype.setMinZoom=function(value){this.googleMap.setOptions({minZoom:value,maxZoom:this.getMaxZoom()})},WPGMZA.GoogleMap.prototype.getMaxZoom=function(){return parseInt(this.settings.max_zoom)},WPGMZA.GoogleMap.prototype.setMaxZoom=function(value){this.googleMap.setOptions({minZoom:this.getMinZoom(),maxZoom:value})},WPGMZA.GoogleMap.prototype.latLngToPixels=function(latLng){var map=this.googleMap,latLng=new google.maps.LatLng({lat:parseFloat(latLng.lat),lng:parseFloat(latLng.lng)}),topRight=map.getProjection().fromLatLngToPoint(map.getBounds().getNorthEast()),bottomLeft=map.getProjection().fromLatLngToPoint(map.getBounds().getSouthWest()),scale=Math.pow(2,map.getZoom()),map=map.getProjection().fromLatLngToPoint(latLng);return{x:(map.x-bottomLeft.x)*scale,y:(map.y-topRight.y)*scale}},WPGMZA.GoogleMap.prototype.pixelsToLatLng=function(x,y){null==y&&("x"in x&&"y"in x?(y=x.y,x=x.x):console.warn("Y coordinate undefined in pixelsToLatLng (did you mean to pass 2 arguments?)"));var map=this.googleMap,topRight=map.getProjection().fromLatLngToPoint(map.getBounds().getNorthEast()),bottomLeft=map.getProjection().fromLatLngToPoint(map.getBounds().getSouthWest()),scale=Math.pow(2,map.getZoom()),x=new google.maps.Point(x/scale+bottomLeft.x,y/scale+topRight.y),bottomLeft=map.getProjection().fromPointToLatLng(x);return{lat:bottomLeft.lat(),lng:bottomLeft.lng()}},WPGMZA.GoogleMap.prototype.onElementResized=function(event){this.googleMap&&google.maps.event.trigger(this.googleMap,"resize")},WPGMZA.GoogleMap.prototype.enableAllInteractions=function(){var options={scrollwheel:!0,draggable:!0,disableDoubleClickZoom:!1};this.googleMap.setOptions(options)},WPGMZA.GoogleMap.prototype.openStreetView=function(options){if(this.googleMap.getStreetView()){if(options&&(options.position&&options.position instanceof WPGMZA.LatLng&&this.googleMap.getStreetView().setPosition(options.position.toGoogleLatLng()),options.heading||options.pitch)){const pov={};options.heading&&(pov.heading=parseFloat(options.heading)),options.pitch&&(pov.pitch=parseFloat(options.pitch)),this.googleMap.getStreetView().setPov(pov)}this.googleMap.getStreetView().setVisible(!0)}},WPGMZA.GoogleMap.prototype.closeStreetView=function(){this.googleMap.getStreetView()&&this.googleMap.getStreetView().setVisible(!1)},WPGMZA.GoogleMap.prototype.isFullScreen=function(){return!(WPGMZA.Map.prototype.isFullScreen.call(this)||!WPGMZA.isFullScreen()||parseInt(window.screen.height)!==parseInt(this.element.firstChild.offsetHeight))},WPGMZA.GoogleMap.prototype.onFullScreenChange=function(fullscreen){if(fullscreen&&!this._stackedComponentsMoved&&this.element.firstChild){const innerContainer=this.element.firstChild;$(this.element).find(".wpgmza-inner-stack").each(function(index,element){$(element).appendTo(innerContainer)}),this._stackedComponentsMoved=!0}}}),jQuery(function($){var Parent;WPGMZA.GoogleMarker=function(options){var self=this,settings=(Parent.call(this,options),{});if(options)for(var name in options)options[name]instanceof WPGMZA.LatLng?settings[name]=options[name].toGoogleLatLng():options[name]instanceof WPGMZA.Map||"icon"==name||(settings[name]=options[name]);this.googleMarker=new google.maps.Marker(settings),(this.googleMarker.wpgmzaMarker=this).googleFeature=this.googleMarker,this.googleMarker.setPosition(new google.maps.LatLng({lat:parseFloat(this.lat),lng:parseFloat(this.lng)})),this.anim&&this.googleMarker.setAnimation(this.anim),this.animation&&this.googleMarker.setAnimation(this.animation),google.maps.event.addListener(this.googleMarker,"click",function(){self.dispatchEvent("click"),self.dispatchEvent("select")}),google.maps.event.addListener(this.googleMarker,"mouseover",function(){self.dispatchEvent("mouseover")}),google.maps.event.addListener(this.googleMarker,"mouseout",function(){self.dispatchEvent("mouseout")}),google.maps.event.addListener(this.googleMarker,"dragend",function(){var googleMarkerPosition=self.googleMarker.getPosition();self.setPosition({lat:googleMarkerPosition.lat(),lng:googleMarkerPosition.lng()}),self.dispatchEvent({type:"dragend",latLng:self.getPosition()}),self.trigger("change")}),this.setOptions(settings),this.trigger("init")},Parent=WPGMZA.isProVersion()?WPGMZA.ProMarker:WPGMZA.Marker,WPGMZA.GoogleMarker.prototype=Object.create(Parent.prototype),WPGMZA.GoogleMarker.prototype.constructor=WPGMZA.GoogleMarker,Object.defineProperty(WPGMZA.GoogleMarker.prototype,"opacity",{get:function(){return this._opacity},set:function(value){this._opacity=value,this.googleMarker.setOpacity(value)}}),WPGMZA.GoogleMarker.prototype.setLabel=function(label){label?(this.googleMarker.setLabel({text:label}),this.googleMarker.getIcon()||this.googleMarker.setIcon(WPGMZA.settings.default_marker_icon)):this.googleMarker.setLabel(null)},WPGMZA.GoogleMarker.prototype.setPosition=function(latLng){Parent.prototype.setPosition.call(this,latLng),this.googleMarker.setPosition({lat:this.lat,lng:this.lng})},WPGMZA.GoogleMarker.prototype.updateOffset=function(){var self=this,icon=this.googleMarker.getIcon(),img=new Image,x=this._offset.x,y=this._offset.y,params="string"==typeof(icon=icon||WPGMZA.settings.default_marker_icon)?{url:icon}:icon;img.onload=function(){var defaultAnchor_x=img.width/2,defaultAnchor_y=img.height;params.anchor=new google.maps.Point(defaultAnchor_x-x,defaultAnchor_y-y),self.googleMarker.setIcon(params)},img.src=params.url},WPGMZA.GoogleMarker.prototype.setOptions=function(options){this.googleMarker.setOptions(options)},WPGMZA.GoogleMarker.prototype.setAnimation=function(animation){Parent.prototype.setAnimation.call(this,animation),this.googleMarker.setAnimation(animation)},WPGMZA.GoogleMarker.prototype.setVisible=function(visible){Parent.prototype.setVisible.call(this,visible),this.googleMarker.setVisible(!!visible)},WPGMZA.GoogleMarker.prototype.getVisible=function(visible){return this.googleMarker.getVisible()},WPGMZA.GoogleMarker.prototype.setDraggable=function(draggable){this.googleMarker.setDraggable(draggable)},WPGMZA.GoogleMarker.prototype.setOpacity=function(opacity){this.googleMarker.setOpacity(opacity)}}),jQuery(function($){WPGMZA.GoogleModernStoreLocatorCircle=function(map,settings){var self=this;WPGMZA.ModernStoreLocatorCircle.call(this,map,settings),this.intervalID=setInterval(function(){var mapSize={width:$(self.mapElement).width(),height:$(self.mapElement).height()};mapSize.width==self.mapSize.width&&mapSize.height==self.mapSize.height||(self.canvasLayer.resize_(),self.canvasLayer.draw(),self.mapSize=mapSize)},1e3),$(document).bind("webkitfullscreenchange mozfullscreenchange fullscreenchange",function(){self.canvasLayer.resize_(),self.canvasLayer.draw()})},WPGMZA.GoogleModernStoreLocatorCircle.prototype=Object.create(WPGMZA.ModernStoreLocatorCircle.prototype),WPGMZA.GoogleModernStoreLocatorCircle.prototype.constructor=WPGMZA.GoogleModernStoreLocatorCircle,WPGMZA.GoogleModernStoreLocatorCircle.prototype.initCanvasLayer=function(){var self=this;this.canvasLayer&&(this.canvasLayer.setMap(null),this.canvasLayer.setAnimate(!1)),this.canvasLayer=new CanvasLayer({map:this.map.googleMap,resizeHandler:function(event){self.onResize(event)},updateHandler:function(event){self.onUpdate(event)},animate:!0,resolutionScale:this.getResolutionScale()})},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setOptions=function(options){WPGMZA.ModernStoreLocatorCircle.prototype.setOptions.call(this,options),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setPosition=function(position){WPGMZA.ModernStoreLocatorCircle.prototype.setPosition.call(this,position),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setRadius=function(radius){WPGMZA.ModernStoreLocatorCircle.prototype.setRadius.call(this,radius),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getTransformedRadius=function(km){var spherical=google.maps.geometry.spherical,center=this.settings.center,equator=new WPGMZA.LatLng({lat:0,lng:0}),center=new WPGMZA.LatLng({lat:center.lat,lng:0}),equator=spherical.computeOffset(equator.toGoogleLatLng(),1e3*km,90),spherical=.006395*km*(spherical.computeOffset(center.toGoogleLatLng(),1e3*km,90).lng()/equator.lng());if(isNaN(spherical))throw new Error("here");return spherical},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getCanvasDimensions=function(){return{width:this.canvasLayer.canvas.width,height:this.canvasLayer.canvas.height}},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getWorldOriginOffset=function(){var position=this.map.googleMap.getProjection().fromLatLngToPoint(this.canvasLayer.getTopLeft());return{x:-position.x,y:-position.y}},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getCenterPixels=function(){var center=new WPGMZA.LatLng(this.settings.center);return this.map.googleMap.getProjection().fromLatLngToPoint(center.toGoogleLatLng())},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getContext=function(type){return this.canvasLayer.canvas.getContext("2d")},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getScale=function(){return Math.pow(2,this.map.getZoom())*this.getResolutionScale()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setVisible=function(visible){WPGMZA.ModernStoreLocatorCircle.prototype.setVisible.call(this,visible),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.destroy=function(){this.canvasLayer.setMap(null),this.canvasLayer=null,clearInterval(this.intervalID)}}),jQuery(function($){WPGMZA.GoogleModernStoreLocator=function(map_id){var map=this.map=WPGMZA.getMapByID(map_id),map_id=(WPGMZA.ModernStoreLocator.call(this,map_id),map.settings.wpgmza_store_locator_restrict);this.addressInput=$(this.element).find(".addressInput, #addressInput")[0],this.addressInput&&map_id&&map_id.length,this.map.googleMap.controls[google.maps.ControlPosition.TOP_CENTER].push(this.element)},WPGMZA.GoogleModernStoreLocator.prototype=Object.create(WPGMZA.ModernStoreLocator.prototype),WPGMZA.GoogleModernStoreLocator.prototype.constructor=WPGMZA.GoogleModernStoreLocator}),jQuery(function($){var Parent;WPGMZA.GooglePointlabel=function(options,pointFeature){Parent.call(this,options,pointFeature),pointFeature&&pointFeature.textFeature?this.textFeature=pointFeature.textFeature:this.textFeature=new WPGMZA.Text.createInstance({text:"",map:this.map,position:this.getPosition()}),(this.googleFeature=this).setOptions(options)},Parent=WPGMZA.isProVersion()?WPGMZA.ProPointlabel:WPGMZA.Pointlabel,WPGMZA.extend(WPGMZA.GooglePointlabel,Parent),WPGMZA.GooglePointlabel.prototype.setOptions=function(options){options.name&&this.textFeature.setText(options.name)}}),jQuery(function($){var Parent;WPGMZA.GooglePolygon=function(options,googlePolygon){var self=this;Parent.call(this,options=options||{},googlePolygon),this.googlePolygon=googlePolygon||new google.maps.Polygon,this.googleFeature=this.googlePolygon,options&&options.polydata&&this.googlePolygon.setOptions({paths:this.parseGeometry(options.polydata)}),this.googlePolygon.wpgmzaPolygon=this,options&&this.setOptions(options),google.maps.event.addListener(this.googlePolygon,"click",function(){self.dispatchEvent({type:"click"})})},Parent=WPGMZA.isProVersion()?WPGMZA.ProPolygon:WPGMZA.Polygon,WPGMZA.GooglePolygon.prototype=Object.create(Parent.prototype),WPGMZA.GooglePolygon.prototype.constructor=WPGMZA.GooglePolygon,WPGMZA.GooglePolygon.prototype.updateNativeFeature=function(){this.googlePolygon.setOptions(this.getScalarProperties())},WPGMZA.GooglePolygon.prototype.getEditable=function(){return this.googlePolygon.getOptions().editable},WPGMZA.GooglePolygon.prototype.setEditable=function(value){var self=this;this.googlePolygon.setOptions({editable:value}),value&&(this.googlePolygon.getPaths().forEach(function(path,index){["insert_at","remove_at","set_at"].forEach(function(name){google.maps.event.addListener(path,name,function(){self.trigger("change")})})}),google.maps.event.addListener(this.googlePolygon,"dragend",function(event){self.trigger("change")}),google.maps.event.addListener(this.googlePolygon,"click",function(event){WPGMZA.altKeyDown&&(this.getPath().removeAt(event.vertex),self.trigger("change"))}))},WPGMZA.GooglePolygon.prototype.setDraggable=function(value){this.googlePolygon.setDraggable(value)},WPGMZA.GooglePolygon.prototype.getGeometry=function(){for(var result=[],path=this.googlePolygon.getPath(),i=0;i<path.getLength();i++){var latLng=path.getAt(i);result.push({lat:latLng.lat(),lng:latLng.lng()})}return result}}),jQuery(function($){WPGMZA.GooglePolyline=function(options,googlePolyline){var self=this;WPGMZA.Polyline.call(this,options,googlePolyline),this.googlePolyline=googlePolyline||new google.maps.Polyline(this.settings),this.googleFeature=this.googlePolyline,options&&options.polydata&&(googlePolyline=this.parseGeometry(options.polydata),this.googlePolyline.setPath(googlePolyline)),this.googlePolyline.wpgmzaPolyline=this,options&&this.setOptions(options),google.maps.event.addListener(this.googlePolyline,"click",function(){self.dispatchEvent({type:"click"})})},WPGMZA.GooglePolyline.prototype=Object.create(WPGMZA.Polyline.prototype),WPGMZA.GooglePolyline.prototype.constructor=WPGMZA.GooglePolyline,WPGMZA.GooglePolyline.prototype.updateNativeFeature=function(){this.googlePolyline.setOptions(this.getScalarProperties())},WPGMZA.GooglePolyline.prototype.setEditable=function(value){var path,self=this;this.googlePolyline.setOptions({editable:value}),value&&(path=this.googlePolyline.getPath(),["insert_at","remove_at","set_at"].forEach(function(name){google.maps.event.addListener(path,name,function(){self.trigger("change")})}),google.maps.event.addListener(this.googlePolyline,"dragend",function(event){self.trigger("change")}),google.maps.event.addListener(this.googlePolyline,"click",function(event){WPGMZA.altKeyDown&&(this.getPath().removeAt(event.vertex),self.trigger("change"))}))},WPGMZA.GooglePolyline.prototype.setDraggable=function(value){this.googlePolyline.setOptions({draggable:value})},WPGMZA.GooglePolyline.prototype.getGeometry=function(){for(var result=[],path=this.googlePolyline.getPath(),i=0;i<path.getLength();i++){var latLng=path.getAt(i);result.push({lat:latLng.lat(),lng:latLng.lng()})}return result}}),jQuery(function($){var Parent=WPGMZA.Rectangle;WPGMZA.GoogleRectangle=function(options,googleRectangle){var self=this;Parent.call(this,options=options||{},googleRectangle),googleRectangle?(this.googleRectangle=googleRectangle,this.cornerA=options.cornerA=new WPGMZA.LatLng({lat:googleRectangle.getBounds().getNorthEast().lat(),lng:googleRectangle.getBounds().getSouthWest().lng()}),this.cornerB=options.cornerB=new WPGMZA.LatLng({lat:googleRectangle.getBounds().getSouthWest().lat(),lng:googleRectangle.getBounds().getNorthEast().lng()})):(this.googleRectangle=new google.maps.Rectangle,this.googleRectangle.wpgmzaRectangle=this),this.googleFeature=this.googleRectangle,options&&this.setOptions(options),google.maps.event.addListener(this.googleRectangle,"click",function(){self.dispatchEvent({type:"click"})})},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProRectangle),WPGMZA.GoogleRectangle.prototype=Object.create(Parent.prototype),WPGMZA.GoogleRectangle.prototype.constructor=WPGMZA.GoogleRectangle,WPGMZA.GoogleRectangle.prototype.getBounds=function(){return WPGMZA.LatLngBounds.fromGoogleLatLngBounds(this.googleRectangle.getBounds())},WPGMZA.GoogleRectangle.prototype.setVisible=function(visible){this.googleRectangle.setVisible(!!visible)},WPGMZA.GoogleRectangle.prototype.setDraggable=function(value){this.googleRectangle.setDraggable(!!value)},WPGMZA.GoogleRectangle.prototype.setEditable=function(value){var self=this;this.googleRectangle.setEditable(!!value),value&&google.maps.event.addListener(this.googleRectangle,"bounds_changed",function(event){self.trigger("change")})},WPGMZA.GoogleRectangle.prototype.setOptions=function(options){WPGMZA.Rectangle.prototype.setOptions.apply(this,arguments),options.cornerA&&options.cornerB&&(this.cornerA=new WPGMZA.LatLng(options.cornerA),this.cornerB=new WPGMZA.LatLng(options.cornerB))},WPGMZA.GoogleRectangle.prototype.updateNativeFeature=function(){var googleOptions=this.getScalarProperties(),north=parseFloat(this.cornerA.lat),west=parseFloat(this.cornerA.lng),south=parseFloat(this.cornerB.lat),east=parseFloat(this.cornerB.lng);north&&west&&south&&east&&(googleOptions.bounds={north:north,west:west,south:south,east:east}),this.googleRectangle.setOptions(googleOptions)}}),jQuery(function($){WPGMZA.GoogleText=function(options){WPGMZA.Text.apply(this,arguments),this.overlay=new WPGMZA.GoogleTextOverlay(options)},WPGMZA.extend(WPGMZA.GoogleText,WPGMZA.Text)}),jQuery(function($){WPGMZA.GoogleTextOverlay=function(options){this.element=$("<div class='wpgmza-google-text-overlay'><div class='wpgmza-inner'></div></div>"),(options=options||{}).position&&(this.position=options.position),options.text&&this.element.find(".wpgmza-inner").text(options.text),options.map&&this.setMap(options.map.googleMap)},window.google&&google.maps&&google.maps.OverlayView&&(WPGMZA.GoogleTextOverlay.prototype=new google.maps.OverlayView),WPGMZA.GoogleTextOverlay.prototype.onAdd=function(){var position=this.getProjection().fromLatLngToDivPixel(this.position.toGoogleLatLng());this.element.css({position:"absolute",left:position.x+"px",top:position.y+"px",minWidth:"200px"}),this.getPanes().floatPane.appendChild(this.element[0])},WPGMZA.GoogleTextOverlay.prototype.draw=function(){var position=this.getProjection().fromLatLngToDivPixel(this.position.toGoogleLatLng());this.element.css({position:"absolute",left:position.x+"px",top:position.y+"px",minWidth:"200px"})},WPGMZA.GoogleTextOverlay.prototype.onRemove=function(){this.element.remove()},WPGMZA.GoogleTextOverlay.prototype.hide=function(){this.element.hide()},WPGMZA.GoogleTextOverlay.prototype.show=function(){this.element.show()},WPGMZA.GoogleTextOverlay.prototype.toggle=function(){this.element.is(":visible")?this.element.hide():this.element.show()},WPGMZA.GoogleTextOverlay.prototype.setPosition=function(position){this.position=position},WPGMZA.GoogleTextOverlay.prototype.setText=function(text){this.element.find(".wpgmza-inner").text(text)},WPGMZA.GoogleTextOverlay.prototype.setFontSize=function(size){size=parseInt(size),this.element.find(".wpgmza-inner").css("font-size",size+"px")},WPGMZA.GoogleTextOverlay.prototype.setFillColor=function(color){color.match(/^#/)||(color="#"+color),this.element.find(".wpgmza-inner").css("color",color)},WPGMZA.GoogleTextOverlay.prototype.setLineColor=function(color){color.match(/^#/)||(color="#"+color),this.element.find(".wpgmza-inner").css("--wpgmza-color-white",color)},WPGMZA.GoogleTextOverlay.prototype.setOpacity=function(opacity){1<(opacity=parseFloat(opacity))?opacity=1:opacity<0&&(opacity=0),this.element.find(".wpgmza-inner").css("opacity",opacity)},WPGMZA.GoogleTextOverlay.prototype.remove=function(){this.element&&this.element.remove()}}),jQuery(function($){"google-maps"!=WPGMZA.settings.engine||WPGMZA.googleAPIStatus&&"USER_CONSENT_NOT_GIVEN"==WPGMZA.googleAPIStatus.code||(WPGMZA.GoogleVertexContextMenu=function(mapEditPage){var self=this;this.mapEditPage=mapEditPage,this.element=document.createElement("div"),this.element.className="wpgmza-vertex-context-menu",this.element.innerHTML="Delete",google.maps.event.addDomListener(this.element,"click",function(event){return self.removeVertex(),event.preventDefault(),event.stopPropagation(),!1})},WPGMZA.GoogleVertexContextMenu.prototype=new google.maps.OverlayView,WPGMZA.GoogleVertexContextMenu.prototype.onAdd=function(){var self=this,map=this.getMap();this.getPanes().floatPane.appendChild(this.element),this.divListener=google.maps.event.addDomListener(map.getDiv(),"mousedown",function(e){e.target!=self.element&&self.close()},!0)},WPGMZA.GoogleVertexContextMenu.prototype.onRemove=function(){google.maps.event.removeListener(this.divListener),this.element.parentNode.removeChild(this.element),this.set("position"),this.set("path"),this.set("vertex")},WPGMZA.GoogleVertexContextMenu.prototype.open=function(map,path,vertex){this.set("position",path.getAt(vertex)),this.set("path",path),this.set("vertex",vertex),this.setMap(map),this.draw()},WPGMZA.GoogleVertexContextMenu.prototype.close=function(){this.setMap(null)},WPGMZA.GoogleVertexContextMenu.prototype.draw=function(){var position=this.get("position"),projection=this.getProjection();position&&projection&&(projection=projection.fromLatLngToDivPixel(position),this.element.style.top=projection.y+"px",this.element.style.left=projection.x+"px")},WPGMZA.GoogleVertexContextMenu.prototype.removeVertex=function(){var path=this.get("path"),vertex=this.get("vertex");path&&null!=vertex&&path.removeAt(vertex),this.close()})}),jQuery(function($){WPGMZA.FeaturePanel=function(element,mapEditPage){var self=this;WPGMZA.EventDispatcher.apply(this,arguments),this.map=mapEditPage.map,this.drawingManager=mapEditPage.drawingManager,this.writersblock=!1,this.feature=null,this.element=element,this.initDefaults(),this.setMode(WPGMZA.FeaturePanel.MODE_ADD),this.drawingInstructionsElement=$(this.element).find(".wpgmza-feature-drawing-instructions"),this.drawingInstructionsElement.detach(),this.editingInstructionsElement=$(this.element).find(".wpgmza-feature-editing-instructions"),this.editingInstructionsElement.detach(),$("#wpgmaps_tabs_markers").on("tabsactivate",function(event,ui){$.contains(ui.newPanel[0],self.element[0])&&self.onTabActivated(event)}),$("#wpgmaps_tabs_markers").on("tabsactivate",function(event,ui){$.contains(ui.oldPanel[0],self.element[0])&&self.onTabDeactivated(event)}),$(".grouping").on("feature-block-opened",function(event){$(event.currentTarget).data("feature")===self.featureType?self.onTabActivated(event):self.onTabDeactivated(event)}),$(".grouping").on("feature-block-closed",function(event){self.onTabDeactivated(event),mapEditPage.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE)}),$(document.body).on("click","[data-edit-"+this.featureType+"-id]",function(event){self.onEditFeature(event)}),$(document.body).on("click","[data-delete-"+this.featureType+"-id]",function(event){self.onDeleteFeature(event)}),$(this.element).find(".wpgmza-save-feature").on("click",function(event){self.onSave(event)}),this.drawingManager.on(self.drawingManagerCompleteEvent,function(event){self.onDrawingComplete(event)}),this.drawingManager.on("drawingmodechanged",function(event){self.onDrawingModeChanged(event)}),$(this.element).on("change input",function(event){self.onPropertyChanged(event)})},WPGMZA.extend(WPGMZA.FeaturePanel,WPGMZA.EventDispatcher),WPGMZA.FeaturePanel.MODE_ADD="add",WPGMZA.FeaturePanel.MODE_EDIT="edit",WPGMZA.FeaturePanel.prevEditableFeature=null,Object.defineProperty(WPGMZA.FeaturePanel.prototype,"featureType",{get:function(){return $(this.element).attr("data-wpgmza-feature-type")}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"drawingManagerCompleteEvent",{get:function(){return this.featureType+"complete"}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"featureDataTable",{get:function(){return $("[data-wpgmza-datatable][data-wpgmza-feature-type='"+this.featureType+"']")[0].wpgmzaDataTable}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"featureAccordion",{get:function(){return $(this.element).closest(".wpgmza-accordion")}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"map",{get:function(){return WPGMZA.mapEditPage.map}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"mode",{get:function(){return this._mode}}),WPGMZA.FeaturePanel.prototype.initPreloader=function(){this.preloader||(this.preloader=$(WPGMZA.preloaderHTML),this.preloader.hide(),$(this.element).append(this.preloader))},WPGMZA.FeaturePanel.prototype.initDataTable=function(){var el=$(this.element).find("[data-wpgmza-datatable][data-wpgmza-rest-api-route]");this[this.featureType+"AdminDataTable"]=new WPGMZA.AdminFeatureDataTable(el)},WPGMZA.FeaturePanel.prototype.initDefaults=function(){$(this.element).find("[data-ajax-name]:not([type='radio'])").each(function(index,el){var val=$(el).val();val&&$(el).attr("data-default-value",val)})},WPGMZA.FeaturePanel.prototype.setCaptionType=function(type,id){var icons={add:"fa-plus-circle",save:"fa-pencil-square-o"};switch(type){case WPGMZA.FeaturePanel.MODE_ADD:case WPGMZA.FeaturePanel.MODE_EDIT:this.featureAccordion.find("[data-add-caption][data-edit-caption]").each(function(index,el){var text=$(el).attr("data-"+type+"-caption"),icon=$(el).find("i.fa");id&&(text+=" "+id),$(el).text(text),icon.length&&((icon=$("<i class='fa' aria-hidden='true'></i>")).addClass(icons[type]),$(el).prepend(" "),$(el).prepend(icon))}),this.sidebarTriggerDelegate("feature-caption-loaded");break;default:throw new Error("Invalid type")}},WPGMZA.FeaturePanel.prototype.setMode=function(type,id){this._mode=type,this.setCaptionType(type,id)},WPGMZA.FeaturePanel.prototype.setTargetFeature=function(feature){var prev,self=this;WPGMZA.FeaturePanel.prevEditableFeature&&((prev=WPGMZA.FeaturePanel.prevEditableFeature).setEditable(!1),prev.setDraggable(!1),prev.off("change")),feature?(feature.setEditable(!0),feature.setDraggable(!0),feature.on("change",function(event){self.onFeatureChanged(event)}),this.setMode(WPGMZA.FeaturePanel.MODE_EDIT),this.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.showInstructions()):this.setMode(WPGMZA.FeaturePanel.MODE_ADD),this.feature=WPGMZA.FeaturePanel.prevEditableFeature=feature},WPGMZA.FeaturePanel.prototype.reset=function(){$(this.element).find("[data-ajax-name]:not([data-ajax-name='map_id']):not([type='color']):not([type='checkbox']):not([type='radio'])").val(""),$(this.element).find("select[data-ajax-name]>option:first-child").prop("selected",!0),$(this.element).find("[data-ajax-name='id']").val("-1"),$(this.element).find("input[type='checkbox']").prop("checked",!1),WPGMZA.InternalEngine.isLegacy()?tinyMCE.get("wpgmza-description-editor")?tinyMCE.get("wpgmza-description-editor").setContent(""):$("#wpgmza-description-editor").val(""):("undefined"!=typeof WritersBlock&&0!=this.writersblock&&this.writersblock.ready?this.writersblock.setContent(""):$("#wpgmza-description-editor").val(""),$(this.element).find("input.wpgmza-color-input").each(function(){this.wpgmzaColorInput&&this.wpgmzaColorInput.parseColor($(this).data("default-value")||this.value)})),$("#wpgmza-description-editor").val(""),$(this.element).find(".wpgmza-image-single-input").trigger("change"),this.showPreloader(!1),this.setMode(WPGMZA.FeaturePanel.MODE_ADD),$(this.element).find("[data-ajax-name][data-default-value]").each(function(index,el){$(el).val($(el).data("default-value"))})},WPGMZA.FeaturePanel.prototype.select=function(arg){var id,expectedBaseClass,self=this;if(this.reset(),$.isNumeric(arg))id=arg;else{if(expectedBaseClass=WPGMZA[WPGMZA.capitalizeWords(this.featureType)],!(feature instanceof expectedBaseClass))throw new Error("Invalid feature type for this panel");id=arg.id}this.showPreloader(!0),this.sidebarTriggerDelegate("edit"),WPGMZA.InternalEngine.isLegacy()&&WPGMZA.animateScroll($(".wpgmza_map")),WPGMZA.restAPI.call("/"+this.featureType+"s/"+id+"?skip_cache=1",{success:function(data,status,xhr){var functionSuffix=WPGMZA.capitalizeWords(self.featureType),functionSuffix=self.map["get"+functionSuffix+"ByID"](id);self.populate(data),self.showPreloader(!1),self.setMode(WPGMZA.FeaturePanel.MODE_EDIT,id),self.setTargetFeature(functionSuffix)}})},WPGMZA.FeaturePanel.prototype.showPreloader=function(show){this.initPreloader(),0==arguments.length||show?(this.preloader.fadeIn(),this.element.addClass("wpgmza-loading")):(this.preloader.fadeOut(),this.element.removeClass("wpgmza-loading"))},WPGMZA.FeaturePanel.prototype.populate=function(data){var value,target,name;for(name in data)switch(target=$(this.element).find("[data-ajax-name='"+name+"']"),value=data[name],(target.attr("type")||"").toLowerCase()){case"checkbox":case"radio":target.prop("checked",1==data[name]);break;case"color":value.match(/^#/)||(value="#"+value);default:if("object"==typeof value&&(value=JSON.stringify(value)),$(this.element).find("[data-ajax-name='"+name+"']:not(select)").val(value),$(this.element).find("[data-ajax-name='"+name+"']:not(select)").hasClass("wpgmza-color-input")){let colorInput=$(this.element).find("[data-ajax-name='"+name+"']:not(select)").get(0);colorInput.wpgmzaColorInput&&colorInput.wpgmzaColorInput.parseColor(colorInput.value)}if($(this.element).find("[data-ajax-name='"+name+"']:not(select)").hasClass("wpgmza-image-single-input")){let imageInputSingle=$(this.element).find("[data-ajax-name='"+name+"']:not(select)").get(0);imageInputSingle.wpgmzaImageInputSingle&&imageInputSingle.wpgmzaImageInputSingle.parseImage(imageInputSingle.value)}$(this.element).find("select[data-ajax-name='"+name+"']").each(function(index,el){"string"==typeof value&&0==data[name].length||$(el).val(value)})}},WPGMZA.FeaturePanel.prototype.serializeFormData=function(){var fields=$(this.element).find("[data-ajax-name]"),data={};return fields.each(function(index,el){var type="text";switch(type=$(el).attr("type")?$(el).attr("type").toLowerCase():type){case"checkbox":data[$(el).attr("data-ajax-name")]=$(el).prop("checked")?1:0;break;case"radio":$(el).prop("checked")&&(data[$(el).attr("data-ajax-name")]=$(el).val());break;default:data[$(el).attr("data-ajax-name")]=$(el).val()}}),data},WPGMZA.FeaturePanel.prototype.discardChanges=function(){var feature;this.feature&&(feature=this.feature,this.setTargetFeature(null),feature&&feature.map&&(this.map["remove"+WPGMZA.capitalizeWords(this.featureType)](feature),-1<feature.id&&this.updateFeatureByID(feature.id)))},WPGMZA.FeaturePanel.prototype.updateFeatureByID=function(id){var feature,self=this,route="/"+this.featureType+"s/",functionSuffix=WPGMZA.capitalizeWords(self.featureType),getByIDFunction="get"+functionSuffix+"ByID",removeFunction="remove"+functionSuffix,addFunction="add"+functionSuffix;WPGMZA.restAPI.call(route+id,{success:function(data,status,xhr){(feature=self.map[getByIDFunction](id))&&self.map[removeFunction](feature),feature=WPGMZA[WPGMZA.capitalizeWords(self.featureType)].createInstance(data),self.map[addFunction](feature)}})},WPGMZA.FeaturePanel.prototype.showInstructions=function(){this.mode===WPGMZA.FeaturePanel.MODE_ADD?WPGMZA.InternalEngine.isLegacy()?($(this.map.element).append(this.drawingInstructionsElement),$(this.drawingInstructionsElement).hide().fadeIn()):$(this.element).prepend(this.drawingInstructionsElement):WPGMZA.InternalEngine.isLegacy()?($(this.map.element).append(this.editingInstructionsElement),$(this.editingInstructionsElement).hide().fadeIn()):$(this.element).prepend(this.editingInstructionsElement)},WPGMZA.FeaturePanel.prototype.onTabActivated=function(){var featureString;this.reset(),this.drawingManager.setDrawingMode(this.featureType),this.onAddFeature(event),WPGMZA.InternalEngine.isLegacy()&&($(".wpgmza-table-container-title").hide(),$(".wpgmza-table-container").hide(),featureString=this.featureType.charAt(0).toUpperCase()+this.featureType.slice(1),$("#wpgmza-table-container-"+featureString).show(),$("#wpgmza-table-container-title-"+featureString).show())},WPGMZA.FeaturePanel.prototype.onTabDeactivated=function(){this.discardChanges(),this.setTargetFeature(null)},WPGMZA.FeaturePanel.prototype.onAddFeature=function(event){this.drawingManager.setDrawingMode(this.featureType)},WPGMZA.FeaturePanel.prototype.onEditFeature=function(event){var name="data-edit-"+this.featureType+"-id",event=$(event.currentTarget).attr(name);this.discardChanges(),this.select(event)},WPGMZA.FeaturePanel.prototype.onDeleteFeature=function(event){var self=this,name="data-delete-"+this.featureType+"-id",event=$(event.currentTarget).attr(name),name="/"+this.featureType+"s/",feature=this.map["get"+WPGMZA.capitalizeWords(this.featureType)+"ByID"](event);confirm(WPGMZA.localized_strings.general_delete_prompt_text)&&(this.featureDataTable.dataTable.processing(!0),WPGMZA.restAPI.call(name+event,{method:"DELETE",success:function(data,status,xhr){self.map["remove"+WPGMZA.capitalizeWords(self.featureType)](feature),self.featureDataTable.reload()}}))},WPGMZA.FeaturePanel.prototype.onDrawingModeChanged=function(event){$(this.drawingInstructionsElement).detach(),$(this.editingInstructionsElement).detach(),this.drawingManager.mode==this.featureType&&this.showInstructions()},WPGMZA.FeaturePanel.prototype.onDrawingComplete=function(event){var event=event["engine"+WPGMZA.capitalizeWords(this.featureType)],formData=this.serializeFormData(),geometryField=$(this.element).find("textarea[data-ajax-name$='data']"),formData=(delete formData.polydata,WPGMZA[WPGMZA.capitalizeWords(this.featureType)].createInstance(formData,event));this.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.map["add"+WPGMZA.capitalizeWords(this.featureType)](formData),this.setTargetFeature(formData),geometryField.length&&geometryField.val(JSON.stringify(formData.getGeometry())),this.featureType},WPGMZA.FeaturePanel.prototype.onPropertyChanged=function(event){var feature=this.feature;feature&&(feature._dirtyFields||(feature._dirtyFields=[]),$(this.element).find(":input[data-ajax-name]").each(function(index,el){var key=$(el).attr("data-ajax-name");feature[key]&&-1===feature._dirtyFields.indexOf(key)&&feature[key]!==$(el).val()&&feature._dirtyFields.push(key),feature[key]=$(el).val()}),feature.updateNativeFeature())},WPGMZA.FeaturePanel.prototype.onFeatureChanged=function(event){var geometryField=$(this.element).find("textarea[data-ajax-name$='data']");geometryField.length&&geometryField.val(JSON.stringify(this.feature.getGeometry()))},WPGMZA.FeaturePanel.prototype.onSave=function(event){WPGMZA.EmbeddedMedia.detatchAll();var self=this,id=$(self.element).find("[data-ajax-name='id']").val(),data=this.serializeFormData(),route="/"+this.featureType+"s/",isNew=-1==id;"circle"!=this.featureType||data.center?"rectangle"!=this.featureType||data.cornerA?"polygon"!=this.featureType||data.polydata?"polyline"!=this.featureType||data.polydata?(isNew||(route+=id),WPGMZA.mapEditPage.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.showPreloader(!0),self.sidebarTriggerDelegate("busy"),WPGMZA.restAPI.call(route,{method:"POST",data:data,success:function(data,status,xhr){var functionSuffix=WPGMZA.capitalizeWords(self.featureType),removeFunction="remove"+functionSuffix,addFunction="add"+functionSuffix;(functionSuffix=self.map["get"+functionSuffix+"ByID"](id))&&self.map[removeFunction](functionSuffix),self.setTargetFeature(null),self.showPreloader(!1),functionSuffix=WPGMZA[WPGMZA.capitalizeWords(self.featureType)].createInstance(data),self.map[addFunction](functionSuffix),self.featureDataTable.reload(),self.onTabActivated(event),self.reset(),isNew?self.sidebarTriggerDelegate("created"):self.sidebarTriggerDelegate("saved"),WPGMZA.notification(WPGMZA.capitalizeWords(self.featureType)+" "+(isNew?"Added":"Saved"))}})):alert(WPGMZA.localized_strings.no_shape_polyline):alert(WPGMZA.localized_strings.no_shape_polygon):alert(WPGMZA.localized_strings.no_shape_rectangle):alert(WPGMZA.localized_strings.no_shape_circle)},WPGMZA.FeaturePanel.prototype.sidebarTriggerDelegate=function(type){type="sidebar-delegate-"+type;$(this.element).trigger({type:type,feature:this.featureType})},WPGMZA.FeaturePanel.prototype.initWritersBlock=function(element){!element||WPGMZA.InternalEngine.isLegacy()||"undefined"==typeof WritersBlock||(this.writersblock=new WritersBlock(element,this.getWritersBlockConfig()),this.writersblock.elements&&this.writersblock.elements.editor&&($(this.writersblock.elements.editor).on("click",".wpgmza-embedded-media",event=>{event.stopPropagation(),event.currentTarget&&(event.currentTarget.wpgmzaEmbeddedMedia||(event.currentTarget.wpgmzaEmbeddedMedia=WPGMZA.EmbeddedMedia.createInstance(event.currentTarget,this.writersblock.elements.editor)),event.currentTarget.wpgmzaEmbeddedMedia.onSelect())}),$(this.writersblock.elements.editor).on("media_resized",()=>{this.writersblock.onEditorChange()})))},WPGMZA.FeaturePanel.prototype.getWritersBlockConfig=function(){return{customTools:[{tag:"shared-blocks",tools:{"custom-media":{icon:"fa fa-file-image-o",title:"Upload Media",action:editor=>{"undefined"!=typeof wp&&void 0!==wp.media&&void 0!==WPGMZA.openMediaDialog&&WPGMZA.openMediaDialog((mediaId,mediaUrl,media)=>{if(mediaUrl)if(media.type)switch(media.type){case"image":editor.writeHtml(`<img class='wpgmza-embedded-media' src='${mediaUrl}' />`);break;case"video":editor.writeHtml(`<video class='wpgmza-embedded-media' controls src='${mediaUrl}'></video>`);break;case"audio":editor.writeHtml(`<audio controls src='${mediaUrl}'></audio>`)}else WPGMZA.notification("We couldn't determine the type of media being added")},{title:"Select media",button:{text:"Add media"},multiple:!1,library:{type:["video","image","audio"]}})}},"code-editor":{icon:"fa fa-code",title:"Code Editor (HTML)",action:editor=>{if(editor._codeEditorActive){if(editor.elements._codeEditor){editor.elements.editor.classList.remove("wpgmza-hidden"),editor.elements._codeEditor.classList.add("wpgmza-hidden");let toolbarItems=editor.elements.toolbar.querySelectorAll("a.tool");for(let tool of toolbarItems)"codeeditor"!==tool.getAttribute("data-value")?tool.classList.remove("wpgmza-writersblock-disabled"):tool.classList.remove("wpgmza-writersblock-hold-state");$(editor.elements._codeEditor).trigger("wpgmza-writersblock-code-edited")}editor._codeEditorActive=!1}else{var tool;editor.elements._codeEditor||(editor.elements._codeEditor=editor.createElement("textarea",["writersblock-wpgmza-code-editor"]),editor.elements._codeEditor.setAttribute("placeholder","\x3c!-- Add HTML Here --\x3e"),editor.elements.wrap.appendChild(editor.elements._codeEditor),editor.elements._codeEditor.__editor=editor,$(editor.elements._codeEditor).on("wpgmza-writersblock-code-edited",function(){const target=$(this).get(0);if(target.__editor){let editedHtml=target.__editor.elements._codeEditor.value;editedHtml=editedHtml.replaceAll("\n","");const validator=document.createElement("div");validator.innerHTML=editedHtml,validator.innerHTML===editedHtml&&(target.__editor.elements.editor.innerHTML=validator.innerHTML,target.__editor.onEditorChange())}}),$(editor.elements._codeEditor).on("change input",function(){$(this).trigger("wpgmza-writersblock-code-edited")})),editor.elements.editor.classList.add("wpgmza-hidden"),editor.elements._codeEditor.classList.remove("wpgmza-hidden");for(tool of editor.elements.toolbar.querySelectorAll("a.tool"))"codeeditor"!==tool.getAttribute("data-value")?tool.classList.add("wpgmza-writersblock-disabled"):tool.classList.add("wpgmza-writersblock-hold-state");if(editor.elements.editor.innerHTML&&0<editor.elements.editor.innerHTML.trim().length){let sourceHtml=editor.elements.editor.innerHTML;sourceHtml=sourceHtml.replaceAll(/<\/(\w+)>/g,"</$1>\n"),editor.elements._codeEditor.value=sourceHtml}editor._codeEditorActive=!0}}}}}],enabledTools:["p","h1","h2","createlink","unlink","bold","italic","underline","strikeThrough","justifyLeft","justifyCenter","justifyRight","insertUnorderedList","insertOrderedList","insertHorizontalRule","custom-media","code-editor"],events:{onUpdateSelection:packet=>{packet.instance&&setTimeout(()=>{const pingedSelection=window.getSelection();pingedSelection&&0===pingedSelection.toString().trim().length&&this.writersblock.hidePopupTools()},10)}}}},WPGMZA.FeaturePanel.prototype.hasDirtyField=function(field){if(this.feature&&this.feature._dirtyFields){if(this.feature._dirtyFields instanceof Array&&-1!==this.feature._dirtyFields.indexOf(field))return!0}else if(!this.feature)return!0;return!1}}),jQuery(function($){WPGMZA.MarkerPanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.MarkerPanel,WPGMZA.FeaturePanel),WPGMZA.MarkerPanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProMarkerPanel:WPGMZA.MarkerPanel)(element,mapEditPage)},WPGMZA.MarkerPanel.prototype.initDefaults=function(){var self=this;WPGMZA.FeaturePanel.prototype.initDefaults.apply(this,arguments),this.adjustSubMode=!1,WPGMZA.InternalEngine.isLegacy()&&this.onTabActivated(null),$(document.body).on("click","[data-adjust-"+this.featureType+"-id]",function(event){self.onAdjustFeature(event)}),$(document.body).on("click",".wpgmza_approve_btn",function(event){self.onApproveMarker(event)})},WPGMZA.MarkerPanel.prototype.onAdjustFeature=function(event){var name="data-adjust-"+this.featureType+"-id",event=$(event.currentTarget).attr(name);this.discardChanges(),this.adjustSubMode=!0,this.select(event)},WPGMZA.MarkerPanel.prototype.onApproveMarker=function(event){var self=this,event="/"+this.featureType+"s/"+$(event.currentTarget).attr("id");WPGMZA.restAPI.call(event,{method:"POST",data:{approved:"1"},success:function(data,status,xhr){self.featureDataTable.reload()}})},WPGMZA.MarkerPanel.prototype.onFeatureChanged=function(event){var aPos,pos;this.adjustSubMode?(aPos=this.feature.getPosition())&&($(this.element).find("[data-ajax-name='lat']").val(aPos.lat),$(this.element).find("[data-ajax-name='lng']").val(aPos.lng)):(aPos=$(this.element).find("input[data-ajax-name$='address']")).length&&(pos=this.feature.getPosition(),aPos.val(pos.lat+", "+pos.lng),aPos.trigger("change"))},WPGMZA.MarkerPanel.prototype.setTargetFeature=function(feature){var prev;WPGMZA.FeaturePanel.prevEditableFeature&&(prev=WPGMZA.FeaturePanel.prevEditableFeature).setOpacity&&prev.setOpacity(1),$(this.element).find("[data-ajax-name]").removeAttr("disabled"),$(this.element).find("fieldset").show(),$(this.element).find(".wpgmza-adjust-mode-notice").addClass("wpgmza-hidden"),$(this.element).find('[data-ajax-name="lat"]').attr("type","hidden"),$(this.element).find('[data-ajax-name="lng"]').attr("type","hidden"),$(this.element).find(".wpgmza-hide-in-adjust-mode").removeClass("wpgmza-hidden"),$(this.element).find(".wpgmza-show-in-adjust-mode").addClass("wpgmza-hidden"),feature?(feature.setOpacity&&feature.setOpacity(.7),feature.getMap().panTo(feature.getPosition()),this.adjustSubMode&&($(this.element).find("[data-ajax-name]").attr("disabled","disabled"),$(this.element).find("fieldset:not(.wpgmza-always-on)").hide(),$(this.element).find(".wpgmza-adjust-mode-notice").removeClass("wpgmza-hidden"),$(this.element).find('[data-ajax-name="lat"]').attr("type","text").removeAttr("disabled"),$(this.element).find('[data-ajax-name="lng"]').attr("type","text").removeAttr("disabled"),$(this.element).find(".wpgmza-hide-in-adjust-mode").addClass("wpgmza-hidden"),$(this.element).find(".wpgmza-show-in-adjust-mode").removeClass("wpgmza-hidden"))):this.adjustSubMode=!1,WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments)},WPGMZA.MarkerPanel.prototype.onSave=function(event){var self=this,geocoder=WPGMZA.Geocoder.createInstance(),geocodingData={address:$(this.element).find("[data-ajax-name='address']").val()},cloud_lat=(WPGMZA.mapEditPage.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.showPreloader(!0),!1),cloud_lng=!1,cloud_lat=(0<document.getElementsByName("lat").length&&(cloud_lat=document.getElementsByName("lat")[0].value),0<document.getElementsByName("lng").length&&(cloud_lng=document.getElementsByName("lng")[0].value),cloud_lat&&cloud_lng&&(WPGMZA_localized_data.settings.googleMapsApiKey&&""!==WPGMZA_localized_data.settings.googleMapsApiKey||(geocodingData.lat=parseFloat(cloud_lat),geocodingData.lng=parseFloat(cloud_lng))),!this.hasDirtyField("address"));this.adjustSubMode||cloud_lat?WPGMZA.FeaturePanel.prototype.onSave.apply(self,arguments):geocoder.geocode(geocodingData,function(results,status){switch(status){case WPGMZA.Geocoder.ZERO_RESULTS:return alert(WPGMZA.localized_strings.zero_results),void self.showPreloader(!1);case WPGMZA.Geocoder.SUCCESS:break;case WPGMZA.Geocoder.NO_ADDRESS:return alert(WPGMZA.localized_strings.no_address),void self.showPreloader(!1);default:WPGMZA.Geocoder.FAIL;return alert(WPGMZA.localized_strings.geocode_fail),void self.showPreloader(!1)}var result=results[0];$(self.element).find("[data-ajax-name='lat']").val(result.lat),$(self.element).find("[data-ajax-name='lng']").val(result.lng),WPGMZA.FeaturePanel.prototype.onSave.apply(self,arguments)}),WPGMZA.mapEditPage.map.resetBounds()}}),jQuery(function($){WPGMZA.CirclePanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.CirclePanel,WPGMZA.FeaturePanel),WPGMZA.CirclePanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProCirclePanel:WPGMZA.CirclePanel)(element,mapEditPage)},WPGMZA.CirclePanel.prototype.updateFields=function(){$(this.element).find("[data-ajax-name='center']").val(this.feature.getCenter().toString()),$(this.element).find("[data-ajax-name='radius']").val(this.feature.getRadius())},WPGMZA.CirclePanel.prototype.onDrawingComplete=function(event){WPGMZA.FeaturePanel.prototype.onDrawingComplete.apply(this,arguments),this.updateFields()},WPGMZA.CirclePanel.prototype.setTargetFeature=function(feature){WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments),feature&&this.updateFields()},WPGMZA.CirclePanel.prototype.onFeatureChanged=function(event){WPGMZA.FeaturePanel.prototype.onFeatureChanged.apply(this,arguments),this.updateFields()}});var wpgmza_autoCompleteDisabled=!1;jQuery(function($){"map-edit"==WPGMZA.currentPage&&(WPGMZA.MapEditPage=function(){var self=this,element=document.body,ajaxRequest=(WPGMZA.EventDispatcher.call(this),WPGMZA.settings.internalEngine&&!WPGMZA.InternalEngine.isLegacy()||$("#wpgmaps_options fieldset").wrapInner("<div class='wpgmza-flex'></div>"),this.themePanel=new WPGMZA.ThemePanel,this.themeEditor=new WPGMZA.ThemeEditor,this.sidebarGroupings=new WPGMZA.SidebarGroupings,this.map=WPGMZA.maps[0],(!WPGMZA.pro_version||WPGMZA.Version.compare(WPGMZA.pro_version,"8.1.0")>=WPGMZA.Version.EQUAL_TO)&&(this.drawingManager=WPGMZA.DrawingManager.createInstance(this.map)),this.initDataTables(),this.initFeaturePanels(),this.initJQueryUIControls(),"en"!==WPGMZA.locale&&(WPGMZA.InternalEngine.isLegacy()?$("#datatable_no_result_message,#datatable_search_string").parent():$("#datatable_no_result_message,#datatable_search_string")).parent().hide(),$("input.wpgmza-address").each(function(index,el){el.addressInput=WPGMZA.AddressInput.createInstance(el,self.map)}),$('#wpgmza-map-edit-page input[type="color"]').each(function(){var buttonClass=WPGMZA.InternalEngine.isLegacy()?"button-secondary":"wpgmza-button";$("<div class='"+buttonClass+" wpgmza-paste-color-btn' title='Paste a HEX color code'><i class='fa fa-clipboard' aria-hidden='true'></i></div>").insertAfter(this)}),jQuery("body").on("click",".wpgmza_ac_result",function(e){var index=jQuery(this).data("id"),lat=jQuery(this).data("lat"),lng=jQuery(this).data("lng"),index=jQuery("#wpgmza_item_address_"+index).html();jQuery("input[name='lat']").val(lat),jQuery("input[name='lng']").val(lng),jQuery("#wpgmza_add_address_map_editor").val(index),jQuery("#wpgmza_autocomplete_search_results").hide()}),jQuery("body").on("click",".wpgmza-paste-color-btn",function(){try{var colorBtn=$(this);if(!navigator||!navigator.clipboard||!navigator.clipboard.readText)return;navigator.clipboard.readText().then(function(textcopy){colorBtn.parent().find('input[type="color"]').val("#"+textcopy.replace("#","").trim())}).catch(function(err){console.error("WP Go Maps: Could not access clipboard",err)})}catch(c_ex){}}),jQuery("body").on("focusout","#wpgmza_add_address_map_editor",function(e){setTimeout(function(){jQuery("#wpgmza_autocomplete_search_results").fadeOut("slow")},500)}),!1),wpgmzaAjaxTimeout=!1,wpgmzaStartTyping=!1,wpgmzaKeyStrokeCount=1,wpgmzaAvgTimeBetweenStrokes=300,wpgmzaTotalTimeForKeyStrokes=0,wpgmzaTmp="",wpgmzaIdentifiedTypingSpeed=!1;$("body").on("keypress",".wpgmza-address",function(e){if("wpgmza_add_address_map_editor"==this.id&&!wpgmza_autoCompleteDisabled){var wpgmza_apikey=!1;if(WPGMZA_localized_data.settings.googleMapsApiKey&&""!==WPGMZA_localized_data.settings.googleMapsApiKey)wpgmza_apikey=WPGMZA_localized_data.settings.googleMapsApiKey;else if("Escape"===e.key||"Alt"===e.key||"Control"===e.key||"Option"===e.key||"Shift"===e.key||"ArrowLeft"===e.key||"ArrowRight"===e.key||"ArrowUp"===e.key||"ArrowDown"===e.key)$("#wpgmza_autocomplete_search_results").hide();else{if(!wpgmzaIdentifiedTypingSpeed)return e=new Date,clearTimeout(wpgmzaTmp),wpgmzaTmp=setTimeout(function(){wpgmzaStartTyping=!1,wpgmzaAvgTimeBetweenStrokes=300,wpgmzaTotalTimeForKeyStrokes=0},1500),wpgmzaStartTyping?1!=wpgmzaKeyStrokeCount&&(wpgmzaCurrentTimeBetweenStrokes=e.getTime()-wpgmzaStartTyping,wpgmzaTotalTimeForKeyStrokes+=wpgmzaCurrentTimeBetweenStrokes,wpgmzaAvgTimeBetweenStrokes=wpgmzaTotalTimeForKeyStrokes/(wpgmzaKeyStrokeCount-1),wpgmzaStartTyping=e.getTime(),3<=wpgmzaKeyStrokeCount&&(wpgmzaIdentifiedTypingSpeed=wpgmzaAvgTimeBetweenStrokes)):wpgmzaStartTyping=e.getTime(),void wpgmzaKeyStrokeCount++;clearTimeout(wpgmzaAjaxTimeout),$("#wpgmza_autocomplete_search_results").html('<div class="wpgmza-pad-5">Searching...</div>'),$("#wpgmza_autocomplete_search_results").show();e=jQuery(this).val();if(""!==e){!1!==ajaxRequest&&ajaxRequest.abort();var domain=window.location.hostname;if("localhost"===domain)try{var paths=window.location.pathname.match(/\/(.*?)\//);paths&&2<=paths.length&&paths[1]&&(domain+="-"+paths[1])}catch(ex){}var wpgmza_api_url="",wpgmza_api_url=wpgmza_apikey?"https://wpgmaps.us-3.evennode.com/api/v1/autocomplete?s="+e+"&d="+domain+"&hash="+WPGMZA_localized_data.siteHash+"&k="+wpgmza_apikey:"https://wpgmaps.us-3.evennode.com/api/v1/autocomplete?s="+e+"&d="+domain+"&hash="+WPGMZA_localized_data.siteHash;WPGMZA&&WPGMZA.settings&&WPGMZA.settings.engine&&(wpgmza_api_url+="&engine="+WPGMZA.settings.engine),wpgmzaAjaxTimeout=setTimeout(function(){ajaxRequest=$.ajax({url:wpgmza_api_url,type:"GET",dataType:"json",success:function(results){try{if(void 0!==results.error)"error1"==results.error?($("#wpgmza_autoc_disabled").html(WPGMZA.localized_strings.cloud_api_key_error_1),$("#wpgmza_autoc_disabled").fadeIn("slow"),$("#wpgmza_autocomplete_search_results").hide(),wpgmza_autoCompleteDisabled=!0):console.error(results.error);else{$("#wpgmza_autocomplete_search_results").html("");var i,html="";for(i in results)html+="<div class='wpgmza_ac_result "+(""===html?"":"border-top")+"' data-id='"+i+"' data-lat='"+results[i].lat+"' data-lng='"+results[i].lng+"'><div class='wpgmza_ac_container'><div class='wpgmza_ac_icon'><img src='"+results[i].icon+"' /></div><div class='wpgmza_ac_item'><span id='wpgmza_item_name_"+i+"' class='wpgmza_item_name'>"+results[i].place_name+"</span><span id='wpgmza_item_address_"+i+"' class='wpgmza_item_address'>"+results[i].formatted_address+"</span></div></div></div>";""==html&&(html="<div class='p-2 text-center'><small>No results found...</small></div>"),$("#wpgmza_autocomplete_search_results").html(html),$("#wpgmza_autocomplete_search_results").show()}}catch(exception){console.error("WP Go Maps Plugin: There was an error returning the list of places for your search")}}})},2*wpgmzaIdentifiedTypingSpeed)}else $("#wpgmza_autocomplete_search_results").hide()}}}),$("#wpgmza_map_height_type").on("change",function(event){self.onMapHeightTypeChange(event)}),$("#advanced-markers .wpgmza-feature-drawing-instructions").remove(),$("[data-search-area='auto']").hide(),$(document.body).on("click","[data-wpgmza-admin-marker-datatable] input[name='mark']",function(event){self.onShiftClick(event)}),$("#wpgmza_map_type").on("change",function(event){self.onMapTypeChanged(event)}),$("body").on("click",".wpgmza_copy_shortcode",function(){var $temp=jQuery("<input>");jQuery('<span id="wpgmza_tmp" style="display:none; width:100%; text-align:center;">');jQuery("body").append($temp),$temp.val(jQuery(this).val()).select(),document.execCommand("copy"),$temp.remove(),WPGMZA.notification("Shortcode Copied")}),this.on("markerupdated",function(event){self.onMarkerUpdated(event)}),this.map&&(this.map.on("zoomchanged",function(event){self.onZoomChanged(event)}),this.map.on("boundschanged",function(event){self.onBoundsChanged(event)}),this.map.on("rightclick",function(event){self.onRightClick(event)})),$(element).on("click",".wpgmza_poly_del_btn",function(event){self.onDeletePolygon(event)}),$(element).on("click",".wpgmza_polyline_del_btn",function(event){self.onDeletePolyline(event)}),$(element).on("click",".wpgmza_dataset_del_btn",function(evevnt){self.onDeleteHeatmap(event)}),$(element).on("click",".wpgmza_circle_del_btn",function(event){self.onDeleteCircle(event)}),$(element).on("click",".wpgmza_rectangle_del_btn",function(event){self.onDeleteRectangle(event)}),$(element).on("click","#wpgmza-open-advanced-theme-data",function(event){event.preventDefault(),$(".wpgmza_theme_data_container").toggleClass("wpgmza_hidden")}),$(element).on("click",".wpgmza-shortcode-button",function(event){event.preventDefault(),$(element).find(".wpgmza-shortcode-description").addClass("wpgmza-hidden");const nearestRow=$(this).closest(".wpgmza-row");if(nearestRow.length){const nearestHint=nearestRow.next(".wpgmza-shortcode-description");nearestHint.length&&nearestHint.removeClass("wpgmza-hidden")}event=$(this).text();if(event.length){const temp=jQuery("<input>");$(document.body).append(temp),temp.val(event).select(),document.execCommand("copy"),temp.remove(),WPGMZA.notification("Shortcode Copied")}})},WPGMZA.extend(WPGMZA.MapEditPage,WPGMZA.EventDispatcher),WPGMZA.MapEditPage.createInstance=function(){return new(WPGMZA.isProVersion()&&WPGMZA.Version.compare(WPGMZA.pro_version,"8.0.0")>=WPGMZA.Version.EQUAL_TO?WPGMZA.ProMapEditPage:WPGMZA.MapEditPage)},WPGMZA.MapEditPage.prototype.initDataTables=function(){var self=this;$("[data-wpgmza-datatable][data-wpgmza-rest-api-route]").each(function(index,el){var featureType=$(el).attr("data-wpgmza-feature-type");self[featureType+"AdminDataTable"]=new WPGMZA.AdminFeatureDataTable(el)})},WPGMZA.MapEditPage.prototype.initFeaturePanels=function(){var self=this;$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").each(function(index,el){var featurePanelElement=$(el).find(".wpgmza-feature-panel-container > *"),el=$(el).attr("data-wpgmza-feature-type"),panelClassName=WPGMZA.capitalizeWords(el)+"Panel",panelClassName=WPGMZA[panelClassName].createInstance(featurePanelElement,self);self[el+"Panel"]=panelClassName})},WPGMZA.MapEditPage.prototype.initJQueryUIControls=function(){var mapContainer,self=this;$("#wpgmaps_tabs").tabs(),mapContainer=$("#wpgmza-map-container").detach(),$("#wpgmaps_tabs_markers").tabs(),$(".map_wrapper").prepend(mapContainer),$("#slider-range-max").slider({range:"max",min:1,max:21,value:$("input[name='map_start_zoom']").val(),slide:function(event,ui){$("input[name='map_start_zoom']").val(ui.value),self.map.setZoom(ui.value)}})},WPGMZA.MapEditPage.prototype.onShiftClick=function(event){var checkbox=event.currentTarget,checkbox=jQuery(checkbox).closest("tr");if(this.lastSelectedRow&&event.shiftKey){var event=this.lastSelectedRow.index(),currIndex=checkbox.index(),startIndex=Math.min(event,currIndex),endIndex=Math.max(event,currIndex),rows=jQuery("[data-wpgmza-admin-marker-datatable] tbody>tr");jQuery("[data-wpgmza-admin-marker-datatable] input[name='mark']").prop("checked",!1);for(var i=startIndex;i<=endIndex;i++)jQuery(rows[i]).find("input[name='mark']").prop("checked",!0)}this.lastSelectedRow=checkbox},WPGMZA.MapEditPage.prototype.onMapTypeChanged=function(event){if("open-layers"!=WPGMZA.settings.engine){var mapTypeId;switch(event.target.value){case"2":mapTypeId=google.maps.MapTypeId.SATELLITE;break;case"3":mapTypeId=google.maps.MapTypeId.HYBRID;break;case"4":mapTypeId=google.maps.MapTypeId.TERRAIN;break;default:mapTypeId=google.maps.MapTypeId.ROADMAP}this.map.setOptions({mapTypeId:mapTypeId})}},WPGMZA.MapEditPage.prototype.onMarkerUpdated=function(event){this.markerDataTable.reload()},WPGMZA.MapEditPage.prototype.onZoomChanged=function(event){$(".map_start_zoom").val(this.map.getZoom())},WPGMZA.MapEditPage.prototype.onBoundsChanged=function(event){var location=this.map.getCenter();$("#wpgmza_start_location").val(location.lat+","+location.lng),$("input[name='map_start_lat']").val(location.lat),$("input[name='map_start_lng']").val(location.lng),$("#wpgmza_start_zoom").val(this.map.getZoom()),$("#wpgmaps_save_reminder").show()},WPGMZA.MapEditPage.prototype.onMapHeightTypeChange=function(event){"%"==event.target.value&&$("#wpgmza_height_warning").show()},WPGMZA.MapEditPage.prototype.onRightClick=function(event){var marker,self=this;this.drawingManager&&this.drawingManager.mode!=WPGMZA.DrawingManager.MODE_MARKER||(this.rightClickMarker||(this.rightClickMarker=WPGMZA.Marker.createInstance({draggable:!0}),this.rightClickMarker.on("dragend",function(event){$(".wpgmza-marker-panel [data-ajax-name='address']").val(event.latLng.lat+", "+event.latLng.lng)}),this.map.on("click",function(event){self.rightClickMarker.setMap(null),$(".wpgmza-marker-panel [data-ajax-name='address']").val("")})),(marker=this.rightClickMarker).setPosition(event.latLng),marker.setMap(this.map),$(".wpgmza-marker-panel [data-ajax-name='address']").val(event.latLng.lat+", "+event.latLng.lng))},WPGMZA.MapEditPage.prototype.onDeletePolygon=function(event){var cur_id=parseInt($(this).attr("id")),data={action:"delete_poly",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,poly_id:cur_id};$.post(ajaxurl,data,function(response){WPGM_Path[cur_id].setMap(null),delete WPGM_PathData[cur_id],delete WPGM_Path[cur_id],$("#wpgmza_poly_holder").html(response)})},WPGMZA.MapEditPage.prototype.onDeletePolyline=function(event){var cur_id=$(this).attr("id"),data={action:"delete_polyline",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,poly_id:cur_id};$.post(ajaxurl,data,function(response){WPGM_PathLine[cur_id].setMap(null),delete WPGM_PathLineData[cur_id],delete WPGM_PathLine[cur_id],$("#wpgmza_polyline_holder").html(response)})},WPGMZA.MapEditPage.prototype.onDeleteHeatmap=function(event){var cur_id=$(this).attr("id"),data={action:"delete_dataset",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,poly_id:cur_id};$.post(ajaxurl,data,function(response){heatmap[cur_id].setMap(null),delete heatmap[cur_id],$("#wpgmza_heatmap_holder").html(response)})},WPGMZA.MapEditPage.prototype.onDeleteCircle=function(event){var circle_id=$(this).attr("id"),data={action:"delete_circle",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,circle_id:circle_id};$.post(ajaxurl,data,function(response){$("#tabs-m-5 table").replaceWith(response),circle_array.forEach(function(circle){if(circle.id==circle_id)return circle.setMap(null),!1})})},WPGMZA.MapEditPage.prototype.onDeleteRectangle=function(event){var rectangle_id=$(this).attr("id"),data={action:"delete_rectangle",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,rectangle_id:rectangle_id};$.post(ajaxurl,data,function(response){$("#tabs-m-6 table").replaceWith(response),rectangle_array.forEach(function(rectangle){if(rectangle.id==rectangle_id)return rectangle.setMap(null),!1})})},$(document).ready(function(event){WPGMZA.mapEditPage=WPGMZA.MapEditPage.createInstance()}))}),jQuery(function($){WPGMZA.PointlabelPanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.PointlabelPanel,WPGMZA.FeaturePanel),WPGMZA.PointlabelPanel.createInstance=function(element,mapEditPage){return new WPGMZA.PointlabelPanel(element,mapEditPage)},WPGMZA.PointlabelPanel.prototype.updateFields=function(){$(this.element).find("[data-ajax-name='center']").val(this.feature.getPosition().toString())},WPGMZA.PointlabelPanel.prototype.onDrawingComplete=function(event){WPGMZA.FeaturePanel.prototype.onDrawingComplete.apply(this,arguments),this.updateFields()},WPGMZA.PointlabelPanel.prototype.setTargetFeature=function(feature){WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments),feature&&this.updateFields()},WPGMZA.PointlabelPanel.prototype.onFeatureChanged=function(event){WPGMZA.FeaturePanel.prototype.onFeatureChanged.apply(this,arguments),this.updateFields()}}),jQuery(function($){WPGMZA.PolygonPanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.PolygonPanel,WPGMZA.FeaturePanel),WPGMZA.PolygonPanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProPolygonPanel:WPGMZA.PolygonPanel)(element,mapEditPage)},Object.defineProperty(WPGMZA.PolygonPanel.prototype,"drawingManagerCompleteEvent",{get:function(){return"polygonclosed"}})}),jQuery(function($){WPGMZA.PolylinePanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.PolylinePanel,WPGMZA.FeaturePanel),WPGMZA.PolylinePanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProPolylinePanel:WPGMZA.PolylinePanel)(element,mapEditPage)}}),jQuery(function($){WPGMZA.RectanglePanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.RectanglePanel,WPGMZA.FeaturePanel),WPGMZA.RectanglePanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProRectanglePanel:WPGMZA.RectanglePanel)(element,mapEditPage)},WPGMZA.RectanglePanel.prototype.updateFields=function(){var bounds=this.feature.getBounds();bounds.north&&bounds.west&&bounds.south&&bounds.east&&($(this.element).find("[data-ajax-name='cornerA']").val(bounds.north+", "+bounds.west),$(this.element).find("[data-ajax-name='cornerB']").val(bounds.south+", "+bounds.east))},WPGMZA.RectanglePanel.prototype.setTargetFeature=function(feature){WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments),feature&&this.updateFields()},WPGMZA.RectanglePanel.prototype.onDrawingComplete=function(event){WPGMZA.FeaturePanel.prototype.onDrawingComplete.apply(this,arguments),this.updateFields()},WPGMZA.RectanglePanel.prototype.onFeatureChanged=function(event){WPGMZA.FeaturePanel.prototype.onFeatureChanged.apply(this,arguments),this.updateFields()}}),jQuery(function($){var Parent=WPGMZA.Circle;WPGMZA.OLCircle=function(options,olFeature){var center,geom;Parent.call(this,options,olFeature),options=options||{},olFeature?(olFeature=olFeature.getGeometry(),center=ol.proj.toLonLat(olFeature.getCenter()),geom=olFeature,options.center=new WPGMZA.LatLng(center[1],center[0]),options.radius=olFeature.getRadius()/1e3):geom=new ol.geom.Circle(ol.proj.fromLonLat([parseFloat(options.center.lng),parseFloat(options.center.lat)]),1e3*options.radius),this.layer=new ol.layer.Vector({source:new ol.source.Vector}),this.olFeature=new ol.Feature({geometry:geom}),this.layer.getSource().addFeature(this.olFeature),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaCircle:this,wpgmzaFeature:this}),options&&this.setOptions(options)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProCircle),WPGMZA.OLCircle.prototype=Object.create(Parent.prototype),WPGMZA.OLCircle.prototype.constructor=WPGMZA.OLCircle,WPGMZA.OLCircle.prototype.setOptions=function(options){Parent.prototype.setOptions.call(this,options),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)},WPGMZA.OLCircle.prototype.getCenter=function(){var lonLat=ol.proj.toLonLat(this.olFeature.getGeometry().getCenter());return new WPGMZA.LatLng({lat:lonLat[1],lng:lonLat[0]})},WPGMZA.OLCircle.prototype.recreate=function(){var radius,y,x;this.olFeature&&(this.layer.getSource().removeFeature(this.olFeature),delete this.olFeature),this.center&&this.radius&&(radius=1e3*parseFloat(this.radius),x=this.center.lng,y=this.center.lat,x=ol.geom.Polygon.circular([x,y],radius,64).clone().transform("EPSG:4326","EPSG:3857"),this.olFeature=new ol.Feature(x),this.layer.getSource().addFeature(this.olFeature))},WPGMZA.OLCircle.prototype.setVisible=function(visible){this.layer.setVisible(!!visible)},WPGMZA.OLCircle.prototype.setCenter=function(center){WPGMZA.Circle.prototype.setCenter.apply(this,arguments),this.recreate()},WPGMZA.OLCircle.prototype.getRadius=function(){return this.layer.getSource().getFeatures()[0].getGeometry().getRadius()/1e3},WPGMZA.OLCircle.prototype.setRadius=function(radius){WPGMZA.Circle.prototype.setRadius.apply(this,arguments)},WPGMZA.OLCircle.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){WPGMZA.OLDrawingManager=function(map){WPGMZA.DrawingManager.call(this,map),this.source=new ol.source.Vector({wrapX:!1}),this.layer=new ol.layer.Vector({source:this.source})},WPGMZA.OLDrawingManager.prototype=Object.create(WPGMZA.DrawingManager.prototype),WPGMZA.OLDrawingManager.prototype.constructor=WPGMZA.OLDrawingManager,WPGMZA.OLDrawingManager.prototype.setOptions=function(options){var params={};options.strokeOpacity&&(params.stroke=new ol.style.Stroke({color:WPGMZA.hexOpacityToRGBA(options.strokeColor,options.strokeOpacity)})),options.fillOpacity&&(params.fill=new ol.style.Fill({color:WPGMZA.hexOpacityToRGBA(options.fillColor,options.fillOpacity)})),this.layer.setStyle(new ol.style.Style(params))},WPGMZA.OLDrawingManager.prototype.setDrawingMode=function(mode){var type,endEventType,self=this;switch(WPGMZA.DrawingManager.prototype.setDrawingMode.call(this,mode),this.interaction&&(this.map.olMap.removeInteraction(this.interaction),this.interaction=null),mode){case WPGMZA.DrawingManager.MODE_NONE:case WPGMZA.DrawingManager.MODE_MARKER:return;case WPGMZA.DrawingManager.MODE_POLYGON:type="Polygon",endEventType="polygonclosed";break;case WPGMZA.DrawingManager.MODE_POLYLINE:type="LineString",endEventType="polylinecomplete";break;case WPGMZA.DrawingManager.MODE_CIRCLE:type="Circle",endEventType="circlecomplete";break;case WPGMZA.DrawingManager.MODE_RECTANGLE:type="Circle",endEventType="rectanglecomplete";break;case WPGMZA.DrawingManager.MODE_HEATMAP:case WPGMZA.DrawingManager.MODE_POINTLABEL:return;case WPGMZA.DrawingManager.MODE_IMAGEOVERLAY:type="Circle",endEventType="imageoverlaycomplete";break;default:throw new Error("Invalid drawing mode")}WPGMZA.mapEditPage&&WPGMZA.mapEditPage.selectInteraction&&WPGMZA.mapEditPage.map.olMap.removeInteraction(WPGMZA.mapEditPage.selectInteraction);var options={source:this.source,type:type};mode!=WPGMZA.DrawingManager.MODE_RECTANGLE&&mode!=WPGMZA.DrawingManager.MODE_IMAGEOVERLAY||(options.geometryFunction=ol.interaction.Draw.createBox()),this.interaction=new ol.interaction.Draw(options),this.interaction.on("drawend",function(event){if(endEventType){var WPGMZAEvent=new WPGMZA.Event(endEventType);switch(mode){case WPGMZA.DrawingManager.MODE_POLYGON:WPGMZAEvent.enginePolygon=event.feature;break;case WPGMZA.DrawingManager.MODE_POLYLINE:WPGMZAEvent.enginePolyline=event.feature;break;case WPGMZA.DrawingManager.MODE_CIRCLE:WPGMZAEvent.engineCircle=event.feature;break;case WPGMZA.DrawingManager.MODE_RECTANGLE:WPGMZAEvent.engineRectangle=event.feature;break;case WPGMZA.DrawingManager.MODE_IMAGEOVERLAY:WPGMZAEvent.engineImageoverlay={engineRectangle:event.feature};break;default:throw new Error("Drawing mode not implemented")}self.dispatchEvent(WPGMZAEvent)}}),this.map.olMap.addInteraction(this.interaction)}}),jQuery(function($){WPGMZA.OLFeature=function(options){WPGMZA.assertInstangeOf(this,"OLFeature"),WPGMZA.Feature.apply(this,arguments)},WPGMZA.extend(WPGMZA.OLFeature,WPGMZA.Feature),WPGMZA.OLFeature.getOLStyle=function(options){var translated={};if(!options)return new ol.style.Style;var name,opacity,weight,map={fillcolor:"fillColor",opacity:"fillOpacity",linecolor:"strokeColor",lineopacity:"strokeOpacity",linethickness:"strokeWeight"};for(name in options=$.extend({},options))name in map&&(options[map[name]]=options[name]);return options.strokeColor&&(weight=opacity=1,"strokeOpacity"in options&&(opacity=options.strokeOpacity),"strokeWeight"in options&&(weight=options.strokeWeight),translated.stroke=new ol.style.Stroke({color:WPGMZA.hexOpacityToString(options.strokeColor,opacity),width:weight})),options.fillColor&&(opacity=1,"fillOpacity"in options&&(opacity=options.fillOpacity),weight=WPGMZA.hexOpacityToString(options.fillColor,opacity),translated.fill=new ol.style.Fill({color:weight})),new ol.style.Style(translated)},WPGMZA.OLFeature.setInteractionsOnFeature=function(feature,enable){enable?feature.modifyInteraction||(feature.snapInteraction=new ol.interaction.Snap({source:feature.layer.getSource()}),feature.map.olMap.addInteraction(feature.snapInteraction),feature.modifyInteraction=new ol.interaction.Modify({source:feature.layer.getSource()}),feature.map.olMap.addInteraction(feature.modifyInteraction),feature.modifyInteraction.on("modifyend",function(event){feature.trigger("change")})):feature.modifyInteraction&&(feature.map&&(feature.map.olMap.removeInteraction(feature.snapInteraction),feature.map.olMap.removeInteraction(feature.modifyInteraction)),delete feature.snapInteraction,delete feature.modifyInteraction)}}),jQuery(function($){WPGMZA.OLGeocoder=function(){},WPGMZA.OLGeocoder.prototype=Object.create(WPGMZA.Geocoder.prototype),WPGMZA.OLGeocoder.prototype.constructor=WPGMZA.OLGeocoder,WPGMZA.OLGeocoder.prototype.getResponseFromCache=function(query,callback){WPGMZA.restAPI.call("/geocode-cache",{data:{query:JSON.stringify(query)},success:function(response,xhr,status){response.lng=response.lon,callback(response)},useCompressedPathVariable:!0})},WPGMZA.OLGeocoder.prototype.getResponseFromNominatim=function(options,callback){var data={q:options.address,format:"json"};options.componentRestrictions&&options.componentRestrictions.country?data.countrycodes=options.componentRestrictions.country:options.country&&(data.countrycodes=options.country),$.ajax("https://nominatim.openstreetmap.org/search/",{data:data,success:function(response,xhr,status){callback(response)},error:function(response,xhr,status){callback(null,WPGMZA.Geocoder.FAIL)}})},WPGMZA.OLGeocoder.prototype.cacheResponse=function(query,response){$.ajax(WPGMZA.ajaxurl,{data:{action:"wpgmza_store_nominatim_cache",query:JSON.stringify(query),response:JSON.stringify(response)},method:"POST"})},WPGMZA.OLGeocoder.prototype.clearCache=function(callback){$.ajax(WPGMZA.ajaxurl,{data:{action:"wpgmza_clear_nominatim_cache"},method:"POST",success:function(response){callback(response)}})},WPGMZA.OLGeocoder.prototype.getLatLngFromAddress=function(options,callback){return WPGMZA.OLGeocoder.prototype.geocode(options,callback)},WPGMZA.OLGeocoder.prototype.getAddressFromLatLng=function(options,callback){return WPGMZA.OLGeocoder.prototype.geocode(options,callback)},WPGMZA.OLGeocoder.prototype.geocode=function(options,callback){var latLng,finish,location,self=this;if(!options)throw new Error("Invalid options");if(WPGMZA.LatLng.REGEXP.test(options.address))return latLng=WPGMZA.LatLng.fromString(options.address),void callback([{geometry:{location:latLng},latLng:latLng,lat:latLng.lat,lng:latLng.lng}],WPGMZA.Geocoder.SUCCESS);if(options.location&&(options.latLng=new WPGMZA.LatLng(options.location)),options.address)location=options.address,finish=function(response,status){for(var i=0;i<response.length;i++)response[i].geometry={location:new WPGMZA.LatLng({lat:parseFloat(response[i].lat),lng:parseFloat(response[i].lon)})},response[i].latLng={lat:parseFloat(response[i].lat),lng:parseFloat(response[i].lon)},response[i].bounds=new WPGMZA.LatLngBounds(new WPGMZA.LatLng({lat:response[i].boundingbox[1],lng:response[i].boundingbox[2]}),new WPGMZA.LatLng({lat:response[i].boundingbox[0],lng:response[i].boundingbox[3]})),response[i].lng=response[i].lon;callback(response,status)};else{if(!options.latLng)throw new Error("You must supply either a latLng or address");location=options.latLng.toString(),finish=function(response,status){var address=response[0].display_name;options.fullResult&&(address=response[0]),callback([address],status)}}var query={location:location,options:options};this.getResponseFromCache(query,function(response){response.length?finish(response,WPGMZA.Geocoder.SUCCESS):self.getResponseFromNominatim($.extend(options,{address:location}),function(response,status){status==WPGMZA.Geocoder.FAIL?callback(null,WPGMZA.Geocoder.FAIL):0==response.length?callback([],WPGMZA.Geocoder.ZERO_RESULTS):(finish(response,WPGMZA.Geocoder.SUCCESS),self.cacheResponse(query,response))})})}}),jQuery(function($){var Parent;WPGMZA.OLInfoWindow=function(feature){var self=this;Parent.call(this,feature),this.element=$("<div class='wpgmza-infowindow ol-info-window-container ol-info-window-plain'></div>")[0],$(this.element).on("click",".ol-info-window-close",function(event){self.close()})},Parent=WPGMZA.isProVersion()?WPGMZA.ProInfoWindow:WPGMZA.InfoWindow,WPGMZA.OLInfoWindow.prototype=Object.create(Parent.prototype),WPGMZA.OLInfoWindow.prototype.constructor=WPGMZA.OLInfoWindow,Object.defineProperty(WPGMZA.OLInfoWindow.prototype,"isPanIntoViewAllowed",{get:function(){return!0}}),WPGMZA.OLInfoWindow.prototype.open=function(map,feature){var self=this,latLng=feature.getPosition();return!!latLng&&(!!Parent.prototype.open.call(this,map,feature)&&(this.parent=map,this.overlay&&this.feature.map.olMap.removeOverlay(this.overlay),this.overlay=new ol.Overlay({element:this.element,stopEvent:!0,insertFirst:!0}),this.overlay.setPosition(ol.proj.fromLonLat([latLng.lng,latLng.lat])),self.feature.map.olMap.addOverlay(this.overlay),$(this.element).show(),this.setContent(this.content),WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER&&WPGMZA.getImageDimensions(feature.getIcon(),function(size){$(self.element).css({left:Math.round(size.width/2)+"px"})}),this.autoResize(),this.trigger("infowindowopen"),void this.trigger("domready")))},WPGMZA.OLInfoWindow.prototype.close=function(event){this.overlay&&($(this.element).hide(),WPGMZA.InfoWindow.prototype.close.call(this),this.trigger("infowindowclose"),this.feature.map.olMap.removeOverlay(this.overlay),this.overlay=null)},WPGMZA.OLInfoWindow.prototype.setContent=function(html){Parent.prototype.setContent.call(this,html),this.content=html;var eaBtn=WPGMZA.isProVersion()?"":this.addEditButton();$(this.element).html(eaBtn+"<i class='fa fa-times ol-info-window-close' aria-hidden='true'></i>"+html)},WPGMZA.OLInfoWindow.prototype.setOptions=function(options){options.maxWidth&&$(this.element).css({"max-width":options.maxWidth+"px"})},WPGMZA.OLInfoWindow.prototype.onOpen=function(){var self=this,imgs=$(this.element).find("img"),numImages=imgs.length,numImagesLoaded=0;WPGMZA.InfoWindow.prototype.onOpen.apply(this,arguments);let canAutoPan=!0;function inside(el,viewport){el=$(el)[0].getBoundingClientRect(),viewport=$(viewport)[0].getBoundingClientRect();return el.left>=viewport.left&&el.left<=viewport.right&&el.right<=viewport.right&&el.right>=viewport.left&&el.top>=viewport.top&&el.top<=viewport.bottom&&el.bottom<=viewport.bottom&&el.bottom>=viewport.top}function panIntoView(){var height=$(self.element).height();self.feature.map.animateNudge(0,.45*-(height+180),self.feature.getPosition())}void 0!==this.feature._osDisableAutoPan&&this.feature._osDisableAutoPan&&(canAutoPan=!1,this.feature._osDisableAutoPan=!1),this.isPanIntoViewAllowed&&canAutoPan&&(imgs.each(function(index,el){el.onload=function(){++numImagesLoaded!=numImages||inside(self.element,self.feature.map.element)||panIntoView()}}),0!=numImages||inside(self.element,self.feature.map.element)||panIntoView())},WPGMZA.OLInfoWindow.prototype.autoResize=function(){var mapWidth,mapHeight;$(this.element).css("max-height","none"),$(this.feature.map.element).length&&(mapHeight=$(this.feature.map.element).height(),mapWidth=$(this.feature.map.element).width(),mapHeight=mapHeight-180,$(this.element).height()>mapHeight&&$(this.element).css("max-height",mapHeight+"px"),mapHeight=648<mapWidth?648:mapWidth-120,$(this.element).width()>mapHeight&&$(this.element).css("max-width",mapHeight+"px"))}}),jQuery(function($){var Parent;WPGMZA.OLMap=function(element,options){var self=this,options=(Parent.call(this,element),this.setOptions(options),this.settings.toOLViewOptions());if($(this.element).html(""),this.olMap=new ol.Map({target:$(element)[0],layers:[this.getTileLayer()],view:this.getTileView(options)}),this.customTileMode&&!ol.extent.containsCoordinate(this.customTileModeExtent,this.olMap.getView().getCenter())){const view=this.olMap.getView();view.setCenter(ol.extent.getCenter(this.customTileModeExtent)),this.wrapLongitude(),this.onBoundsChanged()}function isSettingDisabled(value){return"yes"===value||!!value}this.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan?interaction.setActive(!isSettingDisabled(self.settings.wpgmza_settings_map_draggable)):interaction instanceof ol.interaction.DoubleClickZoom?interaction.setActive(!isSettingDisabled(self.settings.wpgmza_settings_map_clickzoom)):interaction instanceof ol.interaction.MouseWheelZoom&&interaction.setActive(!isSettingDisabled(self.settings.wpgmza_settings_map_scroll))},this),"greedy"!=this.settings.wpgmza_force_greedy_gestures&&"yes"!=this.settings.wpgmza_force_greedy_gestures&&1!=this.settings.wpgmza_force_greedy_gestures&&(this.gestureOverlay=$("<div class='wpgmza-gesture-overlay'></div>"),this.gestureOverlayTimeoutID=null,WPGMZA.isTouchDevice()?(this.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan&&self.olMap.removeInteraction(interaction)}),this.olMap.addInteraction(new ol.interaction.DragPan({condition:function(olBrowserEvent){let allowed=!1;olBrowserEvent=olBrowserEvent.originalEvent;return olBrowserEvent instanceof PointerEvent?this.targetPointers&&this.targetPointers.length&&(allowed=2==this.targetPointers.length):olBrowserEvent instanceof TouchEvent&&olBrowserEvent.touches&&olBrowserEvent.touches.length&&(allowed=2==olBrowserEvent.touches.length),allowed||self.showGestureOverlay(),allowed}})),this.gestureOverlay.text(WPGMZA.localized_strings.use_two_fingers)):(this.olMap.on("wheel",function(event){if(!ol.events.condition.platformModifierKeyOnly(event))return self.showGestureOverlay(),event.originalEvent.preventDefault(),!1}),this.gestureOverlay.text(WPGMZA.localized_strings.use_ctrl_scroll_to_zoom))),this.olMap.getControls().forEach(function(control){control instanceof ol.control.Zoom&&1==WPGMZA.settings.wpgmza_settings_map_zoom&&self.olMap.removeControl(control)},this),isSettingDisabled(WPGMZA.settings.wpgmza_settings_map_full_screen_control)||this.olMap.addControl(new ol.control.FullScreen),WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER&&(this.markerLayer=new ol.layer.Vector({source:new ol.source.Vector({features:[]})}),this.olMap.addLayer(this.markerLayer),this.olMap.on("click",function(event){var event=self.olMap.getFeaturesAtPixel(event.pixel);event&&event.length&&((event=event[0].wpgmzaMarker)&&(event.trigger("click"),event.trigger("select")))})),this.olMap.on("movestart",function(event){self.isBeingDragged=!0}),this.olMap.on("moveend",function(event){self.wrapLongitude(),self.isBeingDragged=!1,self.dispatchEvent("dragend"),self.onIdle()}),this.olMap.getView().on("change:resolution",function(event){self.dispatchEvent("zoom_changed"),self.dispatchEvent("zoomchanged"),setTimeout(function(){self.onIdle()},10)}),this.olMap.getView().on("change",function(){self.onBoundsChanged()}),self.onBoundsChanged(),this._mouseoverNativeFeatures=[],this.olMap.on("pointermove",function(event){if(!event.dragging){try{var featuresUnderPixel=event.target.getFeaturesAtPixel(event.pixel)}catch(e){return}for(var props,featuresUnderPixel=featuresUnderPixel||[],nativeFeaturesUnderPixel=[],i=0;i<featuresUnderPixel.length;i++)(props=featuresUnderPixel[i].getProperties()).wpgmzaFeature&&(nativeFeature=props.wpgmzaFeature,nativeFeaturesUnderPixel.push(nativeFeature),-1==self._mouseoverNativeFeatures.indexOf(nativeFeature)&&(nativeFeature.trigger("mouseover"),self._mouseoverNativeFeatures.push(nativeFeature)));for(i=self._mouseoverNativeFeatures.length-1;0<=i;i--)nativeFeature=self._mouseoverNativeFeatures[i],-1==nativeFeaturesUnderPixel.indexOf(nativeFeature)&&(nativeFeature.trigger("mouseout"),self._mouseoverNativeFeatures.splice(i,1))}}),$(this.element).on("click contextmenu",function(event){event=event||window.event;var isRight,latLng=self.pixelsToLatLng(event.offsetX,event.offsetY);if("which"in event?isRight=3==event.which:"button"in event&&(isRight=2==event.button),1==event.which||1==event.button){if(self.isBeingDragged)return;if($(event.target).closest(".ol-marker").length)return;try{var featuresUnderPixel=self.olMap.getFeaturesAtPixel([event.offsetX,event.offsetY])}catch(e){return}for(var props,featuresUnderPixel=featuresUnderPixel||[],nativeFeaturesUnderPixel=[],i=0;i<featuresUnderPixel.length;i++)(props=featuresUnderPixel[i].getProperties()).wpgmzaFeature&&(nativeFeature=props.wpgmzaFeature,nativeFeaturesUnderPixel.push(nativeFeature),nativeFeature.trigger("click"));return 0<featuresUnderPixel.length?void 0:void self.trigger({type:"click",latLng:latLng})}if(isRight)return self.onRightClick(event)}),WPGMZA.isProVersion()||(this.trigger("init"),this.dispatchEvent("created"),WPGMZA.events.dispatchEvent({type:"mapcreated",map:this}),$(this.element).trigger("wpgooglemaps_loaded"))},Parent=WPGMZA.isProVersion()?WPGMZA.ProMap:WPGMZA.Map,WPGMZA.OLMap.prototype=Object.create(Parent.prototype),WPGMZA.OLMap.prototype.constructor=WPGMZA.OLMap,WPGMZA.OLMap.prototype.getTileLayer=function(){var options={};if(WPGMZA.settings.tile_server_url&&(options.url=WPGMZA.settings.tile_server_url,"custom_override"===WPGMZA.settings.tile_server_url&&(WPGMZA.settings.tile_server_url_override&&""!==WPGMZA.settings.tile_server_url_override.trim()?options.url=WPGMZA.settings.tile_server_url_override.trim():options.url="https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png"),WPGMZA.settings.open_layers_api_key&&""!==WPGMZA.settings.open_layers_api_key&&(options.url+="?apikey="+WPGMZA.settings.open_layers_api_key.trim())),this.settings&&this.settings.custom_tile_enabled&&this.settings.custom_tile_image_width&&this.settings.custom_tile_image_height){var width=parseInt(this.settings.custom_tile_image_width),height=parseInt(this.settings.custom_tile_image_height);if(this.settings.custom_tile_image)return width=[0,0,width,height],height=new ol.proj.Projection({code:"custom-tile-map",units:"pixels",extent:width}),new ol.layer.Image({source:new ol.source.ImageStatic({attributions:this.settings.custom_tile_image_attribution||"©",url:this.settings.custom_tile_image,projection:height,imageExtent:width})})}return new ol.layer.Tile({source:new ol.source.OSM(options)})},WPGMZA.OLMap.prototype.getTileView=function(viewOptions){var width,height;return this.settings&&this.settings.custom_tile_enabled&&this.settings.custom_tile_image_width&&this.settings.custom_tile_image_height&&(width=parseInt(this.settings.custom_tile_image_width),height=parseInt(this.settings.custom_tile_image_height),this.settings.custom_tile_image&&(width=[0,0,width,height],height=new ol.proj.Projection({code:"custom-tile-map",units:"pixels",extent:width}),viewOptions.projection=height,this.customTileModeExtent=width,this.customTileMode=!0)),new ol.View(viewOptions)},WPGMZA.OLMap.prototype.wrapLongitude=function(){var transformed=ol.proj.transform(this.olMap.getView().getCenter(),"EPSG:3857","EPSG:4326"),transformed={lat:transformed[1],lng:transformed[0]};-180<=transformed.lng&&transformed.lng<=180||(transformed.lng=transformed.lng-360*Math.floor(transformed.lng/360),180<transformed.lng&&(transformed.lng-=360),this.setCenter(transformed))},WPGMZA.OLMap.prototype.getCenter=function(){var lonLat=ol.proj.toLonLat(this.olMap.getView().getCenter());return{lat:lonLat[1],lng:lonLat[0]}},WPGMZA.OLMap.prototype.setCenter=function(latLng){var view=this.olMap.getView();WPGMZA.Map.prototype.setCenter.call(this,latLng),view.setCenter(ol.proj.fromLonLat([latLng.lng,latLng.lat])),this.wrapLongitude(),this.onBoundsChanged()},WPGMZA.OLMap.prototype.getBounds=function(){var bounds=this.olMap.getView().calculateExtent(this.olMap.getSize()),nativeBounds=new WPGMZA.LatLngBounds,topLeft=ol.proj.toLonLat([bounds[0],bounds[1]]),bounds=ol.proj.toLonLat([bounds[2],bounds[3]]);return nativeBounds.north=topLeft[1],nativeBounds.south=bounds[1],nativeBounds.west=topLeft[0],nativeBounds.east=bounds[0],nativeBounds},WPGMZA.OLMap.prototype.fitBounds=function(southWest,northEast){southWest instanceof WPGMZA.LatLng&&(southWest={lat:southWest.lat,lng:southWest.lng}),northEast instanceof WPGMZA.LatLng?northEast={lat:northEast.lat,lng:northEast.lng}:southWest instanceof WPGMZA.LatLngBounds&&(southWest={lat:(bounds=southWest).south,lng:bounds.west},northEast={lat:bounds.north,lng:bounds.east});var bounds=this.olMap.getView(),southWest=ol.extent.boundingExtent([ol.proj.fromLonLat([parseFloat(southWest.lng),parseFloat(southWest.lat)]),ol.proj.fromLonLat([parseFloat(northEast.lng),parseFloat(northEast.lat)])]);bounds.fit(southWest,this.olMap.getSize())},WPGMZA.OLMap.prototype.panTo=function(latLng,zoom){var view=this.olMap.getView(),options={center:ol.proj.fromLonLat([parseFloat(latLng.lng),parseFloat(latLng.lat)]),duration:500};1<arguments.length&&(options.zoom=parseInt(zoom)),view.animate(options)},WPGMZA.OLMap.prototype.getZoom=function(){return Math.round(this.olMap.getView().getZoom())},WPGMZA.OLMap.prototype.setZoom=function(value){this.olMap.getView().setZoom(value)},WPGMZA.OLMap.prototype.getMinZoom=function(){return this.olMap.getView().getMinZoom()},WPGMZA.OLMap.prototype.setMinZoom=function(value){this.olMap.getView().setMinZoom(value)},WPGMZA.OLMap.prototype.getMaxZoom=function(){return this.olMap.getView().getMaxZoom()},WPGMZA.OLMap.prototype.setMaxZoom=function(value){this.olMap.getView().setMaxZoom(value)},WPGMZA.OLMap.prototype.setOptions=function(options){Parent.prototype.setOptions.call(this,options),this.olMap&&this.olMap.getView().setProperties(this.settings.toOLViewOptions())},WPGMZA.OLMap.prototype.addMarker=function(marker){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT?this.olMap.addOverlay(marker.overlay):(this.markerLayer.getSource().addFeature(marker.feature),marker.featureInSource=!0),Parent.prototype.addMarker.call(this,marker)},WPGMZA.OLMap.prototype.removeMarker=function(marker){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT?this.olMap.removeOverlay(marker.overlay):(this.markerLayer.getSource().removeFeature(marker.feature),marker.featureInSource=!1),Parent.prototype.removeMarker.call(this,marker)},WPGMZA.OLMap.prototype.addPolygon=function(polygon){this.olMap.addLayer(polygon.layer),Parent.prototype.addPolygon.call(this,polygon)},WPGMZA.OLMap.prototype.removePolygon=function(polygon){this.olMap.removeLayer(polygon.layer),Parent.prototype.removePolygon.call(this,polygon)},WPGMZA.OLMap.prototype.addPolyline=function(polyline){this.olMap.addLayer(polyline.layer),Parent.prototype.addPolyline.call(this,polyline)},WPGMZA.OLMap.prototype.removePolyline=function(polyline){this.olMap.removeLayer(polyline.layer),Parent.prototype.removePolyline.call(this,polyline)},WPGMZA.OLMap.prototype.addCircle=function(circle){this.olMap.addLayer(circle.layer),Parent.prototype.addCircle.call(this,circle)},WPGMZA.OLMap.prototype.removeCircle=function(circle){this.olMap.removeLayer(circle.layer),Parent.prototype.removeCircle.call(this,circle)},WPGMZA.OLMap.prototype.addRectangle=function(rectangle){this.olMap.addLayer(rectangle.layer),Parent.prototype.addRectangle.call(this,rectangle)},WPGMZA.OLMap.prototype.removeRectangle=function(rectangle){this.olMap.removeLayer(rectangle.layer),Parent.prototype.removeRectangle.call(this,rectangle)},WPGMZA.OLMap.prototype.pixelsToLatLng=function(x,y){null==y&&("x"in x&&"y"in x?(y=x.y,x=x.x):console.warn("Y coordinate undefined in pixelsToLatLng (did you mean to pass 2 arguments?)"));x=this.olMap.getCoordinateFromPixel([x,y]);if(!x)return{x:null,y:null};y=ol.proj.toLonLat(x);return{lat:y[1],lng:y[0]}},WPGMZA.OLMap.prototype.latLngToPixels=function(latLng){latLng=ol.proj.fromLonLat([latLng.lng,latLng.lat]),latLng=this.olMap.getPixelFromCoordinate(latLng);return latLng?{x:latLng[0],y:latLng[1]}:{x:null,y:null}},WPGMZA.OLMap.prototype.enableBicycleLayer=function(value){value?(this.bicycleLayer||(this.bicycleLayer=new ol.layer.Tile({source:new ol.source.OSM({url:"http://{a-c}.tile.opencyclemap.org/cycle/{z}/{x}/{y}.png"})})),this.olMap.addLayer(this.bicycleLayer)):this.bicycleLayer&&this.olMap.removeLayer(this.bicycleLayer)},WPGMZA.OLMap.prototype.showGestureOverlay=function(){var self=this;clearTimeout(this.gestureOverlayTimeoutID),$(this.gestureOverlay).stop().animate({opacity:"100"}),$(this.element).append(this.gestureOverlay),$(this.gestureOverlay).css({"line-height":$(this.element).height()+"px",opacity:"1.0"}),$(this.gestureOverlay).show(),this.gestureOverlayTimeoutID=setTimeout(function(){self.gestureOverlay.fadeOut(2e3)},2e3)},WPGMZA.OLMap.prototype.onElementResized=function(event){this.olMap.updateSize()},WPGMZA.OLMap.prototype.onRightClick=function(event){if($(event.target).closest(".ol-marker, .wpgmza_modern_infowindow, .wpgmza-modern-store-locator").length)return!0;var parentOffset=$(this.element).offset(),relX=event.pageX-parentOffset.left,parentOffset=event.pageY-parentOffset.top,relX=this.pixelsToLatLng(relX,parentOffset);return this.trigger({type:"rightclick",latLng:relX}),$(this.element).trigger({type:"rightclick",latLng:relX}),event.preventDefault(),!1},WPGMZA.OLMap.prototype.enableAllInteractions=function(){this.olMap.getInteractions().forEach(function(interaction){(interaction instanceof ol.interaction.DragPan||interaction instanceof ol.interaction.DoubleClickZoom||interaction instanceof ol.interaction.MouseWheelZoom)&&interaction.setActive(!0)},this)}}),jQuery(function($){var Parent;WPGMZA.OLMarker=function(options){var self=this,settings=(Parent.call(this,options),{});if(options)for(var name in options)options[name]instanceof WPGMZA.LatLng?settings[name]=options[name].toLatLngLiteral():options[name]instanceof WPGMZA.Map||(settings[name]=options[name]);var origin=ol.proj.fromLonLat([parseFloat(this.lng),parseFloat(this.lat)]);if(WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT){var img=$("<img alt=''/>")[0];img.onload=function(event){self.updateElementHeight(),self.map&&self.map.olMap.updateSize()},img.src=WPGMZA.defaultMarkerIcon,this.element=$("<div class='ol-marker'></div>")[0],this.element.appendChild(img),this.element.wpgmzaMarker=this,$(this.element).on("mouseover",function(event){self.dispatchEvent("mouseover")}),$(this.element).on("mouseout",function(event){self.dispatchEvent("mouseout")}),this.overlay=new ol.Overlay({element:this.element,position:origin,positioning:"bottom-center",stopEvent:!1}),this.overlay.setPosition(origin),this.animation?this.setAnimation(this.animation):this.anim&&this.setAnimation(this.anim),options&&options.draggable&&this.setDraggable(!0),this.rebindClickListener()}else{if(WPGMZA.OLMarker.renderMode!=WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)throw new Error("Invalid marker render mode");this.feature=new ol.Feature({geometry:new ol.geom.Point(origin)}),this.feature.setStyle(this.getVectorLayerStyle()),(this.feature.wpgmzaMarker=this).feature.wpgmzaFeature=this}this.setOptions(settings),this.trigger("init")},Parent=WPGMZA.isProVersion()?WPGMZA.ProMarker:WPGMZA.Marker,WPGMZA.OLMarker.prototype=Object.create(Parent.prototype),WPGMZA.OLMarker.prototype.constructor=WPGMZA.OLMarker,WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT="element",WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER="vector",WPGMZA.OLMarker.renderMode=WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT,"open-layers"==WPGMZA.settings.engine&&WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER&&(WPGMZA.OLMarker.defaultVectorLayerStyle=new ol.style.Style({image:new ol.style.Icon({anchor:[.5,1],src:WPGMZA.defaultMarkerIcon})}),WPGMZA.OLMarker.hiddenVectorLayerStyle=new ol.style.Style({})),WPGMZA.OLMarker.prototype.getVectorLayerStyle=function(){return this.vectorLayerStyle||WPGMZA.OLMarker.defaultVectorLayerStyle},WPGMZA.OLMarker.prototype.updateElementHeight=function(height,calledOnFocus){var self=this;0!=(height=height||$(this.element).find("img").height())||calledOnFocus||$(window).one("focus",function(event){self.updateElementHeight(!1,!0)}),$(this.element).css({height:height+"px"})},WPGMZA.OLMarker.prototype.addLabel=function(){this.setLabel(this.getLabelText())},WPGMZA.OLMarker.prototype.setLabel=function(label){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?console.warn("Marker labels are not currently supported in Vector Layer rendering mode"):label?(this.label||(this.label=$("<div class='ol-marker-label'/>"),$(this.element).append(this.label)),this.label.html(label)):this.label&&$(this.element).find(".ol-marker-label").remove()},WPGMZA.OLMarker.prototype.getVisible=function(visible){if(WPGMZA.OLMarker.renderMode!=WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)return"none"!=this.overlay.getElement().style.display},WPGMZA.OLMarker.prototype.setVisible=function(visible){var style;Parent.prototype.setVisible.call(this,visible),WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?visible?(style=this.getVectorLayerStyle(),this.feature.setStyle(style)):this.feature.setStyle(null):this.overlay.getElement().style.display=visible?"block":"none"},WPGMZA.OLMarker.prototype.setPosition=function(latLng){Parent.prototype.setPosition.call(this,latLng);latLng=ol.proj.fromLonLat([parseFloat(this.lng),parseFloat(this.lat)]);WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?this.feature.setGeometry(new ol.geom.Point(latLng)):this.overlay.setPosition(latLng)},WPGMZA.OLMarker.prototype.updateOffset=function(x,y){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?console.warn("Marker offset is not currently supported in Vector Layer rendering mode"):(x=this._offset.x,y=this._offset.y,this.element.style.position="relative",this.element.style.left=x+"px",this.element.style.top=y+"px")},WPGMZA.OLMarker.prototype.setAnimation=function(anim){if(WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)console.warn("Marker animation is not currently supported in Vector Layer rendering mode");else switch(Parent.prototype.setAnimation.call(this,anim),anim){case WPGMZA.Marker.ANIMATION_NONE:$(this.element).removeAttr("data-anim");break;case WPGMZA.Marker.ANIMATION_BOUNCE:$(this.element).attr("data-anim","bounce");break;case WPGMZA.Marker.ANIMATION_DROP:$(this.element).attr("data-anim","drop")}},WPGMZA.OLMarker.prototype.setDraggable=function(draggable){var self=this;if(WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)console.warn("Marker dragging is not currently supported in Vector Layer rendering mode");else if(draggable){draggable={disabled:!1};this.jQueryDraggableInitialized||(draggable.start=function(event){self.onDragStart(event)},draggable.stop=function(event){self.onDragEnd(event)});try{$(this.element).draggable(draggable),this.jQueryDraggableInitialized=!0,this.rebindClickListener()}catch(ex){}}else $(this.element).draggable({disabled:!0})},WPGMZA.OLMarker.prototype.setOpacity=function(opacity){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?console.warn("Marker opacity is not currently supported in Vector Layer rendering mode"):$(this.element).css({opacity:opacity})},WPGMZA.OLMarker.prototype.onDragStart=function(event){this.isBeingDragged=!0,this.map.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan&&interaction.setActive(!1)})},WPGMZA.OLMarker.prototype.onDragEnd=function(event){var offset_top=parseFloat($(this.element).css("top").match(/-?\d+/)[0]),offset_left=parseFloat($(this.element).css("left").match(/-?\d+/)[0]),currentLatLng=($(this.element).css({top:"0px",left:"0px"}),this.getPosition()),currentLatLng=this.map.latLngToPixels(currentLatLng),offset_left={x:currentLatLng.x+offset_left,y:currentLatLng.y+offset_top},currentLatLng=this.map.pixelsToLatLng(offset_left);this.setPosition(currentLatLng),this.isBeingDragged=!1,this.trigger({type:"dragend",latLng:currentLatLng}),this.trigger("change"),"yes"!=this.map.settings.wpgmza_settings_map_draggable&&this.map.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan&&interaction.setActive(!0)})},WPGMZA.OLMarker.prototype.onElementClick=function(event){event=event.currentTarget.wpgmzaMarker;event.isBeingDragged||(event.dispatchEvent("click"),event.dispatchEvent("select"))},WPGMZA.OLMarker.prototype.rebindClickListener=function(){$(this.element).off("click",this.onElementClick),$(this.element).on("click",this.onElementClick)}}),jQuery(function($){WPGMZA.OLModernStoreLocatorCircle=function(map,settings){WPGMZA.ModernStoreLocatorCircle.call(this,map,settings)},WPGMZA.OLModernStoreLocatorCircle.prototype=Object.create(WPGMZA.ModernStoreLocatorCircle.prototype),WPGMZA.OLModernStoreLocatorCircle.prototype.constructor=WPGMZA.OLModernStoreLocatorCircle,WPGMZA.OLModernStoreLocatorCircle.prototype.initCanvasLayer=function(){var self=this,olViewportElement=$(this.map.element).children(".ol-viewport");this.canvas=document.createElement("canvas"),this.canvas.className="wpgmza-ol-canvas-overlay",olViewportElement.find(".ol-layers .ol-layer:first-child").prepend(this.canvas),this.renderFunction=function(event){self.canvas.width==olViewportElement.width()&&self.canvas.height==olViewportElement.height()||(self.canvas.width=olViewportElement.width(),self.canvas.height=olViewportElement.height(),$(this.canvas).css({width:olViewportElement.width()+"px",height:olViewportElement.height()+"px"})),self.draw()},this.map.olMap.on("postrender",this.renderFunction)},WPGMZA.OLModernStoreLocatorCircle.prototype.getContext=function(type){return this.canvas.getContext(type)},WPGMZA.OLModernStoreLocatorCircle.prototype.getCanvasDimensions=function(){return{width:this.canvas.width,height:this.canvas.height}},WPGMZA.OLModernStoreLocatorCircle.prototype.getCenterPixels=function(){return this.map.latLngToPixels(this.settings.center)},WPGMZA.OLModernStoreLocatorCircle.prototype.getWorldOriginOffset=function(){return{x:0,y:0}},WPGMZA.OLModernStoreLocatorCircle.prototype.getTransformedRadius=function(km){var center=new WPGMZA.LatLng(this.settings.center),outer=new WPGMZA.LatLng(center),km=(outer.moveByDistance(km,90),this.map.latLngToPixels(center)),center=this.map.latLngToPixels(outer);return Math.abs(center.x-km.x)},WPGMZA.OLModernStoreLocatorCircle.prototype.getScale=function(){return 1},WPGMZA.OLModernStoreLocatorCircle.prototype.destroy=function(){$(this.canvas).remove(),this.map.olMap.un("postrender",this.renderFunction),this.map=null,this.canvas=null}}),jQuery(function($){WPGMZA.OLModernStoreLocator=function(map_id){WPGMZA.ModernStoreLocator.call(this,map_id),(WPGMZA.isProVersion()?$(".wpgmza_map[data-map-id='"+map_id+"']"):$("#wpgmza_map")).append(this.element)},WPGMZA.OLModernStoreLocator.prototype=Object.create(WPGMZA.ModernStoreLocator),WPGMZA.OLModernStoreLocator.prototype.constructor=WPGMZA.OLModernStoreLocator}),jQuery(function($){var Parent=WPGMZA.Pointlabel;WPGMZA.OLPointlabel=function(options,pointFeature){Parent.call(this,options,pointFeature),pointFeature&&pointFeature.textFeature?this.textFeature=pointFeature.textFeature:this.textFeature=new WPGMZA.Text.createInstance({text:"",map:this.map,position:this.getPosition()}),this.updateNativeFeature()},Parent=WPGMZA.isProVersion()?WPGMZA.ProPointlabel:WPGMZA.Pointlabel,WPGMZA.extend(WPGMZA.OLPointlabel,Parent),WPGMZA.OLPointlabel.prototype.updateNativeFeature=function(){var options=this.getScalarProperties();options.name&&this.textFeature.setText(options.name),this.textFeature.refresh()}}),jQuery(function($){var Parent;WPGMZA.OLPolygon=function(options,olFeature){if(Parent.call(this,options,olFeature),olFeature)this.olFeature=olFeature;else{var coordinates=[[]];if(options&&options.polydata)for(var paths=this.parseGeometry(options.polydata),i=0;i<=paths.length;i++)coordinates[0].push(ol.proj.fromLonLat([parseFloat(paths[i%paths.length].lng),parseFloat(paths[i%paths.length].lat)]));this.olFeature=new ol.Feature({geometry:new ol.geom.Polygon(coordinates)})}this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]})}),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaPolygon:this,wpgmzaFeature:this}),options&&this.setOptions(options)},Parent=WPGMZA.isProVersion()?WPGMZA.ProPolygon:WPGMZA.Polygon,WPGMZA.OLPolygon.prototype=Object.create(Parent.prototype),WPGMZA.OLPolygon.prototype.constructor=WPGMZA.OLPolygon,WPGMZA.OLPolygon.prototype.getGeometry=function(){for(var coordinates=this.olFeature.getGeometry().getCoordinates()[0],result=[],i=0;i<coordinates.length;i++){var lonLat=ol.proj.toLonLat(coordinates[i]),lonLat={lat:lonLat[1],lng:lonLat[0]};result.push(lonLat)}return result},WPGMZA.OLPolygon.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){var Parent;WPGMZA.OLPolyline=function(options,olFeature){if(WPGMZA.Polyline.call(this,options),olFeature)this.olFeature=olFeature;else{var coordinates=[];if(options&&options.polydata)for(var path=this.parseGeometry(options.polydata),i=0;i<path.length;i++){if(!$.isNumeric(path[i].lat))throw new Error("Invalid latitude");if(!$.isNumeric(path[i].lng))throw new Error("Invalid longitude");coordinates.push(ol.proj.fromLonLat([parseFloat(path[i].lng),parseFloat(path[i].lat)]))}this.olFeature=new ol.Feature({geometry:new ol.geom.LineString(coordinates)})}this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]})}),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaPolyline:this,wpgmzaFeature:this}),options&&this.setOptions(options)},Parent=WPGMZA.Polyline,WPGMZA.OLPolyline.prototype=Object.create(Parent.prototype),WPGMZA.OLPolyline.prototype.constructor=WPGMZA.OLPolyline,WPGMZA.OLPolyline.prototype.getGeometry=function(){for(var result=[],coordinates=this.olFeature.getGeometry().getCoordinates(),i=0;i<coordinates.length;i++){var lonLat=ol.proj.toLonLat(coordinates[i]),lonLat={lat:lonLat[1],lng:lonLat[0]};result.push(lonLat)}return result},WPGMZA.OLPolyline.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){var Parent=WPGMZA.Rectangle;WPGMZA.OLRectangle=function(options,olFeature){var coordinates;Parent.apply(this,arguments),olFeature?this.olFeature=olFeature:(coordinates=[[]],options.cornerA&&options.cornerB&&(coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerA.lng),parseFloat(options.cornerA.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerB.lng),parseFloat(options.cornerA.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerB.lng),parseFloat(options.cornerB.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerA.lng),parseFloat(options.cornerB.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerA.lng),parseFloat(options.cornerA.lat)]))),this.olFeature=new ol.Feature({geometry:new ol.geom.Polygon(coordinates)})),this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]}),style:this.olStyle}),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaRectangle:this,wpgmzaFeature:this}),options&&this.setOptions(options)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProRectangle),WPGMZA.extend(WPGMZA.OLRectangle,Parent),WPGMZA.OLRectangle.prototype.getBounds=function(){var extent=this.olFeature.getGeometry().getExtent(),topLeft=ol.extent.getTopLeft(extent),extent=ol.extent.getBottomRight(extent),topLeft=ol.proj.toLonLat(topLeft),extent=ol.proj.toLonLat(extent),topLeft=new WPGMZA.LatLng(topLeft[1],topLeft[0]),extent=new WPGMZA.LatLng(extent[1],extent[0]);return new WPGMZA.LatLngBounds(topLeft,extent)},WPGMZA.OLRectangle.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){WPGMZA.OLText=function(options){WPGMZA.Text.apply(this,arguments),this.overlay=new WPGMZA.OLTextOverlay(options)},WPGMZA.extend(WPGMZA.OLText,WPGMZA.Text),WPGMZA.OLText.prototype.refresh=function(){this.overlay&&this.overlay.refresh()}}),jQuery(function($){WPGMZA.OLTextOverlay=function(options){var coords;options.position&&options.map&&(coords=ol.proj.fromLonLat([options.position.lng,options.position.lat]),this.olFeature=new ol.Feature({geometry:new ol.geom.Point(coords)}),this.styleOptions=options||{},this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]}),style:this.getStyle()}),this.layer.setZIndex(10),options.map.olMap.addLayer(this.layer))},WPGMZA.OLTextOverlay.prototype.getStyle=function(){var i,defaults={fontSize:11,fillColor:"#000000",strokeColor:"#ffffff"};for(i in defaults)void 0===this.styleOptions[i]&&(this.styleOptions[i]=defaults[i]);let labelStyles=new ol.style.Style({text:new ol.style.Text({font:"bold "+this.styleOptions.fontSize+'px "Open Sans", "Arial Unicode MS", "sans-serif"',placement:"point",fill:new ol.style.Fill({color:this.styleOptions.fillColor}),stroke:new ol.style.Stroke({color:this.styleOptions.strokeColor,width:1})})});return labelStyles.getText().setText(this.styleOptions.text||""),labelStyles},WPGMZA.OLTextOverlay.prototype.refresh=function(){this.layer&&this.layer.setStyle(this.getStyle())},WPGMZA.OLTextOverlay.prototype.setPosition=function(position){this.olFeature&&(position=ol.proj.fromLonLat([parseFloat(position.lng),parseFloat(position.lat)]),this.olFeature.setGeometry(new ol.geom.Point(position)))},WPGMZA.OLTextOverlay.prototype.setText=function(text){this.styleOptions.text=text},WPGMZA.OLTextOverlay.prototype.setFontSize=function(size){size=parseInt(size),this.styleOptions.fontSize=size},WPGMZA.OLTextOverlay.prototype.setFillColor=function(color){color.match(/^#/)||(color="#"+color),this.styleOptions.fillColor=color},WPGMZA.OLTextOverlay.prototype.setLineColor=function(color){color.match(/^#/)||(color="#"+color),this.styleOptions.strokeColor=color},WPGMZA.OLTextOverlay.prototype.setOpacity=function(opacity){1<(opacity=parseFloat(opacity))?opacity=1:opacity<0&&(opacity=0),this.layer&&this.layer.setOpacity(opacity)},WPGMZA.OLTextOverlay.prototype.remove=function(){this.styleOptions.map&&this.styleOptions.map.olMap.removeLayer(this.layer)}}),jQuery(function($){WPGMZA.OLThemeEditor=function(){var self=this;WPGMZA.EventDispatcher.call(this),this.element=$("#wpgmza-ol-theme-editor"),this.element.length?(this.mapElement=WPGMZA.maps[0].element,$(this.element).find('input[name="wpgmza_ol_tile_filter"]').on("change",function(event){self.onFilterChange(event.currentTarget)})):console.warn("No element to initialise theme editor on")},WPGMZA.extend(WPGMZA.OLThemeEditor,WPGMZA.EventDispatcher),WPGMZA.OLThemeEditor.prototype.onFilterChange=function(context){context instanceof HTMLInputElement&&(context=$(context).val(),this.mapElement&&$(this.mapElement).css("--wpgmza-ol-tile-filter",context))}}),jQuery(function($){WPGMZA.OLThemePanel=function(){var self=this;this.element=$("#wpgmza-ol-theme-panel"),this.map=WPGMZA.maps[0],this.element.length?(this.element.on("click","#wpgmza-theme-presets label, .theme-selection-panel label",function(event){self.onThemePresetClick(event)}),WPGMZA.OLThemePanel=this):console.warn("No element to initialise theme panel on")},WPGMZA.OLThemePanel.prototype.onThemePresetClick=function(event){if(event.currentTarget){const element=$(event.currentTarget);event=element.data("filter");if(event&&$('input[name="wpgmza_ol_tile_filter"]').length){const input=$('input[name="wpgmza_ol_tile_filter"]').get(0);input.wpgmzaCSSFilterInput&&input.wpgmzaCSSFilterInput.parseFilters(event)}}}}),jQuery(function($){WPGMZA.DataTable=function(element){var version,self=this;if(!$.fn.dataTable)return console.warn("The dataTables library is not loaded. Cannot create a dataTable. Did you enable 'Do not enqueue dataTables'?"),void(WPGMZA.settings.wpgmza_do_not_enqueue_datatables&&WPGMZA.getCurrentPage()==WPGMZA.PAGE_MAP_EDIT&&alert("You have selected 'Do not enqueue DataTables' in WP Go Maps' settings. No 3rd party software is loading the DataTables library. Because of this, the marker table cannot load. Please uncheck this option to use the marker table."));$.fn.dataTable.ext?$.fn.dataTable.ext.errMode="throw":(version=$.fn.dataTable.version||"unknown",console.warn("You appear to be running an outdated or modified version of the dataTables library. This may cause issues with table functionality. This is usually caused by 3rd party software loading an older version of DataTables. The loaded version is "+version+", we recommend version 1.10.12 or above.")),$.fn.dataTable.Api&&$.fn.dataTable.Api.register("processing()",function(show){return this.iterator("table",function(ctx){ctx.oApi._fnProcessingDisplay(ctx,show)})}),this.element=element,(this.element.wpgmzaDataTable=this).dataTableElement=this.getDataTableElement();var settings=this.getDataTableSettings();this.phpClass=$(element).attr("data-wpgmza-php-class"),(this.wpgmzaDataTable=this).useCompressedPathVariable=WPGMZA.restAPI.isCompressedPathVariableSupported&&WPGMZA.settings.enable_compressed_path_variables,this.method=this.useCompressedPathVariable?"GET":"POST",null==this.getLanguageURL()||"//cdn.datatables.net/plug-ins/1.10.12/i18n/English.json"==this.getLanguageURL()?(this.dataTable=$(this.dataTableElement).DataTable(settings),this.dataTable.ajax.reload()):$.ajax(this.getLanguageURL(),{success:function(response,status,xhr){self.languageJSON=response,self.dataTable=$(self.dataTableElement).DataTable(settings),self.dataTable.ajax.reload()}})},WPGMZA.DataTable.prototype.getDataTableElement=function(){return $(this.element).find("table")},WPGMZA.DataTable.prototype.onAJAXRequest=function(data,settings){var params={phpClass:this.phpClass},attr=$(this.element).attr("data-wpgmza-ajax-parameters");return attr&&$.extend(params,JSON.parse(attr)),$.extend(data,params)},WPGMZA.DataTable.prototype.onDataTableAjaxRequest=function(data,callback,settings){var self=this,element=this.element,element=$(element).attr("data-wpgmza-rest-api-route"),data=this.onAJAXRequest(data,settings),draw=data.draw;if(delete data.draw,!element)throw new Error("No data-wpgmza-rest-api-route attribute specified");settings={method:"POST",useCompressedPathVariable:!0,data:data,dataType:"json",cache:!this.preventCaching,beforeSend:function(xhr){xhr.setRequestHeader("X-DataTables-Draw",draw)},success:function(response,status,xhr){response.draw=draw,self.lastResponse=response,callback(response),$("[data-marker-icon-src]").each(function(index,element){WPGMZA.MarkerIcon.createInstance($(element).attr("data-marker-icon-src")).applyToElement(element)})}};return WPGMZA.restAPI.call(element,settings)},WPGMZA.DataTable.prototype.getDataTableSettings=function(){var self=this,element=this.element,options={},element=((options=$(element).attr("data-wpgmza-datatable-options")?JSON.parse($(element).attr("data-wpgmza-datatable-options")):options).deferLoading=!0,options.processing=!0,options.serverSide=!0,options.ajax=function(data,callback,settings){return WPGMZA.DataTable.prototype.onDataTableAjaxRequest.apply(self,arguments)},WPGMZA.AdvancedTableDataTable&&this instanceof WPGMZA.AdvancedTableDataTable&&WPGMZA.settings.wpgmza_default_items&&(options.iDisplayLength=parseInt(WPGMZA.settings.wpgmza_default_items)),options.aLengthMenu=[[5,10,25,50,100,-1],["5","10","25","50","100",WPGMZA.localized_strings.all]],this.getLanguageURL());return element&&(options.language={url:element}),options},WPGMZA.DataTable.prototype.getLanguageURL=function(){if(!WPGMZA.locale)return null;var languageURL;switch(WPGMZA.locale.substr(0,2)){case"af":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Afrikaans.json";break;case"sq":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Albanian.json";break;case"am":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Amharic.json";break;case"ar":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Arabic.json";break;case"hy":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Armenian.json";break;case"az":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Azerbaijan.json";break;case"bn":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Bangla.json";break;case"eu":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Basque.json";break;case"be":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Belarusian.json";break;case"bg":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Bulgarian.json";break;case"ca":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Catalan.json";break;case"zh":languageURL="zh_TW"==WPGMZA.locale?WPGMZA.pluginDirURL+"languages/datatables/Chinese-traditional.json":"//cdn.datatables.net/plug-ins/1.10.12/i18n/Chinese.json";break;case"hr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Croatian.json";break;case"cs":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Czech.json";break;case"da":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Danish.json";break;case"nl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Dutch.json";break;case"et":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Estonian.json";break;case"fi":languageURL=WPGMZA.locale.match(/^fil/)?WPGMZA.pluginDirURL+"languages/datatables/Filipino.json":WPGMZA.pluginDirURL+"languages/datatables/Finnish.json";break;case"fr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/French.json";break;case"gl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Galician.json";break;case"ka":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Georgian.json";break;case"de":languageURL=WPGMZA.pluginDirURL+"languages/datatables/German.json";break;case"el":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Greek.json";break;case"gu":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Gujarati.json";break;case"he":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Hebrew.json";break;case"hi":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Hindi.json";break;case"hu":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Hungarian.json";break;case"is":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Icelandic.json";break;case"id":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Indonesian.json";break;case"ga":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Irish.json";break;case"it":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Italian.json";break;case"ja":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Japanese.json";break;case"kk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Kazakh.json";break;case"ko":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Korean.json";break;case"ky":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Kyrgyz.json";break;case"lv":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Latvian.json";break;case"lt":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Lithuanian.json";break;case"mk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Macedonian.json";break;case"ml":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Malay.json";break;case"mn":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Mongolian.json";break;case"ne":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Nepali.json";break;case"nb":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Norwegian-Bokmal.json";break;case"nn":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Norwegian-Nynorsk.json";break;case"ps":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Pashto.json";break;case"fa":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Persian.json";break;case"pl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Polish.json";break;case"pt":languageURL="pt_BR"==WPGMZA.locale?WPGMZA.pluginDirURL+"languages/datatables/Portuguese-Brasil.json":"//cdn.datatables.net/plug-ins/1.10.12/i18n/Portuguese.json";break;case"ro":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Romanian.json";break;case"ru":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Russian.json";break;case"sr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Serbian.json";break;case"si":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Sinhala.json";break;case"sk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Slovak.json";break;case"sl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Slovenian.json";break;case"es":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Spanish.json";break;case"sw":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Swahili.json";break;case"sv":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Swedish.json";break;case"ta":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Tamil.json";break;case"te":languageURL=WPGMZA.pluginDirURL+"languages/datatables/telugu.json";break;case"th":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Thai.json";break;case"tr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Turkish.json";break;case"uk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Ukrainian.json";break;case"ur":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Urdu.json";break;case"uz":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Uzbek.json";break;case"vi":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Vietnamese.json";break;case"cy":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Welsh.json"}return languageURL},WPGMZA.DataTable.prototype.onAJAXResponse=function(response){},WPGMZA.DataTable.prototype.reload=function(){this.dataTable.ajax.reload(null,!1)}}),jQuery(function($){WPGMZA.AdminFeatureDataTable=function(element){var self=this;this.allSelected=!1,WPGMZA.DataTable.call(this,element),this.initModals(),$(element).on("click",".wpgmza.bulk_delete",function(event){self.onBulkDelete(event)}),$(element).on("click",".wpgmza.select_all_markers",function(event){self.onSelectAll(event)}),$(element).on("click",".wpgmza.bulk_edit",function(event){self.onBulkEdit(event)}),$(element).on("click","[data-center-marker-id]",function(event){self.onCenterMarker(event)}),$(element).on("click","[data-duplicate-feature-id]",function(event){self.onDuplicate(event)}),$(element).on("click","[data-move-map-feature-id]",function(event){self.onMoveMap(event)})},WPGMZA.extend(WPGMZA.AdminFeatureDataTable,WPGMZA.DataTable),Object.defineProperty(WPGMZA.AdminFeatureDataTable.prototype,"featureType",{get:function(){return $(this.element).attr("data-wpgmza-feature-type")}}),Object.defineProperty(WPGMZA.AdminFeatureDataTable.prototype,"featurePanel",{get:function(){return WPGMZA.mapEditPage[this.featureType+"Panel"]}}),WPGMZA.AdminFeatureDataTable.prototype.initModals=function(){this.moveModal=!1,this.bulkEditorModal=!1,"marker"===this.featureType&&($(".wpgmza-map-select-modal").length&&(this.moveModal=WPGMZA.GenericModal.createInstance($(".wpgmza-map-select-modal"))),$(".wpgmza-bulk-marker-editor-modal").length&&(this.bulkEditorModal=WPGMZA.GenericModal.createInstance($(".wpgmza-bulk-marker-editor-modal"))))},WPGMZA.AdminFeatureDataTable.prototype.getDataTableSettings=function(){var self=this,options=WPGMZA.DataTable.prototype.getDataTableSettings.call(this);return options.createdRow=function(row,data,index){index=self.lastResponse.meta[index];row.wpgmzaFeatureData=index},options},WPGMZA.AdminFeatureDataTable.prototype.onBulkDelete=function(event){var self=this,ids=[],map=WPGMZA.maps[0],plural=this.featureType+"s";$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaFeatureData.id)}),confirm(WPGMZA.localized_strings.general_delete_prompt_text)&&(ids.forEach(function(marker_id){marker_id=map.getMarkerByID(marker_id);marker_id&&map.removeMarker(marker_id)}),WPGMZA.restAPI.call("/"+plural+"/",{method:"DELETE",data:{ids:ids},complete:function(){self.reload()}}))},WPGMZA.AdminFeatureDataTable.prototype.onSelectAll=function(event){this.allSelected=!this.allSelected;var self=this;$(this.element).find("input[name='mark']").each(function(){self.allSelected?$(this).prop("checked",!0):$(this).prop("checked",!1)})},WPGMZA.AdminFeatureDataTable.prototype.onBulkEdit=function(event){const self=this,ids=[];WPGMZA.maps[0];const plural=this.featureType+"s";$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaFeatureData.id)}),this.bulkEditorModal&&ids.length&&this.bulkEditorModal.show(function(data){data.ids=ids,data.action="bulk_edit",WPGMZA.restAPI.call("/"+plural+"/",{method:"POST",data:data,success:function(response,status,xhr){self.reload()}})})},WPGMZA.AdminFeatureDataTable.prototype.onCenterMarker=function(event){var event=null==event.currentTarget?event:$(event.currentTarget).attr("data-center-marker-id"),event=WPGMZA.mapEditPage.map.getMarkerByID(event);event&&(event=new WPGMZA.LatLng({lat:event.lat,lng:event.lng}),WPGMZA.mapEditPage.map.setCenter(event),WPGMZA.InternalEngine.isLegacy()&&WPGMZA.animateScroll("#wpgmaps_tabs_markers"))},WPGMZA.AdminFeatureDataTable.prototype.onDuplicate=function(event){const self=this;let id=!1;id=null==event.currentTarget?event:$(event.currentTarget).attr("data-duplicate-feature-id");event=this.featureType+"s";WPGMZA.restAPI.call("/"+event+"/",{method:"POST",data:{id:id,action:"duplicate"},success:function(response,status,xhr){self.reload()}})},WPGMZA.AdminFeatureDataTable.prototype.onMoveMap=function(event){const self=this;let id=!1,plural=(id=null==event.currentTarget?event:$(event.currentTarget).attr("data-move-map-feature-id"),this.featureType+"s");this.moveModal&&this.moveModal.show(function(data){data=!!data.map_id&&parseInt(data.map_id);data&&WPGMZA.restAPI.call("/"+plural+"/",{method:"POST",data:{id:id,map_id:data,action:"move_map"},success:function(response,status,xhr){self.reload()}})})}}),jQuery(function($){WPGMZA.AdminMapDataTable=function(element){var self=this;this.allSelected=!1,WPGMZA.DataTable.call(this,element),$(element).on("mousedown","button[data-action='edit']",function(event){switch(event.which){case 1:var map_id=$(event.target).attr("data-map-id");window.location.href=window.location.href+"&action=edit&map_id="+map_id;break;case 2:map_id=$(event.target).attr("data-map-id");window.open(window.location.href+"&action=edit&map_id="+map_id)}}),$(element).find(".wpgmza.select_all_maps").on("click",function(event){self.onSelectAll(event)}),$(element).find(".wpgmza.bulk_delete_maps").on("click",function(event){self.onBulkDelete(event)}),$(element).on("click","button[data-action='duplicate']",function(event){event=$(event.target).attr("data-map-id");WPGMZA.restAPI.call("/maps/",{method:"POST",data:{id:event,action:"duplicate"},success:function(response,status,xhr){self.reload()}})}),$(element).on("click","button[data-action='trash']",function(event){confirm(WPGMZA.localized_strings.map_delete_prompt_text)&&(event=$(event.target).attr("data-map-id"),WPGMZA.restAPI.call("/maps/",{method:"DELETE",data:{id:event},success:function(response,status,xhr){self.reload()}}))})},WPGMZA.extend(WPGMZA.AdminMapDataTable,WPGMZA.DataTable),WPGMZA.AdminMapDataTable.prototype.getDataTableSettings=function(){var self=this,options=WPGMZA.DataTable.prototype.getDataTableSettings.call(this);return options.createdRow=function(row,data,index){index=self.lastResponse.meta[index];row.wpgmzaMapData=index},options},WPGMZA.AdminMapDataTable.prototype.onSelectAll=function(event){this.allSelected=!this.allSelected;var self=this;$(this.element).find("input[name='mark']").each(function(){self.allSelected?$(this).prop("checked",!0):$(this).prop("checked",!1)})},WPGMZA.AdminMapDataTable.prototype.onBulkDelete=function(event){var self=this,ids=[];$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaMapData.id)}),confirm(WPGMZA.localized_strings.map_bulk_delete_prompt_text)&&WPGMZA.restAPI.call("/maps/",{method:"DELETE",data:{ids:ids},complete:function(){self.reload()}})},$(document).ready(function(event){$("[data-wpgmza-admin-map-datatable]").each(function(index,el){WPGMZA.AdminMapDataTable=new WPGMZA.AdminMapDataTable(el)})})}),jQuery(function($){WPGMZA.AdminMarkerDataTable=function(element){var self=this;this.preventCaching=!0,WPGMZA.DataTable.call(this,element),$(element).on("click","[data-delete-marker-id]",function(event){self.onDeleteMarker(event)}),$(element).find(".wpgmza.select_all_markers").on("click",function(event){self.onSelectAll(event)}),$(element).find(".wpgmza.bulk_delete").on("click",function(event){self.onBulkDelete(event)}),$(element).on("click","[data-center-marker-id]",function(event){self.onCenterMarker(event)})},WPGMZA.AdminMarkerDataTable.prototype=Object.create(WPGMZA.DataTable.prototype),WPGMZA.AdminMarkerDataTable.prototype.constructor=WPGMZA.AdminMarkerDataTable,WPGMZA.AdminMarkerDataTable.createInstance=function(element){return new WPGMZA.AdminMarkerDataTable(element)},WPGMZA.AdminMarkerDataTable.prototype.getDataTableSettings=function(){var self=this,options=WPGMZA.DataTable.prototype.getDataTableSettings.call(this);return options.createdRow=function(row,data,index){index=self.lastResponse.meta[index];row.wpgmzaMarkerData=index},options},WPGMZA.AdminMarkerDataTable.prototype.onEditMarker=function(event){WPGMZA.animatedScroll("#wpgmaps_tabs_markers")},WPGMZA.AdminMarkerDataTable.prototype.onDeleteMarker=function(event){var self=this,id=$(event.currentTarget).attr("data-delete-marker-id"),event={action:"delete_marker",security:WPGMZA.legacyajaxnonce,map_id:WPGMZA.mapEditPage.map.id,marker_id:id};$.post(ajaxurl,event,function(response){WPGMZA.mapEditPage.map.removeMarkerByID(id),self.reload()})},WPGMZA.AdminMarkerDataTable.prototype.onApproveMarker=function(event){var cur_id=$(this).attr("id"),cur_id={action:"approve_marker",security:WPGMZA.legacyajaxnonce,map_id:WPGMZA.mapEditPage.map.id,marker_id:cur_id};$.post(ajaxurl,cur_id,function(response){wpgmza_InitMap(),wpgmza_reinitialisetbl()})},WPGMZA.AdminMarkerDataTable.prototype.onSelectAll=function(event){$(this.element).find("input[name='mark']").prop("checked",!0)},WPGMZA.AdminMarkerDataTable.prototype.onBulkDelete=function(event){var self=this,ids=[],map=WPGMZA.maps[0];$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaMarkerData.id)}),ids.forEach(function(marker_id){marker_id=map.getMarkerByID(marker_id);marker_id&&map.removeMarker(marker_id)}),WPGMZA.restAPI.call("/markers/",{method:"DELETE",data:{ids:ids},complete:function(){self.reload()}})},WPGMZA.AdminMarkerDataTable.prototype.onCenterMarker=function(event){var event=null==event.currentTarget?event:$(event.currentTarget).attr("data-center-marker-id"),event=WPGMZA.mapEditPage.map.getMarkerByID(event);event&&(event=new WPGMZA.LatLng({lat:event.lat,lng:event.lng}),WPGMZA.mapEditPage.map.setCenter(event),WPGMZA.mapEditPage.map.setZoom(6),WPGMZA.InternalEngine.isLegacy()&&WPGMZA.animateScroll("#wpgmaps_tabs_markers"))}});
1
+ jQuery(function($){var core={MARKER_PULL_DATABASE:"0",MARKER_PULL_XML:"1",PAGE_MAP_LIST:"map-list",PAGE_MAP_EDIT:"map-edit",PAGE_SETTINGS:"map-settings",PAGE_STYLING:"map-styling",PAGE_SUPPORT:"map-support",PAGE_INSTALLER:"installer",PAGE_CATEGORIES:"categories",PAGE_ADVANCED:"advanced",PAGE_CUSTOM_FIELDS:"custom-fields",maps:[],events:null,settings:null,restAPI:null,localized_strings:null,loadingHTML:'<div class="wpgmza-preloader"><div class="wpgmza-loader">...</div></div>',preloaderHTML:"<div class='wpgmza-preloader'><div></div><div></div><div></div><div></div></div>",getCurrentPage:function(){switch(WPGMZA.getQueryParamValue("page")){case"wp-google-maps-menu":return window.location.href.match(/action=edit/)&&window.location.href.match(/map_id=\d+/)?WPGMZA.PAGE_MAP_EDIT:window.location.href.match(/action=installer/)?WPGMZA.PAGE_INSTALLER:WPGMZA.PAGE_MAP_LIST;case"wp-google-maps-menu-settings":return WPGMZA.PAGE_SETTINGS;case"wp-google-maps-menu-styling":return WPGMZA.PAGE_STYLING;case"wp-google-maps-menu-support":return WPGMZA.PAGE_SUPPORT;case"wp-google-maps-menu-categories":return WPGMZA.PAGE_CATEGORIES;case"wp-google-maps-menu-advanced":return WPGMZA.PAGE_ADVANCED;case"wp-google-maps-menu-custom-fields":return WPGMZA.PAGE_CUSTOM_FIELDS;default:return null}},getScrollAnimationOffset:function(){return(WPGMZA.settings.scroll_animation_offset||0)+($("#wpadminbar").height()||0)},getScrollAnimationDuration:function(){return WPGMZA.settings.scroll_animation_milliseconds||500},animateScroll:function(element,milliseconds){var offset=WPGMZA.getScrollAnimationOffset();milliseconds=milliseconds||WPGMZA.getScrollAnimationDuration(),$("html, body").animate({scrollTop:$(element).offset().top-offset},milliseconds)},extend:function(child,parent){var constructor=child;child.prototype=Object.create(parent.prototype),child.prototype.constructor=constructor},guid:function(){var d=(new Date).getTime();return"undefined"!=typeof performance&&"function"==typeof performance.now&&(d+=performance.now()),"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(c){var r=(d+16*Math.random())%16|0;return d=Math.floor(d/16),("x"===c?r:3&r|8).toString(16)})},hexOpacityToRGBA:function(colour,opacity){colour=parseInt(colour.replace(/^#/,""),16);return[(16711680&colour)>>16,(65280&colour)>>8,255&colour,parseFloat(opacity)]},hexOpacityToString:function(colour,opacity){colour=WPGMZA.hexOpacityToRGBA(colour,opacity);return"rgba("+colour[0]+", "+colour[1]+", "+colour[2]+", "+colour[3]+")"},hexToRgba:function(hex){return/^#([A-Fa-f0-9]{3}){1,2}$/.test(hex)?{r:(hex="0x"+(hex=3==(hex=hex.substring(1).split("")).length?[hex[0],hex[0],hex[1],hex[1],hex[2],hex[2]]:hex).join(""))>>16&255,g:hex>>8&255,b:255&hex,a:1}:0},rgbaToString:function(rgba){return"rgba("+rgba.r+", "+rgba.g+", "+rgba.b+", "+rgba.a+")"},latLngRegexp:/^(\-?\d+(\.\d+)?),\s*(\-?\d+(\.\d+)?)$/,isLatLngString:function(str){if("string"!=typeof str)return null;str=(str=str.match(/^\(.+\)$/)?str.replace(/^\(|\)$/,""):str).match(WPGMZA.latLngRegexp);return str?new WPGMZA.LatLng({lat:parseFloat(str[1]),lng:parseFloat(str[3])}):null},stringToLatLng:function(str){str=WPGMZA.isLatLngString(str);if(str)return str;throw new Error("Not a valid latLng")},isHexColorString:function(str){return"string"==typeof str&&!!str.match(/#[0-9A-F]{6}/i)},imageDimensionsCache:{},getImageDimensions:function(src,callback){var img;WPGMZA.imageDimensionsCache[src]?callback(WPGMZA.imageDimensionsCache[src]):((img=document.createElement("img")).onload=function(event){var result={width:img.width,height:img.height};WPGMZA.imageDimensionsCache[src]=result,callback(result)},img.src=src)},decodeEntities:function(input){return input.replace(/&(nbsp|amp|quot|lt|gt);/g,function(m,e){return m[e]}).replace(/&#(\d+);/gi,function(m,e){return String.fromCharCode(parseInt(e,10))})},isDeveloperMode:function(){return this.settings.developer_mode||window.Cookies&&window.Cookies.get("wpgmza-developer-mode")},isProVersion:function(){return"1"==this._isProVersion},openMediaDialog:function(callback,config){var file_frame;if(file_frame)return file_frame.uploader.uploader.param("post_id",set_to_post_id),void file_frame.open();(file_frame=wp.media.frames.file_frame=config?wp.media(config):wp.media({title:"Select a image to upload",button:{text:"Use this image"},multiple:!1})).on("select",function(){attachment=file_frame.state().get("selection").first().toJSON(),callback(attachment.id,attachment.url,attachment)}),file_frame.open()},getCurrentPosition:function(callback,error,watch){var options,nativeFunction="getCurrentPosition";WPGMZA.userLocationDenied?error&&error({code:1,message:"Location unavailable"}):(watch&&(nativeFunction="watchPosition"),navigator.geolocation?(options={enableHighAccuracy:!0},navigator.geolocation[nativeFunction]?navigator.geolocation[nativeFunction](function(position){callback&&callback(position),WPGMZA.events.trigger("userlocationfound")},function(err){options.enableHighAccuracy=!1,navigator.geolocation[nativeFunction](function(position){callback&&callback(position),WPGMZA.events.trigger("userlocationfound")},function(err){console.warn(err.code,err.message),1==err.code&&(WPGMZA.userLocationDenied=!0),error&&error(err)},options)},options):console.warn(nativeFunction+" is not available")):console.warn("No geolocation available on this device"))},watchPosition:function(callback,error){return WPGMZA.getCurrentPosition(callback,error,!0)},runCatchableTask:function(callback,friendlyErrorContainer){if(WPGMZA.isDeveloperMode())callback();else try{callback()}catch(e){callback=new WPGMZA.FriendlyError(e);$(friendlyErrorContainer).html(""),$(friendlyErrorContainer).append(callback.element),$(friendlyErrorContainer).show()}},capitalizeWords:function(string){return(string+"").replace(/^(.)|\s+(.)/g,function(m){return m.toUpperCase()})},pluralize:function(string){return WPGMZA.singularize(string)+"s"},singularize:function(string){return string.replace(/s$/,"")},assertInstanceOf:function(instance,instanceName){var pro=WPGMZA.isProVersion()?"Pro":"",engine="open-layers"===WPGMZA.settings.engine?"OL":"Google",pro=WPGMZA[engine+pro+instanceName]&&engine+instanceName!="OLFeature"?engine+pro+instanceName:WPGMZA[pro+instanceName]?pro+instanceName:WPGMZA[engine+instanceName]&&WPGMZA[engine+instanceName].prototype?engine+instanceName:instanceName;if("OLFeature"!=pro&&!(instance instanceof WPGMZA[pro]))throw new Error("Object must be an instance of "+pro+" (did you call a constructor directly, rather than createInstance?)")},getMapByID:function(id){for(var i=0;i<WPGMZA.maps.length;i++)if(WPGMZA.maps[i].id==id)return WPGMZA.maps[i];return null},isGoogleAutocompleteSupported:function(){return!!window.google&&(!!google.maps&&(!!google.maps.places&&(!!google.maps.places.Autocomplete&&(!WPGMZA.CloudAPI||!WPGMZA.CloudAPI.isBeingUsed))))},googleAPIStatus:window.wpgmza_google_api_status,isSafari:function(){var ua=navigator.userAgent.toLowerCase();return ua.match(/safari/i)&&!ua.match(/chrome/i)},isTouchDevice:function(){return"ontouchstart"in window},isDeviceiOS:function(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream||!!navigator.platform&&/iPad|iPhone|iPod/.test(navigator.platform)},isModernComponentStyleAllowed:function(){return!WPGMZA.settings.user_interface_style||"legacy"==WPGMZA.settings.user_interface_style||"modern"==WPGMZA.settings.user_interface_style},isElementInView:function(element){var pageTop=$(window).scrollTop(),pageBottom=pageTop+$(window).height(),elementTop=$(element).offset().top,element=elementTop+$(element).height();return elementTop<pageTop&&pageBottom<element||(pageTop<=elementTop&&elementTop<=pageBottom||pageTop<=element&&element<=pageBottom)},isFullScreen:function(){return wpgmzaisFullScreen},getQueryParamValue:function(name){var name=new RegExp(name+"=([^&#]*)");return(name=window.location.href.match(name))?decodeURIComponent(name[1]):null},notification:function(text,time){switch(arguments.length){case 0:text="",time=4e3;break;case 1:time=4e3}var html='<div class="wpgmza-popup-notification">'+text+"</div>";jQuery("body").append(html),setTimeout(function(){jQuery("body").find(".wpgmza-popup-notification").remove()},time)},initMaps:function(){$(document.body).find(".wpgmza_map:not(.wpgmza-initialized)").each(function(index,el){if(el.wpgmzaMap)console.warn("Element missing class wpgmza-initialized but does have wpgmzaMap property. No new instance will be created");else try{el.wpgmzaMap=WPGMZA.Map.createInstance(el)}catch(ex){console.warn("Map initalization: "+ex)}}),WPGMZA.Map.nextInitTimeoutID=setTimeout(WPGMZA.initMaps,3e3)},initCapsules:function(){WPGMZA.capsuleModules=WPGMZA.CapsuleModules.createInstance()},onScroll:function(){$(".wpgmza_map").each(function(index,el){var isInView=WPGMZA.isElementInView(el);el.wpgmzaScrollIntoViewTriggerFlag?isInView||(el.wpgmzaScrollIntoViewTriggerFlag=!1):isInView&&($(el).trigger("mapscrolledintoview.wpgmza"),el.wpgmzaScrollIntoViewTriggerFlag=!0)})},initInstallerRedirect:function(url){$(".wpgmza-wrap").hide(),window.location.href=url}},wpgmzaisFullScreen=!1;for(key in[]){console.warn("It appears that the built in JavaScript Array has been extended, this can create issues with for ... in loops, which may cause failure.");break}for(key in window.WPGMZA?window.WPGMZA=$.extend(window.WPGMZA,core):window.WPGMZA=core,window.uc&&window.uc.reloadOnOptIn&&(window.uc.reloadOnOptIn("S1pcEj_jZX"),window.uc.reloadOnOptOut("S1pcEj_jZX")),WPGMZA_localized_data){var value=WPGMZA_localized_data[key];WPGMZA[key]=value}var key,wpgmzaisFullScreen=!1;for(key in[]){console.warn("It appears that the built in JavaScript Array has been extended, this can create issues with for ... in loops, which may cause failure.");break}for(key in window.WPGMZA?window.WPGMZA=$.extend(window.WPGMZA,core):window.WPGMZA=core,window.uc&&window.uc.reloadOnOptIn&&(window.uc.reloadOnOptIn("S1pcEj_jZX"),window.uc.reloadOnOptOut("S1pcEj_jZX")),WPGMZA_localized_data){value=WPGMZA_localized_data[key];WPGMZA[key]=value}WPGMZA.settings.useLegacyGlobals=!0,$(document).on("fullscreenchange mozfullscreenchange webkitfullscreenchange",function(){wpgmzaisFullScreen=!!document.fullscreenElement,$(document.body).trigger("fullscreenchange.wpgmza")}),$("body").on("click","#wpgmzaCloseChat",function(e){e.preventDefault(),$.ajax(WPGMZA.ajaxurl,{method:"POST",data:{action:"wpgmza_hide_chat",nonce:WPGMZA_localized_data.ajaxnonce}}),$(".wpgmza-chat-help").remove()}),$(window).on("scroll",WPGMZA.onScroll),$(document.body).on("click","button.wpgmza-api-consent",function(event){Cookies.set("wpgmza-api-consent-given",!0),window.location.reload()}),$(document.body).on("keydown",function(event){event.altKey&&(WPGMZA.altKeyDown=!0)}),$(document.body).on("keyup",function(event){event.altKey||(WPGMZA.altKeyDown=!1)}),$(document.body).on("preinit.wpgmza",function(){$(window).trigger("ready.wpgmza"),$(document.body).trigger("ready.body.wpgmza"),$("script[src*='wp-google-maps.combined.js'], script[src*='wp-google-maps-pro.combined.js']").length&&console.warn("Minified script is out of date, using combined script instead.");var key,elements=$("script[src]").filter(function(){return this.src.match(/(^|\/)jquery\.(min\.)?js(\?|$)/i)});1<elements.length&&console.warn("Multiple jQuery versions detected: ",elements);for(key in[]){console.warn("The Array object has been extended incorrectly by your theme or another plugin. This can cause issues with functionality.");break}"https:"!=window.location.protocol&&(elements='<div class="'+(WPGMZA.InternalEngine.isLegacy()?"":"wpgmza-shadow wpgmza-card wpgmza-pos-relative ")+'notice notice-warning"><p>'+WPGMZA.localized_strings.unsecure_geolocation+"</p></div>",$(".wpgmza-geolocation-setting").first().after($(elements))),WPGMZA.googleAPIStatus&&"USER_CONSENT_NOT_GIVEN"==WPGMZA.googleAPIStatus.code&&jQuery(".wpgmza-gdpr-compliance").length<=0&&($(".wpgmza-inner-stack").hide(),$("button.wpgmza-api-consent").on("click",function(event){Cookies.set("wpgmza-api-consent-given",!0),window.location.reload()}))}),function($){$(function(){WPGMZA.restAPI=WPGMZA.RestAPI.createInstance(),WPGMZA.CloudAPI&&(WPGMZA.cloudAPI=WPGMZA.CloudAPI.createInstance()),$(document.body).trigger("preinit.wpgmza"),WPGMZA.initMaps(),WPGMZA.onScroll(),WPGMZA.initCapsules(),$(document.body).trigger("postinit.wpgmza")})}($)}),jQuery(function($){WPGMZA.Compatibility=function(){this.preventDocumentWriteGoogleMapsAPI()},WPGMZA.Compatibility.prototype.preventDocumentWriteGoogleMapsAPI=function(){var old=document.write;document.write=function(content){content.match&&content.match(/maps\.google/)||old.call(document,content)}},WPGMZA.compatiblityModule=new WPGMZA.Compatibility}),!function(root,factory){"object"==typeof exports?module.exports=factory(root):"function"==typeof define&&define.amd?define([],factory.bind(root,root)):factory(root)}("undefined"!=typeof global?global:this,function(root){if(root.CSS&&root.CSS.escape)return root.CSS.escape;function cssEscape(value){if(0==arguments.length)throw new TypeError("`CSS.escape` requires an argument.");for(var codeUnit,string=String(value),length=string.length,index=-1,result="",firstCodeUnit=string.charCodeAt(0);++index<length;)0==(codeUnit=string.charCodeAt(index))?result+="�":result+=1<=codeUnit&&codeUnit<=31||127==codeUnit||0==index&&48<=codeUnit&&codeUnit<=57||1==index&&48<=codeUnit&&codeUnit<=57&&45==firstCodeUnit?"\\"+codeUnit.toString(16)+" ":(0!=index||1!=length||45!=codeUnit)&&(128<=codeUnit||45==codeUnit||95==codeUnit||48<=codeUnit&&codeUnit<=57||65<=codeUnit&&codeUnit<=90||97<=codeUnit&&codeUnit<=122)?string.charAt(index):"\\"+string.charAt(index);return result}return root.CSS||(root.CSS={}),root.CSS.escape=cssEscape}),jQuery(function($){Math.PI;function deg2rad(deg){return deg*(Math.PI/180)}WPGMZA.Distance={MILES:!0,KILOMETERS:!1,MILES_PER_KILOMETER:.621371,KILOMETERS_PER_MILE:1.60934,uiToMeters:function(uiDistance){return parseFloat(uiDistance)/(WPGMZA.settings.distance_units==WPGMZA.Distance.MILES?WPGMZA.Distance.MILES_PER_KILOMETER:1)*1e3},uiToKilometers:function(uiDistance){return.001*WPGMZA.Distance.uiToMeters(uiDistance)},uiToMiles:function(uiDistance){return WPGMZA.Distance.uiToKilometers(uiDistance)*WPGMZA.Distance.MILES_PER_KILOMETER},kilometersToUI:function(km){return WPGMZA.settings.distance_units==WPGMZA.Distance.MILES?km*WPGMZA.Distance.MILES_PER_KILOMETER:km},between:function(a,b){if(!(a instanceof WPGMZA.LatLng||"lat"in a&&"lng"in a))throw new Error("First argument must be an instance of WPGMZA.LatLng or a literal");if(!(b instanceof WPGMZA.LatLng||"lat"in b&&"lng"in b))throw new Error("Second argument must be an instance of WPGMZA.LatLng or a literal");if(a===b)return 0;var lat1=a.lat,lon1=a.lng,lat2=b.lat,b=b.lng,dLat=deg2rad(lat2-lat1),b=deg2rad(b-lon1),a=Math.sin(dLat/2)*Math.sin(dLat/2)+Math.cos(deg2rad(lat1))*Math.cos(deg2rad(lat2))*Math.sin(b/2)*Math.sin(b/2);return 6371*(2*Math.atan2(Math.sqrt(a),Math.sqrt(1-a)))}}}),jQuery(function($){WPGMZA.EliasFano=function(){if(!WPGMZA.EliasFano.isSupported)throw new Error("Elias Fano encoding is not supported on browsers without Uint8Array");WPGMZA.EliasFano.decodingTablesInitialised||WPGMZA.EliasFano.createDecodingTable()},WPGMZA.EliasFano.isSupported="Uint8Array"in window,WPGMZA.EliasFano.decodingTableHighBits=[],WPGMZA.EliasFano.decodingTableDocIDNumber=null,WPGMZA.EliasFano.decodingTableHighBitsCarryover=null,WPGMZA.EliasFano.createDecodingTable=function(){WPGMZA.EliasFano.decodingTableDocIDNumber=new Uint8Array(256),WPGMZA.EliasFano.decodingTableHighBitsCarryover=new Uint8Array(256);for(var decodingTableHighBits=WPGMZA.EliasFano.decodingTableHighBits,decodingTableDocIDNumber=WPGMZA.EliasFano.decodingTableDocIDNumber,decodingTableHighBitsCarryover=WPGMZA.EliasFano.decodingTableHighBitsCarryover,i=0;i<256;i++){var zeroCount=0;decodingTableHighBits[i]=[];for(var j=7;0<=j;j--)zeroCount=0<(i&1<<j)?(decodingTableHighBits[i][decodingTableDocIDNumber[i]]=zeroCount,decodingTableDocIDNumber[i]++,0):(zeroCount+1)%255;decodingTableHighBitsCarryover[i]=zeroCount}WPGMZA.EliasFano.decodingTablesInitialised=!0},WPGMZA.EliasFano.prototype.encode=function(list){var lastDocID=0,buffer1=0,bufferLength1=0,buffer2=0,bufferLength2=0;if(0==list.length)return result;var compressedBufferPointer1=0,compressedBufferPointer2=0,averageDelta=list[list.length-1]/list.length,averageDeltaLog=Math.log2(averageDelta),lowBitsLength=Math.floor(averageDeltaLog),lowBitsMask=(1<<lowBitsLength)-1,prev=null,averageDeltaLog=Math.floor((2+Math.ceil(Math.log2(averageDelta)))*list.length/8)+6,compressedBuffer=new Uint8Array(averageDeltaLog),result=(lowBitsLength<0&&(lowBitsLength=0),compressedBufferPointer2=Math.floor(lowBitsLength*list.length/8+6),compressedBuffer[compressedBufferPointer1++]=255&list.length,compressedBuffer[compressedBufferPointer1++]=255&list.length>>8,compressedBuffer[compressedBufferPointer1++]=255&list.length>>16,compressedBuffer[compressedBufferPointer1++]=255&list.length>>24,compressedBuffer[compressedBufferPointer1++]=255&lowBitsLength,list.forEach(function(docID){var docIDDelta=docID-lastDocID-1;if(!$.isNumeric(docID))throw new Error("Value is not numeric");if(docID=parseInt(docID),null!==prev&&docID<=prev)throw new Error("Elias Fano encoding can only be used on a sorted, ascending list of unique integers.");for(prev=docID,buffer1=buffer1<<lowBitsLength|docIDDelta&lowBitsMask,bufferLength1+=lowBitsLength;7<bufferLength1;)bufferLength1-=8,compressedBuffer[compressedBufferPointer1++]=255&buffer1>>bufferLength1;docIDDelta=1+(docIDDelta>>lowBitsLength);for(buffer2=buffer2<<docIDDelta|1,bufferLength2+=docIDDelta;7<bufferLength2;)bufferLength2-=8,compressedBuffer[compressedBufferPointer2++]=255&buffer2>>bufferLength2;lastDocID=docID}),0<bufferLength1&&(compressedBuffer[compressedBufferPointer1++]=255&buffer1<<8-bufferLength1),0<bufferLength2&&(compressedBuffer[compressedBufferPointer2++]=255&buffer2<<8-bufferLength2),new Uint8Array(compressedBuffer));return result.pointer=compressedBufferPointer2,result},WPGMZA.EliasFano.prototype.decode=function(compressedBuffer){for(var resultPointer=0,list=[],decodingTableHighBits=WPGMZA.EliasFano.decodingTableHighBits,decodingTableDocIDNumber=WPGMZA.EliasFano.decodingTableDocIDNumber,decodingTableHighBitsCarryover=WPGMZA.EliasFano.decodingTableHighBitsCarryover,lowBitsPointer=0,lastDocID=0,docID=0,listCount=compressedBuffer[lowBitsPointer++],lowBitsLength=(listCount=(listCount=(listCount|=compressedBuffer[lowBitsPointer++]<<8)|compressedBuffer[lowBitsPointer++]<<16)|compressedBuffer[lowBitsPointer++]<<24,compressedBuffer[lowBitsPointer++]),lowBitsCount=0,lowBits=0,cb=1,highBitsPointer=Math.floor(lowBitsLength*listCount/8+6);highBitsPointer<compressedBuffer.pointer;highBitsPointer++){docID+=decodingTableHighBitsCarryover[cb];for(var docIDNumber=decodingTableDocIDNumber[cb=compressedBuffer[highBitsPointer]],i=0;i<docIDNumber;i++){for(docID=docID<<lowBitsCount|lowBits&(1<<lowBitsCount)-1;lowBitsCount<lowBitsLength;)docID=(docID<<=8)|(lowBits=compressedBuffer[lowBitsPointer++]),lowBitsCount+=8;docID=(docID>>=lowBitsCount-=lowBitsLength)+((decodingTableHighBits[cb][i]<<lowBitsLength)+lastDocID+1),lastDocID=list[resultPointer++]=docID,docID=0}}return list}}),jQuery(function($){WPGMZA.EventDispatcher=function(){WPGMZA.assertInstanceOf(this,"EventDispatcher"),this._listenersByType={}},WPGMZA.EventDispatcher.prototype.addEventListener=function(type,listener,thisObject,useCapture){var types=type.split(/\s+/);if(1<types.length)for(var i=0;i<types.length;i++)this.addEventListener(types[i],listener,thisObject,useCapture);else{if(!(listener instanceof Function))throw new Error("Listener must be a function");type=this._listenersByType.hasOwnProperty(type)?this._listenersByType[type]:this._listenersByType[type]=[];type.push({listener:listener,thisObject:thisObject||this,useCapture:!!useCapture})}},WPGMZA.EventDispatcher.prototype.on=WPGMZA.EventDispatcher.prototype.addEventListener,WPGMZA.EventDispatcher.prototype.removeEventListener=function(type,listener,thisObject,useCapture){var arr,obj;if(arr=this._listenersByType[type]){thisObject=thisObject||this,useCapture=!!useCapture;for(var i=0;i<arr.length;i++)if(obj=arr[i],(1==arguments.length||obj.listener==listener)&&obj.thisObject==thisObject&&obj.useCapture==useCapture)return void arr.splice(i,1)}},WPGMZA.EventDispatcher.prototype.off=WPGMZA.EventDispatcher.prototype.removeEventListener,WPGMZA.EventDispatcher.prototype.hasEventListener=function(type){return!!_listenersByType[type]},WPGMZA.EventDispatcher.prototype.dispatchEvent=function(event){if(!(event instanceof WPGMZA.Event))if("string"==typeof event)event=new WPGMZA.Event(event);else{var name,src=event;for(name in event=new WPGMZA.Event,src)event[name]=src[name]}for(var path=[],obj=(event.target=this).parent;null!=obj;obj=obj.parent)path.unshift(obj);event.phase=WPGMZA.Event.CAPTURING_PHASE;for(var i=0;i<path.length&&!event._cancelled;i++)path[i]._triggerListeners(event);if(!event._cancelled){for(event.phase=WPGMZA.Event.AT_TARGET,this._triggerListeners(event),event.phase=WPGMZA.Event.BUBBLING_PHASE,i=path.length-1;0<=i&&!event._cancelled;i--)path[i]._triggerListeners(event);for(var topMostElement=this.element,obj=this.parent;null!=obj;obj=obj.parent)obj.element&&(topMostElement=obj.element);if(topMostElement){var key,customEvent={};for(key in event){var value=event[key];"type"==key&&(value+=".wpgmza"),customEvent[key]=value}$(topMostElement).trigger(customEvent)}}},WPGMZA.EventDispatcher.prototype.trigger=WPGMZA.EventDispatcher.prototype.dispatchEvent,WPGMZA.EventDispatcher.prototype._triggerListeners=function(event){var arr,obj;if(arr=this._listenersByType[event.type])for(var i=0;i<arr.length;i++)obj=arr[i],event.phase==WPGMZA.Event.CAPTURING_PHASE&&!obj.useCapture||obj.listener.call(arr[i].thisObject,event)},WPGMZA.events=new WPGMZA.EventDispatcher}),jQuery(function($){WPGMZA.AddressInput=function(element,map){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=element;var json,options={fields:["name","formatted_address"],types:["geocode","establishment"]};(json=$(element).attr("data-autocomplete-options"))&&(options=$.extend(options,JSON.parse(json))),map&&map.settings.wpgmza_store_locator_restrict&&(options.country=map.settings.wpgmza_store_locator_restrict),WPGMZA.isGoogleAutocompleteSupported()?"wpgmza_add_address_map_editor"!=this.element.id&&WPGMZA_localized_data.settings.googleMapsApiKey&&""!==WPGMZA_localized_data.settings.googleMapsApiKey&&(element.googleAutoComplete=new google.maps.places.Autocomplete(element,options),options.country&&element.googleAutoComplete.setComponentRestrictions({country:options.country})):WPGMZA.CloudAPI&&WPGMZA.CloudAPI.isBeingUsed&&(element.cloudAutoComplete=new WPGMZA.CloudAutocomplete(element,options))},WPGMZA.extend(WPGMZA.AddressInput,WPGMZA.EventDispatcher),WPGMZA.AddressInput.createInstance=function(element,map){return new WPGMZA.AddressInput(element,map)}}),jQuery(function($){WPGMZA.CapsuleModules=function(){WPGMZA.EventDispatcher.call(this),this.proxies={},this.capsules=[],this.prepareCapsules(),this.flagCapsules()},WPGMZA.extend(WPGMZA.CapsuleModules,WPGMZA.EventDispatcher),WPGMZA.CapsuleModules.getConstructor=function(){return WPGMZA.isProVersion()?WPGMZA.ProCapsuleModules:WPGMZA.CapsuleModules},WPGMZA.CapsuleModules.createInstance=function(){const constructor=WPGMZA.CapsuleModules.getConstructor();return new constructor},WPGMZA.CapsuleModules.prototype.proxyMap=function(id,settings){return this.proxies[id]||(this.proxies[id]=Object.create(this),this.proxies[id].id=id,this.proxies[id].markers=[],this.proxies[id].showPreloader=function(){},this.proxies[id].getMarkerByID=function(){return{}},this.proxies[id].markerFilter=WPGMZA.MarkerFilter.createInstance(this.proxies[id])),settings&&(this.proxies[id].settings=settings),this.proxies[id]},WPGMZA.CapsuleModules.prototype.flagCapsules=function(){if(this.capsules)for(var i in this.capsules)this.capsules[i].element&&$(this.capsules[i].element).addClass("wpgmza-capsule-module")},WPGMZA.CapsuleModules.prototype.prepareCapsules=function(){this.registerStoreLocator()},WPGMZA.CapsuleModules.prototype.registerStoreLocator=function(){$(".wpgmza-store-locator").each((index,element)=>{var mapId=$(element).data("map-id"),url=$(element).data("url");if(mapId&&!WPGMZA.getMapByID(mapId))if(url){var settings=$(element).data("map-settings"),settings=this.proxyMap(mapId,settings);const capsule={type:"store_locator",element:element,instance:WPGMZA.StoreLocator.createInstance(settings,element)};capsule.instance.isCapsule=!0,capsule.instance.redirectUrl=url,this.capsules.push(capsule)}else console.warn('WPGMZA: You seem to have added a stadalone store locator without a map page URL. Please add a URL to your shortcode [wpgmza_store_locator id="'+mapId+'" url="{URL}"] and try again')})}}),jQuery(function($){WPGMZA.ColorInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={format:"hex",anchor:"left",container:!1,autoClose:!0,autoOpen:!1,supportAlpha:!0,supportPalette:!0,wheelBorderWidth:10,wheelPadding:6,wheelBorderColor:"rgb(255,255,255)"},this.parseOptions(options),this.state={initialized:!1,sliderInvert:!1,lockSlide:!1,lockPicker:!1,open:!1,mouse:{down:!1}},this.color={h:0,s:0,l:100,a:1},this.wrap(),this.renderControls(),this.parseColor(this.value)},WPGMZA.extend(WPGMZA.ColorInput,WPGMZA.EventDispatcher),WPGMZA.ColorInput.createInstance=function(element){return new WPGMZA.ColorInput(element)},WPGMZA.ColorInput.prototype.clamp=function(min,max,value){return isNaN(value)&&(value=0),Math.min(Math.max(value,min),max)},WPGMZA.ColorInput.prototype.degreesToRadians=function(degrees){return degrees*(Math.PI/180)},WPGMZA.ColorInput.prototype.hueToRgb=function(p,q,t){return t<0&&(t+=1),1<t&&--t,t<1/6?p+6*(q-p)*t:t<.5?q:t<2/3?p+(q-p)*(2/3-t)*6:p},WPGMZA.ColorInput.prototype.getMousePositionInCanvas=function(canvas,event){canvas=canvas.getBoundingClientRect();return{x:event.clientX-canvas.left,y:event.clientY-canvas.top}},WPGMZA.ColorInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.ColorInput.prototype.getColor=function(override,format){var hsl=Object.assign({},this.color);if(override)for(var i in override)hsl[i]=override[i];format=format||this.options.format;var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l,hsl.a);switch(format){case"hsl":return"hsl("+hsl.h+", "+hsl.s+"%, "+hsl.l+"%)";case"hsla":return"hsla("+hsl.h+", "+hsl.s+"%, "+hsl.l+"%, "+hsl.a+")";case"rgb":return"rgb("+rgb.r+", "+rgb.g+", "+rgb.b+")";case"rgba":return"rgba("+rgb.r+", "+rgb.g+", "+rgb.b+", "+rgb.a+")"}return this.rgbToHex(rgb.r,rgb.g,rgb.b,rgb.a)},WPGMZA.ColorInput.prototype.setColor=function(hsl){for(var i in hsl)this.color[i]=hsl[i];this.options.supportAlpha||(this.color.a=1),this.updatePreview(),this.commit(),this.state.initialized&&this.update()},WPGMZA.ColorInput.prototype.parseColor=function(value){var hsl;"string"==typeof value&&(-1!==(value=""===(value=value.trim().toLowerCase().replace(/ /g,""))?"rgb(255,255,255)":value).indexOf("rgb")?(value=value.replace(/[a-z\(\)%]/g,""),parts=value.split(","),this.setColor(this.rgbToHsl(parts[0],parts[1],parts[2],parts[3]))):-1!==value.indexOf("hsl")?(value=value.replace(/[a-z\(\)%]/g,""),hsl={h:(parts=value.split(","))[0]?parseInt(parts[0]):0,s:parts[1]?parseInt(parts[1]):0,l:parts[2]?parseInt(parts[2]):100,a:parts[3]?parseFloat(parts[3]):1},this.setColor(hsl)):(hsl=this.hexToRgb(value),this.setColor(this.rgbToHsl(hsl.r,hsl.g,hsl.b,hsl.a))))},WPGMZA.ColorInput.prototype.rgbToHsl=function(r,g,b,a){var rgb={r:0<=r?r/255:255,g:0<=g?g/255:255,b:0<=b?b/255:255,a:0<=a?a:1},r=Math.min(rgb.r,rgb.g,rgb.b),g=Math.max(rgb.r,rgb.g,rgb.b),delta=g-r,hsl={h:(g+r)/2,s:(g+r)/2,l:(g+r)/2,a:rgb.a};if(0!=delta){switch(hsl.s=.5<hsl.l?delta/(2-g-r):delta/(g+r),g){case rgb.r:hsl.h=(rgb.g-rgb.b)/delta+(rgb.g<rgb.b?6:0);break;case rgb.g:hsl.h=(rgb.b-rgb.r)/delta+2;break;case rgb.b:hsl.h=(rgb.r-rgb.g)/delta+4}hsl.h=hsl.h/6}else hsl.h=0,hsl.s=0;return hsl.h=parseInt(360*hsl.h),hsl.s=parseInt(100*hsl.s),hsl.l=parseInt(100*hsl.l),hsl},WPGMZA.ColorInput.prototype.hexToRgb=function(hex){return(hex=hex.trim().toLowerCase().replace(/ /g,"").replace(/[^A-Za-z0-9\s]/g,"")).length<6&&(hex+=hex.charAt(hex.length-1).repeat(6-hex.length)),{r:parseInt(hex.slice(0,2),16),g:parseInt(hex.slice(2,4),16),b:parseInt(hex.slice(4,6),16),a:6<hex.length?this.floatToPrecision(parseInt(hex.slice(6,8),16)/255,2):1}},WPGMZA.ColorInput.prototype.hslToRgb=function(h,s,l,a){var h={h:0<=h?h:0,s:0<=s?s/100:0,l:0<=l?l/100:0,a:0<=a?a:1},s={r:0,g:0,b:0,a:h.a},l=(1-Math.abs(2*h.l-1))*h.s,a=l*(1-Math.abs(h.h/60%2-1)),diff=h.l-l/2;return 0<=h.h&&h.h<60?(s.r=l,s.g=a,s.b=0):60<=h.h&&h.h<120?(s.r=a,s.g=l,s.b=0):120<=h.h&&h.h<180?(s.r=0,s.g=l,s.b=a):180<=h.h&&h.h<240?(s.r=0,s.g=a,s.b=l):240<=h.h&&h.h<300?(s.r=a,s.g=0,s.b=l):300<=h.h&&h.h<360&&(s.r=l,s.g=0,s.b=a),s.r=Math.round(255*(s.r+diff)),s.g=Math.round(255*(s.g+diff)),s.b=Math.round(255*(s.b+diff)),s},WPGMZA.ColorInput.prototype.rgbToHex=function(r,g,b,a){var i,rgb={r:0<=r?r:255,g:0<=g?g:255,b:0<=b?b:255,a:0<=a?a:1};for(i in rgb.r=rgb.r.toString(16),rgb.g=rgb.g.toString(16),rgb.b=rgb.b.toString(16),rgb.a<1?rgb.a=Math.round(255*rgb.a).toString(16):rgb.a="",rgb)1===rgb[i].length&&(rgb[i]="0"+rgb[i]);return"#"+rgb.r+rgb.g+rgb.b+rgb.a},WPGMZA.ColorInput.prototype.floatToPrecision=function(float,precision){return float=parseFloat(float),parseFloat(float.toFixed(precision))},WPGMZA.ColorInput.prototype.wrap=function(){var self=this;if(!this.element||"text"!==this.type)throw new Error("WPGMZA.ColorInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-color-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element),this.options.autoClose&&($(document.body).on("click",function(){self.state.open&&(self.state.mouse.down=!1,self.onTogglePicker())}),$(document.body).on("colorpicker.open.wpgmza",function(event){event.instance!==self&&self.state.open&&self.onTogglePicker()}))},WPGMZA.ColorInput.prototype.renderControls=function(){var self=this;this.container&&(this.preview=$("<div class='wpgmza-color-preview wpgmza-shadow' />"),this.swatch=$("<div class='swatch' />"),this.picker=$("<div class='wpgmza-color-picker wpgmza-card wpgmza-shadow' />"),this.preview.append(this.swatch),this.picker.addClass("anchor-"+this.options.anchor),this.preview.addClass("anchor-"+this.options.anchor),this.preview.on("click",function(event){event.stopPropagation(),self.onTogglePicker()}),this.picker.on("click",function(event){event.stopPropagation()}),this.container.append(this.preview),this.options.container&&0<$(this.options.container).length?($(this.options.container).append(this.picker),$(this.options.container).addClass("wpgmza-color-input-host")):this.container.append(this.picker),this.options.autoOpen&&this.preview.trigger("click"))},WPGMZA.ColorInput.prototype.renderPicker=function(){this.state.initialized||(this.renderWheel(),this.renderFields(),this.renderPalette(),this.state.initialized=!0)},WPGMZA.ColorInput.prototype.renderWheel=function(){var self=this;this.wheel={wrap:$("<div class='canvas-wrapper' />"),element:$("<canvas class='color-wheel' />"),handle:$("<div class='canvas-handle' />"),slider:$("<div class='canvas-slider' />")},this.wheel.target=this.wheel.element.get(0),this.wheel.target.height=256,this.wheel.target.width=256,this.wheel.radius=(this.wheel.target.width-2*(this.options.wheelBorderWidth+this.options.wheelPadding))/2,this.wheel.degreeStep=1/this.wheel.radius,this.wheel.context=this.wheel.target.getContext("2d"),this.wheel.context.clearRect(0,0,this.wheel.target.width,this.wheel.target.height),this.wheel.grid={canvas:document.createElement("canvas")},this.wheel.grid.canvas.width=20,this.wheel.grid.canvas.height=20,this.wheel.grid.context=this.wheel.grid.canvas.getContext("2d"),this.wheel.grid.context.fillStyle="rgb(255,255,255)",this.wheel.grid.context.fillRect(0,0,this.wheel.grid.canvas.width,this.wheel.grid.canvas.height),this.wheel.grid.context.fillStyle="rgb(180,180,180)",this.wheel.grid.context.fillRect(0,0,this.wheel.grid.canvas.width/2,this.wheel.grid.canvas.height/2),this.wheel.grid.context.fillRect(this.wheel.grid.canvas.width/2,this.wheel.grid.canvas.height/2,this.wheel.grid.canvas.width/2,this.wheel.grid.canvas.height/2),this.wheel.element.on("mousedown",function(event){self.state.mouse.down=!0,self.onPickerMouseSelect(event)}),this.wheel.element.on("mousemove",function(event){self.state.mouse.down&&self.onPickerMouseSelect(event)}),this.wheel.element.on("mouseup",function(event){self.clearStates()}),this.wheel.element.on("mouseleave",function(event){self.clearStates()}),this.wheel.wrap.append(this.wheel.element),this.wheel.wrap.append(this.wheel.handle),this.wheel.wrap.append(this.wheel.slider),this.picker.append(this.wheel.wrap)},WPGMZA.ColorInput.prototype.renderFields=function(){var group,self=this;for(group in this.fields={wrap:$("<div class='wpgmza-color-field-wrapper' />"),toggle:$("<div class='color-field-toggle' />"),blocks:{hsla:{keys:["h","s","l","a"]},rgba:{keys:["r","g","b","a"]},hex:{keys:["hex"]}}},this.fields.toggle.on("click",function(){var view=self.fields.view;switch(view){case"hex":view="hsla";break;case"hsla":view="rgba";break;case"rgba":view="hex"}self.updateFieldView(view)}),this.fields.wrap.append(this.fields.toggle),this.fields.blocks){var index,keys=this.fields.blocks[group].keys;for(index in this.fields.blocks[group].wrap=$("<div class='field-block' data-type='"+group+"'/>"),this.fields.blocks[group].rows={labels:$("<div class='labels' />"),controls:$("<div class='controls' />")},this.fields.blocks[group].wrap.append(this.fields.blocks[group].rows.controls),this.fields.blocks[group].wrap.append(this.fields.blocks[group].rows.labels),this.options.supportAlpha||-1===keys.indexOf("a")||this.fields.blocks[group].wrap.addClass("alpha-disabled"),keys){var name=keys[index],label=$("<div class='inner-label' />");label.text(name),this.fields.blocks[group][name]=$("<input type='text'/>"),this.fields.blocks[group].rows.controls.append(this.fields.blocks[group][name]),this.fields.blocks[group].rows.labels.append(label),this.fields.blocks[group][name].on("keydown",function(event){const originalEvent=event.originalEvent;"Enter"===originalEvent.key&&(originalEvent.preventDefault(),originalEvent.stopPropagation(),$(event.currentTarget).trigger("change"))}),this.fields.blocks[group][name].on("change",function(){self.onFieldChange(this)})}this.fields.wrap.append(this.fields.blocks[group].wrap)}this.picker.append(this.fields.wrap),this.updateFieldView()},WPGMZA.ColorInput.prototype.renderPalette=function(){var self=this;if(this.options.supportPalette){for(var i in this.palette={wrap:$("<div class='wpgmza-color-palette-wrap' />"),variations:[{s:-10,l:-10},{h:15},{h:30},{h:-15},{h:-30},{h:100,s:10},{h:-100,s:-10},{h:180}],controls:[]},this.palette.variations){var mutator,variation=this.palette.variations[i],control=$("<div class='palette-swatch' />");for(mutator in variation)control.attr("data-"+mutator,variation[mutator]);control.on("click",function(){var elem=$(this);self.parseColor(elem.css("background-color")),self.element.trigger("input")}),this.palette.wrap.append(control),this.palette.controls.push(control)}this.picker.append(this.palette.wrap)}},WPGMZA.ColorInput.prototype.updateWheel=function(){this.wheel.center={x:this.wheel.radius+this.options.wheelBorderWidth+this.options.wheelPadding,y:this.wheel.radius+this.options.wheelBorderWidth+this.options.wheelPadding},this.color.a<1&&(this.wheel.grid.pattern=this.wheel.context.createPattern(this.wheel.grid.canvas,"repeat"),this.wheel.context.fillStyle=this.wheel.grid.pattern,this.wheel.context.beginPath(),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius,0,2*Math.PI,!0),this.wheel.context.closePath(),this.wheel.context.fill());for(var i=0;i<360;i++){var startAngle=(i-1)*Math.PI/180,endAngle=(i+1)*Math.PI/180;this.wheel.context.beginPath(),this.wheel.context.moveTo(this.wheel.center.x,this.wheel.center.y),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius,startAngle,endAngle),this.wheel.context.closePath(),this.wheel.context.fillStyle="hsla("+i+", 100%, 50%, "+this.color.a+")",this.wheel.context.fill()}var gradient=this.wheel.context.createRadialGradient(this.wheel.center.x,this.wheel.center.y,0,this.wheel.center.x,this.wheel.center.y,this.wheel.radius),gradient=(gradient.addColorStop(0,"rgba(255, 255, 255, 1)"),gradient.addColorStop(1,"rgba(255, 255, 255, 0)"),this.wheel.context.fillStyle=gradient,this.wheel.context.beginPath(),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius,0,2*Math.PI,!0),this.wheel.context.closePath(),this.wheel.context.fill(),this.wheel.context.lineWidth=2,this.wheel.context.strokeStyle=this.options.wheelBorderColor,this.wheel.context.stroke(),this.wheel.context.createLinearGradient(this.wheel.center.x,0,this.wheel.center.x,this.wheel.target.height)),gradient=(gradient.addColorStop(0,this.getColor({l:95},"hsl")),gradient.addColorStop(.5,this.getColor({l:50},"hsl")),gradient.addColorStop(1,this.getColor({l:5},"hsl")),this.wheel.context.beginPath(),this.wheel.context.lineWidth=this.options.wheelBorderWidth,this.wheel.context.strokeStyle=gradient,this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius+this.options.wheelPadding+this.options.wheelBorderWidth/2,0,2*Math.PI),this.wheel.context.stroke(),this.wheel.context.beginPath(),this.wheel.context.lineWidth=1,this.wheel.context.strokeStyle=this.options.wheelBorderColor,this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius+this.options.wheelPadding+this.options.wheelBorderWidth,0,2*Math.PI),this.wheel.context.stroke(),this.wheel.context.beginPath(),this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius+this.options.wheelPadding,0,2*Math.PI),this.wheel.context.stroke(),this.wheel.context.createRadialGradient(this.wheel.center.x,this.wheel.center.y,0,this.wheel.center.x,this.wheel.center.y,this.wheel.radius));gradient.addColorStop(0,"rgba(80, 80, 80, 0)"),gradient.addColorStop(.95,"rgba(80, 80, 80, 0.0)"),gradient.addColorStop(1,"rgba(80, 80, 80, 0.1)"),this.wheel.context.beginPath(),this.wheel.context.lineWidth=6,this.wheel.context.strokeStyle=gradient,this.wheel.context.arc(this.wheel.center.x,this.wheel.center.y,this.wheel.radius-3,0,2*Math.PI),this.wheel.context.stroke()},WPGMZA.ColorInput.prototype.update=function(){this.updateHandles(),this.updateWheel(),this.updateFields(),this.updatePalette()},WPGMZA.ColorInput.prototype.updateHandles=function(){var localRadius=this.wheel.element.width()/2,localHandleOffset=(localRadius-this.options.wheelBorderWidth-this.options.wheelPadding)/100*this.color.s,localHandleOffset={left:localRadius+localHandleOffset*Math.cos(this.degreesToRadians(this.color.h))+"px",top:localRadius+localHandleOffset*Math.sin(this.degreesToRadians(this.color.h))+"px"},localHandleOffset=(this.wheel.handle.css(localHandleOffset),this.color.l/100*360/2),localRadius=(this.state.sliderInvert&&(localHandleOffset=360-localHandleOffset),{left:localRadius+(localRadius-this.options.wheelBorderWidth/2)*Math.cos(this.degreesToRadians(localHandleOffset+90))+"px",top:localRadius+(localRadius-this.options.wheelBorderWidth/2)*Math.sin(this.degreesToRadians(localHandleOffset+90))+"px"});this.wheel.slider.css(localRadius)},WPGMZA.ColorInput.prototype.updatePreview=function(){this.swatch.css({background:this.getColor(!1,"rgba")})},WPGMZA.ColorInput.prototype.updateFields=function(){var group,hsl=Object.assign({},this.color);for(group in this.fields.blocks)switch(group){case"hsla":this.fields.blocks[group].h.val(hsl.h),this.fields.blocks[group].s.val(hsl.s),this.fields.blocks[group].l.val(hsl.l),this.fields.blocks[group].a.val(hsl.a);break;case"rgba":var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l,hsl.a);this.fields.blocks[group].r.val(rgb.r),this.fields.blocks[group].g.val(rgb.g),this.fields.blocks[group].b.val(rgb.b),this.fields.blocks[group].a.val(rgb.a);break;case"hex":var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l,hsl.a),hex=this.rgbToHex(rgb.r,rgb.g,rgb.b,rgb.a);this.fields.blocks[group].hex.val(hex)}},WPGMZA.ColorInput.prototype.updatePalette=function(){if(this.options.supportPalette)for(var i in this.palette.controls){var mutator,hsl=Object.assign({},this.color),i=this.palette.controls[i],data=i.data();for(mutator in 0===hsl.l?(data.h&&(hsl.l+=Math.abs(data.h)/360*100),hsl.l+=10):100===hsl.l&&(data.h&&(hsl.l-=Math.abs(data.h)/360*100),hsl.l-=10),data)hsl[mutator]+=data[mutator];hsl.h<0?hsl.h+=360:360<hsl.h&&(hsl.h-=360),hsl.h=this.clamp(0,360,hsl.h),hsl.s=this.clamp(0,100,hsl.s),hsl.l=this.clamp(0,100,hsl.l);var rgb=this.hslToRgb(hsl.h,hsl.s,hsl.l);i.css("background","rgb("+rgb.r+", "+rgb.g+", "+rgb.b+")")}},WPGMZA.ColorInput.prototype.updateFieldView=function(view){switch(view=view||this.options.format||"hex"){case"rgb":view="rgba";break;case"hsl":view="hsla"}for(var group in this.fields.view=view,this.fields.blocks)group===this.fields.view?this.fields.blocks[group].wrap.show():this.fields.blocks[group].wrap.hide()},WPGMZA.ColorInput.prototype.onPickerMouseSelect=function(event){var localRadius=this.wheel.element.width()/2,event=this.getMousePositionInCanvas(this.wheel.target,event),event={x:event.x-localRadius,y:event.y-localRadius},angle=360*Math.atan2(event.y,event.x)/(2*Math.PI),event=(angle<0&&(angle+=360),Math.sqrt(event.x*event.x+event.y*event.y)),range={pickerScaler:localRadius/this.wheel.radius};range.pickerEdge=range.pickerScaler*localRadius,(event<=range.pickerEdge||this.state.lockPicker)&&!this.state.lockSlide?(this.setColor({h:parseInt(angle),s:Math.min(parseInt(event/range.pickerEdge*100),100)}),this.state.lockPicker=!0):((angle-=90)<0&&(angle+=360),this.state.sliderInvert=!1,180<angle&&(angle=180-(angle-180),this.state.sliderInvert=!0),this.setColor({l:parseInt(angle/180*100)}),this.state.lockSlide=!0),this.element.trigger("input")},WPGMZA.ColorInput.prototype.onFieldChange=function(field){if(field&&""!==$(field).val().trim()){var field=$(field).closest(".field-block"),type=field.data("type"),raw=[];if(field.find("input").each(function(){raw.push($(this).val())}),("hsla"===type||"rgba"===type)&&raw[3]){field=raw[3];if("."===field.trim().charAt(field.trim().length-1))return}switch(type){case"hsla":(hsl={h:raw[0]?parseInt(raw[0]):0,s:raw[1]?parseInt(raw[1]):0,l:raw[2]?parseInt(raw[2]):100,a:raw[3]?parseFloat(raw[3]):1}).h=this.clamp(0,360,hsl.h),hsl.s=this.clamp(0,100,hsl.s),hsl.l=this.clamp(0,100,hsl.l),hsl.a=this.clamp(0,1,hsl.a),this.setColor(hsl);break;case"rgba":(rgb={r:raw[0]?parseInt(raw[0]):255,g:raw[1]?parseInt(raw[1]):255,b:raw[2]?parseInt(raw[2]):255,a:raw[3]?parseFloat(raw[3]):1}).r=this.clamp(0,255,rgb.r),rgb.g=this.clamp(0,255,rgb.g),rgb.b=this.clamp(0,255,rgb.b),rgb.a=this.clamp(0,1,rgb.a);var hsl=this.rgbToHsl(rgb.r,rgb.g,rgb.b,rgb.a);this.setColor(hsl);break;case"hex":var rgb=this.hexToRgb(raw[0]||"#ffffff");this.setColor(this.rgbToHsl(rgb.r,rgb.g,rgb.b,rgb.a))}this.element.trigger("input")}},WPGMZA.ColorInput.prototype.onTogglePicker=function(){this.renderPicker(),this.picker.toggleClass("active"),this.update(),this.state.open=this.picker.hasClass("active"),this.state.open&&$(document.body).trigger({type:"colorpicker.open.wpgmza",instance:this})},WPGMZA.ColorInput.prototype.clearStates=function(){this.state.mouse.down=!1,this.state.lockSlide=!1,this.state.lockPicker=!1},WPGMZA.ColorInput.prototype.commit=function(){var syncValue=this.getColor();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-color-input").each(function(index,el){el.wpgmzaColorInput=WPGMZA.ColorInput.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSBackdropFilterInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={},this.parseOptions(options),this.state={initialized:!1},this.filters={blur:{enable:!1,value:0,unit:"px"},brightness:{enable:!1,value:0,unit:"%"},contrast:{enable:!1,value:0,unit:"%"},grayscale:{enable:!1,value:0,unit:"%"},hue_rotate:{enable:!1,value:0,unit:"deg"},invert:{enable:!1,value:0,unit:"%"},sepia:{enable:!1,value:0,unit:"%"},saturate:{enable:!1,value:0,unit:"%"}},this.wrap(),this.renderControls(),this.parseFilters(this.value)},WPGMZA.extend(WPGMZA.CSSBackdropFilterInput,WPGMZA.EventDispatcher),WPGMZA.CSSBackdropFilterInput.FILTER_PATTERN=/(\S+)/g,WPGMZA.CSSBackdropFilterInput.VALUE_PATTERN=/(\(\S*\))/g,WPGMZA.CSSBackdropFilterInput.createInstance=function(element){return new WPGMZA.CSSBackdropFilterInput(element)},WPGMZA.CSSBackdropFilterInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.CSSBackdropFilterInput.prototype.getFilters=function(override,format){let filters=[];for(var type in this.filters){var data=this.filters[type];data.enable&&(type=type.replace("_","-"),filters.push(type+"("+data.value+data.unit+")"))}return 0<filters.length?filters.join(" "):"none"},WPGMZA.CSSBackdropFilterInput.prototype.setFilters=function(filters){if(this.clearFilters(),filters instanceof Object)for(var type in filters){var value;!this.filters[type]||(value=filters[type])&&(this.filters[type].enable=!0,this.filters[type].value=value)}this.commit(),this.state.initialized&&this.update()},WPGMZA.CSSBackdropFilterInput.prototype.clearFilters=function(){for(var i in this.filters)this.filters[i].enable=!1,this.filters[i].value=0},WPGMZA.CSSBackdropFilterInput.prototype.parseFilters=function(value){if("string"==typeof value){let filters={};if("none"!==(value=""===(value=value.trim().toLowerCase())?"none":value)){value=value.match(WPGMZA.CSSBackdropFilterInput.FILTER_PATTERN);if(value&&value instanceof Array)for(var match of value){let valueArg=match.match(WPGMZA.CSSBackdropFilterInput.VALUE_PATTERN);valueArg=valueArg instanceof Array&&0<valueArg.length?valueArg[0]:"";var numericValue,match=match.replace(valueArg,"").replace("-","_");let value=null;0<valueArg.length&&((numericValue=valueArg.match(/(\d+)/g))instanceof Array&&0<numericValue.length&&(value=parseFloat(numericValue[0]))),filters[match]=value}}this.setFilters(filters)}},WPGMZA.CSSBackdropFilterInput.prototype.wrap=function(){if(!this.element||"text"!==this.type)throw new Error("WPGMZA.CSSUnitInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-styling-backdrop-filter-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element)},WPGMZA.CSSBackdropFilterInput.prototype.renderControls=function(){if(this.container)for(var type in this.itemWrappers={},this.filters){var data=this.filters[type],printType=type.replace("_"," ");const wrapper=$("<div class='backdrop-filter-item-wrap' data-type='"+type+"' />"),toggleWrap=$("<div class='backdrop-filter-toggle-wrap' />"),toggleInput=$("<input type='checkbox' class='backdrop-filter-item-toggle' />"),toggleLabel=$("<label />"),controlWrap=$("<div class='backdrop-filter-control-wrap' />");controlAttributes="data-min='1' data-max='100'","deg"===data.unit?controlAttributes="data-min='1' data-max='360'":"px"===data.unit&&(controlAttributes="data-min='1' data-max='200'");const controlInput=$("<input class='backdrop-filter-item-input' type='text' "+controlAttributes+" value='"+data.value+"' />"),controlLabel=$("<small />"),slider=(controlLabel.append("<span>"+data.value+"</span>"+data.unit),$("<div class='backdrop-filter-item-slider' />"));toggleLabel.append(toggleInput),toggleLabel.append(printType),toggleWrap.append(toggleLabel),controlWrap.append(controlInput),controlWrap.append(controlLabel),controlWrap.append(slider),wrapper.append(toggleWrap),wrapper.append(controlWrap),this.itemWrappers[type]=wrapper,this.container.append(wrapper),this.state.initialized=!0,slider.slider({range:"max",min:controlInput.data("min"),max:controlInput.data("max"),value:controlInput.val(),slide:function(event,ui){controlInput.val(ui.value),controlLabel.find("span").text(ui.value),controlInput.trigger("change")},change:function(event,ui){}}),controlInput.wpgmzaRelativeSlider=slider,toggleInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".backdrop-filter-item-wrap");event=parent.data("type");target.is(":checked")?(parent.addClass("enabled"),this.setFilterState(event,!0)):(parent.removeClass("enabled"),this.setFilterState(event,!1))}),controlInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".backdrop-filter-item-wrap");event=parent.data("type");this.setFilterValue(event,target.val())})}},WPGMZA.CSSBackdropFilterInput.prototype.setFilterState=function(type,state){this.filters[type]&&(this.filters[type].enable=state),this.commit()},WPGMZA.CSSBackdropFilterInput.prototype.setFilterValue=function(type,value){this.filters[type]&&(this.filters[type].value=parseFloat(value)),this.commit()},WPGMZA.CSSBackdropFilterInput.prototype.update=function(){if(this.container)for(var type in this.filters){var data=this.filters[type];const row=this.container.find('.backdrop-filter-item-wrap[data-type="'+type+'"]');row.find(".backdrop-filter-item-toggle").prop("checked",data.enable).trigger("change"),row.find(".backdrop-filter-item-input").val(data.value).trigger("change"),row.find(".backdrop-filter-item-slider").slider("value",data.value),row.find(".backdrop-filter-control-wrap").find("small span").text(data.value)}},WPGMZA.CSSBackdropFilterInput.prototype.commit=function(){var syncValue=this.getFilters();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-styling-backdrop-filter-input").each(function(index,el){el.wpgmzaCSSBackdropFilterInput=WPGMZA.CSSBackdropFilterInput.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSFilterInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={},this.parseOptions(options),this.state={initialized:!1},this.filters={blur:{enable:!1,value:0,unit:"px"},brightness:{enable:!1,value:0,unit:"%"},contrast:{enable:!1,value:0,unit:"%"},grayscale:{enable:!1,value:0,unit:"%"},hue_rotate:{enable:!1,value:0,unit:"deg"},invert:{enable:!1,value:0,unit:"%"},sepia:{enable:!1,value:0,unit:"%"},saturate:{enable:!1,value:0,unit:"%"}},this.wrap(),this.renderControls(),this.parseFilters(this.value)},WPGMZA.extend(WPGMZA.CSSFilterInput,WPGMZA.EventDispatcher),WPGMZA.CSSFilterInput.FILTER_PATTERN=/(\S+)/g,WPGMZA.CSSFilterInput.VALUE_PATTERN=/(\(\S*\))/g,WPGMZA.CSSFilterInput.createInstance=function(element){return new WPGMZA.CSSFilterInput(element)},WPGMZA.CSSFilterInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.CSSFilterInput.prototype.getFilters=function(override,format){let filters=[];for(var type in this.filters){var data=this.filters[type];data.enable&&(type=type.replace("_","-"),filters.push(type+"("+data.value+data.unit+")"))}return 0<filters.length?filters.join(" "):"none"},WPGMZA.CSSFilterInput.prototype.setFilters=function(filters){if(this.clearFilters(),filters instanceof Object)for(var type in filters){var value;!this.filters[type]||(value=filters[type])&&(this.filters[type].enable=!0,this.filters[type].value=value)}this.commit(),this.state.initialized&&this.update()},WPGMZA.CSSFilterInput.prototype.clearFilters=function(){for(var i in this.filters)this.filters[i].enable=!1,this.filters[i].value=0},WPGMZA.CSSFilterInput.prototype.parseFilters=function(value){if("string"==typeof value){let filters={};if("none"!==(value=""===(value=value.trim().toLowerCase())?"none":value)){value=value.match(WPGMZA.CSSFilterInput.FILTER_PATTERN);if(value&&value instanceof Array)for(var match of value){let valueArg=match.match(WPGMZA.CSSFilterInput.VALUE_PATTERN);valueArg=valueArg instanceof Array&&0<valueArg.length?valueArg[0]:"";var numericValue,match=match.replace(valueArg,"").replace("-","_");let value=null;0<valueArg.length&&((numericValue=valueArg.match(/(\d+)/g))instanceof Array&&0<numericValue.length&&(value=parseFloat(numericValue[0]))),filters[match]=value}}this.setFilters(filters)}},WPGMZA.CSSFilterInput.prototype.wrap=function(){if(!this.element||"text"!==this.type)throw new Error("WPGMZA.CSSFilterInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-css-filter-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element)},WPGMZA.CSSFilterInput.prototype.renderControls=function(){if(this.container)for(var type in this.itemWrappers={},this.filters){var data=this.filters[type],printType=type.replace("_"," ");const wrapper=$("<div class='css-filter-item-wrap' data-type='"+type+"' />"),toggleWrap=$("<div class='css-filter-toggle-wrap' />"),toggleInput=$("<input type='checkbox' class='css-filter-item-toggle' />"),toggleLabel=$("<label />"),controlWrap=$("<div class='css-filter-control-wrap' />");controlAttributes="data-min='1' data-max='100'","deg"===data.unit?controlAttributes="data-min='1' data-max='360'":"px"===data.unit&&(controlAttributes="data-min='1' data-max='200'");const controlInput=$("<input class='css-filter-item-input' type='text' "+controlAttributes+" value='"+data.value+"' />"),controlLabel=$("<small />"),slider=(controlLabel.append("<span>"+data.value+"</span>"+data.unit),$("<div class='css-filter-item-slider' />"));toggleLabel.append(toggleInput),toggleLabel.append(printType),toggleWrap.append(toggleLabel),controlWrap.append(controlInput),controlWrap.append(controlLabel),controlWrap.append(slider),wrapper.append(toggleWrap),wrapper.append(controlWrap),this.itemWrappers[type]=wrapper,this.container.append(wrapper),this.state.initialized=!0,slider.slider({range:"max",min:controlInput.data("min"),max:controlInput.data("max"),value:controlInput.val(),slide:function(event,ui){controlInput.val(ui.value),controlLabel.find("span").text(ui.value),controlInput.trigger("change")},change:function(event,ui){}}),controlInput.wpgmzaRelativeSlider=slider,toggleInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".css-filter-item-wrap");event=parent.data("type");target.is(":checked")?(parent.addClass("enabled"),this.setFilterState(event,!0)):(parent.removeClass("enabled"),this.setFilterState(event,!1))}),controlInput.on("change",event=>{const target=$(event.currentTarget),parent=target.closest(".css-filter-item-wrap");event=parent.data("type");this.setFilterValue(event,target.val())})}},WPGMZA.CSSFilterInput.prototype.setFilterState=function(type,state){this.filters[type]&&(this.filters[type].enable=state),this.commit()},WPGMZA.CSSFilterInput.prototype.setFilterValue=function(type,value){this.filters[type]&&(this.filters[type].value=parseFloat(value)),this.commit()},WPGMZA.CSSFilterInput.prototype.update=function(){if(this.container)for(var type in this.filters){var data=this.filters[type];const row=this.container.find('.css-filter-item-wrap[data-type="'+type+'"]');row.find(".css-filter-item-toggle").prop("checked",data.enable).trigger("change"),row.find(".css-filter-item-input").val(data.value).trigger("change"),row.find(".css-filter-item-slider").slider("value",data.value),row.find(".css-filter-control-wrap").find("small span").text(data.value)}},WPGMZA.CSSFilterInput.prototype.commit=function(){var syncValue=this.getFilters();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-css-filter-input").each(function(index,el){el.wpgmzaCSSFilterInput=WPGMZA.CSSFilterInput.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSStateBlock=function(element,options){if(!(element instanceof HTMLElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.tabs=this.element.find(".wpgmza-css-state-block-item"),this.items=this.element.find(".wpgmza-css-state-block-content"),this.items.removeClass("active"),this.bindEvents(),this.element.find(".wpgmza-css-state-block-item:first-child").click()},WPGMZA.extend(WPGMZA.CSSStateBlock,WPGMZA.EventDispatcher),WPGMZA.CSSStateBlock.createInstance=function(element){return new WPGMZA.CSSStateBlock(element)},WPGMZA.CSSStateBlock.prototype.bindEvents=function(){let self=this;this.tabs.on("click",function(event){self.onClick($(this))})},WPGMZA.CSSStateBlock.prototype.onClick=function(item){var type=item.data("type");type&&(this.tabs.removeClass("active"),item.addClass("active"),this.items.removeClass("active"),this.element.find('.wpgmza-css-state-block-content[data-type="'+type+'"]').addClass("active"))},$(document.body).ready(function(){$(".wpgmza-css-state-block").each(function(index,el){el.wpgmzaCSSStateBlock=WPGMZA.CSSStateBlock.createInstance(el)})})}),jQuery(function($){WPGMZA.CSSUnitInput=function(element,options){if(!(element instanceof HTMLInputElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dataAttributes=this.element.data(),this.type=element.type,this.value=element.value,this.options={},this.parseOptions(options),this.state={initialized:!1},this.unit={value:0,suffix:"px"},this.wrap(),this.renderControls(),this.parseUnits(this.value)},WPGMZA.extend(WPGMZA.CSSUnitInput,WPGMZA.EventDispatcher),WPGMZA.CSSUnitInput.VALID_TYPES=["px","%","rem","em"],WPGMZA.CSSUnitInput.createInstance=function(element){return new WPGMZA.CSSUnitInput(element)},WPGMZA.CSSUnitInput.prototype.parseOptions=function(options){if(options)for(var i in options)void 0!==this.options[i]&&("object"==typeof this.options[i]&&"object"==typeof options[i]?this.options[i]=Object.assign(this.options[i],options[i]):this.options[i]=options[i]);if(this.dataAttributes)for(var i in this.dataAttributes)void 0!==this.options[i]&&(this.options[i]=this.dataAttributes[i])},WPGMZA.CSSUnitInput.prototype.getUnits=function(override,format){return this.unit.value+this.unit.suffix},WPGMZA.CSSUnitInput.prototype.setUnits=function(value,suffix){this.unit.value=value?parseFloat(value):this.unit.value,this.unit.suffix=suffix?suffix.trim():this.unit.suffix,0<this.unit.value-parseInt(this.unit.value)&&(this.unit.value=parseFloat(this.unit.value.toFixed(2))),this.unit.value<=0&&(this.unit.value=0),this.validateSuffix(),this.commit(),this.state.initialized&&this.update()},WPGMZA.CSSUnitInput.prototype.parseUnits=function(value){if("string"==typeof value){let unit=(value=""===(value=value.trim().toLowerCase().replace(/ /g,""))?"0px":value).match(/((\d+\.\d+)|(\d+))/),suffix=(unit=unit&&unit[0]?parseFloat(unit[0]):this.unit.value,value.match(/(([a-z]+)|(%))/));suffix=suffix&&suffix[0]?suffix[0]:this.unit.suffix,this.setUnits(unit,suffix)}},WPGMZA.CSSUnitInput.prototype.wrap=function(){if(!this.element||"text"!==this.type)throw new Error("WPGMZA.CSSUnitInput requires a text field as a base");this.element.hide(),this.container=$("<div class='wpgmza-styling-unit-input-wrapper' />"),this.container.insertAfter(this.element),this.container.append(this.element)},WPGMZA.CSSUnitInput.prototype.renderControls=function(){this.container&&(this.unitValueInput=$("<input type='text' class='unit-value-input' />"),this.unitSuffixToggle=$("<div class='unit-suffix-toggle' />"),this.unitValueStepDownBtn=$("<div class='unit-stepper-button' data-mode='down' />"),this.unitValueStepUpBtn=$("<div class='unit-stepper-button' data-mode='up' />"),this.unitValueStepperWrap=$("<div class='unit-stepper-wrapper' />"),this.unitInnerWrap=$("<div class='unit-input-inner-wrap' />"),this.unitValueStepperWrap.append(this.unitValueStepUpBtn),this.unitValueStepperWrap.append(this.unitValueStepDownBtn),this.unitInnerWrap.append(this.unitValueStepperWrap),this.unitInnerWrap.append(this.unitValueInput),this.unitInnerWrap.append(this.unitSuffixToggle),this.container.append(this.unitInnerWrap),this.state.initialized=!0,this.unitValueInput.on("keydown",event=>{const originalEvent=event.originalEvent;originalEvent.key&&1===originalEvent.key.length?(0===originalEvent.key.trim().length||"."!==originalEvent.key&&isNaN(parseInt(originalEvent.key)))&&this.unitSuffixToggle.hide():"ArrowUp"===originalEvent.key?this.increment():"ArrowDown"===originalEvent.key?this.decrement():"Enter"===originalEvent.key&&(originalEvent.preventDefault(),originalEvent.stopPropagation(),$(event.currentTarget).trigger("change"))}),this.unitValueInput.on("change",event=>{const input=$(event.currentTarget);this.parseUnits(input.val())}),this.unitValueStepUpBtn.on("click",event=>{this.increment()}),this.unitValueStepDownBtn.on("click",event=>{this.decrement()}))},WPGMZA.CSSUnitInput.prototype.validateSuffix=function(){(!this.unit.suffix||-1===WPGMZA.CSSUnitInput.VALID_TYPES.indexOf(this.unit.suffix))&&(this.unit.suffix=this.options.defaultSuffix)},WPGMZA.CSSUnitInput.prototype.increment=function(){this.parseUnits(this.unitValueInput.val());let value=this.unit.value;0<value-parseInt(value)?value+=.1:value+=1,this.setUnits(value,this.unit.suffix)},WPGMZA.CSSUnitInput.prototype.decrement=function(){this.parseUnits(this.unitValueInput.val());let value=this.unit.value;0<value-parseInt(value)?value-=.1:--value,this.setUnits(this.unit.value-1,this.unit.suffix)},WPGMZA.CSSUnitInput.prototype.update=function(){this.unitValueInput&&this.unitSuffixToggle&&(this.unitValueInput.val(this.unit.value),this.unitSuffixToggle.text(this.unit.suffix),this.unitSuffixToggle.show())},WPGMZA.CSSUnitInput.prototype.commit=function(){var syncValue=this.getUnits();this.element.val(syncValue),this.element.trigger("change")},$(document.body).ready(function(){$("input.wpgmza-stylig-unit-input").each(function(index,el){el.wpgmzaCSSUnitInput=WPGMZA.CSSUnitInput.createInstance(el)})})}),jQuery(function($){WPGMZA.DrawingManager=function(map){WPGMZA.assertInstanceOf(this,"DrawingManager"),WPGMZA.EventDispatcher.call(this);var self=this;this.map=map,this.mode=WPGMZA.DrawingManager.MODE_NONE,this.map.on("click rightclick",function(event){self.onMapClick(event)})},WPGMZA.DrawingManager.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.DrawingManager.prototype.constructor=WPGMZA.DrawingManager,WPGMZA.DrawingManager.MODE_NONE=null,WPGMZA.DrawingManager.MODE_MARKER="marker",WPGMZA.DrawingManager.MODE_POLYGON="polygon",WPGMZA.DrawingManager.MODE_POLYLINE="polyline",WPGMZA.DrawingManager.MODE_CIRCLE="circle",WPGMZA.DrawingManager.MODE_RECTANGLE="rectangle",WPGMZA.DrawingManager.MODE_HEATMAP="heatmap",WPGMZA.DrawingManager.MODE_POINTLABEL="pointlabel",WPGMZA.DrawingManager.MODE_IMAGEOVERLAY="imageoverlay",WPGMZA.DrawingManager.getConstructor=function(){return"google-maps"!==WPGMZA.settings.engine?WPGMZA.OLDrawingManager:WPGMZA.GoogleDrawingManager},WPGMZA.DrawingManager.createInstance=function(map){return new(WPGMZA.DrawingManager.getConstructor())(map)},WPGMZA.DrawingManager.prototype.setDrawingMode=function(mode){this.mode=mode,this.trigger("drawingmodechanged")},WPGMZA.DrawingManager.prototype.onMapClick=function(event){event.target instanceof WPGMZA.Map&&(this.mode!==WPGMZA.DrawingManager.MODE_POINTLABEL||this.pointlabel||(this.pointlabel=WPGMZA.Pointlabel.createInstance({center:new WPGMZA.LatLng({lat:event.latLng.lat,lng:event.latLng.lng}),map:this.map}),this.map.addPointlabel(this.pointlabel),this.pointlabel.setEditable(!0),this.onPointlabelComplete(this.pointlabel),this.pointlabel=!1))},WPGMZA.DrawingManager.prototype.onPointlabelComplete=function(pointlabel){var event=new WPGMZA.Event("pointlabelcomplete");event.enginePointlabel=pointlabel,this.dispatchEvent(event)}}),jQuery(function($){WPGMZA.EmbeddedMedia=function(element,container){if(!(element instanceof HTMLElement))throw new Error("Element is not an instance of HTMLInputElement");if(!(container instanceof HTMLElement))throw new Error("Container is not an instance of HTMLInputElement");const self=this;WPGMZA.EventDispatcher.apply(this),this.element=$(element),this.container=$(container),this.corners=["southEast"],this.handles=null,this.activeCorner=!1,this.container.on("mousemove",function(event){self.onMoveHandle(event)}),this.container.on("mouseup",function(event){self.activeCorner&&self.onDeactivateHandle(self.activeCorner)}),this.container.on("mouseleave",function(event){self.activeCorner&&(self.onDeactivateHandle(self.activeCorner),self.onDetach())}),this.container.on("mousedown",function(event){self.onDetach()})},WPGMZA.extend(WPGMZA.EmbeddedMedia,WPGMZA.EventDispatcher),WPGMZA.EmbeddedMedia.createInstance=function(element,container){return new WPGMZA.EmbeddedMedia(element,container)},WPGMZA.EmbeddedMedia.detatchAll=function(){var element;for(element of document.querySelectorAll(".wpgmza-embedded-media"))element.wpgmzaEmbeddedMedia&&element.wpgmzaEmbeddedMedia.onDetach();$(".wpgmza-embedded-media").removeClass("selected"),$(".wpgmza-embedded-media-handle").remove()},WPGMZA.EmbeddedMedia.prototype.onSelect=function(){this.element.addClass("selected"),this.updateHandles()},WPGMZA.EmbeddedMedia.prototype.onDetach=function(){this.element.removeClass("selected"),this.destroyHandles(),this.container.trigger("media_resized")},WPGMZA.EmbeddedMedia.prototype.onActivateHandle=function(corner){this.activeCorner=corner},WPGMZA.EmbeddedMedia.prototype.onDeactivateHandle=function(corner){this.activeCorner=!1,this.updateHandles()},WPGMZA.EmbeddedMedia.prototype.onMoveHandle=function(event){if(this.activeCorner&&this.handles[this.activeCorner]){const mouse=this.getMousePosition(event);this.handles[this.activeCorner].element&&(event=this.getAnchorPosition().y+this.element.height(),mouse.y>event&&(mouse.y=event),this.handles[this.activeCorner].element.css({left:mouse.x-3+"px",top:mouse.y-3+"px"}),this.applyResize(mouse))}},WPGMZA.EmbeddedMedia.prototype.createHandles=function(){if(!this.handles){this.handles={};for(var corner of this.corners)this.handles[corner]={element:$("<div/>"),mutating:!1},this.handles[corner].element.addClass("wpgmza-embedded-media-handle"),this.handles[corner].element.attr("data-corner",corner),this.container.append(this.handles[corner].element),this.bindHandle(corner)}},WPGMZA.EmbeddedMedia.prototype.destroyHandles=function(){if(this.handles&&this.handles instanceof Object){for(var i in this.handles){const handle=this.handles[i];handle.element&&handle.element.remove()}this.handles=null}},WPGMZA.EmbeddedMedia.prototype.updateHandles=function(){this.createHandles();var anchor=this.getAnchorPosition();if(this.handles&&this.handles instanceof Object)for(var corner in this.handles){const handle=this.handles[corner].element,position={top:0,left:0};"southEast"===corner&&(position.left=anchor.x+this.element.width(),position.top=anchor.y+this.element.height()),handle.css({left:position.left-3+"px",top:position.top-3+"px"})}},WPGMZA.EmbeddedMedia.prototype.bindHandle=function(corner){const self=this;this.handles&&this.handles[corner]&&(this.handles[corner].element.on("mousedown",function(event){event.preventDefault(),event.stopPropagation(),self.onActivateHandle(corner)}),this.handles[corner].element.on("mouseup",function(event){event.preventDefault(),event.stopPropagation(),self.onDeactivateHandle(corner)}))},WPGMZA.EmbeddedMedia.prototype.applyResize=function(mouse){var anchor=this.getAnchorPosition(),padding=parseInt(this.container.css("padding").replace("px","")),mouse=Math.abs(mouse.x-anchor.x),mouse=this.clamp(padding,this.container.width()-padding,mouse);this.element.css("width",parseInt(mouse)+"px"),this.element.attr("width",parseInt(mouse)),this.container.trigger("media_resized")},WPGMZA.EmbeddedMedia.prototype.getMousePosition=function(event){event=event.originalEvent||event;const pos={x:parseInt(event.pageX-this.container.offset().left),y:parseInt(event.pageY-this.container.offset().top)};event=parseInt(this.container.css("padding").replace("px",""));return pos.x=this.clamp(event,this.container.width()-event,pos.x),pos.y=this.clamp(event,this.container.height()-event,pos.y),pos},WPGMZA.EmbeddedMedia.prototype.getAnchorPosition=function(){return{x:parseInt(this.element.offset().left-this.container.offset().left),y:parseInt(this.element.offset().top-this.container.offset().top)}},WPGMZA.EmbeddedMedia.prototype.clamp=function(min,max,value){return isNaN(value)&&(value=0),Math.min(Math.max(value,min),max)}}),jQuery(function($){WPGMZA.Event=function(options){if("string"==typeof options&&(this.type=options),this.bubbles=!0,this.cancelable=!0,this.phase=WPGMZA.Event.PHASE_CAPTURE,this.target=null,this._cancelled=!1,"object"==typeof options)for(var name in options)this[name]=options[name]},WPGMZA.Event.CAPTURING_PHASE=0,WPGMZA.Event.AT_TARGET=1,WPGMZA.Event.BUBBLING_PHASE=2,WPGMZA.Event.prototype.stopPropagation=function(){this._cancelled=!0}}),jQuery(function($){WPGMZA.FancyControls={formatToggleSwitch:function(el){var div=$("<div class='switch'></div>"),input=el,el=el.parentNode,text=$(el).text().trim(),label=$("<label></label>");$(input).addClass("cmn-toggle cmn-toggle-round-flat"),$(input).attr("id",$(input).attr("name")),$(label).attr("for",$(input).attr("name")),$(div).append(input),$(div).append(label),$(el).replaceWith(div),$(div).wrap($("<div></div>")),$(div).after(text)},formatToggleButton:function(el){var div=$("<div class='switch'></div>"),input=el,el=el.parentNode,text=$(el).text().trim(),label=$("<label></label>");$(input).addClass("cmn-toggle cmn-toggle-yes-no"),$(input).attr("id",$(input).attr("name")),$(label).attr("for",$(input).attr("name")),$(label).attr("data-on",WPGMZA.localized_strings.yes),$(label).attr("data-off",WPGMZA.localized_strings.no),$(div).append(input),$(div).append(label),$(el).replaceWith(div),$(div).wrap($("<div></div>")),$(div).after(text)}},$(".wpgmza-fancy-toggle-switch").each(function(index,el){WPGMZA.FancyControls.formatToggleSwitch(el)}),$(".wpgmza-fancy-toggle-button").each(function(index,el){WPGMZA.FancyControls.formatToggleButton(el)})}),jQuery(function($){WPGMZA.Feature=function(options){for(var key in WPGMZA.assertInstanceOf(this,"Feature"),WPGMZA.EventDispatcher.call(this),this.id=-1,options)this[key]=options[key]},WPGMZA.extend(WPGMZA.Feature,WPGMZA.EventDispatcher),WPGMZA.MapObject=WPGMZA.Feature,WPGMZA.Feature.prototype.parseGeometry=function(subject){if("string"==typeof subject&&subject.match(/^\[/))try{subject=JSON.parse(subject)}catch(e){}if("object"==typeof subject){for(var arr=subject,i=0;i<arr.length;i++)arr[i].lat=parseFloat(arr[i].lat),arr[i].lng=parseFloat(arr[i].lng);return arr}if("string"!=typeof subject)throw new Error("Invalid geometry");for(var coords,results=[],pairs=subject.replace(/[^ ,\d\.\-+e]/g,"").split(","),i=0;i<pairs.length;i++)coords=pairs[i].split(" "),results.push({lat:parseFloat(coords[1]),lng:parseFloat(coords[0])});return results},WPGMZA.Feature.prototype.setOptions=function(options){for(var key in options)this[key]=options[key];this.updateNativeFeature()},WPGMZA.Feature.prototype.setEditable=function(editable){this.setOptions({editable:editable})},WPGMZA.Feature.prototype.setDraggable=function(draggable){this.setOptions({draggable:draggable})},WPGMZA.Feature.prototype.getScalarProperties=function(){var key,options={};for(key in this)switch(typeof this[key]){case"number":options[key]=parseFloat(this[key]);break;case"boolean":case"string":options[key]=this[key]}return options},WPGMZA.Feature.prototype.updateNativeFeature=function(){var props=this.getScalarProperties();"open-layers"===WPGMZA.settings.engine?this.layer&&this.layer.setStyle(WPGMZA.OLFeature.getOLStyle(props)):this.googleFeature.setOptions(props)}}),jQuery(function($){WPGMZA.FriendlyError=function(){}}),jQuery(function($){WPGMZA.GenericModal=function(element,complete,cancel){this.element=$(element),this._onComplete=complete||!1,this._onCancel=cancel||!1,this.bindEvents()},WPGMZA.extend(WPGMZA.GenericModal,WPGMZA.EventDispatcher),WPGMZA.GenericModal.createInstance=function(element,complete,cancel){return new(WPGMZA.isProVersion()?WPGMZA.ProGenericModal:WPGMZA.GenericModal)(element,complete,cancel)},WPGMZA.GenericModal.prototype.bindEvents=function(){const self=this;this.element.on("click",".wpgmza-button",function(){"complete"===$(this).data("action")?self.onComplete():self.onCancel()})},WPGMZA.GenericModal.prototype.getData=function(){const data={};return this.element.find("input,select").each(function(){$(this).data("ajax-name")&&(data[$(this).data("ajax-name")]=$(this).val())}),data},WPGMZA.GenericModal.prototype.onComplete=function(){this.hide(),"function"==typeof this._onComplete&&this._onComplete(this.getData())},WPGMZA.GenericModal.prototype.onCancel=function(){this.hide(),"function"==typeof this._onCancel&&this._onCancel()},WPGMZA.GenericModal.prototype.show=function(complete,cancel){this._onComplete=complete||this._onComplete,this._onCancel=cancel||this._onCancel,this.element.addClass("pending")},WPGMZA.GenericModal.prototype.hide=function(){this.element.removeClass("pending")}}),jQuery(function($){WPGMZA.Geocoder=function(){WPGMZA.assertInstanceOf(this,"Geocoder")},WPGMZA.Geocoder.SUCCESS="success",WPGMZA.Geocoder.ZERO_RESULTS="zero-results",WPGMZA.Geocoder.FAIL="fail",WPGMZA.Geocoder.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.GoogleGeocoder:WPGMZA.OLGeocoder},WPGMZA.Geocoder.createInstance=function(){return new(WPGMZA.Geocoder.getConstructor())},WPGMZA.Geocoder.prototype.getLatLngFromAddress=function(options,callback){WPGMZA.isLatLngString(options.address)&&(options=options.address.split(/,\s*/),callback([(callback=new WPGMZA.LatLng({lat:parseFloat(options[0]),lng:parseFloat(options[1])})).latLng=callback],WPGMZA.Geocoder.SUCCESS))},WPGMZA.Geocoder.prototype.getAddressFromLatLng=function(options,callback){callback([new WPGMZA.LatLng(options.latLng).toString()],WPGMZA.Geocoder.SUCCESS)},WPGMZA.Geocoder.prototype.geocode=function(options,callback){if("address"in options)return this.getLatLngFromAddress(options,callback);if("latLng"in options)return this.getAddressFromLatLng(options,callback);throw new Error("You must supply either a latLng or address")}}),jQuery(function($){WPGMZA.GoogleAPIErrorHandler=function(){var _error,self=this;"google-maps"==WPGMZA.settings.engine&&("map-edit"==WPGMZA.currentPage||0==WPGMZA.is_admin&&1==WPGMZA.userCanAdministrator)&&(this.element=$(WPGMZA.html.googleMapsAPIErrorDialog),1==WPGMZA.is_admin&&this.element.find(".wpgmza-front-end-only").remove(),this.errorMessageList=this.element.find(".wpgmza-google-api-error-list"),this.templateListItem=this.element.find("li.template").remove(),this.messagesAlreadyDisplayed={},_error=console.error,console.error=function(message){self.onErrorMessage(message),_error.apply(this,arguments)},"google-maps"!=WPGMZA.settings.engine||WPGMZA.settings.wpgmza_google_maps_api_key&&WPGMZA.settings.wpgmza_google_maps_api_key.length||WPGMZA.getCurrentPage()==WPGMZA.PAGE_MAP_EDIT||this.addErrorMessage(WPGMZA.localized_strings.no_google_maps_api_key,["https://www.wpgmaps.com/documentation/creating-a-google-maps-api-key/"]))},WPGMZA.GoogleAPIErrorHandler.prototype.onErrorMessage=function(message){var m,urls;message&&((m=message.match(/You have exceeded your (daily )?request quota for this API/))||(m=message.match(/This API project is not authorized to use this API/))||(m=message.match(/^Geocoding Service: .+/))?(urls=message.match(/http(s)?:\/\/[^\s]+/gm),this.addErrorMessage(m[0],urls)):(m=message.match(/^Google Maps.+error: (.+)\s+(http(s?):\/\/.+)/m))&&this.addErrorMessage(m[1].replace(/([A-Z])/g," $1"),[m[2]]))},WPGMZA.GoogleAPIErrorHandler.prototype.addErrorMessage=function(message,urls){var self=this;if(!this.messagesAlreadyDisplayed[message]){var li=this.templateListItem.clone(),buttonContainer=($(li).find(".wpgmza-message").html(message),$(li).find(".wpgmza-documentation-buttons")),buttonTemplate=$(li).find(".wpgmza-documentation-buttons>a");if(buttonTemplate.remove(),urls&&urls.length){for(var i=0;i<urls.length;i++){urls[i];var button=buttonTemplate.clone(),text=WPGMZA.localized_strings.documentation;button.attr("href",urls[i]),$(button).find("i").addClass("fa-external-link"),$(button).append(text)}buttonContainer.append(button)}$(this.errorMessageList).append(li),$("#wpgmza_map, .wpgmza_map").each(function(index,el){var container=$(el).find(".wpgmza-google-maps-api-error-overlay");0==container.length&&(container=$("<div class='wpgmza-google-maps-api-error-overlay'></div>")).html(self.element.html()),setTimeout(function(){$(el).append(container)},1e3)}),$(".gm-err-container").parent().css({"z-index":1}),this.messagesAlreadyDisplayed[message]=!0}},WPGMZA.googleAPIErrorHandler=new WPGMZA.GoogleAPIErrorHandler}),jQuery(function($){WPGMZA.InfoWindow=function(feature){var self=this;WPGMZA.EventDispatcher.call(this),WPGMZA.assertInstanceOf(this,"InfoWindow"),this.on("infowindowopen",function(event){self.onOpen(event)}),feature&&(this.feature=feature,this.state=WPGMZA.InfoWindow.STATE_CLOSED,feature.map?setTimeout(function(){self.onFeatureAdded(event)},100):feature.addEventListener("added",function(event){self.onFeatureAdded(event)}))},WPGMZA.InfoWindow.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.InfoWindow.prototype.constructor=WPGMZA.InfoWindow,WPGMZA.InfoWindow.OPEN_BY_CLICK=1,WPGMZA.InfoWindow.OPEN_BY_HOVER=2,WPGMZA.InfoWindow.STATE_OPEN="open",WPGMZA.InfoWindow.STATE_CLOSED="closed",WPGMZA.InfoWindow.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProInfoWindow:WPGMZA.GoogleInfoWindow:WPGMZA.isProVersion()?WPGMZA.OLProInfoWindow:WPGMZA.OLInfoWindow},WPGMZA.InfoWindow.createInstance=function(feature){return new(this.getConstructor())(feature)},Object.defineProperty(WPGMZA.InfoWindow.prototype,"content",{get:function(){return this.getContent()},set:function(value){this.contentHtml=value}}),WPGMZA.InfoWindow.prototype.addEditButton=function(){return"map-edit"==WPGMZA.currentPage&&this.feature instanceof WPGMZA.Marker?' <a title="Edit this marker" style="width:15px;" class="wpgmza_edit_btn" data-edit-marker-id="'+this.feature.id+'"><i class="fa fa-edit"></i></a>':""},WPGMZA.InfoWindow.prototype.workOutDistanceBetweenTwoMarkers=function(location1,location2){if(location1&&location2)return location1=WPGMZA.Distance.between(location1,location2),this.distanceUnits==WPGMZA.Distance.MILES&&(location1/=WPGMZA.Distance.KILOMETERS_PER_MILE),Math.round(location1,2)},WPGMZA.InfoWindow.prototype.getContent=function(callback){var currentLatLng,html="",extra_html="";return this.feature instanceof WPGMZA.Marker&&(this.feature.map.settings.store_locator_show_distance&&this.feature.map.storeLocator&&this.feature.map.storeLocator.state==WPGMZA.StoreLocator.STATE_APPLIED&&(currentLatLng=this.feature.getPosition(),currentLatLng=this.workOutDistanceBetweenTwoMarkers(this.feature.map.storeLocator.center,currentLatLng),extra_html+="<p>"+(this.feature.map.settings.store_locator_distance==WPGMZA.Distance.KILOMETERS?currentLatLng+WPGMZA.localized_strings.kilometers_away:currentLatLng+" "+WPGMZA.localized_strings.miles_away)+"</p>"),html=this.feature.address+extra_html),this.contentHtml&&(html=this.contentHtml),callback&&callback(html),html},WPGMZA.InfoWindow.prototype.open=function(map,feature){return this.feature=feature,!WPGMZA.settings.disable_infowindows&&"1"!=WPGMZA.settings.wpgmza_settings_disable_infowindows&&(!this.feature.disableInfoWindow&&(this.state=WPGMZA.InfoWindow.STATE_OPEN,!0))},WPGMZA.InfoWindow.prototype.close=function(){this.state!=WPGMZA.InfoWindow.STATE_CLOSED&&(this.state=WPGMZA.InfoWindow.STATE_CLOSED,this.trigger("infowindowclose"))},WPGMZA.InfoWindow.prototype.setContent=function(options){},WPGMZA.InfoWindow.prototype.setOptions=function(options){},WPGMZA.InfoWindow.prototype.onFeatureAdded=function(){1==this.feature.settings.infoopen&&this.open()},WPGMZA.InfoWindow.prototype.onOpen=function(){}}),jQuery(function($){"installer"==WPGMZA.currentPage&&(WPGMZA.Installer=function(){var defaultEngine,self=this;WPGMZA.EventDispatcher.apply(this),this.element=$(document.body).find(".wpgmza-installer-steps"),this.skipButton=$(document.body).find(".wpgmza-installer-skip"),this.element.length<=0||(this.redirectUrl=this.element.data("redirect"),this.step=0,this.max=0,this.findMax(),$(this.element).on("click",".next-step-button",function(event){self.next()}),$(this.element).on("click",".prev-step-button",function(event){self.prev()}),$(this.element).on("click",".sub-step-trigger",function(event){self.triggerSubStep($(this))}),$(this.element).on("change",'input[name="wpgmza_maps_engine"]',function(event){self.setEngine($(this).val())}),$(this.element).on("keyup change",'input[name="api_key"]',function(event){self.setApiKey($(this).val())}),$(this.element).on("change",'select[name="tile_server_url"]',function(event){self.setTileServer($(this).val())}),$(this.element).on("click",".google-maps-auto-key-form-wrapper .wpgmza-button",function(event){self.getAutoKey()}),$(this.element).on("click",".launcher-trigger",function(event){var launcher=$(this).data("launcher");launcher&&"google-maps-quick-start-launcher"===launcher&&self.launchQuickStart()}),this.skipButton.on("click",function(event){event.preventDefault(),self.skip()}),defaultEngine=WPGMZA&&WPGMZA.settings&&WPGMZA.settings.engine?WPGMZA.settings.engine:"google-maps",$(this.element).find('input[name="wpgmza_maps_engine"][value="'+defaultEngine+'"]').prop("checked",!0).trigger("change"),defaultEngine=WPGMZA&&WPGMZA.settings&&WPGMZA.settings.googleMapsApiKey?WPGMZA.settings.googleMapsApiKey:"",this.element.find('input[name="api_key"]').val(defaultEngine).trigger("change"),this.trigger("init.installer.admin"),this.loadStep(this.step))},WPGMZA.extend(WPGMZA.Installer,WPGMZA.EventDispatcher),WPGMZA.Installer.NODE_SERVER="https://wpgmaps.us-3.evennode.com/api/v1/",WPGMZA.Installer.createInstance=function(){return new WPGMZA.Installer},WPGMZA.Installer.prototype.findMax=function(){var self=this;$(this.element).find(".step").each(function(){parseInt($(this).data("step"))>self.max&&(self.max=parseInt($(this).data("step")))})},WPGMZA.Installer.prototype.prepareAddressFields=function(){$(this.element).find("input.wpgmza-address").each(function(index,el){el.addressInput=WPGMZA.AddressInput.createInstance(el,null)})},WPGMZA.Installer.prototype.next=function(){this.step<this.max?this.loadStep(this.step+1):this.complete()},WPGMZA.Installer.prototype.prev=function(){0<this.step&&this.loadStep(this.step-1)},WPGMZA.Installer.prototype.loadStep=function(index){this.loadSubSteps(index),$(this.element).find(".step").removeClass("active"),$(this.element).find('.step[data-step="'+index+'"]').addClass("active"),this.step=index,0===this.step?$(this.element).find(".prev-step-button").addClass("wpgmza-hidden"):$(this.element).find(".prev-step-button").removeClass("wpgmza-hidden"),this.step===this.max?$(this.element).find(".next-step-button span").text($(this.element).find(".next-step-button").data("final")):$(this.element).find(".next-step-button span").text($(this.element).find(".next-step-button").data("next")),this.autoFocus(),this.applyStepConditionState(),$(window).scrollTop(0),this.trigger("step.installer.admin")},WPGMZA.Installer.prototype.loadSubSteps=function(index){const stepWrapper=$(this.element).find('.step[data-step="'+index+'"]');stepWrapper.find(".sub-step-container").length&&(stepWrapper.find(".sub-step").addClass("wpgmza-hidden"),stepWrapper.find(".sub-step-container").removeClass("wpgmza-hidden"))},WPGMZA.Installer.prototype.triggerSubStep=function(context){const stepWrapper=$(this.element).find('.step[data-step="'+this.step+'"]');if(stepWrapper.find(".sub-step-container").length){context=context.data("sub-step");if(stepWrapper.find('.sub-step[data-sub-step="'+context+'"]').length&&(stepWrapper.find(".sub-step-container").addClass("wpgmza-hidden"),stepWrapper.find(".sub-step").addClass("wpgmza-hidden"),stepWrapper.find('.sub-step[data-sub-step="'+context+'"]').removeClass("wpgmza-hidden"),"google-maps-auto-key"===context))try{if(WPGMZA.getCurrentPosition(function(data){if(data.coords){data=data.coords;if($('.google-maps-auto-key-form-wrapper input[name="address"]').attr("placeholder","Fetching..."),data.latitude&&data.longitude){const geocoder=WPGMZA.Geocoder.createInstance();geocoder.getAddressFromLatLng({latLng:new WPGMZA.LatLng({lat:data.latitude,lng:data.longitude})},function(address){$('.google-maps-auto-key-form-wrapper input[name="address"]').attr("placeholder",""),address&&$('.google-maps-auto-key-form-wrapper input[name="address"]').val(address)})}else $('.google-maps-auto-key-form-wrapper input[name="address"]').attr("placeholder","")}}),$('.google-maps-auto-key-form-wrapper input[name="site_url"]').val().trim().length<=0){var domain=window.location.hostname;if("localhost"===domain)try{var paths=window.location.pathname.match(/\/(.*?)\//);paths&&2<=paths.length&&paths[1]&&(domain+="-"+paths[1])}catch(ex){}$('.google-maps-auto-key-form-wrapper input[name="site_url"]').val(domain),$('.google-maps-auto-key-form-wrapper input[name="site_url"]').attr("data-predicted-domain",domain)}}catch(ex){}}},WPGMZA.Installer.prototype.getActiveBlock=function(){return $(this.element).find('.step[data-step="'+this.step+'"]')},WPGMZA.Installer.prototype.autoFocus=function(){var block=this.getActiveBlock();block&&(0<block.find("input").length?block.find("input")[0].focus():0<block.find("select").length&&block.find("select")[0].focus())},WPGMZA.Installer.prototype.complete=function(){$(this.element).find(".step").removeClass("active"),$(this.element).find(".step-controller").addClass("wpgmza-hidden"),$(this.element).find(".step-loader").removeClass("wpgmza-hidden"),$(this.element).find(".step-loader .progress-finish").removeClass("wpgmza-hidden"),this.saveOptions()},WPGMZA.Installer.prototype.getData=function(){var data={};return $(this.element).find(".step").each(function(){$(this).find("input,select").each(function(){var value,name=$(this).attr("name");name&&""!==name.trim()&&""!==(value=$(this).val()).trim()&&(data[name.trim()]=value.trim())})}),data},WPGMZA.Installer.prototype.setEngine=function(engine){this.engine=engine,$(this.element).attr("data-engine",engine)},WPGMZA.Installer.prototype.setApiKey=function(apiKey){this.apiKey=apiKey.trim(),this.applyStepConditionState()},WPGMZA.Installer.prototype.setTileServer=function(server){let previewLink=this.tileServer=server;previewLink=(previewLink=previewLink.replace("{a-c}","a")).replace("{z}/{x}/{y}","7/20/49"),$(this.element).find(".open_layers_sample_tile").attr("src",previewLink)},WPGMZA.Installer.prototype.applyStepConditionState=function(){const stepWrapper=this.getActiveBlock();var condition=stepWrapper.data("conditional");const continueButton=$(this.element).find(".next-step-button");!condition||this.hasSatisfiedStepCondition(condition)?continueButton.removeClass("wpgmza-hidden"):continueButton.addClass("wpgmza-hidden")},WPGMZA.Installer.prototype.hasSatisfiedStepCondition=function(condition){let satisfied=!1;return satisfied="engine-set-up"===condition?!this.engine||"google-maps"!==this.engine||!!this.apiKey:satisfied},WPGMZA.Installer.prototype.getAutoKey=function(){return!1},WPGMZA.Installer.prototype.launchQuickStart=function(){const popupDimensions={width:570,height:700};popupDimensions.left=(screen.width-popupDimensions.width)/2,popupDimensions.top=(screen.height-popupDimensions.height)/2,$("#adminmenuwrap").length&&(popupDimensions.left+=$("#adminmenuwrap").width()/2);let attributes=[];attributes.push("resizable=yes"),attributes.push("width="+popupDimensions.width),attributes.push("height="+popupDimensions.height),attributes.push("left="+popupDimensions.left),attributes.push("top="+popupDimensions.top),attributes=attributes.join(","),window.open("https://console.cloud.google.com/google/maps-hosted","WP Go Maps - Create API Key",attributes)},WPGMZA.Installer.prototype.saveOptions=function(){const self=this;var formData=this.getData(),formData={action:"wpgmza_installer_page_save_options",nonce:this.element.attr("data-ajax-nonce"),wpgmza_maps_engine:this.engine,tile_server_url:formData.tile_server_url,api_key:formData.api_key};$(event.target).prop("disabled",!0),$.ajax(WPGMZA.ajaxurl,{method:"POST",data:formData,success:function(response,status,xhr){window.location.href=self.redirectUrl}})},WPGMZA.Installer.prototype.hideAutoKeyError=function(){$(".auto-key-error").addClass("wpgmza-hidden")},WPGMZA.Installer.prototype.showAutoKeyError=function(codeOrMsg){let message="";(message=-1===codeOrMsg.indexOf(" ")?$(".auto-key-error").data(codeOrMsg)||codeOrMsg:codeOrMsg).length?($(".auto-key-error").find(".notice").text(message),$(".auto-key-error").removeClass("wpgmza-hidden")):this.hideAutoKeyError()},WPGMZA.Installer.prototype.skip=function(){const self=this;$(this.element).find(".step").removeClass("active"),$(this.element).find(".step-controller").addClass("wpgmza-hidden"),$(this.element).find(".step-loader").removeClass("wpgmza-hidden"),$(this.element).find(".step-loader .progress-finish").removeClass("wpgmza-hidden"),this.skipButton.addClass("wpgmza-hidden");var options={action:"wpgmza_installer_page_skip",nonce:this.element.attr("data-ajax-nonce")};$.ajax(WPGMZA.ajaxurl,{method:"POST",data:options,success:function(response,status,xhr){window.location.href=self.redirectUrl}})},$(document).ready(function(event){WPGMZA.installer=WPGMZA.Installer.createInstance()}))}),jQuery(function($){WPGMZA.InternalEngine={LEGACY:"legacy",ATLAS_NOVUS:"atlast-novus",isLegacy:function(){return WPGMZA.settings.internalEngine===WPGMZA.InternalEngine.LEGACY},getEngine:function(){return WPGMZA.settings.internalEngine}}}),jQuery(function($){WPGMZA.InternalViewport=function(map){WPGMZA.EventDispatcher.apply(this),this.map=map,this.limits={},this.element=this.getContainer(),this.update(),$(window).on("resize",event=>{this.trigger("resize.internalviewport"),this.update()})},WPGMZA.extend(WPGMZA.InternalViewport,WPGMZA.EventDispatcher),WPGMZA.InternalViewport.RECT_TYPE_LARGE=0,WPGMZA.InternalViewport.RECT_TYPE_MEDIUM=1,WPGMZA.InternalViewport.RECT_TYPE_SMALL=2,WPGMZA.InternalViewport.CONTAINER_THRESHOLD_MEDIUM=960,WPGMZA.InternalViewport.CONTAINER_THRESHOLD_SMALL=760,WPGMZA.InternalViewport.createInstance=function(map){return new WPGMZA.InternalViewport(map)},WPGMZA.InternalViewport.prototype.getContainer=function(){return this.map&&this.map.element?this.map.element:document.body||!1},WPGMZA.InternalViewport.prototype.getRectType=function(){let type=WPGMZA.InternalViewport.RECT_TYPE_LARGE;return this.limits.container&&this.limits.container.width.value&&(this.limits.container.width.value<=WPGMZA.InternalViewport.CONTAINER_THRESHOLD_SMALL?type=WPGMZA.InternalViewport.RECT_TYPE_SMALL:this.limits.container.width.value<=WPGMZA.InternalViewport.CONTAINER_THRESHOLD_MEDIUM&&(type=WPGMZA.InternalViewport.RECT_TYPE_MEDIUM)),type},WPGMZA.InternalViewport.prototype.wrapMeasurement=function(value,suffix){return{value:value,suffix:suffix||"px"}},WPGMZA.InternalViewport.prototype.update=function(){this.trace(),this.localize(),this.addClass(),this.trigger("update.internalviewport")},WPGMZA.InternalViewport.prototype.trace=function(){this.traceLimits(),this.trigger("trace.internalviewport")},WPGMZA.InternalViewport.prototype.traceLimits=function(){this.limits={container:{},overlays:{},panels:{}},this.getContainer()&&(this.limits.container.width=this.wrapMeasurement(parseInt(this.map.element.offsetWidth)),this.limits.container.height=this.wrapMeasurement(parseInt(this.map.element.offsetHeight)),mode=this.getRectType(),this.limits.container.width&&(this.limits.overlays.max_width=this.wrapMeasurement(100*[.5,.7,1][mode],"%"),this.limits.panels.max_width=this.wrapMeasurement(100*[.3,.5,1][mode],"%")))},WPGMZA.InternalViewport.prototype.localize=function(){const localized={};for(var tag in this.limits)if(this.limits[tag])for(var name in this.limits[tag]){var prop=this.limits[tag][name];name=name.replaceAll("_","-"),name="--wpgmza--viewport-"+tag+"-"+name,localized[name]=prop.value+prop.suffix}var container=this.getContainer();container&&$(container).css(localized),this.trigger("localize.internalviewport")},WPGMZA.InternalViewport.prototype.addClass=function(){var mode,classes=["wpgmza-viewport-large","wpgmza-viewport-medium","wpgmza-viewport-small"],container=this.getContainer();container&&($(container).removeClass(classes),mode=this.getRectType(),$(container).addClass(classes[mode]))}}),jQuery(function($){WPGMZA.LatLng=function(arg,lng){if(this._lat=0,(this._lng=0)!=arguments.length)if(1==arguments.length){if("string"==typeof arg){var m;if(!(m=arg.match(WPGMZA.LatLng.REGEXP)))throw new Error("Invalid LatLng string");arg={lat:m[1],lng:m[3]}}if("object"!=typeof arg||!("lat"in arg&&"lng"in arg))throw new Error("Argument must be a LatLng literal");this.lat=arg.lat,this.lng=arg.lng}else this.lat=arg,this.lng=lng},WPGMZA.LatLng.REGEXP=/^(\-?\d+(\.\d+)?),\s*(\-?\d+(\.\d+)?)$/,WPGMZA.LatLng.isValid=function(obj){return"object"==typeof obj&&("lat"in obj&&"lng"in obj)},WPGMZA.LatLng.isLatLngString=function(str){return"string"==typeof str&&!!str.match(WPGMZA.LatLng.REGEXP)},Object.defineProperty(WPGMZA.LatLng.prototype,"lat",{get:function(){return this._lat},set:function(val){if(!$.isNumeric(val))throw new Error("Latitude must be numeric");this._lat=parseFloat(val)}}),Object.defineProperty(WPGMZA.LatLng.prototype,"lng",{get:function(){return this._lng},set:function(val){if(!$.isNumeric(val))throw new Error("Longitude must be numeric");this._lng=parseFloat(val)}}),WPGMZA.LatLng.fromString=function(string){if(!WPGMZA.LatLng.isLatLngString(string))throw new Error("Not a valid latlng string");string=string.match(WPGMZA.LatLng.REGEXP);return new WPGMZA.LatLng({lat:parseFloat(string[1]),lng:parseFloat(string[3])})},WPGMZA.LatLng.prototype.toString=function(){return this._lat+", "+this._lng},WPGMZA.LatLng.fromCurrentPosition=function(callback,options){options=options||{},callback&&WPGMZA.getCurrentPosition(function(position){var latLng=new WPGMZA.LatLng({lat:position.coords.latitude,lng:position.coords.longitude});options.geocodeAddress?WPGMZA.Geocoder.createInstance().getAddressFromLatLng({latLng:latLng},function(results){results.length&&(latLng.address=results[0]),callback(latLng)}):callback(latLng)})},WPGMZA.LatLng.fromGoogleLatLng=function(googleLatLng){return new WPGMZA.LatLng(googleLatLng.lat(),googleLatLng.lng())},WPGMZA.LatLng.toGoogleLatLngArray=function(arr){var result=[];return arr.forEach(function(nativeLatLng){if(!(nativeLatLng instanceof WPGMZA.LatLng||"lat"in nativeLatLng&&"lng"in nativeLatLng))throw new Error("Unexpected input");result.push(new google.maps.LatLng({lat:parseFloat(nativeLatLng.lat),lng:parseFloat(nativeLatLng.lng)}))}),result},WPGMZA.LatLng.prototype.toGoogleLatLng=function(){return new google.maps.LatLng({lat:this.lat,lng:this.lng})},WPGMZA.LatLng.prototype.toLatLngLiteral=function(){return{lat:this.lat,lng:this.lng}},WPGMZA.LatLng.prototype.moveByDistance=function(kilometers,heading){var kilometers=parseFloat(kilometers)/6371,heading=parseFloat(heading)/180*Math.PI,phi1=this.lat/180*Math.PI,lambda1=this.lng/180*Math.PI,sinPhi1=Math.sin(phi1),phi1=Math.cos(phi1),sinDelta=Math.sin(kilometers),kilometers=Math.cos(kilometers),sinTheta=Math.sin(heading),heading=sinPhi1*kilometers+phi1*sinDelta*Math.cos(heading),phi2=Math.asin(heading),lambda1=lambda1+Math.atan2(sinTheta*sinDelta*phi1,kilometers-sinPhi1*heading);this.lat=180*phi2/Math.PI,this.lng=180*lambda1/Math.PI},WPGMZA.LatLng.prototype.getGreatCircleDistance=function(arg1,arg2){var lat1=this.lat,lon1=this.lng;if(1==arguments.length)other=new WPGMZA.LatLng(arg1);else{if(2!=arguments.length)throw new Error("Invalid number of arguments");other=new WPGMZA.LatLng(arg1,arg2)}var lat2=other.lat,other=other.lng,phi1=lat1.toRadians(),phi2=lat2.toRadians(),lat2=(lat2-lat1).toRadians(),lat1=(other-lon1).toRadians(),other=Math.sin(lat2/2)*Math.sin(lat2/2)+Math.cos(phi1)*Math.cos(phi2)*Math.sin(lat1/2)*Math.sin(lat1/2);return 6371*(2*Math.atan2(Math.sqrt(other),Math.sqrt(1-other)))}}),jQuery(function($){WPGMZA.LatLngBounds=function(southWest,northEast){var other;southWest instanceof WPGMZA.LatLngBounds?(this.south=(other=southWest).south,this.north=other.north,this.west=other.west,this.east=other.east):southWest&&northEast&&(this.south=southWest.lat,this.north=northEast.lat,this.west=southWest.lng,this.east=northEast.lng)},WPGMZA.LatLngBounds.fromGoogleLatLngBounds=function(googleLatLngBounds){if(!(googleLatLngBounds instanceof google.maps.LatLngBounds))throw new Error("Argument must be an instance of google.maps.LatLngBounds");var result=new WPGMZA.LatLngBounds,southWest=googleLatLngBounds.getSouthWest(),googleLatLngBounds=googleLatLngBounds.getNorthEast();return result.north=googleLatLngBounds.lat(),result.south=southWest.lat(),result.west=southWest.lng(),result.east=googleLatLngBounds.lng(),result},WPGMZA.LatLngBounds.fromGoogleLatLngBoundsLiteral=function(obj){var result=new WPGMZA.LatLngBounds,southWest=obj.southwest,obj=obj.northeast;return result.north=obj.lat,result.south=southWest.lat,result.west=southWest.lng,result.east=obj.lng,result},WPGMZA.LatLngBounds.prototype.isInInitialState=function(){return null==this.north&&null==this.south&&null==this.west&&null==this.east},WPGMZA.LatLngBounds.prototype.extend=function(latLng){if(latLng instanceof WPGMZA.LatLng||(latLng=new WPGMZA.LatLng(latLng)),this.isInInitialState())return this.north=this.south=latLng.lat,void(this.west=this.east=latLng.lng);latLng.lat<this.north&&(this.north=latLng.lat),latLng.lat>this.south&&(this.south=latLng.lat),latLng.lng<this.west&&(this.west=latLng.lng),latLng.lng>this.east&&(this.east=latLng.lng)},WPGMZA.LatLngBounds.prototype.extendByPixelMargin=function(map,x,arg){var y=x;if(!(map instanceof WPGMZA.Map))throw new Error("First argument must be an instance of WPGMZA.Map");if(this.isInInitialState())throw new Error("Cannot extend by pixels in initial state");3<=arguments.length&&(y=arg);var southWest=new WPGMZA.LatLng(this.south,this.west),northEast=new WPGMZA.LatLng(this.north,this.east),southWest=map.latLngToPixels(southWest),northEast=map.latLngToPixels(northEast);southWest.x-=x,southWest.y+=y,northEast.x+=x,northEast.y-=y,southWest=map.pixelsToLatLng(southWest.x,southWest.y),northEast=map.pixelsToLatLng(northEast.x,northEast.y),this.toString();this.north=northEast.lat,this.south=southWest.lat,this.west=southWest.lng,this.east=northEast.lng},WPGMZA.LatLngBounds.prototype.contains=function(latLng){if(latLng instanceof WPGMZA.LatLng)return!(latLng.lat<Math.min(this.north,this.south))&&(!(latLng.lat>Math.max(this.north,this.south))&&(this.west<this.east?latLng.lng>=this.west&&latLng.lng<=this.east:latLng.lng<=this.west||latLng.lng>=this.east));throw new Error("Argument must be an instance of WPGMZA.LatLng")},WPGMZA.LatLngBounds.prototype.toString=function(){return this.north+"N "+this.south+"S "+this.west+"W "+this.east+"E"},WPGMZA.LatLngBounds.prototype.toLiteral=function(){return{north:this.north,south:this.south,west:this.west,east:this.east}}}),jQuery(function($){var key,legacyGlobals={marker_pull:"0",marker_array:[],MYMAP:[],infoWindow_poly:[],markerClusterer:[],heatmap:[],WPGM_Path:[],WPGM_Path_Polygon:[],WPGM_PathLine:[],WPGM_PathLineData:[],WPGM_PathData:[],original_iw:null,wpgmza_user_marker:null,wpgmaps_localize_marker_data:[],wpgmaps_localize_polygon_settings:[],wpgmaps_localize_heatmap_settings:[],wpgmaps_localize_polyline_settings:[],wpgmza_cirtcle_data_array:[],wpgmza_rectangle_data_array:[],wpgmzaForceLegacyMarkerClusterer:!1};for(key in legacyGlobals)!function(key){key in window?console.warn("Cannot redefine legacy global "+key):Object.defineProperty(window,key,{get:function(){return console.warn("This property is deprecated and should no longer be used"),legacyGlobals[key]},set:function(value){console.warn("This property is deprecated and should no longer be used"),legacyGlobals[key]=value}})}(key);WPGMZA.legacyGlobals=legacyGlobals,window.InitMap=window.resetLocations=window.searchLocations=window.fillInAddress=window.searchLocationsNear=function(){console.warn("This function is deprecated and should no longer be used")}}),jQuery(function($){WPGMZA.MapListPage=function(){$("body").on("click",".wpgmza_copy_shortcode",function(){var $temp=jQuery("<input>");jQuery('<span id="wpgmza_tmp" style="display:none; width:100%; text-align:center;">');jQuery("body").append($temp),$temp.val(jQuery(this).val()).select(),document.execCommand("copy"),$temp.remove(),WPGMZA.notification("Shortcode Copied")})},WPGMZA.MapListPage.createInstance=function(){return new WPGMZA.MapListPage},$(document).ready(function(event){WPGMZA.getCurrentPage()==WPGMZA.PAGE_MAP_LIST&&(WPGMZA.mapListPage=WPGMZA.MapListPage.createInstance())})}),jQuery(function($){WPGMZA.MapSettings=function(element){var json,self=this,element=element.getAttribute("data-settings");try{json=JSON.parse(element)}catch(e){element=(element=element.replace(/\\%/g,"%")).replace(/\\\\"/g,'\\"');try{json=JSON.parse(element)}catch(e){json={},console.warn("Failed to parse map settings JSON")}}function addSettings(input){if(input)for(var key in input){var value;"other_settings"!=key&&(value=input[key],String(value).match(/^-?\d+$/)&&(value=parseInt(value)),self[key]=value)}}WPGMZA.assertInstanceOf(this,"MapSettings"),addSettings(WPGMZA.settings),addSettings(json),json&&json.other_settings&&addSettings(json.other_settings)},WPGMZA.MapSettings.prototype.toOLViewOptions=function(){var coords,self=this,options={center:ol.proj.fromLonLat([-119.4179,36.7783]),zoom:4};function empty(name){return"object"!=typeof self[name]&&(!self[name]||!self[name].length)}return"string"==typeof this.start_location&&(coords=this.start_location.replace(/^\(|\)$/g,"").split(","),WPGMZA.isLatLngString(this.start_location)?options.center=ol.proj.fromLonLat([parseFloat(coords[1]),parseFloat(coords[0])]):console.warn("Invalid start location")),this.center&&(options.center=ol.proj.fromLonLat([parseFloat(this.center.lng),parseFloat(this.center.lat)])),empty("map_start_lat")||empty("map_start_lng")||(options.center=ol.proj.fromLonLat([parseFloat(this.map_start_lng),parseFloat(this.map_start_lat)])),this.zoom&&(options.zoom=parseInt(this.zoom)),this.start_zoom&&(options.zoom=parseInt(this.start_zoom)),this.map_start_zoom&&(options.zoom=parseInt(this.map_start_zoom)),this.map_min_zoom&&this.map_max_zoom&&(options.minZoom=Math.min(this.map_min_zoom,this.map_max_zoom),options.maxZoom=Math.max(this.map_min_zoom,this.map_max_zoom)),options},WPGMZA.MapSettings.prototype.toGoogleMapsOptions=function(){var self=this,latLngCoords=this.start_location&&this.start_location.length?this.start_location.split(","):[36.7783,-119.4179];function empty(name){return"object"!=typeof self[name]&&(!self[name]||!self[name].length)}function formatCoord(coord){return $.isNumeric(coord)?coord:parseFloat(String(coord).replace(/[\(\)\s]/,""))}var latLngCoords=new google.maps.LatLng(formatCoord(latLngCoords[0]),formatCoord(latLngCoords[1])),zoom=this.start_zoom?parseInt(this.start_zoom):4,options=(!this.start_zoom&&this.zoom&&(zoom=parseInt(this.zoom)),{zoom:zoom=this.map_start_zoom?parseInt(this.map_start_zoom):zoom,center:latLngCoords});function isSettingDisabled(value){return"yes"===value||!!value}switch(empty("center")||(options.center=new google.maps.LatLng({lat:parseFloat(this.center.lat),lng:parseFloat(this.center.lng)})),empty("map_start_lat")||empty("map_start_lng")||(options.center=new google.maps.LatLng({lat:parseFloat(this.map_start_lat),lng:parseFloat(this.map_start_lng)})),this.map_min_zoom&&this.map_max_zoom&&(options.minZoom=Math.min(this.map_min_zoom,this.map_max_zoom),options.maxZoom=Math.max(this.map_min_zoom,this.map_max_zoom)),options.zoomControl=!isSettingDisabled(this.wpgmza_settings_map_zoom),options.panControl=!isSettingDisabled(this.wpgmza_settings_map_pan),options.mapTypeControl=!isSettingDisabled(this.wpgmza_settings_map_type),options.streetViewControl=!isSettingDisabled(this.wpgmza_settings_map_streetview),options.fullscreenControl=!isSettingDisabled(this.wpgmza_settings_map_full_screen_control),options.draggable=!isSettingDisabled(this.wpgmza_settings_map_draggable),options.disableDoubleClickZoom=isSettingDisabled(this.wpgmza_settings_map_clickzoom),isSettingDisabled(this.wpgmza_settings_map_tilt_controls)&&(options.rotateControl=!1,options.tilt=0),this.wpgmza_settings_map_scroll&&(options.scrollwheel=!1),"greedy"==this.wpgmza_force_greedy_gestures||"yes"==this.wpgmza_force_greedy_gestures||1==this.wpgmza_force_greedy_gestures?(options.gestureHandling="greedy",!this.wpgmza_settings_map_scroll&&"scrollwheel"in options&&delete options.scrollwheel):options.gestureHandling="cooperative",parseInt(this.type)){case 2:options.mapTypeId=google.maps.MapTypeId.SATELLITE;break;case 3:options.mapTypeId=google.maps.MapTypeId.HYBRID;break;case 4:options.mapTypeId=google.maps.MapTypeId.TERRAIN;break;default:options.mapTypeId=google.maps.MapTypeId.ROADMAP}return this.wpgmza_theme_data&&this.wpgmza_theme_data.length&&(options.styles=WPGMZA.GoogleMap.parseThemeData(this.wpgmza_theme_data)),options}}),jQuery(function($){WPGMZA.Map=function(element,options){var self=this;if(WPGMZA.assertInstanceOf(this,"Map"),WPGMZA.EventDispatcher.call(this),!(element instanceof HTMLElement||window.elementor))throw new Error("Argument must be a HTMLElement");if(element.hasAttribute("data-map-id")?this.id=element.getAttribute("data-map-id"):this.id=1,!/\d+/.test(this.id))throw new Error("Map ID must be an integer");if(WPGMZA.maps.push(this),this.element=element,this.element.wpgmzaMap=this,$(this.element).addClass("wpgmza-initialized"),this.engineElement=element,this.markers=[],this.polygons=[],this.polylines=[],this.circles=[],this.rectangles=[],this.pointlabels=[],WPGMZA.googleAPIStatus&&"USER_CONSENT_NOT_GIVEN"==WPGMZA.googleAPIStatus.code)return $(element).append($(WPGMZA.api_consent_html)),void $(element).css({height:"auto"});if(this.loadSettings(options),this.loadStyling(),this.shortcodeAttributes={},$(this.element).attr("data-shortcode-attributes"))try{this.shortcodeAttributes=JSON.parse($(this.element).attr("data-shortcode-attributes")),this.shortcodeAttributes.zoom&&(this.settings.map_start_zoom=parseInt(this.shortcodeAttributes.zoom))}catch(e){console.warn("Error parsing shortcode attributes")}this.innerStack=$(this.element).find(".wpgmza-inner-stack"),this.setDimensions(),this.setAlignment(),this.initInternalViewport(),this.markerFilter=WPGMZA.MarkerFilter.createInstance(this),this.on("init",function(event){self.onInit(event)}),this.on("click",function(event){self.onClick(event)}),$(document.body).on("fullscreenchange.wpgmza",function(event){var fullscreen=self.isFullScreen();self.onFullScreenChange(fullscreen)}),WPGMZA.useLegacyGlobals&&(wpgmzaLegacyGlobals.MYMAP[this.id]={map:null,bounds:null,mc:null},wpgmzaLegacyGlobals.MYMAP.init=wpgmzaLegacyGlobals.MYMAP[this.id].init=wpgmzaLegacyGlobals.MYMAP.placeMarkers=wpgmzaLegacyGlobals.MYMAP[this.id].placeMarkers=function(){console.warn("This function is deprecated and should no longer be used")})},WPGMZA.Map.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.Map.prototype.constructor=WPGMZA.Map,WPGMZA.Map.nightTimeThemeData=[{elementType:"geometry",stylers:[{color:"#242f3e"}]},{elementType:"labels.text.fill",stylers:[{color:"#746855"}]},{elementType:"labels.text.stroke",stylers:[{color:"#242f3e"}]},{featureType:"administrative.locality",elementType:"labels.text.fill",stylers:[{color:"#d59563"}]},{featureType:"landscape",elementType:"geometry.fill",stylers:[{color:"#575663"}]},{featureType:"poi",elementType:"labels.text.fill",stylers:[{color:"#d59563"}]},{featureType:"poi.park",elementType:"geometry",stylers:[{color:"#263c3f"}]},{featureType:"poi.park",elementType:"labels.text.fill",stylers:[{color:"#6b9a76"}]},{featureType:"road",elementType:"geometry",stylers:[{color:"#38414e"}]},{featureType:"road",elementType:"geometry.stroke",stylers:[{color:"#212a37"}]},{featureType:"road",elementType:"labels.text.fill",stylers:[{color:"#9ca5b3"}]},{featureType:"road.highway",elementType:"geometry",stylers:[{color:"#746855"}]},{featureType:"road.highway",elementType:"geometry.fill",stylers:[{color:"#80823e"}]},{featureType:"road.highway",elementType:"geometry.stroke",stylers:[{color:"#1f2835"}]},{featureType:"road.highway",elementType:"labels.text.fill",stylers:[{color:"#f3d19c"}]},{featureType:"transit",elementType:"geometry",stylers:[{color:"#2f3948"}]},{featureType:"transit.station",elementType:"labels.text.fill",stylers:[{color:"#d59563"}]},{featureType:"water",elementType:"geometry",stylers:[{color:"#17263c"}]},{featureType:"water",elementType:"geometry.fill",stylers:[{color:"#1b737a"}]},{featureType:"water",elementType:"labels.text.fill",stylers:[{color:"#515c6d"}]},{featureType:"water",elementType:"labels.text.stroke",stylers:[{color:"#17263c"}]}],WPGMZA.Map.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProMap:WPGMZA.GoogleMap:WPGMZA.isProVersion()?WPGMZA.OLProMap:WPGMZA.OLMap},WPGMZA.Map.createInstance=function(element,options){return new(WPGMZA.Map.getConstructor())(element,options)},Object.defineProperty(WPGMZA.Map.prototype,"markersPlaced",{get:function(){return this._markersPlaced},set:function(value){throw new Error("Value is read only")}}),Object.defineProperty(WPGMZA.Map.prototype,"lat",{get:function(){return this.getCenter().lat},set:function(value){var center=this.getCenter();center.lat=value,this.setCenter(center)}}),Object.defineProperty(WPGMZA.Map.prototype,"lng",{get:function(){return this.getCenter().lng},set:function(value){var center=this.getCenter();center.lng=value,this.setCenter(center)}}),Object.defineProperty(WPGMZA.Map.prototype,"zoom",{get:function(){return this.getZoom()},set:function(value){this.setZoom(value)}}),WPGMZA.Map.prototype.onInit=function(event){this.initPreloader(),0<this.innerStack.length&&$(this.element).append(this.innerStack),WPGMZA.getCurrentPage()!=WPGMZA.PAGE_MAP_EDIT&&this.initStoreLocator(),"autoFetchFeatures"in this.settings&&!1===this.settings.autoFetchFeatures||this.fetchFeatures()},WPGMZA.Map.prototype.initPreloader=function(){this.preloader=$(WPGMZA.preloaderHTML),$(this.preloader).hide(),$(this.element).append(this.preloader)},WPGMZA.Map.prototype.showPreloader=function(show){show?$(this.preloader).show():$(this.preloader).hide()},WPGMZA.Map.prototype.loadSettings=function(options){var settings=new WPGMZA.MapSettings(this.element);settings.other_settings;if(delete settings.other_settings,options)for(var key in options)settings[key]=options[key];this.settings=settings},WPGMZA.Map.prototype.loadStyling=function(){if(!WPGMZA.InternalEngine.isLegacy()){if(WPGMZA.stylingSettings&&WPGMZA.stylingSettings instanceof Object&&0<Object.keys(WPGMZA.stylingSettings).length)for(var name in WPGMZA.stylingSettings){var value;-1===name.indexOf("--")||(value=WPGMZA.stylingSettings[name])&&$(this.element).css(name,value)}var tileFilter;this.settings&&this.settings.wpgmza_ol_tile_filter&&((tileFilter=this.settings.wpgmza_ol_tile_filter.trim())&&$(this.element).css("--wpgmza-ol-tile-filter",tileFilter))}},WPGMZA.Map.prototype.initInternalViewport=function(){"1"!=WPGMZA.is_admin&&(this.internalViewport=WPGMZA.InternalViewport.createInstance(this))},WPGMZA.Map.prototype.initStoreLocator=function(){var storeLocatorElement=$(".wpgmza_sl_main_div,.wpgmza-store-locator");storeLocatorElement.length&&(this.storeLocator=WPGMZA.StoreLocator.createInstance(this,storeLocatorElement[0]))},WPGMZA.Map.prototype.getFeatureArrays=function(){var arrays=WPGMZA.Map.prototype.getFeatureArrays.call(this);return arrays.heatmaps=this.heatmaps,arrays.imageoverlays=this.imageoverlays,arrays},WPGMZA.Map.prototype.setOptions=function(options){for(var name in options)this.settings[name]=options[name]},WPGMZA.Map.prototype.getRESTParameters=function(options){var defaults={};return options&&options.filter||(defaults.filter=JSON.stringify(this.markerFilter.getFilteringParameters())),$.extend(!0,defaults,options)},WPGMZA.Map.prototype.fetchFeaturesViaREST=function(){var data,offset,limit,self=this,filter=this.markerFilter.getFilteringParameters();"1"==WPGMZA.is_admin&&(filter.includeUnapproved=!0,filter.excludeIntegrated=!0),this.shortcodeAttributes.acf_post_id&&(filter.acfPostID=this.shortcodeAttributes.acf_post_id),this.showPreloader(!0),this.fetchFeaturesXhr&&this.fetchFeaturesXhr.abort(),WPGMZA.settings.fetchMarkersBatchSize&&WPGMZA.settings.enable_batch_loading?(offset=0,limit=parseInt(WPGMZA.settings.fetchMarkersBatchSize),function fetchNextBatch(){filter.offset=offset,filter.limit=limit,data=self.getRESTParameters({filter:JSON.stringify(filter)}),self.fetchFeaturesXhr=WPGMZA.restAPI.call("/markers/",{useCompressedPathVariable:!0,data:data,success:function(result,status,xhr){result.length?(self.onMarkersFetched(result,!0),offset+=limit,fetchNextBatch()):(self.onMarkersFetched(result),data.exclude="markers",WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:data,success:function(result,status,xhr){self.onFeaturesFetched(result)}}))}})}()):(data=this.getRESTParameters({filter:JSON.stringify(filter)}),this.fetchFeaturesXhr=WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:data,success:function(result,status,xhr){self.onFeaturesFetched(result)}}))},WPGMZA.Map.prototype.fetchFeaturesViaXML=function(){var self=this,urls=[WPGMZA.markerXMLPathURL+this.id+"markers.xml"];function fetchFeaturesExcludingMarkersViaREST(){var filter={map_id:this.id,mashup_ids:this.mashupIDs},filter={filter:JSON.stringify(filter),exclude:"markers"};WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:filter,success:function(result,status,xhr){self.onFeaturesFetched(result)}})}if(this.mashupIDs&&this.mashupIDs.forEach(function(id){urls.push(WPGMZA.markerXMLPathURL+id+"markers.xml")}),urls=urls.filter(function(item,index){return urls.indexOf(item)==index}),window.Worker&&window.Blob&&window.URL&&WPGMZA.settings.enable_asynchronous_xml_parsing){var source=WPGMZA.loadXMLAsWebWorker.toString().replace(/function\(\)\s*{([\s\S]+)}/,"$1"),source=new Blob([source],{type:"text/javascript"}),source=new Worker(URL.createObjectURL(source));source.onmessage=function(event){self.onMarkersFetched(event.data),fetchFeaturesExcludingMarkersViaREST()},source.postMessage({command:"load",protocol:window.location.protocol,urls:urls})}else for(var filesLoaded=0,converter=new WPGMZA.XMLCacheConverter,converted=[],i=0;i<urls.length;i++)$.ajax(urls[i],{success:function(response,status,xhr){converted=converted.concat(converter.convert(response)),++filesLoaded==urls.length&&(self.onMarkersFetched(converted),fetchFeaturesExcludingMarkersViaREST())}})},WPGMZA.Map.prototype.fetchFeatures=function(){WPGMZA.settings.wpgmza_settings_marker_pull!=WPGMZA.MARKER_PULL_XML||"1"==WPGMZA.is_admin?this.fetchFeaturesViaREST():this.fetchFeaturesViaXML()},WPGMZA.Map.prototype.onFeaturesFetched=function(data){for(var type in data.markers&&this.onMarkersFetched(data.markers),data)if("markers"!=type)for(var module=type.substr(0,1).toUpperCase()+type.substr(1).replace(/s$/,""),i=0;i<data[type].length;i++){var instance=WPGMZA[module].createInstance(data[type][i]);this["add"+module](instance)}},WPGMZA.Map.prototype.onMarkersFetched=function(data,expectMoreBatches){for(var self=this,startFiltered=this.shortcodeAttributes.cat&&this.shortcodeAttributes.cat.length,i=0;i<data.length;i++){var obj=data[i],marker=WPGMZA.Marker.createInstance(obj);startFiltered&&(marker.isFiltered=!0,marker.setVisible(!1)),this.addMarker(marker)}if(!expectMoreBatches){this.showPreloader(!1);var triggerEvent=function(){self._markersPlaced=!0,self.trigger("markersplaced"),self.off("filteringcomplete",triggerEvent)};if(this.shortcodeAttributes.cat){for(var categories=this.shortcodeAttributes.cat.split(","),select=$("select[mid='"+this.id+"'][name='wpgmza_filter_select']"),i=0;i<categories.length;i++)$("input[type='checkbox'][mid='"+this.id+"'][value='"+categories[i]+"']").prop("checked",!0),select.val(categories[i]);this.on("filteringcomplete",triggerEvent),this.markerFilter.update({categories:categories})}else triggerEvent();if(this.shortcodeAttributes.markers){for(var arr=this.shortcodeAttributes.markers.split(","),markers=[],i=0;i<arr.length;i++){var id=(id=arr[i]).replace(" ",""),marker=this.getMarkerByID(id);markers.push(marker)}this.fitMapBoundsToMarkers(markers)}}},WPGMZA.Map.prototype.fetchFeaturesViaXML=function(){var self=this,urls=[WPGMZA.markerXMLPathURL+this.id+"markers.xml"];function fetchFeaturesExcludingMarkersViaREST(){var filter={map_id:this.id,mashup_ids:this.mashupIDs},filter={filter:JSON.stringify(filter),exclude:"markers"};WPGMZA.restAPI.call("/features/",{useCompressedPathVariable:!0,data:filter,success:function(result,status,xhr){self.onFeaturesFetched(result)}})}if(this.mashupIDs&&this.mashupIDs.forEach(function(id){urls.push(WPGMZA.markerXMLPathURL+id+"markers.xml")}),urls=urls.filter(function(item,index){return urls.indexOf(item)==index}),window.Worker&&window.Blob&&window.URL&&WPGMZA.settings.enable_asynchronous_xml_parsing){var source=WPGMZA.loadXMLAsWebWorker.toString().replace(/function\(\)\s*{([\s\S]+)}/,"$1"),source=new Blob([source],{type:"text/javascript"}),source=new Worker(URL.createObjectURL(source));source.onmessage=function(event){self.onMarkersFetched(event.data),fetchFeaturesExcludingMarkersViaREST()},source.postMessage({command:"load",protocol:window.location.protocol,urls:urls})}else for(var filesLoaded=0,converter=new WPGMZA.XMLCacheConverter,converted=[],i=0;i<urls.length;i++)$.ajax(urls[i],{success:function(response,status,xhr){converted=converted.concat(converter.convert(response)),++filesLoaded==urls.length&&(self.onMarkersFetched(converted),fetchFeaturesExcludingMarkersViaREST())}})},WPGMZA.Map.prototype.fetchFeatures=function(){WPGMZA.settings.wpgmza_settings_marker_pull!=WPGMZA.MARKER_PULL_XML||"1"==WPGMZA.is_admin?this.fetchFeaturesViaREST():this.fetchFeaturesViaXML()},WPGMZA.Map.prototype.onFeaturesFetched=function(data){for(var type in data.markers&&this.onMarkersFetched(data.markers),data)if("markers"!=type)for(var module=type.substr(0,1).toUpperCase()+type.substr(1).replace(/s$/,""),i=0;i<data[type].length;i++){var instance=WPGMZA[module].createInstance(data[type][i]);this["add"+module](instance)}},WPGMZA.Map.prototype.onMarkersFetched=function(data,expectMoreBatches){for(var self=this,startFiltered=this.shortcodeAttributes.cat&&this.shortcodeAttributes.cat.length,i=0;i<data.length;i++){var obj=data[i],marker=WPGMZA.Marker.createInstance(obj);startFiltered&&(marker.isFiltered=!0,marker.setVisible(!1)),this.addMarker(marker)}if(!expectMoreBatches){this.showPreloader(!1);var triggerEvent=function(){self._markersPlaced=!0,self.trigger("markersplaced"),self.off("filteringcomplete",triggerEvent)};if(this.shortcodeAttributes.cat){for(var categories=this.shortcodeAttributes.cat.split(","),select=$("select[mid='"+this.id+"'][name='wpgmza_filter_select']"),i=0;i<categories.length;i++)$("input[type='checkbox'][mid='"+this.id+"'][value='"+categories[i]+"']").prop("checked",!0),select.val(categories[i]);this.on("filteringcomplete",triggerEvent),this.markerFilter.update({categories:categories})}else triggerEvent();if(this.shortcodeAttributes.markers){for(var arr=this.shortcodeAttributes.markers.split(","),markers=[],i=0;i<arr.length;i++){var id=(id=arr[i]).replace(" ",""),marker=this.getMarkerByID(id);markers.push(marker)}this.fitMapBoundsToMarkers(markers)}}};Math.PI;function deg2rad(deg){return deg*(Math.PI/180)}WPGMZA.Map.getGeographicDistance=function(lat1,lon1,lat2,lon2){var dLat=deg2rad(lat2-lat1),lon2=deg2rad(lon2-lon1),lon1=Math.sin(dLat/2)*Math.sin(dLat/2)+Math.cos(deg2rad(lat1))*Math.cos(deg2rad(lat2))*Math.sin(lon2/2)*Math.sin(lon2/2);return 6371*(2*Math.atan2(Math.sqrt(lon1),Math.sqrt(1-lon1)))},WPGMZA.Map.prototype.setCenter=function(latLng){if(!("lat"in latLng&&"lng"in latLng))throw new Error("Argument is not an object with lat and lng")},WPGMZA.Map.prototype.setDimensions=function(width,height){0==arguments.length&&(width=this.settings.map_width||"100",this.settings.map_width_type?width+=this.settings.map_width_type.replace("\\",""):width+="%",height=this.settings.map_height||"400",this.settings.map_height_type?height+=this.settings.map_height_type.replace("\\",""):height+="px"),$(this.engineElement).css({width:width,height:height})},WPGMZA.Map.prototype.setAlignment=function(){switch(parseInt(this.settings.wpgmza_map_align)){case 1:case 2:$(this.element).addClass("wpgmza-auto-left");break;case 3:$(this.element).addClass("wpgmza-auto-right")}},WPGMZA.Map.prototype.addMarker=function(marker){if(!(marker instanceof WPGMZA.Marker))throw new Error("Argument must be an instance of WPGMZA.Marker");marker.map=this,(marker.parent=this).markers.push(marker),this.dispatchEvent({type:"markeradded",marker:marker}),marker.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removeMarker=function(marker){if(!(marker instanceof WPGMZA.Marker))throw new Error("Argument must be an instance of WPGMZA.Marker");if(marker.map!==this)throw new Error("Wrong map error");marker.infoWindow&&marker.infoWindow.close(),marker.map=null,marker.parent=null;var index=this.markers.indexOf(marker);if(-1==index)throw new Error("Marker not found in marker array");this.markers.splice(index,1),this.dispatchEvent({type:"markerremoved",marker:marker}),marker.dispatchEvent({type:"removed"})},WPGMZA.Map.prototype.removeAllMarkers=function(options){for(var i=this.markers.length-1;0<=i;i--)this.removeMarker(this.markers[i])},WPGMZA.Map.prototype.getMarkerByID=function(id){for(var i=0;i<this.markers.length;i++)if(this.markers[i].id==id)return this.markers[i];return null},WPGMZA.Map.prototype.getMarkerByTitle=function(title){if("string"==typeof title){for(var i=0;i<this.markers.length;i++)if(this.markers[i].title==title)return this.markers[i]}else{if(!(title instanceof RegExp))throw new Error("Invalid argument");for(i=0;i<this.markers.length;i++)if(title.test(this.markers[i].title))return this.markers[i]}return null},WPGMZA.Map.prototype.removeMarkerByID=function(id){id=this.getMarkerByID(id);id&&this.removeMarker(id)},WPGMZA.Map.prototype.addPolygon=function(polygon){if(!(polygon instanceof WPGMZA.Polygon))throw new Error("Argument must be an instance of WPGMZA.Polygon");(polygon.map=this).polygons.push(polygon),this.dispatchEvent({type:"polygonadded",polygon:polygon}),polygon.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removePolygon=function(polygon){if(!(polygon instanceof WPGMZA.Polygon))throw new Error("Argument must be an instance of WPGMZA.Polygon");if(polygon.map!==this)throw new Error("Wrong map error");polygon.map=null,this.polygons.splice(this.polygons.indexOf(polygon),1),this.dispatchEvent({type:"polygonremoved",polygon:polygon})},WPGMZA.Map.prototype.getPolygonByID=function(id){for(var i=0;i<this.polygons.length;i++)if(this.polygons[i].id==id)return this.polygons[i];return null},WPGMZA.Map.prototype.removePolygonByID=function(id){id=this.getPolygonByID(id);id&&this.removePolygon(id)},WPGMZA.Map.prototype.getPolylineByID=function(id){for(var i=0;i<this.polylines.length;i++)if(this.polylines[i].id==id)return this.polylines[i];return null},WPGMZA.Map.prototype.addPolyline=function(polyline){if(!(polyline instanceof WPGMZA.Polyline))throw new Error("Argument must be an instance of WPGMZA.Polyline");(polyline.map=this).polylines.push(polyline),this.dispatchEvent({type:"polylineadded",polyline:polyline}),polyline.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removePolyline=function(polyline){if(!(polyline instanceof WPGMZA.Polyline))throw new Error("Argument must be an instance of WPGMZA.Polyline");if(polyline.map!==this)throw new Error("Wrong map error");polyline.map=null,this.polylines.splice(this.polylines.indexOf(polyline),1),this.dispatchEvent({type:"polylineremoved",polyline:polyline})},WPGMZA.Map.prototype.getPolylineByID=function(id){for(var i=0;i<this.polylines.length;i++)if(this.polylines[i].id==id)return this.polylines[i];return null},WPGMZA.Map.prototype.removePolylineByID=function(id){id=this.getPolylineByID(id);id&&this.removePolyline(id)},WPGMZA.Map.prototype.addCircle=function(circle){if(!(circle instanceof WPGMZA.Circle))throw new Error("Argument must be an instance of WPGMZA.Circle");(circle.map=this).circles.push(circle),this.dispatchEvent({type:"circleadded",circle:circle}),circle.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removeCircle=function(circle){if(!(circle instanceof WPGMZA.Circle))throw new Error("Argument must be an instance of WPGMZA.Circle");if(circle.map!==this)throw new Error("Wrong map error");circle.map=null,this.circles.splice(this.circles.indexOf(circle),1),this.dispatchEvent({type:"circleremoved",circle:circle})},WPGMZA.Map.prototype.getCircleByID=function(id){for(var i=0;i<this.circles.length;i++)if(this.circles[i].id==id)return this.circles[i];return null},WPGMZA.Map.prototype.removeCircleByID=function(id){id=this.getCircleByID(id);id&&this.removeCircle(id)},WPGMZA.Map.prototype.addRectangle=function(rectangle){if(!(rectangle instanceof WPGMZA.Rectangle))throw new Error("Argument must be an instance of WPGMZA.Rectangle");(rectangle.map=this).rectangles.push(rectangle),this.dispatchEvent({type:"rectangleadded",rectangle:rectangle}),rectangle.dispatchEvent({type:"added"})},WPGMZA.Map.prototype.removeRectangle=function(rectangle){if(!(rectangle instanceof WPGMZA.Rectangle))throw new Error("Argument must be an instance of WPGMZA.Rectangle");if(rectangle.map!==this)throw new Error("Wrong map error");rectangle.map=null,this.rectangles.splice(this.rectangles.indexOf(rectangle),1),this.dispatchEvent({type:"rectangleremoved",rectangle:rectangle})},WPGMZA.Map.prototype.getRectangleByID=function(id){for(var i=0;i<this.rectangles.length;i++)if(this.rectangles[i].id==id)return this.rectangles[i];return null},WPGMZA.Map.prototype.removeRectangleByID=function(id){id=this.getRectangleByID(id);id&&this.removeRectangle(id)},WPGMZA.Map.prototype.addPointlabel=function(pointlabel){if(!(pointlabel instanceof WPGMZA.Pointlabel))throw new Error("Argument must be an instance of WPGMZA.Pointlabel");(pointlabel.map=this).pointlabels.push(pointlabel),this.dispatchEvent({type:"pointlabeladded",pointlabel:pointlabel})},WPGMZA.Map.prototype.removePointlabel=function(pointlabel){if(!(pointlabel instanceof WPGMZA.Pointlabel))throw new Error("Argument must be an instance of WPGMZA.Pointlabel");if(pointlabel.map!==this)throw new Error("Wrong map error");pointlabel.map=null,this.pointlabels.splice(this.pointlabels.indexOf(pointlabel),1),this.dispatchEvent({type:"pointlabelremoved",pointlabel:pointlabel})},WPGMZA.Map.prototype.getPointlabelByID=function(id){for(var i=0;i<this.pointlabels.length;i++)if(this.pointlabels[i].id==id)return this.pointlabels[i];return null},WPGMZA.Map.prototype.removePointlabelByID=function(id){id=this.getPointlabelByID(id);id&&this.removePointlabel(id)},WPGMZA.Map.prototype.resetBounds=function(){var latlng=new WPGMZA.LatLng(this.settings.map_start_lat,this.settings.map_start_lng);this.panTo(latlng),this.setZoom(this.settings.map_start_zoom)},WPGMZA.Map.prototype.nudge=function(x,y){x=this.nudgeLatLng(this.getCenter(),x,y);this.setCenter(x)},WPGMZA.Map.prototype.nudgeLatLng=function(latLng,x,y){latLng=this.latLngToPixels(latLng);if(latLng.x+=parseFloat(x),latLng.y+=parseFloat(y),isNaN(latLng.x)||isNaN(latLng.y))throw new Error("Invalid coordinates supplied");return this.pixelsToLatLng(latLng)},WPGMZA.Map.prototype.animateNudge=function(x,y,origin,milliseconds){if(origin){if(!(origin instanceof WPGMZA.LatLng))throw new Error("Origin must be an instance of WPGMZA.LatLng")}else origin=this.getCenter();origin=this.nudgeLatLng(origin,x,y),milliseconds=milliseconds||WPGMZA.getScrollAnimationDuration(),$(this).animate({lat:origin.lat,lng:origin.lng},milliseconds)},WPGMZA.Map.prototype.onWindowResize=function(event){},WPGMZA.Map.prototype.onElementResized=function(event){},WPGMZA.Map.prototype.onBoundsChanged=function(event){this.trigger("boundschanged"),this.trigger("bounds_changed")},WPGMZA.Map.prototype.onIdle=function(event){this.trigger("idle")},WPGMZA.Map.prototype.onClick=function(event){},WPGMZA.Map.prototype.onFullScreenChange=function(fullscreen){this.trigger("fullscreenchange.map")},WPGMZA.Map.prototype.hasVisibleMarkers=function(){for(var marker,length=this.markers.length,i=0;i<length;i++)if((marker=this.markers[i]).isFilterable&&marker.getVisible())return!0;return!1},WPGMZA.Map.prototype.isFullScreen=function(){return!(!WPGMZA.isFullScreen()||parseInt(window.screen.height)!==parseInt(this.element.offsetHeight))},WPGMZA.Map.prototype.closeAllInfoWindows=function(){this.markers.forEach(function(marker){marker.infoWindow&&marker.infoWindow.close()})},WPGMZA.Map.prototype.openStreetView=function(options){},WPGMZA.Map.prototype.closeStreetView=function(options){},$(document).ready(function(event){var invisibleMaps;WPGMZA.visibilityWorkaroundIntervalID||(invisibleMaps=jQuery(".wpgmza_map:hidden"),WPGMZA.visibilityWorkaroundIntervalID=setInterval(function(){jQuery(invisibleMaps).each(function(index,el){var id;jQuery(el).is(":visible")&&(id=jQuery(el).attr("data-map-id"),WPGMZA.getMapByID(id).onElementResized(),invisibleMaps.splice(invisibleMaps.toArray().indexOf(el),1))})},1e3))})}),jQuery(function($){WPGMZA.MapsEngineDialog=function(element){var self=this;this.element=element,window.wpgmzaUnbindSaveReminder&&window.wpgmzaUnbindSaveReminder(),$(this.element).data("installer-link")?WPGMZA.initInstallerRedirect($(this.element).data("installer-link")):($(element).remodal().open(),$(element).show(),$(element).find("input:radio").on("change",function(event){$("#wpgmza-confirm-engine").prop("disabled",!1),$("#wpgmza-confirm-engine").click()}),$("#wpgmza-confirm-engine").on("click",function(event){self.onButtonClicked(event)}))},WPGMZA.MapsEngineDialog.prototype.onButtonClicked=function(event){$(event.target).prop("disabled",!0),$.ajax(WPGMZA.ajaxurl,{method:"POST",data:{action:"wpgmza_maps_engine_dialog_set_engine",engine:$("[name='wpgmza_maps_engine']:checked").val(),nonce:$("#wpgmza-maps-engine-dialog").attr("data-ajax-nonce")},success:function(response,status,xhr){window.location.reload()}})},$(document).ready(function(event){var element=$("#wpgmza-maps-engine-dialog");!element.length||WPGMZA.settings.wpgmza_maps_engine_dialog_done||WPGMZA.settings.wpgmza_google_maps_api_key&&WPGMZA.settings.wpgmza_google_maps_api_key.length||WPGMZA.ignoreInstallerRedirect||(WPGMZA.mapsEngineDialog=new WPGMZA.MapsEngineDialog(element))})}),jQuery(function($){WPGMZA.MarkerFilter=function(map){WPGMZA.EventDispatcher.call(this),this.map=map},WPGMZA.MarkerFilter.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.MarkerFilter.prototype.constructor=WPGMZA.MarkerFilter,WPGMZA.MarkerFilter.createInstance=function(map){return new WPGMZA.MarkerFilter(map)},WPGMZA.MarkerFilter.prototype.getFilteringParameters=function(){var params={map_id:this.map.id};return params=this.map.storeLocator?$.extend(params,this.map.storeLocator.getFilteringParameters()):params},WPGMZA.MarkerFilter.prototype.update=function(params,source){var self=this;function dispatchEvent(result){var event=new WPGMZA.Event("filteringcomplete");event.map=self.map,event.source=source,event.filteredMarkers=result,event.filteringParams=params,self.onFilteringComplete(event),self.trigger(event),self.map.trigger(event)}this.updateTimeoutID||(params=params||{},this.xhr&&(this.xhr.abort(),delete this.xhr),this.updateTimeoutID=setTimeout(function(){if((params=$.extend(self.getFilteringParameters(),params)).center instanceof WPGMZA.LatLng&&(params.center=params.center.toLatLngLiteral()),params.hideAll)return dispatchEvent([]),void delete self.updateTimeoutID;self.map.showPreloader(!0),self.xhr=WPGMZA.restAPI.call("/markers",{data:{fields:["id"],filter:JSON.stringify(params)},success:function(result,status,xhr){self.map.showPreloader(!1),dispatchEvent(result)},useCompressedPathVariable:!0}),delete self.updateTimeoutID},0))},WPGMZA.MarkerFilter.prototype.onFilteringComplete=function(event){var map=[];event.filteredMarkers.forEach(function(data){map[data.id]=!0}),this.map.markers.forEach(function(marker){var allowByFilter;marker.isFilterable&&(allowByFilter=!!map[marker.id],marker.isFiltered=!allowByFilter,marker.setVisible(allowByFilter))})}}),jQuery(function($){WPGMZA.Marker=function(row){var self=this;this._offset={x:0,y:0},WPGMZA.assertInstanceOf(this,"Marker"),this.lat="36.778261",this.lng="-119.4179323999",this.address="California",this.title=null,this.description="",this.link="",this.icon="",this.approved=1,this.pic=null,this.isFilterable=!0,this.disableInfoWindow=!1,WPGMZA.Feature.apply(this,arguments),row&&row.heatmap||(row&&this.on("init",function(event){row.position&&this.setPosition(row.position),row.map&&row.map.addMarker(this)}),this.addEventListener("added",function(event){self.onAdded(event)}),this.handleLegacyGlobals(row))},WPGMZA.Marker.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Marker.prototype.constructor=WPGMZA.Marker,WPGMZA.Marker.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProMarker:WPGMZA.GoogleMarker:WPGMZA.isProVersion()?WPGMZA.OLProMarker:WPGMZA.OLMarker},WPGMZA.Marker.createInstance=function(row){return new(WPGMZA.Marker.getConstructor())(row)},WPGMZA.Marker.ANIMATION_NONE="0",WPGMZA.Marker.ANIMATION_BOUNCE="1",WPGMZA.Marker.ANIMATION_DROP="2",Object.defineProperty(WPGMZA.Marker.prototype,"offsetX",{get:function(){return this._offset.x},set:function(value){this._offset.x=value,this.updateOffset()}}),Object.defineProperty(WPGMZA.Marker.prototype,"offsetY",{get:function(){return this._offset.y},set:function(value){this._offset.y=value,this.updateOffset()}}),WPGMZA.Marker.prototype.onAdded=function(event){var self=this;this.addEventListener("click",function(event){self.onClick(event)}),this.addEventListener("mouseover",function(event){self.onMouseOver(event)}),this.addEventListener("select",function(event){self.onSelect(event)}),this.map.settings.marker==this.id&&self.trigger("select"),"1"==this.infoopen&&(this._osDisableAutoPan=!0,this.openInfoWindow(!0))},WPGMZA.Marker.prototype.handleLegacyGlobals=function(row){var m;WPGMZA.settings.useLegacyGlobals&&this.map_id&&this.id&&(WPGMZA.pro_version&&(m=WPGMZA.pro_version.match(/\d+/))&&m[0]<=7||(WPGMZA.legacyGlobals.marker_array[this.map_id]||(WPGMZA.legacyGlobals.marker_array[this.map_id]=[]),WPGMZA.legacyGlobals.marker_array[this.map_id][this.id]=this,WPGMZA.legacyGlobals.wpgmaps_localize_marker_data[this.map_id]||(WPGMZA.legacyGlobals.wpgmaps_localize_marker_data[this.map_id]=[]),m=$.extend({marker_id:this.id},row),WPGMZA.legacyGlobals.wpgmaps_localize_marker_data[this.map_id][this.id]=m))},WPGMZA.Marker.prototype.initInfoWindow=function(){this.infoWindow||(this.infoWindow=WPGMZA.InfoWindow.createInstance())},WPGMZA.Marker.prototype.openInfoWindow=function(autoOpen){this.map?(autoOpen||(this.map.lastInteractedMarker&&this.map.lastInteractedMarker.infoWindow.close(),this.map.lastInteractedMarker=this),this.initInfoWindow(),this.infoWindow.open(this.map,this)):console.warn("Cannot open infowindow for marker with no map")},WPGMZA.Marker.prototype.onClick=function(event){},WPGMZA.Marker.prototype.onSelect=function(event){this.openInfoWindow()},WPGMZA.Marker.prototype.onMouseOver=function(event){WPGMZA.settings.wpgmza_settings_map_open_marker_by==WPGMZA.InfoWindow.OPEN_BY_HOVER&&this.openInfoWindow()},WPGMZA.Marker.prototype.getIcon=function(){function stripProtocol(url){return"string"!=typeof url?url:url.replace(/^http(s?):/,"")}return WPGMZA.defaultMarkerIcon?stripProtocol(WPGMZA.defaultMarkerIcon):stripProtocol(WPGMZA.settings.default_marker_icon)},WPGMZA.Marker.prototype.getPosition=function(){return new WPGMZA.LatLng({lat:parseFloat(this.lat),lng:parseFloat(this.lng)})},WPGMZA.Marker.prototype.setPosition=function(latLng){latLng instanceof WPGMZA.LatLng?(this.lat=latLng.lat,this.lng=latLng.lng):(this.lat=parseFloat(latLng.lat),this.lng=parseFloat(latLng.lng))},WPGMZA.Marker.prototype.setOffset=function(x,y){this._offset.x=x,this._offset.y=y,this.updateOffset()},WPGMZA.Marker.prototype.updateOffset=function(){},WPGMZA.Marker.prototype.getAnimation=function(){return this.anim},WPGMZA.Marker.prototype.setAnimation=function(animation){},WPGMZA.Marker.prototype.getVisible=function(){},WPGMZA.Marker.prototype.setVisible=function(visible){!visible&&this.infoWindow&&this.infoWindow.close()},WPGMZA.Marker.prototype.getMap=function(){return this.map},WPGMZA.Marker.prototype.setMap=function(map){map?map.addMarker(this):this.map&&this.map.removeMarker(this),this.map=map},WPGMZA.Marker.prototype.getDraggable=function(){},WPGMZA.Marker.prototype.setDraggable=function(draggable){},WPGMZA.Marker.prototype.setOptions=function(options){},WPGMZA.Marker.prototype.setOpacity=function(opacity){},WPGMZA.Marker.prototype.panIntoView=function(){if(!this.map)throw new Error("Marker hasn't been added to a map");this.map.setCenter(this.getPosition())},WPGMZA.Marker.prototype.toJSON=function(){var result=WPGMZA.Feature.prototype.toJSON.call(this),position=this.getPosition();return $.extend(result,{lat:position.lat,lng:position.lng,address:this.address,title:this.title,description:this.description,link:this.link,icon:this.icon,pic:this.pic,approved:this.approved}),result}}),jQuery(function($){WPGMZA.ModernStoreLocatorCircle=function(map_id,settings){var map=WPGMZA.isProVersion()?this.map=WPGMZA.getMapByID(map_id):this.map=WPGMZA.maps[0];this.map_id=map_id,this.mapElement=map.element,this.mapSize={width:$(this.mapElement).width(),height:$(this.mapElement).height()},this.initCanvasLayer(),this.settings={center:new WPGMZA.LatLng(0,0),radius:1,color:"#ff0000",shadowColor:"white",shadowBlur:4,centerRingRadius:10,centerRingLineWidth:3,numInnerRings:9,innerRingLineWidth:1,innerRingFade:!0,numOuterRings:7,ringLineWidth:1,mainRingLineWidth:2,numSpokes:6,spokesStartAngle:Math.PI/2,numRadiusLabels:6,radiusLabelsStartAngle:Math.PI/2,radiusLabelFont:"13px sans-serif",visible:!1},settings&&this.setOptions(settings)},WPGMZA.ModernStoreLocatorCircle.createInstance=function(map,settings){return new("google-maps"==WPGMZA.settings.engine?WPGMZA.GoogleModernStoreLocatorCircle:WPGMZA.OLModernStoreLocatorCircle)(map,settings)},WPGMZA.ModernStoreLocatorCircle.prototype.initCanvasLayer=function(){},WPGMZA.ModernStoreLocatorCircle.prototype.onResize=function(event){this.draw()},WPGMZA.ModernStoreLocatorCircle.prototype.onUpdate=function(event){this.draw()},WPGMZA.ModernStoreLocatorCircle.prototype.setOptions=function(options){for(var name in options){var functionName="set"+name.substr(0,1).toUpperCase()+name.substr(1);"function"==typeof this[functionName]?this[functionName](options[name]):this.settings[name]=options[name]}},WPGMZA.ModernStoreLocatorCircle.prototype.getResolutionScale=function(){return window.devicePixelRatio||1},WPGMZA.ModernStoreLocatorCircle.prototype.getCenter=function(){return this.getPosition()},WPGMZA.ModernStoreLocatorCircle.prototype.setCenter=function(value){this.setPosition(value)},WPGMZA.ModernStoreLocatorCircle.prototype.getPosition=function(){return this.settings.center},WPGMZA.ModernStoreLocatorCircle.prototype.setPosition=function(position){this.settings.center=position},WPGMZA.ModernStoreLocatorCircle.prototype.getRadius=function(){return this.settings.radius},WPGMZA.ModernStoreLocatorCircle.prototype.setRadius=function(radius){if(isNaN(radius))throw new Error("Invalid radius");this.settings.radius=radius},WPGMZA.ModernStoreLocatorCircle.prototype.getVisible=function(){return this.settings.visible},WPGMZA.ModernStoreLocatorCircle.prototype.setVisible=function(visible){this.settings.visible=visible},WPGMZA.ModernStoreLocatorCircle.prototype.getTransformedRadius=function(km){throw new Error("Abstract function called")},WPGMZA.ModernStoreLocatorCircle.prototype.getContext=function(type){throw new Error("Abstract function called")},WPGMZA.ModernStoreLocatorCircle.prototype.getCanvasDimensions=function(){throw new Error("Abstract function called")},WPGMZA.ModernStoreLocatorCircle.prototype.validateSettings=function(){WPGMZA.isHexColorString(this.settings.color)||(this.settings.color="#ff0000")},WPGMZA.ModernStoreLocatorCircle.prototype.draw=function(){this.validateSettings();var settings=this.settings,canvasDimensions=this.getCanvasDimensions(),canvasWidth=canvasDimensions.width,canvasDimensions=canvasDimensions.height;this.map,this.getResolutionScale();if((context=this.getContext("2d")).clearRect(0,0,canvasWidth,canvasDimensions),settings.visible){context.shadowColor=settings.shadowColor,context.shadowBlur=settings.shadowBlur,context.setTransform(1,0,0,1,0,0);var end,scale=this.getScale(),canvasWidth=(context.scale(scale,scale),this.getWorldOriginOffset()),worldPoint=(context.translate(canvasWidth.x,canvasWidth.y),new WPGMZA.LatLng(this.settings.center),this.getCenterPixels()),rgba=WPGMZA.hexToRgba(settings.color),ringSpacing=this.getTransformedRadius(settings.radius)/(settings.numInnerRings+1),radius=(context.strokeStyle=settings.color,context.lineWidth=1/scale*settings.centerRingLineWidth,context.beginPath(),context.arc(worldPoint.x,worldPoint.y,this.getTransformedRadius(settings.centerRingRadius)/scale,0,2*Math.PI),context.stroke(),context.closePath(),this.getTransformedRadius(settings.radius)+ringSpacing*settings.numOuterRings+1),canvasDimensions=context.createRadialGradient(0,0,0,0,0,radius),rgba=WPGMZA.hexToRgba(settings.color),canvasWidth=WPGMZA.rgbaToString(rgba);rgba.a=0,end=WPGMZA.rgbaToString(rgba),canvasDimensions.addColorStop(0,canvasWidth),canvasDimensions.addColorStop(1,end),context.save(),context.translate(worldPoint.x,worldPoint.y),context.strokeStyle=canvasDimensions,context.lineWidth=2/scale;for(var i=0;i<settings.numSpokes;i++)spokeAngle=settings.spokesStartAngle+2*Math.PI*(i/settings.numSpokes),x=Math.cos(spokeAngle)*radius,y=Math.sin(spokeAngle)*radius,context.setLineDash([2/scale,15/scale]),context.beginPath(),context.moveTo(0,0),context.lineTo(x,y),context.stroke();context.setLineDash([]),context.restore(),context.lineWidth=1/scale*settings.innerRingLineWidth;for(i=1;i<=settings.numInnerRings;i++){radius=i*ringSpacing;settings.innerRingFade&&(rgba.a=1-(i-1)/settings.numInnerRings),context.strokeStyle=WPGMZA.rgbaToString(rgba),context.beginPath(),context.arc(worldPoint.x,worldPoint.y,radius,0,2*Math.PI),context.stroke(),context.closePath()}context.strokeStyle=settings.color,context.lineWidth=1/scale*settings.centerRingLineWidth,context.beginPath(),context.arc(worldPoint.x,worldPoint.y,this.getTransformedRadius(settings.radius),0,2*Math.PI),context.stroke(),context.closePath();for(radius=radius+ringSpacing,i=0;i<settings.numOuterRings;i++)settings.innerRingFade&&(rgba.a=1-i/settings.numOuterRings),context.strokeStyle=WPGMZA.rgbaToString(rgba),context.beginPath(),context.arc(worldPoint.x,worldPoint.y,radius,0,2*Math.PI),context.stroke(),context.closePath(),radius+=ringSpacing;if(0<settings.numRadiusLabels){var x,y,radius=this.getTransformedRadius(settings.radius);(canvasWidth=settings.radiusLabelFont.match(/(\d+)px/))&&parseInt(canvasWidth[1]),context.font=settings.radiusLabelFont,context.textAlign="center",context.textBaseline="middle",context.fillStyle=settings.color,context.save(),context.translate(worldPoint.x,worldPoint.y);for(i=0;i<settings.numRadiusLabels;i++){var spokeAngle,textAngle=(spokeAngle=settings.radiusLabelsStartAngle+2*Math.PI*(i/settings.numRadiusLabels))+Math.PI/2,text=settings.radiusString;0<Math.sin(spokeAngle)&&(textAngle-=Math.PI),x=Math.cos(spokeAngle)*radius,y=Math.sin(spokeAngle)*radius,context.save(),context.translate(x,y),context.rotate(textAngle),context.scale(1/scale,1/scale),textAngle=context.measureText(text).width,height=textAngle/2,context.clearRect(-textAngle,-height,2*textAngle,2*height),context.fillText(settings.radiusString,0,0),context.restore()}context.restore()}}}}),jQuery(function($){WPGMZA.ModernStoreLocator=function(map_id){var original,inner,addressInput,placeholder,container,titleSearch,numCategories,icons,self=this,map=WPGMZA.getMapByID(map_id);WPGMZA.assertInstanceOf(this,"ModernStoreLocator"),(original=(WPGMZA.isProVersion()?$(".wpgmza_sl_search_button[mid='"+map_id+"'], .wpgmza_sl_search_button_"+map_id):$(".wpgmza_sl_search_button")).closest(".wpgmza_sl_main_div")).length&&(this.element=$("<div class='wpgmza-modern-store-locator'><div class='wpgmza-inner wpgmza-modern-hover-opaque'/></div>")[0],inner=$(this.element).find(".wpgmza-inner"),addressInput=WPGMZA.isProVersion()?$(original).find(".addressInput"):$(original).find("#addressInput"),map.settings.store_locator_query_string&&map.settings.store_locator_query_string.length&&addressInput.attr("placeholder",map.settings.store_locator_query_string),inner.append(addressInput),(titleSearch=$(original).find("[id='nameInput_"+map_id+"']")).length&&((placeholder=map.settings.store_locator_name_string)&&placeholder.length&&titleSearch.attr("placeholder",placeholder),inner.append(titleSearch)),(placeholder=$(original).find("button.wpgmza-use-my-location"))&&inner.append(placeholder),$(addressInput).on("keydown keypress",function(event){13==event.keyCode&&self.searchButton.is(":visible")&&self.searchButton.trigger("click")}),$(addressInput).on("input",function(event){self.searchButton.show(),self.resetButton.hide()}),inner.append($(original).find("select.wpgmza_sl_radius_select")),this.searchButton=$(original).find(".wpgmza_sl_search_button, .wpgmza_sl_search_button_div"),inner.append(this.searchButton),this.resetButton=$(original).find(".wpgmza_sl_reset_button_div"),inner.append(this.resetButton),this.resetButton.on("click",function(event){resetLocations(map_id)}),this.resetButton.hide(),WPGMZA.isProVersion()&&(this.searchButton.on("click",function(event){0!=$("addressInput_"+map_id).val()&&(self.searchButton.hide(),self.resetButton.show(),map.storeLocator.state=WPGMZA.StoreLocator.STATE_APPLIED)}),this.resetButton.on("click",function(event){self.resetButton.hide(),self.searchButton.show(),map.storeLocator.state=WPGMZA.StoreLocator.STATE_INITIAL})),inner.append($("#wpgmza_distance_type_"+map_id)),container=$(original).find(".wpgmza_cat_checkbox_holder"),$(container).children("ul"),titleSearch=$(container).find("li"),numCategories=0,icons=[],titleSearch.each(function(index,el){var category_id,id=$(el).attr("class").match(/\d+/);for(category_id in wpgmza_category_data)if(id==category_id){var src=wpgmza_category_data[category_id].image,icon=$('<div class="wpgmza-chip-icon"/>');icon.css({"background-image":"url('"+src+"')",width:$("#wpgmza_cat_checkbox_"+category_id+" + label").height()+"px"}),icons.push(icon),null!=src&&""!=src&&$("#wpgmza_cat_checkbox_"+category_id+" + label").prepend(icon),numCategories++;break}}),$(this.element).append(container),numCategories&&(this.optionsButton=$('<span class="wpgmza_store_locator_options_button"><i class="fa fa-list"></i></span>'),$(this.searchButton).before(this.optionsButton)),setInterval(function(){icons.forEach(function(icon){var height=$(icon).height();$(icon).css({width:height+"px"}),$(icon).closest("label").css({"padding-left":height+8+"px"})}),$(container).css("width",$(self.element).find(".wpgmza-inner").outerWidth()+"px")},1e3),$(this.element).find(".wpgmza_store_locator_options_button").on("click",function(event){container.hasClass("wpgmza-open")?container.removeClass("wpgmza-open"):container.addClass("wpgmza-open")}),$(original).remove(),$(this.element).find("input, select").on("focus",function(){$(inner).addClass("active")}),$(this.element).find("input, select").on("blur",function(){$(inner).removeClass("active")}),$(this.element).on("mouseover","li.wpgmza_cat_checkbox_item_holder",function(event){self.onMouseOverCategory(event)}),$(this.element).on("mouseleave","li.wpgmza_cat_checkbox_item_holder",function(event){self.onMouseLeaveCategory(event)}),$("body").on("click",".wpgmza_store_locator_options_button",function(event){setTimeout(function(){var p_cat,$p_map;$(".wpgmza_cat_checkbox_holder").hasClass("wpgmza-open")&&(p_cat=(p_cat=$(".wpgmza_cat_checkbox_holder")).position().top+p_cat.outerHeight(!0)+$(".wpgmza-modern-store-locator").height(),($p_map=$(".wpgmza_map")).position().top+$p_map.outerHeight(!0)<=p_cat&&($(".wpgmza_cat_ul").css("overflow","scroll "),$(".wpgmza_cat_ul").css("height","100%"),$(".wpgmza-modern-store-locator").css("height","100%"),$(".wpgmza_cat_checkbox_holder.wpgmza-open").css({"padding-bottom":"50px",height:"100%"})))},500)}))},WPGMZA.ModernStoreLocator.createInstance=function(map_id){return new("open-layers"!==WPGMZA.settings.engine?WPGMZA.GoogleModernStoreLocator:WPGMZA.OLModernStoreLocator)(map_id)},WPGMZA.ModernStoreLocator.prototype.onMouseOverCategory=function(event){event=event.currentTarget;$(event).children("ul.wpgmza_cat_checkbox_item_holder").stop(!0,!1).fadeIn()},WPGMZA.ModernStoreLocator.prototype.onMouseLeaveCategory=function(event){event=event.currentTarget;$(event).children("ul.wpgmza_cat_checkbox_item_holder").stop(!0,!1).fadeOut()}}),jQuery(function($){WPGMZA.NativeMapsAppIcon=function(){navigator.userAgent.match(/^Apple|iPhone|iPad|iPod/)?(this.type="apple",this.element=$('<span><i class="fab fa fa-apple" aria-hidden="true"></i></span>')):(this.type="google",this.element=$('<span><i class="fab fa fa-google" aria-hidden="true"></i></span>'))}}),jQuery(function($){WPGMZA.PersistentAdminNotice=function(element,options){if(!(element instanceof HTMLElement))throw new Error("Element is not an instance of HTMLInputElement");this.element=$(element),this.dismissButton=this.element.find(".notice-dismiss"),this.ajaxActionButton=this.element.find("a[data-ajax]"),this.bindEvents()},WPGMZA.extend(WPGMZA.PersistentAdminNotice,WPGMZA.EventDispatcher),WPGMZA.PersistentAdminNotice.createInstance=function(element){return new WPGMZA.PersistentAdminNotice(element)},WPGMZA.PersistentAdminNotice.prototype.bindEvents=function(){let self=this;this.dismissButton.on("click",function(event){self.onDismiss($(this))}),this.ajaxActionButton.on("click",function(event){event.preventDefault(),self.onAjaxAction($(this))})},WPGMZA.PersistentAdminNotice.prototype.onDismiss=function(item){var data={action:"wpgmza_dismiss_persistent_notice",slug:this.element.data("slug"),wpgmza_security:WPGMZA.ajaxnonce};$.ajax(WPGMZA.ajaxurl,{method:"POST",data:data,success:function(response,status,xhr){},error:function(){}})},WPGMZA.PersistentAdminNotice.prototype.onAjaxAction=function(item){var action;item.data("disabled")||(action=item.data("ajax-action"),item.attr("data-disabled","true"),item.css("opacity","0.5"),action&&(item={action:"wpgmza_persisten_notice_quick_action",relay:action,wpgmza_security:WPGMZA.ajaxnonce},$.ajax(WPGMZA.ajaxurl,{method:"POST",data:item,success:function(response){window.location.reload()},error:function(){}})))},$(document.body).ready(function(){$(".wpgmza-persistent-notice").each(function(index,el){el.wpgmzaPersistentAdminNotice=WPGMZA.PersistentAdminNotice.createInstance(el)})})}),jQuery(function($){WPGMZA.Pointlabel=function(options,pointlabel){var map;WPGMZA.assertInstanceOf(this,"Pointlabel"),(options=options||{}).map?this.map=options.map:!options.map&&options.map_id&&(map=WPGMZA.getMapByID(options.map_id))&&(this.map=map),this.center=new WPGMZA.LatLng,WPGMZA.Feature.apply(this,arguments),pointlabel&&(this.setPosition(pointlabel.getPosition()),pointlabel.marker&&(this.marker=pointlabel.marker))},WPGMZA.Pointlabel.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Pointlabel.prototype.constructor=WPGMZA.Pointlabel,Object.defineProperty(WPGMZA.Pointlabel.prototype,"map",{enumerable:!0,get:function(){return this._map||null},set:function(a){this.textFeature&&!a&&this.textFeature.remove(),this._map=a}}),WPGMZA.Pointlabel.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProPointlabel:WPGMZA.GooglePointlabel:WPGMZA.isProVersion()?WPGMZA.OLProPointlabel:WPGMZA.OLPointlabel},WPGMZA.Pointlabel.createInstance=function(options,pointlabel){return new(WPGMZA.Pointlabel.getConstructor())(options,pointlabel)},WPGMZA.Pointlabel.createEditableMarker=function(options){function callback(){try{marker.setIcon(WPGMZA.labelpointIcon)}catch(ex){}marker.off("added",callback)}(options=$.extend({draggable:!0,disableInfoWindow:!0},options)).pointlabel&&(latLng=options.pointlabel.getPosition(),options.lat=latLng.lat,options.lng=latLng.lng);var latLng,marker=WPGMZA.Marker.createInstance(options);return marker.on("added",callback),marker},WPGMZA.Pointlabel.prototype.setEditable=function(editable){var self=this;this.marker&&(this.marker.map.removeMarker(this.marker),delete this.marker),this._prevMap&&delete this._prevMap,editable&&(this.marker=WPGMZA.Pointlabel.createEditableMarker({pointlabel:this}),this.map.addMarker(this.marker),this._dragEndCallback=function(event){self.onDragEnd(event)},editable=this.map,this.marker.on("dragend",this._dragEndCallback),editable.on("pointlabelremoved",function(event){event.pointlabel}))},WPGMZA.Pointlabel.prototype.onDragEnd=function(event){event.target instanceof WPGMZA.Marker&&this.marker&&(event.latLng&&this.setPosition(event.latLng),this.trigger("change"))},WPGMZA.Pointlabel.prototype.onMapMouseDown=function(event){if(0==event.button)return this._mouseDown=!0,event.preventDefault(),!1},WPGMZA.Pointlabel.prototype.onWindowMouseUp=function(event){0==event.button&&(this._mouseDown=!1)},WPGMZA.Pointlabel.prototype.onMapMouseMove=function(event){this._mouseDown&&(event={x:event.pageX-$(this.map.element).offset().left,y:event.pageY+30-$(this.map.element).offset().top},(event=this.map.pixelsToLatLng(event))&&this.setPosition(event),this.trigger("change"))},WPGMZA.Pointlabel.prototype.getPosition=function(){return this.center?new WPGMZA.LatLng({lat:this.center.lat,lng:this.center.lng}):null},WPGMZA.Pointlabel.prototype.setPosition=function(position){this.center={},this.center.lat=position.lat,this.center.lng=position.lng,this.textFeature&&this.textFeature.setPosition(this.getPosition())},WPGMZA.Pointlabel.prototype.getMap=function(){return this.map},WPGMZA.Pointlabel.prototype.setMap=function(map){this.map&&this.map.removePointlabel(this),map&&map.addPointlabel(this)}}),jQuery(function($){Uint8Array.prototype.slice||Object.defineProperty(Uint8Array.prototype,"slice",{value:function(begin,end){return new Uint8Array(Array.prototype.slice.call(this,begin,end))}}),WPGMZA.isSafari()&&!window.external&&(window.external={})}),jQuery(function($){WPGMZA.Polygon=function(row,enginePolygon){var self=this;WPGMZA.assertInstanceOf(this,"Polygon"),this.paths=null,WPGMZA.Feature.apply(this,arguments),this.addEventListener("added",function(event){self.onAdded()})},WPGMZA.Polygon.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Polygon.prototype.constructor=WPGMZA.Polygon,Object.defineProperty(WPGMZA.Polygon.prototype,"fillColor",{enumerable:!0,get:function(){return this.fillcolor&&this.fillcolor.length?"#"+this.fillcolor.replace(/^#/,""):"#ff0000"},set:function(a){this.fillcolor=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"fillOpacity",{enumerable:!0,get:function(){return this.opacity&&this.opacity.length?this.opacity:.6},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"strokeColor",{enumerable:!0,get:function(){return this.linecolor&&this.linecolor.length?"#"+this.linecolor.replace(/^#/,""):"#ff0000"},set:function(a){this.linecolor=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.lineopacity&&this.lineopacity.length?this.lineopacity:.6},set:function(a){this.lineopacity=a}}),Object.defineProperty(WPGMZA.Polygon.prototype,"strokeWeight",{enumerable:!0,get:function(){return this.linethickness&&this.linethickness.length?parseInt(this.linethickness):3}}),WPGMZA.Polygon.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.isProVersion()?WPGMZA.GoogleProPolygon:WPGMZA.GooglePolygon:WPGMZA.isProVersion()?WPGMZA.OLProPolygon:WPGMZA.OLPolygon},WPGMZA.Polygon.createInstance=function(row,engineObject){return new(WPGMZA.Polygon.getConstructor())(row,engineObject)},WPGMZA.Polygon.prototype.onAdded=function(){}}),jQuery(function($){WPGMZA.Polyline=function(options,googlePolyline){var self=this;WPGMZA.assertInstanceOf(this,"Polyline"),WPGMZA.Feature.apply(this,arguments),this.addEventListener("added",function(event){self.onAdded()})},WPGMZA.Polyline.prototype=Object.create(WPGMZA.Feature.prototype),WPGMZA.Polyline.prototype.constructor=WPGMZA.Polyline,Object.defineProperty(WPGMZA.Polyline.prototype,"strokeColor",{enumerable:!0,get:function(){return this.linecolor&&this.linecolor.length?"#"+this.linecolor.replace(/^#/,""):"#ff0000"},set:function(a){this.linecolor=a}}),Object.defineProperty(WPGMZA.Polyline.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.opacity&&this.opacity.length?this.opacity:.6},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Polyline.prototype,"strokeWeight",{enumerable:!0,get:function(){return this.linethickness&&this.linethickness.length?parseInt(this.linethickness):1},set:function(a){this.linethickness=a}}),Object.defineProperty(WPGMZA.Polyline.prototype,"layergroup",{enumerable:!0,get:function(){return this._layergroup||0},set:function(value){parseInt(value)&&(this._layergroup=parseInt(value)+WPGMZA.Shape.BASE_LAYER_INDEX)}}),WPGMZA.Polyline.getConstructor=function(){return"open-layers"!==WPGMZA.settings.engine?WPGMZA.GooglePolyline:WPGMZA.OLPolyline},WPGMZA.Polyline.createInstance=function(options,engineObject){return new(WPGMZA.Polyline.getConstructor())(options,engineObject)},WPGMZA.Polyline.prototype.getPoints=function(){return this.toJSON().points},WPGMZA.Polyline.prototype.onAdded=function(){this.layergroup&&this.setLayergroup(this.layergroup)},WPGMZA.Polyline.prototype.toJSON=function(){var result=WPGMZA.Feature.prototype.toJSON.call(this);return result.title=this.title,result},WPGMZA.Polyline.prototype.setLayergroup=function(layergroup){this.layergroup=layergroup,this.layergroup&&this.setOptions({zIndex:this.layergroup})}}),jQuery(function($){WPGMZA.PopoutPanel=function(element){this.element=element},WPGMZA.PopoutPanel.prototype.open=function(){$(this.element).addClass("wpgmza-open")},WPGMZA.PopoutPanel.prototype.close=function(){$(this.element).removeClass("wpgmza-open")}}),jQuery(function($){function sendAJAXFallbackRequest(route,params){if((params=$.extend({},params)).data||(params.data={}),"route"in params.data)throw new Error("Cannot send route through this method");if("action"in params.data)throw new Error("Cannot send action through this method");return params.data.route=route,params.data.action="wpgmza_rest_api_request",WPGMZA.restAPI.addNonce(route,params,WPGMZA.RestAPI.CONTEXT_AJAX),$.ajax(WPGMZA.ajaxurl,params)}WPGMZA.RestAPI=function(){WPGMZA.RestAPI.URL=WPGMZA.resturl,this.useAJAXFallback=!1,$(document.body).trigger("init.restapi.wpgmza")},WPGMZA.RestAPI.CONTEXT_REST="REST",WPGMZA.RestAPI.CONTEXT_AJAX="AJAX",WPGMZA.RestAPI.createInstance=function(){return new WPGMZA.RestAPI},Object.defineProperty(WPGMZA.RestAPI.prototype,"isCompressedPathVariableSupported",{get:function(){return WPGMZA.serverCanInflate&&"Uint8Array"in window&&"TextEncoder"in window}}),Object.defineProperty(WPGMZA.RestAPI.prototype,"isCompressedPathVariableAllowed",{get:function(){return!WPGMZA.pro_version||WPGMZA.Version.compare(WPGMZA.pro_version,"8.0.0")>=WPGMZA.Version.EQUAL_TO?!WPGMZA.settings.disable_compressed_path_variables:WPGMZA.settings.enable_compressed_path_variables}}),Object.defineProperty(WPGMZA.RestAPI.prototype,"maxURLLength",{get:function(){return 2083}}),WPGMZA.RestAPI.prototype.compressParams=function(params){var suffix="",string=(!params.markerIDs||1<(markerIDs=params.markerIDs.split(",")).length&&(markerIDs=(new WPGMZA.EliasFano).encode(markerIDs),compressed=pako.deflate(markerIDs),string=Array.prototype.map.call(compressed,function(ch){return String.fromCharCode(ch)}).join(""),suffix="/"+btoa(string).replace(/\//g,"-").replace(/=+$/,""),params.midcbp=markerIDs.pointer,delete params.markerIDs),JSON.stringify(params)),markerIDs=(new TextEncoder).encode(string),compressed=pako.deflate(markerIDs),params=Array.prototype.map.call(compressed,function(ch){return String.fromCharCode(ch)}).join("");return btoa(params).replace(/\//g,"-").replace(/=+$/,"")+suffix},WPGMZA.RestAPI.prototype.getNonce=function(route){var pattern,matches=[];for(pattern in WPGMZA.restnoncetable){var regex=new RegExp(pattern);route.match(regex)&&matches.push({pattern:pattern,nonce:WPGMZA.restnoncetable[pattern],length:pattern.length})}if(matches.length)return matches.sort(function(a,b){return b.length-a.length}),matches[0].nonce;throw new Error("No nonce found for route")},WPGMZA.RestAPI.prototype.addNonce=function(route,params,context){function setRESTNonce(xhr){context==WPGMZA.RestAPI.CONTEXT_REST&&self.shouldAddNonce(route)&&xhr.setRequestHeader("X-WP-Nonce",WPGMZA.restnonce),params&&params.method&&!params.method.match(/^GET$/i)&&xhr.setRequestHeader("X-WPGMZA-Action-Nonce",self.getNonce(route))}var base,self=this;params.beforeSend?(base=params.beforeSend,params.beforeSend=function(xhr){base(xhr),setRESTNonce(xhr)}):params.beforeSend=setRESTNonce},WPGMZA.RestAPI.prototype.shouldAddNonce=function(route){route=route.replace(/\//g,"");var isAdmin=!1;WPGMZA.is_admin&&1===parseInt(WPGMZA.is_admin)&&(isAdmin=!0);return!(route&&["markers","features","marker-listing","datatables"].includes(route)&&!isAdmin)},WPGMZA.RestAPI.prototype.call=function(route,params){if(this.useAJAXFallback)return sendAJAXFallbackRequest(route,params);var compressedParams,data,attemptedCompressedPathVariable=!1,fallbackRoute=route,fallbackParams=$.extend({},params);if("string"!=typeof route||!route.match(/^\//)&&!route.match(/^http/))throw new Error("Invalid route");WPGMZA.RestAPI.URL.match(/\/$/)&&(route=route.replace(/^\//,"")),params=params||{},this.addNonce(route,params,WPGMZA.RestAPI.CONTEXT_REST),params.error||(params.error=function(xhr,status,message){if("abort"!=status){switch(xhr.status){case 401:case 403:case 405:return($.post(WPGMZA.ajaxurl,{action:"wpgmza_report_rest_api_blocked"},function(response){}),console.warn("The REST API was blocked. This is usually due to security plugins blocking REST requests for non-authenticated users."),"DELETE"===params.method)?(console.warn("The REST API rejected a DELETE request, attempting again with POST fallback"),params.method="POST",params.data||(params.data={}),params.data.simulateDelete="yes",WPGMZA.restAPI.call(route,params)):(this.useAJAXFallback=!0,sendAJAXFallbackRequest(fallbackRoute,fallbackParams));case 414:if(attemptedCompressedPathVariable)return fallbackParams.method="POST",fallbackParams.useCompressedPathVariable=!1,WPGMZA.restAPI.call(fallbackRoute,fallbackParams)}throw new Error(message)}}),params.useCompressedPathVariable&&this.isCompressedPathVariableSupported&&this.isCompressedPathVariableAllowed&&(compressedParams=$.extend({},params),data=params.data,data=this.compressParams(data),WPGMZA.isServerIIS&&(data=data.replace(/\+/g,"%20")),data=route.replace(/\/$/,"")+"/base64"+data,WPGMZA.RestAPI.URL,compressedParams.method="GET",delete compressedParams.data,!1===params.cache&&(compressedParams.data={skip_cache:1}),data.length<this.maxURLLength?(attemptedCompressedPathVariable=!0,route=data,params=compressedParams):(WPGMZA.RestAPI.compressedPathVariableURLLimitWarningDisplayed||console.warn("Compressed path variable route would exceed URL length limit"),WPGMZA.RestAPI.compressedPathVariableURLLimitWarningDisplayed=!0));var onSuccess=null;return params.success&&(onSuccess=params.success),params.success=function(result,status,xhr){if("object"!=typeof result){var rawResult=result;try{result=JSON.parse(result)}catch(parseExc){result=rawResult}}onSuccess&&"function"==typeof onSuccess&&onSuccess(result,status,xhr)},WPGMZA.RestAPI.URL.match(/\?/)&&(route=route.replace(/\?/,"&")),$.ajax(WPGMZA.RestAPI.URL+route,params)};var nativeCallFunction=WPGMZA.RestAPI.call;WPGMZA.RestAPI.call=function(){console.warn("WPGMZA.RestAPI.call was called statically, did you mean to call the function on WPGMZA.restAPI?"),nativeCallFunction.apply(this,arguments)},$(document.body).on("click","#wpgmza-rest-api-blocked button.notice-dismiss",function(event){WPGMZA.restAPI.call("/rest-api/",{method:"POST",data:{dismiss_blocked_notice:!0}})})});var $_GET={};if(-1!==document.location.toString().indexOf("?"))for(var query=document.location.toString().replace(/^.*?\?/,"").replace(/#.*$/,"").split("&"),wpgmza_i=0,wpgmza_l=query.length;wpgmza_i<wpgmza_l;wpgmza_i++){var aux=decodeURIComponent(query[wpgmza_i]).split("=");$_GET[aux[0]]=aux[1]}jQuery(function($){WPGMZA.SettingsPage=function(){var self=this;this._keypressHistory=[],this._codemirrors={},this.updateEngineSpecificControls(),this.updateStorageControls(),this.updateBatchControls(),this.updateGDPRControls(),this.updateWooControls(),$(window).on("keypress",function(event){self.onKeyPress(event)}),jQuery("body").on("click",".wpgmza_destroy_data",function(e){e.preventDefault();var ttype=jQuery(this).attr("danger"),e="wpgmza_destroy_all_data"==ttype?"Are you sure? This will delete ALL data and settings for WP Go Maps!":"Are you sure?";window.confirm(e)&&jQuery.ajax(WPGMZA.ajaxurl,{method:"POST",data:{action:"wpgmza_maps_settings_danger_zone_delete_data",type:ttype,nonce:wpgmza_dz_nonce},success:function(response,status,xhr){"wpgmza_destroy_all_data"==ttype?window.location.replace("admin.php?page=wp-google-maps-menu&action=welcome_page"):"wpgmza_reset_all_settings"==ttype?window.location.reload():alert("Complete.")}})}),$("select[name='wpgmza_maps_engine']").on("change",function(event){self.updateEngineSpecificControls()}),$('[name="wpgmza_settings_marker_pull"]').on("click",function(event){self.updateStorageControls()}),$('input[name="enable_batch_loading"]').on("change",function(event){self.updateBatchControls()}),$("input[name='wpgmza_gdpr_require_consent_before_load'], input[name='wpgmza_gdpr_require_consent_before_vgm_submit'], input[name='wpgmza_gdpr_override_notice']").on("change",function(event){self.updateGDPRControls()}),$('input[name="woo_checkout_map_enabled"]').on("change",function(event){self.updateWooControls()}),$('select[name="tile_server_url"]').on("change",function(event){"custom_override"===$('select[name="tile_server_url"]').val()?$(".wpgmza_tile_server_override_component").removeClass("wpgmza-hidden"):$(".wpgmza_tile_server_override_component").addClass("wpgmza-hidden")}),$('select[name="tile_server_url"]').trigger("change"),jQuery("#wpgmza_flush_cache_btn").on("click",function(){jQuery(this).attr("disabled","disabled"),WPGMZA.settingsPage.flushGeocodeCache()}),$("#wpgmza-global-settings").tabs({create:function(event,ui){var elmnt,y;void 0!==$_GET.highlight&&((elmnt=document.getElementById($_GET.highlight)).classList.add("highlight-item"),setTimeout(function(){elmnt.classList.add("highlight-item-step-2")},1e3),y=elmnt.getBoundingClientRect().top+window.pageYOffset+-100,window.scrollTo({top:y,behavior:"smooth"}))},activate:function(){for(var i in self._codemirrors)self._codemirrors[i].refresh()}}),$("#wpgmza-global-setting").bind("create",function(event,ui){alert("now")}),$("#wpgmza-global-settings fieldset").each(function(index,el){$(el).children(":not(legend)").wrapAll("<span class='settings-group'></span>")}),$("textarea[name^='wpgmza_custom_']").each(function(){var name=$(this).attr("name"),type="js"===name.replace("wpgmza_custom_","")?"javascript":"css";self._codemirrors[name]=wp.CodeMirror.fromTextArea(this,{lineNumbers:!0,mode:type,theme:"wpgmza"}),self._codemirrors[name].on("change",function(instance){instance.save()}),self._codemirrors[name].refresh()}),$(".wpgmza-integration-tool-button").on("click",function(event){event.preventDefault();event=$(this).data("tool-type");if(event){event={type:event};const button=$(this);button.attr("disabled","disabled"),WPGMZA.restAPI.call("/integration-tools/",{method:"POST",data:event,success:function(data,status,xhr){if(button.removeAttr("disabled"),data&&data.type)switch(data.type){case"test_collation":data.success||($('.wpgmza-integration-tool-button[data-tool-type="test_collation"]').addClass("wpgmza-hidden"),$('.wpgmza-integration-tool-button[data-tool-type="resolve_collation"]').removeClass("wpgmza-hidden")),data.message&&window.alert(data.message);break;case"resolve_collation":data.success||($('.wpgmza-integration-tool-button[data-tool-type="test_collation"]').removeClass("wpgmza-hidden"),$('.wpgmza-integration-tool-button[data-tool-type="resolve_collation"]').addClass("wpgmza-hidden")),data.message&&window.alert(data.message);break;default:data.message&&window.alert(data.message)}}})}})},WPGMZA.SettingsPage.createInstance=function(){return new WPGMZA.SettingsPage},WPGMZA.SettingsPage.prototype.updateEngineSpecificControls=function(){var engine=$("select[name='wpgmza_maps_engine']").val();$("[data-required-maps-engine][data-required-maps-engine!='"+engine+"']").hide(),$("[data-required-maps-engine='"+engine+"']").show()},WPGMZA.SettingsPage.prototype.updateStorageControls=function(){$("input[name='wpgmza_settings_marker_pull'][value='1']").is(":checked")?$("#xml-cache-settings").show():$("#xml-cache-settings").hide()},WPGMZA.SettingsPage.prototype.updateBatchControls=function(){$("input[name='enable_batch_loading']").is(":checked")?$("#batch-loader-settings").show():$("#batch-loader-settings").hide()},WPGMZA.SettingsPage.prototype.updateGDPRControls=function(){var showNoticeControls=$("input[name='wpgmza_gdpr_require_consent_before_load']").prop("checked"),vgmCheckbox=$("input[name='wpgmza_gdpr_require_consent_before_vgm_submit']"),vgmCheckbox=(showNoticeControls=vgmCheckbox.length?showNoticeControls||vgmCheckbox.prop("checked"):showNoticeControls)&&$("input[name='wpgmza_gdpr_override_notice']").prop("checked");showNoticeControls?$("#wpgmza-gdpr-compliance-notice").show(!!WPGMZA.InternalEngine.isLegacy()&&"slow"):$("#wpgmza-gdpr-compliance-notice").hide(!!WPGMZA.InternalEngine.isLegacy()&&"slow"),vgmCheckbox?$("#wpgmza_gdpr_override_notice_text").show(!!WPGMZA.InternalEngine.isLegacy()&&"slow"):$("#wpgmza_gdpr_override_notice_text").hide(!!WPGMZA.InternalEngine.isLegacy()&&"slow")},WPGMZA.SettingsPage.prototype.updateWooControls=function(){$("input[name='woo_checkout_map_enabled']").prop("checked")?$(".woo-checkout-maps-select-row").show():$(".woo-checkout-maps-select-row").hide()},WPGMZA.SettingsPage.prototype.flushGeocodeCache=function(){(new WPGMZA.OLGeocoder).clearCache(function(response){jQuery("#wpgmza_flush_cache_btn").removeAttr("disabled")})},WPGMZA.SettingsPage.prototype.onKeyPress=function(event){this._keypressHistory.push(event.key),9<this._keypressHistory.length&&(this._keypressHistory=this._keypressHistory.slice(this._keypressHistory.length-9)),"codecabin"!=this._keypressHistory.join("")||this._developerModeRevealed||($("fieldset#wpgmza-developer-mode").show(),this._developerModeRevealed=!0)},$(document).ready(function(event){WPGMZA.getCurrentPage()&&(WPGMZA.settingsPage=WPGMZA.SettingsPage.createInstance())})}),jQuery(function($){var Parent=WPGMZA.Feature;WPGMZA.Shape=function(options,engineFeature){var self=this;WPGMZA.assertInstanceOf(this,"Shape"),Parent.apply(this,arguments),this.addEventListener("added",function(event){self.onAdded()})},WPGMZA.extend(WPGMZA.Shape,WPGMZA.Feature),WPGMZA.Shape.BASE_LAYER_INDEX=99999,WPGMZA.Shape.prototype.onAdded=function(){}}),jQuery(function($){var Parent=WPGMZA.Shape;WPGMZA.Circle=function(options,engineCircle){WPGMZA.assertInstanceOf(this,"Circle"),this.center=new WPGMZA.LatLng,this.radius=100,Parent.apply(this,arguments)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProShape),WPGMZA.extend(WPGMZA.Circle,Parent),Object.defineProperty(WPGMZA.Circle.prototype,"fillColor",{enumerable:!0,get:function(){return this.color&&this.color.length?this.color:"#ff0000"},set:function(a){this.color=a}}),Object.defineProperty(WPGMZA.Circle.prototype,"fillOpacity",{enumerable:!0,get:function(){return this.opacity||0==this.opacity?parseFloat(this.opacity):.5},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Circle.prototype,"strokeColor",{enumerable:!0,get:function(){return this.lineColor||"#000000"},set:function(a){this.lineColor=a}}),Object.defineProperty(WPGMZA.Circle.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.lineOpacity||0==this.lineOpacity?parseFloat(this.lineOpacity):0},set:function(a){this.lineOpacity=a}}),WPGMZA.Circle.createInstance=function(options,engineCircle){var constructor;switch(WPGMZA.settings.engine){case"open-layers":if(WPGMZA.isProVersion()){constructor=WPGMZA.OLProCircle;break}constructor=WPGMZA.OLCircle;break;default:if(WPGMZA.isProVersion()){constructor=WPGMZA.GoogleProCircle;break}constructor=WPGMZA.GoogleCircle}return new constructor(options,engineCircle)},WPGMZA.Circle.prototype.getCenter=function(){return this.center.clone()},WPGMZA.Circle.prototype.setCenter=function(latLng){this.center.lat=latLng.lat,this.center.lng=latLng.lng},WPGMZA.Circle.prototype.getRadius=function(){return this.radius},WPGMZA.Circle.prototype.setRadius=function(radius){this.radius=radius},WPGMZA.Circle.prototype.getMap=function(){return this.map},WPGMZA.Circle.prototype.setMap=function(map){this.map&&this.map.removeCircle(this),map&&map.addCircle(this)}}),jQuery(function($){var Parent=WPGMZA.Shape;WPGMZA.Rectangle=function(options,engineRectangle){WPGMZA.assertInstanceOf(this,"Rectangle"),this.name="",this.cornerA=new WPGMZA.LatLng,this.cornerB=new WPGMZA.LatLng,this.color="#ff0000",this.opacity=.5,Parent.apply(this,arguments)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProShape),WPGMZA.extend(WPGMZA.Rectangle,Parent),Object.defineProperty(WPGMZA.Rectangle.prototype,"fillColor",{enumerable:!0,get:function(){return this.color&&this.color.length?this.color:"#ff0000"},set:function(a){this.color=a}}),Object.defineProperty(WPGMZA.Rectangle.prototype,"fillOpacity",{enumerable:!0,get:function(){return this.opacity||0==this.opacity?parseFloat(this.opacity):.5},set:function(a){this.opacity=a}}),Object.defineProperty(WPGMZA.Rectangle.prototype,"strokeColor",{enumerable:!0,get:function(){return this.lineColor||"#000000"},set:function(a){this.lineColor=a}}),Object.defineProperty(WPGMZA.Rectangle.prototype,"strokeOpacity",{enumerable:!0,get:function(){return this.lineOpacity||0==this.lineOpacity?parseFloat(this.lineOpacity):0},set:function(a){this.lineOpacity=a}}),WPGMZA.Rectangle.createInstance=function(options,engineRectangle){var constructor;switch(WPGMZA.settings.engine){case"open-layers":if(WPGMZA.isProVersion()){constructor=WPGMZA.OLProRectangle;break}constructor=WPGMZA.OLRectangle;break;default:if(WPGMZA.isProVersion()){constructor=WPGMZA.GoogleProRectangle;break}constructor=WPGMZA.GoogleRectangle}return new constructor(options,engineRectangle)}}),jQuery(function($){WPGMZA.SidebarGroupings=function(){var self=this;this.element=document.body,this.actionBar={element:$(this.element).find(".action-bar"),dynamicAction:null,dynamicLabel:""},$(this.element).on("click",".grouping .item",function(event){self.openTab(event)}),$(".quick-actions .actions").on("click",".icon",function(event){var feature=$(this).data("type");feature&&(self.openTabByFeatureType(feature),$(".quick-actions #qa-add-datasets").prop("checked",!1))}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-edit",function(event){event.feature&&self.openTabByFeatureType(event.feature)}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-saved",function(event){event.feature&&self.closeCurrent()}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-busy",function(event){self.resetScroll()}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-created",function(event){}),$(this.element).find(".fieldset-toggle").on("click",function(event){$(this).toggleClass("toggled")}),$(this.element).on("click",".wpgmza-toolbar .wpgmza-toolbar-list > *",function(event){$(this).parent().parent().find("label").click()}),$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").on("sidebar-delegate-feature-caption-loaded",function(event){self.actionBar.dynamicAction&&(self.actionBar.dynamicLabel=self.actionBar.dynamicAction.text(),self.actionBar.element.find(".dynamic-action").removeClass("wpgmza-hidden").text(self.actionBar.dynamicLabel))}),this.actionBar.element.find(".dynamic-action").on("click",function(event){self.actionBar.dynamicAction&&self.actionBar.dynamicAction.click()}),this.initUpsellBlocks()},WPGMZA.extend(WPGMZA.SidebarGroupings,WPGMZA.EventDispatcher),WPGMZA.SidebarGroupings.createInstance=function(){return new WPGMZA.SidebarGroupings},WPGMZA.SidebarGroupings.prototype.openTab=function(event){event=event.currentTarget,event=$(event).data("group");this.openTabByGroupId(event),WPGMZA.mapEditPage&&WPGMZA.mapEditPage.map&&WPGMZA.mapEditPage.map.onElementResized()},WPGMZA.SidebarGroupings.prototype.openTabByFeatureType=function(feature){0<$(this.element).find('.grouping[data-feature="'+feature+'"]').length&&(feature=$(this.element).find('.grouping[data-feature="'+feature+'"]').data("group"),this.openTabByGroupId(feature))},WPGMZA.SidebarGroupings.prototype.openTabByGroupId=function(groupId){var element;groupId&&this.hasGroup(groupId)&&(this.closeAll(),(element=$(this.element).find('.grouping[data-group="'+groupId+'"]')).addClass("open"),element.data("feature-discard")&&$(element).trigger("feature-block-closed"),0<$(".wpgmza-map-settings-form").find(element).length?$(".wpgmza-map-settings-form").removeClass("wpgmza-hidden"):$(".wpgmza-map-settings-form").addClass("wpgmza-hidden"),element.hasClass("auto-expand")?$(".sidebar").addClass("expanded"):$(".sidebar").removeClass("expanded"),element.data("feature")&&$(element).trigger("feature-block-opened"),$(element).trigger("grouping-opened",[groupId]),this.updateActionBar(element))},WPGMZA.SidebarGroupings.prototype.hasGroup=function(groupId){return 0<$(this.element).find('.grouping[data-group="'+groupId+'"]').length},WPGMZA.SidebarGroupings.prototype.closeAll=function(){var self=this;$(this.element).find(".grouping.open").each(function(){var group=$(this).data("group");group&&$(self.element).trigger("grouping-closed",[group])}),$(this.element).find(".grouping").removeClass("open")},WPGMZA.SidebarGroupings.prototype.closeCurrent=function(){0<$(this.element).find(".grouping.open").length&&$(this.element).find(".grouping.open").find(".heading.has-back .item").click()},WPGMZA.SidebarGroupings.prototype.updateActionBar=function(element){this.actionBar.dynamicAction=null,element&&element.data("feature")&&0<element.find(".wpgmza-save-feature").length&&(this.actionBar.dynamicAction=element.find(".wpgmza-save-feature").first(),this.actionBar.dynamicLabel=this.actionBar.dynamicAction.text().trim()),this.actionBar.dynamicAction&&this.actionBar.dynamicAction.addClass("wpgmza-hidden"),this.actionBar.dynamicAction&&this.actionBar.dynamicLabel?(this.actionBar.element.find(".dynamic-action").removeClass("wpgmza-hidden").text(this.actionBar.dynamicLabel),this.actionBar.element.find(".static-action").addClass("wpgmza-hidden")):(this.actionBar.element.find(".static-action").removeClass("wpgmza-hidden"),this.actionBar.element.find(".dynamic-action").addClass("wpgmza-hidden").text(""))},WPGMZA.SidebarGroupings.prototype.resetScroll=function(){0<$(this.element).find(".grouping.open").length&&$(this.element).find(".grouping.open .settings").scrollTop(0)},WPGMZA.SidebarGroupings.prototype.initUpsellBlocks=function(){var upsellWrappers=$(this.element).find(".upsell-block.auto-rotate");if(upsellWrappers&&0<upsellWrappers.length)for(var currentWrapper of upsellWrappers)1<(currentWrapper=$(currentWrapper)).find(".upsell-block-card").length?(currentWrapper.addClass("rotate"),currentWrapper.on("wpgmza-upsell-rotate-card",function(){var cardLength=$(this).find(".upsell-block-card").length;$(this).find(".upsell-block-card").hide();let nextCard=parseInt(Math.random()*cardLength),nextCardElem=(nextCard<0?nextCard=0:nextCard>=cardLength&&(nextCard=cardLength-1),$(this).find(".upsell-block-card:nth-child("+(nextCard+1)+")"));0<nextCardElem.length&&!nextCardElem.hasClass("active")?($(this).find(".upsell-block-card").removeClass("active"),nextCardElem.addClass("active"),nextCardElem.fadeIn(200)):nextCardElem.show(),setTimeout(()=>{$(this).trigger("wpgmza-upsell-rotate-card")},1e4)}),currentWrapper.trigger("wpgmza-upsell-rotate-card")):currentWrapper.addClass("static")}}),jQuery(function($){WPGMZA.StoreLocator=function(map,element){var self=this;WPGMZA.EventDispatcher.call(this),this._center=null,this.map=map,this.element=element,this.state=WPGMZA.StoreLocator.STATE_INITIAL,this.distanceUnits=this.map.settings.store_locator_distance,this.addressInput=WPGMZA.AddressInput.createInstance(this.addressElement,this.map),$(element).find(".wpgmza-not-found-msg").hide(),this.radiusElement&&this.map.settings.wpgmza_store_locator_default_radius&&(this.radiusElement.data("default-override")||0<this.radiusElement.find("option[value='"+this.map.settings.wpgmza_store_locator_default_radius+"']").length&&this.radiusElement.val(this.map.settings.wpgmza_store_locator_default_radius)),this.map.on("storelocatorgeocodecomplete",function(event){self.onGeocodeComplete(event)}),this.map.on("init",function(event){self.map.markerFilter.on("filteringcomplete",function(event){self.onFilteringComplete(event)}),!WPGMZA.InternalEngine.isLegacy()||void 0!==self.map.settings.store_locator_style&&"modern"!=self.map.settings.store_locator_style&&"modern"!==WPGMZA.settings.user_interface_style||"default"!==WPGMZA.settings.user_interface_style&&"modern"!=WPGMZA.settings.user_interface_style&&"legacy"!=WPGMZA.settings.user_interface_style||(self.legacyModernAdapter=WPGMZA.ModernStoreLocator.createInstance(map.id))}),WPGMZA.InternalEngine.isLegacy()?($(document.body).on("click",".wpgmza_sl_search_button_"+map.id+", [data-map-id='"+map.id+"'] .wpgmza_sl_search_button",function(event){self.onSearch(event)}),$(document.body).on("click",".wpgmza_sl_reset_button_"+map.id+", [data-map-id='"+map.id+"'] .wpgmza_sl_reset_button_div",function(event){self.onReset(event)})):($(this.searchButton).on("click",function(event){self.onSearch(event)}),$(this.resetButton).on("click",function(event){self.onReset(event)})),$(this.addressElement).on("keypress",function(event){13==event.which&&self.onSearch(event)}),this.onQueryParamSearch(),self.trigger("init.storelocator")},WPGMZA.StoreLocator.prototype=Object.create(WPGMZA.EventDispatcher.prototype),WPGMZA.StoreLocator.prototype.constructor=WPGMZA.StoreLocator,WPGMZA.StoreLocator.STATE_INITIAL="initial",WPGMZA.StoreLocator.STATE_APPLIED="applied",WPGMZA.StoreLocator.createInstance=function(map,element){return new WPGMZA.StoreLocator(map,element)},Object.defineProperty(WPGMZA.StoreLocator.prototype,"address",{get:function(){return $(this.addressElement).val()}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"addressElement",{get:function(){return(this.legacyModernAdapter?$(this.legacyModernAdapter.element):$(this.element)).find("input.wpgmza-address")[0]}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"countryRestriction",{get:function(){return this.map.settings.wpgmza_store_locator_restrict}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"radiusElement",{get:function(){return WPGMZA.InternalEngine.isLegacy()?$("#radiusSelect, #radiusSelect_"+this.map.id):$(this.element).find("select.wpgmza-radius")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"searchButton",{get:function(){return $(this.element).find(".wpgmza-search")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"resetButton",{get:function(){return $(this.element).find(".wpgmza-reset")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"errorElement",{get:function(){return $(this.element).find(".wpgmza-error")}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"radius",{get:function(){return parseFloat(this.radiusElement.val())}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"center",{get:function(){return this._center}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"bounds",{get:function(){return this._bounds}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"marker",{get:function(){if(1!=this.map.settings.store_locator_bounce)return null;if(this._marker)return this._marker;return this._marker=WPGMZA.Marker.createInstance({visible:!1}),this._marker.disableInfoWindow=!0,this._marker.isFilterable=!1,this._marker.setAnimation(WPGMZA.Marker.ANIMATION_BOUNCE),this._marker}}),Object.defineProperty(WPGMZA.StoreLocator.prototype,"circle",{get:function(){return this._circle||("modern"!=this.map.settings.wpgmza_store_locator_radius_style||WPGMZA.isDeviceiOS()?this._circle=WPGMZA.Circle.createInstance({strokeColor:"#ff0000",strokeOpacity:"0.25",strokeWeight:2,fillColor:"#ff0000",fillOpacity:"0.15",visible:!1,clickable:!1,center:new WPGMZA.LatLng}):(this._circle=WPGMZA.ModernStoreLocatorCircle.createInstance(this.map.id),this._circle.settings.color=this.circleStrokeColor),this._circle)}}),WPGMZA.StoreLocator.prototype.onGeocodeComplete=function(event){if(!event.results||!event.results.length)return this._center=null,void(this._bounds=null);event.results[0].latLng?this._center=new WPGMZA.LatLng(event.results[0].latLng):event.results[0]instanceof WPGMZA.LatLng&&(this._center=new WPGMZA.LatLng(event.results[0])),this._bounds=new WPGMZA.LatLngBounds(event.results[0].bounds),this.isCapsule?this.redirectUrl&&this.onRedirectSearch():this.map.markerFilter.update({},this)},WPGMZA.StoreLocator.prototype.onSearch=function(event){var geocoder,options,self=this;return this.state=WPGMZA.StoreLocator.STATE_APPLIED,this.address&&this.address.length?(WPGMZA.InternalEngine.isLegacy()&&void 0!==this.map.settings.store_locator_style&&"modern"!==this.map.settings.store_locator_style&&"modern"!==WPGMZA.settings.user_interface_style&&"default"===WPGMZA.settings.user_interface_style&&WPGMZA.animateScroll(this.map.element),$(this.element).find(".wpgmza-not-found-msg").hide(),$(this.element).find(".wpgmza-error").removeClass("visible"),this.setVisualState("busy"),WPGMZA.LatLng.isLatLngString(this.address)?callback([WPGMZA.LatLng.fromString(this.address)],WPGMZA.Geocoder.SUCCESS):(geocoder=WPGMZA.Geocoder.createInstance(),options={address:this.address},this.countryRestriction&&(options.country=this.countryRestriction),geocoder.geocode(options,function(results,status){status==WPGMZA.Geocoder.SUCCESS?callback(results,status):WPGMZA.InternalEngine.isLegacy()?alert(WPGMZA.localized_strings.address_not_found):(self.showError(WPGMZA.localized_strings.address_not_found),self.setVisualState(!1))})),self.trigger("search.storelocator"),!0):(this.addressElement.focus(),!1);function callback(results,status){self.map.trigger({type:"storelocatorgeocodecomplete",results:results,status:status}),self.setVisualState("complete")}},WPGMZA.StoreLocator.prototype.onReset=function(event){this.state=WPGMZA.StoreLocator.STATE_INITIAL,this._center=null,this._bounds=null,this.map.setZoom(this.map.settings.map_start_zoom),$(this.element).find(".wpgmza-not-found-msg").hide(),this.circle&&this.circle.setVisible(!1),this.marker&&this.marker.map&&this.map.removeMarker(this.marker),this.map.markerFilter.update({},this),this.setVisualState(!1),WPGMZA.InternalEngine.isLegacy()||$(this.addressElement).val("").focus(),this.trigger("reset.storelocator")},WPGMZA.StoreLocator.prototype.onRedirectSearch=function(){if(this.redirectUrl)try{var data={radius:this.radius,center:this.center.lat+","+this.center.lng};const params=new URLSearchParams(data);window.location.href=this.redirectUrl+"?"+params.toString(),this.setVisualState("busy")}catch(ex){console.warn(ex)}},WPGMZA.StoreLocator.prototype.getFilteringParameters=function(){return this.center?{center:this.center,radius:this.radius}:{}},WPGMZA.StoreLocator.prototype.getZoomFromRadius=function(radius){return this.distanceUnits==WPGMZA.Distance.MILES&&(radius*=WPGMZA.Distance.KILOMETERS_PER_MILE),Math.round(14-Math.log(radius)/Math.LN2)},WPGMZA.StoreLocator.prototype.onFilteringComplete=function(event){var factor,params=event.filteringParams,marker=this.marker,marker=(marker&&marker.setVisible(!1),params.center&&(this.map.setCenter(params.center),marker&&(marker.setPosition(params.center),marker.setVisible(!0),marker.map!=this.map&&this.map.addMarker(marker))),params.radius&&this.map.setZoom(this.getZoomFromRadius(params.radius)),this.circle);marker&&(marker.setVisible(!1),factor=this.distanceUnits==WPGMZA.Distance.MILES?WPGMZA.Distance.KILOMETERS_PER_MILE:1,params.center&&params.radius&&(marker.setRadius(params.radius*factor),marker.setCenter(params.center),marker.setVisible(!0),marker instanceof WPGMZA.ModernStoreLocatorCircle||marker.map==this.map||this.map.addCircle(marker)),marker instanceof WPGMZA.ModernStoreLocatorCircle&&(marker.settings.radiusString=this.radius)),0==event.filteredMarkers.length&&this.state===WPGMZA.StoreLocator.STATE_APPLIED&&(WPGMZA.InternalEngine.isLegacy()?0<$(this.element).find(".wpgmza-no-results").length&&"legacy"===WPGMZA.settings.user_interface_style?$(this.element).find(".wpgmza-no-results").show():alert(this.map.settings.store_locator_not_found_message||WPGMZA.localized_strings.zero_results):this.showError(this.map.settings.store_locator_not_found_message||WPGMZA.localized_strings.zero_results))},WPGMZA.StoreLocator.prototype.onQueryParamSearch=function(){var queryCenter=WPGMZA.getQueryParamValue("center"),queryCenter=(queryCenter&&$(this.addressElement).val(queryCenter),WPGMZA.getQueryParamValue("radius"));queryCenter&&$(this.radiusElement).val(queryCenter),this.isCapsule||this.map.on("init",()=>{this.onSearch()})},WPGMZA.StoreLocator.prototype.setVisualState=function(state){!1!==state?$(this.element).attr("data-state",state):$(this.element).removeAttr("data-state")},WPGMZA.StoreLocator.prototype.showError=function(error){var self=this;WPGMZA.InternalEngine.isLegacy()||($(this.errorElement).text(error).addClass("visible"),setTimeout(function(){$(self.errorElement).text("").removeClass("visible")},3e3))}}),jQuery(function($){WPGMZA.StylingPage=function(){var self=this;this.element=document.body,this.styleGuide={wrapper:$(this.element).find(".wpgmza-styling-map-preview .wpgmza-style-guide-wrapper")},this.controls={},$(this.element).find(".wpgmza-styling-editor fieldset").each(function(){self.prepareControl(this)}),$(this.element).find(".wpgmza-styling-preset-select").on("change",function(){self.applyPreset(this)}),this.bindEvents(),this.parseUserPreset()},WPGMZA.StylingPage.PRESETS={},WPGMZA.StylingPage.PRESETS.default={"--wpgmza-component-color":"#ffffff","--wpgmza-component-text-color":"#000000","--wpgmza-component-color-accent":"#1A73E8","--wpgmza-component-text-color-accent":"#ffffff","--wpgmza-color-grey-500":"#bfbfbf","--wpgmza-component-border-radius":"2px","--wpgmza-component-font-size":"15px","--wpgmza-component-backdrop-filter":"none"},WPGMZA.StylingPage.PRESETS.glass={"--wpgmza-component-color":"rgba(255, 255, 255, 0.3)","--wpgmza-component-text-color":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color"],"--wpgmza-component-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-color-accent"],"--wpgmza-component-text-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color-accent"],"--wpgmza-color-grey-500":WPGMZA.StylingPage.PRESETS.default["--wpgmza-color-grey-500"],"--wpgmza-component-border-radius":"8px","--wpgmza-component-font-size":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-font-size"],"--wpgmza-component-backdrop-filter":"blur(20px)"},WPGMZA.StylingPage.PRESETS.rounded={"--wpgmza-component-color":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-color"],"--wpgmza-component-text-color":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color"],"--wpgmza-component-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-color-accent"],"--wpgmza-component-text-color-accent":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-text-color-accent"],"--wpgmza-color-grey-500":WPGMZA.StylingPage.PRESETS.default["--wpgmza-color-grey-500"],"--wpgmza-component-border-radius":"20px","--wpgmza-component-font-size":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-font-size"],"--wpgmza-component-backdrop-filter":WPGMZA.StylingPage.PRESETS.default["--wpgmza-component-backdrop-filter"]},WPGMZA.StylingPage.createInstance=function(){return new WPGMZA.StylingPage},WPGMZA.StylingPage.prototype.prepareControl=function(element){var element=$(element),input=element.find("input"),name=input.attr("name");if(""!==name.trim()){this.controls[name]={container:element,input:input};element=0<this.controls[name].input.length&&this.controls[name].input.get(0);if(element)if(element.wpgmzaColorInput){const colorInput=element.wpgmzaColorInput;colorInput.container&&(this.controls[name].resetButton=$("<div class='wpgmza-styling-editor-reset-btn' data-reset-control-name='"+name+"' />"),colorInput.container.prepend(this.controls[name].resetButton),colorInput.container.addClass("wpgmza-styling-editor-contains-reset"))}else if(element.wpgmzaCSSUnitInput){const unitInput=element.wpgmzaCSSUnitInput;unitInput.container&&(this.controls[name].resetButton=$("<div class='wpgmza-styling-editor-reset-btn' data-reset-control-name='"+name+"' />"),unitInput.container.prepend(this.controls[name].resetButton),unitInput.container.addClass("wpgmza-styling-editor-contains-reset"))}this.resetControl(this.controls[name])}},WPGMZA.StylingPage.prototype.bindEvents=function(){var name,self=this;for(name in this.controls)this.controls[name].input.on("change",function(){self.updateControl(this)});this.styleGuide.steps=this.styleGuide.wrapper.find(".wpgmza-style-guide-step").length,this.styleGuide.index=0,this.styleGuide.wrapper.find(".wpgmza-style-guide-nav .prev-btn").on("click",function(){--self.styleGuide.index,self.styleGuide.index<0&&(self.styleGuide.index=self.styleGuide.steps-1),self.styleGuide.wrapper.trigger("update-view")}),this.styleGuide.wrapper.find(".wpgmza-style-guide-nav .next-btn").on("click",function(){self.styleGuide.index+=1,self.styleGuide.index>=self.styleGuide.steps&&(self.styleGuide.index=0),self.styleGuide.wrapper.trigger("update-view")}),this.styleGuide.wrapper.on("update-view",function(){self.styleGuide.wrapper.find(".wpgmza-style-guide-step").removeClass("active"),self.styleGuide.wrapper.find(".wpgmza-style-guide-step:nth-child("+(self.styleGuide.index+1)+")").addClass("active")}),$(document.body).on("click",".wpgmza-styling-editor-reset-btn",function(){$(this);var field=$(this).data("reset-control-name");field&&self.controls[field]&&self.resetControl(self.controls[field])})},WPGMZA.StylingPage.prototype.updateControl=function(input){var name=$(input).attr("name");name&&-1!==name.indexOf("--")&&$(".wpgmza-styling-preview-wrap .wpgmza_map").css(name,$(input).val())},WPGMZA.StylingPage.prototype.resetControl=function(control){var name=control.input.attr("name");if(name&&-1!==name.indexOf("--")&&(name=$(":root").css(name))){var name=name.trim(),activeInput=0<control.input.length&&control.input.get(0);if(activeInput)if(activeInput.wpgmzaColorInput){const colorInput=activeInput.wpgmzaColorInput;colorInput.parseColor(name)}else if(activeInput.wpgmzaCSSUnitInput){const unitInput=activeInput.wpgmzaCSSUnitInput;unitInput.parseUnits(name)}else if(activeInput.wpgmzaCSSBackdropFilterInput){const backdropInput=activeInput.wpgmzaCSSBackdropFilterInput;backdropInput.parseFilters(name)}else control.input.val(name)}},WPGMZA.StylingPage.prototype.parseUserPreset=function(){WPGMZA.stylingSettings&&WPGMZA.stylingSettings instanceof Object&&0<Object.keys(WPGMZA.stylingSettings).length&&(WPGMZA.StylingPage.PRESETS.user=WPGMZA.stylingSettings,$(".wpgmza-styling-preset-select").append("<option value='user'>User Defined</option>"),$(".wpgmza-styling-preset-select").val("user").trigger("change"))},WPGMZA.StylingPage.prototype.applyPreset=function(element){element=(element=$(element)).val();if(element&&WPGMZA.StylingPage.PRESETS[element]){var fieldName,preset=WPGMZA.StylingPage.PRESETS[element];for(fieldName in preset){var fieldValue=preset[fieldName];let field=$(this.element).find('input[name="'+fieldName+'"]');0<field.length&&((field=field.get(0)).wpgmzaColorInput?field.wpgmzaColorInput.parseColor(fieldValue):field.wpgmzaCSSUnitInput?field.wpgmzaCSSUnitInput.parseUnits(fieldValue):field.wpgmzaCSSBackdropFilterInput?field.wpgmzaCSSBackdropFilterInput.parseFilters(fieldValue):($(field).val(fieldValue),$(field).trigger("change")))}}},$(document).ready(function(event){WPGMZA.getCurrentPage()&&(WPGMZA.stylingPage=WPGMZA.StylingPage.createInstance())})}),jQuery(function($){WPGMZA.SupportPage=function(){$(".support-page").tabs(),$(".wpgmza-copy-sysinfo").on("click",function(){var info=$(".system-info").text();if(info.length){const temp=jQuery("<textarea>");$(document.body).append(temp),temp.val(info).select(),document.execCommand("copy"),temp.remove(),WPGMZA.notification("Info Copied")}})},WPGMZA.SupportPage.createInstance=function(){return new WPGMZA.SupportPage},$(document).ready(function(event){WPGMZA.getCurrentPage()===WPGMZA.PAGE_SUPPORT&&(WPGMZA.supportPage=WPGMZA.SupportPage.createInstance())})}),jQuery(function($){WPGMZA.Text=function(options){if(options)for(var name in options)this[name]=options[name]},WPGMZA.Text.createInstance=function(options){return new("open-layers"!==WPGMZA.settings.engine?WPGMZA.GoogleText:WPGMZA.OLText)(options)},WPGMZA.Text.prototype.setPosition=function(position){this.overlay&&this.overlay.setPosition(position)},WPGMZA.Text.prototype.setText=function(text){this.overlay&&this.overlay.setText(text)},WPGMZA.Text.prototype.setFontSize=function(size){this.overlay&&this.overlay.setFontSize(size)},WPGMZA.Text.prototype.setFillColor=function(color){this.overlay&&this.overlay.setFillColor(color)},WPGMZA.Text.prototype.setLineColor=function(color){this.overlay&&this.overlay.setLineColor(color)},WPGMZA.Text.prototype.setOpacity=function(opacity){this.overlay&&this.overlay.setOpacity(opacity)},WPGMZA.Text.prototype.remove=function(){this.overlay&&this.overlay.remove()},WPGMZA.Text.prototype.refresh=function(){}}),jQuery(function($){WPGMZA.ThemeEditor=function(){if(WPGMZA.EventDispatcher.call(this),this.element=$("#wpgmza-theme-editor"),"open-layers"==WPGMZA.settings.engine)return this.element.remove(),void(this.olThemeEditor=new WPGMZA.OLThemeEditor);this.element.length?(this.json=[{}],this.mapElement=WPGMZA.maps[0].element,this.element.appendTo("#wpgmza-map-theme-editor__holder"),$(window).on("scroll",function(event){}),setInterval(function(){},200),this.initHTML(),WPGMZA.themeEditor=this):console.warn("No element to initialise theme editor on")},WPGMZA.extend(WPGMZA.ThemeEditor,WPGMZA.EventDispatcher),WPGMZA.ThemeEditor.prototype.updatePosition=function(){},WPGMZA.ThemeEditor.features={all:[],administrative:["country","land_parcel","locality","neighborhood","province"],landscape:["man_made","natural","natural.landcover","natural.terrain"],poi:["attraction","business","government","medical","park","place_of_worship","school","sports_complex"],road:["arterial","highway","highway.controlled_access","local"],transit:["line","station","station.airport","station.bus","station.rail"],water:[]},WPGMZA.ThemeEditor.elements={all:[],geometry:["fill","stroke"],labels:["icon","text","text.fill","text.stroke"]},WPGMZA.ThemeEditor.prototype.parse=function(){$("#wpgmza_theme_editor_feature option, #wpgmza_theme_editor_element option").css("font-weight","normal"),$("#wpgmza_theme_editor_error").hide(),$("#wpgmza_theme_editor").show(),$("#wpgmza_theme_editor_do_hue").prop("checked",!1),$("#wpgmza_theme_editor_hue").val("#000000"),$("#wpgmza_theme_editor_lightness").val(""),$("#wpgmza_theme_editor_saturation").val(""),$("#wpgmza_theme_editor_gamma").val(""),$("#wpgmza_theme_editor_do_invert_lightness").prop("checked",!1),$("#wpgmza_theme_editor_visibility").val("inherit"),$("#wpgmza_theme_editor_do_color").prop("checked",!1),$("#wpgmza_theme_editor_color").val("#000000"),$("#wpgmza_theme_editor_weight").val("");var textarea=$('textarea[name="wpgmza_theme_data"]');if(this.refreshColorInputs(),!textarea.val()||textarea.val().length<1)this.json=[{}];else{try{this.json=$.parseJSON($('textarea[name="wpgmza_theme_data"]').val())}catch(e){return this.json=[{}],$("#wpgmza_theme_editor").hide(),void $("#wpgmza_theme_editor_error").show()}$.isArray(this.json)||(textarea=this.json,this.json=[],this.json.push(textarea)),this.highlightFeatures(),this.highlightElements(),this.loadElementStylers()}},WPGMZA.ThemeEditor.prototype.highlightFeatures=function(){$("#wpgmza_theme_editor_feature option").css("font-weight","normal"),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")?$('#wpgmza_theme_editor_feature option[value="'+v.featureType+'"]'):$('#wpgmza_theme_editor_feature option[value="all"]')).css("font-weight","bold")})},WPGMZA.ThemeEditor.prototype.highlightElements=function(){var feature=$("#wpgmza_theme_editor_feature").val();$("#wpgmza_theme_editor_element option").css("font-weight","normal"),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")&&v.featureType==feature||"all"==feature&&!v.hasOwnProperty("featureType"))&&(v.hasOwnProperty("elementType")?$('#wpgmza_theme_editor_element option[value="'+v.elementType+'"]'):$('#wpgmza_theme_editor_element option[value="all"]')).css("font-weight","bold")})},WPGMZA.ThemeEditor.prototype.loadElementStylers=function(){var feature=$("#wpgmza_theme_editor_feature").val(),element=$("#wpgmza_theme_editor_element").val();$("#wpgmza_theme_editor_do_hue").prop("checked",!1),$("#wpgmza_theme_editor_hue").val("#000000"),$("#wpgmza_theme_editor_lightness").val(""),$("#wpgmza_theme_editor_saturation").val(""),$("#wpgmza_theme_editor_gamma").val(""),$("#wpgmza_theme_editor_do_invert_lightness").prop("checked",!1),$("#wpgmza_theme_editor_visibility").val("inherit"),$("#wpgmza_theme_editor_do_color").prop("checked",!1),$("#wpgmza_theme_editor_color").val("#000000"),$("#wpgmza_theme_editor_weight").val(""),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")&&v.featureType==feature||"all"==feature&&!v.hasOwnProperty("featureType"))&&(v.hasOwnProperty("elementType")&&v.elementType==element||"all"==element&&!v.hasOwnProperty("elementType"))&&v.hasOwnProperty("stylers")&&$.isArray(v.stylers)&&0<v.stylers.length&&$.each(v.stylers,function(ii,vv){vv.hasOwnProperty("hue")&&($("#wpgmza_theme_editor_do_hue").prop("checked",!0),$("#wpgmza_theme_editor_hue").val(vv.hue)),vv.hasOwnProperty("lightness")&&$("#wpgmza_theme_editor_lightness").val(vv.lightness),vv.hasOwnProperty("saturation")&&$("#wpgmza_theme_editor_saturation").val(vv.xaturation),vv.hasOwnProperty("gamma")&&$("#wpgmza_theme_editor_gamma").val(vv.gamma),vv.hasOwnProperty("invert_lightness")&&$("#wpgmza_theme_editor_do_invert_lightness").prop("checked",!0),vv.hasOwnProperty("visibility")&&$("#wpgmza_theme_editor_visibility").val(vv.visibility),vv.hasOwnProperty("color")&&($("#wpgmza_theme_editor_do_color").prop("checked",!0),$("#wpgmza_theme_editor_color").val(vv.color)),vv.hasOwnProperty("weight")&&$("#wpgmza_theme_editor_weight").val(vv.weight)})}),this.refreshColorInputs()},WPGMZA.ThemeEditor.prototype.writeElementStylers=function(){var new_feature_element_stylers,feature=$("#wpgmza_theme_editor_feature").val(),element=$("#wpgmza_theme_editor_element").val(),indexJSON=null,stylers=[];"inherit"!=$("#wpgmza_theme_editor_visibility").val()&&stylers.push({visibility:$("#wpgmza_theme_editor_visibility").val()}),!0===$("#wpgmza_theme_editor_do_color").prop("checked")&&stylers.push({color:$("#wpgmza_theme_editor_color").val()}),!0===$("#wpgmza_theme_editor_do_hue").prop("checked")&&stylers.push({hue:$("#wpgmza_theme_editor_hue").val()}),0<$("#wpgmza_theme_editor_gamma").val().length&&stylers.push({gamma:parseFloat($("#wpgmza_theme_editor_gamma").val())}),0<$("#wpgmza_theme_editor_weight").val().length&&stylers.push({weight:parseFloat($("#wpgmza_theme_editor_weight").val())}),0<$("#wpgmza_theme_editor_saturation").val().length&&stylers.push({saturation:parseFloat($("#wpgmza_theme_editor_saturation").val())}),0<$("#wpgmza_theme_editor_lightness").val().length&&stylers.push({lightness:parseFloat($("#wpgmza_theme_editor_lightness").val())}),!0===$("#wpgmza_theme_editor_do_invert_lightness").prop("checked")&&stylers.push({invert_lightness:!0}),$.each(this.json,function(i,v){(v.hasOwnProperty("featureType")&&v.featureType==feature||"all"==feature&&!v.hasOwnProperty("featureType"))&&(v.hasOwnProperty("elementType")&&v.elementType==element||"all"==element&&!v.hasOwnProperty("elementType"))&&(indexJSON=i)}),null===indexJSON?0<stylers.length&&(new_feature_element_stylers={},"all"!=feature&&(new_feature_element_stylers.featureType=feature),"all"!=element&&(new_feature_element_stylers.elementType=element),new_feature_element_stylers.stylers=stylers,this.json.push(new_feature_element_stylers)):0<stylers.length?this.json[indexJSON].stylers=stylers:this.json.splice(indexJSON,1),$('textarea[name="wpgmza_theme_data"]').val(JSON.stringify(this.json).replace(/:/g,": ").replace(/,/g,", ")),this.highlightFeatures(),this.highlightElements(),WPGMZA.themePanel.updateMapTheme()},WPGMZA.ThemeEditor.prototype.initHTML=function(){var self=this;$.each(WPGMZA.ThemeEditor.features,function(i,v){$("#wpgmza_theme_editor_feature").append('<option value="'+i+'">'+i+"</option>"),0<v.length&&$.each(v,function(ii,vv){$("#wpgmza_theme_editor_feature").append('<option value="'+i+"."+vv+'">'+i+"."+vv+"</option>")})}),$.each(WPGMZA.ThemeEditor.elements,function(i,v){$("#wpgmza_theme_editor_element").append('<option value="'+i+'">'+i+"</option>"),0<v.length&&$.each(v,function(ii,vv){$("#wpgmza_theme_editor_element").append('<option value="'+i+"."+vv+'">'+i+"."+vv+"</option>")})}),this.parse(),$('textarea[name="wpgmza_theme_data"]').on("input selectionchange propertychange",function(){self.parse()}),$(".wpgmza_theme_selection").click(function(){setTimeout(function(){$('textarea[name="wpgmza_theme_data"]').trigger("input")},1e3)}),$("#wpgmza-theme-editor__toggle").click(function(){$("#wpgmza-theme-editor").removeClass("active")}),$("#wpgmza_theme_editor_feature").on("change",function(){self.highlightElements(),self.loadElementStylers()}),$("#wpgmza_theme_editor_element").on("change",function(){self.loadElementStylers()}),$("#wpgmza_theme_editor_do_hue, #wpgmza_theme_editor_hue, #wpgmza_theme_editor_lightness, #wpgmza_theme_editor_saturation, #wpgmza_theme_editor_gamma, #wpgmza_theme_editor_do_invert_lightness, #wpgmza_theme_editor_visibility, #wpgmza_theme_editor_do_color, #wpgmza_theme_editor_color, #wpgmza_theme_editor_weight").on("input selectionchange propertychange",function(){self.writeElementStylers()}),"open-layers"==WPGMZA.settings.engine&&$("#wpgmza_theme_editor :input").prop("disabled",!0)},WPGMZA.ThemeEditor.prototype.refreshColorInputs=function(){$("input#wpgmza_theme_editor_hue,input#wpgmza_theme_editor_color").each(function(){this.wpgmzaColorInput&&this.wpgmzaColorInput.parseColor(this.value)})}}),jQuery(function($){WPGMZA.ThemePanel=function(){var self=this;if(this.element=$("#wpgmza-theme-panel"),this.map=WPGMZA.maps[0],"open-layers"==WPGMZA.settings.engine)return this.element.remove(),void(this.olThemePanel=new WPGMZA.OLThemePanel);this.element.length?($("#wpgmza-theme-presets").owlCarousel({items:6,dots:!0}),this.element.on("click","#wpgmza-theme-presets label, .theme-selection-panel label",function(event){self.onThemePresetClick(event)}),$("#wpgmza-open-theme-editor").on("click",function(event){$("#wpgmza-map-theme-editor__holder").addClass("active"),$("#wpgmza-theme-editor").addClass("active"),WPGMZA.animateScroll($("#wpgmza-theme-editor"))}),WPGMZA.themePanel=this):console.warn("No element to initialise theme panel on")},WPGMZA.ThemePanel.previewImageCenter={lat:33.701806462148646,lng:-118.15949896058983},WPGMZA.ThemePanel.previewImageZoom=11,WPGMZA.ThemePanel.prototype.onThemePresetClick=function(event){var event=$(event.currentTarget).find("[data-theme-json]").attr("data-theme-json"),textarea=$("textarea[name='wpgmza_theme_data']"),existingData=textarea.val(),allPresetData=[];$(this.element).find("[data-theme-json]").each(function(index,el){allPresetData.push($(el).attr("data-theme-json"))}),existingData.length&&-1==allPresetData.indexOf(existingData)&&!confirm(WPGMZA.localized_strings.overwrite_theme_data)||(textarea.val(event),this.updateMapTheme(),WPGMZA.themeEditor.parse())},WPGMZA.ThemePanel.prototype.updateMapTheme=function(){var data;try{data=JSON.parse($("textarea[name='wpgmza_theme_data']").val())}catch(e){return void alert(WPGMZA.localized_strings.invalid_theme_data)}this.map.setOptions({styles:data})}}),jQuery(function($){WPGMZA.Version=function(){},WPGMZA.Version.GREATER_THAN=1,WPGMZA.Version.EQUAL_TO=0,WPGMZA.Version.LESS_THAN=-1,WPGMZA.Version.compare=function(v1,v2){for(var v1parts=v1.match(/\d+/g),v2parts=v2.match(/\d+/g),i=0;i<v1parts.length;++i){if(v2parts.length===i)return 1;if(v1parts[i]!==v2parts[i])return v1parts[i]>v2parts[i]?1:-1}return v1parts.length!=v2parts.length?-1:0}}),jQuery(function($){WPGMZA.XMLCacheConverter=function(){},WPGMZA.XMLCacheConverter.prototype.convert=function(xml){var markers=[],remap={marker_id:"id",linkd:"link"};return $(xml).find("marker").each(function(index,el){var data={};$(el).children().each(function(j,child){var key=child.nodeName;remap[key]&&(key=remap[key]),child.hasAttribute("data-json")?data[key]=JSON.parse($(child).text()):data[key]=$(child).text()}),markers.push(data)}),markers}}),jQuery(function($){WPGMZA.loadXMLAsWebWorker=function(){function tXml(a,d){function c(){for(var l=[];a[b];){if(60==a.charCodeAt(b)){if(47===a.charCodeAt(b+1)){b=a.indexOf(">",b);break}if(33===a.charCodeAt(b+1)){if(45==a.charCodeAt(b+2)){for(;62!==a.charCodeAt(b)||45!=a.charCodeAt(b-1)||45!=a.charCodeAt(b-2)||-1==b;)b=a.indexOf(">",b+1);-1===b&&(b=a.length)}else for(b+=2;62!==a.charCodeAt(b);)b++;b++;continue}var c=f();l.push(c)}else c=b,-2===(b=a.indexOf("<",b)-1)&&(b=a.length),0<(c=a.slice(c,b+1)).trim().length&&l.push(c);b++}return l}function l(){for(var c=b;-1===g.indexOf(a[b]);)b++;return a.slice(c,b)}function f(){var d={};b++,d.tagName=l();for(var f=!1;62!==a.charCodeAt(b);){if(64<(e=a.charCodeAt(b))&&e<91||96<e&&e<123){for(var h,g=l(),e=a.charCodeAt(b);39!==e&&34!==e&&!(64<e&&e<91||96<e&&e<123)&&62!==e;)b++,e=a.charCodeAt(b);f||(d.attributes={},f=!0),39===e||34===e?(e=a[b],h=++b,b=a.indexOf(e,h),e=a.slice(h,b)):(e=null,b--),d.attributes[g]=e}b++}return 47!==a.charCodeAt(b-1)&&("script"==d.tagName?(f=b+1,b=a.indexOf("<\/script>",b),d.children=[a.slice(f,b-1)],b+=8):"style"==d.tagName?(f=b+1,b=a.indexOf("</style>",b),d.children=[a.slice(f,b-1)],b+=7):-1==k.indexOf(d.tagName)&&(b++,d.children=c())),d}var b,g="\n\t>/= ",k=["img","br","input","meta","link"],h=null;return(d=d||{}).searchId?(-1===(b=new RegExp("s*ids*=s*['\"]"+d.searchId+"['\"]").exec(a).index)||-1!==(b=a.lastIndexOf("<",b))&&(h=f()),b):(b=0,h=c(),d.filter&&(h=tXml.filter(h,d.filter)),d.simplify?tXml.simplefy(h):h)}tXml.simplify=function(a){var c,d={};if(1===a.length&&"string"==typeof a[0])return a[0];for(c in a.forEach(function(a){var c;d[a.tagName]||(d[a.tagName]=[]),"object"==typeof a?(c=tXml.simplefy(a.children),d[a.tagName].push(c),a.attributes&&(c._attributes=a.attributes)):d[a.tagName].push(a)}),d)1==d[c].length&&(d[c]=d[c][0]);return d},tXml.filter=function(a,d){var c=[];return a.forEach(function(a){"object"==typeof a&&d(a)&&c.push(a),a.children&&(a=tXml.filter(a.children,d),c=c.concat(a))}),c},tXml.domToXml=function(a){var c="";return function d(a){if(a)for(var f=0;f<a.length;f++)if("string"==typeof a[f])c+=a[f].trim();else{var g=a[f],k=void(c+="<"+g.tagName);for(k in g.attributes)c=-1===g.attributes[k].indexOf('"')?c+(" "+k+'="'+g.attributes[k].trim())+'"':c+(" "+k+"='"+g.attributes[k].trim())+"'";c+=">",d(g.children),c+="</"+g.tagName+">"}}(O),c},"object"!=typeof window&&(module.exports=tXml);var inputData,totalFiles,worker=self,dataForMainThread=[],filesLoaded=0;function onXMLLoaded(request){4==request.readyState&&200==request.status&&((new Date).getTime(),function(xml){for(var markers=xml[0].children[0],remap={marker_id:"id",linkd:"link"},i=0;i<markers.children.length;i++){var data={};markers.children[i].children.forEach(function(node){var key=node.tagName;remap[key]&&(key=remap[key]),node.attributes["data-json"]?data[key]=JSON.parse(node.children[0]):node.children.length?data[key]=node.children[0]:data[key]=""}),dataForMainThread.push(data)}}(tXml(request.responseText)),++filesLoaded>=totalFiles?worker.postMessage(dataForMainThread):loadNextFile())}function loadNextFile(){var url=inputData.urls[filesLoaded],request=new XMLHttpRequest;request.onreadystatechange=function(){onXMLLoaded(this)},request.open("GET",inputData.protocol+url,!0),request.send()}self.addEventListener("message",function(event){event=event.data;if("load"!==event.command)throw new Error("Unknown command");dataForMainThread=[],filesLoaded=0,totalFiles=(inputData=event).urls.length,loadNextFile()},!1)}}),jQuery(function($){WPGMZA.Integration={},WPGMZA.integrationModules={},WPGMZA.Integration.Blocks={},WPGMZA.Integration.Blocks.instances={}}),jQuery(function($){var __,registerBlockType,InspectorControls,_wp$editor,Dashicon,PanelBody;window.wp&&wp.i18n&&wp.blocks&&wp.editor&&wp.components&&(__=wp.i18n.__,registerBlockType=wp.blocks.registerBlockType,_wp$editor=wp.editor,InspectorControls=_wp$editor.InspectorControls,_wp$editor.BlockControls,_wp$editor=wp.components,Dashicon=_wp$editor.Dashicon,_wp$editor.Toolbar,_wp$editor.Button,_wp$editor.Tooltip,PanelBody=_wp$editor.PanelBody,_wp$editor.TextareaControl,_wp$editor.CheckboxControl,_wp$editor.TextControl,_wp$editor.SelectControl,_wp$editor.RichText,WPGMZA.Integration.Gutenberg=function(){registerBlockType("gutenberg-wpgmza/block",this.getBlockDefinition())},WPGMZA.Integration.Gutenberg.prototype.getBlockTitle=function(){return __("WP Go Maps")},WPGMZA.Integration.Gutenberg.prototype.getBlockInspectorControls=function(props){return React.createElement(InspectorControls,{key:"inspector"},React.createElement(PanelBody,{title:__("Map Settings")},React.createElement("p",{class:"map-block-gutenberg-button-container"},React.createElement("a",{href:WPGMZA.adminurl+"admin.php?page=wp-google-maps-menu&action=edit&map_id=1",target:"_blank",class:"button button-primary"},React.createElement("i",{class:"fa fa-pencil-square-o","aria-hidden":"true"}),__("Go to Map Editor"))),React.createElement("p",{class:"map-block-gutenberg-button-container"},React.createElement("a",{href:"https://www.wpgmaps.com/documentation/creating-your-first-map/",target:"_blank",class:"button button-primary"},React.createElement("i",{class:"fa fa-book","aria-hidden":"true"}),__("View Documentation")))))},WPGMZA.Integration.Gutenberg.prototype.getBlockAttributes=function(){return{}},WPGMZA.Integration.Gutenberg.prototype.getBlockDefinition=function(props){var _this=this;return{title:WPGMZA.InternalEngine.isLegacy()?__("WP Go Maps"):__("Map"),description:__("The easiest to use Google Maps plugin! Create custom Google Maps with high quality markers containing locations, descriptions, images and links. Add your customized map to your WordPress posts and/or pages quickly and easily with the supplied shortcode. No fuss."),category:!WPGMZA.InternalEngine.isLegacy()&&this.verifyCategory("wpgmza-gutenberg")?"wpgmza-gutenberg":"common",icon:"location-alt",keywords:[__("Map"),__("Maps"),__("Google")],attributes:this.getBlockAttributes(),edit:function(props){return[!!props.isSelected&&_this.getBlockInspectorControls(props),React.createElement("div",{className:props.className+" wpgmza-gutenberg-block"},React.createElement(Dashicon,{icon:"location-alt"}),React.createElement("span",{class:"wpgmza-gutenberg-block-title"},__("Your map will appear here on your websites front end")))]},save:function(props){return null}}},WPGMZA.Integration.Gutenberg.prototype.verifyCategory=function(category){if(wp.blocks&&wp.blocks.getCategories){var i,categories=wp.blocks.getCategories();for(i in categories)if(categories[i].slug===category)return!0}return!1},WPGMZA.Integration.Gutenberg.getConstructor=function(){return WPGMZA.Integration.Gutenberg},WPGMZA.Integration.Gutenberg.createInstance=function(){return new(WPGMZA.Integration.Gutenberg.getConstructor())},WPGMZA.isProVersion()||/^6/.test(WPGMZA.pro_version)||(WPGMZA.integrationModules.gutenberg=WPGMZA.Integration.Gutenberg.createInstance()))}),jQuery(function($){$(document).ready(function(event){var parent=document.body.onclick;parent&&(document.body.onclick=function(event){event.target instanceof WPGMZA.Marker||parent(event)})})}),jQuery(function($){WPGMZA.GoogleUICompatibility=function(){var style;navigator.vendor&&-1<navigator.vendor.indexOf("Apple")&&navigator.userAgent&&-1==navigator.userAgent.indexOf("CriOS")&&-1==navigator.userAgent.indexOf("FxiOS")||((style=$("<style id='wpgmza-google-ui-compatiblity-fix'/>")).html(".wpgmza_map img:not(button img) { padding:0 !important; }"),$(document.head).append(style))},WPGMZA.googleUICompatibility=new WPGMZA.GoogleUICompatibility}),jQuery(function($){var Parent=WPGMZA.Circle;WPGMZA.GoogleCircle=function(options,googleCircle){var self=this;Parent.call(this,options,googleCircle),googleCircle?(this.googleCircle=googleCircle,options&&(options.center=WPGMZA.LatLng.fromGoogleLatLng(googleCircle.getCenter()),options.radius=googleCircle.getRadius()/1e3)):(this.googleCircle=new google.maps.Circle,this.googleCircle.wpgmzaCircle=this),this.googleFeature=this.googleCircle,options&&this.setOptions(options),google.maps.event.addListener(this.googleCircle,"click",function(){self.dispatchEvent({type:"click"})})},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProCircle),WPGMZA.GoogleCircle.prototype=Object.create(Parent.prototype),WPGMZA.GoogleCircle.prototype.constructor=WPGMZA.GoogleCircle,WPGMZA.GoogleCircle.prototype.getCenter=function(){return WPGMZA.LatLng.fromGoogleLatLng(this.googleCircle.getCenter())},WPGMZA.GoogleCircle.prototype.setCenter=function(center){WPGMZA.Circle.prototype.setCenter.apply(this,arguments),this.googleCircle.setCenter(center)},WPGMZA.GoogleCircle.prototype.getRadius=function(){return this.googleCircle.getRadius()/1e3},WPGMZA.GoogleCircle.prototype.setRadius=function(radius){WPGMZA.Circle.prototype.setRadius.apply(this,arguments),this.googleCircle.setRadius(1e3*parseFloat(radius))},WPGMZA.GoogleCircle.prototype.setVisible=function(visible){this.googleCircle.setVisible(!!visible)},WPGMZA.GoogleCircle.prototype.setDraggable=function(value){this.googleCircle.setDraggable(!!value)},WPGMZA.GoogleCircle.prototype.setEditable=function(value){var self=this;this.googleCircle.setOptions({editable:value}),value&&(google.maps.event.addListener(this.googleCircle,"center_changed",function(event){self.center=WPGMZA.LatLng.fromGoogleLatLng(self.googleCircle.getCenter()),self.trigger("change")}),google.maps.event.addListener(this.googleCircle,"radius_changed",function(event){self.radius=self.googleCircle.getRadius()/1e3,self.trigger("change")}))},WPGMZA.GoogleCircle.prototype.setOptions=function(options){WPGMZA.Circle.prototype.setOptions.apply(this,arguments),options.center&&(this.center=new WPGMZA.LatLng(options.center))},WPGMZA.GoogleCircle.prototype.updateNativeFeature=function(){var googleOptions=this.getScalarProperties(),center=new WPGMZA.LatLng(this.center);googleOptions.radius*=1e3,googleOptions.center=center.toGoogleLatLng(),this.googleCircle.setOptions(googleOptions)}}),jQuery(function($){WPGMZA.GoogleDrawingManager=function(map){var self=this;WPGMZA.DrawingManager.call(this,map),this.mode=null,this.googleDrawingManager=new google.maps.drawing.DrawingManager({drawingControl:!1,polygonOptions:{editable:!0},polylineOptions:{editable:!0},circleOptions:{editable:!0},rectangleOptions:{draggable:!0,editable:!0,strokeWeight:1,fillOpacity:0}}),this.googleDrawingManager.setMap(map.googleMap),google.maps.event.addListener(this.googleDrawingManager,"polygoncomplete",function(polygon){self.onPolygonClosed(polygon)}),google.maps.event.addListener(this.googleDrawingManager,"polylinecomplete",function(polyline){self.onPolylineComplete(polyline)}),google.maps.event.addListener(this.googleDrawingManager,"circlecomplete",function(circle){self.onCircleComplete(circle)}),google.maps.event.addListener(this.googleDrawingManager,"rectanglecomplete",function(rectangle){self.onRectangleComplete(rectangle)})},WPGMZA.GoogleDrawingManager.prototype=Object.create(WPGMZA.DrawingManager.prototype),WPGMZA.GoogleDrawingManager.prototype.constructor=WPGMZA.GoogleDrawingManager,WPGMZA.GoogleDrawingManager.prototype.setDrawingMode=function(mode){var googleMode;switch(WPGMZA.DrawingManager.prototype.setDrawingMode.call(this,mode),mode){case WPGMZA.DrawingManager.MODE_NONE:case WPGMZA.DrawingManager.MODE_MARKER:googleMode=null;break;case WPGMZA.DrawingManager.MODE_POLYGON:googleMode=google.maps.drawing.OverlayType.POLYGON;break;case WPGMZA.DrawingManager.MODE_POLYLINE:googleMode=google.maps.drawing.OverlayType.POLYLINE;break;case WPGMZA.DrawingManager.MODE_CIRCLE:googleMode=google.maps.drawing.OverlayType.CIRCLE;break;case WPGMZA.DrawingManager.MODE_RECTANGLE:googleMode=google.maps.drawing.OverlayType.RECTANGLE;break;case WPGMZA.DrawingManager.MODE_HEATMAP:case WPGMZA.DrawingManager.MODE_POINTLABEL:googleMode=null;break;case WPGMZA.DrawingManager.MODE_IMAGEOVERLAY:googleMode=google.maps.drawing.OverlayType.RECTANGLE;break;default:throw new Error("Invalid drawing mode")}this.googleDrawingManager.setDrawingMode(googleMode)},WPGMZA.GoogleDrawingManager.prototype.setOptions=function(options){this.googleDrawingManager.setOptions({polygonOptions:options,polylineOptions:options})},WPGMZA.GoogleDrawingManager.prototype.onVertexClicked=function(event){},WPGMZA.GoogleDrawingManager.prototype.onPolygonClosed=function(googlePolygon){var event=new WPGMZA.Event("polygonclosed");event.enginePolygon=googlePolygon,this.dispatchEvent(event)},WPGMZA.GoogleDrawingManager.prototype.onPolylineComplete=function(googlePolyline){var event=new WPGMZA.Event("polylinecomplete");event.enginePolyline=googlePolyline,this.dispatchEvent(event)},WPGMZA.GoogleDrawingManager.prototype.onCircleComplete=function(googleCircle){var event=new WPGMZA.Event("circlecomplete");event.engineCircle=googleCircle,this.dispatchEvent(event)},WPGMZA.GoogleDrawingManager.prototype.onRectangleComplete=function(googleRectangle){var event;this.mode===WPGMZA.DrawingManager.MODE_IMAGEOVERLAY?this.onImageoverlayComplete(googleRectangle):((event=new WPGMZA.Event("rectanglecomplete")).engineRectangle=googleRectangle,this.dispatchEvent(event))},WPGMZA.GoogleDrawingManager.prototype.onHeatmapPointAdded=function(googleMarker){var position=WPGMZA.LatLng.fromGoogleLatLng(googleMarker.getPosition()),googleMarker=(googleMarker.setMap(null),WPGMZA.Marker.createInstance()),image=(googleMarker.setPosition(position),{url:WPGMZA.imageFolderURL+"heatmap-point.png",origin:new google.maps.Point(0,0),anchor:new google.maps.Point(13,13)}),image=(googleMarker.googleMarker.setIcon(image),this.map.addMarker(googleMarker),new WPGMZA.Event("heatmappointadded"));image.position=position,this.trigger(image)},WPGMZA.GoogleDrawingManager.prototype.onImageoverlayComplete=function(rectangle){var event=new WPGMZA.Event("imageoverlaycomplete");event.engineImageoverlay={googleRectangle:rectangle},this.dispatchEvent(event)}}),jQuery(function($){WPGMZA.GoogleGeocoder=function(){},WPGMZA.GoogleGeocoder.prototype=Object.create(WPGMZA.Geocoder.prototype),WPGMZA.GoogleGeocoder.prototype.constructor=WPGMZA.GoogleGeocoder,WPGMZA.GoogleGeocoder.prototype.getLatLngFromAddress=function(options,callback){if(options&&options.address)return options.lat&&options.lng&&(latLng={lat:options.lat,lng:options.lng},callback([{geometry:{location:latLng},latLng:latLng,lat:latLng.lat,lng:latLng.lng,bounds:null}],WPGMZA.Geocoder.SUCCESS)),WPGMZA.isLatLngString(options.address)?WPGMZA.Geocoder.prototype.getLatLngFromAddress.call(this,options,callback):(options.country&&(options.componentRestrictions={country:options.country}),void(new google.maps.Geocoder).geocode(options,function(results,status){var bounds,location;status==google.maps.GeocoderStatus.OK?(location={lat:(location=results[0].geometry.location).lat(),lng:location.lng()},bounds=null,results[0].geometry.bounds&&(bounds=WPGMZA.LatLngBounds.fromGoogleLatLngBounds(results[0].geometry.bounds)),callback(results=[{geometry:{location:location},latLng:location,lat:location.lat,lng:location.lng,bounds:bounds}],WPGMZA.Geocoder.SUCCESS)):(location=WPGMZA.Geocoder.FAIL,status==google.maps.GeocoderStatus.ZERO_RESULTS&&(location=WPGMZA.Geocoder.ZERO_RESULTS),callback(null,location))}));var latLng;nativeStatus=WPGMZA.Geocoder.NO_ADDRESS,callback(null,nativeStatus)},WPGMZA.GoogleGeocoder.prototype.getAddressFromLatLng=function(options,callback){if(!options||!options.latLng)throw new Error("No latLng specified");var latLng=new WPGMZA.LatLng(options.latLng),geocoder=new google.maps.Geocoder,options=$.extend(options,{location:{lat:latLng.lat,lng:latLng.lng}});let fullResult=!1;options.fullResult&&(fullResult=!0,delete options.fullResult),delete options.latLng,geocoder.geocode(options,function(results,status){"OK"!==status&&callback(null,WPGMZA.Geocoder.FAIL),results&&results.length||callback([],WPGMZA.Geocoder.NO_RESULTS),fullResult?callback([results[0]],WPGMZA.Geocoder.SUCCESS):callback([results[0].formatted_address],WPGMZA.Geocoder.SUCCESS)})}}),jQuery(function($){WPGMZA.settings.engine&&"google-maps"!=WPGMZA.settings.engine||window.google&&window.google.maps&&(WPGMZA.GoogleHTMLOverlay=function(map){this.element=$("<div class='wpgmza-google-html-overlay'></div>"),this.visible=!0,this.position=new WPGMZA.LatLng,this.setMap(map.googleMap),this.wpgmzaMap=map},WPGMZA.GoogleHTMLOverlay.prototype=new google.maps.OverlayView,WPGMZA.GoogleHTMLOverlay.prototype.onAdd=function(){this.getPanes().overlayMouseTarget.appendChild(this.element[0])},WPGMZA.GoogleHTMLOverlay.prototype.onRemove=function(){this.element&&$(this.element).parent().length&&($(this.element).remove(),this.element=null)},WPGMZA.GoogleHTMLOverlay.prototype.draw=function(){this.updateElementPosition()},WPGMZA.GoogleHTMLOverlay.prototype.updateElementPosition=function(){var projection=this.getProjection();projection&&(projection=projection.fromLatLngToDivPixel(this.position.toGoogleLatLng()),$(this.element).css({left:projection.x,top:projection.y}))})}),jQuery(function($){var Parent;WPGMZA.GoogleInfoWindow=function(feature){Parent.call(this,feature),this.setFeature(feature)},WPGMZA.GoogleInfoWindow.Z_INDEX=99,Parent=WPGMZA.isProVersion()?WPGMZA.ProInfoWindow:WPGMZA.InfoWindow,WPGMZA.GoogleInfoWindow.prototype=Object.create(Parent.prototype),WPGMZA.GoogleInfoWindow.prototype.constructor=WPGMZA.GoogleInfoWindow,WPGMZA.GoogleInfoWindow.prototype.setFeature=function(feature){(this.feature=feature)instanceof WPGMZA.Marker?this.googleObject=feature.googleMarker:feature instanceof WPGMZA.Polygon?this.googleObject=feature.googlePolygon:feature instanceof WPGMZA.Polyline&&(this.googleObject=feature.googlePolyline)},WPGMZA.GoogleInfoWindow.prototype.createGoogleInfoWindow=function(){var self=this;this.googleInfoWindow||(this.googleInfoWindow=new google.maps.InfoWindow,this.googleInfoWindow.setZIndex(WPGMZA.GoogleInfoWindow.Z_INDEX),google.maps.event.addListener(this.googleInfoWindow,"domready",function(event){self.trigger("domready")}),google.maps.event.addListener(this.googleInfoWindow,"closeclick",function(event){self.state!=WPGMZA.InfoWindow.STATE_CLOSED&&(self.state=WPGMZA.InfoWindow.STATE_CLOSED,self.feature.map.trigger("infowindowclose"))}))},WPGMZA.GoogleInfoWindow.prototype.open=function(map,feature){var self=this;if(!Parent.prototype.open.call(this,map,feature))return!1;this.parent=map,this.createGoogleInfoWindow(),this.setFeature(feature),void 0!==feature._osDisableAutoPan&&(feature._osDisableAutoPan?(this.googleInfoWindow.setOptions({disableAutoPan:!0}),feature._osDisableAutoPan=!1):this.googleInfoWindow.setOptions({disableAutoPan:!1})),this.googleInfoWindow.open(this.feature.map.googleMap,this.googleObject);var intervalID,guid=WPGMZA.guid(),map=WPGMZA.isProVersion()?"":this.addEditButton(),feature="<div id='"+guid+"'>"+map+" "+this.content+"</div>";return this.googleInfoWindow.setContent(feature),intervalID=setInterval(function(event){(div=$("#"+guid)).length&&(clearInterval(intervalID),div[0].wpgmzaFeature=self.feature,div.addClass("wpgmza-infowindow"),self.element=div[0],self.trigger("infowindowopen"))},50),!0},WPGMZA.GoogleInfoWindow.prototype.close=function(){this.googleInfoWindow&&(WPGMZA.InfoWindow.prototype.close.call(this),this.googleInfoWindow.close())},WPGMZA.GoogleInfoWindow.prototype.setContent=function(html){Parent.prototype.setContent.call(this,html),this.content=html,this.createGoogleInfoWindow(),this.googleInfoWindow.setContent(html)},WPGMZA.GoogleInfoWindow.prototype.setOptions=function(options){Parent.prototype.setOptions.call(this,options),this.createGoogleInfoWindow(),this.googleInfoWindow.setOptions(options)}}),jQuery(function($){var Parent;WPGMZA.GoogleMap=function(element,options){var self=this;Parent.call(this,element,options),this.loadGoogleMap(),options?this.setOptions(options,!0):this.setOptions({},!0),google.maps.event.addListener(this.googleMap,"click",function(event){var wpgmzaEvent=new WPGMZA.Event("click");wpgmzaEvent.latLng={lat:event.latLng.lat(),lng:event.latLng.lng()},self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap,"rightclick",function(event){var wpgmzaEvent=new WPGMZA.Event("rightclick");wpgmzaEvent.latLng={lat:event.latLng.lat(),lng:event.latLng.lng()},self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap,"dragend",function(event){self.dispatchEvent("dragend")}),google.maps.event.addListener(this.googleMap,"zoom_changed",function(event){self.dispatchEvent("zoom_changed"),self.dispatchEvent("zoomchanged")}),google.maps.event.addListener(this.googleMap,"idle",function(event){self.onIdle(event)}),this.googleMap.getStreetView()&&(google.maps.event.addListener(this.googleMap.getStreetView(),"visible_changed",function(){var wpgmzaEvent=new WPGMZA.Event("streetview_visible_changed");wpgmzaEvent.visible=this.getVisible(),self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap.getStreetView(),"position_changed",function(){var wpgmzaEvent=new WPGMZA.Event("streetview_position_changed");const position=this.getPosition();position&&(wpgmzaEvent.latLng={lat:position.lat(),lng:position.lng()}),wpgmzaEvent.visible=this.getVisible(),self.dispatchEvent(wpgmzaEvent)}),google.maps.event.addListener(this.googleMap.getStreetView(),"pov_changed",function(){var wpgmzaEvent=new WPGMZA.Event("streetview_pov_changed"),pov=this.getPov();pov&&(wpgmzaEvent.pov={heading:pov.heading,pitch:pov.pitch}),wpgmzaEvent.visible=this.getVisible(),self.dispatchEvent(wpgmzaEvent)})),WPGMZA.isProVersion()||(this.trigger("init"),this.dispatchEvent("created"),WPGMZA.events.dispatchEvent({type:"mapcreated",map:this}),$(this.element).trigger("wpgooglemaps_loaded"))},WPGMZA.isProVersion()?(Parent=WPGMZA.ProMap,WPGMZA.GoogleMap.prototype=Object.create(WPGMZA.ProMap.prototype)):(Parent=WPGMZA.Map,WPGMZA.GoogleMap.prototype=Object.create(WPGMZA.Map.prototype)),WPGMZA.GoogleMap.prototype.constructor=WPGMZA.GoogleMap,WPGMZA.GoogleMap.parseThemeData=function(raw){var json;try{json=JSON.parse(raw)}catch(e){try{json=eval(raw)}catch(e){var str=raw,str=str.replace(/\\'/g,"'");str=str.replace(/\\"/g,'"'),str=str.replace(/\\0/g,"\0"),str=str.replace(/\\\\/g,"\\");try{json=eval(str)}catch(e){return console.warn("Couldn't parse theme data"),[]}}}return json},WPGMZA.GoogleMap.prototype.loadGoogleMap=function(){var self=this,options=this.settings.toGoogleMapsOptions();this.googleMap=new google.maps.Map(this.engineElement,options),google.maps.event.addListener(this.googleMap,"bounds_changed",function(){self.onBoundsChanged()}),1==this.settings.bicycle&&this.enableBicycleLayer(!0),1==this.settings.traffic&&this.enableTrafficLayer(!0),this.settings.transport_layer&&this.enablePublicTransportLayer(!0),this.showPointsOfInterest(this.settings.wpgmza_show_point_of_interest),$(this.engineElement).append($(this.element).find(".wpgmza-loader"))},WPGMZA.GoogleMap.prototype.setOptions=function(options,initializing){Parent.prototype.setOptions.call(this,options),options.scrollwheel&&delete options.scrollwheel,initializing?(initializing=$.extend(options,this.settings.toGoogleMapsOptions()),!(initializing=$.extend({},initializing)).center instanceof google.maps.LatLng&&(initializing.center instanceof WPGMZA.LatLng||"object"==typeof initializing.center)&&(initializing.center={lat:parseFloat(initializing.center.lat),lng:parseFloat(initializing.center.lng)}),this.settings.hide_point_of_interest&&(initializing.styles||(initializing.styles=[]),initializing.styles.push({featureType:"poi",elementType:"labels",stylers:[{visibility:"off"}]})),this.googleMap.setOptions(initializing)):this.googleMap.setOptions(options)},WPGMZA.GoogleMap.prototype.addMarker=function(marker){marker.googleMarker.setMap(this.googleMap),Parent.prototype.addMarker.call(this,marker)},WPGMZA.GoogleMap.prototype.removeMarker=function(marker){marker.googleMarker.setMap(null),Parent.prototype.removeMarker.call(this,marker)},WPGMZA.GoogleMap.prototype.addPolygon=function(polygon){polygon.googlePolygon.setMap(this.googleMap),Parent.prototype.addPolygon.call(this,polygon)},WPGMZA.GoogleMap.prototype.removePolygon=function(polygon){polygon.googlePolygon.setMap(null),Parent.prototype.removePolygon.call(this,polygon)},WPGMZA.GoogleMap.prototype.addPolyline=function(polyline){polyline.googlePolyline.setMap(this.googleMap),Parent.prototype.addPolyline.call(this,polyline)},WPGMZA.GoogleMap.prototype.removePolyline=function(polyline){polyline.googlePolyline.setMap(null),Parent.prototype.removePolyline.call(this,polyline)},WPGMZA.GoogleMap.prototype.addCircle=function(circle){circle.googleCircle.setMap(this.googleMap),Parent.prototype.addCircle.call(this,circle)},WPGMZA.GoogleMap.prototype.removeCircle=function(circle){circle.googleCircle.setMap(null),Parent.prototype.removeCircle.call(this,circle)},WPGMZA.GoogleMap.prototype.addRectangle=function(rectangle){rectangle.googleRectangle.setMap(this.googleMap),Parent.prototype.addRectangle.call(this,rectangle)},WPGMZA.GoogleMap.prototype.removeRectangle=function(rectangle){rectangle.googleRectangle.setMap(null),Parent.prototype.removeRectangle.call(this,rectangle)},WPGMZA.GoogleMap.prototype.getCenter=function(){var latLng=this.googleMap.getCenter();return{lat:latLng.lat(),lng:latLng.lng()}},WPGMZA.GoogleMap.prototype.setCenter=function(latLng){WPGMZA.Map.prototype.setCenter.call(this,latLng),latLng instanceof WPGMZA.LatLng?this.googleMap.setCenter({lat:latLng.lat,lng:latLng.lng}):this.googleMap.setCenter(latLng)},WPGMZA.GoogleMap.prototype.panTo=function(latLng){latLng instanceof WPGMZA.LatLng?this.googleMap.panTo({lat:latLng.lat,lng:latLng.lng}):this.googleMap.panTo(latLng)},WPGMZA.GoogleMap.prototype.getZoom=function(){return this.googleMap.getZoom()},WPGMZA.GoogleMap.prototype.setZoom=function(value){if(isNaN(value))throw new Error("Value must not be NaN");return this.googleMap.setZoom(parseInt(value))},WPGMZA.GoogleMap.prototype.getBounds=function(){var nativeBounds=new WPGMZA.LatLngBounds({});try{var bounds=this.googleMap.getBounds(),northEast=bounds.getNorthEast(),southWest=bounds.getSouthWest();nativeBounds.north=northEast.lat(),nativeBounds.south=southWest.lat(),nativeBounds.west=southWest.lng(),nativeBounds.east=northEast.lng(),nativeBounds.topLeft={lat:northEast.lat(),lng:southWest.lng()},nativeBounds.bottomRight={lat:southWest.lat(),lng:northEast.lng()}}catch(ex){}return nativeBounds},WPGMZA.GoogleMap.prototype.fitBounds=function(southWest,northEast){southWest instanceof WPGMZA.LatLng&&(southWest={lat:southWest.lat,lng:southWest.lng}),northEast instanceof WPGMZA.LatLng?northEast={lat:northEast.lat,lng:northEast.lng}:southWest instanceof WPGMZA.LatLngBounds&&(southWest={lat:(bounds=southWest).south,lng:bounds.west},northEast={lat:bounds.north,lng:bounds.east});var bounds=new google.maps.LatLngBounds(southWest,northEast);this.googleMap.fitBounds(bounds)},WPGMZA.GoogleMap.prototype.fitBoundsToVisibleMarkers=function(){for(var bounds=new google.maps.LatLngBounds,i=0;i<this.markers.length;i++)markers[i].getVisible()&&bounds.extend(markers[i].getPosition());this.googleMap.fitBounds(bounds)},WPGMZA.GoogleMap.prototype.enableBicycleLayer=function(enable){this.bicycleLayer||(this.bicycleLayer=new google.maps.BicyclingLayer),this.bicycleLayer.setMap(enable?this.googleMap:null)},WPGMZA.GoogleMap.prototype.enableTrafficLayer=function(enable){this.trafficLayer||(this.trafficLayer=new google.maps.TrafficLayer),this.trafficLayer.setMap(enable?this.googleMap:null)},WPGMZA.GoogleMap.prototype.enablePublicTransportLayer=function(enable){this.publicTransportLayer||(this.publicTransportLayer=new google.maps.TransitLayer),this.publicTransportLayer.setMap(enable?this.googleMap:null)},WPGMZA.GoogleMap.prototype.showPointsOfInterest=function(show){var text=$("textarea[name='theme_data']").val();text&&((text=JSON.parse(text)).push({featureType:"poi",stylers:[{visibility:show?"on":"off"}]}),this.googleMap.setOptions({styles:text}))},WPGMZA.GoogleMap.prototype.getMinZoom=function(){return parseInt(this.settings.min_zoom)},WPGMZA.GoogleMap.prototype.setMinZoom=function(value){this.googleMap.setOptions({minZoom:value,maxZoom:this.getMaxZoom()})},WPGMZA.GoogleMap.prototype.getMaxZoom=function(){return parseInt(this.settings.max_zoom)},WPGMZA.GoogleMap.prototype.setMaxZoom=function(value){this.googleMap.setOptions({minZoom:this.getMinZoom(),maxZoom:value})},WPGMZA.GoogleMap.prototype.latLngToPixels=function(latLng){var map=this.googleMap,latLng=new google.maps.LatLng({lat:parseFloat(latLng.lat),lng:parseFloat(latLng.lng)}),topRight=map.getProjection().fromLatLngToPoint(map.getBounds().getNorthEast()),bottomLeft=map.getProjection().fromLatLngToPoint(map.getBounds().getSouthWest()),scale=Math.pow(2,map.getZoom()),map=map.getProjection().fromLatLngToPoint(latLng);return{x:(map.x-bottomLeft.x)*scale,y:(map.y-topRight.y)*scale}},WPGMZA.GoogleMap.prototype.pixelsToLatLng=function(x,y){null==y&&("x"in x&&"y"in x?(y=x.y,x=x.x):console.warn("Y coordinate undefined in pixelsToLatLng (did you mean to pass 2 arguments?)"));var map=this.googleMap,topRight=map.getProjection().fromLatLngToPoint(map.getBounds().getNorthEast()),bottomLeft=map.getProjection().fromLatLngToPoint(map.getBounds().getSouthWest()),scale=Math.pow(2,map.getZoom()),x=new google.maps.Point(x/scale+bottomLeft.x,y/scale+topRight.y),bottomLeft=map.getProjection().fromPointToLatLng(x);return{lat:bottomLeft.lat(),lng:bottomLeft.lng()}},WPGMZA.GoogleMap.prototype.onElementResized=function(event){this.googleMap&&google.maps.event.trigger(this.googleMap,"resize")},WPGMZA.GoogleMap.prototype.enableAllInteractions=function(){var options={scrollwheel:!0,draggable:!0,disableDoubleClickZoom:!1};this.googleMap.setOptions(options)},WPGMZA.GoogleMap.prototype.openStreetView=function(options){if(this.googleMap.getStreetView()){if(options&&(options.position&&options.position instanceof WPGMZA.LatLng&&this.googleMap.getStreetView().setPosition(options.position.toGoogleLatLng()),options.heading||options.pitch)){const pov={};options.heading&&(pov.heading=parseFloat(options.heading)),options.pitch&&(pov.pitch=parseFloat(options.pitch)),this.googleMap.getStreetView().setPov(pov)}this.googleMap.getStreetView().setVisible(!0)}},WPGMZA.GoogleMap.prototype.closeStreetView=function(){this.googleMap.getStreetView()&&this.googleMap.getStreetView().setVisible(!1)},WPGMZA.GoogleMap.prototype.isFullScreen=function(){return!(WPGMZA.Map.prototype.isFullScreen.call(this)||!WPGMZA.isFullScreen()||parseInt(window.screen.height)!==parseInt(this.element.firstChild.offsetHeight))},WPGMZA.GoogleMap.prototype.onFullScreenChange=function(fullscreen){if(fullscreen&&!this._stackedComponentsMoved&&this.element.firstChild){const innerContainer=this.element.firstChild;$(this.element).find(".wpgmza-inner-stack").each(function(index,element){$(element).appendTo(innerContainer)}),this._stackedComponentsMoved=!0}}}),jQuery(function($){var Parent;WPGMZA.GoogleMarker=function(options){var self=this,settings=(Parent.call(this,options),{});if(options)for(var name in options)options[name]instanceof WPGMZA.LatLng?settings[name]=options[name].toGoogleLatLng():options[name]instanceof WPGMZA.Map||"icon"==name||(settings[name]=options[name]);this.googleMarker=new google.maps.Marker(settings),(this.googleMarker.wpgmzaMarker=this).googleFeature=this.googleMarker,this.googleMarker.setPosition(new google.maps.LatLng({lat:parseFloat(this.lat),lng:parseFloat(this.lng)})),this.anim&&this.googleMarker.setAnimation(this.anim),this.animation&&this.googleMarker.setAnimation(this.animation),google.maps.event.addListener(this.googleMarker,"click",function(){self.dispatchEvent("click"),self.dispatchEvent("select")}),google.maps.event.addListener(this.googleMarker,"mouseover",function(){self.dispatchEvent("mouseover")}),google.maps.event.addListener(this.googleMarker,"mouseout",function(){self.dispatchEvent("mouseout")}),google.maps.event.addListener(this.googleMarker,"dragend",function(){var googleMarkerPosition=self.googleMarker.getPosition();self.setPosition({lat:googleMarkerPosition.lat(),lng:googleMarkerPosition.lng()}),self.dispatchEvent({type:"dragend",latLng:self.getPosition()}),self.trigger("change")}),this.setOptions(settings),this.trigger("init")},Parent=WPGMZA.isProVersion()?WPGMZA.ProMarker:WPGMZA.Marker,WPGMZA.GoogleMarker.prototype=Object.create(Parent.prototype),WPGMZA.GoogleMarker.prototype.constructor=WPGMZA.GoogleMarker,Object.defineProperty(WPGMZA.GoogleMarker.prototype,"opacity",{get:function(){return this._opacity},set:function(value){this._opacity=value,this.googleMarker.setOpacity(value)}}),WPGMZA.GoogleMarker.prototype.setLabel=function(label){label?(this.googleMarker.setLabel({text:label}),this.googleMarker.getIcon()||this.googleMarker.setIcon(WPGMZA.settings.default_marker_icon)):this.googleMarker.setLabel(null)},WPGMZA.GoogleMarker.prototype.setPosition=function(latLng){Parent.prototype.setPosition.call(this,latLng),this.googleMarker.setPosition({lat:this.lat,lng:this.lng})},WPGMZA.GoogleMarker.prototype.updateOffset=function(){var self=this,icon=this.googleMarker.getIcon(),img=new Image,x=this._offset.x,y=this._offset.y,params="string"==typeof(icon=icon||WPGMZA.settings.default_marker_icon)?{url:icon}:icon;img.onload=function(){var defaultAnchor_x=img.width/2,defaultAnchor_y=img.height;params.anchor=new google.maps.Point(defaultAnchor_x-x,defaultAnchor_y-y),self.googleMarker.setIcon(params)},img.src=params.url},WPGMZA.GoogleMarker.prototype.setOptions=function(options){this.googleMarker.setOptions(options)},WPGMZA.GoogleMarker.prototype.setAnimation=function(animation){Parent.prototype.setAnimation.call(this,animation),this.googleMarker.setAnimation(animation)},WPGMZA.GoogleMarker.prototype.setVisible=function(visible){Parent.prototype.setVisible.call(this,visible),this.googleMarker.setVisible(!!visible)},WPGMZA.GoogleMarker.prototype.getVisible=function(visible){return this.googleMarker.getVisible()},WPGMZA.GoogleMarker.prototype.setDraggable=function(draggable){this.googleMarker.setDraggable(draggable)},WPGMZA.GoogleMarker.prototype.setOpacity=function(opacity){this.googleMarker.setOpacity(opacity)}}),jQuery(function($){WPGMZA.GoogleModernStoreLocatorCircle=function(map,settings){var self=this;WPGMZA.ModernStoreLocatorCircle.call(this,map,settings),this.intervalID=setInterval(function(){var mapSize={width:$(self.mapElement).width(),height:$(self.mapElement).height()};mapSize.width==self.mapSize.width&&mapSize.height==self.mapSize.height||(self.canvasLayer.resize_(),self.canvasLayer.draw(),self.mapSize=mapSize)},1e3),$(document).bind("webkitfullscreenchange mozfullscreenchange fullscreenchange",function(){self.canvasLayer.resize_(),self.canvasLayer.draw()})},WPGMZA.GoogleModernStoreLocatorCircle.prototype=Object.create(WPGMZA.ModernStoreLocatorCircle.prototype),WPGMZA.GoogleModernStoreLocatorCircle.prototype.constructor=WPGMZA.GoogleModernStoreLocatorCircle,WPGMZA.GoogleModernStoreLocatorCircle.prototype.initCanvasLayer=function(){var self=this;this.canvasLayer&&(this.canvasLayer.setMap(null),this.canvasLayer.setAnimate(!1)),this.canvasLayer=new CanvasLayer({map:this.map.googleMap,resizeHandler:function(event){self.onResize(event)},updateHandler:function(event){self.onUpdate(event)},animate:!0,resolutionScale:this.getResolutionScale()})},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setOptions=function(options){WPGMZA.ModernStoreLocatorCircle.prototype.setOptions.call(this,options),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setPosition=function(position){WPGMZA.ModernStoreLocatorCircle.prototype.setPosition.call(this,position),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setRadius=function(radius){WPGMZA.ModernStoreLocatorCircle.prototype.setRadius.call(this,radius),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getTransformedRadius=function(km){var spherical=google.maps.geometry.spherical,center=this.settings.center,equator=new WPGMZA.LatLng({lat:0,lng:0}),center=new WPGMZA.LatLng({lat:center.lat,lng:0}),equator=spherical.computeOffset(equator.toGoogleLatLng(),1e3*km,90),spherical=.006395*km*(spherical.computeOffset(center.toGoogleLatLng(),1e3*km,90).lng()/equator.lng());if(isNaN(spherical))throw new Error("here");return spherical},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getCanvasDimensions=function(){return{width:this.canvasLayer.canvas.width,height:this.canvasLayer.canvas.height}},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getWorldOriginOffset=function(){var position=this.map.googleMap.getProjection().fromLatLngToPoint(this.canvasLayer.getTopLeft());return{x:-position.x,y:-position.y}},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getCenterPixels=function(){var center=new WPGMZA.LatLng(this.settings.center);return this.map.googleMap.getProjection().fromLatLngToPoint(center.toGoogleLatLng())},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getContext=function(type){return this.canvasLayer.canvas.getContext("2d")},WPGMZA.GoogleModernStoreLocatorCircle.prototype.getScale=function(){return Math.pow(2,this.map.getZoom())*this.getResolutionScale()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.setVisible=function(visible){WPGMZA.ModernStoreLocatorCircle.prototype.setVisible.call(this,visible),this.canvasLayer.scheduleUpdate()},WPGMZA.GoogleModernStoreLocatorCircle.prototype.destroy=function(){this.canvasLayer.setMap(null),this.canvasLayer=null,clearInterval(this.intervalID)}}),jQuery(function($){WPGMZA.GoogleModernStoreLocator=function(map_id){var map=this.map=WPGMZA.getMapByID(map_id),map_id=(WPGMZA.ModernStoreLocator.call(this,map_id),map.settings.wpgmza_store_locator_restrict);this.addressInput=$(this.element).find(".addressInput, #addressInput")[0],this.addressInput&&map_id&&map_id.length,this.map.googleMap.controls[google.maps.ControlPosition.TOP_CENTER].push(this.element)},WPGMZA.GoogleModernStoreLocator.prototype=Object.create(WPGMZA.ModernStoreLocator.prototype),WPGMZA.GoogleModernStoreLocator.prototype.constructor=WPGMZA.GoogleModernStoreLocator}),jQuery(function($){var Parent;WPGMZA.GooglePointlabel=function(options,pointFeature){Parent.call(this,options,pointFeature),pointFeature&&pointFeature.textFeature?this.textFeature=pointFeature.textFeature:this.textFeature=new WPGMZA.Text.createInstance({text:"",map:this.map,position:this.getPosition()}),(this.googleFeature=this).setOptions(options)},Parent=WPGMZA.isProVersion()?WPGMZA.ProPointlabel:WPGMZA.Pointlabel,WPGMZA.extend(WPGMZA.GooglePointlabel,Parent),WPGMZA.GooglePointlabel.prototype.setOptions=function(options){options.name&&this.textFeature.setText(options.name)}}),jQuery(function($){var Parent;WPGMZA.GooglePolygon=function(options,googlePolygon){var self=this;Parent.call(this,options=options||{},googlePolygon),this.googlePolygon=googlePolygon||new google.maps.Polygon,this.googleFeature=this.googlePolygon,options&&options.polydata&&this.googlePolygon.setOptions({paths:this.parseGeometry(options.polydata)}),this.googlePolygon.wpgmzaPolygon=this,options&&this.setOptions(options),google.maps.event.addListener(this.googlePolygon,"click",function(){self.dispatchEvent({type:"click"})})},Parent=WPGMZA.isProVersion()?WPGMZA.ProPolygon:WPGMZA.Polygon,WPGMZA.GooglePolygon.prototype=Object.create(Parent.prototype),WPGMZA.GooglePolygon.prototype.constructor=WPGMZA.GooglePolygon,WPGMZA.GooglePolygon.prototype.updateNativeFeature=function(){this.googlePolygon.setOptions(this.getScalarProperties())},WPGMZA.GooglePolygon.prototype.getEditable=function(){return this.googlePolygon.getOptions().editable},WPGMZA.GooglePolygon.prototype.setEditable=function(value){var self=this;this.googlePolygon.setOptions({editable:value}),value&&(this.googlePolygon.getPaths().forEach(function(path,index){["insert_at","remove_at","set_at"].forEach(function(name){google.maps.event.addListener(path,name,function(){self.trigger("change")})})}),google.maps.event.addListener(this.googlePolygon,"dragend",function(event){self.trigger("change")}),google.maps.event.addListener(this.googlePolygon,"click",function(event){WPGMZA.altKeyDown&&(this.getPath().removeAt(event.vertex),self.trigger("change"))}))},WPGMZA.GooglePolygon.prototype.setDraggable=function(value){this.googlePolygon.setDraggable(value)},WPGMZA.GooglePolygon.prototype.getGeometry=function(){for(var result=[],path=this.googlePolygon.getPath(),i=0;i<path.getLength();i++){var latLng=path.getAt(i);result.push({lat:latLng.lat(),lng:latLng.lng()})}return result}}),jQuery(function($){WPGMZA.GooglePolyline=function(options,googlePolyline){var self=this;WPGMZA.Polyline.call(this,options,googlePolyline),this.googlePolyline=googlePolyline||new google.maps.Polyline(this.settings),this.googleFeature=this.googlePolyline,options&&options.polydata&&(googlePolyline=this.parseGeometry(options.polydata),this.googlePolyline.setPath(googlePolyline)),this.googlePolyline.wpgmzaPolyline=this,options&&this.setOptions(options),google.maps.event.addListener(this.googlePolyline,"click",function(){self.dispatchEvent({type:"click"})})},WPGMZA.GooglePolyline.prototype=Object.create(WPGMZA.Polyline.prototype),WPGMZA.GooglePolyline.prototype.constructor=WPGMZA.GooglePolyline,WPGMZA.GooglePolyline.prototype.updateNativeFeature=function(){this.googlePolyline.setOptions(this.getScalarProperties())},WPGMZA.GooglePolyline.prototype.setEditable=function(value){var path,self=this;this.googlePolyline.setOptions({editable:value}),value&&(path=this.googlePolyline.getPath(),["insert_at","remove_at","set_at"].forEach(function(name){google.maps.event.addListener(path,name,function(){self.trigger("change")})}),google.maps.event.addListener(this.googlePolyline,"dragend",function(event){self.trigger("change")}),google.maps.event.addListener(this.googlePolyline,"click",function(event){WPGMZA.altKeyDown&&(this.getPath().removeAt(event.vertex),self.trigger("change"))}))},WPGMZA.GooglePolyline.prototype.setDraggable=function(value){this.googlePolyline.setOptions({draggable:value})},WPGMZA.GooglePolyline.prototype.getGeometry=function(){for(var result=[],path=this.googlePolyline.getPath(),i=0;i<path.getLength();i++){var latLng=path.getAt(i);result.push({lat:latLng.lat(),lng:latLng.lng()})}return result}}),jQuery(function($){var Parent=WPGMZA.Rectangle;WPGMZA.GoogleRectangle=function(options,googleRectangle){var self=this;Parent.call(this,options=options||{},googleRectangle),googleRectangle?(this.googleRectangle=googleRectangle,this.cornerA=options.cornerA=new WPGMZA.LatLng({lat:googleRectangle.getBounds().getNorthEast().lat(),lng:googleRectangle.getBounds().getSouthWest().lng()}),this.cornerB=options.cornerB=new WPGMZA.LatLng({lat:googleRectangle.getBounds().getSouthWest().lat(),lng:googleRectangle.getBounds().getNorthEast().lng()})):(this.googleRectangle=new google.maps.Rectangle,this.googleRectangle.wpgmzaRectangle=this),this.googleFeature=this.googleRectangle,options&&this.setOptions(options),google.maps.event.addListener(this.googleRectangle,"click",function(){self.dispatchEvent({type:"click"})})},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProRectangle),WPGMZA.GoogleRectangle.prototype=Object.create(Parent.prototype),WPGMZA.GoogleRectangle.prototype.constructor=WPGMZA.GoogleRectangle,WPGMZA.GoogleRectangle.prototype.getBounds=function(){return WPGMZA.LatLngBounds.fromGoogleLatLngBounds(this.googleRectangle.getBounds())},WPGMZA.GoogleRectangle.prototype.setVisible=function(visible){this.googleRectangle.setVisible(!!visible)},WPGMZA.GoogleRectangle.prototype.setDraggable=function(value){this.googleRectangle.setDraggable(!!value)},WPGMZA.GoogleRectangle.prototype.setEditable=function(value){var self=this;this.googleRectangle.setEditable(!!value),value&&google.maps.event.addListener(this.googleRectangle,"bounds_changed",function(event){self.trigger("change")})},WPGMZA.GoogleRectangle.prototype.setOptions=function(options){WPGMZA.Rectangle.prototype.setOptions.apply(this,arguments),options.cornerA&&options.cornerB&&(this.cornerA=new WPGMZA.LatLng(options.cornerA),this.cornerB=new WPGMZA.LatLng(options.cornerB))},WPGMZA.GoogleRectangle.prototype.updateNativeFeature=function(){var googleOptions=this.getScalarProperties(),north=parseFloat(this.cornerA.lat),west=parseFloat(this.cornerA.lng),south=parseFloat(this.cornerB.lat),east=parseFloat(this.cornerB.lng);north&&west&&south&&east&&(googleOptions.bounds={north:north,west:west,south:south,east:east}),this.googleRectangle.setOptions(googleOptions)}}),jQuery(function($){WPGMZA.GoogleText=function(options){WPGMZA.Text.apply(this,arguments),this.overlay=new WPGMZA.GoogleTextOverlay(options)},WPGMZA.extend(WPGMZA.GoogleText,WPGMZA.Text)}),jQuery(function($){WPGMZA.GoogleTextOverlay=function(options){this.element=$("<div class='wpgmza-google-text-overlay'><div class='wpgmza-inner'></div></div>"),(options=options||{}).position&&(this.position=options.position),options.text&&this.element.find(".wpgmza-inner").text(options.text),options.map&&this.setMap(options.map.googleMap)},window.google&&google.maps&&google.maps.OverlayView&&(WPGMZA.GoogleTextOverlay.prototype=new google.maps.OverlayView),WPGMZA.GoogleTextOverlay.prototype.onAdd=function(){var position=this.getProjection().fromLatLngToDivPixel(this.position.toGoogleLatLng());this.element.css({position:"absolute",left:position.x+"px",top:position.y+"px",minWidth:"200px"}),this.getPanes().floatPane.appendChild(this.element[0])},WPGMZA.GoogleTextOverlay.prototype.draw=function(){var position=this.getProjection().fromLatLngToDivPixel(this.position.toGoogleLatLng());this.element.css({position:"absolute",left:position.x+"px",top:position.y+"px",minWidth:"200px"})},WPGMZA.GoogleTextOverlay.prototype.onRemove=function(){this.element.remove()},WPGMZA.GoogleTextOverlay.prototype.hide=function(){this.element.hide()},WPGMZA.GoogleTextOverlay.prototype.show=function(){this.element.show()},WPGMZA.GoogleTextOverlay.prototype.toggle=function(){this.element.is(":visible")?this.element.hide():this.element.show()},WPGMZA.GoogleTextOverlay.prototype.setPosition=function(position){this.position=position},WPGMZA.GoogleTextOverlay.prototype.setText=function(text){this.element.find(".wpgmza-inner").text(text)},WPGMZA.GoogleTextOverlay.prototype.setFontSize=function(size){size=parseInt(size),this.element.find(".wpgmza-inner").css("font-size",size+"px")},WPGMZA.GoogleTextOverlay.prototype.setFillColor=function(color){color.match(/^#/)||(color="#"+color),this.element.find(".wpgmza-inner").css("color",color)},WPGMZA.GoogleTextOverlay.prototype.setLineColor=function(color){color.match(/^#/)||(color="#"+color),this.element.find(".wpgmza-inner").css("--wpgmza-color-white",color)},WPGMZA.GoogleTextOverlay.prototype.setOpacity=function(opacity){1<(opacity=parseFloat(opacity))?opacity=1:opacity<0&&(opacity=0),this.element.find(".wpgmza-inner").css("opacity",opacity)},WPGMZA.GoogleTextOverlay.prototype.remove=function(){this.element&&this.element.remove()}}),jQuery(function($){"google-maps"!=WPGMZA.settings.engine||WPGMZA.googleAPIStatus&&"USER_CONSENT_NOT_GIVEN"==WPGMZA.googleAPIStatus.code||(WPGMZA.GoogleVertexContextMenu=function(mapEditPage){var self=this;this.mapEditPage=mapEditPage,this.element=document.createElement("div"),this.element.className="wpgmza-vertex-context-menu",this.element.innerHTML="Delete",google.maps.event.addDomListener(this.element,"click",function(event){return self.removeVertex(),event.preventDefault(),event.stopPropagation(),!1})},WPGMZA.GoogleVertexContextMenu.prototype=new google.maps.OverlayView,WPGMZA.GoogleVertexContextMenu.prototype.onAdd=function(){var self=this,map=this.getMap();this.getPanes().floatPane.appendChild(this.element),this.divListener=google.maps.event.addDomListener(map.getDiv(),"mousedown",function(e){e.target!=self.element&&self.close()},!0)},WPGMZA.GoogleVertexContextMenu.prototype.onRemove=function(){google.maps.event.removeListener(this.divListener),this.element.parentNode.removeChild(this.element),this.set("position"),this.set("path"),this.set("vertex")},WPGMZA.GoogleVertexContextMenu.prototype.open=function(map,path,vertex){this.set("position",path.getAt(vertex)),this.set("path",path),this.set("vertex",vertex),this.setMap(map),this.draw()},WPGMZA.GoogleVertexContextMenu.prototype.close=function(){this.setMap(null)},WPGMZA.GoogleVertexContextMenu.prototype.draw=function(){var position=this.get("position"),projection=this.getProjection();position&&projection&&(projection=projection.fromLatLngToDivPixel(position),this.element.style.top=projection.y+"px",this.element.style.left=projection.x+"px")},WPGMZA.GoogleVertexContextMenu.prototype.removeVertex=function(){var path=this.get("path"),vertex=this.get("vertex");path&&null!=vertex&&path.removeAt(vertex),this.close()})}),jQuery(function($){WPGMZA.FeaturePanel=function(element,mapEditPage){var self=this;WPGMZA.EventDispatcher.apply(this,arguments),this.map=mapEditPage.map,this.drawingManager=mapEditPage.drawingManager,this.writersblock=!1,this.feature=null,this.element=element,this.initDefaults(),this.setMode(WPGMZA.FeaturePanel.MODE_ADD),this.drawingInstructionsElement=$(this.element).find(".wpgmza-feature-drawing-instructions"),this.drawingInstructionsElement.detach(),this.editingInstructionsElement=$(this.element).find(".wpgmza-feature-editing-instructions"),this.editingInstructionsElement.detach(),$("#wpgmaps_tabs_markers").on("tabsactivate",function(event,ui){$.contains(ui.newPanel[0],self.element[0])&&self.onTabActivated(event)}),$("#wpgmaps_tabs_markers").on("tabsactivate",function(event,ui){$.contains(ui.oldPanel[0],self.element[0])&&self.onTabDeactivated(event)}),$(".grouping").on("feature-block-opened",function(event){$(event.currentTarget).data("feature")===self.featureType?self.onTabActivated(event):self.onTabDeactivated(event)}),$(".grouping").on("feature-block-closed",function(event){self.onTabDeactivated(event),mapEditPage.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE)}),$(document.body).on("click","[data-edit-"+this.featureType+"-id]",function(event){self.onEditFeature(event)}),$(document.body).on("click","[data-delete-"+this.featureType+"-id]",function(event){self.onDeleteFeature(event)}),$(this.element).find(".wpgmza-save-feature").on("click",function(event){self.onSave(event)}),this.drawingManager.on(self.drawingManagerCompleteEvent,function(event){self.onDrawingComplete(event)}),this.drawingManager.on("drawingmodechanged",function(event){self.onDrawingModeChanged(event)}),$(this.element).on("change input",function(event){self.onPropertyChanged(event)})},WPGMZA.extend(WPGMZA.FeaturePanel,WPGMZA.EventDispatcher),WPGMZA.FeaturePanel.MODE_ADD="add",WPGMZA.FeaturePanel.MODE_EDIT="edit",WPGMZA.FeaturePanel.prevEditableFeature=null,Object.defineProperty(WPGMZA.FeaturePanel.prototype,"featureType",{get:function(){return $(this.element).attr("data-wpgmza-feature-type")}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"drawingManagerCompleteEvent",{get:function(){return this.featureType+"complete"}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"featureDataTable",{get:function(){return $("[data-wpgmza-datatable][data-wpgmza-feature-type='"+this.featureType+"']")[0].wpgmzaDataTable}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"featureAccordion",{get:function(){return $(this.element).closest(".wpgmza-accordion")}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"map",{get:function(){return WPGMZA.mapEditPage.map}}),Object.defineProperty(WPGMZA.FeaturePanel.prototype,"mode",{get:function(){return this._mode}}),WPGMZA.FeaturePanel.prototype.initPreloader=function(){this.preloader||(this.preloader=$(WPGMZA.preloaderHTML),this.preloader.hide(),$(this.element).append(this.preloader))},WPGMZA.FeaturePanel.prototype.initDataTable=function(){var el=$(this.element).find("[data-wpgmza-datatable][data-wpgmza-rest-api-route]");this[this.featureType+"AdminDataTable"]=new WPGMZA.AdminFeatureDataTable(el)},WPGMZA.FeaturePanel.prototype.initDefaults=function(){$(this.element).find("[data-ajax-name]:not([type='radio'])").each(function(index,el){var val=$(el).val();val&&$(el).attr("data-default-value",val)})},WPGMZA.FeaturePanel.prototype.setCaptionType=function(type,id){var icons={add:"fa-plus-circle",save:"fa-pencil-square-o"};switch(type){case WPGMZA.FeaturePanel.MODE_ADD:case WPGMZA.FeaturePanel.MODE_EDIT:this.featureAccordion.find("[data-add-caption][data-edit-caption]").each(function(index,el){var text=$(el).attr("data-"+type+"-caption"),icon=$(el).find("i.fa");id&&(text+=" "+id),$(el).text(text),icon.length&&((icon=$("<i class='fa' aria-hidden='true'></i>")).addClass(icons[type]),$(el).prepend(" "),$(el).prepend(icon))}),this.sidebarTriggerDelegate("feature-caption-loaded");break;default:throw new Error("Invalid type")}},WPGMZA.FeaturePanel.prototype.setMode=function(type,id){this._mode=type,this.setCaptionType(type,id)},WPGMZA.FeaturePanel.prototype.setTargetFeature=function(feature){var prev,self=this;WPGMZA.FeaturePanel.prevEditableFeature&&((prev=WPGMZA.FeaturePanel.prevEditableFeature).setEditable(!1),prev.setDraggable(!1),prev.off("change")),feature?(feature.setEditable(!0),feature.setDraggable(!0),feature.on("change",function(event){self.onFeatureChanged(event)}),this.setMode(WPGMZA.FeaturePanel.MODE_EDIT),this.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.showInstructions()):this.setMode(WPGMZA.FeaturePanel.MODE_ADD),this.feature=WPGMZA.FeaturePanel.prevEditableFeature=feature},WPGMZA.FeaturePanel.prototype.reset=function(){$(this.element).find("[data-ajax-name]:not([data-ajax-name='map_id']):not([type='color']):not([type='checkbox']):not([type='radio'])").val(""),$(this.element).find("select[data-ajax-name]>option:first-child").prop("selected",!0),$(this.element).find("[data-ajax-name='id']").val("-1"),$(this.element).find("input[type='checkbox']").prop("checked",!1),WPGMZA.InternalEngine.isLegacy()?tinyMCE.get("wpgmza-description-editor")?tinyMCE.get("wpgmza-description-editor").setContent(""):$("#wpgmza-description-editor").val(""):("undefined"!=typeof WritersBlock&&0!=this.writersblock&&this.writersblock.ready?(this.writersblock.setContent(""),this.writersblock.elements&&this.writersblock.elements._codeEditor&&(this.writersblock.elements._codeEditor.value="")):$("#wpgmza-description-editor").val(""),$(this.element).find("input.wpgmza-color-input").each(function(){this.wpgmzaColorInput&&this.wpgmzaColorInput.parseColor($(this).data("default-value")||this.value)})),$("#wpgmza-description-editor").val(""),$(this.element).find(".wpgmza-image-single-input").trigger("change"),this.showPreloader(!1),this.setMode(WPGMZA.FeaturePanel.MODE_ADD),$(this.element).find("[data-ajax-name][data-default-value]").each(function(index,el){$(el).val($(el).data("default-value"))})},WPGMZA.FeaturePanel.prototype.select=function(arg){var id,expectedBaseClass,self=this;if(this.reset(),$.isNumeric(arg))id=arg;else{if(expectedBaseClass=WPGMZA[WPGMZA.capitalizeWords(this.featureType)],!(feature instanceof expectedBaseClass))throw new Error("Invalid feature type for this panel");id=arg.id}this.showPreloader(!0),this.sidebarTriggerDelegate("edit"),WPGMZA.InternalEngine.isLegacy()&&WPGMZA.animateScroll($(".wpgmza_map")),WPGMZA.restAPI.call("/"+this.featureType+"s/"+id+"?skip_cache=1",{success:function(data,status,xhr){var functionSuffix=WPGMZA.capitalizeWords(self.featureType),functionSuffix=self.map["get"+functionSuffix+"ByID"](id);self.populate(data),self.showPreloader(!1),self.setMode(WPGMZA.FeaturePanel.MODE_EDIT,id),self.setTargetFeature(functionSuffix)}})},WPGMZA.FeaturePanel.prototype.showPreloader=function(show){this.initPreloader(),0==arguments.length||show?(this.preloader.fadeIn(),this.element.addClass("wpgmza-loading")):(this.preloader.fadeOut(),this.element.removeClass("wpgmza-loading"))},WPGMZA.FeaturePanel.prototype.populate=function(data){var value,target,name;for(name in data)switch(target=$(this.element).find("[data-ajax-name='"+name+"']"),value=data[name],(target.attr("type")||"").toLowerCase()){case"checkbox":case"radio":target.prop("checked",1==data[name]);break;case"color":value.match(/^#/)||(value="#"+value);default:if("object"==typeof value&&(value=JSON.stringify(value)),$(this.element).find("[data-ajax-name='"+name+"']:not(select)").val(value),$(this.element).find("[data-ajax-name='"+name+"']:not(select)").hasClass("wpgmza-color-input")){let colorInput=$(this.element).find("[data-ajax-name='"+name+"']:not(select)").get(0);colorInput.wpgmzaColorInput&&colorInput.wpgmzaColorInput.parseColor(colorInput.value)}if($(this.element).find("[data-ajax-name='"+name+"']:not(select)").hasClass("wpgmza-image-single-input")){let imageInputSingle=$(this.element).find("[data-ajax-name='"+name+"']:not(select)").get(0);imageInputSingle.wpgmzaImageInputSingle&&imageInputSingle.wpgmzaImageInputSingle.parseImage(imageInputSingle.value)}$(this.element).find("select[data-ajax-name='"+name+"']").each(function(index,el){"string"==typeof value&&0==data[name].length||$(el).val(value)})}},WPGMZA.FeaturePanel.prototype.serializeFormData=function(){var fields=$(this.element).find("[data-ajax-name]"),data={};return fields.each(function(index,el){var type="text";switch(type=$(el).attr("type")?$(el).attr("type").toLowerCase():type){case"checkbox":data[$(el).attr("data-ajax-name")]=$(el).prop("checked")?1:0;break;case"radio":$(el).prop("checked")&&(data[$(el).attr("data-ajax-name")]=$(el).val());break;default:data[$(el).attr("data-ajax-name")]=$(el).val()}}),data},WPGMZA.FeaturePanel.prototype.discardChanges=function(){var feature;this.feature&&(feature=this.feature,this.setTargetFeature(null),feature&&feature.map&&(this.map["remove"+WPGMZA.capitalizeWords(this.featureType)](feature),-1<feature.id&&this.updateFeatureByID(feature.id)))},WPGMZA.FeaturePanel.prototype.updateFeatureByID=function(id){var feature,self=this,route="/"+this.featureType+"s/",functionSuffix=WPGMZA.capitalizeWords(self.featureType),getByIDFunction="get"+functionSuffix+"ByID",removeFunction="remove"+functionSuffix,addFunction="add"+functionSuffix;WPGMZA.restAPI.call(route+id,{success:function(data,status,xhr){(feature=self.map[getByIDFunction](id))&&self.map[removeFunction](feature),feature=WPGMZA[WPGMZA.capitalizeWords(self.featureType)].createInstance(data),self.map[addFunction](feature)}})},WPGMZA.FeaturePanel.prototype.showInstructions=function(){this.mode===WPGMZA.FeaturePanel.MODE_ADD?WPGMZA.InternalEngine.isLegacy()?($(this.map.element).append(this.drawingInstructionsElement),$(this.drawingInstructionsElement).hide().fadeIn()):$(this.element).prepend(this.drawingInstructionsElement):WPGMZA.InternalEngine.isLegacy()?($(this.map.element).append(this.editingInstructionsElement),$(this.editingInstructionsElement).hide().fadeIn()):$(this.element).prepend(this.editingInstructionsElement)},WPGMZA.FeaturePanel.prototype.onTabActivated=function(){var featureString;this.reset(),this.drawingManager.setDrawingMode(this.featureType),this.onAddFeature(event),WPGMZA.InternalEngine.isLegacy()&&($(".wpgmza-table-container-title").hide(),$(".wpgmza-table-container").hide(),featureString=this.featureType.charAt(0).toUpperCase()+this.featureType.slice(1),$("#wpgmza-table-container-"+featureString).show(),$("#wpgmza-table-container-title-"+featureString).show())},WPGMZA.FeaturePanel.prototype.onTabDeactivated=function(){this.discardChanges(),this.setTargetFeature(null)},WPGMZA.FeaturePanel.prototype.onAddFeature=function(event){this.drawingManager.setDrawingMode(this.featureType)},WPGMZA.FeaturePanel.prototype.onEditFeature=function(event){var name="data-edit-"+this.featureType+"-id",event=$(event.currentTarget).attr(name);this.discardChanges(),this.select(event)},WPGMZA.FeaturePanel.prototype.onDeleteFeature=function(event){var self=this,name="data-delete-"+this.featureType+"-id",event=$(event.currentTarget).attr(name),name="/"+this.featureType+"s/",feature=this.map["get"+WPGMZA.capitalizeWords(this.featureType)+"ByID"](event);confirm(WPGMZA.localized_strings.general_delete_prompt_text)&&(this.featureDataTable.dataTable.processing(!0),WPGMZA.restAPI.call(name+event,{method:"DELETE",success:function(data,status,xhr){self.map["remove"+WPGMZA.capitalizeWords(self.featureType)](feature),self.featureDataTable.reload()}}))},WPGMZA.FeaturePanel.prototype.onDrawingModeChanged=function(event){$(this.drawingInstructionsElement).detach(),$(this.editingInstructionsElement).detach(),this.drawingManager.mode==this.featureType&&this.showInstructions()},WPGMZA.FeaturePanel.prototype.onDrawingComplete=function(event){var event=event["engine"+WPGMZA.capitalizeWords(this.featureType)],formData=this.serializeFormData(),geometryField=$(this.element).find("textarea[data-ajax-name$='data']"),formData=(delete formData.polydata,WPGMZA[WPGMZA.capitalizeWords(this.featureType)].createInstance(formData,event));this.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.map["add"+WPGMZA.capitalizeWords(this.featureType)](formData),this.setTargetFeature(formData),geometryField.length&&geometryField.val(JSON.stringify(formData.getGeometry())),this.featureType},WPGMZA.FeaturePanel.prototype.onPropertyChanged=function(event){var feature=this.feature;feature&&(feature._dirtyFields||(feature._dirtyFields=[]),$(this.element).find(":input[data-ajax-name]").each(function(index,el){var key=$(el).attr("data-ajax-name");feature[key]&&-1===feature._dirtyFields.indexOf(key)&&feature[key]!==$(el).val()&&feature._dirtyFields.push(key),feature[key]=$(el).val()}),feature.updateNativeFeature())},WPGMZA.FeaturePanel.prototype.onFeatureChanged=function(event){var geometryField=$(this.element).find("textarea[data-ajax-name$='data']");geometryField.length&&geometryField.val(JSON.stringify(this.feature.getGeometry()))},WPGMZA.FeaturePanel.prototype.onSave=function(event){WPGMZA.EmbeddedMedia.detatchAll();var self=this,id=$(self.element).find("[data-ajax-name='id']").val(),data=this.serializeFormData(),route="/"+this.featureType+"s/",isNew=-1==id;"circle"!=this.featureType||data.center?"rectangle"!=this.featureType||data.cornerA?"polygon"!=this.featureType||data.polydata?"polyline"!=this.featureType||data.polydata?(isNew||(route+=id),WPGMZA.mapEditPage.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.showPreloader(!0),self.sidebarTriggerDelegate("busy"),WPGMZA.restAPI.call(route,{method:"POST",data:data,success:function(data,status,xhr){var functionSuffix=WPGMZA.capitalizeWords(self.featureType),removeFunction="remove"+functionSuffix,addFunction="add"+functionSuffix;(functionSuffix=self.map["get"+functionSuffix+"ByID"](id))&&self.map[removeFunction](functionSuffix),self.setTargetFeature(null),self.showPreloader(!1),functionSuffix=WPGMZA[WPGMZA.capitalizeWords(self.featureType)].createInstance(data),self.map[addFunction](functionSuffix),self.featureDataTable.reload(),self.onTabActivated(event),self.reset(),isNew?self.sidebarTriggerDelegate("created"):self.sidebarTriggerDelegate("saved"),WPGMZA.notification(WPGMZA.capitalizeWords(self.featureType)+" "+(isNew?"Added":"Saved"))}})):alert(WPGMZA.localized_strings.no_shape_polyline):alert(WPGMZA.localized_strings.no_shape_polygon):alert(WPGMZA.localized_strings.no_shape_rectangle):alert(WPGMZA.localized_strings.no_shape_circle)},WPGMZA.FeaturePanel.prototype.sidebarTriggerDelegate=function(type){type="sidebar-delegate-"+type;$(this.element).trigger({type:type,feature:this.featureType})},WPGMZA.FeaturePanel.prototype.initWritersBlock=function(element){!element||WPGMZA.InternalEngine.isLegacy()||"undefined"==typeof WritersBlock||(this.writersblock=new WritersBlock(element,this.getWritersBlockConfig()),this.writersblock.elements&&this.writersblock.elements.editor&&($(this.writersblock.elements.editor).on("click",".wpgmza-embedded-media",event=>{event.stopPropagation(),event.currentTarget&&(event.currentTarget.wpgmzaEmbeddedMedia||(event.currentTarget.wpgmzaEmbeddedMedia=WPGMZA.EmbeddedMedia.createInstance(event.currentTarget,this.writersblock.elements.editor)),event.currentTarget.wpgmzaEmbeddedMedia.onSelect())}),$(this.writersblock.elements.editor).on("media_resized",()=>{this.writersblock.onEditorChange()})))},WPGMZA.FeaturePanel.prototype.getWritersBlockConfig=function(){return{customTools:[{tag:"shared-blocks",tools:{"custom-media":{icon:"fa fa-file-image-o",title:"Upload Media",action:editor=>{"undefined"!=typeof wp&&void 0!==wp.media&&void 0!==WPGMZA.openMediaDialog&&WPGMZA.openMediaDialog((mediaId,mediaUrl,media)=>{if(mediaUrl)if(media.type)switch(media.type){case"image":editor.writeHtml(`<img class='wpgmza-embedded-media' src='${mediaUrl}' />`);break;case"video":editor.writeHtml(`<video class='wpgmza-embedded-media' controls src='${mediaUrl}'></video>`);break;case"audio":editor.writeHtml(`<audio controls src='${mediaUrl}'></audio>`)}else WPGMZA.notification("We couldn't determine the type of media being added")},{title:"Select media",button:{text:"Add media"},multiple:!1,library:{type:["video","image","audio"]}})}},"code-editor":{icon:"fa fa-code",title:"Code Editor (HTML)",action:editor=>{if(editor._codeEditorActive){if(editor.elements._codeEditor){editor.elements.editor.classList.remove("wpgmza-hidden"),editor.elements._codeEditor.classList.add("wpgmza-hidden");let toolbarItems=editor.elements.toolbar.querySelectorAll("a.tool");for(let tool of toolbarItems)"codeeditor"!==tool.getAttribute("data-value")?tool.classList.remove("wpgmza-writersblock-disabled"):tool.classList.remove("wpgmza-writersblock-hold-state");$(editor.elements._codeEditor).trigger("wpgmza-writersblock-code-edited")}editor._codeEditorActive=!1}else{var tool;editor.elements._codeEditor||(editor.elements._codeEditor=editor.createElement("textarea",["writersblock-wpgmza-code-editor"]),editor.elements._codeEditor.setAttribute("placeholder","\x3c!-- Add HTML Here --\x3e"),editor.elements.wrap.appendChild(editor.elements._codeEditor),editor.elements._codeEditor.__editor=editor,$(editor.elements._codeEditor).on("wpgmza-writersblock-code-edited",function(){const target=$(this).get(0);if(target.__editor){let editedHtml=target.__editor.elements._codeEditor.value;editedHtml=editedHtml.replaceAll("\n","");const validator=document.createElement("div");validator.innerHTML=editedHtml,validator.innerHTML===editedHtml&&(target.__editor.elements.editor.innerHTML=validator.innerHTML,target.__editor.onEditorChange())}}),$(editor.elements._codeEditor).on("change input",function(){$(this).trigger("wpgmza-writersblock-code-edited")})),editor.elements.editor.classList.add("wpgmza-hidden"),editor.elements._codeEditor.classList.remove("wpgmza-hidden");for(tool of editor.elements.toolbar.querySelectorAll("a.tool"))"codeeditor"!==tool.getAttribute("data-value")?tool.classList.add("wpgmza-writersblock-disabled"):tool.classList.add("wpgmza-writersblock-hold-state");if(editor.elements.editor.innerHTML&&0<editor.elements.editor.innerHTML.trim().length){let sourceHtml=editor.elements.editor.innerHTML;sourceHtml=sourceHtml.replaceAll(/<\/(\w+)>/g,"</$1>\n"),editor.elements._codeEditor.value=sourceHtml}editor._codeEditorActive=!0}}}}}],enabledTools:["p","h1","h2","createlink","unlink","bold","italic","underline","strikeThrough","justifyLeft","justifyCenter","justifyRight","insertUnorderedList","insertOrderedList","insertHorizontalRule","custom-media","code-editor"],events:{onUpdateSelection:packet=>{packet.instance&&setTimeout(()=>{const pingedSelection=window.getSelection();pingedSelection&&0===pingedSelection.toString().trim().length&&this.writersblock.hidePopupTools()},10)}}}},WPGMZA.FeaturePanel.prototype.hasDirtyField=function(field){if(this.feature&&this.feature._dirtyFields){if(this.feature._dirtyFields instanceof Array&&-1!==this.feature._dirtyFields.indexOf(field))return!0}else if(!this.feature)return!0;return!1}}),jQuery(function($){WPGMZA.MarkerPanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.MarkerPanel,WPGMZA.FeaturePanel),WPGMZA.MarkerPanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProMarkerPanel:WPGMZA.MarkerPanel)(element,mapEditPage)},WPGMZA.MarkerPanel.prototype.initDefaults=function(){var self=this;WPGMZA.FeaturePanel.prototype.initDefaults.apply(this,arguments),this.adjustSubMode=!1,WPGMZA.InternalEngine.isLegacy()&&this.onTabActivated(null),$(document.body).on("click","[data-adjust-"+this.featureType+"-id]",function(event){self.onAdjustFeature(event)}),$(document.body).on("click",".wpgmza_approve_btn",function(event){self.onApproveMarker(event)})},WPGMZA.MarkerPanel.prototype.onAdjustFeature=function(event){var name="data-adjust-"+this.featureType+"-id",event=$(event.currentTarget).attr(name);this.discardChanges(),this.adjustSubMode=!0,this.select(event)},WPGMZA.MarkerPanel.prototype.onApproveMarker=function(event){var self=this,event="/"+this.featureType+"s/"+$(event.currentTarget).attr("id");WPGMZA.restAPI.call(event,{method:"POST",data:{approved:"1"},success:function(data,status,xhr){self.featureDataTable.reload()}})},WPGMZA.MarkerPanel.prototype.onFeatureChanged=function(event){var aPos,pos;this.adjustSubMode?(aPos=this.feature.getPosition())&&($(this.element).find("[data-ajax-name='lat']").val(aPos.lat),$(this.element).find("[data-ajax-name='lng']").val(aPos.lng)):(aPos=$(this.element).find("input[data-ajax-name$='address']")).length&&(pos=this.feature.getPosition(),aPos.val(pos.lat+", "+pos.lng),aPos.trigger("change"))},WPGMZA.MarkerPanel.prototype.setTargetFeature=function(feature){var prev;WPGMZA.FeaturePanel.prevEditableFeature&&(prev=WPGMZA.FeaturePanel.prevEditableFeature).setOpacity&&prev.setOpacity(1),$(this.element).find("[data-ajax-name]").removeAttr("disabled"),$(this.element).find("fieldset").show(),$(this.element).find(".wpgmza-adjust-mode-notice").addClass("wpgmza-hidden"),$(this.element).find('[data-ajax-name="lat"]').attr("type","hidden"),$(this.element).find('[data-ajax-name="lng"]').attr("type","hidden"),$(this.element).find(".wpgmza-hide-in-adjust-mode").removeClass("wpgmza-hidden"),$(this.element).find(".wpgmza-show-in-adjust-mode").addClass("wpgmza-hidden"),feature?(feature.setOpacity&&feature.setOpacity(.7),feature.getMap().panTo(feature.getPosition()),this.adjustSubMode&&($(this.element).find("[data-ajax-name]").attr("disabled","disabled"),$(this.element).find("fieldset:not(.wpgmza-always-on)").hide(),$(this.element).find(".wpgmza-adjust-mode-notice").removeClass("wpgmza-hidden"),$(this.element).find('[data-ajax-name="lat"]').attr("type","text").removeAttr("disabled"),$(this.element).find('[data-ajax-name="lng"]').attr("type","text").removeAttr("disabled"),$(this.element).find(".wpgmza-hide-in-adjust-mode").addClass("wpgmza-hidden"),$(this.element).find(".wpgmza-show-in-adjust-mode").removeClass("wpgmza-hidden"))):this.adjustSubMode=!1,WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments)},WPGMZA.MarkerPanel.prototype.onSave=function(event){var self=this,geocoder=WPGMZA.Geocoder.createInstance(),geocodingData={address:$(this.element).find("[data-ajax-name='address']").val()},cloud_lat=(WPGMZA.mapEditPage.drawingManager.setDrawingMode(WPGMZA.DrawingManager.MODE_NONE),this.showPreloader(!0),!1),cloud_lng=!1,cloud_lat=(0<document.getElementsByName("lat").length&&(cloud_lat=document.getElementsByName("lat")[0].value),0<document.getElementsByName("lng").length&&(cloud_lng=document.getElementsByName("lng")[0].value),cloud_lat&&cloud_lng&&(WPGMZA_localized_data.settings.googleMapsApiKey&&""!==WPGMZA_localized_data.settings.googleMapsApiKey||(geocodingData.lat=parseFloat(cloud_lat),geocodingData.lng=parseFloat(cloud_lng))),!this.hasDirtyField("address"));this.adjustSubMode||cloud_lat?WPGMZA.FeaturePanel.prototype.onSave.apply(self,arguments):geocoder.geocode(geocodingData,function(results,status){switch(status){case WPGMZA.Geocoder.ZERO_RESULTS:return alert(WPGMZA.localized_strings.zero_results),void self.showPreloader(!1);case WPGMZA.Geocoder.SUCCESS:break;case WPGMZA.Geocoder.NO_ADDRESS:return alert(WPGMZA.localized_strings.no_address),void self.showPreloader(!1);default:WPGMZA.Geocoder.FAIL;return alert(WPGMZA.localized_strings.geocode_fail),void self.showPreloader(!1)}var result=results[0];$(self.element).find("[data-ajax-name='lat']").val(result.lat),$(self.element).find("[data-ajax-name='lng']").val(result.lng),WPGMZA.FeaturePanel.prototype.onSave.apply(self,arguments)}),WPGMZA.mapEditPage.map.resetBounds()}}),jQuery(function($){WPGMZA.CirclePanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.CirclePanel,WPGMZA.FeaturePanel),WPGMZA.CirclePanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProCirclePanel:WPGMZA.CirclePanel)(element,mapEditPage)},WPGMZA.CirclePanel.prototype.updateFields=function(){$(this.element).find("[data-ajax-name='center']").val(this.feature.getCenter().toString()),$(this.element).find("[data-ajax-name='radius']").val(this.feature.getRadius())},WPGMZA.CirclePanel.prototype.onDrawingComplete=function(event){WPGMZA.FeaturePanel.prototype.onDrawingComplete.apply(this,arguments),this.updateFields()},WPGMZA.CirclePanel.prototype.setTargetFeature=function(feature){WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments),feature&&this.updateFields()},WPGMZA.CirclePanel.prototype.onFeatureChanged=function(event){WPGMZA.FeaturePanel.prototype.onFeatureChanged.apply(this,arguments),this.updateFields()}});var wpgmza_autoCompleteDisabled=!1;jQuery(function($){"map-edit"==WPGMZA.currentPage&&(WPGMZA.MapEditPage=function(){var self=this,element=document.body,ajaxRequest=(WPGMZA.EventDispatcher.call(this),WPGMZA.settings.internalEngine&&!WPGMZA.InternalEngine.isLegacy()||$("#wpgmaps_options fieldset").wrapInner("<div class='wpgmza-flex'></div>"),this.themePanel=new WPGMZA.ThemePanel,this.themeEditor=new WPGMZA.ThemeEditor,this.sidebarGroupings=new WPGMZA.SidebarGroupings,this.map=WPGMZA.maps[0],(!WPGMZA.pro_version||WPGMZA.Version.compare(WPGMZA.pro_version,"8.1.0")>=WPGMZA.Version.EQUAL_TO)&&(this.drawingManager=WPGMZA.DrawingManager.createInstance(this.map)),this.initDataTables(),this.initFeaturePanels(),this.initJQueryUIControls(),"en"!==WPGMZA.locale&&(WPGMZA.InternalEngine.isLegacy()?$("#datatable_no_result_message,#datatable_search_string").parent():$("#datatable_no_result_message,#datatable_search_string")).parent().hide(),$("input.wpgmza-address").each(function(index,el){el.addressInput=WPGMZA.AddressInput.createInstance(el,self.map)}),$('#wpgmza-map-edit-page input[type="color"]').each(function(){var buttonClass=WPGMZA.InternalEngine.isLegacy()?"button-secondary":"wpgmza-button";$("<div class='"+buttonClass+" wpgmza-paste-color-btn' title='Paste a HEX color code'><i class='fa fa-clipboard' aria-hidden='true'></i></div>").insertAfter(this)}),jQuery("body").on("click",".wpgmza_ac_result",function(e){var index=jQuery(this).data("id"),lat=jQuery(this).data("lat"),lng=jQuery(this).data("lng"),index=jQuery("#wpgmza_item_address_"+index).html();jQuery("input[name='lat']").val(lat),jQuery("input[name='lng']").val(lng),jQuery("#wpgmza_add_address_map_editor").val(index),jQuery("#wpgmza_autocomplete_search_results").hide()}),jQuery("body").on("click",".wpgmza-paste-color-btn",function(){try{var colorBtn=$(this);if(!navigator||!navigator.clipboard||!navigator.clipboard.readText)return;navigator.clipboard.readText().then(function(textcopy){colorBtn.parent().find('input[type="color"]').val("#"+textcopy.replace("#","").trim())}).catch(function(err){console.error("WP Go Maps: Could not access clipboard",err)})}catch(c_ex){}}),jQuery("body").on("focusout","#wpgmza_add_address_map_editor",function(e){setTimeout(function(){jQuery("#wpgmza_autocomplete_search_results").fadeOut("slow")},500)}),!1),wpgmzaAjaxTimeout=!1,wpgmzaStartTyping=!1,wpgmzaKeyStrokeCount=1,wpgmzaAvgTimeBetweenStrokes=300,wpgmzaTotalTimeForKeyStrokes=0,wpgmzaTmp="",wpgmzaIdentifiedTypingSpeed=!1;$("body").on("keypress",".wpgmza-address",function(e){if("wpgmza_add_address_map_editor"==this.id&&!wpgmza_autoCompleteDisabled){var wpgmza_apikey=!1;if(WPGMZA_localized_data.settings.googleMapsApiKey&&""!==WPGMZA_localized_data.settings.googleMapsApiKey&&(wpgmza_apikey=WPGMZA_localized_data.settings.googleMapsApiKey),"Escape"===e.key||"Alt"===e.key||"Control"===e.key||"Option"===e.key||"Shift"===e.key||"ArrowLeft"===e.key||"ArrowRight"===e.key||"ArrowUp"===e.key||"ArrowDown"===e.key)$("#wpgmza_autocomplete_search_results").hide();else{if(!wpgmzaIdentifiedTypingSpeed)return e=new Date,clearTimeout(wpgmzaTmp),wpgmzaTmp=setTimeout(function(){wpgmzaStartTyping=!1,wpgmzaAvgTimeBetweenStrokes=300,wpgmzaTotalTimeForKeyStrokes=0},1500),wpgmzaStartTyping?1!=wpgmzaKeyStrokeCount&&(wpgmzaCurrentTimeBetweenStrokes=e.getTime()-wpgmzaStartTyping,wpgmzaTotalTimeForKeyStrokes+=wpgmzaCurrentTimeBetweenStrokes,wpgmzaAvgTimeBetweenStrokes=wpgmzaTotalTimeForKeyStrokes/(wpgmzaKeyStrokeCount-1),wpgmzaStartTyping=e.getTime(),3<=wpgmzaKeyStrokeCount&&(wpgmzaIdentifiedTypingSpeed=wpgmzaAvgTimeBetweenStrokes)):wpgmzaStartTyping=e.getTime(),void wpgmzaKeyStrokeCount++;clearTimeout(wpgmzaAjaxTimeout),$("#wpgmza_autocomplete_search_results").html('<div class="wpgmza-pad-5">Searching...</div>'),$("#wpgmza_autocomplete_search_results").show();e=jQuery(this).val();if(""!==e){!1!==ajaxRequest&&ajaxRequest.abort();var domain=window.location.hostname;if("localhost"===domain)try{var paths=window.location.pathname.match(/\/(.*?)\//);paths&&2<=paths.length&&paths[1]&&(domain+="-"+paths[1])}catch(ex){}var wpgmza_api_url="",wpgmza_api_url=wpgmza_apikey?"https://wpgmaps.us-3.evennode.com/api/v1/autocomplete?s="+e+"&d="+domain+"&hash="+WPGMZA_localized_data.siteHash+"&k="+wpgmza_apikey:"https://wpgmaps.us-3.evennode.com/api/v1/autocomplete?s="+e+"&d="+domain+"&hash="+WPGMZA_localized_data.siteHash;WPGMZA&&WPGMZA.settings&&WPGMZA.settings.engine&&(wpgmza_api_url+="&engine="+WPGMZA.settings.engine),wpgmzaAjaxTimeout=setTimeout(function(){ajaxRequest=$.ajax({url:wpgmza_api_url,type:"GET",dataType:"json",success:function(results){try{if(void 0!==results.error)"error1"==results.error?($("#wpgmza_autoc_disabled").html(WPGMZA.localized_strings.cloud_api_key_error_1),$("#wpgmza_autoc_disabled").fadeIn("slow"),$("#wpgmza_autocomplete_search_results").hide(),wpgmza_autoCompleteDisabled=!0):console.error(results.error);else{$("#wpgmza_autocomplete_search_results").html("");var i,html="";for(i in results)html+="<div class='wpgmza_ac_result "+(""===html?"":"border-top")+"' data-id='"+i+"' data-lat='"+results[i].lat+"' data-lng='"+results[i].lng+"'><div class='wpgmza_ac_container'><div class='wpgmza_ac_icon'><img src='"+results[i].icon+"' /></div><div class='wpgmza_ac_item'><span id='wpgmza_item_name_"+i+"' class='wpgmza_item_name'>"+results[i].place_name+"</span><span id='wpgmza_item_address_"+i+"' class='wpgmza_item_address'>"+results[i].formatted_address+"</span></div></div></div>";""==html&&(html="<div class='p-2 text-center'><small>No results found...</small></div>"),$("#wpgmza_autocomplete_search_results").html(html),$("#wpgmza_autocomplete_search_results").show()}}catch(exception){console.error("WP Go Maps Plugin: There was an error returning the list of places for your search")}},error:function(){$("#wpgmza_autocomplete_search_results").hide()}})},2*wpgmzaIdentifiedTypingSpeed)}else $("#wpgmza_autocomplete_search_results").hide()}}}),$("#wpgmza_map_height_type").on("change",function(event){self.onMapHeightTypeChange(event)}),$("#advanced-markers .wpgmza-feature-drawing-instructions").remove(),$("[data-search-area='auto']").hide(),$(document.body).on("click","[data-wpgmza-admin-marker-datatable] input[name='mark']",function(event){self.onShiftClick(event)}),$("#wpgmza_map_type").on("change",function(event){self.onMapTypeChanged(event)}),$("body").on("click",".wpgmza_copy_shortcode",function(){var $temp=jQuery("<input>");jQuery('<span id="wpgmza_tmp" style="display:none; width:100%; text-align:center;">');jQuery("body").append($temp),$temp.val(jQuery(this).val()).select(),document.execCommand("copy"),$temp.remove(),WPGMZA.notification("Shortcode Copied")}),this.on("markerupdated",function(event){self.onMarkerUpdated(event)}),this.map&&(this.map.on("zoomchanged",function(event){self.onZoomChanged(event)}),this.map.on("boundschanged",function(event){self.onBoundsChanged(event)}),this.map.on("rightclick",function(event){self.onRightClick(event)})),$(element).on("click",".wpgmza_poly_del_btn",function(event){self.onDeletePolygon(event)}),$(element).on("click",".wpgmza_polyline_del_btn",function(event){self.onDeletePolyline(event)}),$(element).on("click",".wpgmza_dataset_del_btn",function(evevnt){self.onDeleteHeatmap(event)}),$(element).on("click",".wpgmza_circle_del_btn",function(event){self.onDeleteCircle(event)}),$(element).on("click",".wpgmza_rectangle_del_btn",function(event){self.onDeleteRectangle(event)}),$(element).on("click","#wpgmza-open-advanced-theme-data",function(event){event.preventDefault(),$(".wpgmza_theme_data_container").toggleClass("wpgmza_hidden")}),$(element).on("click",".wpgmza-shortcode-button",function(event){event.preventDefault(),$(element).find(".wpgmza-shortcode-description").addClass("wpgmza-hidden");const nearestRow=$(this).closest(".wpgmza-row");if(nearestRow.length){const nearestHint=nearestRow.next(".wpgmza-shortcode-description");nearestHint.length&&nearestHint.removeClass("wpgmza-hidden")}event=$(this).text();if(event.length){const temp=jQuery("<input>");$(document.body).append(temp),temp.val(event).select(),document.execCommand("copy"),temp.remove(),WPGMZA.notification("Shortcode Copied")}})},WPGMZA.extend(WPGMZA.MapEditPage,WPGMZA.EventDispatcher),WPGMZA.MapEditPage.createInstance=function(){return new(WPGMZA.isProVersion()&&WPGMZA.Version.compare(WPGMZA.pro_version,"8.0.0")>=WPGMZA.Version.EQUAL_TO?WPGMZA.ProMapEditPage:WPGMZA.MapEditPage)},WPGMZA.MapEditPage.prototype.initDataTables=function(){var self=this;$("[data-wpgmza-datatable][data-wpgmza-rest-api-route]").each(function(index,el){var featureType=$(el).attr("data-wpgmza-feature-type");self[featureType+"AdminDataTable"]=new WPGMZA.AdminFeatureDataTable(el)})},WPGMZA.MapEditPage.prototype.initFeaturePanels=function(){var self=this;$(".wpgmza-feature-accordion[data-wpgmza-feature-type]").each(function(index,el){var featurePanelElement=$(el).find(".wpgmza-feature-panel-container > *"),el=$(el).attr("data-wpgmza-feature-type"),panelClassName=WPGMZA.capitalizeWords(el)+"Panel",panelClassName=WPGMZA[panelClassName].createInstance(featurePanelElement,self);self[el+"Panel"]=panelClassName})},WPGMZA.MapEditPage.prototype.initJQueryUIControls=function(){var mapContainer,self=this;$("#wpgmaps_tabs").tabs(),mapContainer=$("#wpgmza-map-container").detach(),$("#wpgmaps_tabs_markers").tabs(),$(".map_wrapper").prepend(mapContainer),$("#slider-range-max").slider({range:"max",min:1,max:21,value:$("input[name='map_start_zoom']").val(),slide:function(event,ui){$("input[name='map_start_zoom']").val(ui.value),self.map.setZoom(ui.value)}})},WPGMZA.MapEditPage.prototype.onShiftClick=function(event){var checkbox=event.currentTarget,checkbox=jQuery(checkbox).closest("tr");if(this.lastSelectedRow&&event.shiftKey){var event=this.lastSelectedRow.index(),currIndex=checkbox.index(),startIndex=Math.min(event,currIndex),endIndex=Math.max(event,currIndex),rows=jQuery("[data-wpgmza-admin-marker-datatable] tbody>tr");jQuery("[data-wpgmza-admin-marker-datatable] input[name='mark']").prop("checked",!1);for(var i=startIndex;i<=endIndex;i++)jQuery(rows[i]).find("input[name='mark']").prop("checked",!0)}this.lastSelectedRow=checkbox},WPGMZA.MapEditPage.prototype.onMapTypeChanged=function(event){if("open-layers"!=WPGMZA.settings.engine){var mapTypeId;switch(event.target.value){case"2":mapTypeId=google.maps.MapTypeId.SATELLITE;break;case"3":mapTypeId=google.maps.MapTypeId.HYBRID;break;case"4":mapTypeId=google.maps.MapTypeId.TERRAIN;break;default:mapTypeId=google.maps.MapTypeId.ROADMAP}this.map.setOptions({mapTypeId:mapTypeId})}},WPGMZA.MapEditPage.prototype.onMarkerUpdated=function(event){this.markerDataTable.reload()},WPGMZA.MapEditPage.prototype.onZoomChanged=function(event){$(".map_start_zoom").val(this.map.getZoom())},WPGMZA.MapEditPage.prototype.onBoundsChanged=function(event){var location=this.map.getCenter();$("#wpgmza_start_location").val(location.lat+","+location.lng),$("input[name='map_start_lat']").val(location.lat),$("input[name='map_start_lng']").val(location.lng),$("#wpgmza_start_zoom").val(this.map.getZoom()),$("#wpgmaps_save_reminder").show()},WPGMZA.MapEditPage.prototype.onMapHeightTypeChange=function(event){"%"==event.target.value&&$("#wpgmza_height_warning").show()},WPGMZA.MapEditPage.prototype.onRightClick=function(event){var marker,self=this;this.drawingManager&&this.drawingManager.mode!=WPGMZA.DrawingManager.MODE_MARKER||(this.rightClickMarker||(this.rightClickMarker=WPGMZA.Marker.createInstance({draggable:!0}),this.rightClickMarker.on("dragend",function(event){$(".wpgmza-marker-panel [data-ajax-name='address']").val(event.latLng.lat+", "+event.latLng.lng)}),this.map.on("click",function(event){self.rightClickMarker.setMap(null),$(".wpgmza-marker-panel [data-ajax-name='address']").val("")})),(marker=this.rightClickMarker).setPosition(event.latLng),marker.setMap(this.map),$(".wpgmza-marker-panel [data-ajax-name='address']").val(event.latLng.lat+", "+event.latLng.lng))},WPGMZA.MapEditPage.prototype.onDeletePolygon=function(event){var cur_id=parseInt($(this).attr("id")),data={action:"delete_poly",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,poly_id:cur_id};$.post(ajaxurl,data,function(response){WPGM_Path[cur_id].setMap(null),delete WPGM_PathData[cur_id],delete WPGM_Path[cur_id],$("#wpgmza_poly_holder").html(response)})},WPGMZA.MapEditPage.prototype.onDeletePolyline=function(event){var cur_id=$(this).attr("id"),data={action:"delete_polyline",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,poly_id:cur_id};$.post(ajaxurl,data,function(response){WPGM_PathLine[cur_id].setMap(null),delete WPGM_PathLineData[cur_id],delete WPGM_PathLine[cur_id],$("#wpgmza_polyline_holder").html(response)})},WPGMZA.MapEditPage.prototype.onDeleteHeatmap=function(event){var cur_id=$(this).attr("id"),data={action:"delete_dataset",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,poly_id:cur_id};$.post(ajaxurl,data,function(response){heatmap[cur_id].setMap(null),delete heatmap[cur_id],$("#wpgmza_heatmap_holder").html(response)})},WPGMZA.MapEditPage.prototype.onDeleteCircle=function(event){var circle_id=$(this).attr("id"),data={action:"delete_circle",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,circle_id:circle_id};$.post(ajaxurl,data,function(response){$("#tabs-m-5 table").replaceWith(response),circle_array.forEach(function(circle){if(circle.id==circle_id)return circle.setMap(null),!1})})},WPGMZA.MapEditPage.prototype.onDeleteRectangle=function(event){var rectangle_id=$(this).attr("id"),data={action:"delete_rectangle",security:wpgmza_legacy_map_edit_page_vars.ajax_nonce,map_id:this.map.id,rectangle_id:rectangle_id};$.post(ajaxurl,data,function(response){$("#tabs-m-6 table").replaceWith(response),rectangle_array.forEach(function(rectangle){if(rectangle.id==rectangle_id)return rectangle.setMap(null),!1})})},$(document).ready(function(event){WPGMZA.mapEditPage=WPGMZA.MapEditPage.createInstance()}))}),jQuery(function($){WPGMZA.PointlabelPanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.PointlabelPanel,WPGMZA.FeaturePanel),WPGMZA.PointlabelPanel.createInstance=function(element,mapEditPage){return new WPGMZA.PointlabelPanel(element,mapEditPage)},WPGMZA.PointlabelPanel.prototype.updateFields=function(){$(this.element).find("[data-ajax-name='center']").val(this.feature.getPosition().toString())},WPGMZA.PointlabelPanel.prototype.onDrawingComplete=function(event){WPGMZA.FeaturePanel.prototype.onDrawingComplete.apply(this,arguments),this.updateFields()},WPGMZA.PointlabelPanel.prototype.setTargetFeature=function(feature){WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments),feature&&this.updateFields()},WPGMZA.PointlabelPanel.prototype.onFeatureChanged=function(event){WPGMZA.FeaturePanel.prototype.onFeatureChanged.apply(this,arguments),this.updateFields()}}),jQuery(function($){WPGMZA.PolygonPanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.PolygonPanel,WPGMZA.FeaturePanel),WPGMZA.PolygonPanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProPolygonPanel:WPGMZA.PolygonPanel)(element,mapEditPage)},Object.defineProperty(WPGMZA.PolygonPanel.prototype,"drawingManagerCompleteEvent",{get:function(){return"polygonclosed"}})}),jQuery(function($){WPGMZA.PolylinePanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.PolylinePanel,WPGMZA.FeaturePanel),WPGMZA.PolylinePanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProPolylinePanel:WPGMZA.PolylinePanel)(element,mapEditPage)}}),jQuery(function($){WPGMZA.RectanglePanel=function(element,mapEditPage){WPGMZA.FeaturePanel.apply(this,arguments)},WPGMZA.extend(WPGMZA.RectanglePanel,WPGMZA.FeaturePanel),WPGMZA.RectanglePanel.createInstance=function(element,mapEditPage){return new(WPGMZA.isProVersion()?WPGMZA.ProRectanglePanel:WPGMZA.RectanglePanel)(element,mapEditPage)},WPGMZA.RectanglePanel.prototype.updateFields=function(){var bounds=this.feature.getBounds();bounds.north&&bounds.west&&bounds.south&&bounds.east&&($(this.element).find("[data-ajax-name='cornerA']").val(bounds.north+", "+bounds.west),$(this.element).find("[data-ajax-name='cornerB']").val(bounds.south+", "+bounds.east))},WPGMZA.RectanglePanel.prototype.setTargetFeature=function(feature){WPGMZA.FeaturePanel.prototype.setTargetFeature.apply(this,arguments),feature&&this.updateFields()},WPGMZA.RectanglePanel.prototype.onDrawingComplete=function(event){WPGMZA.FeaturePanel.prototype.onDrawingComplete.apply(this,arguments),this.updateFields()},WPGMZA.RectanglePanel.prototype.onFeatureChanged=function(event){WPGMZA.FeaturePanel.prototype.onFeatureChanged.apply(this,arguments),this.updateFields()}}),jQuery(function($){var Parent=WPGMZA.Circle;WPGMZA.OLCircle=function(options,olFeature){var center,geom;Parent.call(this,options,olFeature),options=options||{},olFeature?(olFeature=olFeature.getGeometry(),center=ol.proj.toLonLat(olFeature.getCenter()),geom=olFeature,options.center=new WPGMZA.LatLng(center[1],center[0]),options.radius=olFeature.getRadius()/1e3):geom=new ol.geom.Circle(ol.proj.fromLonLat([parseFloat(options.center.lng),parseFloat(options.center.lat)]),1e3*options.radius),this.layer=new ol.layer.Vector({source:new ol.source.Vector}),this.olFeature=new ol.Feature({geometry:geom}),this.layer.getSource().addFeature(this.olFeature),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaCircle:this,wpgmzaFeature:this}),options&&this.setOptions(options)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProCircle),WPGMZA.OLCircle.prototype=Object.create(Parent.prototype),WPGMZA.OLCircle.prototype.constructor=WPGMZA.OLCircle,WPGMZA.OLCircle.prototype.setOptions=function(options){Parent.prototype.setOptions.call(this,options),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)},WPGMZA.OLCircle.prototype.getCenter=function(){var lonLat=ol.proj.toLonLat(this.olFeature.getGeometry().getCenter());return new WPGMZA.LatLng({lat:lonLat[1],lng:lonLat[0]})},WPGMZA.OLCircle.prototype.recreate=function(){var radius,y,x;this.olFeature&&(this.layer.getSource().removeFeature(this.olFeature),delete this.olFeature),this.center&&this.radius&&(radius=1e3*parseFloat(this.radius),x=this.center.lng,y=this.center.lat,x=ol.geom.Polygon.circular([x,y],radius,64).clone().transform("EPSG:4326","EPSG:3857"),this.olFeature=new ol.Feature(x),this.layer.getSource().addFeature(this.olFeature))},WPGMZA.OLCircle.prototype.setVisible=function(visible){this.layer.setVisible(!!visible)},WPGMZA.OLCircle.prototype.setCenter=function(center){WPGMZA.Circle.prototype.setCenter.apply(this,arguments),this.recreate()},WPGMZA.OLCircle.prototype.getRadius=function(){return this.layer.getSource().getFeatures()[0].getGeometry().getRadius()/1e3},WPGMZA.OLCircle.prototype.setRadius=function(radius){WPGMZA.Circle.prototype.setRadius.apply(this,arguments)},WPGMZA.OLCircle.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){WPGMZA.OLDrawingManager=function(map){WPGMZA.DrawingManager.call(this,map),this.source=new ol.source.Vector({wrapX:!1}),this.layer=new ol.layer.Vector({source:this.source})},WPGMZA.OLDrawingManager.prototype=Object.create(WPGMZA.DrawingManager.prototype),WPGMZA.OLDrawingManager.prototype.constructor=WPGMZA.OLDrawingManager,WPGMZA.OLDrawingManager.prototype.setOptions=function(options){var params={};options.strokeOpacity&&(params.stroke=new ol.style.Stroke({color:WPGMZA.hexOpacityToRGBA(options.strokeColor,options.strokeOpacity)})),options.fillOpacity&&(params.fill=new ol.style.Fill({color:WPGMZA.hexOpacityToRGBA(options.fillColor,options.fillOpacity)})),this.layer.setStyle(new ol.style.Style(params))},WPGMZA.OLDrawingManager.prototype.setDrawingMode=function(mode){var type,endEventType,self=this;switch(WPGMZA.DrawingManager.prototype.setDrawingMode.call(this,mode),this.interaction&&(this.map.olMap.removeInteraction(this.interaction),this.interaction=null),mode){case WPGMZA.DrawingManager.MODE_NONE:case WPGMZA.DrawingManager.MODE_MARKER:return;case WPGMZA.DrawingManager.MODE_POLYGON:type="Polygon",endEventType="polygonclosed";break;case WPGMZA.DrawingManager.MODE_POLYLINE:type="LineString",endEventType="polylinecomplete";break;case WPGMZA.DrawingManager.MODE_CIRCLE:type="Circle",endEventType="circlecomplete";break;case WPGMZA.DrawingManager.MODE_RECTANGLE:type="Circle",endEventType="rectanglecomplete";break;case WPGMZA.DrawingManager.MODE_HEATMAP:case WPGMZA.DrawingManager.MODE_POINTLABEL:return;case WPGMZA.DrawingManager.MODE_IMAGEOVERLAY:type="Circle",endEventType="imageoverlaycomplete";break;default:throw new Error("Invalid drawing mode")}WPGMZA.mapEditPage&&WPGMZA.mapEditPage.selectInteraction&&WPGMZA.mapEditPage.map.olMap.removeInteraction(WPGMZA.mapEditPage.selectInteraction);var options={source:this.source,type:type};mode!=WPGMZA.DrawingManager.MODE_RECTANGLE&&mode!=WPGMZA.DrawingManager.MODE_IMAGEOVERLAY||(options.geometryFunction=ol.interaction.Draw.createBox()),this.interaction=new ol.interaction.Draw(options),this.interaction.on("drawend",function(event){if(endEventType){var WPGMZAEvent=new WPGMZA.Event(endEventType);switch(mode){case WPGMZA.DrawingManager.MODE_POLYGON:WPGMZAEvent.enginePolygon=event.feature;break;case WPGMZA.DrawingManager.MODE_POLYLINE:WPGMZAEvent.enginePolyline=event.feature;break;case WPGMZA.DrawingManager.MODE_CIRCLE:WPGMZAEvent.engineCircle=event.feature;break;case WPGMZA.DrawingManager.MODE_RECTANGLE:WPGMZAEvent.engineRectangle=event.feature;break;case WPGMZA.DrawingManager.MODE_IMAGEOVERLAY:WPGMZAEvent.engineImageoverlay={engineRectangle:event.feature};break;default:throw new Error("Drawing mode not implemented")}self.dispatchEvent(WPGMZAEvent)}}),this.map.olMap.addInteraction(this.interaction)}}),jQuery(function($){WPGMZA.OLFeature=function(options){WPGMZA.assertInstangeOf(this,"OLFeature"),WPGMZA.Feature.apply(this,arguments)},WPGMZA.extend(WPGMZA.OLFeature,WPGMZA.Feature),WPGMZA.OLFeature.getOLStyle=function(options){var translated={};if(!options)return new ol.style.Style;var name,opacity,weight,map={fillcolor:"fillColor",opacity:"fillOpacity",linecolor:"strokeColor",lineopacity:"strokeOpacity",linethickness:"strokeWeight"};for(name in options=$.extend({},options))name in map&&(options[map[name]]=options[name]);return options.strokeColor&&(weight=opacity=1,"strokeOpacity"in options&&(opacity=options.strokeOpacity),"strokeWeight"in options&&(weight=options.strokeWeight),translated.stroke=new ol.style.Stroke({color:WPGMZA.hexOpacityToString(options.strokeColor,opacity),width:weight})),options.fillColor&&(opacity=1,"fillOpacity"in options&&(opacity=options.fillOpacity),weight=WPGMZA.hexOpacityToString(options.fillColor,opacity),translated.fill=new ol.style.Fill({color:weight})),new ol.style.Style(translated)},WPGMZA.OLFeature.setInteractionsOnFeature=function(feature,enable){enable?feature.modifyInteraction||(feature.snapInteraction=new ol.interaction.Snap({source:feature.layer.getSource()}),feature.map.olMap.addInteraction(feature.snapInteraction),feature.modifyInteraction=new ol.interaction.Modify({source:feature.layer.getSource()}),feature.map.olMap.addInteraction(feature.modifyInteraction),feature.modifyInteraction.on("modifyend",function(event){feature.trigger("change")})):feature.modifyInteraction&&(feature.map&&(feature.map.olMap.removeInteraction(feature.snapInteraction),feature.map.olMap.removeInteraction(feature.modifyInteraction)),delete feature.snapInteraction,delete feature.modifyInteraction)}}),jQuery(function($){WPGMZA.OLGeocoder=function(){},WPGMZA.OLGeocoder.prototype=Object.create(WPGMZA.Geocoder.prototype),WPGMZA.OLGeocoder.prototype.constructor=WPGMZA.OLGeocoder,WPGMZA.OLGeocoder.prototype.getResponseFromCache=function(query,callback){WPGMZA.restAPI.call("/geocode-cache",{data:{query:JSON.stringify(query)},success:function(response,xhr,status){response.lng=response.lon,callback(response)},useCompressedPathVariable:!0})},WPGMZA.OLGeocoder.prototype.getResponseFromNominatim=function(options,callback){var data={q:options.address,format:"json"};options.componentRestrictions&&options.componentRestrictions.country?data.countrycodes=options.componentRestrictions.country:options.country&&(data.countrycodes=options.country),$.ajax("https://nominatim.openstreetmap.org/search/",{data:data,success:function(response,xhr,status){callback(response)},error:function(response,xhr,status){callback(null,WPGMZA.Geocoder.FAIL)}})},WPGMZA.OLGeocoder.prototype.cacheResponse=function(query,response){$.ajax(WPGMZA.ajaxurl,{data:{action:"wpgmza_store_nominatim_cache",query:JSON.stringify(query),response:JSON.stringify(response)},method:"POST"})},WPGMZA.OLGeocoder.prototype.clearCache=function(callback){$.ajax(WPGMZA.ajaxurl,{data:{action:"wpgmza_clear_nominatim_cache"},method:"POST",success:function(response){callback(response)}})},WPGMZA.OLGeocoder.prototype.getLatLngFromAddress=function(options,callback){return WPGMZA.OLGeocoder.prototype.geocode(options,callback)},WPGMZA.OLGeocoder.prototype.getAddressFromLatLng=function(options,callback){return WPGMZA.OLGeocoder.prototype.geocode(options,callback)},WPGMZA.OLGeocoder.prototype.geocode=function(options,callback){var latLng,finish,location,self=this;if(!options)throw new Error("Invalid options");if(WPGMZA.LatLng.REGEXP.test(options.address))return latLng=WPGMZA.LatLng.fromString(options.address),void callback([{geometry:{location:latLng},latLng:latLng,lat:latLng.lat,lng:latLng.lng}],WPGMZA.Geocoder.SUCCESS);if(options.location&&(options.latLng=new WPGMZA.LatLng(options.location)),options.address)location=options.address,finish=function(response,status){for(var i=0;i<response.length;i++)response[i].geometry={location:new WPGMZA.LatLng({lat:parseFloat(response[i].lat),lng:parseFloat(response[i].lon)})},response[i].latLng={lat:parseFloat(response[i].lat),lng:parseFloat(response[i].lon)},response[i].bounds=new WPGMZA.LatLngBounds(new WPGMZA.LatLng({lat:response[i].boundingbox[1],lng:response[i].boundingbox[2]}),new WPGMZA.LatLng({lat:response[i].boundingbox[0],lng:response[i].boundingbox[3]})),response[i].lng=response[i].lon;callback(response,status)};else{if(!options.latLng)throw new Error("You must supply either a latLng or address");location=options.latLng.toString(),finish=function(response,status){var address=response[0].display_name;options.fullResult&&(address=response[0]),callback([address],status)}}var query={location:location,options:options};this.getResponseFromCache(query,function(response){response.length?finish(response,WPGMZA.Geocoder.SUCCESS):self.getResponseFromNominatim($.extend(options,{address:location}),function(response,status){status==WPGMZA.Geocoder.FAIL?callback(null,WPGMZA.Geocoder.FAIL):0==response.length?callback([],WPGMZA.Geocoder.ZERO_RESULTS):(finish(response,WPGMZA.Geocoder.SUCCESS),self.cacheResponse(query,response))})})}}),jQuery(function($){var Parent;WPGMZA.OLInfoWindow=function(feature){var self=this;Parent.call(this,feature),this.element=$("<div class='wpgmza-infowindow ol-info-window-container ol-info-window-plain'></div>")[0],$(this.element).on("click",".ol-info-window-close",function(event){self.close()})},Parent=WPGMZA.isProVersion()?WPGMZA.ProInfoWindow:WPGMZA.InfoWindow,WPGMZA.OLInfoWindow.prototype=Object.create(Parent.prototype),WPGMZA.OLInfoWindow.prototype.constructor=WPGMZA.OLInfoWindow,Object.defineProperty(WPGMZA.OLInfoWindow.prototype,"isPanIntoViewAllowed",{get:function(){return!0}}),WPGMZA.OLInfoWindow.prototype.open=function(map,feature){var self=this,latLng=feature.getPosition();return!!latLng&&(!!Parent.prototype.open.call(this,map,feature)&&(this.parent=map,this.overlay&&this.feature.map.olMap.removeOverlay(this.overlay),this.overlay=new ol.Overlay({element:this.element,stopEvent:!0,insertFirst:!0}),this.overlay.setPosition(ol.proj.fromLonLat([latLng.lng,latLng.lat])),self.feature.map.olMap.addOverlay(this.overlay),$(this.element).show(),this.setContent(this.content),WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER&&WPGMZA.getImageDimensions(feature.getIcon(),function(size){$(self.element).css({left:Math.round(size.width/2)+"px"})}),this.autoResize(),this.trigger("infowindowopen"),void this.trigger("domready")))},WPGMZA.OLInfoWindow.prototype.close=function(event){this.overlay&&($(this.element).hide(),WPGMZA.InfoWindow.prototype.close.call(this),this.trigger("infowindowclose"),this.feature.map.olMap.removeOverlay(this.overlay),this.overlay=null)},WPGMZA.OLInfoWindow.prototype.setContent=function(html){Parent.prototype.setContent.call(this,html),this.content=html;var eaBtn=WPGMZA.isProVersion()?"":this.addEditButton();$(this.element).html(eaBtn+"<i class='fa fa-times ol-info-window-close' aria-hidden='true'></i>"+html)},WPGMZA.OLInfoWindow.prototype.setOptions=function(options){options.maxWidth&&$(this.element).css({"max-width":options.maxWidth+"px"})},WPGMZA.OLInfoWindow.prototype.onOpen=function(){var self=this,imgs=$(this.element).find("img"),numImages=imgs.length,numImagesLoaded=0;WPGMZA.InfoWindow.prototype.onOpen.apply(this,arguments);let canAutoPan=!0;function inside(el,viewport){el=$(el)[0].getBoundingClientRect(),viewport=$(viewport)[0].getBoundingClientRect();return el.left>=viewport.left&&el.left<=viewport.right&&el.right<=viewport.right&&el.right>=viewport.left&&el.top>=viewport.top&&el.top<=viewport.bottom&&el.bottom<=viewport.bottom&&el.bottom>=viewport.top}function panIntoView(){var height=$(self.element).height();self.feature.map.animateNudge(0,.45*-(height+180),self.feature.getPosition())}void 0!==this.feature._osDisableAutoPan&&this.feature._osDisableAutoPan&&(canAutoPan=!1,this.feature._osDisableAutoPan=!1),this.isPanIntoViewAllowed&&canAutoPan&&(imgs.each(function(index,el){el.onload=function(){++numImagesLoaded!=numImages||inside(self.element,self.feature.map.element)||panIntoView()}}),0!=numImages||inside(self.element,self.feature.map.element)||panIntoView())},WPGMZA.OLInfoWindow.prototype.autoResize=function(){var mapWidth,mapHeight;$(this.element).css("max-height","none"),$(this.feature.map.element).length&&(mapHeight=$(this.feature.map.element).height(),mapWidth=$(this.feature.map.element).width(),mapHeight=mapHeight-180,$(this.element).height()>mapHeight&&$(this.element).css("max-height",mapHeight+"px"),mapHeight=648<mapWidth?648:mapWidth-120,$(this.element).width()>mapHeight&&$(this.element).css("max-width",mapHeight+"px"))}}),jQuery(function($){var Parent;WPGMZA.OLMap=function(element,options){var self=this,options=(Parent.call(this,element),this.setOptions(options),this.settings.toOLViewOptions());if($(this.element).html(""),this.olMap=new ol.Map({target:$(element)[0],layers:[this.getTileLayer()],view:this.getTileView(options)}),this.customTileMode&&!ol.extent.containsCoordinate(this.customTileModeExtent,this.olMap.getView().getCenter())){const view=this.olMap.getView();view.setCenter(ol.extent.getCenter(this.customTileModeExtent)),this.wrapLongitude(),this.onBoundsChanged()}function isSettingDisabled(value){return"yes"===value||!!value}this.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan?interaction.setActive(!isSettingDisabled(self.settings.wpgmza_settings_map_draggable)):interaction instanceof ol.interaction.DoubleClickZoom?interaction.setActive(!isSettingDisabled(self.settings.wpgmza_settings_map_clickzoom)):interaction instanceof ol.interaction.MouseWheelZoom&&interaction.setActive(!isSettingDisabled(self.settings.wpgmza_settings_map_scroll))},this),"greedy"!=this.settings.wpgmza_force_greedy_gestures&&"yes"!=this.settings.wpgmza_force_greedy_gestures&&1!=this.settings.wpgmza_force_greedy_gestures&&(this.gestureOverlay=$("<div class='wpgmza-gesture-overlay'></div>"),this.gestureOverlayTimeoutID=null,WPGMZA.isTouchDevice()?(this.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan&&self.olMap.removeInteraction(interaction)}),this.olMap.addInteraction(new ol.interaction.DragPan({condition:function(olBrowserEvent){let allowed=!1;olBrowserEvent=olBrowserEvent.originalEvent;return olBrowserEvent instanceof PointerEvent?this.targetPointers&&this.targetPointers.length&&(allowed=2==this.targetPointers.length):olBrowserEvent instanceof TouchEvent&&olBrowserEvent.touches&&olBrowserEvent.touches.length&&(allowed=2==olBrowserEvent.touches.length),allowed||self.showGestureOverlay(),allowed}})),this.gestureOverlay.text(WPGMZA.localized_strings.use_two_fingers)):(this.olMap.on("wheel",function(event){if(!ol.events.condition.platformModifierKeyOnly(event))return self.showGestureOverlay(),event.originalEvent.preventDefault(),!1}),this.gestureOverlay.text(WPGMZA.localized_strings.use_ctrl_scroll_to_zoom))),this.olMap.getControls().forEach(function(control){control instanceof ol.control.Zoom&&1==WPGMZA.settings.wpgmza_settings_map_zoom&&self.olMap.removeControl(control)},this),isSettingDisabled(WPGMZA.settings.wpgmza_settings_map_full_screen_control)||this.olMap.addControl(new ol.control.FullScreen),WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER&&(this.markerLayer=new ol.layer.Vector({source:new ol.source.Vector({features:[]})}),this.olMap.addLayer(this.markerLayer),this.olMap.on("click",function(event){var event=self.olMap.getFeaturesAtPixel(event.pixel);event&&event.length&&((event=event[0].wpgmzaMarker)&&(event.trigger("click"),event.trigger("select")))})),this.olMap.on("movestart",function(event){self.isBeingDragged=!0}),this.olMap.on("moveend",function(event){self.wrapLongitude(),self.isBeingDragged=!1,self.dispatchEvent("dragend"),self.onIdle()}),this.olMap.getView().on("change:resolution",function(event){self.dispatchEvent("zoom_changed"),self.dispatchEvent("zoomchanged"),setTimeout(function(){self.onIdle()},10)}),this.olMap.getView().on("change",function(){self.onBoundsChanged()}),self.onBoundsChanged(),this._mouseoverNativeFeatures=[],this.olMap.on("pointermove",function(event){if(!event.dragging){try{var featuresUnderPixel=event.target.getFeaturesAtPixel(event.pixel)}catch(e){return}for(var props,featuresUnderPixel=featuresUnderPixel||[],nativeFeaturesUnderPixel=[],i=0;i<featuresUnderPixel.length;i++)(props=featuresUnderPixel[i].getProperties()).wpgmzaFeature&&(nativeFeature=props.wpgmzaFeature,nativeFeaturesUnderPixel.push(nativeFeature),-1==self._mouseoverNativeFeatures.indexOf(nativeFeature)&&(nativeFeature.trigger("mouseover"),self._mouseoverNativeFeatures.push(nativeFeature)));for(i=self._mouseoverNativeFeatures.length-1;0<=i;i--)nativeFeature=self._mouseoverNativeFeatures[i],-1==nativeFeaturesUnderPixel.indexOf(nativeFeature)&&(nativeFeature.trigger("mouseout"),self._mouseoverNativeFeatures.splice(i,1))}}),$(this.element).on("click contextmenu",function(event){event=event||window.event;var isRight,latLng=self.pixelsToLatLng(event.offsetX,event.offsetY);if("which"in event?isRight=3==event.which:"button"in event&&(isRight=2==event.button),1==event.which||1==event.button){if(self.isBeingDragged)return;if($(event.target).closest(".ol-marker").length)return;try{var featuresUnderPixel=self.olMap.getFeaturesAtPixel([event.offsetX,event.offsetY])}catch(e){return}for(var props,featuresUnderPixel=featuresUnderPixel||[],nativeFeaturesUnderPixel=[],i=0;i<featuresUnderPixel.length;i++)(props=featuresUnderPixel[i].getProperties()).wpgmzaFeature&&(nativeFeature=props.wpgmzaFeature,nativeFeaturesUnderPixel.push(nativeFeature),nativeFeature.trigger("click"));return 0<featuresUnderPixel.length?void 0:void self.trigger({type:"click",latLng:latLng})}if(isRight)return self.onRightClick(event)}),WPGMZA.isProVersion()||(this.trigger("init"),this.dispatchEvent("created"),WPGMZA.events.dispatchEvent({type:"mapcreated",map:this}),$(this.element).trigger("wpgooglemaps_loaded"))},Parent=WPGMZA.isProVersion()?WPGMZA.ProMap:WPGMZA.Map,WPGMZA.OLMap.prototype=Object.create(Parent.prototype),WPGMZA.OLMap.prototype.constructor=WPGMZA.OLMap,WPGMZA.OLMap.prototype.getTileLayer=function(){var options={};if(WPGMZA.settings.tile_server_url&&(options.url=WPGMZA.settings.tile_server_url,"custom_override"===WPGMZA.settings.tile_server_url&&(WPGMZA.settings.tile_server_url_override&&""!==WPGMZA.settings.tile_server_url_override.trim()?options.url=WPGMZA.settings.tile_server_url_override.trim():options.url="https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png"),WPGMZA.settings.open_layers_api_key&&""!==WPGMZA.settings.open_layers_api_key&&(options.url+="?apikey="+WPGMZA.settings.open_layers_api_key.trim())),this.settings&&this.settings.custom_tile_enabled&&this.settings.custom_tile_image_width&&this.settings.custom_tile_image_height){var width=parseInt(this.settings.custom_tile_image_width),height=parseInt(this.settings.custom_tile_image_height);if(this.settings.custom_tile_image)return width=[0,0,width,height],height=new ol.proj.Projection({code:"custom-tile-map",units:"pixels",extent:width}),new ol.layer.Image({source:new ol.source.ImageStatic({attributions:this.settings.custom_tile_image_attribution||"©",url:this.settings.custom_tile_image,projection:height,imageExtent:width})})}return new ol.layer.Tile({source:new ol.source.OSM(options)})},WPGMZA.OLMap.prototype.getTileView=function(viewOptions){var width,height;return this.settings&&this.settings.custom_tile_enabled&&this.settings.custom_tile_image_width&&this.settings.custom_tile_image_height&&(width=parseInt(this.settings.custom_tile_image_width),height=parseInt(this.settings.custom_tile_image_height),this.settings.custom_tile_image&&(width=[0,0,width,height],height=new ol.proj.Projection({code:"custom-tile-map",units:"pixels",extent:width}),viewOptions.projection=height,this.customTileModeExtent=width,this.customTileMode=!0)),new ol.View(viewOptions)},WPGMZA.OLMap.prototype.wrapLongitude=function(){var transformed=ol.proj.transform(this.olMap.getView().getCenter(),"EPSG:3857","EPSG:4326"),transformed={lat:transformed[1],lng:transformed[0]};-180<=transformed.lng&&transformed.lng<=180||(transformed.lng=transformed.lng-360*Math.floor(transformed.lng/360),180<transformed.lng&&(transformed.lng-=360),this.setCenter(transformed))},WPGMZA.OLMap.prototype.getCenter=function(){var lonLat=ol.proj.toLonLat(this.olMap.getView().getCenter());return{lat:lonLat[1],lng:lonLat[0]}},WPGMZA.OLMap.prototype.setCenter=function(latLng){var view=this.olMap.getView();WPGMZA.Map.prototype.setCenter.call(this,latLng),view.setCenter(ol.proj.fromLonLat([latLng.lng,latLng.lat])),this.wrapLongitude(),this.onBoundsChanged()},WPGMZA.OLMap.prototype.getBounds=function(){var bounds=this.olMap.getView().calculateExtent(this.olMap.getSize()),nativeBounds=new WPGMZA.LatLngBounds,topLeft=ol.proj.toLonLat([bounds[0],bounds[1]]),bounds=ol.proj.toLonLat([bounds[2],bounds[3]]);return nativeBounds.north=topLeft[1],nativeBounds.south=bounds[1],nativeBounds.west=topLeft[0],nativeBounds.east=bounds[0],nativeBounds},WPGMZA.OLMap.prototype.fitBounds=function(southWest,northEast){southWest instanceof WPGMZA.LatLng&&(southWest={lat:southWest.lat,lng:southWest.lng}),northEast instanceof WPGMZA.LatLng?northEast={lat:northEast.lat,lng:northEast.lng}:southWest instanceof WPGMZA.LatLngBounds&&(southWest={lat:(bounds=southWest).south,lng:bounds.west},northEast={lat:bounds.north,lng:bounds.east});var bounds=this.olMap.getView(),southWest=ol.extent.boundingExtent([ol.proj.fromLonLat([parseFloat(southWest.lng),parseFloat(southWest.lat)]),ol.proj.fromLonLat([parseFloat(northEast.lng),parseFloat(northEast.lat)])]);bounds.fit(southWest,this.olMap.getSize())},WPGMZA.OLMap.prototype.panTo=function(latLng,zoom){var view=this.olMap.getView(),options={center:ol.proj.fromLonLat([parseFloat(latLng.lng),parseFloat(latLng.lat)]),duration:500};1<arguments.length&&(options.zoom=parseInt(zoom)),view.animate(options)},WPGMZA.OLMap.prototype.getZoom=function(){return Math.round(this.olMap.getView().getZoom())},WPGMZA.OLMap.prototype.setZoom=function(value){this.olMap.getView().setZoom(value)},WPGMZA.OLMap.prototype.getMinZoom=function(){return this.olMap.getView().getMinZoom()},WPGMZA.OLMap.prototype.setMinZoom=function(value){this.olMap.getView().setMinZoom(value)},WPGMZA.OLMap.prototype.getMaxZoom=function(){return this.olMap.getView().getMaxZoom()},WPGMZA.OLMap.prototype.setMaxZoom=function(value){this.olMap.getView().setMaxZoom(value)},WPGMZA.OLMap.prototype.setOptions=function(options){Parent.prototype.setOptions.call(this,options),this.olMap&&this.olMap.getView().setProperties(this.settings.toOLViewOptions())},WPGMZA.OLMap.prototype.addMarker=function(marker){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT?this.olMap.addOverlay(marker.overlay):(this.markerLayer.getSource().addFeature(marker.feature),marker.featureInSource=!0),Parent.prototype.addMarker.call(this,marker)},WPGMZA.OLMap.prototype.removeMarker=function(marker){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT?this.olMap.removeOverlay(marker.overlay):(this.markerLayer.getSource().removeFeature(marker.feature),marker.featureInSource=!1),Parent.prototype.removeMarker.call(this,marker)},WPGMZA.OLMap.prototype.addPolygon=function(polygon){this.olMap.addLayer(polygon.layer),Parent.prototype.addPolygon.call(this,polygon)},WPGMZA.OLMap.prototype.removePolygon=function(polygon){this.olMap.removeLayer(polygon.layer),Parent.prototype.removePolygon.call(this,polygon)},WPGMZA.OLMap.prototype.addPolyline=function(polyline){this.olMap.addLayer(polyline.layer),Parent.prototype.addPolyline.call(this,polyline)},WPGMZA.OLMap.prototype.removePolyline=function(polyline){this.olMap.removeLayer(polyline.layer),Parent.prototype.removePolyline.call(this,polyline)},WPGMZA.OLMap.prototype.addCircle=function(circle){this.olMap.addLayer(circle.layer),Parent.prototype.addCircle.call(this,circle)},WPGMZA.OLMap.prototype.removeCircle=function(circle){this.olMap.removeLayer(circle.layer),Parent.prototype.removeCircle.call(this,circle)},WPGMZA.OLMap.prototype.addRectangle=function(rectangle){this.olMap.addLayer(rectangle.layer),Parent.prototype.addRectangle.call(this,rectangle)},WPGMZA.OLMap.prototype.removeRectangle=function(rectangle){this.olMap.removeLayer(rectangle.layer),Parent.prototype.removeRectangle.call(this,rectangle)},WPGMZA.OLMap.prototype.pixelsToLatLng=function(x,y){null==y&&("x"in x&&"y"in x?(y=x.y,x=x.x):console.warn("Y coordinate undefined in pixelsToLatLng (did you mean to pass 2 arguments?)"));x=this.olMap.getCoordinateFromPixel([x,y]);if(!x)return{x:null,y:null};y=ol.proj.toLonLat(x);return{lat:y[1],lng:y[0]}},WPGMZA.OLMap.prototype.latLngToPixels=function(latLng){latLng=ol.proj.fromLonLat([latLng.lng,latLng.lat]),latLng=this.olMap.getPixelFromCoordinate(latLng);return latLng?{x:latLng[0],y:latLng[1]}:{x:null,y:null}},WPGMZA.OLMap.prototype.enableBicycleLayer=function(value){value?(this.bicycleLayer||(this.bicycleLayer=new ol.layer.Tile({source:new ol.source.OSM({url:"http://{a-c}.tile.opencyclemap.org/cycle/{z}/{x}/{y}.png"})})),this.olMap.addLayer(this.bicycleLayer)):this.bicycleLayer&&this.olMap.removeLayer(this.bicycleLayer)},WPGMZA.OLMap.prototype.showGestureOverlay=function(){var self=this;clearTimeout(this.gestureOverlayTimeoutID),$(this.gestureOverlay).stop().animate({opacity:"100"}),$(this.element).append(this.gestureOverlay),$(this.gestureOverlay).css({"line-height":$(this.element).height()+"px",opacity:"1.0"}),$(this.gestureOverlay).show(),this.gestureOverlayTimeoutID=setTimeout(function(){self.gestureOverlay.fadeOut(2e3)},2e3)},WPGMZA.OLMap.prototype.onElementResized=function(event){this.olMap.updateSize()},WPGMZA.OLMap.prototype.onRightClick=function(event){if($(event.target).closest(".ol-marker, .wpgmza_modern_infowindow, .wpgmza-modern-store-locator").length)return!0;var parentOffset=$(this.element).offset(),relX=event.pageX-parentOffset.left,parentOffset=event.pageY-parentOffset.top,relX=this.pixelsToLatLng(relX,parentOffset);return this.trigger({type:"rightclick",latLng:relX}),$(this.element).trigger({type:"rightclick",latLng:relX}),event.preventDefault(),!1},WPGMZA.OLMap.prototype.enableAllInteractions=function(){this.olMap.getInteractions().forEach(function(interaction){(interaction instanceof ol.interaction.DragPan||interaction instanceof ol.interaction.DoubleClickZoom||interaction instanceof ol.interaction.MouseWheelZoom)&&interaction.setActive(!0)},this)}}),jQuery(function($){var Parent;WPGMZA.OLMarker=function(options){var self=this,settings=(Parent.call(this,options),{});if(options)for(var name in options)options[name]instanceof WPGMZA.LatLng?settings[name]=options[name].toLatLngLiteral():options[name]instanceof WPGMZA.Map||(settings[name]=options[name]);var origin=ol.proj.fromLonLat([parseFloat(this.lng),parseFloat(this.lat)]);if(WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT){var img=$("<img alt=''/>")[0];img.onload=function(event){self.updateElementHeight(),self.map&&self.map.olMap.updateSize()},img.src=WPGMZA.defaultMarkerIcon,this.element=$("<div class='ol-marker'></div>")[0],this.element.appendChild(img),this.element.wpgmzaMarker=this,$(this.element).on("mouseover",function(event){self.dispatchEvent("mouseover")}),$(this.element).on("mouseout",function(event){self.dispatchEvent("mouseout")}),this.overlay=new ol.Overlay({element:this.element,position:origin,positioning:"bottom-center",stopEvent:!1}),this.overlay.setPosition(origin),this.animation?this.setAnimation(this.animation):this.anim&&this.setAnimation(this.anim),options&&options.draggable&&this.setDraggable(!0),this.rebindClickListener()}else{if(WPGMZA.OLMarker.renderMode!=WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)throw new Error("Invalid marker render mode");this.feature=new ol.Feature({geometry:new ol.geom.Point(origin)}),this.feature.setStyle(this.getVectorLayerStyle()),(this.feature.wpgmzaMarker=this).feature.wpgmzaFeature=this}this.setOptions(settings),this.trigger("init")},Parent=WPGMZA.isProVersion()?WPGMZA.ProMarker:WPGMZA.Marker,WPGMZA.OLMarker.prototype=Object.create(Parent.prototype),WPGMZA.OLMarker.prototype.constructor=WPGMZA.OLMarker,WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT="element",WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER="vector",WPGMZA.OLMarker.renderMode=WPGMZA.OLMarker.RENDER_MODE_HTML_ELEMENT,"open-layers"==WPGMZA.settings.engine&&WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER&&(WPGMZA.OLMarker.defaultVectorLayerStyle=new ol.style.Style({image:new ol.style.Icon({anchor:[.5,1],src:WPGMZA.defaultMarkerIcon})}),WPGMZA.OLMarker.hiddenVectorLayerStyle=new ol.style.Style({})),WPGMZA.OLMarker.prototype.getVectorLayerStyle=function(){return this.vectorLayerStyle||WPGMZA.OLMarker.defaultVectorLayerStyle},WPGMZA.OLMarker.prototype.updateElementHeight=function(height,calledOnFocus){var self=this;0!=(height=height||$(this.element).find("img").height())||calledOnFocus||$(window).one("focus",function(event){self.updateElementHeight(!1,!0)}),$(this.element).css({height:height+"px"})},WPGMZA.OLMarker.prototype.addLabel=function(){this.setLabel(this.getLabelText())},WPGMZA.OLMarker.prototype.setLabel=function(label){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?console.warn("Marker labels are not currently supported in Vector Layer rendering mode"):label?(this.label||(this.label=$("<div class='ol-marker-label'/>"),$(this.element).append(this.label)),this.label.html(label)):this.label&&$(this.element).find(".ol-marker-label").remove()},WPGMZA.OLMarker.prototype.getVisible=function(visible){if(WPGMZA.OLMarker.renderMode!=WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)return"none"!=this.overlay.getElement().style.display},WPGMZA.OLMarker.prototype.setVisible=function(visible){var style;Parent.prototype.setVisible.call(this,visible),WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?visible?(style=this.getVectorLayerStyle(),this.feature.setStyle(style)):this.feature.setStyle(null):this.overlay.getElement().style.display=visible?"block":"none"},WPGMZA.OLMarker.prototype.setPosition=function(latLng){Parent.prototype.setPosition.call(this,latLng);latLng=ol.proj.fromLonLat([parseFloat(this.lng),parseFloat(this.lat)]);WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?this.feature.setGeometry(new ol.geom.Point(latLng)):this.overlay.setPosition(latLng)},WPGMZA.OLMarker.prototype.updateOffset=function(x,y){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?console.warn("Marker offset is not currently supported in Vector Layer rendering mode"):(x=this._offset.x,y=this._offset.y,this.element.style.position="relative",this.element.style.left=x+"px",this.element.style.top=y+"px")},WPGMZA.OLMarker.prototype.setAnimation=function(anim){if(WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)console.warn("Marker animation is not currently supported in Vector Layer rendering mode");else switch(Parent.prototype.setAnimation.call(this,anim),anim){case WPGMZA.Marker.ANIMATION_NONE:$(this.element).removeAttr("data-anim");break;case WPGMZA.Marker.ANIMATION_BOUNCE:$(this.element).attr("data-anim","bounce");break;case WPGMZA.Marker.ANIMATION_DROP:$(this.element).attr("data-anim","drop")}},WPGMZA.OLMarker.prototype.setDraggable=function(draggable){var self=this;if(WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER)console.warn("Marker dragging is not currently supported in Vector Layer rendering mode");else if(draggable){draggable={disabled:!1};this.jQueryDraggableInitialized||(draggable.start=function(event){self.onDragStart(event)},draggable.stop=function(event){self.onDragEnd(event)});try{$(this.element).draggable(draggable),this.jQueryDraggableInitialized=!0,this.rebindClickListener()}catch(ex){}}else $(this.element).draggable({disabled:!0})},WPGMZA.OLMarker.prototype.setOpacity=function(opacity){WPGMZA.OLMarker.renderMode==WPGMZA.OLMarker.RENDER_MODE_VECTOR_LAYER?console.warn("Marker opacity is not currently supported in Vector Layer rendering mode"):$(this.element).css({opacity:opacity})},WPGMZA.OLMarker.prototype.onDragStart=function(event){this.isBeingDragged=!0,this.map.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan&&interaction.setActive(!1)})},WPGMZA.OLMarker.prototype.onDragEnd=function(event){var offset_top=parseFloat($(this.element).css("top").match(/-?\d+/)[0]),offset_left=parseFloat($(this.element).css("left").match(/-?\d+/)[0]),currentLatLng=($(this.element).css({top:"0px",left:"0px"}),this.getPosition()),currentLatLng=this.map.latLngToPixels(currentLatLng),offset_left={x:currentLatLng.x+offset_left,y:currentLatLng.y+offset_top},currentLatLng=this.map.pixelsToLatLng(offset_left);this.setPosition(currentLatLng),this.isBeingDragged=!1,this.trigger({type:"dragend",latLng:currentLatLng}),this.trigger("change"),"yes"!=this.map.settings.wpgmza_settings_map_draggable&&this.map.olMap.getInteractions().forEach(function(interaction){interaction instanceof ol.interaction.DragPan&&interaction.setActive(!0)})},WPGMZA.OLMarker.prototype.onElementClick=function(event){event=event.currentTarget.wpgmzaMarker;event.isBeingDragged||(event.dispatchEvent("click"),event.dispatchEvent("select"))},WPGMZA.OLMarker.prototype.rebindClickListener=function(){$(this.element).off("click",this.onElementClick),$(this.element).on("click",this.onElementClick)}}),jQuery(function($){WPGMZA.OLModernStoreLocatorCircle=function(map,settings){WPGMZA.ModernStoreLocatorCircle.call(this,map,settings)},WPGMZA.OLModernStoreLocatorCircle.prototype=Object.create(WPGMZA.ModernStoreLocatorCircle.prototype),WPGMZA.OLModernStoreLocatorCircle.prototype.constructor=WPGMZA.OLModernStoreLocatorCircle,WPGMZA.OLModernStoreLocatorCircle.prototype.initCanvasLayer=function(){var self=this,olViewportElement=$(this.map.element).children(".ol-viewport");this.canvas=document.createElement("canvas"),this.canvas.className="wpgmza-ol-canvas-overlay",olViewportElement.find(".ol-layers .ol-layer:first-child").prepend(this.canvas),this.renderFunction=function(event){self.canvas.width==olViewportElement.width()&&self.canvas.height==olViewportElement.height()||(self.canvas.width=olViewportElement.width(),self.canvas.height=olViewportElement.height(),$(this.canvas).css({width:olViewportElement.width()+"px",height:olViewportElement.height()+"px"})),self.draw()},this.map.olMap.on("postrender",this.renderFunction)},WPGMZA.OLModernStoreLocatorCircle.prototype.getContext=function(type){return this.canvas.getContext(type)},WPGMZA.OLModernStoreLocatorCircle.prototype.getCanvasDimensions=function(){return{width:this.canvas.width,height:this.canvas.height}},WPGMZA.OLModernStoreLocatorCircle.prototype.getCenterPixels=function(){return this.map.latLngToPixels(this.settings.center)},WPGMZA.OLModernStoreLocatorCircle.prototype.getWorldOriginOffset=function(){return{x:0,y:0}},WPGMZA.OLModernStoreLocatorCircle.prototype.getTransformedRadius=function(km){var center=new WPGMZA.LatLng(this.settings.center),outer=new WPGMZA.LatLng(center),km=(outer.moveByDistance(km,90),this.map.latLngToPixels(center)),center=this.map.latLngToPixels(outer);return Math.abs(center.x-km.x)},WPGMZA.OLModernStoreLocatorCircle.prototype.getScale=function(){return 1},WPGMZA.OLModernStoreLocatorCircle.prototype.destroy=function(){$(this.canvas).remove(),this.map.olMap.un("postrender",this.renderFunction),this.map=null,this.canvas=null}}),jQuery(function($){WPGMZA.OLModernStoreLocator=function(map_id){WPGMZA.ModernStoreLocator.call(this,map_id),(WPGMZA.isProVersion()?$(".wpgmza_map[data-map-id='"+map_id+"']"):$("#wpgmza_map")).append(this.element)},WPGMZA.OLModernStoreLocator.prototype=Object.create(WPGMZA.ModernStoreLocator),WPGMZA.OLModernStoreLocator.prototype.constructor=WPGMZA.OLModernStoreLocator}),jQuery(function($){var Parent=WPGMZA.Pointlabel;WPGMZA.OLPointlabel=function(options,pointFeature){Parent.call(this,options,pointFeature),pointFeature&&pointFeature.textFeature?this.textFeature=pointFeature.textFeature:this.textFeature=new WPGMZA.Text.createInstance({text:"",map:this.map,position:this.getPosition()}),this.updateNativeFeature()},Parent=WPGMZA.isProVersion()?WPGMZA.ProPointlabel:WPGMZA.Pointlabel,WPGMZA.extend(WPGMZA.OLPointlabel,Parent),WPGMZA.OLPointlabel.prototype.updateNativeFeature=function(){var options=this.getScalarProperties();options.name&&this.textFeature.setText(options.name),this.textFeature.refresh()}}),jQuery(function($){var Parent;WPGMZA.OLPolygon=function(options,olFeature){if(Parent.call(this,options,olFeature),olFeature)this.olFeature=olFeature;else{var coordinates=[[]];if(options&&options.polydata)for(var paths=this.parseGeometry(options.polydata),i=0;i<=paths.length;i++)coordinates[0].push(ol.proj.fromLonLat([parseFloat(paths[i%paths.length].lng),parseFloat(paths[i%paths.length].lat)]));this.olFeature=new ol.Feature({geometry:new ol.geom.Polygon(coordinates)})}this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]})}),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaPolygon:this,wpgmzaFeature:this}),options&&this.setOptions(options)},Parent=WPGMZA.isProVersion()?WPGMZA.ProPolygon:WPGMZA.Polygon,WPGMZA.OLPolygon.prototype=Object.create(Parent.prototype),WPGMZA.OLPolygon.prototype.constructor=WPGMZA.OLPolygon,WPGMZA.OLPolygon.prototype.getGeometry=function(){for(var coordinates=this.olFeature.getGeometry().getCoordinates()[0],result=[],i=0;i<coordinates.length;i++){var lonLat=ol.proj.toLonLat(coordinates[i]),lonLat={lat:lonLat[1],lng:lonLat[0]};result.push(lonLat)}return result},WPGMZA.OLPolygon.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){var Parent;WPGMZA.OLPolyline=function(options,olFeature){if(WPGMZA.Polyline.call(this,options),olFeature)this.olFeature=olFeature;else{var coordinates=[];if(options&&options.polydata)for(var path=this.parseGeometry(options.polydata),i=0;i<path.length;i++){if(!$.isNumeric(path[i].lat))throw new Error("Invalid latitude");if(!$.isNumeric(path[i].lng))throw new Error("Invalid longitude");coordinates.push(ol.proj.fromLonLat([parseFloat(path[i].lng),parseFloat(path[i].lat)]))}this.olFeature=new ol.Feature({geometry:new ol.geom.LineString(coordinates)})}this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]})}),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaPolyline:this,wpgmzaFeature:this}),options&&this.setOptions(options)},Parent=WPGMZA.Polyline,WPGMZA.OLPolyline.prototype=Object.create(Parent.prototype),WPGMZA.OLPolyline.prototype.constructor=WPGMZA.OLPolyline,WPGMZA.OLPolyline.prototype.getGeometry=function(){for(var result=[],coordinates=this.olFeature.getGeometry().getCoordinates(),i=0;i<coordinates.length;i++){var lonLat=ol.proj.toLonLat(coordinates[i]),lonLat={lat:lonLat[1],lng:lonLat[0]};result.push(lonLat)}return result},WPGMZA.OLPolyline.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){var Parent=WPGMZA.Rectangle;WPGMZA.OLRectangle=function(options,olFeature){var coordinates;Parent.apply(this,arguments),olFeature?this.olFeature=olFeature:(coordinates=[[]],options.cornerA&&options.cornerB&&(coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerA.lng),parseFloat(options.cornerA.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerB.lng),parseFloat(options.cornerA.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerB.lng),parseFloat(options.cornerB.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerA.lng),parseFloat(options.cornerB.lat)])),coordinates[0].push(ol.proj.fromLonLat([parseFloat(options.cornerA.lng),parseFloat(options.cornerA.lat)]))),this.olFeature=new ol.Feature({geometry:new ol.geom.Polygon(coordinates)})),this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]}),style:this.olStyle}),this.layer.getSource().getFeatures()[0].setProperties({wpgmzaRectangle:this,wpgmzaFeature:this}),options&&this.setOptions(options)},WPGMZA.isProVersion()&&(Parent=WPGMZA.ProRectangle),WPGMZA.extend(WPGMZA.OLRectangle,Parent),WPGMZA.OLRectangle.prototype.getBounds=function(){var extent=this.olFeature.getGeometry().getExtent(),topLeft=ol.extent.getTopLeft(extent),extent=ol.extent.getBottomRight(extent),topLeft=ol.proj.toLonLat(topLeft),extent=ol.proj.toLonLat(extent),topLeft=new WPGMZA.LatLng(topLeft[1],topLeft[0]),extent=new WPGMZA.LatLng(extent[1],extent[0]);return new WPGMZA.LatLngBounds(topLeft,extent)},WPGMZA.OLRectangle.prototype.setOptions=function(options){Parent.prototype.setOptions.apply(this,arguments),"editable"in options&&WPGMZA.OLFeature.setInteractionsOnFeature(this,options.editable)}}),jQuery(function($){WPGMZA.OLText=function(options){WPGMZA.Text.apply(this,arguments),this.overlay=new WPGMZA.OLTextOverlay(options)},WPGMZA.extend(WPGMZA.OLText,WPGMZA.Text),WPGMZA.OLText.prototype.refresh=function(){this.overlay&&this.overlay.refresh()}}),jQuery(function($){WPGMZA.OLTextOverlay=function(options){var coords;options.position&&options.map&&(coords=ol.proj.fromLonLat([options.position.lng,options.position.lat]),this.olFeature=new ol.Feature({geometry:new ol.geom.Point(coords)}),this.styleOptions=options||{},this.layer=new ol.layer.Vector({source:new ol.source.Vector({features:[this.olFeature]}),style:this.getStyle()}),this.layer.setZIndex(10),options.map.olMap.addLayer(this.layer))},WPGMZA.OLTextOverlay.prototype.getStyle=function(){var i,defaults={fontSize:11,fillColor:"#000000",strokeColor:"#ffffff"};for(i in defaults)void 0===this.styleOptions[i]&&(this.styleOptions[i]=defaults[i]);let labelStyles=new ol.style.Style({text:new ol.style.Text({font:"bold "+this.styleOptions.fontSize+'px "Open Sans", "Arial Unicode MS", "sans-serif"',placement:"point",fill:new ol.style.Fill({color:this.styleOptions.fillColor}),stroke:new ol.style.Stroke({color:this.styleOptions.strokeColor,width:1})})});return labelStyles.getText().setText(this.styleOptions.text||""),labelStyles},WPGMZA.OLTextOverlay.prototype.refresh=function(){this.layer&&this.layer.setStyle(this.getStyle())},WPGMZA.OLTextOverlay.prototype.setPosition=function(position){this.olFeature&&(position=ol.proj.fromLonLat([parseFloat(position.lng),parseFloat(position.lat)]),this.olFeature.setGeometry(new ol.geom.Point(position)))},WPGMZA.OLTextOverlay.prototype.setText=function(text){this.styleOptions.text=text},WPGMZA.OLTextOverlay.prototype.setFontSize=function(size){size=parseInt(size),this.styleOptions.fontSize=size},WPGMZA.OLTextOverlay.prototype.setFillColor=function(color){color.match(/^#/)||(color="#"+color),this.styleOptions.fillColor=color},WPGMZA.OLTextOverlay.prototype.setLineColor=function(color){color.match(/^#/)||(color="#"+color),this.styleOptions.strokeColor=color},WPGMZA.OLTextOverlay.prototype.setOpacity=function(opacity){1<(opacity=parseFloat(opacity))?opacity=1:opacity<0&&(opacity=0),this.layer&&this.layer.setOpacity(opacity)},WPGMZA.OLTextOverlay.prototype.remove=function(){this.styleOptions.map&&this.styleOptions.map.olMap.removeLayer(this.layer)}}),jQuery(function($){WPGMZA.OLThemeEditor=function(){var self=this;WPGMZA.EventDispatcher.call(this),this.element=$("#wpgmza-ol-theme-editor"),this.element.length?(this.mapElement=WPGMZA.maps[0].element,$(this.element).find('input[name="wpgmza_ol_tile_filter"]').on("change",function(event){self.onFilterChange(event.currentTarget)})):console.warn("No element to initialise theme editor on")},WPGMZA.extend(WPGMZA.OLThemeEditor,WPGMZA.EventDispatcher),WPGMZA.OLThemeEditor.prototype.onFilterChange=function(context){context instanceof HTMLInputElement&&(context=$(context).val(),this.mapElement&&$(this.mapElement).css("--wpgmza-ol-tile-filter",context))}}),jQuery(function($){WPGMZA.OLThemePanel=function(){var self=this;this.element=$("#wpgmza-ol-theme-panel"),this.map=WPGMZA.maps[0],this.element.length?(this.element.on("click","#wpgmza-theme-presets label, .theme-selection-panel label",function(event){self.onThemePresetClick(event)}),WPGMZA.OLThemePanel=this):console.warn("No element to initialise theme panel on")},WPGMZA.OLThemePanel.prototype.onThemePresetClick=function(event){if(event.currentTarget){const element=$(event.currentTarget);event=element.data("filter");if(event&&$('input[name="wpgmza_ol_tile_filter"]').length){const input=$('input[name="wpgmza_ol_tile_filter"]').get(0);input.wpgmzaCSSFilterInput&&input.wpgmzaCSSFilterInput.parseFilters(event)}}}}),jQuery(function($){WPGMZA.DataTable=function(element){var version,self=this;if(!$.fn.dataTable)return console.warn("The dataTables library is not loaded. Cannot create a dataTable. Did you enable 'Do not enqueue dataTables'?"),void(WPGMZA.settings.wpgmza_do_not_enqueue_datatables&&WPGMZA.getCurrentPage()==WPGMZA.PAGE_MAP_EDIT&&alert("You have selected 'Do not enqueue DataTables' in WP Go Maps' settings. No 3rd party software is loading the DataTables library. Because of this, the marker table cannot load. Please uncheck this option to use the marker table."));$.fn.dataTable.ext?$.fn.dataTable.ext.errMode="throw":(version=$.fn.dataTable.version||"unknown",console.warn("You appear to be running an outdated or modified version of the dataTables library. This may cause issues with table functionality. This is usually caused by 3rd party software loading an older version of DataTables. The loaded version is "+version+", we recommend version 1.10.12 or above.")),$.fn.dataTable.Api&&$.fn.dataTable.Api.register("processing()",function(show){return this.iterator("table",function(ctx){ctx.oApi._fnProcessingDisplay(ctx,show)})}),this.element=element,(this.element.wpgmzaDataTable=this).dataTableElement=this.getDataTableElement();var settings=this.getDataTableSettings();this.phpClass=$(element).attr("data-wpgmza-php-class"),(this.wpgmzaDataTable=this).useCompressedPathVariable=WPGMZA.restAPI.isCompressedPathVariableSupported&&WPGMZA.settings.enable_compressed_path_variables,this.method=this.useCompressedPathVariable?"GET":"POST",null==this.getLanguageURL()||"//cdn.datatables.net/plug-ins/1.10.12/i18n/English.json"==this.getLanguageURL()?(this.dataTable=$(this.dataTableElement).DataTable(settings),this.dataTable.ajax.reload()):$.ajax(this.getLanguageURL(),{success:function(response,status,xhr){self.languageJSON=response,self.dataTable=$(self.dataTableElement).DataTable(settings),self.dataTable.ajax.reload()}})},WPGMZA.DataTable.prototype.getDataTableElement=function(){return $(this.element).find("table")},WPGMZA.DataTable.prototype.onAJAXRequest=function(data,settings){var params={phpClass:this.phpClass},attr=$(this.element).attr("data-wpgmza-ajax-parameters");return attr&&$.extend(params,JSON.parse(attr)),$.extend(data,params)},WPGMZA.DataTable.prototype.onDataTableAjaxRequest=function(data,callback,settings){var self=this,element=this.element,element=$(element).attr("data-wpgmza-rest-api-route"),data=this.onAJAXRequest(data,settings),draw=data.draw;if(delete data.draw,!element)throw new Error("No data-wpgmza-rest-api-route attribute specified");settings={method:"POST",useCompressedPathVariable:!0,data:data,dataType:"json",cache:!this.preventCaching,beforeSend:function(xhr){xhr.setRequestHeader("X-DataTables-Draw",draw)},success:function(response,status,xhr){response.draw=draw,self.lastResponse=response,callback(response),$("[data-marker-icon-src]").each(function(index,element){WPGMZA.MarkerIcon.createInstance($(element).attr("data-marker-icon-src")).applyToElement(element)})}};return WPGMZA.restAPI.call(element,settings)},WPGMZA.DataTable.prototype.getDataTableSettings=function(){var self=this,element=this.element,options={},element=((options=$(element).attr("data-wpgmza-datatable-options")?JSON.parse($(element).attr("data-wpgmza-datatable-options")):options).deferLoading=!0,options.processing=!0,options.serverSide=!0,options.ajax=function(data,callback,settings){return WPGMZA.DataTable.prototype.onDataTableAjaxRequest.apply(self,arguments)},WPGMZA.AdvancedTableDataTable&&this instanceof WPGMZA.AdvancedTableDataTable&&WPGMZA.settings.wpgmza_default_items&&(options.iDisplayLength=parseInt(WPGMZA.settings.wpgmza_default_items)),options.aLengthMenu=[[5,10,25,50,100,-1],["5","10","25","50","100",WPGMZA.localized_strings.all]],this.getLanguageURL());return element&&(options.language={url:element}),options},WPGMZA.DataTable.prototype.getLanguageURL=function(){if(!WPGMZA.locale)return null;var languageURL;switch(WPGMZA.locale.substr(0,2)){case"af":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Afrikaans.json";break;case"sq":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Albanian.json";break;case"am":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Amharic.json";break;case"ar":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Arabic.json";break;case"hy":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Armenian.json";break;case"az":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Azerbaijan.json";break;case"bn":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Bangla.json";break;case"eu":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Basque.json";break;case"be":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Belarusian.json";break;case"bg":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Bulgarian.json";break;case"ca":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Catalan.json";break;case"zh":languageURL="zh_TW"==WPGMZA.locale?WPGMZA.pluginDirURL+"languages/datatables/Chinese-traditional.json":"//cdn.datatables.net/plug-ins/1.10.12/i18n/Chinese.json";break;case"hr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Croatian.json";break;case"cs":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Czech.json";break;case"da":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Danish.json";break;case"nl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Dutch.json";break;case"et":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Estonian.json";break;case"fi":languageURL=WPGMZA.locale.match(/^fil/)?WPGMZA.pluginDirURL+"languages/datatables/Filipino.json":WPGMZA.pluginDirURL+"languages/datatables/Finnish.json";break;case"fr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/French.json";break;case"gl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Galician.json";break;case"ka":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Georgian.json";break;case"de":languageURL=WPGMZA.pluginDirURL+"languages/datatables/German.json";break;case"el":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Greek.json";break;case"gu":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Gujarati.json";break;case"he":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Hebrew.json";break;case"hi":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Hindi.json";break;case"hu":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Hungarian.json";break;case"is":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Icelandic.json";break;case"id":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Indonesian.json";break;case"ga":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Irish.json";break;case"it":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Italian.json";break;case"ja":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Japanese.json";break;case"kk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Kazakh.json";break;case"ko":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Korean.json";break;case"ky":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Kyrgyz.json";break;case"lv":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Latvian.json";break;case"lt":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Lithuanian.json";break;case"mk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Macedonian.json";break;case"ml":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Malay.json";break;case"mn":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Mongolian.json";break;case"ne":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Nepali.json";break;case"nb":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Norwegian-Bokmal.json";break;case"nn":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Norwegian-Nynorsk.json";break;case"ps":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Pashto.json";break;case"fa":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Persian.json";break;case"pl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Polish.json";break;case"pt":languageURL="pt_BR"==WPGMZA.locale?WPGMZA.pluginDirURL+"languages/datatables/Portuguese-Brasil.json":"//cdn.datatables.net/plug-ins/1.10.12/i18n/Portuguese.json";break;case"ro":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Romanian.json";break;case"ru":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Russian.json";break;case"sr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Serbian.json";break;case"si":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Sinhala.json";break;case"sk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Slovak.json";break;case"sl":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Slovenian.json";break;case"es":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Spanish.json";break;case"sw":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Swahili.json";break;case"sv":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Swedish.json";break;case"ta":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Tamil.json";break;case"te":languageURL=WPGMZA.pluginDirURL+"languages/datatables/telugu.json";break;case"th":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Thai.json";break;case"tr":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Turkish.json";break;case"uk":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Ukrainian.json";break;case"ur":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Urdu.json";break;case"uz":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Uzbek.json";break;case"vi":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Vietnamese.json";break;case"cy":languageURL=WPGMZA.pluginDirURL+"languages/datatables/Welsh.json"}return languageURL},WPGMZA.DataTable.prototype.onAJAXResponse=function(response){},WPGMZA.DataTable.prototype.reload=function(){this.dataTable.ajax.reload(null,!1)}}),jQuery(function($){WPGMZA.AdminFeatureDataTable=function(element){var self=this;this.allSelected=!1,WPGMZA.DataTable.call(this,element),this.initModals(),$(element).on("click",".wpgmza.bulk_delete",function(event){self.onBulkDelete(event)}),$(element).on("click",".wpgmza.select_all_markers",function(event){self.onSelectAll(event)}),$(element).on("click",".wpgmza.bulk_edit",function(event){self.onBulkEdit(event)}),$(element).on("click","[data-center-marker-id]",function(event){self.onCenterMarker(event)}),$(element).on("click","[data-duplicate-feature-id]",function(event){self.onDuplicate(event)}),$(element).on("click","[data-move-map-feature-id]",function(event){self.onMoveMap(event)})},WPGMZA.extend(WPGMZA.AdminFeatureDataTable,WPGMZA.DataTable),Object.defineProperty(WPGMZA.AdminFeatureDataTable.prototype,"featureType",{get:function(){return $(this.element).attr("data-wpgmza-feature-type")}}),Object.defineProperty(WPGMZA.AdminFeatureDataTable.prototype,"featurePanel",{get:function(){return WPGMZA.mapEditPage[this.featureType+"Panel"]}}),WPGMZA.AdminFeatureDataTable.prototype.initModals=function(){this.moveModal=!1,this.bulkEditorModal=!1,"marker"===this.featureType&&($(".wpgmza-map-select-modal").length&&(this.moveModal=WPGMZA.GenericModal.createInstance($(".wpgmza-map-select-modal"))),$(".wpgmza-bulk-marker-editor-modal").length&&(this.bulkEditorModal=WPGMZA.GenericModal.createInstance($(".wpgmza-bulk-marker-editor-modal"))))},WPGMZA.AdminFeatureDataTable.prototype.getDataTableSettings=function(){var self=this,options=WPGMZA.DataTable.prototype.getDataTableSettings.call(this);return options.createdRow=function(row,data,index){index=self.lastResponse.meta[index];row.wpgmzaFeatureData=index},options},WPGMZA.AdminFeatureDataTable.prototype.onBulkDelete=function(event){var self=this,ids=[],map=WPGMZA.maps[0],plural=this.featureType+"s";$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaFeatureData.id)}),confirm(WPGMZA.localized_strings.general_delete_prompt_text)&&(ids.forEach(function(marker_id){marker_id=map.getMarkerByID(marker_id);marker_id&&map.removeMarker(marker_id)}),WPGMZA.restAPI.call("/"+plural+"/",{method:"DELETE",data:{ids:ids},complete:function(){self.reload()}}))},WPGMZA.AdminFeatureDataTable.prototype.onSelectAll=function(event){this.allSelected=!this.allSelected;var self=this;$(this.element).find("input[name='mark']").each(function(){self.allSelected?$(this).prop("checked",!0):$(this).prop("checked",!1)})},WPGMZA.AdminFeatureDataTable.prototype.onBulkEdit=function(event){const self=this,ids=[];WPGMZA.maps[0];const plural=this.featureType+"s";$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaFeatureData.id)}),this.bulkEditorModal&&ids.length&&this.bulkEditorModal.show(function(data){data.ids=ids,data.action="bulk_edit",WPGMZA.restAPI.call("/"+plural+"/",{method:"POST",data:data,success:function(response,status,xhr){self.reload()}})})},WPGMZA.AdminFeatureDataTable.prototype.onCenterMarker=function(event){var event=null==event.currentTarget?event:$(event.currentTarget).attr("data-center-marker-id"),event=WPGMZA.mapEditPage.map.getMarkerByID(event);event&&(event=new WPGMZA.LatLng({lat:event.lat,lng:event.lng}),WPGMZA.mapEditPage.map.setCenter(event),WPGMZA.InternalEngine.isLegacy()&&WPGMZA.animateScroll("#wpgmaps_tabs_markers"))},WPGMZA.AdminFeatureDataTable.prototype.onDuplicate=function(event){const self=this;let id=!1;id=null==event.currentTarget?event:$(event.currentTarget).attr("data-duplicate-feature-id");event=this.featureType+"s";WPGMZA.restAPI.call("/"+event+"/",{method:"POST",data:{id:id,action:"duplicate"},success:function(response,status,xhr){self.reload()}})},WPGMZA.AdminFeatureDataTable.prototype.onMoveMap=function(event){const self=this;let id=!1,plural=(id=null==event.currentTarget?event:$(event.currentTarget).attr("data-move-map-feature-id"),this.featureType+"s");this.moveModal&&this.moveModal.show(function(data){data=!!data.map_id&&parseInt(data.map_id);data&&WPGMZA.restAPI.call("/"+plural+"/",{method:"POST",data:{id:id,map_id:data,action:"move_map"},success:function(response,status,xhr){self.reload()}})})}}),jQuery(function($){WPGMZA.AdminMapDataTable=function(element){var self=this;this.allSelected=!1,WPGMZA.DataTable.call(this,element),$(element).on("mousedown","button[data-action='edit']",function(event){switch(event.which){case 1:var map_id=$(event.target).attr("data-map-id");window.location.href=window.location.href+"&action=edit&map_id="+map_id;break;case 2:map_id=$(event.target).attr("data-map-id");window.open(window.location.href+"&action=edit&map_id="+map_id)}}),$(element).find(".wpgmza.select_all_maps").on("click",function(event){self.onSelectAll(event)}),$(element).find(".wpgmza.bulk_delete_maps").on("click",function(event){self.onBulkDelete(event)}),$(element).on("click","button[data-action='duplicate']",function(event){event=$(event.target).attr("data-map-id");WPGMZA.restAPI.call("/maps/",{method:"POST",data:{id:event,action:"duplicate"},success:function(response,status,xhr){self.reload()}})}),$(element).on("click","button[data-action='trash']",function(event){confirm(WPGMZA.localized_strings.map_delete_prompt_text)&&(event=$(event.target).attr("data-map-id"),WPGMZA.restAPI.call("/maps/",{method:"DELETE",data:{id:event},success:function(response,status,xhr){self.reload()}}))})},WPGMZA.extend(WPGMZA.AdminMapDataTable,WPGMZA.DataTable),WPGMZA.AdminMapDataTable.prototype.getDataTableSettings=function(){var self=this,options=WPGMZA.DataTable.prototype.getDataTableSettings.call(this);return options.createdRow=function(row,data,index){index=self.lastResponse.meta[index];row.wpgmzaMapData=index},options},WPGMZA.AdminMapDataTable.prototype.onSelectAll=function(event){this.allSelected=!this.allSelected;var self=this;$(this.element).find("input[name='mark']").each(function(){self.allSelected?$(this).prop("checked",!0):$(this).prop("checked",!1)})},WPGMZA.AdminMapDataTable.prototype.onBulkDelete=function(event){var self=this,ids=[];$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaMapData.id)}),confirm(WPGMZA.localized_strings.map_bulk_delete_prompt_text)&&WPGMZA.restAPI.call("/maps/",{method:"DELETE",data:{ids:ids},complete:function(){self.reload()}})},$(document).ready(function(event){$("[data-wpgmza-admin-map-datatable]").each(function(index,el){WPGMZA.AdminMapDataTable=new WPGMZA.AdminMapDataTable(el)})})}),jQuery(function($){WPGMZA.AdminMarkerDataTable=function(element){var self=this;this.preventCaching=!0,WPGMZA.DataTable.call(this,element),$(element).on("click","[data-delete-marker-id]",function(event){self.onDeleteMarker(event)}),$(element).find(".wpgmza.select_all_markers").on("click",function(event){self.onSelectAll(event)}),$(element).find(".wpgmza.bulk_delete").on("click",function(event){self.onBulkDelete(event)}),$(element).on("click","[data-center-marker-id]",function(event){self.onCenterMarker(event)})},WPGMZA.AdminMarkerDataTable.prototype=Object.create(WPGMZA.DataTable.prototype),WPGMZA.AdminMarkerDataTable.prototype.constructor=WPGMZA.AdminMarkerDataTable,WPGMZA.AdminMarkerDataTable.createInstance=function(element){return new WPGMZA.AdminMarkerDataTable(element)},WPGMZA.AdminMarkerDataTable.prototype.getDataTableSettings=function(){var self=this,options=WPGMZA.DataTable.prototype.getDataTableSettings.call(this);return options.createdRow=function(row,data,index){index=self.lastResponse.meta[index];row.wpgmzaMarkerData=index},options},WPGMZA.AdminMarkerDataTable.prototype.onEditMarker=function(event){WPGMZA.animatedScroll("#wpgmaps_tabs_markers")},WPGMZA.AdminMarkerDataTable.prototype.onDeleteMarker=function(event){var self=this,id=$(event.currentTarget).attr("data-delete-marker-id"),event={action:"delete_marker",security:WPGMZA.legacyajaxnonce,map_id:WPGMZA.mapEditPage.map.id,marker_id:id};$.post(ajaxurl,event,function(response){WPGMZA.mapEditPage.map.removeMarkerByID(id),self.reload()})},WPGMZA.AdminMarkerDataTable.prototype.onApproveMarker=function(event){var cur_id=$(this).attr("id"),cur_id={action:"approve_marker",security:WPGMZA.legacyajaxnonce,map_id:WPGMZA.mapEditPage.map.id,marker_id:cur_id};$.post(ajaxurl,cur_id,function(response){wpgmza_InitMap(),wpgmza_reinitialisetbl()})},WPGMZA.AdminMarkerDataTable.prototype.onSelectAll=function(event){$(this.element).find("input[name='mark']").prop("checked",!0)},WPGMZA.AdminMarkerDataTable.prototype.onBulkDelete=function(event){var self=this,ids=[],map=WPGMZA.maps[0];$(this.element).find("input[name='mark']:checked").each(function(index,el){el=$(el).closest("tr")[0];ids.push(el.wpgmzaMarkerData.id)}),ids.forEach(function(marker_id){marker_id=map.getMarkerByID(marker_id);marker_id&&map.removeMarker(marker_id)}),WPGMZA.restAPI.call("/markers/",{method:"DELETE",data:{ids:ids},complete:function(){self.reload()}})},WPGMZA.AdminMarkerDataTable.prototype.onCenterMarker=function(event){var event=null==event.currentTarget?event:$(event.currentTarget).attr("data-center-marker-id"),event=WPGMZA.mapEditPage.map.getMarkerByID(event);event&&(event=new WPGMZA.LatLng({lat:event.lat,lng:event.lng}),WPGMZA.mapEditPage.map.setCenter(event),WPGMZA.mapEditPage.map.setZoom(6),WPGMZA.InternalEngine.isLegacy()&&WPGMZA.animateScroll("#wpgmaps_tabs_markers"))}});
js/v8/wp-google-maps.min.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["./wp-google-maps/js/v8/wp-google-maps.combined.js"],"names":["jQuery","$","core","MARKER_PULL_DATABASE","MARKER_PULL_XML","PAGE_MAP_LIST","PAGE_MAP_EDIT","PAGE_SETTINGS","PAGE_STYLING","PAGE_SUPPORT","PAGE_INSTALLER","PAGE_CATEGORIES","PAGE_ADVANCED","PAGE_CUSTOM_FIELDS","maps","events","settings","restAPI","localized_strings","loadingHTML","preloaderHTML","getCurrentPage","WPGMZA","getQueryParamValue","window","location","href","match","getScrollAnimationOffset","scroll_animation_offset","height","getScrollAnimationDuration","scroll_animation_milliseconds","animateScroll","element","milliseconds","offset","animate","scrollTop","top","extend","child","parent","constructor","prototype","Object","create","guid","d","Date","getTime","performance","now","replace","c","r","Math","random","floor","toString","hexOpacityToRGBA","colour","opacity","hex","parseInt","parseFloat","hexOpacityToString","arr","hexToRgba","test","substring","split","length","join","g","b","a","rgbaToString","rgba","latLngRegexp","isLatLngString","str","m","LatLng","lat","lng","stringToLatLng","result","Error","isHexColorString","imageDimensionsCache","getImageDimensions","src","callback","img","document","createElement","onload","event","width","decodeEntities","input","e","String","fromCharCode","isDeveloperMode","this","developer_mode","Cookies","get","isProVersion","_isProVersion","openMediaDialog","config","file_frame","uploader","param","set_to_post_id","open","wp","media","frames","title","button","text","multiple","on","attachment","state","first","toJSON","id","url","getCurrentPosition","error","watch","options","nativeFunction","userLocationDenied","code","message","navigator","geolocation","enableHighAccuracy","position","trigger","err","console","warn","watchPosition","runCatchableTask","friendlyErrorContainer","friendlyError","FriendlyError","html","append","show","capitalizeWords","string","toUpperCase","pluralize","singularize","assertInstanceOf","instance","instanceName","pro","engine","fullInstanceName","getMapByID","i","isGoogleAutocompleteSupported","google","places","Autocomplete","CloudAPI","isBeingUsed","googleAPIStatus","wpgmza_google_api_status","isSafari","ua","userAgent","toLowerCase","isTouchDevice","isDeviceiOS","MSStream","platform","isModernComponentStyleAllowed","user_interface_style","isElementInView","pageTop","pageBottom","elementTop","elementBottom","isFullScreen","wpgmzaisFullScreen","name","regex","RegExp","decodeURIComponent","notification","time","arguments","setTimeout","find","remove","initMaps","body","each","index","el","wpgmzaMap","Map","createInstance","ex","nextInitTimeoutID","initCapsules","capsuleModules","CapsuleModules","onScroll","isInView","wpgmzaScrollIntoViewTriggerFlag","initInstallerRedirect","hide","key","uc","reloadOnOptIn","reloadOnOptOut","WPGMZA_localized_data","value","useLegacyGlobals","fullscreenElement","preventDefault","ajax","ajaxurl","method","data","action","nonce","ajaxnonce","set","reload","altKey","altKeyDown","elements","filter","protocol","warning","InternalEngine","isLegacy","unsecure_geolocation","after","RestAPI","cloudAPI","Compatibility","preventDocumentWriteGoogleMapsAPI","old","write","content","call","compatiblityModule","root","factory","exports","module","define","amd","bind","global","CSS","escape","cssEscape","TypeError","codeUnit","firstCodeUnit","charCodeAt","charAt","PI","deg2rad","deg","Distance","MILES","KILOMETERS","MILES_PER_KILOMETER","KILOMETERS_PER_MILE","uiToMeters","uiDistance","distance_units","uiToKilometers","uiToMiles","kilometersToUI","km","between","lat1","lon1","lat2","lon2","dLat","dLon","sin","cos","atan2","sqrt","EliasFano","isSupported","decodingTablesInitialised","createDecodingTable","decodingTableHighBits","decodingTableDocIDNumber","decodingTableHighBitsCarryover","Uint8Array","zeroCount","j","encode","list","lastDocID","buffer1","bufferLength1","buffer2","bufferLength2","compressedBufferPointer1","compressedBufferPointer2","averageDelta","averageDeltaLog","log2","lowBitsLength","lowBitsMask","prev","maxCompressedSize","ceil","compressedBuffer","forEach","docID","docIDDelta","isNumeric","unaryCodeLength","pointer","decode","resultPointer","lowBitsPointer","listCount","lowBitsCount","lowBits","cb","highBitsPointer","docIDNumber","EventDispatcher","_listenersByType","addEventListener","type","listener","thisObject","useCapture","types","Function","target","hasOwnProperty","push","removeEventListener","obj","splice","off","hasEventListener","dispatchEvent","Event","path","unshift","phase","CAPTURING_PHASE","_cancelled","_triggerListeners","AT_TARGET","BUBBLING_PHASE","topMostElement","customEvent","AddressInput","map","HTMLInputElement","json","fields","attr","JSON","parse","wpgmza_store_locator_restrict","country","googleMapsApiKey","googleAutoComplete","setComponentRestrictions","cloudAutoComplete","CloudAutocomplete","proxies","capsules","prepareCapsules","flagCapsules","getConstructor","ProCapsuleModules","proxyMap","markers","showPreloader","getMarkerByID","markerFilter","MarkerFilter","let","addClass","registerStoreLocator","mapId","mapProxy","capsule","StoreLocator","isCapsule","redirectUrl","ColorInput","dataAttributes","format","anchor","container","autoClose","autoOpen","supportAlpha","supportPalette","wheelBorderWidth","wheelPadding","wheelBorderColor","parseOptions","initialized","sliderInvert","lockSlide","lockPicker","mouse","down","color","h","s","l","wrap","renderControls","parseColor","clamp","min","max","isNaN","degreesToRadians","degrees","hueToRgb","p","q","t","getMousePositionInCanvas","canvas","rect","getBoundingClientRect","x","clientX","left","y","clientY","assign","getColor","override","hsl","rgb","hslToRgb","rgbToHex","setColor","updatePreview","commit","update","trim","indexOf","parts","rgbToHsl","hexToRgb","bounds","delta","repeat","slice","floatToPrecision","chroma","abs","exp","diff","round","float","precision","toFixed","self","insertAfter","onTogglePicker","preview","swatch","picker","stopPropagation","renderPicker","renderWheel","renderFields","renderPalette","wheel","handle","slider","radius","degreeStep","context","getContext","clearRect","grid","fillStyle","fillRect","onPickerMouseSelect","clearStates","group","toggle","blocks","hsla","keys","view","updateFieldView","rows","labels","controls","label","originalEvent","currentTarget","onFieldChange","palette","variations","mutator","variation","control","elem","css","updateWheel","center","pattern","createPattern","beginPath","arc","closePath","fill","startAngle","endAngle","moveTo","gradient","createRadialGradient","strokeGradient","addColorStop","lineWidth","strokeStyle","stroke","createLinearGradient","shadow","updateHandles","updateFields","updatePalette","localRadius","localHandleOffset","handleStyles","sliderDegrees","sliderStyles","background","val","localPosition","dir","angle","distance","range","pickerScaler","pickerEdge","field","block","closest","raw","tA","toggleClass","hasClass","syncValue","ready","wpgmzaColorInput","CSSBackdropFilterInput","filters","blur","enable","unit","brightness","contrast","grayscale","hue_rotate","invert","sepia","saturate","parseFilters","FILTER_PATTERN","VALUE_PATTERN","getFilters","setFilters","clearFilters","matches","Array","valueArg","numericValue","itemWrappers","printType","wrapper","toggleWrap","toggleInput","toggleLabel","controlWrap","controlAttributes","controlInput","controlLabel","slide","ui","change","wpgmzaRelativeSlider","is","setFilterState","removeClass","setFilterValue","row","prop","wpgmzaCSSBackdropFilterInput","CSSFilterInput","wpgmzaCSSFilterInput","CSSStateBlock","HTMLElement","tabs","items","bindEvents","click","onClick","item","wpgmzaCSSStateBlock","CSSUnitInput","suffix","parseUnits","VALID_TYPES","getUnits","setUnits","validateSuffix","unitValueInput","unitSuffixToggle","unitValueStepDownBtn","unitValueStepUpBtn","unitValueStepperWrap","unitInnerWrap","increment","decrement","defaultSuffix","wpgmzaCSSUnitInput","DrawingManager","mode","MODE_NONE","onMapClick","MODE_MARKER","MODE_POLYGON","MODE_POLYLINE","MODE_CIRCLE","MODE_RECTANGLE","MODE_HEATMAP","MODE_POINTLABEL","MODE_IMAGEOVERLAY","OLDrawingManager","GoogleDrawingManager","setDrawingMode","pointlabel","Pointlabel","latLng","addPointlabel","setEditable","onPointlabelComplete","enginePointlabel","EmbeddedMedia","apply","corners","handles","activeCorner","onMoveHandle","onDeactivateHandle","onDetach","detatchAll","querySelectorAll","wpgmzaEmbeddedMedia","onSelect","destroyHandles","onActivateHandle","corner","getMousePosition","maxTop","getAnchorPosition","applyResize","createHandles","mutating","bindHandle","padding","maxWidth","pos","pageX","pageY","bubbles","cancelable","PHASE_CAPTURE","FancyControls","formatToggleSwitch","div","parentNode","replaceWith","formatToggleButton","yes","no","Feature","MapObject","parseGeometry","subject","coords","results","pairs","setOptions","updateNativeFeature","editable","setDraggable","draggable","getScalarProperties","props","layer","setStyle","OLFeature","getOLStyle","googleFeature","GenericModal","complete","cancel","_onComplete","_onCancel","ProGenericModal","onComplete","onCancel","getData","Geocoder","SUCCESS","ZERO_RESULTS","FAIL","GoogleGeocoder","OLGeocoder","getLatLngFromAddress","address","getAddressFromLatLng","geocode","GoogleAPIErrorHandler","_error","currentPage","is_admin","userCanAdministrator","googleMapsAPIErrorDialog","errorMessageList","templateListItem","messagesAlreadyDisplayed","onErrorMessage","wpgmza_google_maps_api_key","addErrorMessage","no_google_maps_api_key","urls","li","clone","buttonContainer","buttonTemplate","documentation","z-index","googleAPIErrorHandler","InfoWindow","feature","onOpen","STATE_CLOSED","onFeatureAdded","OPEN_BY_CLICK","OPEN_BY_HOVER","STATE_OPEN","GoogleProInfoWindow","GoogleInfoWindow","OLProInfoWindow","OLInfoWindow","defineProperty","getContent","contentHtml","addEditButton","Marker","workOutDistanceBetweenTwoMarkers","location1","location2","distanceToDisplay","distanceUnits","extra_html","store_locator_show_distance","storeLocator","STATE_APPLIED","currentLatLng","getPosition","store_locator_distance","kilometers_away","miles_away","disable_infowindows","wpgmza_settings_disable_infowindows","disableInfoWindow","close","setContent","infoopen","Installer","currentApiKey","step","findMax","next","triggerSubStep","setEngine","setApiKey","setTileServer","getAutoKey","launcher","launchQuickStart","defaultEngine","loadStep","NODE_SERVER","prepareAddressFields","addressInput","loadSubSteps","autoFocus","applyStepConditionState","stepWrapper","latitude","longitude","geocoder","domain","hostname","paths","pathname","getActiveBlock","focus","saveOptions","apiKey","server","previewLink","tileServer","condition","continueButton","hasSatisfiedStepCondition","satisfied","popupDimensions","screen","attributes","formData","wpgmza_maps_engine","tile_server_url","api_key","success","response","status","xhr","hideAutoKeyError","showAutoKeyError","codeOrMsg","installer","LEGACY","ATLAS_NOVUS","internalEngine","getEngine","InternalViewport","limits","getContainer","RECT_TYPE_LARGE","RECT_TYPE_MEDIUM","RECT_TYPE_SMALL","CONTAINER_THRESHOLD_MEDIUM","CONTAINER_THRESHOLD_SMALL","getRectType","wrapMeasurement","trace","localize","traceLimits","overlays","panels","offsetWidth","offsetHeight","max_width","localized","tag","replaceAll","classes","arg","_lat","_lng","REGEXP","isValid","fromString","fromCurrentPosition","geocodeAddress","fromGoogleLatLng","googleLatLng","toGoogleLatLngArray","nativeLatLng","toGoogleLatLng","toLatLngLiteral","moveByDistance","kilometers","heading","theta","phi1","lambda1","sinPhi1","cosPhi1","sinDelta","cosDelta","sinTheta","sinPhi2","phi2","asin","lambda2","getGreatCircleDistance","arg1","arg2","other","toRadians","deltaPhi","deltaLambda","LatLngBounds","southWest","northEast","south","north","west","east","fromGoogleLatLngBounds","googleLatLngBounds","getSouthWest","getNorthEast","fromGoogleLatLngBoundsLiteral","southwest","northeast","isInInitialState","undefined","extendByPixelMargin","latLngToPixels","pixelsToLatLng","contains","toLiteral","legacyGlobals","marker_pull","marker_array","MYMAP","infoWindow_poly","markerClusterer","heatmap","WPGM_Path","WPGM_Path_Polygon","WPGM_PathLine","WPGM_PathLineData","WPGM_PathData","original_iw","wpgmza_user_marker","wpgmaps_localize_marker_data","wpgmaps_localize_polygon_settings","wpgmaps_localize_heatmap_settings","wpgmaps_localize_polyline_settings","wpgmza_cirtcle_data_array","wpgmza_rectangle_data_array","wpgmzaForceLegacyMarkerClusterer","bindLegacyGlobalProperty","InitMap","resetLocations","searchLocations","fillInAddress","searchLocationsNear","MapListPage","$temp","select","execCommand","mapListPage","MapSettings","getAttribute","addSettings","other_settings","toOLViewOptions","ol","proj","fromLonLat","zoom","empty","start_location","map_start_lng","map_start_lat","start_zoom","map_start_zoom","map_min_zoom","map_max_zoom","minZoom","maxZoom","toGoogleMapsOptions","latLngCoords","formatCoord","coord","isSettingDisabled","zoomControl","wpgmza_settings_map_zoom","panControl","wpgmza_settings_map_pan","mapTypeControl","wpgmza_settings_map_type","streetViewControl","wpgmza_settings_map_streetview","fullscreenControl","wpgmza_settings_map_full_screen_control","wpgmza_settings_map_draggable","disableDoubleClickZoom","wpgmza_settings_map_clickzoom","wpgmza_settings_map_tilt_controls","rotateControl","tilt","wpgmza_settings_map_scroll","scrollwheel","wpgmza_force_greedy_gestures","gestureHandling","mapTypeId","MapTypeId","SATELLITE","HYBRID","TERRAIN","ROADMAP","wpgmza_theme_data","styles","GoogleMap","parseThemeData","elementor","hasAttribute","engineElement","polygons","polylines","circles","rectangles","pointlabels","api_consent_html","loadSettings","loadStyling","shortcodeAttributes","innerStack","setDimensions","setAlignment","initInternalViewport","onInit","fullscreen","onFullScreenChange","wpgmzaLegacyGlobals","mc","init","placeMarkers","nightTimeThemeData","elementType","stylers","featureType","GoogleProMap","OLProMap","OLMap","_markersPlaced","getCenter","setCenter","getZoom","setZoom","initPreloader","initStoreLocator","autoFetchFeatures","fetchFeatures","preloader","stylingSettings","tileFilter","wpgmza_ol_tile_filter","internalViewport","storeLocatorElement","getFeatureArrays","arrays","heatmaps","imageoverlays","getRESTParameters","defaults","stringify","getFilteringParameters","fetchFeaturesViaREST","limit","includeUnapproved","excludeIntegrated","acf_post_id","acfPostID","fetchFeaturesXhr","abort","fetchMarkersBatchSize","enable_batch_loading","fetchNextBatch","useCompressedPathVariable","onMarkersFetched","exclude","onFeaturesFetched","fetchFeaturesViaXML","markerXMLPathURL","fetchFeaturesExcludingMarkersViaREST","map_id","mashup_ids","mashupIDs","Worker","Blob","URL","enable_asynchronous_xml_parsing","source","loadXMLAsWebWorker","blob","worker","createObjectURL","onmessage","postMessage","command","filesLoaded","converter","XMLCacheConverter","converted","concat","convert","wpgmza_settings_marker_pull","substr","expectMoreBatches","startFiltered","cat","marker","isFiltered","setVisible","addMarker","triggerEvent","categories","fitMapBoundsToMarkers","getGeographicDistance","map_width","map_width_type","map_height","map_height_type","wpgmza_map_align","removeMarker","infoWindow","removeAllMarkers","getMarkerByTitle","removeMarkerByID","addPolygon","polygon","Polygon","removePolygon","getPolygonByID","removePolygonByID","getPolylineByID","addPolyline","polyline","Polyline","removePolyline","removePolylineByID","addCircle","circle","Circle","removeCircle","getCircleByID","removeCircleByID","addRectangle","rectangle","Rectangle","removeRectangle","getRectangleByID","removeRectangleByID","removePointlabel","getPointlabelByID","removePointlabelByID","resetBounds","latlng","panTo","nudge","nudged","nudgeLatLng","pixels","animateNudge","origin","onWindowResize","onElementResized","onBoundsChanged","onIdle","hasVisibleMarkers","isFilterable","getVisible","closeAllInfoWindows","openStreetView","closeStreetView","invisibleMaps","visibilityWorkaroundIntervalID","setInterval","toArray","MapsEngineDialog","wpgmzaUnbindSaveReminder","remodal","onButtonClicked","wpgmza_maps_engine_dialog_done","mapsEngineDialog","params","filteredMarkers","filteringParams","onFilteringComplete","updateTimeoutID","hideAll","allowByFilter","_offset","description","link","icon","approved","pic","setPosition","onAdded","handleLegacyGlobals","GoogleProMarker","GoogleMarker","OLProMarker","OLMarker","ANIMATION_NONE","ANIMATION_BOUNCE","ANIMATION_DROP","updateOffset","onMouseOver","_osDisableAutoPan","openInfoWindow","cloned","pro_version","marker_id","initInfoWindow","lastInteractedMarker","wpgmza_settings_map_open_marker_by","getIcon","stripProtocol","defaultMarkerIcon","default_marker_icon","setOffset","getAnimation","anim","setAnimation","animation","visible","getMap","setMap","getDraggable","setOpacity","panIntoView","ModernStoreLocatorCircle","mapElement","mapSize","initCanvasLayer","shadowColor","shadowBlur","centerRingRadius","centerRingLineWidth","numInnerRings","innerRingLineWidth","innerRingFade","numOuterRings","ringLineWidth","mainRingLineWidth","numSpokes","spokesStartAngle","numRadiusLabels","radiusLabelsStartAngle","radiusLabelFont","GoogleModernStoreLocatorCircle","OLModernStoreLocatorCircle","onResize","draw","onUpdate","functionName","getResolutionScale","devicePixelRatio","getRadius","setRadius","getTransformedRadius","getCanvasDimensions","validateSettings","canvasDimensions","canvasWidth","canvasHeight","setTransform","end","scale","getScale","getWorldOriginOffset","worldPoint","translate","getCenterPixels","ringSpacing","grad","start","save","spokeAngle","setLineDash","lineTo","restore","font","textAlign","textBaseline","textAngle","radiusString","rotate","measureText","fillText","ModernStoreLocator","original","inner","numCategories","icons","store_locator_query_string","titleSearch","placeholder","store_locator_name_string","keyCode","searchButton","resetButton","STATE_INITIAL","children","category_id","wpgmza_category_data","image","background-image","prepend","optionsButton","before","padding-left","outerWidth","onMouseOverCategory","onMouseLeaveCategory","position_cat","$p_map","p_cat","outerHeight","padding-bottom","GoogleModernStoreLocator","OLModernStoreLocator","stop","fadeIn","fadeOut","NativeMapsAppIcon","PersistentAdminNotice","dismissButton","ajaxActionButton","onDismiss","onAjaxAction","slug","wpgmza_security","relay","wpgmzaPersistentAdminNotice","enumerable","_map","textFeature","GoogleProPointlabel","GooglePointlabel","OLProPointlabel","OLPointlabel","createEditableMarker","setIcon","labelpointIcon","_prevMap","_dragEndCallback","onDragEnd","onMapMouseDown","_mouseDown","onWindowMouseUp","onMapMouseMove","begin","external","enginePolygon","fillcolor","linecolor","lineopacity","linethickness","GoogleProPolygon","GooglePolygon","OLProPolygon","OLPolygon","engineObject","googlePolyline","_layergroup","Shape","BASE_LAYER_INDEX","GooglePolyline","OLPolyline","getPoints","points","layergroup","setLayergroup","zIndex","PopoutPanel","sendAJAXFallbackRequest","route","addNonce","CONTEXT_AJAX","resturl","useAJAXFallback","CONTEXT_REST","serverCanInflate","Version","compare","EQUAL_TO","disable_compressed_path_variables","enable_compressed_path_variables","compressParams","markerIDs","encoded","compressed","pako","deflate","ch","btoa","midcbp","TextEncoder","getNonce","restnoncetable","sort","setRESTNonce","shouldAddNonce","setRequestHeader","restnonce","base","beforeSend","isAdmin","includes","compressedParams","compressedRoute","attemptedCompressedPathVariable","fallbackRoute","fallbackParams","post","simulateDelete","isCompressedPathVariableSupported","isCompressedPathVariableAllowed","base64","isServerIIS","cache","skip_cache","maxURLLength","compressedPathVariableURLLimitWarningDisplayed","onSuccess","rawResult","parseExc","nativeCallFunction","dismiss_blocked_notice","$_GET","query","wpgmza_i","wpgmza_l","aux","SettingsPage","_keypressHistory","_codemirrors","updateEngineSpecificControls","updateStorageControls","updateBatchControls","updateGDPRControls","updateWooControls","onKeyPress","ttype","confirm","wpgmza_dz_nonce","alert","settingsPage","flushGeocodeCache","elmnt","getElementById","classList","add","pageYOffset","scrollTo","behavior","activate","refresh","wrapAll","CodeMirror","fromTextArea","lineNumbers","theme","removeAttr","showNoticeControls","vgmCheckbox","showOverrideTextarea","clearCache","_developerModeRevealed","Parent","engineFeature","engineCircle","ProShape","lineColor","lineOpacity","OLProCircle","OLCircle","GoogleProCircle","GoogleCircle","engineRectangle","cornerA","cornerB","OLProRectangle","OLRectangle","GoogleProRectangle","GoogleRectangle","SidebarGroupings","actionBar","dynamicAction","dynamicLabel","openTab","openTabByFeatureType","closeCurrent","resetScroll","initUpsellBlocks","tab","groupId","openTabByGroupId","mapEditPage","hasGroup","closeAll","updateActionBar","upsellWrappers","currentWrapper","cardLength","nextCard","nextCardElem","_center","addressElement","radiusElement","wpgmza_store_locator_default_radius","onGeocodeComplete","store_locator_style","legacyModernAdapter","onSearch","onReset","which","onQueryParamSearch","_bounds","store_locator_bounce","_marker","_circle","wpgmza_store_locator_radius_style","strokeColor","strokeOpacity","strokeWeight","fillColor","fillOpacity","clickable","circleStrokeColor","onRedirectSearch","setVisualState","countryRestriction","address_not_found","showError","URLSearchParams","getZoomFromRadius","log","LN2","factor","store_locator_not_found_message","zero_results","queryCenter","queryRadius","errorElement","StylingPage","styleGuide","prepareControl","applyPreset","parseUserPreset","PRESETS","default","--wpgmza-component-color","--wpgmza-component-text-color","--wpgmza-component-color-accent","--wpgmza-component-text-color-accent","--wpgmza-color-grey-500","--wpgmza-component-border-radius","--wpgmza-component-font-size","--wpgmza-component-backdrop-filter","glass","rounded","activeInput","colorInput","unitInput","resetControl","updateControl","steps","backdropInput","user","fieldName","preset","fieldValue","stylingPage","SupportPage","info","temp","supportPage","Text","GoogleText","OLText","overlay","setText","setFontSize","size","setFillColor","setLineColor","ThemeEditor","olThemeEditor","OLThemeEditor","appendTo","initHTML","themeEditor","updatePosition","features","all","administrative","landscape","poi","road","transit","water","geometry","textarea","refreshColorInputs","parseJSON","isArray","jsonCopy","highlightFeatures","highlightElements","loadElementStylers","v","ii","vv","hue","lightness","xaturation","gamma","visibility","weight","writeElementStylers","new_feature_element_stylers","indexJSON","saturation","invert_lightness","themePanel","updateMapTheme","ThemePanel","olThemePanel","OLThemePanel","owlCarousel","dots","onThemePresetClick","previewImageCenter","previewImageZoom","selectedData","existingData","allPresetData","overwrite_theme_data","invalid_theme_data","GREATER_THAN","LESS_THAN","v1","v2","v1parts","v2parts","xml","remap","linkd","nodeName","tXml","f","tagName","k","searchId","exec","lastIndexOf","simplify","simplefy","_attributes","domToXml","O","inputData","totalFiles","dataForMainThread","onXMLLoaded","request","readyState","node","convertAndAppend","responseText","loadNextFile","XMLHttpRequest","onreadystatechange","send","Integration","integrationModules","Blocks","instances","__","registerBlockType","InspectorControls","_wp$components","Dashicon","PanelBody","i18n","editor","components","_wp$editor","BlockControls","Toolbar","Button","Tooltip","TextareaControl","CheckboxControl","TextControl","SelectControl","RichText","Gutenberg","getBlockDefinition","getBlockTitle","getBlockInspectorControls","React","class","adminurl","aria-hidden","getBlockAttributes","_this","category","verifyCategory","keywords","edit","isSelected","className","getCategories","gutenberg","onclick","GoogleUICompatibility","style","vendor","head","googleUICompatibility","googleCircle","wpgmzaCircle","addListener","ProCircle","googleOptions","googleDrawingManager","drawing","drawingControl","polygonOptions","polylineOptions","circleOptions","rectangleOptions","googleMap","onPolygonClosed","onPolylineComplete","onCircleComplete","onRectangleComplete","googleMode","OverlayType","POLYGON","POLYLINE","CIRCLE","RECTANGLE","onVertexClicked","googlePolygon","enginePolyline","googleRectangle","onImageoverlayComplete","onHeatmapPointAdded","googleMarker","imageFolderURL","Point","engineImageoverlay","componentRestrictions","nativeStatus","GeocoderStatus","OK","NO_ADDRESS","fullResult","NO_RESULTS","formatted_address","GoogleHTMLOverlay","OverlayView","onAdd","getPanes","overlayMouseTarget","appendChild","onRemove","updateElementPosition","projection","getProjection","fromLatLngToDivPixel","setFeature","Z_INDEX","ProInfoWindow","googleObject","createGoogleInfoWindow","googleInfoWindow","setZIndex","disableAutoPan","intervalID","eaBtn","clearInterval","wpgmzaFeature","loadGoogleMap","wpgmzaEvent","getStreetView","pov","getPov","pitch","ProMap","eval","bicycle","enableBicycleLayer","traffic","enableTrafficLayer","transport_layer","enablePublicTransportLayer","showPointsOfInterest","wpgmza_show_point_of_interest","initializing","hide_point_of_interest","getBounds","nativeBounds","topLeft","bottomRight","fitBounds","fitBoundsToVisibleMarkers","bicycleLayer","BicyclingLayer","trafficLayer","TrafficLayer","publicTransportLayer","TransitLayer","getMinZoom","min_zoom","setMinZoom","getMaxZoom","max_zoom","setMaxZoom","topRight","fromLatLngToPoint","bottomLeft","pow","fromPointToLatLng","enableAllInteractions","setPov","firstChild","_stackedComponentsMoved","innerContainer","wpgmzaMarker","googleMarkerPosition","ProMarker","_opacity","setLabel","Image","defaultAnchor","canvasLayer","resize_","setAnimate","CanvasLayer","resizeHandler","updateHandler","resolutionScale","scheduleUpdate","spherical","equator","offsetAtEquator","computeOffset","getTopLeft","destroy","restrict","ControlPosition","TOP_CENTER","pointFeature","ProPointlabel","polydata","wpgmzaPolygon","ProPolygon","getEditable","getOptions","getPaths","getPath","removeAt","vertex","getGeometry","getLength","getAt","setPath","wpgmzaPolyline","wpgmzaRectangle","ProRectangle","GoogleTextOverlay","minWidth","floatPane","GoogleVertexContextMenu","innerHTML","addDomListener","removeVertex","divListener","getDiv","removeListener","removeChild","point","FeaturePanel","drawingManager","writersblock","initDefaults","setMode","MODE_ADD","drawingInstructionsElement","detach","editingInstructionsElement","newPanel","onTabActivated","oldPanel","onTabDeactivated","onEditFeature","onDeleteFeature","onSave","drawingManagerCompleteEvent","onDrawingComplete","onDrawingModeChanged","onPropertyChanged","MODE_EDIT","prevEditableFeature","wpgmzaDataTable","_mode","initDataTable","AdminFeatureDataTable","setCaptionType","featureAccordion","sidebarTriggerDelegate","setTargetFeature","onFeatureChanged","showInstructions","reset","tinyMCE","WritersBlock","expectedBaseClass","functionSuffix","populate","imageInputSingle","wpgmzaImageInputSingle","parseImage","serializeFormData","discardChanges","updateFeatureByID","getByIDFunction","removeFunction","addFunction","featureString","onAddFeature","general_delete_prompt_text","featureDataTable","dataTable","processing","geometryField","nativeFeature","_dirtyFields","isNew","no_shape_polyline","no_shape_polygon","no_shape_rectangle","no_shape_circle","eventType","initWritersBlock","getWritersBlockConfig","onEditorChange","customTools","tools","custom-media","mediaId","mediaUrl","writeHtml","library","code-editor","_codeEditorActive","_codeEditor","toolbarItems","toolbar","tool","setAttribute","__editor","editedHtml","validator","sourceHtml","enabledTools","onUpdateSelection","packet","pingedSelection","getSelection","hidePopupTools","hasDirtyField","MarkerPanel","ProMarkerPanel","adjustSubMode","onAdjustFeature","onApproveMarker","addressField","aPos","geocodingData","cloud_lat","cloud_lng","addressUnchanged","getElementsByName","no_address","geocode_fail","CirclePanel","ProCirclePanel","wpgmza_autoCompleteDisabled","MapEditPage","ajaxRequest","wrapInner","sidebarGroupings","initDataTables","initFeaturePanels","initJQueryUIControls","locale","buttonClass","colorBtn","clipboard","readText","then","textcopy","catch","c_ex","wpgmzaAjaxTimeout","wpgmzaStartTyping","wpgmzaKeyStrokeCount","wpgmzaAvgTimeBetweenStrokes","wpgmzaTotalTimeForKeyStrokes","wpgmzaTmp","wpgmzaIdentifiedTypingSpeed","wpgmza_apikey","clearTimeout","wpgmzaCurrentTimeBetweenStrokes","currentSearch","wpgmza_api_url","siteHash","dataType","cloud_api_key_error_1","exception","onMapHeightTypeChange","onShiftClick","onMapTypeChanged","onMarkerUpdated","onZoomChanged","onRightClick","onDeletePolygon","onDeletePolyline","evevnt","onDeleteHeatmap","onDeleteCircle","onDeleteRectangle","nearestRow","nearestHint","shortcode","ProMapEditPage","featurePanelElement","panelClassName","mapContainer","checkbox","lastSelectedRow","shiftKey","prevIndex","currIndex","startIndex","endIndex","markerDataTable","rightClickMarker","cur_id","security","wpgmza_legacy_map_edit_page_vars","ajax_nonce","poly_id","circle_id","circle_array","rectangle_id","rectangle_array","PointlabelPanel","PolygonPanel","ProPolygonPanel","PolylinePanel","ProPolylinePanel","RectanglePanel","ProRectanglePanel","olFeature","geom","toLonLat","Vector","getSource","addFeature","getFeatures","setProperties","setInteractionsOnFeature","lonLat","recreate","circle3857","removeFeature","circular","transform","wrapX","Stroke","Fill","Style","endEventType","interaction","olMap","removeInteraction","selectInteraction","geometryFunction","Draw","createBox","WPGMZAEvent","addInteraction","assertInstangeOf","translated","modifyInteraction","snapInteraction","Snap","Modify","getResponseFromCache","lon","getResponseFromNominatim","countrycodes","cacheResponse","finish","boundingbox","display_name","removeOverlay","Overlay","stopEvent","insertFirst","addOverlay","renderMode","RENDER_MODE_VECTOR_LAYER","autoResize","max-width","imgs","numImages","numImagesLoaded","canAutoPan","inside","viewport","right","bottom","isPanIntoViewAllowed","mapWidth","mapHeight","maxHeight","viewOptions","layers","getTileLayer","getTileView","customTileMode","extent","containsCoordinate","customTileModeExtent","getView","wrapLongitude","getInteractions","DragPan","setActive","DoubleClickZoom","MouseWheelZoom","gestureOverlay","gestureOverlayTimeoutID","olBrowserEvent","allowed","PointerEvent","targetPointers","TouchEvent","touches","showGestureOverlay","use_two_fingers","platformModifierKeyOnly","use_ctrl_scroll_to_zoom","getControls","Zoom","removeControl","addControl","FullScreen","markerLayer","addLayer","getFeaturesAtPixel","pixel","isBeingDragged","_mouseoverNativeFeatures","dragging","featuresUnderPixel","nativeFeaturesUnderPixel","getProperties","isRight","offsetX","offsetY","tile_server_url_override","open_layers_api_key","custom_tile_enabled","custom_tile_image_width","custom_tile_image_height","custom_tile_image","Projection","units","ImageStatic","attributions","custom_tile_image_attribution","imageExtent","Tile","OSM","View","transformed","calculateExtent","getSize","boundingExtent","fit","duration","RENDER_MODE_HTML_ELEMENT","featureInSource","removeLayer","getCoordinateFromPixel","getPixelFromCoordinate","line-height","updateSize","parentOffset","relX","relY","updateElementHeight","positioning","rebindClickListener","getVectorLayerStyle","defaultVectorLayerStyle","Icon","hiddenVectorLayerStyle","vectorLayerStyle","calledOnFocus","one","addLabel","getLabelText","getElement","display","setGeometry","disabled","jQueryDraggableInitialized","onDragStart","pixelsBeforeDrag","pixelsAfterDrag","latLngAfterDrag","onElementClick","olViewportElement","renderFunction","outer","centerPixels","outerPixels","un","coordinates","getCoordinates","LineString","olStyle","getExtent","getBottomRight","topLeftLonLat","bottomRightLonLat","topLeftLatLng","bottomRightLatLng","OLTextOverlay","styleOptions","getStyle","fontSize","labelStyles","placement","getText","onFilterChange","DataTable","version","fn","wpgmza_do_not_enqueue_datatables","ext","errMode","Api","register","iterator","ctx","oApi","_fnProcessingDisplay","dataTableElement","getDataTableElement","getDataTableSettings","phpClass","getLanguageURL","languageJSON","onAJAXRequest","onDataTableAjaxRequest","preventCaching","lastResponse","MarkerIcon","applyToElement","languageURL","deferLoading","serverSide","AdvancedTableDataTable","wpgmza_default_items","iDisplayLength","aLengthMenu","language","pluginDirURL","onAJAXResponse","allSelected","initModals","onBulkDelete","onSelectAll","onBulkEdit","onCenterMarker","onDuplicate","onMoveMap","moveModal","bulkEditorModal","createdRow","meta","wpgmzaFeatureData","ids","plural","AdminMapDataTable","map_delete_prompt_text","wpgmzaMapData","map_bulk_delete_prompt_text","AdminMarkerDataTable","onDeleteMarker","wpgmzaMarkerData","onEditMarker","animatedScroll","legacyajaxnonce","wpgmza_InitMap","wpgmza_reinitialisetbl"],"mappings":"AAMAA,OAAO,SAASC,GAEf,IAAIC,KAAO,CACVC,qBAAsB,IACtBC,gBAAkB,IAElBC,cAAkB,WA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