mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-09 20:26:16 -08:00
添加本地视频预览
This commit is contained in:
1 parent
acdb272393
commit
5c067c2c47
3 files changed
+120
-11
No files matched your search
@@ -96,13 +96,10 @@ var art = new Artplayer({
|
||||
],
|
||||
controls: [
|
||||
{
|
||||
name: 'line',
|
||||
name: 'preview',
|
||||
position: 'right',
|
||||
index: 1,
|
||||
html: '主线',
|
||||
click: function() {
|
||||
console.log('click line');
|
||||
},
|
||||
html: '打开'
|
||||
},
|
||||
],
|
||||
icons: {
|
||||
@@ -111,6 +108,9 @@ var art = new Artplayer({
|
||||
});
|
||||
|
||||
art.on('firstCanplay', () => {
|
||||
var preview = document.querySelector('.art-control-preview');
|
||||
art.plugins.artplayerPluginLocalPreview.attach(preview);
|
||||
|
||||
art.on('resize', $player => {
|
||||
art.controls.quality.show();
|
||||
art.controls.setting.show();
|
||||
|
||||
Reference in new issue
Block a user