@visitscotland/component-library 4.7.4 → 4.7.7

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.
@@ -1517,7 +1517,7 @@
1517
1517
  "scripts/0e6fcaca5793d325e71f.js",
1518
1518
  "scripts/c31932e999f4e02b0740.js",
1519
1519
  "scripts/7926eaf34e584f4ee8f2.js",
1520
- "scripts/3be3d5d2ab11521ed91e.js",
1520
+ "scripts/4c1f26c64e28681543ad.js",
1521
1521
  "scripts/8c8506dd855920073398.js",
1522
1522
  "scripts/7598be4ae5f3a7c45c3a.js"
1523
1523
  ],
@@ -1529,7 +1529,7 @@
1529
1529
  "styles/f875df71c41035b40148.css",
1530
1530
  "styles/a1ea6d101866bc682576.css",
1531
1531
  "styles/0e6fcaca5793d325e71f.css",
1532
- "styles/3be3d5d2ab11521ed91e.css",
1532
+ "styles/4c1f26c64e28681543ad.css",
1533
1533
  "styles/8c8506dd855920073398.css",
1534
1534
  "styles/7598be4ae5f3a7c45c3a.css"
1535
1535
  ]
@@ -3848,7 +3848,7 @@
3848
3848
  "scripts/0e6fcaca5793d325e71f.js",
3849
3849
  "scripts/c31932e999f4e02b0740.js",
3850
3850
  "scripts/7926eaf34e584f4ee8f2.js",
3851
- "scripts/3be3d5d2ab11521ed91e.js",
3851
+ "scripts/4c1f26c64e28681543ad.js",
3852
3852
  "scripts/01527cee581757e82bbd.js"
3853
3853
  ],
3854
3854
  "styles": [
@@ -3858,7 +3858,7 @@
3858
3858
  "styles/f875df71c41035b40148.css",
3859
3859
  "styles/a1ea6d101866bc682576.css",
3860
3860
  "styles/0e6fcaca5793d325e71f.css",
3861
- "styles/3be3d5d2ab11521ed91e.css",
3861
+ "styles/4c1f26c64e28681543ad.css",
3862
3862
  "styles/01527cee581757e82bbd.css"
3863
3863
  ]
3864
3864
  },
@@ -3901,7 +3901,7 @@
3901
3901
  "scripts/0e6fcaca5793d325e71f.js",
3902
3902
  "scripts/c31932e999f4e02b0740.js",
3903
3903
  "scripts/7926eaf34e584f4ee8f2.js",
3904
- "scripts/3be3d5d2ab11521ed91e.js",
3904
+ "scripts/4c1f26c64e28681543ad.js",
3905
3905
  "scripts/3e161476a901afaa0a49.js"
3906
3906
  ],
3907
3907
  "styles": [
@@ -3911,7 +3911,7 @@
3911
3911
  "styles/f875df71c41035b40148.css",
3912
3912
  "styles/a1ea6d101866bc682576.css",
3913
3913
  "styles/0e6fcaca5793d325e71f.css",
3914
- "styles/3be3d5d2ab11521ed91e.css",
3914
+ "styles/4c1f26c64e28681543ad.css",
3915
3915
  "styles/3e161476a901afaa0a49.css"
3916
3916
  ]
3917
3917
  },
@@ -4198,7 +4198,7 @@
4198
4198
  "scripts/13a3665f4f37c4c1e8fc.js",
4199
4199
  "scripts/c31932e999f4e02b0740.js",
4200
4200
  "scripts/7926eaf34e584f4ee8f2.js",
4201
- "scripts/3be3d5d2ab11521ed91e.js",
4201
+ "scripts/4c1f26c64e28681543ad.js",
4202
4202
  "scripts/8c8506dd855920073398.js",
4203
4203
  "scripts/8e385b0dd7f538a68ee5.js"
4204
4204
  ],
@@ -4210,7 +4210,7 @@
4210
4210
  "styles/a1ea6d101866bc682576.css",
4211
4211
  "styles/0e6fcaca5793d325e71f.css",
4212
4212
  "styles/13a3665f4f37c4c1e8fc.css",
4213
- "styles/3be3d5d2ab11521ed91e.css",
4213
+ "styles/4c1f26c64e28681543ad.css",
4214
4214
  "styles/8c8506dd855920073398.css",
4215
4215
  "styles/8e385b0dd7f538a68ee5.css"
4216
4216
  ]
