@visitscotland/component-library 1.0.26 → 1.0.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (22) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/client/manifest.json +42 -42
  3. package/dist/client/scripts/39c81d98eb88fed09973.js +1 -0
  4. package/dist/client/scripts/59531d6f4722d2e7b428.js +1 -0
  5. package/dist/client/scripts/{4a0169bf91e4e2397bcf.js → 735b36d8513eefa1d4c2.js} +1 -1
  6. package/dist/client/scripts/{c788c99f37db9b766c04.js → e2d75b0fff8d7d6c7f33.js} +1 -1
  7. package/dist/client/scripts/f8b6622c5200fd2be991.js +1 -0
  8. package/dist/ssr/index.js +1 -1
  9. package/dist/ssr/manifest.json +1 -1
  10. package/package.json +1 -1
  11. package/dist/client/scripts/715bb6a96d7bf32e6f14.js +0 -1
  12. package/dist/client/scripts/898c147b72953c7d8efb.js +0 -1
  13. package/dist/client/scripts/9f1410bbc12b850a2071.js +0 -1
  14. /package/dist/client/scripts/{f027bc5a4b3fd5eb22f1.js → 5c10419a0c7462f2f14d.js} +0 -0
  15. /package/dist/client/scripts/{1b952d87bc0aca49a896.js → 5c1f5cf47b7383235645.js} +0 -0
  16. /package/dist/client/scripts/{8c5347740d69b612c97c.js → 8468fdfd3cabfa7bffab.js} +0 -0
  17. /package/dist/client/styles/{898c147b72953c7d8efb.css → 39c81d98eb88fed09973.css} +0 -0
  18. /package/dist/client/styles/{9f1410bbc12b850a2071.css → 59531d6f4722d2e7b428.css} +0 -0
  19. /package/dist/client/styles/{f027bc5a4b3fd5eb22f1.css → 5c10419a0c7462f2f14d.css} +0 -0
  20. /package/dist/client/styles/{1b952d87bc0aca49a896.css → 5c1f5cf47b7383235645.css} +0 -0
  21. /package/dist/client/styles/{8c5347740d69b612c97c.css → 8468fdfd3cabfa7bffab.css} +0 -0
  22. /package/dist/ssr/styles/{854c3269072e84c1aae9.css → 2c4b49252fcc28b3d6a1.css} +0 -0
