@visitscotland/component-library 5.21.1 → 5.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  import { createElementBlock, openBlock, renderSlot, resolveComponent, createBlock, normalizeClass, withCtx, createElementVNode, createVNode, withDirectives, createCommentVNode, normalizeStyle, vShow, inject, mergeProps, toDisplayString, ref, onMounted, onUnmounted, createTextVNode, Fragment, renderList, resolveDirective, withModifiers, normalizeProps, createSlots, getCurrentInstance, defineComponent, computed as computed$1, watch, reactive, provide, onBeforeMount, isRef, onBeforeUnmount, unref, isReactive, isReadonly, nextTick, isVNode, markRaw, toRef, resolveDynamicComponent, h, withKeys, mergeModels, useModel, toHandlers, vModelText, guardReactiveProps, onUpdated, Suspense } from "vue";
2
- import { _ as _export_sfc, V as VsButton, d as dataLayerMixin, a as VsHeading, n as nn, b as an, c as VsIcon, r as rn, l as lodashExports, e as VsBody, f as VsContainer, g as VsRow, h as VsCol, i as ci, p as pi$2, j as en, k as dmoUrls, m as VsImg, E as Ed, o as axios, q as designTokens, Y as Yo, Z as Zo, s as pn, O as Ou, T as Tu, t as ku, u as VsWarning, v as fn, w as un, X as Xi, x as commonjsGlobal, y as require$$0$1, z as requireHasown, A as requireShams, B as callBound, C as isGeneratorFunction, D as isTypedArray, F as whichTypedArray, G as getAugmentedNamespace, H as getDefaultExportFromCjs, L as Lu, I as ld, J as _a, K as products, M as paths, N as monthsEnglish, P as VsLoading, Q as ol, R as wn, S as Ea, U as Bn, W as Je, $ as St, a0 as Pa, a1 as Ka, a2 as vc, a3 as dc, a4 as useDataLayerStore, a5 as checkVendorLibrary, a6 as siteSearchCloseTemplate, a7 as siteSearchClickTemplate, a8 as siteSearchUsageTemplate, a9 as siteSearchOpenTemplate, aa as googleMapInteractionTemplate, ab as googleMapTimeToFirstInteractionTemplate, ac as googleMapClickTemplate, ad as googleMapFilterInteractionTemplate, ae as googleMapSearchTemplate } from "./LoadingSpinner-BV9HMdg5.mjs";
3
- import { af as Se } from "./LoadingSpinner-BV9HMdg5.mjs";
2
+ import { _ as _export_sfc, V as VsButton, d as dataLayerMixin, a as VsHeading, n as nn, b as an, c as VsIcon, r as rn, l as lodashExports, e as VsBody, f as VsContainer, g as VsRow, h as VsCol, i as ci, p as pi$2, j as en, k as dmoUrls, m as VsImg, E as Ed, o as axios, q as designTokens, Y as Yo, Z as Zo, s as pn, O as Ou, T as Tu, t as ku, u as VsWarning, v as fn, w as un, X as Xi, x as commonjsGlobal, y as require$$0$1, z as requireHasown, A as requireShams, B as callBound, C as isGeneratorFunction, D as isTypedArray, F as whichTypedArray, G as getAugmentedNamespace, H as getDefaultExportFromCjs, L as Lu, I as ld, J as _a, K as products, M as paths, N as monthsEnglish, P as VsLoading, Q as ol, R as wn, S as Ea, U as Bn, W as Je, $ as St, a0 as Pa, a1 as Ka, a2 as vc, a3 as dc, a4 as useDataLayerStore, a5 as checkVendorLibrary, a6 as siteSearchCloseTemplate, a7 as siteSearchClickTemplate, a8 as siteSearchUsageTemplate, a9 as siteSearchOpenTemplate, aa as googleMapInteractionTemplate, ab as googleMapTimeToFirstInteractionTemplate, ac as googleMapFilterInteractionTemplate, ad as googleMapSearchTemplate } from "./LoadingSpinner-Al46acPr.mjs";
3
+ import { ae as Se } from "./LoadingSpinner-Al46acPr.mjs";
4
4
  import { defineStore, storeToRefs } from "pinia";
