Only load videojs when there are sources, and minor style tweaks
This commit is contained in:
@@ -20,10 +20,7 @@
|
||||
<a href="http://videojs.com/html5-video-support/" target="_blank">supports HTML5 video</a>
|
||||
| {% else %}
|
||||
.video-dummy.sorry(
|
||||
style="{% if node.picture %}height: {{ node.picture.height }}px{% endif %}")
|
||||
| {% if node.picture %}
|
||||
img.video-dummy-thumbnail(src="{{ node.picture.thumbnail('l', api=api) }}")
|
||||
| {% endif %}
|
||||
style="{% if node.picture %}background-image: url({{ node.picture.thumbnail('l', api=api) }});{% endif %}")
|
||||
.video-dummy-content
|
||||
i.pi-lock.video-dummy-content-icon
|
||||
.video-dummy-content-text
|
||||
@@ -133,8 +130,10 @@
|
||||
#comments-list-items-loading
|
||||
i.pi-spin
|
||||
|
||||
| {% if node.video_sources %}
|
||||
script(type="text/javascript").
|
||||
videojs(document.getElementById('videoplayer'), { fluid: true });
|
||||
| {% endif %}
|
||||
|
||||
include ../../_scripts
|
||||
|
||||
|
@@ -104,7 +104,9 @@ include _scripts
|
||||
|
||||
script(src="{{ url_for('static_pillar', filename='assets/js/vendor/jquery.montage.min.js') }}")
|
||||
script.
|
||||
videojs(document.getElementById('videoplayer'), { fluid: true });
|
||||
| {% if header_video_file %}
|
||||
videojs(document.getElementById('videoplayer'), { fluid: true });
|
||||
| {% endif %}
|
||||
|
||||
function montage(){
|
||||
var $container = $('#featured-list'),
|
||||
|
Reference in New Issue
Block a user