package/CHANGELOG.md CHANGED
@@ -2,6 +2,22 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [1.0.28](https://github.com/visitscotland/vs-component-library/compare/v1.0.27...v1.0.28) (2023-09-14)
6
+
7
+
8
+ ### 🐛 Bug Fixes
9
+
10
+ * **psw:** fix translations in PSW ([ab1e2b5](https://github.com/visitscotland/vs-component-library/commit/ab1e2b5f98e81c9d6806f7493cb7c42ea4105133))
11
+ * **psw:** retrieve language object on getLabel execution ([44ec5aa](https://github.com/visitscotland/vs-component-library/commit/44ec5aa44d8153de7c79e031aff5d94c57c77aee))
12
+ * **psw:** translate product names ([5ec842d](https://github.com/visitscotland/vs-component-library/commit/5ec842d6a845aaf7658dec874cd531b2f2e527aa))
13
+
14
+ ### [1.0.27](https://github.com/visitscotland/vs-component-library/compare/v1.0.26...v1.0.27) (2023-09-13)
15
+
16
+
17
+ ### 🐛 Bug Fixes
18
+
19
+ * **onetrust:** fix missing window in ssr error ([ad47d74](https://github.com/visitscotland/vs-component-library/commit/ad47d74d7d21650da2c209a1715183fb54c07b2c))
20
+
5
21
  ### [1.0.26](https://github.com/visitscotland/vs-component-library/compare/v1.0.25...v1.0.26) (2023-09-12)
6
22
 
7
23
 
@@ -201,7 +201,7 @@
201
201
  "scripts/b1355b8d61822d820c3c.js",
202
202
  "scripts/f8af198424679e336ce9.js",
203
203
  "scripts/3174db281106a2d5e619.js",
204
- "scripts/c788c99f37db9b766c04.js"
204
+ "scripts/e2d75b0fff8d7d6c7f33.js"
205
205
  ]
206
206
  },
207
207
  "VsCookiesFallback": {
@@ -927,7 +927,7 @@
927
927
  "scripts/c609148fc3e4bae68f67.js",
928
928
  "scripts/24228f9eee7eb5c30688.js",
929
929
  "scripts/3174db281106a2d5e619.js",
930
- "scripts/4a0169bf91e4e2397bcf.js",
930
+ "scripts/735b36d8513eefa1d4c2.js",
931
931
  "scripts/52a88ad64041afb98d43.js",
932
932
  "scripts/5cb7b258824862644a28.js",
933
933
  "scripts/68f7c6031293430987cd.js"
@@ -2001,7 +2001,7 @@
2001
2001
  "scripts/24228f9eee7eb5c30688.js",
2002
2002
  "scripts/af20ced2e34b6801258c.js",
2003
2003
  "scripts/3174db281106a2d5e619.js",
2004
- "scripts/4a0169bf91e4e2397bcf.js",
2004
+ "scripts/735b36d8513eefa1d4c2.js",
2005
2005
  "scripts/52a88ad64041afb98d43.js",
2006
2006
  "scripts/5cb7b258824862644a28.js",
2007
2007
  "scripts/9a5b8573e2af7b27fdeb.js",
@@ -2260,7 +2260,7 @@
2260
2260
  "scripts/24228f9eee7eb5c30688.js",
2261
2261
  "scripts/d0fd50a5b063d113a609.js",
2262
2262
  "scripts/3174db281106a2d5e619.js",
2263
- "scripts/4a0169bf91e4e2397bcf.js",
2263
+ "scripts/735b36d8513eefa1d4c2.js",
2264
2264
  "scripts/e4da1861edcade544efd.js"
2265
2265
  ],
2266
2266
  "styles": [
@@ -2909,7 +2909,7 @@
2909
2909
  "scripts/24228f9eee7eb5c30688.js",
2910
2910
  "scripts/af20ced2e34b6801258c.js",
2911
2911
  "scripts/3174db281106a2d5e619.js",
2912
- "scripts/4a0169bf91e4e2397bcf.js",
2912
+ "scripts/735b36d8513eefa1d4c2.js",
2913
2913
  "scripts/52a88ad64041afb98d43.js",
2914
2914
  "scripts/e3df89c35c49687c02b1.js",
2915
2915
  "scripts/1448817d8612666a0079.js",
@@ -4081,7 +4081,7 @@
4081
4081
  "scripts/24228f9eee7eb5c30688.js",
4082
4082
  "scripts/af20ced2e34b6801258c.js",
4083
4083
  "scripts/3174db281106a2d5e619.js",
4084
- "scripts/4a0169bf91e4e2397bcf.js",
4084
+ "scripts/735b36d8513eefa1d4c2.js",
4085
4085
  "scripts/52a88ad64041afb98d43.js",
4086
4086
  "scripts/5cb7b258824862644a28.js",
4087
4087
  "scripts/9a5b8573e2af7b27fdeb.js",
@@ -4136,7 +4136,7 @@
4136
4136
  "scripts/24228f9eee7eb5c30688.js",
4137
4137
  "scripts/af20ced2e34b6801258c.js",
4138
4138
  "scripts/3174db281106a2d5e619.js",
4139
- "scripts/4a0169bf91e4e2397bcf.js",
4139
+ "scripts/735b36d8513eefa1d4c2.js",
4140
4140
  "scripts/52a88ad64041afb98d43.js",
4141
4141
  "scripts/5cb7b258824862644a28.js",
4142
4142
  "scripts/9a5b8573e2af7b27fdeb.js",
@@ -4448,7 +4448,7 @@
4448
4448
  "scripts/af20ced2e34b6801258c.js",
4449
4449
  "scripts/d0fd50a5b063d113a609.js",
4450
4450
  "scripts/3174db281106a2d5e619.js",
4451
- "scripts/4a0169bf91e4e2397bcf.js",
4451
+ "scripts/735b36d8513eefa1d4c2.js",
4452
4452
  "scripts/52a88ad64041afb98d43.js",
4453
4453
  "scripts/5cb7b258824862644a28.js",
4454
4454
  "scripts/9a5b8573e2af7b27fdeb.js",
@@ -4507,7 +4507,7 @@
4507
4507
  "scripts/af20ced2e34b6801258c.js",
4508
4508
  "scripts/d0fd50a5b063d113a609.js",
4509
4509
  "scripts/3174db281106a2d5e619.js",
4510
- "scripts/4a0169bf91e4e2397bcf.js",
4510
+ "scripts/735b36d8513eefa1d4c2.js",
4511
4511
  "scripts/52a88ad64041afb98d43.js",
4512
4512
  "scripts/5cb7b258824862644a28.js",
4513
4513
  "scripts/9a5b8573e2af7b27fdeb.js",
@@ -4833,13 +4833,13 @@
4833
4833
  "scripts/3a9571cfaf25865bccc9.js",
4834
4834
  "scripts/d77b7b29af4fb24edbe0.js",
4835
4835
  "scripts/414cc4d3f993aab28a8f.js",
4836
- "scripts/715bb6a96d7bf32e6f14.js",
4836
+ "scripts/f8b6622c5200fd2be991.js",
4837
4837
  "scripts/6f8a69836503b59819ba.js",
4838
- "scripts/8c5347740d69b612c97c.js",
4838
+ "scripts/8468fdfd3cabfa7bffab.js",
4839
4839
  "scripts/891ff7a5d9b432a92b97.js"
4840
4840
  ],
4841
4841
  "styles": [
4842
- "styles/8c5347740d69b612c97c.css"
4842
+ "styles/8468fdfd3cabfa7bffab.css"
4843
4843
  ]
4844
4844
  },
4845
4845
  "VsGuestCounter": {
@@ -4907,17 +4907,17 @@
4907
4907
  "scripts/c609148fc3e4bae68f67.js",
4908
4908
  "scripts/e57aeb2f5204c61f5555.js",
4909
4909
  "scripts/bbffd3414a7c7fddbcd6.js",
4910
- "scripts/715bb6a96d7bf32e6f14.js",
4911
- "scripts/f027bc5a4b3fd5eb22f1.js",
4912
- "scripts/1b952d87bc0aca49a896.js",
4910
+ "scripts/f8b6622c5200fd2be991.js",
4911
+ "scripts/5c10419a0c7462f2f14d.js",
4912
+ "scripts/5c1f5cf47b7383235645.js",
4913
4913
  "scripts/1701a9402143e4b7b77c.js"
4914
4914
  ],
4915
4915
  "styles": [
4916
4916
  "styles/c1e52b98d340cd47fee7.css",
4917
4917
  "styles/c609148fc3e4bae68f67.css",
4918
4918
  "styles/bbffd3414a7c7fddbcd6.css",
4919
- "styles/f027bc5a4b3fd5eb22f1.css",
4920
- "styles/1b952d87bc0aca49a896.css"
4919
+ "styles/5c10419a0c7462f2f14d.css",
4920
+ "styles/5c1f5cf47b7383235645.css"
4921
4921
  ]
4922
4922
  },
4923
4923
  "VsGuestSelectorNumberGroup": {
@@ -4997,15 +4997,15 @@
4997
4997
  "scripts/c609148fc3e4bae68f67.js",
4998
4998
  "scripts/e57aeb2f5204c61f5555.js",
4999
4999
  "scripts/bbffd3414a7c7fddbcd6.js",
5000
- "scripts/715bb6a96d7bf32e6f14.js",
5001
- "scripts/f027bc5a4b3fd5eb22f1.js",
5000
+ "scripts/f8b6622c5200fd2be991.js",
5001
+ "scripts/5c10419a0c7462f2f14d.js",
5002
5002
  "scripts/37647589fe5f0407574d.js"
5003
5003
  ],
5004
5004
  "styles": [
5005
5005
  "styles/c1e52b98d340cd47fee7.css",
5006
5006
  "styles/c609148fc3e4bae68f67.css",
5007
5007
  "styles/bbffd3414a7c7fddbcd6.css",
5008
- "styles/f027bc5a4b3fd5eb22f1.css"
5008
+ "styles/5c10419a0c7462f2f14d.css"
5009
5009
  ]
5010
5010
  },
5011
5011
  "VsInputGroup": {
@@ -5100,26 +5100,26 @@
5100
5100
  "scripts/e57aeb2f5204c61f5555.js",
5101
5101
  "scripts/32ca64baf0af7b9faffa.js",
5102
5102
  "scripts/bbffd3414a7c7fddbcd6.js",
5103
- "scripts/715bb6a96d7bf32e6f14.js",
5104
- "scripts/f027bc5a4b3fd5eb22f1.js",
5103
+ "scripts/f8b6622c5200fd2be991.js",
5104
+ "scripts/5c10419a0c7462f2f14d.js",
5105
5105
  "scripts/6f8a69836503b59819ba.js",
5106
- "scripts/1b952d87bc0aca49a896.js",
5107
- "scripts/8c5347740d69b612c97c.js",
5106
+ "scripts/5c1f5cf47b7383235645.js",
5107
+ "scripts/8468fdfd3cabfa7bffab.js",
5108
5108
  "scripts/6c28685f52b01d108e4d.js",
5109
5109
  "scripts/aa3efed6b1f6232ce3fe.js",
5110
5110
  "scripts/96174af322a67416c0a9.js",
5111
- "scripts/9f1410bbc12b850a2071.js",
5111
+ "scripts/59531d6f4722d2e7b428.js",
5112
5112
  "scripts/97cddd3583069debb72b.js"
5113
5113
  ],
5114
5114
  "styles": [
5115
5115
  "styles/c1e52b98d340cd47fee7.css",
5116
5116
  "styles/c609148fc3e4bae68f67.css",
5117
5117
  "styles/bbffd3414a7c7fddbcd6.css",
5118
- "styles/f027bc5a4b3fd5eb22f1.css",
5119
- "styles/1b952d87bc0aca49a896.css",
5120
- "styles/8c5347740d69b612c97c.css",
5118
+ "styles/5c10419a0c7462f2f14d.css",
5119
+ "styles/5c1f5cf47b7383235645.css",
5120
+ "styles/8468fdfd3cabfa7bffab.css",
5121
5121
  "styles/6c28685f52b01d108e4d.css",
5122
- "styles/9f1410bbc12b850a2071.css"
5122
+ "styles/59531d6f4722d2e7b428.css"
5123
5123
  ]
5124
5124
  },
5125
5125
  "VsSelectInput": {
@@ -5228,16 +5228,16 @@
5228
5228
  "scripts/e57aeb2f5204c61f5555.js",
5229
5229
  "scripts/32ca64baf0af7b9faffa.js",
5230
5230
  "scripts/bbffd3414a7c7fddbcd6.js",
5231
- "scripts/715bb6a96d7bf32e6f14.js",
5232
- "scripts/f027bc5a4b3fd5eb22f1.js",
5231
+ "scripts/f8b6622c5200fd2be991.js",
5232
+ "scripts/5c10419a0c7462f2f14d.js",
5233
5233
  "scripts/6f8a69836503b59819ba.js",
5234
- "scripts/1b952d87bc0aca49a896.js",
5235
- "scripts/8c5347740d69b612c97c.js",
5234
+ "scripts/5c1f5cf47b7383235645.js",
5235
+ "scripts/8468fdfd3cabfa7bffab.js",
5236
5236
  "scripts/6c28685f52b01d108e4d.js",
5237
5237
  "scripts/aa3efed6b1f6232ce3fe.js",
5238
5238
  "scripts/96174af322a67416c0a9.js",
5239
- "scripts/9f1410bbc12b850a2071.js",
5240
- "scripts/898c147b72953c7d8efb.js"
5239
+ "scripts/59531d6f4722d2e7b428.js",
5240
+ "scripts/39c81d98eb88fed09973.js"
5241
5241
  ],
5242
5242
  "styles": [
5243
5243
  "styles/c1e52b98d340cd47fee7.css",
@@ -5246,12 +5246,12 @@
5246
5246
  "styles/ae5c80d270825f9d87fa.css",
5247
5247
  "styles/24228f9eee7eb5c30688.css",
5248
5248
  "styles/bbffd3414a7c7fddbcd6.css",
5249
- "styles/f027bc5a4b3fd5eb22f1.css",
5250
- "styles/1b952d87bc0aca49a896.css",
5251
- "styles/8c5347740d69b612c97c.css",
5249
+ "styles/5c10419a0c7462f2f14d.css",
5250
+ "styles/5c1f5cf47b7383235645.css",
5251
+ "styles/8468fdfd3cabfa7bffab.css",
5252
5252
  "styles/6c28685f52b01d108e4d.css",
5253
- "styles/9f1410bbc12b850a2071.css",
5254
- "styles/898c147b72953c7d8efb.css"
5253
+ "styles/59531d6f4722d2e7b428.css",
5254
+ "styles/39c81d98eb88fed09973.css"
5255
5255
  ]
5256
5256
  },
5257
5257
  "VsQuote": {
@@ -5759,7 +5759,7 @@
5759
5759
  "scripts/24228f9eee7eb5c30688.js",
5760
5760
  "scripts/af20ced2e34b6801258c.js",
5761
5761
  "scripts/3174db281106a2d5e619.js",
5762
- "scripts/4a0169bf91e4e2397bcf.js",
5762
+ "scripts/735b36d8513eefa1d4c2.js",
5763
5763
  "scripts/52a88ad64041afb98d43.js",
5764
5764
  "scripts/5cb7b258824862644a28.js",
5765
5765
  "scripts/9a5b8573e2af7b27fdeb.js",
@@ -6202,7 +6202,7 @@
6202
6202
  "scripts/c609148fc3e4bae68f67.js",
6203
6203
  "scripts/24228f9eee7eb5c30688.js",
6204
6204
  "scripts/3174db281106a2d5e619.js",
6205
- "scripts/4a0169bf91e4e2397bcf.js",
6205
+ "scripts/735b36d8513eefa1d4c2.js",
6206
6206
  "scripts/52a88ad64041afb98d43.js",
6207
6207
  "scripts/e3df89c35c49687c02b1.js",
6208
6208
  "scripts/1448817d8612666a0079.js",
@@ -0,0 +1 @@
1
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.VsProductSearch=e():t.VsProductSearch=e()}(self,(function(){return(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[7018],{42720:function(){},63529:function(t,e,n){"use strict";var r=n(81779),s=n(73366),o=n(22048),u=n(97809);e.Z={name:"VsProductSearch",status:"prototype",release:"0.0.1",components:{VsContainer:r.xB,VsRow:r.ou,VsCol:r.hY,VsProductSearchEmbed:u.default,VsHeading:s.default,VsWarning:o.default},props:{noJsMessage:{type:String,required:!0},defaultLocation:{type:String,default:""},defaultProd:{type:String,default:"acti,attr,reta"},defaultLocale:{type:String,default:"en"}}}},20823:function(t,e,n){"use strict";n.d(e,{s:function(){return a}});var r=n(66252),s=n(3577),o={class:"vs-product-search"},u={class:"vs-product-search__intro"};function a(t,e,n,a,c,l){var i=(0,r.up)("VsHeading"),d=(0,r.up)("VsCol"),f=(0,r.up)("VsProductSearchEmbed"),p=(0,r.up)("VsWarning"),_=(0,r.up)("VsRow"),v=(0,r.up)("VsContainer");return(0,r.wg)(),(0,r.iD)("div",o,[(0,r.Wm)(v,null,{default:(0,r.w5)((function(){return[(0,r.Wm)(_,null,{default:(0,r.w5)((function(){return[(0,r.Wm)(d,{class:"vs-product-search__col vs-product-search__col--left",xl:"7"},{default:(0,r.w5)((function(){return[(0,r.Wm)(i,{level:"2",alternative:"",class:"vs-product-search__heading mt-0"},{default:(0,r.w5)((function(){return[(0,r.WI)(t.$slots,"vs-module-heading")]})),_:3}),(0,r._)("div",u,[(0,r.WI)(t.$slots,"vs-module-intro")])]})),_:3}),(0,r.Wm)(d,{class:"vs-product-search__col vs-product-search__col--right",xl:"5"},{default:(0,r.w5)((function(){return[(0,r.Wm)(f,{class:"vs-product-search__widget","default-location":n.defaultLocation,"default-locale":n.defaultLocale,"default-prod":n.defaultProd},null,8,["default-location","default-locale","default-prod"]),(0,r.Wm)(p,{class:"vs-product-search__no-js"},{default:(0,r.w5)((function(){return[(0,r.Uk)((0,s.toDisplayString)(n.noJsMessage),1)]})),_:1})]})),_:1})]})),_:3})]})),_:3})])}},66217:function(t,e,n){"use strict";var r=n(93379),s=n.n(r),o=n(7795),u=n.n(o),a=n(90569),c=n.n(a),l=n(3565),i=n.n(l),d=n(19216),f=n.n(d),p=n(44589),_=n.n(p),v=n(42720),h=n.n(v),m={};m.styleTagTransform=_(),m.setAttributes=i(),m.insert=c().bind(null,"head"),m.domAPI=u(),m.insertStyleElement=f(),s()(h(),m),h()&&h().locals&&h().locals},65121:function(t,e,n){"use strict";n.r(e);var r=n(8468),s=n(11406);n(50144);const o=(0,n(83744).Z)(s.Z,[["render",r.s]]);e.default=o},11406:function(t,e,n){"use strict";n.d(e,{Z:function(){return r.Z}});var r=n(63529)},8468:function(t,e,n){"use strict";n.d(e,{s:function(){return r.s}});var r=n(20823)},50144:function(t,e,n){"use strict";n(66217)}},function(t){return t.O(0,[6252,3744,7991,9963,6486,2854,4942,6765,7169,7476,8764,7429,4300,7218,7370,5730,976,3918,7581,4186,1321,1779,3366,2048,7810,5643,2604,2147,2336,2278,7710,6971,9335,7175,501,7809],(function(){return 65121,t(t.s=65121)})),t.O()}])}));
@@ -0,0 +1 @@
1
+ (self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[7809],{28765:function(){},54955:function(e,t,n){"use strict";var a=n(93379),l=n.n(a),o=n(7795),r=n.n(o),u=n(90569),c=n.n(u),i=n(3565),s=n.n(i),d=n(19216),f=n.n(d),p=n(44589),v=n.n(p),m=n(28765),h=n.n(m),b={};b.styleTagTransform=v(),b.setAttributes=s(),b.insert=c().bind(null,"head"),b.domAPI=r(),b.insertStyleElement=f(),l()(h(),b),h()&&h().locals&&h().locals},43062:function(e,t,n){"use strict";var a=this&&this.__assign||function(){return a=Object.assign||function(e){for(var t,n=1,a=arguments.length;n<a;n++)for(var l in t=arguments[n])Object.prototype.hasOwnProperty.call(t,l)&&(e[l]=t[l]);return e},a.apply(this,arguments)},l=this&&this.__awaiter||function(e,t,n,a){return new(n||(n=Promise))((function(l,o){function r(e){try{c(a.next(e))}catch(e){o(e)}}function u(e){try{c(a.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?l(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,u)}c((a=a.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var n,a,l,o,r={label:0,sent:function(){if(1&l[0])throw l[1];return l[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(r=0)),r;)try{if(n=1,a&&(l=2&u[0]?a.return:u[0]?a.throw||((l=a.return)&&l.call(a),0):a.next)&&!(l=l.call(a,u[1])).done)return l;switch(a=0,l&&(u=[2&u[0],l.value]),u[0]){case 0:case 1:l=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,a=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(!((l=(l=r.trys).length>0&&l[l.length-1])||6!==u[0]&&2!==u[0])){r=0;continue}if(3===u[0]&&(!l||u[1]>l[0]&&u[1]<l[3])){r.label=u[1];break}if(6===u[0]&&r.label<l[1]){r.label=l[1],l=u;break}if(l&&r.label<l[2]){r.label=l[2],r.ops.push(u);break}l[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(e){u=[6,e],a=0}finally{n=l=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var u=n(76765),c=n(76765),i={class:"vs-product-search-embed"},s={key:0,class:"container"},d={class:"row"},f={class:"col-12"},p=["action","onSubmit"],v={"aria-live":"polite"},m=["disabled","value"],h=["disabled","value"],b=["value"],y={key:4,type:"hidden",name:"areaproxdist",value:"10"},k={key:5},g={key:3},w=[(0,c.createElementVNode)("input",{hidden:"true",name:"avail",value:"on"},null,-1)],_={key:0},N=["value"],T=n(76765),V=n(12147),x=n(61309),B=n(68504),E=n(83506),L=r(n(27175)),S=r(n(17710)),C=r(n(49335)),P=r(n(10501)),D=r(n(96971)),O=r(n(83918));t.default=(0,u.defineComponent)({__name:"ProductSearchEmbed",props:{defaultProd:{type:String,default:"acti,attr,reta"},defaultLocation:{type:String,default:""},defaultLocale:{type:String,default:""}},setup:function(e){var t=this,n=e,r=(0,T.ref)(!1),u=(0,T.ref)(),j=(0,T.ref)([]),U=((0,T.ref)(null),(0,T.ref)()),M=(0,T.ref)(!1),A=(0,T.computed)((function(){var e=void 0===u.value?"see-do":u.value;return"/info/".concat(x.paths[e])})),F=!1,I={en:{localeUrl:""},fr:{localeUrl:"fr-fr"},de:{localeUrl:"de-de"},es:{localeUrl:"es-es"},it:{localeUrl:"it-it"},nl:{localeUrl:"nl-nl"}},G=(0,T.computed)((function(){var e=n.defaultLocale.length>0?n.defaultLocale:(0,V.getLocale)();return"en"===e&&(e=""),e})),R=(0,T.computed)((function(){return"".concat(x.baseUrl.prod).concat(G.value?"/"+G.value:"").concat(A.value,"/search-results")})),J="https://www.visitscotland.com/data/locations?locale=".concat(G.value),Y=(0,T.ref)([]),K=function(e){U.value=Y.value.find((function(t){return t.name===e}))},q=(0,T.ref)([]),z=(0,T.ref)([]),H=(0,T.ref)([]),Q=function(){r.value=!0,(0,T.nextTick)((function(){r.value=!1}))},W=(0,T.computed)((function(){return r.value?[]:q.value.map((function(e){return a(a({},e),{displayName:(0,V.getProductName)(e.optionValue,e.displayName)})}))}));(0,T.onBeforeMount)((function(){return l(t,void 0,void 0,(function(){var e;return o(this,(function(t){return window.VS={},(e=document.createElement("script")).async=!1,e.onload=Q,e.setAttribute("src","https://www.visitscotland.com/".concat((I[n.defaultLocale]||"").localeUrl,"/data/template/search.js")),document.head.appendChild(e),[2]}))}))})),(0,T.onMounted)((function(){return l(t,void 0,void 0,(function(){var e,t,a;return o(this,(function(l){switch(l.label){case 0:return[4,(0,E.getData)(J)];case 1:return(e=l.sent())&&(Y.value=e.data),""!==n.defaultLocation&&K(n.defaultLocation),F=!0,u.value=n.defaultProd,o=(0,B.getProductTypes)(),r=[],o.forEach((function(e){r.push(e)})),q.value=r,[4,(0,E.getData)("https://www.visitscotland.com/tms-api/v1/attractions")];case 2:return(t=l.sent())&&(z.value=t.data),[4,(0,E.getData)("https://www.visitscotland.com/tms-api/v1/origins?active=1")];case 3:return(a=l.sent())&&(H.value=a.data),[2]}var o,r}))}))}));var X=function(e){M.value=!0;var t=e.currentTarget;setTimeout((function(){t.submit()}),500)};return function(t,n){var a,l,o,T,B,E;return(0,c.openBlock)(),(0,c.createElementBlock)("div",i,[r.value?(0,c.createCommentVNode)("",!0):((0,c.openBlock)(),(0,c.createElementBlock)("div",s,[(0,c.createElementVNode)("div",d,[(0,c.createElementVNode)("div",f,[(0,c.createElementVNode)("form",{action:R.value,onSubmit:(0,c.withModifiers)(X,["prevent"]),"accept-charset":"UTF-8"},[(0,c.createVNode)(C.default,{label:(0,c.unref)(V.getLabelText)("for","For"),id:"select-type",name:"prodtypes","default-selected":e.defaultProd,onChangeOption:n[0]||(n[0]=function(e){return u.value=e}),options:W.value},null,8,["label","default-selected","options"]),(0,c.createElementVNode)("div",v,["tour"!=u.value&&(0,c.unref)(F)?((0,c.openBlock)(),(0,c.createBlock)(L.default,{key:0,id:"search-location",label:(0,c.unref)(V.getLabelText)("location","Location"),"multiselect-label":"name",name:"loc",options:Y.value,placeholder:(0,c.unref)(V.getLabelText)("location_placeholder","Enter a location"),"track-by":"name",onChangeValue:n[1]||(n[1]=function(e){return K(e)}),"default-val":(0,c.unref)(U)},null,8,["label","options","placeholder","default-val"])):(0,c.createCommentVNode)("",!0),"tour"!==u.value?((0,c.openBlock)(),(0,c.createElementBlock)("input",{key:1,type:"hidden",name:"locplace",disabled:"POLYGON"===(null===(a=(0,c.unref)(U))||void 0===a?void 0:a.type),value:(null===(l=(0,c.unref)(U))||void 0===l?void 0:l.key)||""},null,8,m)):(0,c.createCommentVNode)("",!0),"tour"!==u.value?((0,c.openBlock)(),(0,c.createElementBlock)("input",{key:2,type:"hidden",name:"locpoly",disabled:"POLYGON"!==(null===(o=(0,c.unref)(U))||void 0===o?void 0:o.type),value:(null===(T=(0,c.unref)(U))||void 0===T?void 0:T.key)||""},null,8,h)):(0,c.createCommentVNode)("",!0),"tour"!==u.value?((0,c.openBlock)(),(0,c.createElementBlock)("input",{key:3,type:"hidden",name:"locprox",value:"DISTRICT"===(null===(B=(0,c.unref)(U))||void 0===B?void 0:B.type)?1:0},null,8,b)):(0,c.createCommentVNode)("",!0),"tour"!==u.value&&"DISTRICT"===(null===(E=(0,c.unref)(U))||void 0===E?void 0:E.type)?((0,c.openBlock)(),(0,c.createElementBlock)("input",y)):(0,c.createCommentVNode)("",!0),"even"===u.value||"acco"===u.value?((0,c.openBlock)(),(0,c.createElementBlock)("div",k,["even"===u.value||"acco"===u.value?((0,c.openBlock)(),(0,c.createBlock)(D.default,{key:0,legend:(0,c.unref)(V.getLabelText)("date_label","Dates"),"start-label":(0,c.unref)(V.getLabelText)("checkin","Start Date","dates"),"end-label":(0,c.unref)(V.getLabelText)("checkout","End Date","dates"),"default-dates":M.value},null,8,["legend","start-label","end-label","default-dates"])):(0,c.createCommentVNode)("",!0),"even"===u.value?((0,c.openBlock)(),(0,c.createBlock)(P.default,{key:1,name:"name",label:(0,c.unref)(V.getLabelText)("keywords","Keywords"),id:"search-keywords"},null,8,["label"])):(0,c.createCommentVNode)("",!0),"acco"===u.value?((0,c.openBlock)(),(0,c.createBlock)(S.default,{key:2,availability:!0,label:(0,c.unref)(V.getLabelText)("guests","Guests"),id:"guest-selector"},null,8,["label"])):(0,c.createCommentVNode)("",!0),"acco"===u.value?((0,c.openBlock)(),(0,c.createElementBlock)("div",g,w)):(0,c.createCommentVNode)("",!0)])):(0,c.createCommentVNode)("",!0)]),"tour"===u.value?((0,c.openBlock)(),(0,c.createElementBlock)("div",_,[(0,c.createVNode)(L.default,{id:"tour-origin",label:(0,c.unref)(V.getLabelText)("tour_origin","Starting point"),"multiselect-label":"name",name:"origins[]",options:H.value,placeholder:(0,c.unref)(V.getLabelText)("tour_origin_placeholder","Location"),"track-by":"name","is-tour-location":!0},null,8,["label","options","placeholder"]),((0,c.openBlock)(!0),(0,c.createElementBlock)(c.Fragment,null,(0,c.renderList)(j.value,(function(e){return(0,c.openBlock)(),(0,c.createElementBlock)("input",{type:"hidden",name:"attractions[]",value:e},null,8,N)})),256)),(0,c.createVNode)(L.default,{id:"tour-month",label:(0,c.unref)(V.getLabelText)("tour_month","I'm traveling in"),"multiselect-label":"label",name:"when",options:(0,c.unref)(V.getLabelText)("months",(0,c.unref)(x.monthsEnglish)),placeholder:(0,c.unref)(V.getLabelText)("tour_month_placeholder","Select month"),"track-by":"value"},null,8,["label","options","placeholder"])])):(0,c.createCommentVNode)("",!0),(0,c.createVNode)(O.default,{class:"mt-6",variant:"dark"},{default:(0,c.withCtx)((function(){return[(0,c.createTextVNode)((0,c.toDisplayString)((0,c.unref)(V.getLabelText)("search","Search")),1)]})),_:1})],40,p)])])]))])}}})},61309:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.monthsEnglish=t.baseUrl=t.paths=t.products=void 0,t.products=[{key:"accommodation",displayName:"Accommodation",optionValue:"acco"},{key:"eventsAndFestivals",displayName:"Events & Festivals",optionValue:"even"},{key:"foodAndDrink",displayName:"Food & Drink",optionValue:"cate"},{key:"thingsToDo",displayName:"Things to do",optionValue:"acti,attr,reta"},{key:"tours",displayName:"Tours",optionValue:"tour"}],t.paths={acco:"accommodation","acti,attr,reta":"see-do",cate:"food-drink",even:"events",tour:"tours"},t.baseUrl={dev:"http://172.28.81.65:8089",prod:"https://www.visitscotland.com"},t.monthsEnglish=[{label:"January",value:"january"},{label:"February",value:"february"},{label:"March",value:"march"},{label:"April",value:"april"},{label:"May",value:"may"},{label:"June",value:"june"},{label:"July",value:"july"},{label:"August",value:"august"},{label:"September",value:"september"},{label:"October",value:"october"},{label:"November",value:"november"},{label:"December",value:"december"}]},83506:function(e,t,n){"use strict";var a=n(25108),l=this&&this.__awaiter||function(e,t,n,a){return new(n||(n=Promise))((function(l,o){function r(e){try{c(a.next(e))}catch(e){o(e)}}function u(e){try{c(a.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?l(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,u)}c((a=a.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var n,a,l,o,r={label:0,sent:function(){if(1&l[0])throw l[1];return l[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(u){return function(c){return function(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(r=0)),r;)try{if(n=1,a&&(l=2&u[0]?a.return:u[0]?a.throw||((l=a.return)&&l.call(a),0):a.next)&&!(l=l.call(a,u[1])).done)return l;switch(a=0,l&&(u=[2&u[0],l.value]),u[0]){case 0:case 1:l=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,a=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(!((l=(l=r.trys).length>0&&l[l.length-1])||6!==u[0]&&2!==u[0])){r=0;continue}if(3===u[0]&&(!l||u[1]>l[0]&&u[1]<l[3])){r.label=u[1];break}if(6===u[0]&&r.label<l[1]){r.label=l[1],l=u;break}if(l&&r.label<l[2]){r.label=l[2],r.ops.push(u);break}l[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(e){u=[6,e],a=0}finally{n=l=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([u,c])}}},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.getData=void 0;var u=r(n(97218));t.getData=function(e){return l(this,void 0,void 0,(function(){var t;return o(this,(function(n){switch(n.label){case 0:return n.trys.push([0,2,,3]),[4,u.default.get(e)];case 1:return[2,n.sent().data];case 2:return t=n.sent(),a.error("Axios error: ".concat(t)),[3,3];case 3:return[2]}}))}))}},68504:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getProductTypes=t.getURLParameters=void 0;var a,l=n(61309);a="undefined"!=typeof window&&"object"==typeof window.VS?window.VS:{},t.getURLParameters=function(){var e=new URLSearchParams(document.location.search),t=Object.fromEntries(e);return"object"==typeof t&&Object.keys(t).forEach((function(e){return null===t[e]&&delete t[e]})),t},t.getProductTypes=function(){if(Object.keys(a).length<=0)return l.products;var e=a.search_config.basic_config.productTypes,t=[];return Object.keys(e).forEach((function(n){t.push({key:e[n].value,displayName:e[n].text,optionValue:e[n].value})})),t}},97809:function(e,t,n){"use strict";n.r(t);var a=n(65531),l={};for(var o in a)"default"!==o&&(l[o]=function(e){return a[e]}.bind(0,o));n.d(t,l),n(67430);const r=a.default;t.default=r},67430:function(e,t,n){"use strict";n(54955)},65531:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l.a}});var a=n(43062),l=n.n(a),o={};for(var r in a)"default"!==r&&(o[r]=function(e){return a[e]}.bind(0,r));n.d(t,o)}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[3810],{67106:function(e,t,r){var o=r(4942),n=r(67476),i=r(27447);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){(0,o.Z)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var u={computed:s(s({},(0,n.rn)(i.Z,{cookiesSet:function(e){return e.allowedCookies}})),{},{onetrustActiveGroups:function(){return window.OnetrustActiveGroups},requiredCookiesExist:function(){var e=this,t=!0;return this.requiredCookies?this.requiredCookies.forEach((function(r){-1===e.cookiesSet.indexOf(r)&&(t=!1)})):t=!1,t},cookiesInitStatus:function(){return void 0===this.onetrustActiveGroups||this.cookiesSet.length,!0}})};t.Z=u},16033:function(e,t){t.Z={youtube:["C0001","C0004"],languageSelector:["C0001"],embed:["C0001","C0003","C0004"],recaptcha:["C0001"],map:["C0001"]}}}]);
1
+ "use strict";(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[3810],{67106:function(e,t,r){var o=r(4942),n=r(67476),i=r(27447);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){(0,o.Z)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var s={computed:u(u({},(0,n.rn)(i.Z,{cookiesSet:function(e){return e.allowedCookies}})),{},{onetrustActiveGroups:function(){return"undefined"!=typeof window?window.OnetrustActiveGroups:null},requiredCookiesExist:function(){var e=this,t=!0;return this.requiredCookies?this.requiredCookies.forEach((function(r){-1===e.cookiesSet.indexOf(r)&&(t=!1)})):t=!1,t},cookiesInitStatus:function(){return void 0===this.onetrustActiveGroups||this.cookiesSet.length,!0}})};t.Z=s},16033:function(e,t){t.Z={youtube:["C0001","C0004"],languageSelector:["C0001"],embed:["C0001","C0003","C0004"],recaptcha:["C0001"],map:["C0001"]}}}]);
@@ -1 +1 @@
1
- "use strict";!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.VsCookieChecker=n():t.VsCookieChecker=n()}(self,(function(){return(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[4663],{49017:function(t,n,e){var o=e(15730),i=e(27447),r=e(48082),c=null;n.Z={data:function(){return{oneTrust:new r.Z,activeGroups:""}},watch:{activeGroups:function(){var t=this.activeGroups.split(",").filter((function(t){return""!==t}));c&&(c.setCookieArray(t),c.setTestRun(!0))}},mounted:function(){c=(0,i.Z)((0,o.Z)())},created:function(){this.checkOneTrust(),this.checkActiveGroups()},methods:{checkOneTrust:function(){var t=this;"undefined"!=typeof window&&this.oneTrust.checkThirdPartyLibrary("OneTrust",(function(){window.OneTrust.OnConsentChanged((function(){t.oneTrust.checkThirdPartyLibrary("OnetrustActiveGroups",(function(){t.activeGroups=window.OnetrustActiveGroups}))}))}))},checkActiveGroups:function(){var t=this;"undefined"!=typeof window&&this.oneTrust.checkThirdPartyLibrary("OnetrustActiveGroups",(function(){t.activeGroups=window.OnetrustActiveGroups}))}}}},2604:function(t,n,e){e.d(n,{s:function(){return r}});var o=e(66252),i={class:"d-none"};function r(t,n,e,r,c,s){return(0,o.wg)(),(0,o.iD)("span",i)}},94569:function(t,n){n.Z=function(){return Math.random().toString(36).substring(7)}},48082:function(t,n,e){e.d(n,{Z:function(){return a}});var o=e(43144),i=e(15671),r=e(4942),c=e(94569),s=e(25108),a=(0,o.Z)((function t(){var n=this;(0,i.Z)(this,t),(0,r.Z)(this,"init",(function(){window.NodeList&&!NodeList.prototype.forEach&&(NodeList.prototype.forEach=Array.prototype.forEach)})),(0,r.Z)(this,"instaOT",(function(t,e,o,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;s.log("insta");var c=n;n.checkThirdPartyLibrary("OneTrust",(function(){n.onetrustCookieCheck(t,(function(n){if(n)c.setIframeSrc();else if(i){s.log("fallback",o),s.log("container",i);var a=Array.from(o.classList)[0];i.length>1?i.forEach((function(n,s){i[s].querySelector(".".concat(a))||c.showOneTrustFallback(t,e,o,i[s],r)})):i.querySelector(".".concat(a))||c.showOneTrustFallback(t,e,o,i,r)}})),window.OneTrust.OnConsentChanged((function(){c.onetrustCookieCheck(t,(function(n){n&&(window.OneTrustEventBus.dispatchEvent("otCategory-approved"),c.hideOneTrustFallback(t),c.setIframeSrc())}))}))}))})),(0,r.Z)(this,"showOneTrustFallback",(function(t,e,o,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;s.log("showfallback");var a={visible:!1,fallback:o};if(a.visible)return!1;if(i.length>1&&a.fallback)s.log("aqui"),i.forEach((function(e){var o=a.fallback.cloneNode(!0);o.id=(0,c.Z)(),e.insertAdjacentHTML("afterend",o.outerHTML);var i=document.getElementById(o.id);i.style.display="block",a.visible=!0,o.classList.add("vscookies-".concat(t)),n.fallbacks.push({id:i.id,cat:t,visible:!0}),n.setFBButtonListener(o)}));else{s.log("aca");var u=a.fallback.cloneNode(!0);u.id=(0,c.Z)(),u.style.display="block",u.classList.add("vscookies-".concat(t)),r?i.insertBefore(u,i.childNodes[r]):i.appendChild(u),n.fallbacks.push({id:u.id,cat:t}),a.visible=!0,n.setFBButtonListener(u)}})),(0,r.Z)(this,"onetrustCookieCheck",(function(t,n){return n(window.OnetrustActiveGroups.includes(t))})),(0,r.Z)(this,"hideOneTrustFallback",(function(t){n.fallbacks.map((function(n){n.cat===t&&document.getElementById(n.id)&&(document.getElementById(n.id).style.display="none")}));var e=document.querySelectorAll(".vscookies-".concat(t));e.size>0&&e.map((function(t){t.style.display="none"}))})),(0,r.Z)(this,"checkThirdPartyLibrary",(function(t,e){var o=n;window.setTimeout((function(){window[t]?e(window[t]):o.checkThirdPartyLibrary(t,e)}),500)})),(0,r.Z)(this,"setFBButtonListener",(function(t){t.querySelector("#ot-sdk-btn").addEventListener("click",(function(){window.OneTrust.ToggleInfoDisplay()}))})),(0,r.Z)(this,"setIframeSrc",(function(){var t=document.querySelectorAll('iframe[data-src]:not([data-src=""])');t&&t.forEach((function(t){t.src=t.dataset.src,t.removeAttribute("data-src")}))})),this.fallbacks=[]}))},1312:function(t,n,e){e.r(n);var o=e(41723),i=e(62480);const r=(0,e(83744).Z)(i.Z,[["render",o.s]]);n.default=r},62480:function(t,n,e){e.d(n,{Z:function(){return o.Z}});var o=e(49017)},41723:function(t,n,e){e.d(n,{s:function(){return o.s}});var o=e(2604)}},function(t){return t.O(0,[6252,3744,9963,4942,6765,7169,8341,5730,7447],(function(){return 1312,t(t.s=1312)})),t.O()}])}));
1
+ "use strict";!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.VsCookieChecker=n():t.VsCookieChecker=n()}(self,(function(){return(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[4663],{49017:function(t,n,e){var o=e(15730),i=e(27447),r=e(48082),c=null;n.Z={data:function(){return{oneTrust:new r.Z,activeGroups:""}},watch:{activeGroups:function(){var t=this.activeGroups.split(",").filter((function(t){return""!==t}));c&&(c.setCookieArray(t),c.setTestRun(!0))}},mounted:function(){c=(0,i.Z)((0,o.Z)())},created:function(){this.checkOneTrust(),this.checkActiveGroups()},methods:{checkOneTrust:function(){var t=this;"undefined"!=typeof window&&this.oneTrust.checkThirdPartyLibrary("OneTrust",(function(){window.OneTrust.OnConsentChanged((function(){t.oneTrust.checkThirdPartyLibrary("OnetrustActiveGroups",(function(){t.activeGroups=window.OnetrustActiveGroups}))}))}))},checkActiveGroups:function(){var t=this;"undefined"!=typeof window&&this.oneTrust.checkThirdPartyLibrary("OnetrustActiveGroups",(function(){t.activeGroups=window.OnetrustActiveGroups}))}}}},2604:function(t,n,e){e.d(n,{s:function(){return r}});var o=e(66252),i={class:"d-none"};function r(t,n,e,r,c,s){return(0,o.wg)(),(0,o.iD)("span",i)}},94569:function(t,n){n.Z=function(){return Math.random().toString(36).substring(7)}},48082:function(t,n,e){e.d(n,{Z:function(){return a}});var o=e(43144),i=e(15671),r=e(4942),c=e(94569),s=e(25108),a=(0,o.Z)((function t(){var n=this;(0,i.Z)(this,t),(0,r.Z)(this,"init",(function(){window.NodeList&&!NodeList.prototype.forEach&&(NodeList.prototype.forEach=Array.prototype.forEach)})),(0,r.Z)(this,"instaOT",(function(t,e,o,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;s.log("insta");var c=n;n.checkThirdPartyLibrary("OneTrust",(function(){n.onetrustCookieCheck(t,(function(n){if(n)c.setIframeSrc();else if(i){s.log("fallback",o),s.log("container",i);var a=Array.from(o.classList)[0];i.length>1?i.forEach((function(n,s){i[s].querySelector(".".concat(a))||c.showOneTrustFallback(t,e,o,i[s],r)})):i.querySelector(".".concat(a))||c.showOneTrustFallback(t,e,o,i,r)}})),window.OneTrust.OnConsentChanged((function(){c.onetrustCookieCheck(t,(function(n){n&&(window.OneTrustEventBus.dispatchEvent("otCategory-approved"),c.hideOneTrustFallback(t),c.setIframeSrc())}))}))}))})),(0,r.Z)(this,"showOneTrustFallback",(function(t,e,o,i){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;s.log("showfallback");var a={visible:!1,fallback:o};if(a.visible)return!1;if(i.length>1&&a.fallback)s.log("aqui"),i.forEach((function(e){var o=a.fallback.cloneNode(!0);o.id=(0,c.Z)(),e.insertAdjacentHTML("afterend",o.outerHTML);var i=document.getElementById(o.id);i.style.display="block",a.visible=!0,o.classList.add("vscookies-".concat(t)),n.fallbacks.push({id:i.id,cat:t,visible:!0}),n.setFBButtonListener(o)}));else{s.log("aca");var u=a.fallback.cloneNode(!0);u.id=(0,c.Z)(),u.style.display="block",u.classList.add("vscookies-".concat(t)),r?i.insertBefore(u,i.childNodes[r]):i.appendChild(u),n.fallbacks.push({id:u.id,cat:t}),a.visible=!0,n.setFBButtonListener(u)}})),(0,r.Z)(this,"onetrustCookieCheck",(function(t,n){if("undefined"!=typeof window)return n(window.OnetrustActiveGroups.includes(t))})),(0,r.Z)(this,"hideOneTrustFallback",(function(t){n.fallbacks.map((function(n){n.cat===t&&document.getElementById(n.id)&&(document.getElementById(n.id).style.display="none")}));var e=document.querySelectorAll(".vscookies-".concat(t));e.size>0&&e.map((function(t){t.style.display="none"}))})),(0,r.Z)(this,"checkThirdPartyLibrary",(function(t,e){var o=n;window.setTimeout((function(){window[t]?e(window[t]):o.checkThirdPartyLibrary(t,e)}),500)})),(0,r.Z)(this,"setFBButtonListener",(function(t){t.querySelector("#ot-sdk-btn").addEventListener("click",(function(){window.OneTrust.ToggleInfoDisplay()}))})),(0,r.Z)(this,"setIframeSrc",(function(){var t=document.querySelectorAll('iframe[data-src]:not([data-src=""])');t&&t.forEach((function(t){t.src=t.dataset.src,t.removeAttribute("data-src")}))})),this.fallbacks=[]}))},1312:function(t,n,e){e.r(n);var o=e(41723),i=e(62480);const r=(0,e(83744).Z)(i.Z,[["render",o.s]]);n.default=r},62480:function(t,n,e){e.d(n,{Z:function(){return o.Z}});var o=e(49017)},41723:function(t,n,e){e.d(n,{s:function(){return o.s}});var o=e(2604)}},function(t){return t.O(0,[6252,3744,9963,4942,6765,7169,8341,5730,7447],(function(){return 1312,t(t.s=1312)})),t.O()}])}));
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[2147],{12147:function(e,o){var n;Object.defineProperty(o,"__esModule",{value:!0}),o.getLocale=o.getProductName=o.getLabelText=void 0,o.getLabelText=function(e,o,t){return n="undefined"!=typeof window&&"object"==typeof window.VS?window.VS:{},Object.keys(n).length>0?void 0!==t?n.search_config.basic_config.search_module[t][e]:n.search_config.basic_config.search_module[e]:o},o.getProductName=function(e,o){if(n="undefined"!=typeof window&&"object"==typeof window.VS?window.VS:{},Object.keys(n).length>0){var t={};return Object.keys(n.search_config.basic_config.productTypes).forEach((function(e){var o=n.search_config.basic_config.productTypes[e];t[o.value]=o.text})),t[e]?t[e]:o}return o},o.getLocale=function(){var e=document.documentElement.lang.toLocaleLowerCase().slice(0,2)||"";return"en"===e&&(e=""),e}}}]);