aboutsummaryrefslogtreecommitdiffstats
path: root/src/js/plugins
diff options
context:
space:
mode:
authorSam Potts <sam@potts.es>2019-04-30 23:44:05 +1000
committerSam Potts <sam@potts.es>2019-04-30 23:44:05 +1000
commit80aa6ffe435b170466838f977d52438a95e22186 (patch)
tree0243268c1dd2af2ded86c03f2ea222032cb58527 /src/js/plugins
parent0694e586502f7ce85ce7858b67d515403b48c87e (diff)
downloadplyr-80aa6ffe435b170466838f977d52438a95e22186.tar.lz
plyr-80aa6ffe435b170466838f977d52438a95e22186.tar.xz
plyr-80aa6ffe435b170466838f977d52438a95e22186.zip
Linting changes
Diffstat (limited to 'src/js/plugins')
-rw-r--r--src/js/plugins/ads.js1
-rw-r--r--src/js/plugins/previewThumbnails.js4
-rw-r--r--src/js/plugins/vimeo.js2
-rw-r--r--src/js/plugins/youtube.js3
4 files changed, 0 insertions, 10 deletions
diff --git a/src/js/plugins/ads.js b/src/js/plugins/ads.js
index 2b083285..2acfaed9 100644
--- a/src/js/plugins/ads.js
+++ b/src/js/plugins/ads.js
@@ -303,7 +303,6 @@ class Ads {
*/
onAdEvent(event) {
const { container } = this.player.elements;
-
// Retrieve the ad from the event. Some events (e.g. ALL_ADS_COMPLETED)
// don't have ad object associated
const ad = event.getAd();
diff --git a/src/js/plugins/previewThumbnails.js b/src/js/plugins/previewThumbnails.js
index 3e4b17a3..f03abe69 100644
--- a/src/js/plugins/previewThumbnails.js
+++ b/src/js/plugins/previewThumbnails.js
@@ -121,7 +121,6 @@ class PreviewThumbnails {
// If string, convert into single-element list
const urls = is.string(src) ? [src] : src;
-
// Loop through each src URL. Download and process the VTT file, storing the resulting data in this.thumbnails
const promises = urls.map(u => this.getThumbnail(u));
@@ -467,7 +466,6 @@ class PreviewThumbnails {
const { urlPrefix } = this.thumbnails[0];
const thumbURL = urlPrefix + newThumbFilename;
-
const previewImage = new Image();
previewImage.src = thumbURL;
previewImage.onload = () => {
@@ -601,11 +599,9 @@ class PreviewThumbnails {
const seekbarRect = this.player.elements.progress.getBoundingClientRect();
const plyrRect = this.player.elements.container.getBoundingClientRect();
const { container } = this.elements.thumb;
-
// Find the lowest and highest desired left-position, so we don't slide out the side of the video container
const minVal = plyrRect.left - seekbarRect.left + 10;
const maxVal = plyrRect.right - seekbarRect.left - container.clientWidth - 10;
-
// Set preview container position to: mousepos, minus seekbar.left, minus half of previewContainer.clientWidth
let previewPos = this.mousePosX - seekbarRect.left - container.clientWidth / 2;
diff --git a/src/js/plugins/vimeo.js b/src/js/plugins/vimeo.js
index 8d920eea..bef48708 100644
--- a/src/js/plugins/vimeo.js
+++ b/src/js/plugins/vimeo.js
@@ -91,7 +91,6 @@ const vimeo = {
}
const id = parseId(source);
-
// Build an iframe
const iframe = createElement('iframe');
const src = format(player.config.urls.vimeo.iframe, id, params);
@@ -102,7 +101,6 @@ const vimeo = {
// Get poster, if already set
const { poster } = player;
-
// Inject the package
const wrapper = createElement('div', { poster, class: player.config.classNames.embedContainer });
wrapper.appendChild(iframe);
diff --git a/src/js/plugins/youtube.js b/src/js/plugins/youtube.js
index 7abc05fe..a5b1dafd 100644
--- a/src/js/plugins/youtube.js
+++ b/src/js/plugins/youtube.js
@@ -107,7 +107,6 @@ const youtube = {
// API ready
ready() {
const player = this;
-
// Ignore already setup (race condition)
const currentId = player.media.getAttribute('id');
if (!is.empty(currentId) && currentId.startsWith('youtube-')) {
@@ -125,10 +124,8 @@ const youtube = {
// Replace the <iframe> with a <div> due to YouTube API issues
const videoId = parseId(source);
const id = generateId(player.provider);
-
// Get poster, if already set
const { poster } = player;
-
// Replace media element
const container = createElement('div', { id, poster });
player.media = replaceElement(container, player.media);