@visitscotland/component-library 5.59.3 → 5.59.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -14684,7 +14684,7 @@ const prototypes = {
|
|
|
14684
14684
|
checkOverflow: checkOverflow$1,
|
|
14685
14685
|
classes
|
|
14686
14686
|
}, extendedDefaults = {};
|
|
14687
|
-
let Swiper$1 = class
|
|
14687
|
+
let Swiper$1 = class ae {
|
|
14688
14688
|
constructor(...n) {
|
|
14689
14689
|
let t, s;
|
|
14690
14690
|
n.length === 1 && n[0].constructor && Object.prototype.toString.call(n[0]).slice(8, -1) === "Object" ? s = n[0] : [t, s] = n, s || (s = {}), s = extend$1({}, s), t && !s.el && (s.el = t);
|
|
@@ -14695,7 +14695,7 @@ let Swiper$1 = class se {
|
|
|
14695
14695
|
const d = extend$1({}, s, {
|
|
14696
14696
|
el: c
|
|
14697
14697
|
});
|
|
14698
|
-
l.push(new
|
|
14698
|
+
l.push(new ae(d));
|
|
14699
14699
|
}), l;
|
|
14700
14700
|
}
|
|
14701
14701
|
const r = this;
|
|
@@ -14979,12 +14979,12 @@ let Swiper$1 = class se {
|
|
|
14979
14979
|
return defaults;
|
|
14980
14980
|
}
|
|
14981
14981
|
static installModule(n) {
|
|
14982
|
-
|
|
14983
|
-
const t =
|
|
14982
|
+
ae.prototype.__modules__ || (ae.prototype.__modules__ = []);
|
|
14983
|
+
const t = ae.prototype.__modules__;
|
|
14984
14984
|
typeof n == "function" && t.indexOf(n) < 0 && t.push(n);
|
|
14985
14985
|
}
|
|
14986
14986
|
static use(n) {
|
|
14987
|
-
return Array.isArray(n) ? (n.forEach((t) =>
|
|
14987
|
+
return Array.isArray(n) ? (n.forEach((t) => ae.installModule(t)), ae) : (ae.installModule(n), ae);
|
|
14988
14988
|
}
|
|
14989
14989
|
};
|
|
14990
14990
|
Object.keys(prototypes).forEach((e) => {
|
|
@@ -32839,17 +32839,17 @@ const useGoogleMapStore = defineStore("googleMap", () => {
|
|
|
32839
32839
|
onMounted(() => {
|
|
32840
32840
|
a.selectedDestinationType = n[0].id;
|
|
32841
32841
|
});
|
|
32842
|
-
const o = (
|
|
32842
|
+
const o = (d) => a.selectedDestinationType === d ? "primary" : "secondary", i = n.filter((d) => d.id !== "towns"), l = {
|
|
32843
32843
|
cities: "fa-regular fa-city",
|
|
32844
32844
|
regions: "fa-regular fa-map-location-dot",
|
|
32845
32845
|
islands: "fa-regular fa-island-tropical",
|
|
32846
32846
|
towns: "fa-regular fa-house-chimney-window",
|
|
32847
32847
|
"national-parks": "fa-kit fa-vs-icon-national-park"
|
|
32848
32848
|
};
|
|
32849
|
-
function
|
|
32850
|
-
a.selectedDestinationType =
|
|
32849
|
+
function c(d) {
|
|
32850
|
+
a.selectedDestinationType = d, s();
|
|
32851
32851
|
}
|
|
32852
|
-
return (
|
|
32852
|
+
return (d, u) => (openBlock(), createElementBlock("div", _hoisted_1$2, [
|
|
32853
32853
|
createVNode(VsDetail, {
|
|
32854
32854
|
color: "secondary",
|
|
32855
32855
|
size: "small"
|
|
@@ -32860,15 +32860,15 @@ const useGoogleMapStore = defineStore("googleMap", () => {
|
|
|
32860
32860
|
_: 1
|
|
32861
32861
|
}),
|
|
32862
32862
|
createElementVNode("div", _hoisted_2$2, [
|
|
32863
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(
|
|
32864
|
-
key:
|
|
32865
|
-
icon:
|
|
32863
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(i), (f) => (openBlock(), createBlock(VsButton, {
|
|
32864
|
+
key: f.id,
|
|
32865
|
+
icon: l[f.id],
|
|
32866
32866
|
size: "sm",
|
|
32867
|
-
variant: o(
|
|
32868
|
-
onClick: (
|
|
32867
|
+
variant: o(f.id),
|
|
32868
|
+
onClick: (m) => c(f.id)
|
|
32869
32869
|
}, {
|
|
32870
32870
|
default: withCtx(() => [
|
|
32871
|
-
createTextVNode(toDisplayString(
|
|
32871
|
+
createTextVNode(toDisplayString(f.label), 1)
|
|
32872
32872
|
]),
|
|
32873
32873
|
_: 2
|
|
32874
32874
|
}, 1032, ["icon", "variant", "onClick"]))), 128))
|
|
@@ -32876,9 +32876,9 @@ const useGoogleMapStore = defineStore("googleMap", () => {
|
|
|
32876
32876
|
createElementVNode("div", _hoisted_3$2, [
|
|
32877
32877
|
createVNode(VsRow, { class: "vs-map__destinations" }, {
|
|
32878
32878
|
default: withCtx(() => [
|
|
32879
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(t), (
|
|
32880
|
-
key:
|
|
32881
|
-
place:
|
|
32879
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(t), (f) => (openBlock(), createBlock(_sfc_main$3, {
|
|
32880
|
+
key: f.properties.id,
|
|
32881
|
+
place: f
|
|
32882
32882
|
}, null, 8, ["place"]))), 128))
|
|
32883
32883
|
]),
|
|
32884
32884
|
_: 1
|
|
@@ -33490,7 +33490,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
|
|
|
33490
33490
|
}), o.addListener("tilesloaded", () => {
|
|
33491
33491
|
B.value || (B.value = !0, ke());
|
|
33492
33492
|
}), o.addListener("idle", () => {
|
|
33493
|
-
k = Me(), !ie.value && de.value && he(oe(o)) && (ue.value = !0, P.selectedDestinationType = "", de.value = !1);
|
|
33493
|
+
k = Me(), !ie.value && de.value && he(oe(o)) && (ue.value = !0, P.selectedDestinationType = "", se.value = "", de.value = !1);
|
|
33494
33494
|
}), l.addEventListener("gmp-select", ({ place: z }) => {
|
|
33495
33495
|
v[z.id] && ve(z, v[z.id]);
|
|
33496
33496
|
}), c.addEventListener("gmp-select", ({ place: z }) => {
|
|
@@ -33595,7 +33595,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
|
|
|
33595
33595
|
const q = Object.fromEntries(
|
|
33596
33596
|
X.map((j) => [j.id, j.label])
|
|
33597
33597
|
);
|
|
33598
|
-
E.value = `${q[F]} ${
|
|
33598
|
+
E.value = `${q[F]} ${se.value}`, p.value = E.value, P.showCategories = !0, ue.value = !1;
|
|
33599
33599
|
}
|
|
33600
33600
|
function ge(F, z) {
|
|
33601
33601
|
const q = ref([]), j = ref();
|
|
@@ -33629,10 +33629,10 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
|
|
|
33629
33629
|
}));
|
|
33630
33630
|
}
|
|
33631
33631
|
function $e(F, z) {
|
|
33632
|
-
if (I.value = z,
|
|
33632
|
+
if (I.value = z, se.value = "", F === "self-catering" && !b.value.has("self-catering")) {
|
|
33633
33633
|
D.value = !0, Ce(), b.value = /* @__PURE__ */ new Set(), b.value.add(F);
|
|
33634
33634
|
const q = ge(b.value, F).value;
|
|
33635
|
-
E.value = q, p.value = `${E.value} ${
|
|
33635
|
+
E.value = q, p.value = `${E.value} ${se.value}`, be(), p.value = q;
|
|
33636
33636
|
} else b.value.has(F) ? (b.value.delete("self-catering"), b.value.delete(F), N.value = /* @__PURE__ */ new Set(), C.value = /* @__PURE__ */ new Set(), b.value.forEach((q) => {
|
|
33637
33637
|
xe(q, {
|
|
33638
33638
|
includeTypes: !0,
|
|
@@ -33651,7 +33651,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
|
|
|
33651
33651
|
excludedTypes: Array.from(C.value).flat()
|
|
33652
33652
|
}), L.value.add(
|
|
33653
33653
|
ge(b.value, F).value
|
|
33654
|
-
), E.value = `${Array.from(L.value).join(", ")} ${
|
|
33654
|
+
), E.value = `${Array.from(L.value).join(", ")} ${se.value}`, p.value = E.value, P.showCategories = !0);
|
|
33655
33655
|
}
|
|
33656
33656
|
async function _e({
|
|
33657
33657
|
includedTypes: F = [],
|
|
@@ -33662,7 +33662,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
|
|
|
33662
33662
|
P.filterUsesCount += 1, $.value = "nearby";
|
|
33663
33663
|
const j = o.getBounds(), W = j.getNorthEast(), G = j.getSouthWest(), Z = google.maps.geometry.spherical.computeDistanceBetween(W, G);
|
|
33664
33664
|
let te = 25e3;
|
|
33665
|
-
(P.selectedDestinationType === "regions" || P.selectedDestinationType === "islands" &&
|
|
33665
|
+
(P.selectedDestinationType === "regions" || P.selectedDestinationType === "islands" && se.value === "Shetland" || P.selectedDestinationType === "islands" && se.value === "Orkney") && (te = 5e4);
|
|
33666
33666
|
const le = Math.min(Z / 2, te);
|
|
33667
33667
|
u.includedTypes = F, u.excludedTypes = z ?? [], u.maxResultCount = NUMBER_OF_RESULTS, u.locationRestriction = {
|
|
33668
33668
|
center: o.getCenter(),
|
|
@@ -33815,9 +33815,9 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
|
|
|
33815
33815
|
}
|
|
33816
33816
|
return z;
|
|
33817
33817
|
}
|
|
33818
|
-
const
|
|
33818
|
+
const se = ref("");
|
|
33819
33819
|
function Ee(F) {
|
|
33820
|
-
P.showDestinations = !1,
|
|
33820
|
+
P.showDestinations = !1, se.value = F.properties.title, J(() => o.fitBounds(
|
|
33821
33821
|
// eslint-disable-next-line no-undef
|
|
33822
33822
|
new google.maps.LatLngBounds(
|
|
33823
33823
|
// eslint-disable-next-line no-undef
|
|
@@ -33840,7 +33840,7 @@ const _hoisted_1 = { class: "vs-map" }, _hoisted_2 = { class: "vs-map__controls"
|
|
|
33840
33840
|
)), fe("things-to-do", 2);
|
|
33841
33841
|
}
|
|
33842
33842
|
function Ie() {
|
|
33843
|
-
if (P.showDestinations = !1, P.sidebarOpen = !0,
|
|
33843
|
+
if (P.showDestinations = !1, P.sidebarOpen = !0, se.value = "", ue.value = !1, b.value.size > 0) {
|
|
33844
33844
|
if (b.value.has("self-catering"))
|
|
33845
33845
|
b.value.delete("self-catering"), $e("self-catering", 0);
|
|
33846
33846
|
else {
|
package/package.json
CHANGED