Refactor watch.js

This commit is contained in:
Omar Roth
2019-05-06 09:48:33 -05:00
parent 5e2889e776
commit 2faa2ed1f4
5 changed files with 367 additions and 344 deletions

View File

@@ -61,7 +61,7 @@ var options = {
"fullscreenToggle"
]
}
};
}
var shareOptions = {
socials: ["fbFeed", "tw", "reddit", "email"],
@@ -72,7 +72,7 @@ var shareOptions = {
image: "<%= thumbnail %>",
embedCode: "<iframe id='ivplayer' type='text/html' width='640' height='360' \
src='<%= host_url %>/embed/<%= video.id %>?<%= host_params %>' frameborder='0'></iframe>"
};
}
var player = videojs("player", options, function() {
this.hotkeys({
@@ -242,7 +242,7 @@ xhr.onreadystatechange = function () {
}
}
}
};
}
window.addEventListener('__ar_annotation_click', e => {
const { url, target, seconds } = e.detail;