diff options
author | Sam Potts <sam@potts.es> | 2019-04-30 23:44:05 +1000 |
---|---|---|
committer | Sam Potts <sam@potts.es> | 2019-04-30 23:44:05 +1000 |
commit | 80aa6ffe435b170466838f977d52438a95e22186 (patch) | |
tree | 0243268c1dd2af2ded86c03f2ea222032cb58527 /src/js/plugins/previewThumbnails.js | |
parent | 0694e586502f7ce85ce7858b67d515403b48c87e (diff) | |
download | plyr-80aa6ffe435b170466838f977d52438a95e22186.tar.lz plyr-80aa6ffe435b170466838f977d52438a95e22186.tar.xz plyr-80aa6ffe435b170466838f977d52438a95e22186.zip |
Linting changes
Diffstat (limited to 'src/js/plugins/previewThumbnails.js')
-rw-r--r-- | src/js/plugins/previewThumbnails.js | 4 |
1 files changed, 0 insertions, 4 deletions
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; |