constrain to viewport on large images #254

Merged
bones7242 merged 2 commits from viewport-constraint into master 2017-11-09 00:58:48 +01:00
3 changed files with 5 additions and 5 deletions

View file

@ -526,7 +526,7 @@ table {
padding:6px; padding:6px;
} }
.show-asset-light { .showlite-asset {
max-width: 50%; max-width: 50%;
} }

View file

@ -36,7 +36,7 @@
padding-right: 1.5em; padding-right: 1.5em;
} }
.show-asset-light { .showlite-asset {
max-width: 100%; max-width: 100%;
} }

View file

@ -1,12 +1,12 @@
{{#ifConditional fileInfo.fileType '===' 'video/mp4'}} {{#ifConditional fileInfo.fileType '===' 'video/mp4'}}
{{#ifConditional fileInfo.fileExt '===' '.gifv'}} {{#ifConditional fileInfo.fileExt '===' '.gifv'}}
<video class="show-asset-light" autoplay loop muted> <video class="showlite-asset" autoplay loop muted>
<source src="/{{fileInfo.claimId}}/{{fileInfo.name}}.{{fileInfo.fileExt}}"> <source src="/{{fileInfo.claimId}}/{{fileInfo.name}}.{{fileInfo.fileExt}}">
{{!--fallback--}} {{!--fallback--}}
Your browser does not support the <code>video</code> element. Your browser does not support the <code>video</code> element.
</video> </video>
{{else}} {{else}}
<video class="show-asset-light" controls id="video-player"> <video class="showlite-asset" controls id="video-player">
<source src="/{{fileInfo.claimId}}/{{fileInfo.name}}.{{fileInfo.fileExt}}"> <source src="/{{fileInfo.claimId}}/{{fileInfo.name}}.{{fileInfo.fileExt}}">
{{!--fallback--}} {{!--fallback--}}
Your browser does not support the <code>video</code> element. Your browser does not support the <code>video</code> element.
@ -16,6 +16,6 @@
<a class="link--primary fine-print" href="/{{fileInfo.claimId}}/{{fileInfo.name}}">hosted via spee&lt;h</a> <a class="link--primary fine-print" href="/{{fileInfo.claimId}}/{{fileInfo.name}}">hosted via spee&lt;h</a>
{{else}} {{else}}
<a href="/{{fileInfo.claimId}}/{{fileInfo.name}}"> <a href="/{{fileInfo.claimId}}/{{fileInfo.name}}">
<img class="show-asset-lite" src="/{{fileInfo.claimId}}/{{fileInfo.name}}.{{fileInfo.fileExt}}" alt="{{fileInfo.fileName}}"/> <img class="showlite-asset" src="/{{fileInfo.claimId}}/{{fileInfo.name}}.{{fileInfo.fileExt}}" alt="{{fileInfo.fileName}}"/>
</a> </a>
{{/ifConditional}} {{/ifConditional}}