- player bug in admin fix

- player rendering issue fix
- station.streams property
- glitch in template rendering when page parent is not published
This commit is contained in:
bkfox
2022-12-16 14:53:11 +01:00
parent 8bd11f363b
commit 246eba6654
9 changed files with 40 additions and 19 deletions

View File

@ -5,12 +5,13 @@ Base template used to display a Page
Context:
- page: page
- parent: parent page
{% endcomment %}
{% block header_crumbs %}
{{ block.super }}
{% if page.category %}
/ {{ page.category.title }}
{% if parent %} / {% endif %} {{ page.category.title }}
{% endif %}
{% endblock %}

View File

@ -9,8 +9,9 @@ The audio player
role="{% translate "player" %}"
aria-description="{% translate "Audio player used to listen to the radio and podcasts" %}">
<noscript>
<audio src="{{ audio_streams.0 }}" controls>
{% for stream in audio_streams %}
<audio src="{% if request.station.streams %}{{ request.station.streams.0 }}{% endif %}"
controls>
{% for stream in request.station.streams %}
<source src="{{ stream }}" />
{% endfor %}
</audio>
@ -18,7 +19,7 @@ The audio player
</noscript>
<a-player ref="player"
:live-args="{url: '{% url "api:live" %}', timeout:10, src: {{ audio_streams|json }} || []}"
:live-args="{% player_live_attr %}"
button-title="{% translate "Play or pause audio" %}">
<template v-slot:content="{ loaded, live, current }">
<h4 v-if="loaded" class="title is-4">