mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-25 08:01:20 -08:00
refactor: Update artplayer-plugin-vtt-thumbnail version to 1.0.3
This commit is contained in:
1 parent
44171beb3a
commit
c44ec85ed2
8 files changed
+14
-12
No files matched your search
@@ -150,7 +150,7 @@ var _getVttArray = require("./getVttArray");
|
||||
var _getVttArrayDefault = parcelHelpers.interopDefault(_getVttArray);
|
||||
function artplayerPluginVttThumbnail(option) {
|
||||
return async (art)=>{
|
||||
const { constructor: { utils: { setStyle, isMobile } }, template: { $progress } } = art;
|
||||
const { constructor: { utils: { setStyle, isMobile, addClass } }, template: { $progress } } = art;
|
||||
let timer = null;
|
||||
const thumbnails = await (0, _getVttArrayDefault.default)(option.vtt);
|
||||
function showThumbnails($control, find, width) {
|
||||
@@ -168,6 +168,7 @@ function artplayerPluginVttThumbnail(option) {
|
||||
index: 20,
|
||||
style: option.style || {},
|
||||
mounted ($control) {
|
||||
addClass($control, "art-control-thumbnails");
|
||||
art.on("setBar", async (type, percentage, event)=>{
|
||||
const isMobileDroging = type === "played" && event && isMobile;
|
||||
if (type === "hover" || isMobileDroging) {
|
||||
|
||||
Reference in new issue
Block a user