Fix project header videos
This commit is contained in:
@@ -130,17 +130,11 @@
|
|||||||
#comments-list-items-loading
|
#comments-list-items-loading
|
||||||
i.pi-spin
|
i.pi-spin
|
||||||
|
|
||||||
| {% if node.video_sources %}
|
|
||||||
script(type="text/javascript").
|
script(type="text/javascript").
|
||||||
|
{% if node.video_sources %}
|
||||||
videojs(document.getElementById('videoplayer'), { fluid: true });
|
videojs(document.getElementById('videoplayer'), { fluid: true });
|
||||||
| {% endif %}
|
{% endif %}
|
||||||
|
|
||||||
include ../../_scripts
|
|
||||||
|
|
||||||
| {% endblock %}
|
|
||||||
|
|
||||||
| {% block footer_scripts %}
|
|
||||||
script(type="text/javascript").
|
|
||||||
$(function(){
|
$(function(){
|
||||||
// Generate GA pageview
|
// Generate GA pageview
|
||||||
ga('send', 'pageview', location.pathname);
|
ga('send', 'pageview', location.pathname);
|
||||||
@@ -157,4 +151,6 @@ script(type="text/javascript").
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
include ../../_scripts
|
||||||
|
|
||||||
| {% endblock %}
|
| {% endblock %}
|
||||||
|
@@ -1,9 +1,3 @@
|
|||||||
| {% block head %}
|
|
||||||
| {% if header_video_file %}
|
|
||||||
script(src="//vjs.zencdn.net/5.8.8/video.js")
|
|
||||||
| {% endif %}
|
|
||||||
| {% endblock %}
|
|
||||||
|
|
||||||
| {% block body %}
|
| {% block body %}
|
||||||
|
|
||||||
#node-container
|
#node-container
|
||||||
@@ -13,11 +7,11 @@ script(src="//vjs.zencdn.net/5.8.8/video.js")
|
|||||||
controls,
|
controls,
|
||||||
data-setup="{}",
|
data-setup="{}",
|
||||||
preload="auto",
|
preload="auto",
|
||||||
poster="{% if node.picture %}{{ header_video_node.picture.thumbnail('l', api=api) }}{% endif %}")
|
poster="{% if header_video_node.picture %}{{ header_video_node.picture.thumbnail('l', api=api) }}{% endif %}")
|
||||||
| {% for source in node.video_sources %}
|
| {% for source in header_video_file.variations %}
|
||||||
source(
|
source(
|
||||||
src="{{ source.src }}",
|
src="{{ source.link | safe }}",
|
||||||
type="{{ source.type }}")
|
type="{{ source.content_type }}")
|
||||||
| {% endfor %}
|
| {% endfor %}
|
||||||
p.vjs-no-js.
|
p.vjs-no-js.
|
||||||
To view this video please enable JavaScript, and consider upgrading to a web browser that
|
To view this video please enable JavaScript, and consider upgrading to a web browser that
|
||||||
@@ -104,10 +98,6 @@ include _scripts
|
|||||||
|
|
||||||
script(src="{{ url_for('static_pillar', filename='assets/js/vendor/jquery.montage.min.js') }}")
|
script(src="{{ url_for('static_pillar', filename='assets/js/vendor/jquery.montage.min.js') }}")
|
||||||
script.
|
script.
|
||||||
{% if header_video_file %}
|
|
||||||
videojs(document.getElementById('videoplayer'), { fluid: true });
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
function montage(){
|
function montage(){
|
||||||
var $container = $('#featured-list'),
|
var $container = $('#featured-list'),
|
||||||
$imgs = $container.find('img').hide(),
|
$imgs = $container.find('img').hide(),
|
||||||
|
Reference in New Issue
Block a user