Merge pull request #8866 from Wikia/VE-1993

VE-1993: Render videos in media collection tabs
This commit is contained in:
Inez Korczyński 2015-10-22 16:03:31 -07:00
commit ed23fc1a8e
2 changed files with 11 additions and 1 deletions

View file

@ -191,6 +191,10 @@ ul.pi-image-collection-tabs {
.pi-image-collection-tab-content {
background-color: $infobox-background;
display: none;
.video-thumbnail {
display: block;
}
}
.pi-image-collection-tab-content.current {

View file

@ -9,8 +9,14 @@
{{#images}}
<div class="pi-image-collection-tab-content {{#isFirst}}current{{/isFirst}}" id="pi-tab-{{ref}}">
<figure class="pi-item pi-image">
<a href="{{url}}" class="image image-thumbnail" title="{{alt}}">
<a href="{{url}}" class="image image-thumbnail {{#isVideo}} video video-thumbnail small{{/isVideo}}" title="{{alt}}">
<img src="{{thumbnail}}" class="pi-image-thumbnail" alt="{{alt}}" width="{{{width}}}" height="{{{height}}}" data-{{media-type}}-key="{{name}}" data-{{media-type}}-name="{{name}}"/>
{{#isVideo}}
{{#duration}}
<span class="duration" itemprop="duration">{{duration}}</span>
{{/duration}}
<span class="play-circle"></span>
{{/isVideo}}
</a>
</figure>
</div>