mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-27 01:21:20 -08:00
add ads option
This commit is contained in:
1 parent
fe0e46212f
commit
0048991f7e
6 files changed
+31
-1
No files matched your search
@@ -141,6 +141,7 @@ export default class Artplayer extends Emitter {
|
||||
localVideo: false,
|
||||
localSubtitle: false,
|
||||
useSSR: false,
|
||||
ads: [],
|
||||
layers: [],
|
||||
contextmenu: [],
|
||||
controls: [],
|
||||
|
||||
@@ -57,6 +57,11 @@ export default {
|
||||
localVideo: b,
|
||||
localSubtitle: b,
|
||||
useSSR: b,
|
||||
ads: [
|
||||
{
|
||||
url: s,
|
||||
},
|
||||
],
|
||||
plugins: [f],
|
||||
whitelist: [`${s}|${f}|${r}`],
|
||||
layers: [ComponentOption],
|
||||
|
||||
+10
@@ -305,6 +305,16 @@ type Option = {
|
||||
*/
|
||||
whitelist?: (string | WhitelistFunction | RegExp)[];
|
||||
|
||||
/**
|
||||
* Custom ads list
|
||||
*/
|
||||
ads?: {
|
||||
/**
|
||||
* The ads video url
|
||||
*/
|
||||
url: string;
|
||||
}[];
|
||||
|
||||
/**
|
||||
* Custom layer list
|
||||
*/
|
||||
|
||||
Reference in new issue
Block a user