2
0
mirror of https://github.com/inventree/inventree-docs.git synced 2025-04-27 21:26:43 +00:00

Update img.html

This commit is contained in:
Oliver 2020-09-21 23:31:24 +10:00 committed by GitHub
parent 81dbc9194c
commit 863311bcce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,12 +1,13 @@
{% set assets = '/en/latest/assets' %}
<figure class='image'>
{% if id %}
<!-- The link that, when clicked, will display the image in full screen -->
<a href="#{{ id }}">
{% elif url %}
<a href="{{ base_url }}/assets/images/{{ url }}">
<a href="{{ assets }}/images/{{ url }}">
{% endif %}
<img class='img-inline' src='{{ base_url }}/assets/images/{{ url }}' alt='{{ description }}' title='{{ description }}'
<img class='img-inline' src='{{ assets }}/images/{{ url }}' alt='{{ description }}' title='{{ description }}'
{% if maxwidth or maxheight %}style='
{% if maxwidth %} max-width:{{ maxwidth }};{% endif %}
{% if maxheight %} max-height: {{ maxheight }};{% endif %}
@ -19,7 +20,7 @@
{% if id %}
<!-- The full screen image, hidden by default -->
<a href="#_" class="overlay" id="{{ id }}">
<img src="{{ base_url }}/assets/images/{{ url }}" alt="{{ description }}" />
<img src="{{ assets }}/images/{{ url }}" alt="{{ description }}" />
</a>
{% endif %}
</figure>