Skip to content

Commit

Permalink
IBX-7983: Handled previewing ezimage field with height of 0 (#2117)
Browse files Browse the repository at this point in the history
  • Loading branch information
barw4 authored Apr 17, 2024
1 parent 2ffae96 commit ef36131
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -433,10 +433,12 @@
<td>{{ 'ezimage.master_dimensions'|trans|desc('Master dimensions') }}:</td>
<td>{{ 'ezimage.width_and_height'|trans({'%width%': field.value.width, '%height%': field.value.height})|desc('Width: %width%px height: %height%px') }}</td>
</tr>
<tr class="ez-field-preview__meta-value-row">
<td>{{ 'ezimage.ratio'|trans|desc('Ratio') }}:</td>
<td>{{ (field.value.width/field.value.height)|round(2) }}</td>
</tr>
{% if field.value.height != '0' %}
<tr class="ez-field-preview__meta-value-row">
<td>{{ 'ezimage.ratio'|trans|desc('Ratio') }}:</td>
<td>{{ (field.value.width/field.value.height)|round(2) }}</td>
</tr>
{% endif %}
</tbody>
</table>
</div>
Expand Down

0 comments on commit ef36131

Please sign in to comment.