5
5
  const _sfc_main$2t = {
6
6
  name: "VsAccordion",
@@ -35470,19 +35470,6 @@ function dataLayerComposable() {
35470
35470
  filter_usage_index: c.filter_usage_index
35471
35471
  }, f = s(d), p = a(googleMapFilterInteractionTemplate, f);
35472
35472
  break;
35473
- case "googleMapClickEvent":
35474
- u = "map_click_to_google_maps", d = {
35475
- event: u,
35476
- click_origin: c.click_origin,
35477
- attraction_name: c.attraction_name,
35478
- attraction_rating: c.attraction_rating,
35479
- attraction_category: c.attraction_category,
35480
- search_map_location: c.search_map_location,
35481
- click_text: c.click_text,
35482
- click_url: c.click_url,
35483
- search_result_position: c.search_result_position
35484
- }, f = s(d), p = a(googleMapClickTemplate, f);
35485
- break;
35486
35473
  case "googleMapTimeToFirstInteractionEvent":
35487
35474
  u = "map_time_to_first_interaction", d = {
35488
35475
  event: u,
@@ -35498,6 +35485,7 @@ function dataLayerComposable() {
35498
35485
  map_location: c.map_location,
35499
35486
  visible_attractions_count: c.visible_attractions_count,
35500
35487
  card_attraction_name: c.card_attraction_name,
35488
+ card_attraction_url: c.card_attraction_url,
35501
35489
  card_attraction_rating: c.card_attraction_rating,
35502
35490
  interaction_timestamp_ms: c.interaction_timestamp_ms
35503
35491
  }, f = s(d), p = a(googleMapInteractionTemplate, f);
@@ -35541,6 +35529,16 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
35541
35529
  type: String,
35542
35530
  default: "vs-map"
35543
35531
  },
35532
+ /**
35533
+ * Rendering Type for the Map.
35534
+ * True = Vector Map, otherwise fallback to Raster
35535
+ * Vector Map enables support (with correct MapID) for advanced features like shading
35536
+ * Raster Maps are available for full compatibility across devices.
35537
+ */
35538
+ mapTypeVector: {
35539
+ type: Boolean,
35540
+ default: !1
35541
+ },
35544
35542
  /**
35545
35543
  * Center point of map.
35546
35544
  * Defaults to what is considered the center of Scotland
@@ -35675,8 +35673,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
35675
35673
  lat: t.center.lat,
35676
35674
  lng: t.center.lng
35677
35675
  },
35678
- // eslint-disable-next-line no-undef
35679
- renderingType: google.maps.RenderingType.VECTOR,
35676
+ renderingType: t.mapTypeVector ? google.maps.RenderingType.VECTOR : google.maps.RenderingType.RASTER,
35680
35677
  zoom: t.zoom,
35681
35678
  isFractionalZoomEnabled: !0,
35682
35679
  mapId: t.mapId,
@@ -35882,19 +35879,21 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
35882
35879
  });
35883
35880
  }
35884
35881
  async function G(Y, W) {
35885
- let J = "", ne = "";
35882
+ let J = "", ne = "", ae = "";
35886
35883
  W && (await W.fetchFields({
35887
35884
  fields: [
35888
35885
  "displayName",
35889
- "rating"
35886
+ "rating",
35887
+ "websiteURI"
35890
35888
  ]
35891
- }), J = W.displayName, ne = W.rating), n.createDataLayerObject("googleMapInteractionEvent", {
35889
+ }), J = W.displayName, ne = W.rating, ae = W.websiteURI), n.createDataLayerObject("googleMapInteractionEvent", {
35892
35890
  interaction_type: Y,
35893
35891
  search_query: d.value.trim(),
35894
35892
  map_location: a.getCenter().toString(),
35895
35893
  visible_attractions_count: m,
35896
35894
  card_attraction_name: J,
35897
35895
  card_attraction_rating: ne,
35896
+ card_attraction_url: ae,
35898
35897
  interaction_timestamp_ms: Date.now()
35899
35898
  }), U(Y);
35900
35899
  }