moved all thumbnail url decisions to server-side
This commit is contained in:
parent
83b5400c9c
commit
6158ef9724
3 changed files with 5 additions and 6 deletions
|
@ -157,6 +157,9 @@ module.exports = {
|
|||
element['showUrlLong'] = `/${channelName}:${longChannelId}/${element.name}`;
|
||||
element['directUrlLong'] = `/${channelName}:${longChannelId}/${element.name}.${fileExtenstion}`;
|
||||
element['directUrlShort'] = `/${channelName}:${shortChannelId}/${element.name}.${fileExtenstion}`;
|
||||
if (!element.thumbnail || element.thumbnail === '') {
|
||||
element['thumbnail'] = 'https://spee.ch/assets/img/content-freedom-large.png';
|
||||
}
|
||||
});
|
||||
}
|
||||
return resolve(allChannelClaims);
|
||||
|
|
|
@ -155,7 +155,7 @@ module.exports = {
|
|||
element['directUrlLong'] = `/${element.claimId}/${element.name}.${fileExtenstion}`;
|
||||
element['directUrlShort'] = `/${element.claimId}/${element.name}.${fileExtenstion}`;
|
||||
element['contentType'] = element.fileType;
|
||||
element['thumbnail'] = '';
|
||||
element['thumbnail'] = 'https://spee.ch/assets/img/content-freedom-large.png';
|
||||
});
|
||||
}
|
||||
resolve(results);
|
||||
|
|
|
@ -1,11 +1,7 @@
|
|||
<div class='content-list-card'>
|
||||
<a href="{{this.showUrlLong}}"><span class='content-list-card-link'></span></a>
|
||||
{{#ifConditional this.contentType '===' 'video/mp4'}}
|
||||
{{#ifConditional this.thumbnail '===' ''}}
|
||||
<img class="content-list-asset" src="/assets/img/content-freedom-large.png"/>
|
||||
{{else}}
|
||||
<img class="content-list-asset" src="{{this.thumbnail}}"/>
|
||||
{{/ifConditional}}
|
||||
{{else}}
|
||||
<img class="content-list-asset" src="{{this.directUrlLong}}" />
|
||||
{{/ifConditional}}
|
||||
|
|
Loading…
Reference in a new issue