{% set res_url = resource_view.get('audio_url') or resource.get('url') %}

<audio style="margin:auto; max-height:100%; display:block; min-width: 100%;"
controls src="{{ resource_view.audio_url or resource.get('url') }}">
  {% trans %}
    Your browser doesn't support <code>HTML5 audio</code>. Here is
    a <a href="{{ res_url }}" alt="audio url">link to the audio</a> instead.
  {% endtrans %}
</audio>
