@asd20/ui 3.2.582 → 3.2.584

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.
@@ -190,16 +190,30 @@ export default {
190
190
  const firstVideo = videos[0]
191
191
 
192
192
  let imageUrl = null
193
+ let headerImageUrl = null
193
194
  let imageCaption = null
194
195
  let videoUrl = firstVideo ? firstVideo.watchUrl : null
195
196
 
197
+ // if (coverImage) {
198
+ // const coverImageFiles = coverImage.files || []
199
+ // const coverImageFull = coverImageFiles.find(f => f.name === 'full')
200
+ // imageUrl = coverImageFull ? coverImageFull.url : coverImage.url || ''
201
+ // imageCaption = coverImage.metadata
202
+ // ? coverImage.metadata.alt
203
+ // : coverImage.alt || ''
204
+ // }
196
205
  if (coverImage) {
197
206
  const coverImageFiles = coverImage.files || []
198
207
  const coverImageFull = coverImageFiles.find(f => f.name === 'full')
199
- imageUrl = coverImageFull ? coverImageFull.url : coverImage.url || ''
200
- imageCaption = coverImage.metadata
201
- ? coverImage.metadata.alt
202
- : coverImage.alt || ''
208
+ if (coverImageFull && coverImageFull.filename.includes('headerimage')) {
209
+ imageUrl = ''
210
+ headerImageUrl = coverImageFull ? coverImageFull.url : coverImage.url || ''
211
+ } else {
212
+ imageUrl = coverImageFull ? coverImageFull.url : coverImage.url || ''
213
+ imageCaption = coverImage.metadata
214
+ ? coverImage.metadata.alt
215
+ : coverImage.alt || ''
216
+ }
203
217
  }
204
218
  // else if (firstVideo) {
205
219
  // imageUrl = firstVideo.coverImageUrl
@@ -213,6 +227,7 @@ export default {
213
227
  lead: this.firstMessage.shortDescription || '',
214
228
  imageUrl,
215
229
  imageCaption,
230
+ headerImageUrl,
216
231
  videoUrl,
217
232
  callsToAction: this.firstMessage.callsToAction,
218
233
  detailLink: this.firstMessage ? this.firstMessage.detailLink : '',