@@ -4255,7 +4255,7 @@
4255
4255
  "scripts/13a3665f4f37c4c1e8fc.js",
4256
4256
  "scripts/c31932e999f4e02b0740.js",
4257
4257
  "scripts/7926eaf34e584f4ee8f2.js",
4258
- "scripts/3be3d5d2ab11521ed91e.js",
4258
+ "scripts/4c1f26c64e28681543ad.js",
4259
4259
  "scripts/8c8506dd855920073398.js",
4260
4260
  "scripts/b0037533f99665d7dc59.js"
4261
4261
  ],
@@ -4267,7 +4267,7 @@
4267
4267
  "styles/a1ea6d101866bc682576.css",
4268
4268
  "styles/0e6fcaca5793d325e71f.css",
4269
4269
  "styles/13a3665f4f37c4c1e8fc.css",
4270
- "styles/3be3d5d2ab11521ed91e.css",
4270
+ "styles/4c1f26c64e28681543ad.css",
4271
4271
  "styles/8c8506dd855920073398.css",
4272
4272
  "styles/b0037533f99665d7dc59.css"
4273
4273
  ]
@@ -5592,7 +5592,7 @@
5592
5592
  "scripts/0e6fcaca5793d325e71f.js",
5593
5593
  "scripts/c31932e999f4e02b0740.js",
5594
5594
  "scripts/7926eaf34e584f4ee8f2.js",
5595
- "scripts/3be3d5d2ab11521ed91e.js",
5595
+ "scripts/4c1f26c64e28681543ad.js",
5596
5596
  "scripts/d88e1e53842cc326fc62.js"
5597
5597
  ],
5598
5598
  "styles": [
@@ -5602,7 +5602,7 @@
5602
5602
  "styles/f875df71c41035b40148.css",
5603
5603
  "styles/a1ea6d101866bc682576.css",
5604
5604
  "styles/0e6fcaca5793d325e71f.css",
5605
- "styles/3be3d5d2ab11521ed91e.css"
5605
+ "styles/4c1f26c64e28681543ad.css"
5606
5606
  ]
5607
5607
  },
