Skip to content

Commit

Permalink
[BUGFIX] add if-statement for media, if showinpreview is enabled/disa…
Browse files Browse the repository at this point in the history
…bled (#482)
  • Loading branch information
mesosa authored and dmh committed Mar 1, 2019
1 parent 1f6bb43 commit 6c65146
Showing 1 changed file with 13 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,19 @@
</f:comment>
<div class="news-img-wrap {f:if(condition:'{settings.detail.media.image.lightbox.enabled}', then:'lightbox__wrp-news' )}">
<f:for each="{media}" as="mediaElement">
<div class="outer">
<f:if condition="{mediaElement.originalResource.type} == 2">
<f:render partial="Detail/MediaImage" arguments="{mediaElement: mediaElement, settings:settings}"/>
</f:if>
<f:if condition="{mediaElement.originalResource.type} == 4">
<f:render partial="Detail/MediaVideo" arguments="{mediaElement: mediaElement, settings:settings}"/>
</f:if>
<f:if condition="{mediaElement.originalResource.type} == 5">
<f:render partial="Detail/MediaImage" arguments="{mediaElement: mediaElement, settings:settings}"/>
</f:if>
</div>
<f:if condition="{mediaElement.showinpreview} != 2">
<div class="outer">
<f:if condition="{mediaElement.originalResource.type} == 2">
<f:render partial="Detail/MediaImage" arguments="{mediaElement: mediaElement, settings:settings}"/>
</f:if>
<f:if condition="{mediaElement.originalResource.type} == 4">
<f:render partial="Detail/MediaVideo" arguments="{mediaElement: mediaElement, settings:settings}"/>
</f:if>
<f:if condition="{mediaElement.originalResource.type} == 5">
<f:render partial="Detail/MediaImage" arguments="{mediaElement: mediaElement, settings:settings}"/>
</f:if>
</div>
</f:if>
</f:for>
</div>
</f:if>
Expand Down

0 comments on commit 6c65146

Please sign in to comment.