@visitscotland/component-library 3.2.2 → 3.2.3

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.
@@ -1690,7 +1690,7 @@
1690
1690
  "scripts/a5720cb035b84b05a681.js",
1691
1691
  "scripts/c250b6d349526b79c26f.js",
1692
1692
  "scripts/8831aa9b92c7ec8958fd.js",
1693
- "scripts/ec7baa92a825a338c11d.js"
1693
+ "scripts/95501bef3266846cf57e.js"
1694
1694
  ],
1695
1695
  "styles": [
1696
1696
  "styles/cd7968f5815183867103.css",
@@ -1698,7 +1698,7 @@
1698
1698
  "styles/a4a067edc9342e4ea427.css",
1699
1699
  "styles/a5720cb035b84b05a681.css",
1700
1700
  "styles/c250b6d349526b79c26f.css",
1701
- "styles/ec7baa92a825a338c11d.css"
1701
+ "styles/95501bef3266846cf57e.css"
1702
1702
  ]
1703
1703
  },
1704
1704
  "VsFooterAccordionItem": {
@@ -0,0 +1 @@
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.VsEmbedWrapper=t():e.VsEmbedWrapper=t()}(self,(function(){return(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[5734],{19379:function(){},59579:function(e,t,r){"use strict";var n=r(11438),o=r(72958),i=r(79122),s=r(83178),u=r(12308).A.embed;t.A={name:"VsEmbedWrapper",status:"prototype",release:"0.0.1",components:{VsContainer:n.T$,VsRow:n.AQ,VsCol:n.Il,VsRichTextWrapper:o.default,VsWarning:i.default},mixins:[s.A],props:{noCookiesRequired:{type:Boolean,default:!1},noCookieText:{type:String,required:!0},errorText:{type:String,required:!0},noJsText:{type:String,required:!0},extraContent:{type:String,default:""}},data:function(){return{requiredCookies:this.noCookiesRequired?null:u}},computed:{showError:function(){return!this.noCookiesRequired&&(!this.requiredCookiesExist&&!0===this.cookiesInitStatus||"error"===this.cookiesInitStatus)},warningText:function(){var e="";return"error"===this.cookiesInitStatus&&(e=this.errorText),this.requiredCookiesExist||!0!==this.cookiesInitStatus||(e=this.noCookieText),e}}}},93143:function(e,t,r){"use strict";r.d(t,{X:function(){return a}});var n=r(20641),o=r(90033),i={"data-test":"vs-embed-wrapper",class:"vs-embed-wrapper"},s={key:"fallback"},u=["innerHTML"];function a(e,t,r,a,c,d){var p=(0,n.g2)("VsRichTextWrapper"),f=(0,n.g2)("VsCol"),l=(0,n.g2)("VsWarning"),b=(0,n.g2)("VsRow"),k=(0,n.g2)("VsContainer");return(0,n.uX)(),(0,n.CE)("div",i,[(0,n.bF)(k,null,{default:(0,n.k6)((function(){return[(0,n.bF)(b,null,{default:(0,n.k6)((function(){return[(0,n.bF)(f,{cols:"12",sm:"10","offset-sm":"1",md:"6","offset-md":"3"},{default:(0,n.k6)((function(){return[e.$slots["embed-intro-copy"]&&e.$slots["embed-intro-copy"]()&&!d.showError?((0,n.uX)(),(0,n.Wv)(p,{key:0,class:"vs-module-wrapper__intro vs-embed-wrapper__intro","data-test":"vs-module-wrapper__intro"},{default:(0,n.k6)((function(){return[(0,n.RG)(e.$slots,"embed-intro-copy")]})),_:3})):(0,n.Q3)("",!0)]})),_:3}),(0,n.bF)(f,{cols:"12"},{default:(0,n.k6)((function(){return[(0,n.Lk)("div",{class:(0,o.normalizeClass)(["vs-embed-wrapper__container",e.requiredCookiesExist||r.noCookiesRequired?"":"d-none"]),key:"embeddedContent"},[(0,n.RG)(e.$slots,"embed-widget")],2),d.showError?((0,n.uX)(),(0,n.CE)("div",s,[(0,n.bF)(l,{type:!0===e.cookiesInitStatus?"cookie":"normal",class:"vs-embed-wrapper__error","data-test":"vs-embed-wrapper__error"},(0,n.eX)({default:(0,n.k6)((function(){return[(0,n.eW)((0,o.toDisplayString)(d.warningText)+" ",1)]})),_:2},[r.extraContent?{name:"extra-content",fn:(0,n.k6)((function(){return[(0,n.Lk)("div",{innerHTML:r.extraContent},null,8,u)]})),key:"0"}:void 0,e.requiredCookiesExist||!0!==e.cookiesInitStatus?void 0:{name:"button-text",fn:(0,n.k6)((function(){return[(0,n.RG)(e.$slots,"embed-button-text")]})),key:"1"}]),1032,["type"])])):(0,n.Q3)("",!0),(0,n.bF)(l,{type:"normal","data-test":"vs-embed-wrapper__error--no-js",class:"vs-embed-wrapper__error vs-embed-wrapper__error--no-js"},{default:(0,n.k6)((function(){return[(0,n.eW)((0,o.toDisplayString)(r.noJsText),1)]})),_:1})]})),_:3})]})),_:3})]})),_:3})])}},83178:function(e,t,r){"use strict";var n=r(64467),o=r(10810),i=r(2829);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){(0,n.A)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var a={data:function(){return{bypassCookiesExist:!1}},computed:u(u({},(0,o.aH)(i.A,{cookiesSet:function(e){return e.allowedCookies}})),{},{onetrustActiveGroups:function(){return"undefined"!=typeof window?window.OnetrustActiveGroups:null},requiredCookiesExist:function(){var e=this;if("undefined"!=typeof window&&window.bypassCookieChecks)return this.bypassCookiesExist;var t=!0;return this.requiredCookies?this.requiredCookies.forEach((function(r){-1===e.cookiesSet.indexOf(r)&&(t=!1)})):t=!1,t},cookiesInitStatus:function(){return"undefined"!=typeof window&&window.bypassCookieChecks?this.bypassCookiesExist:(void 0===this.onetrustActiveGroups||this.cookiesSet.length,!0)}}),mounted:function(){var e=this;setTimeout((function(){e.bypassCookiesExist=!0}),50)}};t.A=a},12308:function(e,t){"use strict";t.A={youtube:["C0001","C0004"],languageSelector:["C0001"],embed:["C0001","C0003","C0004"],recaptcha:["C0001"],map:["C0001"]}},84289:function(e,t,r){"use strict";var n=r(85072),o=r.n(n),i=r(97825),s=r.n(i),u=r(77659),a=r.n(u),c=r(55056),d=r.n(c),p=r(10540),f=r.n(p),l=r(41113),b=r.n(l),k=r(19379),m=r.n(k),y={};y.styleTagTransform=b(),y.setAttributes=d(),y.insert=a().bind(null,"head"),y.domAPI=s(),y.insertStyleElement=f(),o()(m(),y),m()&&m().locals&&m().locals},66649:function(e,t,r){"use strict";r.r(t);var n=r(58087),o=r(69295);r(41365);const i=(0,r(66262).A)(o.A,[["render",n.X]]);t.default=i},69295:function(e,t,r){"use strict";r.d(t,{A:function(){return n.A}});var n=r(59579)},58087:function(e,t,r){"use strict";r.d(t,{X:function(){return n.X}});var n=r(93143)},41365:function(e,t,r){"use strict";r(84289)}},function(e){return e.O(0,[641,6262,7510,3751,4352,4467,7527,8086,810,6422,8745,8836,8638,2368,7521,1438,9122,2958,2829],(function(){return 66649,e(e.s=66649)})),e.O()}])}));
@@ -27,6 +27,14 @@ declare const _default: import('vue').DefineComponent<{
27
27
  type: StringConstructor;
28
28
  required: true;
29
29
  };
30
+ /**
31
+ * Extra content to display, rendered as html so it can include
32
+ * explanatory links
33
+ */
34
+ extraContent: {
35
+ type: StringConstructor;
36
+ default: string;
37
+ };
30
38
  }, any, {
31
39
  requiredCookies: string[];
32
40
  }, {
@@ -72,7 +80,16 @@ declare const _default: import('vue').DefineComponent<{
72
80
  type: StringConstructor;
73
81
  required: true;
74
82
  };
83
+ /**
84
+ * Extra content to display, rendered as html so it can include
85
+ * explanatory links
86
+ */
87
+ extraContent: {
88
+ type: StringConstructor;
89
+ default: string;
90
+ };
75
91
  }>>, {
76
92
  noCookiesRequired: boolean;
93
+ extraContent: string;
77
94
  }, {}>;
78
95
  export default _default;