5608
5608
  "VsStyledListItem": {
@@ -0,0 +1 @@
1
+ (self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[9116],{5314:function(){},90020:function(e,t,s){"use strict";var n=s(13838),i=s(45676),a=s(31574),r=s(48836),d=s(79122),l=s(57957),c=s(45921),o=s.n(c);t.A={name:"VsStretchedLinkCard",status:"prototype",release:"0.0.1",components:{VsHeading:n.default,VsLink:i.default,VsImg:a.default,VsButton:r.default,VsWarning:d.default},inject:{noJsMessage:{default:null},theme:{default:null}},props:{link:{type:String,required:!0,default:"#"},headingLevel:{type:[String,Number],default:"3",validator:function(e){return e.match(/(1|2|3|4|5|6)/)}},headingStyle:{type:[String,Number],default:"heading-xs",validator:function(e){return e.match(/(display-l|display-m|display-s|display-xs|heading-xxl|heading-xl|heading-l|heading-m|heading-s|heading-xs|heading-xxs)/)}},type:{type:String,required:!0,validator:function(e){return e.match(/(default|external|internal|download|video)/)}},imgSrc:{type:String,default:void 0},imgAlt:{type:String,default:""},disabled:{type:Boolean,default:!1},videoId:{type:String,default:""},videoBtnText:{type:String,default:""},errorMessage:{type:String,default:""},errorType:{type:String,default:"image",validator:function(e){return e.match(/(image|full)/)}},warningSize:{type:String,default:"small",validator:function(e){return e.match(/(normal|small)/)}},businessSupport:{type:Boolean,default:!1},isHomePage:{type:Boolean,default:!1}},setup:function(){return{videoStore:o()()}},data:function(){return{jsDisabled:!0}},computed:{formattedVideoBtnText:function(){return"".concat(this.videoBtnText," | ")},formattedVideoDuration:function(){var e="".concat(this.videoDetails.videoFullDuration.seconds);return 1===e.length&&(e="0".concat(e)),"".concat(this.videoDetails.videoFullDuration.minutes,":").concat(e)},stretchedLinkCardClasses:function(){var e="";return this.disabled&&(e+="vs-stretched-link-card--disabled"),"video"===this.type&&(e+=" vs-stretched-link-card--video"),this.showWarning&&"video"===this.type&&(e+=" vs-stretched-link-card--warning"),e},videoDetails:function(){return this.videoStore.videos[this.videoId]},videoLoaded:function(){return void 0!==this.videoDetails&&this.videoDetails.videoDuration>0},warningClass:function(){var e="";return this.videoId&&this.jsDisabled&&(e="vs-stretched-link-card__img-container--warning ","full"===this.errorType&&(e+="vs-stretched-link-card__img-container--warning-full")),e},showWarning:function(){return!!this.jsDisabled},warningMessage:function(){return this.errorMessage},warningAttrs:function(){var e={};return"small"===this.size&&(e.size="sm"),e}},mounted:function(){this.jsDisabled=(0,l.A)()},methods:{emitShowModal:function(){this.videoId&&this.emitter&&this.emitter.emit("showModal",this.videoId,"#videoShow")}}}},96518:function(e,t,s){"use strict";s.d(t,{X:function(){return c}});var n=s(20641),i=s(90033),a={key:0,class:"vs-stretched-link-card__video-btn-text"},r={key:1,class:"vs-stretched-link-card__category","data-test":"vs-stretched-link-card__category"},d={class:"vs-stretched-link-card__content","data-test":"vs-stretched-link-card__content"},l={key:3,class:"vs-stretched-link-card__badges","data-test":"vs-stretched-link-card__badges"};function c(e,t,s,c,o,u){var h=(0,n.g2)("VsWarning"),g=(0,n.g2)("VsImg"),v=(0,n.g2)("VsButton"),f=(0,n.g2)("VsLink"),k=(0,n.g2)("VsHeading");return(0,n.uX)(),(0,n.CE)("div",{class:(0,i.normalizeClass)(["card vs-stretched-link-card",u.stretchedLinkCardClasses]),"data-test":"vs-stretched-link-card",onClick:t[0]||(t[0]=function(){return u.emitShowModal&&u.emitShowModal.apply(u,arguments)}),onKeypress:t[1]||(t[1]=function(){return u.emitShowModal&&u.emitShowModal.apply(u,arguments)})},["full"===u.showWarning?((0,n.uX)(),(0,n.Wv)(h,{key:0,size:s.warningSize,type:"normal","data-test":"vs-stretched-link-card__full-warning",class:"vs-stretched-link-card__full-warning"},{default:(0,n.k6)((function(){return[(0,n.eW)((0,i.toDisplayString)(u.warningMessage),1)]})),_:1},8,["size"])):(0,n.Q3)("",!0),"full"===s.errorType&&""!==s.videoId?((0,n.uX)(),(0,n.Wv)(h,{key:1,size:s.warningSize,"data-test":"vs-stretched-link-card__full-warning",class:"vs-stretched-link-card__full-warning vs-stretched-link-card__full-warning--no-js"},{default:(0,n.k6)((function(){return[(0,n.eW)((0,i.toDisplayString)(u.noJsMessage),1)]})),_:1},8,["size"])):(0,n.Q3)("",!0),s.imgSrc?((0,n.uX)(),(0,n.CE)("div",{key:2,class:(0,i.normalizeClass)(["vs-stretched-link-card__img-container",u.warningClass])},[s.imgSrc?((0,n.uX)(),(0,n.Wv)(g,{key:0,src:s.imgSrc,alt:s.imgAlt,class:"vs-stretched-link-card__img","data-test":"vs-stretched-link-card__img","data-chromatic":"ignore"},null,8,["src","alt"])):(0,n.Q3)("",!0),"image"===u.showWarning?((0,n.uX)(),(0,n.Wv)(h,{key:1,size:s.warningSize,type:"normal","data-test":"vs-stretched-link-card__image-warning",class:"vs-stretched-link-card__image-warning"},{default:(0,n.k6)((function(){return[(0,n.eW)((0,i.toDisplayString)(u.warningMessage),1)]})),_:1},8,["size"])):(0,n.Q3)("",!0),""!==s.videoId&&"image"===s.errorType?((0,n.uX)(),(0,n.Wv)(h,{key:2,size:s.warningSize,"data-test":"vs-stretched-link-card__warning",class:"vs-stretched-link-card__image-warning vs-stretched-link-card__image-warning--no-js"},{default:(0,n.k6)((function(){return[(0,n.eW)((0,i.toDisplayString)(u.noJsMessage),1)]})),_:1},8,["size"])):(0,n.Q3)("",!0)],2)):(0,n.Q3)("",!0),e.$slots["stretched-card-panels"]&&e.$slots["stretched-card-panels"]()?(0,n.RG)(e.$slots,"stretched-card-panels",{key:3}):(0,n.Q3)("",!0),"full"!==u.showWarning?((0,n.uX)(),(0,n.CE)("div",{key:4,class:(0,i.normalizeClass)(["card-body",s.videoId?"position-relative":""])},[s.videoId&&u.videoLoaded?((0,n.uX)(),(0,n.Wv)(v,{key:0,class:"vs-stretched-link-card__video-button","data-test":"vs-stretched-link-card__video-button",icon:"play","icon-position":"left",size:"md",ref:"videoShow",rounded:!1,onClick:u.emitShowModal},{default:(0,n.k6)((function(){return[s.videoBtnText?((0,n.uX)(),(0,n.CE)("span",a,(0,i.toDisplayString)(u.formattedVideoBtnText),1)):(0,n.Q3)("",!0),(0,n.eW)(" "+(0,i.toDisplayString)(u.formattedVideoDuration),1)]})),_:1},8,["onClick"])):(0,n.Q3)("",!0),e.$slots["stretched-card-category"]&&e.$slots["stretched-card-category"]()?((0,n.uX)(),(0,n.CE)("span",r,[(0,n.RG)(e.$slots,"stretched-card-category")])):(0,n.Q3)("",!0),e.$slots["stretched-card-header"]&&e.$slots["stretched-card-header"]()?((0,n.uX)(),(0,n.Wv)(k,{key:2,level:s.headingLevel,"heading-style":s.headingStyle,class:"card-title vs-stretched-link-card__title","data-test":"vs-stretched-link-card__title"},{default:(0,n.k6)((function(){return[e.$slots["stretched-card-link"]&&e.$slots["stretched-card-link"]()?(0,n.RG)(e.$slots,"stretched-card-header",{key:0}):s.businessSupport||"video"!==s.type?((0,n.uX)(),(0,n.Wv)(f,{key:2,href:s.link,type:s.type,class:(0,i.normalizeClass)(["stretched-link",s.disabled?"stretched-link--disabled":""]),variant:"dark"===u.theme?"on-dark":"primary","data-test":"vs-stretched-link",disabled:s.disabled,tabindex:!s.videoId&&!s.disabled||s.businessSupport?"0":"-1"},{default:(0,n.k6)((function(){return[(0,n.RG)(e.$slots,"stretched-card-header")]})),_:3},8,["href","type","class","variant","disabled","tabindex"])):(0,n.RG)(e.$slots,"stretched-card-header",{key:1})]})),_:3},8,["level","heading-style"])):(0,n.Q3)("",!0),(0,n.Lk)("div",d,[(0,n.RG)(e.$slots,"stretched-card-content")]),e.$slots["stretched-card-badges"]&&e.$slots["stretched-card-badges"]()?((0,n.uX)(),(0,n.CE)("div",l,[(0,n.RG)(e.$slots,"stretched-card-badges")])):(0,n.Q3)("",!0),e.$slots["stretched-card-link"]&&e.$slots["stretched-card-link"]()?((0,n.uX)(),(0,n.Wv)(f,{key:4,href:s.link,class:"vs-stretched-link-card__link stretched-link","data-test":"vs-stretched-link-card__link"},{default:(0,n.k6)((function(){return[(0,n.RG)(e.$slots,"stretched-card-link")]})),_:3},8,["href"])):(0,n.Q3)("",!0)],2)):(0,n.Q3)("",!0)],34)}},64500:function(e,t,s){"use strict";var n=s(85072),i=s.n(n),a=s(97825),r=s.n(a),d=s(77659),l=s.n(d),c=s(55056),o=s.n(c),u=s(10540),h=s.n(u),g=s(41113),v=s.n(g),f=s(5314),k=s.n(f),y={};y.styleTagTransform=v(),y.setAttributes=o(),y.insert=l().bind(null,"head"),y.domAPI=r(),y.insertStyleElement=h(),i()(k(),y),k()&&k().locals&&k().locals},59116:function(e,t,s){"use strict";s.r(t);var n=s(65398),i=s(11736);s(18688);const a=(0,s(66262).A)(i.A,[["render",n.X]]);t.default=a},11736:function(e,t,s){"use strict";s.d(t,{A:function(){return n.A}});var n=s(90020)},65398:function(e,t,s){"use strict";s.d(t,{X:function(){return n.X}});var n=s(96518)},18688:function(e,t,s){"use strict";s(64500)}}]);