mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-28 10:31:20 -08:00
Update index.js
This commit is contained in:
1 parent
18a3e88e62
commit
563e796098
1 file changed
+4
-11
@@ -43,12 +43,7 @@ var art = new Artplayer({
|
|||||||
{
|
{
|
||||||
html: `<img style="width: 100px" src="${url}/image/your-name.png">`,
|
html: `<img style="width: 100px" src="${url}/image/your-name.png">`,
|
||||||
click: function() {
|
click: function() {
|
||||||
art.destroy(true);
|
console.info('You clicked on the custom layer');
|
||||||
art = new Artplayer({
|
|
||||||
autoplay: true,
|
|
||||||
container: '.artplayer-app',
|
|
||||||
url: url + '/video/your-name.mp4',
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
style: {
|
style: {
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
@@ -106,12 +101,10 @@ var art = new Artplayer({
|
|||||||
],
|
],
|
||||||
controls: [
|
controls: [
|
||||||
{
|
{
|
||||||
name: 'localVideo',
|
|
||||||
position: 'right',
|
position: 'right',
|
||||||
html: 'OPEN',
|
html: 'Custom Control',
|
||||||
tooltip: 'Open Local Video',
|
click: function() {
|
||||||
mounted: $preview => {
|
console.info('You clicked on the custom control');
|
||||||
art.plugins.localVideo.attach($preview);
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|||||||
Reference in new issue
Block a user